1 #!/bin/bash
   2 #
   3 # ##########################################################
   4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ###
   5 # ##########################################################
   6 #
   7 #! /bin/sh
   8 # Guess values for system-dependent variables and create Makefiles.
   9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk8.
  10 #
  11 # Report bugs to <build-dev@openjdk.java.net>.
  12 #
  13 #
  14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
  15 #
  16 #
  17 # This configure script is free software; the Free Software Foundation
  18 # gives unlimited permission to copy, distribute and modify it.
  19 ## -------------------- ##
  20 ## M4sh Initialization. ##
  21 ## -------------------- ##
  22 
  23 # Be more Bourne compatible
  24 DUALCASE=1; export DUALCASE # for MKS sh
  25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  26   emulate sh
  27   NULLCMD=:
  28   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  29   # is contrary to our usage.  Disable this feature.
  30   alias -g '${1+"$@"}'='"$@"'
  31   setopt NO_GLOB_SUBST
  32 else
  33   case `(set -o) 2>/dev/null` in #(
  34   *posix*) :
  35     set -o posix ;; #(
  36   *) :
  37      ;;
  38 esac
  39 fi
  40 
  41 
  42 as_nl='
  43 '
  44 export as_nl
  45 # Printing a long string crashes Solaris 7 /usr/bin/printf.
  46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  49 # Prefer a ksh shell builtin over an external printf program on Solaris,
  50 # but without wasting forks for bash or zsh.
  51 if test -z "$BASH_VERSION$ZSH_VERSION" \
  52     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  53   as_echo='print -r --'
  54   as_echo_n='print -rn --'
  55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  56   as_echo='printf %s\n'
  57   as_echo_n='printf %s'
  58 else
  59   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  60     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  61     as_echo_n='/usr/ucb/echo -n'
  62   else
  63     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  64     as_echo_n_body='eval
  65       arg=$1;
  66       case $arg in #(
  67       *"$as_nl"*)
  68         expr "X$arg" : "X\\(.*\\)$as_nl";
  69         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  70       esac;
  71       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  72     '
  73     export as_echo_n_body
  74     as_echo_n='sh -c $as_echo_n_body as_echo'
  75   fi
  76   export as_echo_body
  77   as_echo='sh -c $as_echo_body as_echo'
  78 fi
  79 
  80 # The user is always right.
  81 if test "${PATH_SEPARATOR+set}" != set; then
  82   PATH_SEPARATOR=:
  83   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  84     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  85       PATH_SEPARATOR=';'
  86   }
  87 fi
  88 
  89 
  90 # IFS
  91 # We need space, tab and new line, in precisely that order.  Quoting is
  92 # there to prevent editors from complaining about space-tab.
  93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  94 # splitting by setting IFS to empty value.)
  95 IFS=" ""        $as_nl"
  96 
  97 # Find who we are.  Look in the path if we contain no directory separator.
  98 as_myself=
  99 case $0 in #((
 100   *[\\/]* ) as_myself=$0 ;;
 101   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 102 for as_dir in $PATH
 103 do
 104   IFS=$as_save_IFS
 105   test -z "$as_dir" && as_dir=.
 106     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
 107   done
 108 IFS=$as_save_IFS
 109 
 110      ;;
 111 esac
 112 # We did not find ourselves, most probably we were run as `sh COMMAND'
 113 # in which case we are not to be found in the path.
 114 if test "x$as_myself" = x; then
 115   as_myself=$0
 116 fi
 117 if test ! -f "$as_myself"; then
 118   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
 119   exit 1
 120 fi
 121 
 122 # Unset variables that we do not need and which cause bugs (e.g. in
 123 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
 124 # suppresses any "Segmentation fault" message there.  '((' could
 125 # trigger a bug in pdksh 5.2.14.
 126 for as_var in BASH_ENV ENV MAIL MAILPATH
 127 do eval test x\${$as_var+set} = xset \
 128   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
 129 done
 130 PS1='$ '
 131 PS2='> '
 132 PS4='+ '
 133 
 134 # NLS nuisances.
 135 LC_ALL=C
 136 export LC_ALL
 137 LANGUAGE=C
 138 export LANGUAGE
 139 
 140 # CDPATH.
 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
 142 
 143 # Use a proper internal environment variable to ensure we don't fall
 144   # into an infinite loop, continuously re-executing ourselves.
 145   if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
 146     _as_can_reexec=no; export _as_can_reexec;
 147     # We cannot yet assume a decent shell, so we have to provide a
 148 # neutralization value for shells without unset; and this also
 149 # works around shells that cannot unset nonexistent variables.
 150 # Preserve -v and -x to the replacement shell.
 151 BASH_ENV=/dev/null
 152 ENV=/dev/null
 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
 154 case $- in # ((((
 155   *v*x* | *x*v* ) as_opts=-vx ;;
 156   *v* ) as_opts=-v ;;
 157   *x* ) as_opts=-x ;;
 158   * ) as_opts= ;;
 159 esac
 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
 161 # Admittedly, this is quite paranoid, since all the known shells bail
 162 # out after a failed `exec'.
 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
 164 as_fn_exit 255
 165   fi
 166   # We don't want this to propagate to other subprocesses.
 167           { _as_can_reexec=; unset _as_can_reexec;}
 168 if test "x$CONFIG_SHELL" = x; then
 169   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
 170   emulate sh
 171   NULLCMD=:
 172   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
 173   # is contrary to our usage.  Disable this feature.
 174   alias -g '\${1+\"\$@\"}'='\"\$@\"'
 175   setopt NO_GLOB_SUBST
 176 else
 177   case \`(set -o) 2>/dev/null\` in #(
 178   *posix*) :
 179     set -o posix ;; #(
 180   *) :
 181      ;;
 182 esac
 183 fi
 184 "
 185   as_required="as_fn_return () { (exit \$1); }
 186 as_fn_success () { as_fn_return 0; }
 187 as_fn_failure () { as_fn_return 1; }
 188 as_fn_ret_success () { return 0; }
 189 as_fn_ret_failure () { return 1; }
 190 
 191 exitcode=0
 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
 197 
 198 else
 199   exitcode=1; echo positional parameters were not saved.
 200 fi
 201 test x\$exitcode = x0 || exit 1
 202 test -x / || exit 1"
 203   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
 204   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
 205   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
 206   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
 207 test \$(( 1 + 1 )) = 2 || exit 1"
 208   if (eval "$as_required") 2>/dev/null; then :
 209   as_have_required=yes
 210 else
 211   as_have_required=no
 212 fi
 213   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
 214 
 215 else
 216   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 217 as_found=false
 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
 219 do
 220   IFS=$as_save_IFS
 221   test -z "$as_dir" && as_dir=.
 222   as_found=:
 223   case $as_dir in #(
 224          /*)
 225            for as_base in sh bash ksh sh5; do
 226              # Try only shells that exist, to save several forks.
 227              as_shell=$as_dir/$as_base
 228              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
 229                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
 230   CONFIG_SHELL=$as_shell as_have_required=yes
 231                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
 232   break 2
 233 fi
 234 fi
 235            done;;
 236        esac
 237   as_found=false
 238 done
 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
 240               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
 241   CONFIG_SHELL=$SHELL as_have_required=yes
 242 fi; }
 243 IFS=$as_save_IFS
 244 
 245 
 246       if test "x$CONFIG_SHELL" != x; then :
 247   export CONFIG_SHELL
 248              # We cannot yet assume a decent shell, so we have to provide a
 249 # neutralization value for shells without unset; and this also
 250 # works around shells that cannot unset nonexistent variables.
 251 # Preserve -v and -x to the replacement shell.
 252 BASH_ENV=/dev/null
 253 ENV=/dev/null
 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
 255 case $- in # ((((
 256   *v*x* | *x*v* ) as_opts=-vx ;;
 257   *v* ) as_opts=-v ;;
 258   *x* ) as_opts=-x ;;
 259   * ) as_opts= ;;
 260 esac
 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
 262 # Admittedly, this is quite paranoid, since all the known shells bail
 263 # out after a failed `exec'.
 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
 265 exit 255
 266 fi
 267 
 268     if test x$as_have_required = xno; then :
 269   $as_echo "$0: This script requires a shell more modern than all"
 270   $as_echo "$0: the shells that I found on your system."
 271   if test x${ZSH_VERSION+set} = xset ; then
 272     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
 273     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
 274   else
 275     $as_echo "$0: Please tell bug-autoconf@gnu.org and
 276 $0: build-dev@openjdk.java.net about your system, including
 277 $0: any error possibly output before this message. Then
 278 $0: install a modern shell, or manually run the script
 279 $0: under such a shell if you do have one."
 280   fi
 281   exit 1
 282 fi
 283 fi
 284 fi
 285 SHELL=${CONFIG_SHELL-/bin/sh}
 286 export SHELL
 287 # Unset more variables known to interfere with behavior of common tools.
 288 CLICOLOR_FORCE= GREP_OPTIONS=
 289 unset CLICOLOR_FORCE GREP_OPTIONS
 290 
 291 ## --------------------- ##
 292 ## M4sh Shell Functions. ##
 293 ## --------------------- ##
 294 # as_fn_unset VAR
 295 # ---------------
 296 # Portably unset VAR.
 297 as_fn_unset ()
 298 {
 299   { eval $1=; unset $1;}
 300 }
 301 as_unset=as_fn_unset
 302 
 303 # as_fn_set_status STATUS
 304 # -----------------------
 305 # Set $? to STATUS, without forking.
 306 as_fn_set_status ()
 307 {
 308   return $1
 309 } # as_fn_set_status
 310 
 311 # as_fn_exit STATUS
 312 # -----------------
 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
 314 as_fn_exit ()
 315 {
 316   set +e
 317   as_fn_set_status $1
 318   exit $1
 319 } # as_fn_exit
 320 
 321 # as_fn_mkdir_p
 322 # -------------
 323 # Create "$as_dir" as a directory, including parents if necessary.
 324 as_fn_mkdir_p ()
 325 {
 326 
 327   case $as_dir in #(
 328   -*) as_dir=./$as_dir;;
 329   esac
 330   test -d "$as_dir" || eval $as_mkdir_p || {
 331     as_dirs=
 332     while :; do
 333       case $as_dir in #(
 334       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
 335       *) as_qdir=$as_dir;;
 336       esac
 337       as_dirs="'$as_qdir' $as_dirs"
 338       as_dir=`$as_dirname -- "$as_dir" ||
 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
 340          X"$as_dir" : 'X\(//\)[^/]' \| \
 341          X"$as_dir" : 'X\(//\)$' \| \
 342          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
 343 $as_echo X"$as_dir" |
 344     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
 345             s//\1/
 346             q
 347           }
 348           /^X\(\/\/\)[^/].*/{
 349             s//\1/
 350             q
 351           }
 352           /^X\(\/\/\)$/{
 353             s//\1/
 354             q
 355           }
 356           /^X\(\/\).*/{
 357             s//\1/
 358             q
 359           }
 360           s/.*/./; q'`
 361       test -d "$as_dir" && break
 362     done
 363     test -z "$as_dirs" || eval "mkdir $as_dirs"
 364   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
 365 
 366 
 367 } # as_fn_mkdir_p
 368 
 369 # as_fn_executable_p FILE
 370 # -----------------------
 371 # Test if FILE is an executable regular file.
 372 as_fn_executable_p ()
 373 {
 374   test -f "$1" && test -x "$1"
 375 } # as_fn_executable_p
 376 # as_fn_append VAR VALUE
 377 # ----------------------
 378 # Append the text in VALUE to the end of the definition contained in VAR. Take
 379 # advantage of any shell optimizations that allow amortized linear growth over
 380 # repeated appends, instead of the typical quadratic growth present in naive
 381 # implementations.
 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
 383   eval 'as_fn_append ()
 384   {
 385     eval $1+=\$2
 386   }'
 387 else
 388   as_fn_append ()
 389   {
 390     eval $1=\$$1\$2
 391   }
 392 fi # as_fn_append
 393 
 394 # as_fn_arith ARG...
 395 # ------------------
 396 # Perform arithmetic evaluation on the ARGs, and store the result in the
 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments
 398 # must be portable across $(()) and expr.
 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
 400   eval 'as_fn_arith ()
 401   {
 402     as_val=$(( $* ))
 403   }'
 404 else
 405   as_fn_arith ()
 406   {
 407     as_val=`expr "$@" || test $? -eq 1`
 408   }
 409 fi # as_fn_arith
 410 
 411 
 412 # as_fn_error STATUS ERROR [LINENO LOG_FD]
 413 # ----------------------------------------
 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
 416 # script with STATUS, using 1 if that was 0.
 417 as_fn_error ()
 418 {
 419   as_status=$1; test $as_status -eq 0 && as_status=1
 420   if test "$4"; then
 421     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
 422     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
 423   fi
 424   $as_echo "$as_me: error: $2" >&2
 425   as_fn_exit $as_status
 426 } # as_fn_error
 427 
 428 if expr a : '\(a\)' >/dev/null 2>&1 &&
 429    test "X`expr 00001 : '.*\(...\)'`" = X001; then
 430   as_expr=expr
 431 else
 432   as_expr=false
 433 fi
 434 
 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
 436   as_basename=basename
 437 else
 438   as_basename=false
 439 fi
 440 
 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
 442   as_dirname=dirname
 443 else
 444   as_dirname=false
 445 fi
 446 
 447 as_me=`$as_basename -- "$0" ||
 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
 449          X"$0" : 'X\(//\)$' \| \
 450          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
 451 $as_echo X/"$0" |
 452     sed '/^.*\/\([^/][^/]*\)\/*$/{
 453             s//\1/
 454             q
 455           }
 456           /^X\/\(\/\/\)$/{
 457             s//\1/
 458             q
 459           }
 460           /^X\/\(\/\).*/{
 461             s//\1/
 462             q
 463           }
 464           s/.*/./; q'`
 465 
 466 # Avoid depending upon Character Ranges.
 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
 470 as_cr_digits='0123456789'
 471 as_cr_alnum=$as_cr_Letters$as_cr_digits
 472 
 473 
 474   as_lineno_1=$LINENO as_lineno_1a=$LINENO
 475   as_lineno_2=$LINENO as_lineno_2a=$LINENO
 476   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
 477   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
 478   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
 479   sed -n '
 480     p
 481     /[$]LINENO/=
 482   ' <$as_myself |
 483     sed '
 484       s/[$]LINENO.*/&-/
 485       t lineno
 486       b
 487       :lineno
 488       N
 489       :loop
 490       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
 491       t loop
 492       s/-\n.*//
 493     ' >$as_me.lineno &&
 494   chmod +x "$as_me.lineno" ||
 495     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
 496 
 497   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
 498   # already done that, so ensure we don't try to do so again and fall
 499   # in an infinite loop.  This has already happened in practice.
 500   _as_can_reexec=no; export _as_can_reexec
 501   # Don't try to exec as it changes $[0], causing all sort of problems
 502   # (the dirname of $[0] is not the place where we might find the
 503   # original and so on.  Autoconf is especially sensitive to this).
 504   . "./$as_me.lineno"
 505   # Exit status is that of the last command.
 506   exit
 507 }
 508 
 509 ECHO_C= ECHO_N= ECHO_T=
 510 case `echo -n x` in #(((((
 511 -n*)
 512   case `echo 'xy\c'` in
 513   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
 514   xy)  ECHO_C='\c';;
 515   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
 516        ECHO_T=' ';;
 517   esac;;
 518 *)
 519   ECHO_N='-n';;
 520 esac
 521 
 522 rm -f conf$$ conf$$.exe conf$$.file
 523 if test -d conf$$.dir; then
 524   rm -f conf$$.dir/conf$$.file
 525 else
 526   rm -f conf$$.dir
 527   mkdir conf$$.dir 2>/dev/null
 528 fi
 529 if (echo >conf$$.file) 2>/dev/null; then
 530   if ln -s conf$$.file conf$$ 2>/dev/null; then
 531     as_ln_s='ln -s'
 532     # ... but there are two gotchas:
 533     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
 534     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
 535     # In both cases, we have to default to `cp -pR'.
 536     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
 537       as_ln_s='cp -pR'
 538   elif ln conf$$.file conf$$ 2>/dev/null; then
 539     as_ln_s=ln
 540   else
 541     as_ln_s='cp -pR'
 542   fi
 543 else
 544   as_ln_s='cp -pR'
 545 fi
 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
 547 rmdir conf$$.dir 2>/dev/null
 548 
 549 if mkdir -p . 2>/dev/null; then
 550   as_mkdir_p='mkdir -p "$as_dir"'
 551 else
 552   test -d ./-p && rmdir ./-p
 553   as_mkdir_p=false
 554 fi
 555 
 556 as_test_x='test -x'
 557 as_executable_p=as_fn_executable_p
 558 
 559 # Sed expression to map a string onto a valid CPP name.
 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
 561 
 562 # Sed expression to map a string onto a valid variable name.
 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
 564 
 565 
 566 test -n "$DJDIR" || exec 7<&0 </dev/null
 567 exec 6>&1
 568 
 569 # Name of the host.
 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
 571 # so uname gets run too.
 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
 573 
 574 #
 575 # Initializations.
 576 #
 577 ac_default_prefix=/usr/local
 578 ac_clean_files=
 579 ac_config_libobj_dir=.
 580 LIBOBJS=
 581 cross_compiling=no
 582 subdirs=
 583 MFLAGS=
 584 MAKEFLAGS=
 585 
 586 # Identity of this package.
 587 PACKAGE_NAME='OpenJDK'
 588 PACKAGE_TARNAME='openjdk'
 589 PACKAGE_VERSION='jdk8'
 590 PACKAGE_STRING='OpenJDK jdk8'
 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net'
 592 PACKAGE_URL='http://openjdk.java.net'
 593 
 594 # Factoring default headers for most tests.
 595 ac_includes_default="\
 596 #include <stdio.h>
 597 #ifdef HAVE_SYS_TYPES_H
 598 # include <sys/types.h>
 599 #endif
 600 #ifdef HAVE_SYS_STAT_H
 601 # include <sys/stat.h>
 602 #endif
 603 #ifdef STDC_HEADERS
 604 # include <stdlib.h>
 605 # include <stddef.h>
 606 #else
 607 # ifdef HAVE_STDLIB_H
 608 #  include <stdlib.h>
 609 # endif
 610 #endif
 611 #ifdef HAVE_STRING_H
 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
 613 #  include <memory.h>
 614 # endif
 615 # include <string.h>
 616 #endif
 617 #ifdef HAVE_STRINGS_H
 618 # include <strings.h>
 619 #endif
 620 #ifdef HAVE_INTTYPES_H
 621 # include <inttypes.h>
 622 #endif
 623 #ifdef HAVE_STDINT_H
 624 # include <stdint.h>
 625 #endif
 626 #ifdef HAVE_UNISTD_H
 627 # include <unistd.h>
 628 #endif"
 629 
 630 ac_subst_vars='LTLIBOBJS
 631 LIBOBJS
 632 CCACHE
 633 USE_PRECOMPILED_HEADER
 634 SJAVAC_SERVER_DIR
 635 ENABLE_SJAVAC
 636 SJAVAC_SERVER_JAVA
 637 JOBS
 638 MEMORY_SIZE
 639 NUM_CORES
 640 ENABLE_INTREE_EC
 641 SALIB_NAME
 642 HOTSPOT_MAKE_ARGS
 643 MSVCR_DLL
 644 LIBCXX
 645 LLVM_LIBS
 646 LLVM_LDFLAGS
 647 LLVM_CFLAGS
 648 LLVM_CONFIG
 649 LIBFFI_LIBS
 650 LIBFFI_CFLAGS
 651 STATIC_CXX_SETTING
 652 LIBDL
 653 LIBM
 654 LIBZIP_CAN_USE_MMAP
 655 USE_EXTERNAL_LIBZ
 656 USE_EXTERNAL_LIBGIF
 657 USE_EXTERNAL_LIBJPEG
 658 ALSA_LIBS
 659 ALSA_CFLAGS
 660 FREETYPE_BUNDLE_LIB_PATH
 661 FREETYPE_LIBS
 662 FREETYPE_CFLAGS
 663 CUPS_CFLAGS
 664 OPENWIN_HOME
 665 X_EXTRA_LIBS
 666 X_LIBS
 667 X_PRE_LIBS
 668 X_CFLAGS
 669 XMKMF
 670 FIXPATH
 671 ZIP_DEBUGINFO_FILES
 672 ENABLE_DEBUG_SYMBOLS
 673 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 674 ZERO_ARCHFLAG
 675 LDFLAGS_CXX_JDK
 676 LDFLAGS_JDKEXE_SUFFIX
 677 LDFLAGS_JDKLIB_SUFFIX
 678 LDFLAGS_JDKEXE
 679 LDFLAGS_JDKLIB
 680 CXXFLAGS_JDKEXE
 681 CXXFLAGS_JDKLIB
 682 CFLAGS_JDKEXE
 683 CFLAGS_JDKLIB
 684 MACOSX_VERSION_MIN
 685 LEGACY_EXTRA_LDFLAGS
 686 LEGACY_EXTRA_CXXFLAGS
 687 LEGACY_EXTRA_CFLAGS
 688 CXX_O_FLAG_NONE
 689 CXX_O_FLAG_NORM
 690 CXX_O_FLAG_HI
 691 CXX_O_FLAG_HIGHEST
 692 C_O_FLAG_NONE
 693 C_O_FLAG_NORM
 694 C_O_FLAG_HI
 695 C_O_FLAG_HIGHEST
 696 CXXFLAGS_DEBUG_SYMBOLS
 697 CFLAGS_DEBUG_SYMBOLS
 698 CXX_FLAG_DEPS
 699 C_FLAG_DEPS
 700 SET_SHARED_LIBRARY_MAPFILE
 701 SET_SHARED_LIBRARY_NAME
 702 SET_SHARED_LIBRARY_ORIGIN
 703 SET_EXECUTABLE_ORIGIN
 704 SHARED_LIBRARY_FLAGS
 705 CXX_FLAG_REORDER
 706 C_FLAG_REORDER
 707 RC_FLAGS
 708 AR_OUT_OPTION
 709 LD_OUT_OPTION
 710 EXE_OUT_OPTION
 711 CC_OUT_OPTION
 712 POST_MCS_CMD
 713 POST_STRIP_CMD
 714 ARFLAGS
 715 COMPILER_TARGET_BITS_FLAG
 716 JT_HOME
 717 JTREGEXE
 718 USING_BROKEN_SUSE_LD
 719 PACKAGE_PATH
 720 LDEXECXX
 721 LDEXE
 722 USE_CLANG
 723 HOTSPOT_LD
 724 HOTSPOT_CXX
 725 HOTSPOT_RC
 726 HOTSPOT_MT
 727 BUILD_LD
 728 BUILD_CXX
 729 BUILD_CC
 730 ac_ct_OBJDUMP
 731 OBJDUMP
 732 ac_ct_OBJCOPY
 733 OBJCOPY
 734 ac_ct_NM
 735 ac_ct_STRIP
 736 MCS
 737 GNM
 738 NM
 739 STRIP
 740 DUMPBIN
 741 RC
 742 MT
 743 LIPO
 744 ac_ct_OBJC
 745 OBJCFLAGS
 746 OBJC
 747 ac_ct_AR
 748 AR
 749 AS
 750 LDCXX
 751 LD
 752 CXXCPP
 753 CPP
 754 ac_ct_CXX
 755 CXXFLAGS
 756 CXX
 757 ac_ct_PROPER_COMPILER_CXX
 758 PROPER_COMPILER_CXX
 759 TOOLS_DIR_CXX
 760 POTENTIAL_CXX
 761 OBJEXT
 762 EXEEXT
 763 ac_ct_CC
 764 CPPFLAGS
 765 LDFLAGS
 766 CFLAGS
 767 CC
 768 ac_ct_PROPER_COMPILER_CC
 769 PROPER_COMPILER_CC
 770 TOOLS_DIR_CC
 771 POTENTIAL_CC
 772 VS_PATH
 773 VS_LIB
 774 VS_INCLUDE
 775 CYGWIN_LINK
 776 EXE_SUFFIX
 777 OBJ_SUFFIX
 778 STATIC_LIBRARY
 779 SHARED_LIBRARY
 780 STATIC_LIBRARY_SUFFIX
 781 SHARED_LIBRARY_SUFFIX
 782 LIBRARY_PREFIX
 783 TOOLCHAIN_TYPE
 784 BUILD_HOTSPOT
 785 HOTSPOT_DIST
 786 BUILD_OUTPUT
 787 OVERRIDE_SRC_ROOT
 788 ADD_SRC_ROOT
 789 JDK_TOPDIR
 790 NASHORN_TOPDIR
 791 HOTSPOT_TOPDIR
 792 JAXWS_TOPDIR
 793 JAXP_TOPDIR
 794 CORBA_TOPDIR
 795 LANGTOOLS_TOPDIR
 796 BOOT_JDK_JVMARGS
 797 JAVAC_FLAGS
 798 BOOT_JDK_SOURCETARGET
 799 JARSIGNER
 800 NATIVE2ASCII
 801 JAR
 802 JAVAH
 803 JAVAC
 804 JAVA
 805 BOOT_JDK
 806 BOOT_TOOLSJAR
 807 BOOT_RTJAR
 808 JAVA_CHECK
 809 JAVAC_CHECK
 810 COOKED_BUILD_NUMBER
 811 JDK_VERSION
 812 COPYRIGHT_YEAR
 813 MACOSX_BUNDLE_ID_BASE
 814 MACOSX_BUNDLE_NAME_BASE
 815 COMPANY_NAME
 816 JDK_RC_PLATFORM_NAME
 817 PRODUCT_SUFFIX
 818 PRODUCT_NAME
 819 LAUNCHER_NAME
 820 MILESTONE
 821 JDK_BUILD_NUMBER
 822 JDK_UPDATE_VERSION
 823 JDK_MICRO_VERSION
 824 JDK_MINOR_VERSION
 825 JDK_MAJOR_VERSION
 826 USER_RELEASE_SUFFIX
 827 COMPRESS_JARS
 828 RMICONNECTOR_IIOP
 829 UNLIMITED_CRYPTO
 830 CACERTS_FILE
 831 TEST_IN_BUILD
 832 BUILD_HEADLESS
 833 SUPPORT_HEADFUL
 834 SUPPORT_HEADLESS
 835 BDEPS_FTP
 836 BDEPS_UNZIP
 837 OS_VERSION_MICRO
 838 OS_VERSION_MINOR
 839 OS_VERSION_MAJOR
 840 PKG_CONFIG
 841 CODESIGN
 842 XATTR
 843 DSYMUTIL
 844 IS_GNU_TIME
 845 TIME
 846 STAT
 847 HG
 848 READELF
 849 OTOOL
 850 LDD
 851 ZIP
 852 UNZIP
 853 FIND_DELETE
 854 MAKE
 855 CHECK_TOOLSDIR_MAKE
 856 CHECK_TOOLSDIR_GMAKE
 857 CHECK_MAKE
 858 CHECK_GMAKE
 859 PKGHANDLER
 860 OUTPUT_ROOT
 861 CONF_NAME
 862 SPEC
 863 BUILD_VARIANT_RELEASE
 864 DEBUG_CLASSFILES
 865 FASTDEBUG
 866 VARIANT
 867 DEBUG_LEVEL
 868 MACOSX_UNIVERSAL
 869 INCLUDE_SA
 870 JVM_VARIANT_CORE
 871 JVM_VARIANT_ZEROSHARK
 872 JVM_VARIANT_ZERO
 873 JVM_VARIANT_KERNEL
 874 JVM_VARIANT_MINIMAL1
 875 JVM_VARIANT_CLIENT
 876 JVM_VARIANT_SERVER
 877 JVM_VARIANTS
 878 JVM_INTERPRETER
 879 JDK_VARIANT
 880 SET_OPENJDK
 881 BUILD_LOG_WRAPPER
 882 BUILD_LOG_PREVIOUS
 883 BUILD_LOG
 884 SYS_ROOT
 885 PATH_SEP
 886 TOPDIR
 887 ZERO_ARCHDEF
 888 DEFINE_CROSS_COMPILE_ARCH
 889 LP64
 890 OPENJDK_TARGET_OS_EXPORT_DIR
 891 OPENJDK_TARGET_OS_API_DIR
 892 OPENJDK_TARGET_CPU_JLI_CFLAGS
 893 OPENJDK_TARGET_CPU_OSARCH
 894 OPENJDK_TARGET_CPU_ISADIR
 895 OPENJDK_TARGET_CPU_LIBDIR
 896 OPENJDK_TARGET_CPU_LEGACY_LIB
 897 OPENJDK_TARGET_CPU_LEGACY
 898 REQUIRED_OS_VERSION
 899 REQUIRED_OS_NAME
 900 COMPILE_TYPE
 901 OPENJDK_TARGET_CPU_ENDIAN
 902 OPENJDK_TARGET_CPU_BITS
 903 OPENJDK_TARGET_CPU_ARCH
 904 OPENJDK_TARGET_CPU
 905 OPENJDK_TARGET_OS_API
 906 OPENJDK_TARGET_OS
 907 OPENJDK_BUILD_CPU_ENDIAN
 908 OPENJDK_BUILD_CPU_BITS
 909 OPENJDK_BUILD_CPU_ARCH
 910 OPENJDK_BUILD_CPU
 911 OPENJDK_BUILD_OS_API
 912 OPENJDK_BUILD_OS
 913 OPENJDK_BUILD_AUTOCONF_NAME
 914 OPENJDK_TARGET_AUTOCONF_NAME
 915 target_os
 916 target_vendor
 917 target_cpu
 918 target
 919 host_os
 920 host_vendor
 921 host_cpu
 922 host
 923 build_os
 924 build_vendor
 925 build_cpu
 926 build
 927 SETFILE
 928 DF
 929 READLINK
 930 CYGPATH
 931 SED
 932 FGREP
 933 EGREP
 934 GREP
 935 AWK
 936 XARGS
 937 WHICH
 938 WC
 939 UNIQ
 940 UNAME
 941 TR
 942 TOUCH
 943 TEE
 944 TAR
 945 TAIL
 946 SORT
 947 SH
 948 RM
 949 PRINTF
 950 NAWK
 951 MV
 952 MKTEMP
 953 MKDIR
 954 LS
 955 LN
 956 HEAD
 957 FIND
 958 FILE
 959 EXPR
 960 ECHO
 961 DIRNAME
 962 DIFF
 963 DATE
 964 CUT
 965 CPIO
 966 CP
 967 COMM
 968 CMP
 969 CHMOD
 970 CAT
 971 BASH
 972 BASENAME
 973 DATE_WHEN_CONFIGURED
 974 CONFIGURE_COMMAND_LINE
 975 target_alias
 976 host_alias
 977 build_alias
 978 LIBS
 979 ECHO_T
 980 ECHO_N
 981 ECHO_C
 982 DEFS
 983 mandir
 984 localedir
 985 libdir
 986 psdir
 987 pdfdir
 988 dvidir
 989 htmldir
 990 infodir
 991 docdir
 992 oldincludedir
 993 includedir
 994 localstatedir
 995 sharedstatedir
 996 sysconfdir
 997 datadir
 998 datarootdir
 999 libexecdir
1000 sbindir
1001 bindir
1002 program_transform_name
1003 prefix
1004 exec_prefix
1005 PACKAGE_URL
1006 PACKAGE_BUGREPORT
1007 PACKAGE_STRING
1008 PACKAGE_VERSION
1009 PACKAGE_TARNAME
1010 PACKAGE_NAME
1011 PATH_SEPARATOR
1012 SHELL'
1013 ac_subst_files=''
1014 ac_user_opts='
1015 enable_option_checking
1016 with_target_bits
1017 with_sys_root
1018 with_tools_dir
1019 with_devkit
1020 enable_openjdk_only
1021 with_custom_make_dir
1022 with_jdk_variant
1023 with_jvm_interpreter
1024 with_jvm_variants
1025 enable_debug
1026 with_debug_level
1027 with_conf_name
1028 with_builddeps_conf
1029 with_builddeps_server
1030 with_builddeps_dir
1031 with_builddeps_group
1032 enable_headful
1033 enable_hotspot_test_in_build
1034 with_cacerts_file
1035 enable_unlimited_crypto
1036 enable_rmiconnector_iiop
1037 with_milestone
1038 with_update_version
1039 with_user_release_suffix
1040 with_build_number
1041 with_boot_jdk
1042 with_boot_jdk_jvmargs
1043 with_add_source_root
1044 with_override_source_root
1045 with_adds_and_overrides
1046 with_override_langtools
1047 with_override_corba
1048 with_override_jaxp
1049 with_override_jaxws
1050 with_override_hotspot
1051 with_override_nashorn
1052 with_override_jdk
1053 with_import_hotspot
1054 with_toolchain_type
1055 with_jtreg
1056 with_extra_cflags
1057 with_extra_cxxflags
1058 with_extra_ldflags
1059 enable_debug_symbols
1060 enable_zip_debug_info
1061 enable_macosx_runtime_support
1062 with_x
1063 with_cups
1064 with_cups_include
1065 with_freetype
1066 with_freetype_include
1067 with_freetype_lib
1068 enable_freetype_bundling
1069 with_alsa
1070 with_alsa_include
1071 with_alsa_lib
1072 with_giflib
1073 with_zlib
1074 with_stdc__lib
1075 with_msvcr_dll
1076 with_dxsdk
1077 with_dxsdk_lib
1078 with_dxsdk_include
1079 with_num_cores
1080 with_memory_size
1081 with_jobs
1082 with_sjavac_server_java
1083 enable_sjavac
1084 enable_precompiled_headers
1085 enable_ccache
1086 with_ccache_dir
1087 '
1088       ac_precious_vars='build_alias
1089 host_alias
1090 target_alias
1091 BASENAME
1092 BASH
1093 CAT
1094 CHMOD
1095 CMP
1096 COMM
1097 CP
1098 CPIO
1099 CUT
1100 DATE
1101 DIFF
1102 DIRNAME
1103 ECHO
1104 EXPR
1105 FILE
1106 FIND
1107 HEAD
1108 LN
1109 LS
1110 MKDIR
1111 MKTEMP
1112 MV
1113 NAWK
1114 PRINTF
1115 RM
1116 SH
1117 SORT
1118 TAIL
1119 TAR
1120 TEE
1121 TOUCH
1122 TR
1123 UNAME
1124 UNIQ
1125 WC
1126 WHICH
1127 XARGS
1128 AWK
1129 GREP
1130 EGREP
1131 FGREP
1132 SED
1133 CYGPATH
1134 READLINK
1135 DF
1136 SETFILE
1137 UNZIP
1138 ZIP
1139 LDD
1140 OTOOL
1141 READELF
1142 HG
1143 STAT
1144 TIME
1145 DSYMUTIL
1146 XATTR
1147 CODESIGN
1148 PKG_CONFIG
1149 JAVA
1150 JAVAC
1151 JAVAH
1152 JAR
1153 NATIVE2ASCII
1154 JARSIGNER
1155 CC
1156 CFLAGS
1157 LDFLAGS
1158 LIBS
1159 CPPFLAGS
1160 CXX
1161 CXXFLAGS
1162 CCC
1163 CPP
1164 CXXCPP
1165 AS
1166 AR
1167 OBJC
1168 OBJCFLAGS
1169 LIPO
1170 STRIP
1171 NM
1172 GNM
1173 MCS
1174 OBJCOPY
1175 OBJDUMP
1176 BUILD_CC
1177 BUILD_CXX
1178 BUILD_LD
1179 JTREGEXE
1180 XMKMF
1181 FREETYPE_CFLAGS
1182 FREETYPE_LIBS
1183 ALSA_CFLAGS
1184 ALSA_LIBS
1185 LIBFFI_CFLAGS
1186 LIBFFI_LIBS
1187 CCACHE'
1188 
1189 
1190 # Initialize some variables set by options.
1191 ac_init_help=
1192 ac_init_version=false
1193 ac_unrecognized_opts=
1194 ac_unrecognized_sep=
1195 # The variables have the same names as the options, with
1196 # dashes changed to underlines.
1197 cache_file=/dev/null
1198 exec_prefix=NONE
1199 no_create=
1200 no_recursion=
1201 prefix=NONE
1202 program_prefix=NONE
1203 program_suffix=NONE
1204 program_transform_name=s,x,x,
1205 silent=
1206 site=
1207 srcdir=
1208 verbose=
1209 x_includes=NONE
1210 x_libraries=NONE
1211 
1212 # Installation directory options.
1213 # These are left unexpanded so users can "make install exec_prefix=/foo"
1214 # and all the variables that are supposed to be based on exec_prefix
1215 # by default will actually change.
1216 # Use braces instead of parens because sh, perl, etc. also accept them.
1217 # (The list follows the same order as the GNU Coding Standards.)
1218 bindir='${exec_prefix}/bin'
1219 sbindir='${exec_prefix}/sbin'
1220 libexecdir='${exec_prefix}/libexec'
1221 datarootdir='${prefix}/share'
1222 datadir='${datarootdir}'
1223 sysconfdir='${prefix}/etc'
1224 sharedstatedir='${prefix}/com'
1225 localstatedir='${prefix}/var'
1226 includedir='${prefix}/include'
1227 oldincludedir='/usr/include'
1228 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1229 infodir='${datarootdir}/info'
1230 htmldir='${docdir}'
1231 dvidir='${docdir}'
1232 pdfdir='${docdir}'
1233 psdir='${docdir}'
1234 libdir='${exec_prefix}/lib'
1235 localedir='${datarootdir}/locale'
1236 mandir='${datarootdir}/man'
1237 
1238 ac_prev=
1239 ac_dashdash=
1240 for ac_option
1241 do
1242   # If the previous option needs an argument, assign it.
1243   if test -n "$ac_prev"; then
1244     eval $ac_prev=\$ac_option
1245     ac_prev=
1246     continue
1247   fi
1248 
1249   case $ac_option in
1250   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1251   *=)   ac_optarg= ;;
1252   *)    ac_optarg=yes ;;
1253   esac
1254 
1255   # Accept the important Cygnus configure options, so we can diagnose typos.
1256 
1257   case $ac_dashdash$ac_option in
1258   --)
1259     ac_dashdash=yes ;;
1260 
1261   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1262     ac_prev=bindir ;;
1263   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1264     bindir=$ac_optarg ;;
1265 
1266   -build | --build | --buil | --bui | --bu)
1267     ac_prev=build_alias ;;
1268   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1269     build_alias=$ac_optarg ;;
1270 
1271   -cache-file | --cache-file | --cache-fil | --cache-fi \
1272   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1273     ac_prev=cache_file ;;
1274   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1275   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1276     cache_file=$ac_optarg ;;
1277 
1278   --config-cache | -C)
1279     cache_file=config.cache ;;
1280 
1281   -datadir | --datadir | --datadi | --datad)
1282     ac_prev=datadir ;;
1283   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1284     datadir=$ac_optarg ;;
1285 
1286   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1287   | --dataroo | --dataro | --datar)
1288     ac_prev=datarootdir ;;
1289   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1290   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1291     datarootdir=$ac_optarg ;;
1292 
1293   -disable-* | --disable-*)
1294     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1295     # Reject names that are not valid shell variable names.
1296     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1297       as_fn_error $? "invalid feature name: $ac_useropt"
1298     ac_useropt_orig=$ac_useropt
1299     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1300     case $ac_user_opts in
1301       *"
1302 "enable_$ac_useropt"
1303 "*) ;;
1304       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1305          ac_unrecognized_sep=', ';;
1306     esac
1307     eval enable_$ac_useropt=no ;;
1308 
1309   -docdir | --docdir | --docdi | --doc | --do)
1310     ac_prev=docdir ;;
1311   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1312     docdir=$ac_optarg ;;
1313 
1314   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1315     ac_prev=dvidir ;;
1316   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1317     dvidir=$ac_optarg ;;
1318 
1319   -enable-* | --enable-*)
1320     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1321     # Reject names that are not valid shell variable names.
1322     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1323       as_fn_error $? "invalid feature name: $ac_useropt"
1324     ac_useropt_orig=$ac_useropt
1325     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1326     case $ac_user_opts in
1327       *"
1328 "enable_$ac_useropt"
1329 "*) ;;
1330       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1331          ac_unrecognized_sep=', ';;
1332     esac
1333     eval enable_$ac_useropt=\$ac_optarg ;;
1334 
1335   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1336   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1337   | --exec | --exe | --ex)
1338     ac_prev=exec_prefix ;;
1339   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1340   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1341   | --exec=* | --exe=* | --ex=*)
1342     exec_prefix=$ac_optarg ;;
1343 
1344   -gas | --gas | --ga | --g)
1345     # Obsolete; use --with-gas.
1346     with_gas=yes ;;
1347 
1348   -help | --help | --hel | --he | -h)
1349     ac_init_help=long ;;
1350   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1351     ac_init_help=recursive ;;
1352   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1353     ac_init_help=short ;;
1354 
1355   -host | --host | --hos | --ho)
1356     ac_prev=host_alias ;;
1357   -host=* | --host=* | --hos=* | --ho=*)
1358     host_alias=$ac_optarg ;;
1359 
1360   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1361     ac_prev=htmldir ;;
1362   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1363   | --ht=*)
1364     htmldir=$ac_optarg ;;
1365 
1366   -includedir | --includedir | --includedi | --included | --include \
1367   | --includ | --inclu | --incl | --inc)
1368     ac_prev=includedir ;;
1369   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1370   | --includ=* | --inclu=* | --incl=* | --inc=*)
1371     includedir=$ac_optarg ;;
1372 
1373   -infodir | --infodir | --infodi | --infod | --info | --inf)
1374     ac_prev=infodir ;;
1375   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1376     infodir=$ac_optarg ;;
1377 
1378   -libdir | --libdir | --libdi | --libd)
1379     ac_prev=libdir ;;
1380   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1381     libdir=$ac_optarg ;;
1382 
1383   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1384   | --libexe | --libex | --libe)
1385     ac_prev=libexecdir ;;
1386   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1387   | --libexe=* | --libex=* | --libe=*)
1388     libexecdir=$ac_optarg ;;
1389 
1390   -localedir | --localedir | --localedi | --localed | --locale)
1391     ac_prev=localedir ;;
1392   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1393     localedir=$ac_optarg ;;
1394 
1395   -localstatedir | --localstatedir | --localstatedi | --localstated \
1396   | --localstate | --localstat | --localsta | --localst | --locals)
1397     ac_prev=localstatedir ;;
1398   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1399   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1400     localstatedir=$ac_optarg ;;
1401 
1402   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1403     ac_prev=mandir ;;
1404   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1405     mandir=$ac_optarg ;;
1406 
1407   -nfp | --nfp | --nf)
1408     # Obsolete; use --without-fp.
1409     with_fp=no ;;
1410 
1411   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1412   | --no-cr | --no-c | -n)
1413     no_create=yes ;;
1414 
1415   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1416   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1417     no_recursion=yes ;;
1418 
1419   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1420   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1421   | --oldin | --oldi | --old | --ol | --o)
1422     ac_prev=oldincludedir ;;
1423   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1424   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1425   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1426     oldincludedir=$ac_optarg ;;
1427 
1428   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1429     ac_prev=prefix ;;
1430   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1431     prefix=$ac_optarg ;;
1432 
1433   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1434   | --program-pre | --program-pr | --program-p)
1435     ac_prev=program_prefix ;;
1436   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1437   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1438     program_prefix=$ac_optarg ;;
1439 
1440   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1441   | --program-suf | --program-su | --program-s)
1442     ac_prev=program_suffix ;;
1443   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1444   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1445     program_suffix=$ac_optarg ;;
1446 
1447   -program-transform-name | --program-transform-name \
1448   | --program-transform-nam | --program-transform-na \
1449   | --program-transform-n | --program-transform- \
1450   | --program-transform | --program-transfor \
1451   | --program-transfo | --program-transf \
1452   | --program-trans | --program-tran \
1453   | --progr-tra | --program-tr | --program-t)
1454     ac_prev=program_transform_name ;;
1455   -program-transform-name=* | --program-transform-name=* \
1456   | --program-transform-nam=* | --program-transform-na=* \
1457   | --program-transform-n=* | --program-transform-=* \
1458   | --program-transform=* | --program-transfor=* \
1459   | --program-transfo=* | --program-transf=* \
1460   | --program-trans=* | --program-tran=* \
1461   | --progr-tra=* | --program-tr=* | --program-t=*)
1462     program_transform_name=$ac_optarg ;;
1463 
1464   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1465     ac_prev=pdfdir ;;
1466   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1467     pdfdir=$ac_optarg ;;
1468 
1469   -psdir | --psdir | --psdi | --psd | --ps)
1470     ac_prev=psdir ;;
1471   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1472     psdir=$ac_optarg ;;
1473 
1474   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1475   | -silent | --silent | --silen | --sile | --sil)
1476     silent=yes ;;
1477 
1478   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1479     ac_prev=sbindir ;;
1480   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1481   | --sbi=* | --sb=*)
1482     sbindir=$ac_optarg ;;
1483 
1484   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1485   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1486   | --sharedst | --shareds | --shared | --share | --shar \
1487   | --sha | --sh)
1488     ac_prev=sharedstatedir ;;
1489   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1490   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1491   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1492   | --sha=* | --sh=*)
1493     sharedstatedir=$ac_optarg ;;
1494 
1495   -site | --site | --sit)
1496     ac_prev=site ;;
1497   -site=* | --site=* | --sit=*)
1498     site=$ac_optarg ;;
1499 
1500   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1501     ac_prev=srcdir ;;
1502   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1503     srcdir=$ac_optarg ;;
1504 
1505   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1506   | --syscon | --sysco | --sysc | --sys | --sy)
1507     ac_prev=sysconfdir ;;
1508   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1509   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1510     sysconfdir=$ac_optarg ;;
1511 
1512   -target | --target | --targe | --targ | --tar | --ta | --t)
1513     ac_prev=target_alias ;;
1514   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1515     target_alias=$ac_optarg ;;
1516 
1517   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1518     verbose=yes ;;
1519 
1520   -version | --version | --versio | --versi | --vers | -V)
1521     ac_init_version=: ;;
1522 
1523   -with-* | --with-*)
1524     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1525     # Reject names that are not valid shell variable names.
1526     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1527       as_fn_error $? "invalid package name: $ac_useropt"
1528     ac_useropt_orig=$ac_useropt
1529     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1530     case $ac_user_opts in
1531       *"
1532 "with_$ac_useropt"
1533 "*) ;;
1534       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1535          ac_unrecognized_sep=', ';;
1536     esac
1537     eval with_$ac_useropt=\$ac_optarg ;;
1538 
1539   -without-* | --without-*)
1540     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1541     # Reject names that are not valid shell variable names.
1542     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1543       as_fn_error $? "invalid package name: $ac_useropt"
1544     ac_useropt_orig=$ac_useropt
1545     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1546     case $ac_user_opts in
1547       *"
1548 "with_$ac_useropt"
1549 "*) ;;
1550       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1551          ac_unrecognized_sep=', ';;
1552     esac
1553     eval with_$ac_useropt=no ;;
1554 
1555   --x)
1556     # Obsolete; use --with-x.
1557     with_x=yes ;;
1558 
1559   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1560   | --x-incl | --x-inc | --x-in | --x-i)
1561     ac_prev=x_includes ;;
1562   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1563   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1564     x_includes=$ac_optarg ;;
1565 
1566   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1567   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1568     ac_prev=x_libraries ;;
1569   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1570   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1571     x_libraries=$ac_optarg ;;
1572 
1573   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1574 Try \`$0 --help' for more information"
1575     ;;
1576 
1577   *=*)
1578     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1579     # Reject names that are not valid shell variable names.
1580     case $ac_envvar in #(
1581       '' | [0-9]* | *[!_$as_cr_alnum]* )
1582       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1583     esac
1584     eval $ac_envvar=\$ac_optarg
1585     export $ac_envvar ;;
1586 
1587   *)
1588     # FIXME: should be removed in autoconf 3.0.
1589     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1590     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1591       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1592     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1593     ;;
1594 
1595   esac
1596 done
1597 
1598 if test -n "$ac_prev"; then
1599   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1600   as_fn_error $? "missing argument to $ac_option"
1601 fi
1602 
1603 if test -n "$ac_unrecognized_opts"; then
1604   case $enable_option_checking in
1605     no) ;;
1606     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1607     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1608   esac
1609 fi
1610 
1611 # Check all directory arguments for consistency.
1612 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1613                 datadir sysconfdir sharedstatedir localstatedir includedir \
1614                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1615                 libdir localedir mandir
1616 do
1617   eval ac_val=\$$ac_var
1618   # Remove trailing slashes.
1619   case $ac_val in
1620     */ )
1621       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1622       eval $ac_var=\$ac_val;;
1623   esac
1624   # Be sure to have absolute directory names.
1625   case $ac_val in
1626     [\\/$]* | ?:[\\/]* )  continue;;
1627     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1628   esac
1629   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1630 done
1631 
1632 # There might be people who depend on the old broken behavior: `$host'
1633 # used to hold the argument of --host etc.
1634 # FIXME: To remove some day.
1635 build=$build_alias
1636 host=$host_alias
1637 target=$target_alias
1638 
1639 # FIXME: To remove some day.
1640 if test "x$host_alias" != x; then
1641   if test "x$build_alias" = x; then
1642     cross_compiling=maybe
1643   elif test "x$build_alias" != "x$host_alias"; then
1644     cross_compiling=yes
1645   fi
1646 fi
1647 
1648 ac_tool_prefix=
1649 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1650 
1651 test "$silent" = yes && exec 6>/dev/null
1652 
1653 
1654 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1655 ac_ls_di=`ls -di .` &&
1656 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1657   as_fn_error $? "working directory cannot be determined"
1658 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1659   as_fn_error $? "pwd does not report name of working directory"
1660 
1661 
1662 # Find the source files, if location was not specified.
1663 if test -z "$srcdir"; then
1664   ac_srcdir_defaulted=yes
1665   # Try the directory containing this script, then the parent directory.
1666   ac_confdir=`$as_dirname -- "$as_myself" ||
1667 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1668          X"$as_myself" : 'X\(//\)[^/]' \| \
1669          X"$as_myself" : 'X\(//\)$' \| \
1670          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1671 $as_echo X"$as_myself" |
1672     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1673             s//\1/
1674             q
1675           }
1676           /^X\(\/\/\)[^/].*/{
1677             s//\1/
1678             q
1679           }
1680           /^X\(\/\/\)$/{
1681             s//\1/
1682             q
1683           }
1684           /^X\(\/\).*/{
1685             s//\1/
1686             q
1687           }
1688           s/.*/./; q'`
1689   srcdir=$ac_confdir
1690   if test ! -r "$srcdir/$ac_unique_file"; then
1691     srcdir=..
1692   fi
1693 else
1694   ac_srcdir_defaulted=no
1695 fi
1696 if test ! -r "$srcdir/$ac_unique_file"; then
1697   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1698   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1699 fi
1700 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1701 ac_abs_confdir=`(
1702         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1703         pwd)`
1704 # When building in place, set srcdir=.
1705 if test "$ac_abs_confdir" = "$ac_pwd"; then
1706   srcdir=.
1707 fi
1708 # Remove unnecessary trailing slashes from srcdir.
1709 # Double slashes in file names in object file debugging info
1710 # mess up M-x gdb in Emacs.
1711 case $srcdir in
1712 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1713 esac
1714 for ac_var in $ac_precious_vars; do
1715   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1716   eval ac_env_${ac_var}_value=\$${ac_var}
1717   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1718   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1719 done
1720 
1721 #
1722 # Report the --help message.
1723 #
1724 if test "$ac_init_help" = "long"; then
1725   # Omit some internal or obsolete options to make the list less imposing.
1726   # This message is too long to be a string in the A/UX 3.1 sh.
1727   cat <<_ACEOF
1728 \`configure' configures OpenJDK jdk8 to adapt to many kinds of systems.
1729 
1730 Usage: $0 [OPTION]... [VAR=VALUE]...
1731 
1732 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1733 VAR=VALUE.  See below for descriptions of some of the useful variables.
1734 
1735 Defaults for the options are specified in brackets.
1736 
1737 Configuration:
1738   -h, --help              display this help and exit
1739       --help=short        display options specific to this package
1740       --help=recursive    display the short help of all the included packages
1741   -V, --version           display version information and exit
1742   -q, --quiet, --silent   do not print \`checking ...' messages
1743       --cache-file=FILE   cache test results in FILE [disabled]
1744   -C, --config-cache      alias for \`--cache-file=config.cache'
1745   -n, --no-create         do not create output files
1746       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1747 
1748 Installation directories:
1749   --prefix=PREFIX         install architecture-independent files in PREFIX
1750                           [$ac_default_prefix]
1751   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1752                           [PREFIX]
1753 
1754 By default, \`make install' will install all the files in
1755 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1756 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1757 for instance \`--prefix=\$HOME'.
1758 
1759 For better control, use the options below.
1760 
1761 Fine tuning of the installation directories:
1762   --bindir=DIR            user executables [EPREFIX/bin]
1763   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1764   --libexecdir=DIR        program executables [EPREFIX/libexec]
1765   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1766   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1767   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1768   --libdir=DIR            object code libraries [EPREFIX/lib]
1769   --includedir=DIR        C header files [PREFIX/include]
1770   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1771   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1772   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1773   --infodir=DIR           info documentation [DATAROOTDIR/info]
1774   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1775   --mandir=DIR            man documentation [DATAROOTDIR/man]
1776   --docdir=DIR            documentation root [DATAROOTDIR/doc/openjdk]
1777   --htmldir=DIR           html documentation [DOCDIR]
1778   --dvidir=DIR            dvi documentation [DOCDIR]
1779   --pdfdir=DIR            pdf documentation [DOCDIR]
1780   --psdir=DIR             ps documentation [DOCDIR]
1781 _ACEOF
1782 
1783   cat <<\_ACEOF
1784 
1785 X features:
1786   --x-includes=DIR    X include files are in DIR
1787   --x-libraries=DIR   X library files are in DIR
1788 
1789 System types:
1790   --build=BUILD     configure for building on BUILD [guessed]
1791   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1792   --target=TARGET   configure for building compilers for TARGET [HOST]
1793 _ACEOF
1794 fi
1795 
1796 if test -n "$ac_init_help"; then
1797   case $ac_init_help in
1798      short | recursive ) echo "Configuration of OpenJDK jdk8:";;
1799    esac
1800   cat <<\_ACEOF
1801 
1802 Optional Features:
1803   --disable-option-checking  ignore unrecognized --enable/--with options
1804   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1805   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1806   --enable-openjdk-only   suppress building custom source even if present
1807                           [disabled]
1808   --enable-debug          set the debug level to fastdebug (shorthand for
1809                           --with-debug-level=fastdebug) [disabled]
1810   --disable-headful       disable building headful support (graphical UI
1811                           support) [enabled]
1812   --enable-hotspot-test-in-build
1813                           run the Queens test after Hotspot build [disabled]
1814   --enable-unlimited-crypto
1815                           Enable unlimited crypto policy [disabled]
1816   --enable-rmiconnector-iiop
1817                           enable the JMX RMIConnector iiop transport
1818                           [disabled]
1819   --disable-debug-symbols disable generation of debug symbols [enabled]
1820   --disable-zip-debug-info
1821                           disable zipping of debug-info files [enabled]
1822   --enable-macosx-runtime-support
1823                           Deprecated. Option is kept for backwards
1824                           compatibility and is ignored
1825   --disable-freetype-bundling
1826                           disable bundling of the freetype library with the
1827                           build result [enabled on Windows or when using
1828                           --with-freetype, disabled otherwise]
1829   --enable-sjavac         use sjavac to do fast incremental compiles
1830                           [disabled]
1831   --disable-precompiled-headers
1832                           disable using precompiled headers when compiling C++
1833                           [enabled]
1834   --enable-ccache         enable using ccache to speed up recompilations
1835                           [disabled]
1836 
1837 Optional Packages:
1838   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1839   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1840   --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1841                           support it), e.g. --with-target-bits=32 [guessed]
1842   --with-sys-root         pass this sys-root to the compilers and tools (for
1843                           cross-compiling)
1844   --with-tools-dir        search this directory for compilers and tools (for
1845                           cross-compiling)
1846   --with-devkit           use this directory as base for tools-dir and
1847                           sys-root (for cross-compiling)
1848   --with-custom-make-dir  Deprecated. Option is kept for backwards
1849                           compatibility and is ignored
1850   --with-jdk-variant      JDK variant to build (normal) [normal]
1851   --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1852   --with-jvm-variants     JVM variants (separated by commas) to build (server,
1853                           client, minimal1, kernel, zero, zeroshark, core)
1854                           [server]
1855   --with-debug-level      set the debug level (release, fastdebug, slowdebug)
1856                           [release]
1857   --with-conf-name        use this as the name of the configuration [generated
1858                           from important configuration options]
1859   --with-builddeps-conf   use this configuration file for the builddeps
1860   --with-builddeps-server download and use build dependencies from this server
1861                           url
1862   --with-builddeps-dir    store downloaded build dependencies here
1863                           [/localhome/builddeps]
1864   --with-builddeps-group  chgrp the downloaded build dependencies to this
1865                           group
1866   --with-cacerts-file     specify alternative cacerts file
1867   --with-milestone        Set milestone value for build [internal]
1868   --with-update-version   Set update version value for build [b00]
1869   --with-user-release-suffix
1870                           Add a custom string to the version string if build
1871                           number is not set.[username_builddateb00]
1872   --with-build-number     Set build number value for build [b00]
1873   --with-boot-jdk         path to Boot JDK (used to bootstrap build) [probed]
1874   --with-boot-jdk-jvmargs specify JVM arguments to be passed to all
1875                           invocations of the Boot JDK, overriding the default
1876                           values, e.g --with-boot-jdk-jvmargs="-Xmx8G
1877                           -enableassertions"
1878   --with-add-source-root  for each and every source directory, look in this
1879                           additional source root for the same directory; if it
1880                           exists and have files in it, include it in the build
1881   --with-override-source-root
1882                           for each and every source directory, look in this
1883                           override source root for the same directory; if it
1884                           exists, use that directory instead and ignore the
1885                           directory in the original source root
1886   --with-adds-and-overrides
1887                           use the subdirs 'adds' and 'overrides' in the
1888                           specified directory as add-source-root and
1889                           override-source-root
1890   --with-override-langtools
1891                           use this langtools dir for the build
1892   --with-override-corba   use this corba dir for the build
1893   --with-override-jaxp    use this jaxp dir for the build
1894   --with-override-jaxws   use this jaxws dir for the build
1895   --with-override-hotspot use this hotspot dir for the build
1896   --with-override-nashorn use this nashorn dir for the build
1897   --with-override-jdk     use this jdk dir for the build
1898   --with-import-hotspot   import hotspot binaries from this jdk image or
1899                           hotspot build dist dir instead of building from
1900                           source
1901   --with-toolchain-type   the toolchain type (or family) to use, use '--help'
1902                           to show possible values [platform dependent]
1903   --with-jtreg            Regression Test Harness [probed]
1904   --with-extra-cflags     extra flags to be used when compiling jdk c-files
1905   --with-extra-cxxflags   extra flags to be used when compiling jdk c++-files
1906   --with-extra-ldflags    extra flags to be used when linking jdk
1907   --with-x                use the X Window System
1908   --with-cups             specify prefix directory for the cups package
1909                           (expecting the headers under PATH/include)
1910   --with-cups-include     specify directory for the cups include files
1911   --with-freetype         specify prefix directory for the freetype package
1912                           (expecting the libraries under PATH/lib and the
1913                           headers under PATH/include)
1914   --with-freetype-include specify directory for the freetype include files
1915   --with-freetype-lib     specify directory for the freetype library
1916   --with-alsa             specify prefix directory for the alsa package
1917                           (expecting the libraries under PATH/lib and the
1918                           headers under PATH/include)
1919   --with-alsa-include     specify directory for the alsa include files
1920   --with-alsa-lib         specify directory for the alsa library
1921   --with-giflib           use giflib from build system or OpenJDK source
1922                           (system, bundled) [bundled]
1923   --with-zlib             use zlib from build system or OpenJDK source
1924                           (system, bundled) [bundled]
1925   --with-stdc++lib=<static>,<dynamic>,<default>
1926                           force linking of the C++ runtime on Linux to either
1927                           static or dynamic, default is static with dynamic as
1928                           fallback
1929   --with-msvcr-dll        copy this msvcr100.dll into the built JDK (Windows
1930                           only) [probed]
1931   --with-dxsdk            Deprecated. Option is kept for backwards
1932                           compatibility and is ignored
1933   --with-dxsdk-lib        Deprecated. Option is kept for backwards
1934                           compatibility and is ignored
1935   --with-dxsdk-include    Deprecated. Option is kept for backwards
1936                           compatibility and is ignored
1937   --with-num-cores        number of cores in the build system, e.g.
1938                           --with-num-cores=8 [probed]
1939   --with-memory-size      memory (in MB) available in the build system, e.g.
1940                           --with-memory-size=1024 [probed]
1941   --with-jobs             number of parallel jobs to let make run [calculated
1942                           based on cores and memory]
1943   --with-sjavac-server-java
1944                           use this java binary for running the sjavac
1945                           background server [Boot JDK java]
1946   --with-ccache-dir       where to store ccache files [~/.ccache]
1947 
1948 Some influential environment variables:
1949   BASENAME    Override default value for BASENAME
1950   BASH        Override default value for BASH
1951   CAT         Override default value for CAT
1952   CHMOD       Override default value for CHMOD
1953   CMP         Override default value for CMP
1954   COMM        Override default value for COMM
1955   CP          Override default value for CP
1956   CPIO        Override default value for CPIO
1957   CUT         Override default value for CUT
1958   DATE        Override default value for DATE
1959   DIFF        Override default value for DIFF
1960   DIRNAME     Override default value for DIRNAME
1961   ECHO        Override default value for ECHO
1962   EXPR        Override default value for EXPR
1963   FILE        Override default value for FILE
1964   FIND        Override default value for FIND
1965   HEAD        Override default value for HEAD
1966   LN          Override default value for LN
1967   LS          Override default value for LS
1968   MKDIR       Override default value for MKDIR
1969   MKTEMP      Override default value for MKTEMP
1970   MV          Override default value for MV
1971   NAWK        Override default value for NAWK
1972   PRINTF      Override default value for PRINTF
1973   RM          Override default value for RM
1974   SH          Override default value for SH
1975   SORT        Override default value for SORT
1976   TAIL        Override default value for TAIL
1977   TAR         Override default value for TAR
1978   TEE         Override default value for TEE
1979   TOUCH       Override default value for TOUCH
1980   TR          Override default value for TR
1981   UNAME       Override default value for UNAME
1982   UNIQ        Override default value for UNIQ
1983   WC          Override default value for WC
1984   WHICH       Override default value for WHICH
1985   XARGS       Override default value for XARGS
1986   AWK         Override default value for AWK
1987   GREP        Override default value for GREP
1988   EGREP       Override default value for EGREP
1989   FGREP       Override default value for FGREP
1990   SED         Override default value for SED
1991   CYGPATH     Override default value for CYGPATH
1992   READLINK    Override default value for READLINK
1993   DF          Override default value for DF
1994   SETFILE     Override default value for SETFILE
1995   UNZIP       Override default value for UNZIP
1996   ZIP         Override default value for ZIP
1997   LDD         Override default value for LDD
1998   OTOOL       Override default value for OTOOL
1999   READELF     Override default value for READELF
2000   HG          Override default value for HG
2001   STAT        Override default value for STAT
2002   TIME        Override default value for TIME
2003   DSYMUTIL    Override default value for DSYMUTIL
2004   XATTR       Override default value for XATTR
2005   CODESIGN    Override default value for CODESIGN
2006   PKG_CONFIG  path to pkg-config utility
2007   JAVA        Override default value for JAVA
2008   JAVAC       Override default value for JAVAC
2009   JAVAH       Override default value for JAVAH
2010   JAR         Override default value for JAR
2011   NATIVE2ASCII
2012               Override default value for NATIVE2ASCII
2013   JARSIGNER   Override default value for JARSIGNER
2014   CC          C compiler command
2015   CFLAGS      C compiler flags
2016   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2017               nonstandard directory <lib dir>
2018   LIBS        libraries to pass to the linker, e.g. -l<library>
2019   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2020               you have headers in a nonstandard directory <include dir>
2021   CXX         C++ compiler command
2022   CXXFLAGS    C++ compiler flags
2023   CPP         C preprocessor
2024   CXXCPP      C++ preprocessor
2025   AS          Override default value for AS
2026   AR          Override default value for AR
2027   OBJC        Objective C compiler command
2028   OBJCFLAGS   Objective C compiler flags
2029   LIPO        Override default value for LIPO
2030   STRIP       Override default value for STRIP
2031   NM          Override default value for NM
2032   GNM         Override default value for GNM
2033   MCS         Override default value for MCS
2034   OBJCOPY     Override default value for OBJCOPY
2035   OBJDUMP     Override default value for OBJDUMP
2036   BUILD_CC    Override default value for BUILD_CC
2037   BUILD_CXX   Override default value for BUILD_CXX
2038   BUILD_LD    Override default value for BUILD_LD
2039   JTREGEXE    Override default value for JTREGEXE
2040   XMKMF       Path to xmkmf, Makefile generator for X Window System
2041   FREETYPE_CFLAGS
2042               C compiler flags for FREETYPE, overriding pkg-config
2043   FREETYPE_LIBS
2044               linker flags for FREETYPE, overriding pkg-config
2045   ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
2046   ALSA_LIBS   linker flags for ALSA, overriding pkg-config
2047   LIBFFI_CFLAGS
2048               C compiler flags for LIBFFI, overriding pkg-config
2049   LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config
2050   CCACHE      Override default value for CCACHE
2051 
2052 Use these variables to override the choices made by `configure' or to help
2053 it to find libraries and programs with nonstandard names/locations.
2054 
2055 Report bugs to <build-dev@openjdk.java.net>.
2056 OpenJDK home page: <http://openjdk.java.net>.
2057 _ACEOF
2058 ac_status=$?
2059 fi
2060 
2061 if test "$ac_init_help" = "recursive"; then
2062   # If there are subdirs, report their specific --help.
2063   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2064     test -d "$ac_dir" ||
2065       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2066       continue
2067     ac_builddir=.
2068 
2069 case "$ac_dir" in
2070 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2071 *)
2072   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2073   # A ".." for each directory in $ac_dir_suffix.
2074   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2075   case $ac_top_builddir_sub in
2076   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2077   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2078   esac ;;
2079 esac
2080 ac_abs_top_builddir=$ac_pwd
2081 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2082 # for backward compatibility:
2083 ac_top_builddir=$ac_top_build_prefix
2084 
2085 case $srcdir in
2086   .)  # We are building in place.
2087     ac_srcdir=.
2088     ac_top_srcdir=$ac_top_builddir_sub
2089     ac_abs_top_srcdir=$ac_pwd ;;
2090   [\\/]* | ?:[\\/]* )  # Absolute name.
2091     ac_srcdir=$srcdir$ac_dir_suffix;
2092     ac_top_srcdir=$srcdir
2093     ac_abs_top_srcdir=$srcdir ;;
2094   *) # Relative name.
2095     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2096     ac_top_srcdir=$ac_top_build_prefix$srcdir
2097     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2098 esac
2099 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2100 
2101     cd "$ac_dir" || { ac_status=$?; continue; }
2102     # Check for guested configure.
2103     if test -f "$ac_srcdir/configure.gnu"; then
2104       echo &&
2105       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2106     elif test -f "$ac_srcdir/configure"; then
2107       echo &&
2108       $SHELL "$ac_srcdir/configure" --help=recursive
2109     else
2110       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2111     fi || ac_status=$?
2112     cd "$ac_pwd" || { ac_status=$?; break; }
2113   done
2114 fi
2115 
2116 test -n "$ac_init_help" && exit $ac_status
2117 if $ac_init_version; then
2118   cat <<\_ACEOF
2119 OpenJDK configure jdk8
2120 generated by GNU Autoconf 2.69
2121 
2122 Copyright (C) 2012 Free Software Foundation, Inc.
2123 This configure script is free software; the Free Software Foundation
2124 gives unlimited permission to copy, distribute and modify it.
2125 _ACEOF
2126   exit
2127 fi
2128 
2129 ## ------------------------ ##
2130 ## Autoconf initialization. ##
2131 ## ------------------------ ##
2132 
2133 # ac_fn_c_try_compile LINENO
2134 # --------------------------
2135 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2136 ac_fn_c_try_compile ()
2137 {
2138   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2139   rm -f conftest.$ac_objext
2140   if { { ac_try="$ac_compile"
2141 case "(($ac_try" in
2142   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2143   *) ac_try_echo=$ac_try;;
2144 esac
2145 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2146 $as_echo "$ac_try_echo"; } >&5
2147   (eval "$ac_compile") 2>conftest.err
2148   ac_status=$?
2149   if test -s conftest.err; then
2150     grep -v '^ *+' conftest.err >conftest.er1
2151     cat conftest.er1 >&5
2152     mv -f conftest.er1 conftest.err
2153   fi
2154   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2155   test $ac_status = 0; } && {
2156          test -z "$ac_c_werror_flag" ||
2157          test ! -s conftest.err
2158        } && test -s conftest.$ac_objext; then :
2159   ac_retval=0
2160 else
2161   $as_echo "$as_me: failed program was:" >&5
2162 sed 's/^/| /' conftest.$ac_ext >&5
2163 
2164         ac_retval=1
2165 fi
2166   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2167   as_fn_set_status $ac_retval
2168 
2169 } # ac_fn_c_try_compile
2170 
2171 # ac_fn_cxx_try_compile LINENO
2172 # ----------------------------
2173 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2174 ac_fn_cxx_try_compile ()
2175 {
2176   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2177   rm -f conftest.$ac_objext
2178   if { { ac_try="$ac_compile"
2179 case "(($ac_try" in
2180   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2181   *) ac_try_echo=$ac_try;;
2182 esac
2183 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2184 $as_echo "$ac_try_echo"; } >&5
2185   (eval "$ac_compile") 2>conftest.err
2186   ac_status=$?
2187   if test -s conftest.err; then
2188     grep -v '^ *+' conftest.err >conftest.er1
2189     cat conftest.er1 >&5
2190     mv -f conftest.er1 conftest.err
2191   fi
2192   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2193   test $ac_status = 0; } && {
2194          test -z "$ac_cxx_werror_flag" ||
2195          test ! -s conftest.err
2196        } && test -s conftest.$ac_objext; then :
2197   ac_retval=0
2198 else
2199   $as_echo "$as_me: failed program was:" >&5
2200 sed 's/^/| /' conftest.$ac_ext >&5
2201 
2202         ac_retval=1
2203 fi
2204   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2205   as_fn_set_status $ac_retval
2206 
2207 } # ac_fn_cxx_try_compile
2208 
2209 # ac_fn_c_try_cpp LINENO
2210 # ----------------------
2211 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2212 ac_fn_c_try_cpp ()
2213 {
2214   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2215   if { { ac_try="$ac_cpp conftest.$ac_ext"
2216 case "(($ac_try" in
2217   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2218   *) ac_try_echo=$ac_try;;
2219 esac
2220 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2221 $as_echo "$ac_try_echo"; } >&5
2222   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2223   ac_status=$?
2224   if test -s conftest.err; then
2225     grep -v '^ *+' conftest.err >conftest.er1
2226     cat conftest.er1 >&5
2227     mv -f conftest.er1 conftest.err
2228   fi
2229   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2230   test $ac_status = 0; } > conftest.i && {
2231          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2232          test ! -s conftest.err
2233        }; then :
2234   ac_retval=0
2235 else
2236   $as_echo "$as_me: failed program was:" >&5
2237 sed 's/^/| /' conftest.$ac_ext >&5
2238 
2239     ac_retval=1
2240 fi
2241   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2242   as_fn_set_status $ac_retval
2243 
2244 } # ac_fn_c_try_cpp
2245 
2246 # ac_fn_cxx_try_cpp LINENO
2247 # ------------------------
2248 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2249 ac_fn_cxx_try_cpp ()
2250 {
2251   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2252   if { { ac_try="$ac_cpp conftest.$ac_ext"
2253 case "(($ac_try" in
2254   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2255   *) ac_try_echo=$ac_try;;
2256 esac
2257 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2258 $as_echo "$ac_try_echo"; } >&5
2259   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2260   ac_status=$?
2261   if test -s conftest.err; then
2262     grep -v '^ *+' conftest.err >conftest.er1
2263     cat conftest.er1 >&5
2264     mv -f conftest.er1 conftest.err
2265   fi
2266   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2267   test $ac_status = 0; } > conftest.i && {
2268          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2269          test ! -s conftest.err
2270        }; then :
2271   ac_retval=0
2272 else
2273   $as_echo "$as_me: failed program was:" >&5
2274 sed 's/^/| /' conftest.$ac_ext >&5
2275 
2276     ac_retval=1
2277 fi
2278   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2279   as_fn_set_status $ac_retval
2280 
2281 } # ac_fn_cxx_try_cpp
2282 
2283 # ac_fn_objc_try_compile LINENO
2284 # -----------------------------
2285 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2286 ac_fn_objc_try_compile ()
2287 {
2288   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2289   rm -f conftest.$ac_objext
2290   if { { ac_try="$ac_compile"
2291 case "(($ac_try" in
2292   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2293   *) ac_try_echo=$ac_try;;
2294 esac
2295 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2296 $as_echo "$ac_try_echo"; } >&5
2297   (eval "$ac_compile") 2>conftest.err
2298   ac_status=$?
2299   if test -s conftest.err; then
2300     grep -v '^ *+' conftest.err >conftest.er1
2301     cat conftest.er1 >&5
2302     mv -f conftest.er1 conftest.err
2303   fi
2304   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2305   test $ac_status = 0; } && {
2306          test -z "$ac_objc_werror_flag" ||
2307          test ! -s conftest.err
2308        } && test -s conftest.$ac_objext; then :
2309   ac_retval=0
2310 else
2311   $as_echo "$as_me: failed program was:" >&5
2312 sed 's/^/| /' conftest.$ac_ext >&5
2313 
2314         ac_retval=1
2315 fi
2316   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2317   as_fn_set_status $ac_retval
2318 
2319 } # ac_fn_objc_try_compile
2320 
2321 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
2322 # ---------------------------------------------------------
2323 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2324 # the include files in INCLUDES and setting the cache variable VAR
2325 # accordingly.
2326 ac_fn_cxx_check_header_mongrel ()
2327 {
2328   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2329   if eval \${$3+:} false; then :
2330   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2331 $as_echo_n "checking for $2... " >&6; }
2332 if eval \${$3+:} false; then :
2333   $as_echo_n "(cached) " >&6
2334 fi
2335 eval ac_res=\$$3
2336                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2337 $as_echo "$ac_res" >&6; }
2338 else
2339   # Is the header compilable?
2340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2341 $as_echo_n "checking $2 usability... " >&6; }
2342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2343 /* end confdefs.h.  */
2344 $4
2345 #include <$2>
2346 _ACEOF
2347 if ac_fn_cxx_try_compile "$LINENO"; then :
2348   ac_header_compiler=yes
2349 else
2350   ac_header_compiler=no
2351 fi
2352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2354 $as_echo "$ac_header_compiler" >&6; }
2355 
2356 # Is the header present?
2357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2358 $as_echo_n "checking $2 presence... " >&6; }
2359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2360 /* end confdefs.h.  */
2361 #include <$2>
2362 _ACEOF
2363 if ac_fn_cxx_try_cpp "$LINENO"; then :
2364   ac_header_preproc=yes
2365 else
2366   ac_header_preproc=no
2367 fi
2368 rm -f conftest.err conftest.i conftest.$ac_ext
2369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2370 $as_echo "$ac_header_preproc" >&6; }
2371 
2372 # So?  What about this header?
2373 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
2374   yes:no: )
2375     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2376 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2377     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2378 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2379     ;;
2380   no:yes:* )
2381     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2382 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2383     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2384 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2385     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2386 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2387     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2388 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2389     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2390 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2391 ( $as_echo "## ----------------------------------------- ##
2392 ## Report this to build-dev@openjdk.java.net ##
2393 ## ----------------------------------------- ##"
2394      ) | sed "s/^/$as_me: WARNING:     /" >&2
2395     ;;
2396 esac
2397   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2398 $as_echo_n "checking for $2... " >&6; }
2399 if eval \${$3+:} false; then :
2400   $as_echo_n "(cached) " >&6
2401 else
2402   eval "$3=\$ac_header_compiler"
2403 fi
2404 eval ac_res=\$$3
2405                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2406 $as_echo "$ac_res" >&6; }
2407 fi
2408   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2409 
2410 } # ac_fn_cxx_check_header_mongrel
2411 
2412 # ac_fn_cxx_try_run LINENO
2413 # ------------------------
2414 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2415 # that executables *can* be run.
2416 ac_fn_cxx_try_run ()
2417 {
2418   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2419   if { { ac_try="$ac_link"
2420 case "(($ac_try" in
2421   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2422   *) ac_try_echo=$ac_try;;
2423 esac
2424 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2425 $as_echo "$ac_try_echo"; } >&5
2426   (eval "$ac_link") 2>&5
2427   ac_status=$?
2428   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2429   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2430   { { case "(($ac_try" in
2431   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2432   *) ac_try_echo=$ac_try;;
2433 esac
2434 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2435 $as_echo "$ac_try_echo"; } >&5
2436   (eval "$ac_try") 2>&5
2437   ac_status=$?
2438   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2439   test $ac_status = 0; }; }; then :
2440   ac_retval=0
2441 else
2442   $as_echo "$as_me: program exited with status $ac_status" >&5
2443        $as_echo "$as_me: failed program was:" >&5
2444 sed 's/^/| /' conftest.$ac_ext >&5
2445 
2446        ac_retval=$ac_status
2447 fi
2448   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2449   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2450   as_fn_set_status $ac_retval
2451 
2452 } # ac_fn_cxx_try_run
2453 
2454 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
2455 # ---------------------------------------------------------
2456 # Tests whether HEADER exists and can be compiled using the include files in
2457 # INCLUDES, setting the cache variable VAR accordingly.
2458 ac_fn_cxx_check_header_compile ()
2459 {
2460   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2461   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2462 $as_echo_n "checking for $2... " >&6; }
2463 if eval \${$3+:} false; then :
2464   $as_echo_n "(cached) " >&6
2465 else
2466   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2467 /* end confdefs.h.  */
2468 $4
2469 #include <$2>
2470 _ACEOF
2471 if ac_fn_cxx_try_compile "$LINENO"; then :
2472   eval "$3=yes"
2473 else
2474   eval "$3=no"
2475 fi
2476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2477 fi
2478 eval ac_res=\$$3
2479                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2480 $as_echo "$ac_res" >&6; }
2481   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2482 
2483 } # ac_fn_cxx_check_header_compile
2484 
2485 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES
2486 # ----------------------------------------------
2487 # Tries to find the compile-time value of EXPR in a program that includes
2488 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2489 # computed
2490 ac_fn_cxx_compute_int ()
2491 {
2492   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2493   if test "$cross_compiling" = yes; then
2494     # Depending upon the size, compute the lo and hi bounds.
2495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2496 /* end confdefs.h.  */
2497 $4
2498 int
2499 main ()
2500 {
2501 static int test_array [1 - 2 * !(($2) >= 0)];
2502 test_array [0] = 0;
2503 return test_array [0];
2504 
2505   ;
2506   return 0;
2507 }
2508 _ACEOF
2509 if ac_fn_cxx_try_compile "$LINENO"; then :
2510   ac_lo=0 ac_mid=0
2511   while :; do
2512     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2513 /* end confdefs.h.  */
2514 $4
2515 int
2516 main ()
2517 {
2518 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2519 test_array [0] = 0;
2520 return test_array [0];
2521 
2522   ;
2523   return 0;
2524 }
2525 _ACEOF
2526 if ac_fn_cxx_try_compile "$LINENO"; then :
2527   ac_hi=$ac_mid; break
2528 else
2529   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2530                         if test $ac_lo -le $ac_mid; then
2531                           ac_lo= ac_hi=
2532                           break
2533                         fi
2534                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2535 fi
2536 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2537   done
2538 else
2539   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2540 /* end confdefs.h.  */
2541 $4
2542 int
2543 main ()
2544 {
2545 static int test_array [1 - 2 * !(($2) < 0)];
2546 test_array [0] = 0;
2547 return test_array [0];
2548 
2549   ;
2550   return 0;
2551 }
2552 _ACEOF
2553 if ac_fn_cxx_try_compile "$LINENO"; then :
2554   ac_hi=-1 ac_mid=-1
2555   while :; do
2556     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2557 /* end confdefs.h.  */
2558 $4
2559 int
2560 main ()
2561 {
2562 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2563 test_array [0] = 0;
2564 return test_array [0];
2565 
2566   ;
2567   return 0;
2568 }
2569 _ACEOF
2570 if ac_fn_cxx_try_compile "$LINENO"; then :
2571   ac_lo=$ac_mid; break
2572 else
2573   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2574                         if test $ac_mid -le $ac_hi; then
2575                           ac_lo= ac_hi=
2576                           break
2577                         fi
2578                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2579 fi
2580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2581   done
2582 else
2583   ac_lo= ac_hi=
2584 fi
2585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2586 fi
2587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2588 # Binary search between lo and hi bounds.
2589 while test "x$ac_lo" != "x$ac_hi"; do
2590   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
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) <= $ac_mid)];
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_hi=$ac_mid
2607 else
2608   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2609 fi
2610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2611 done
2612 case $ac_lo in #((
2613 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2614 '') ac_retval=1 ;;
2615 esac
2616   else
2617     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2618 /* end confdefs.h.  */
2619 $4
2620 static long int longval () { return $2; }
2621 static unsigned long int ulongval () { return $2; }
2622 #include <stdio.h>
2623 #include <stdlib.h>
2624 int
2625 main ()
2626 {
2627 
2628   FILE *f = fopen ("conftest.val", "w");
2629   if (! f)
2630     return 1;
2631   if (($2) < 0)
2632     {
2633       long int i = longval ();
2634       if (i != ($2))
2635         return 1;
2636       fprintf (f, "%ld", i);
2637     }
2638   else
2639     {
2640       unsigned long int i = ulongval ();
2641       if (i != ($2))
2642         return 1;
2643       fprintf (f, "%lu", i);
2644     }
2645   /* Do not output a trailing newline, as this causes \r\n confusion
2646      on some platforms.  */
2647   return ferror (f) || fclose (f) != 0;
2648 
2649   ;
2650   return 0;
2651 }
2652 _ACEOF
2653 if ac_fn_cxx_try_run "$LINENO"; then :
2654   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2655 else
2656   ac_retval=1
2657 fi
2658 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2659   conftest.$ac_objext conftest.beam conftest.$ac_ext
2660 rm -f conftest.val
2661 
2662   fi
2663   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2664   as_fn_set_status $ac_retval
2665 
2666 } # ac_fn_cxx_compute_int
2667 
2668 # ac_fn_cxx_try_link LINENO
2669 # -------------------------
2670 # Try to link conftest.$ac_ext, and return whether this succeeded.
2671 ac_fn_cxx_try_link ()
2672 {
2673   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2674   rm -f conftest.$ac_objext conftest$ac_exeext
2675   if { { ac_try="$ac_link"
2676 case "(($ac_try" in
2677   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2678   *) ac_try_echo=$ac_try;;
2679 esac
2680 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2681 $as_echo "$ac_try_echo"; } >&5
2682   (eval "$ac_link") 2>conftest.err
2683   ac_status=$?
2684   if test -s conftest.err; then
2685     grep -v '^ *+' conftest.err >conftest.er1
2686     cat conftest.er1 >&5
2687     mv -f conftest.er1 conftest.err
2688   fi
2689   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2690   test $ac_status = 0; } && {
2691          test -z "$ac_cxx_werror_flag" ||
2692          test ! -s conftest.err
2693        } && test -s conftest$ac_exeext && {
2694          test "$cross_compiling" = yes ||
2695          test -x conftest$ac_exeext
2696        }; then :
2697   ac_retval=0
2698 else
2699   $as_echo "$as_me: failed program was:" >&5
2700 sed 's/^/| /' conftest.$ac_ext >&5
2701 
2702         ac_retval=1
2703 fi
2704   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2705   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2706   # interfere with the next link command; also delete a directory that is
2707   # left behind by Apple's compiler.  We do this before executing the actions.
2708   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2709   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2710   as_fn_set_status $ac_retval
2711 
2712 } # ac_fn_cxx_try_link
2713 
2714 # ac_fn_cxx_check_func LINENO FUNC VAR
2715 # ------------------------------------
2716 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2717 ac_fn_cxx_check_func ()
2718 {
2719   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2720   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2721 $as_echo_n "checking for $2... " >&6; }
2722 if eval \${$3+:} false; then :
2723   $as_echo_n "(cached) " >&6
2724 else
2725   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2726 /* end confdefs.h.  */
2727 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2728    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2729 #define $2 innocuous_$2
2730 
2731 /* System header to define __stub macros and hopefully few prototypes,
2732     which can conflict with char $2 (); below.
2733     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2734     <limits.h> exists even on freestanding compilers.  */
2735 
2736 #ifdef __STDC__
2737 # include <limits.h>
2738 #else
2739 # include <assert.h>
2740 #endif
2741 
2742 #undef $2
2743 
2744 /* Override any GCC internal prototype to avoid an error.
2745    Use char because int might match the return type of a GCC
2746    builtin and then its argument prototype would still apply.  */
2747 #ifdef __cplusplus
2748 extern "C"
2749 #endif
2750 char $2 ();
2751 /* The GNU C library defines this for functions which it implements
2752     to always fail with ENOSYS.  Some functions are actually named
2753     something starting with __ and the normal name is an alias.  */
2754 #if defined __stub_$2 || defined __stub___$2
2755 choke me
2756 #endif
2757 
2758 int
2759 main ()
2760 {
2761 return $2 ();
2762   ;
2763   return 0;
2764 }
2765 _ACEOF
2766 if ac_fn_cxx_try_link "$LINENO"; then :
2767   eval "$3=yes"
2768 else
2769   eval "$3=no"
2770 fi
2771 rm -f core conftest.err conftest.$ac_objext \
2772     conftest$ac_exeext conftest.$ac_ext
2773 fi
2774 eval ac_res=\$$3
2775                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2776 $as_echo "$ac_res" >&6; }
2777   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2778 
2779 } # ac_fn_cxx_check_func
2780 
2781 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2782 # -------------------------------------------------------
2783 # Tests whether HEADER exists and can be compiled using the include files in
2784 # INCLUDES, setting the cache variable VAR accordingly.
2785 ac_fn_c_check_header_compile ()
2786 {
2787   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2788   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2789 $as_echo_n "checking for $2... " >&6; }
2790 if eval \${$3+:} false; then :
2791   $as_echo_n "(cached) " >&6
2792 else
2793   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2794 /* end confdefs.h.  */
2795 $4
2796 #include <$2>
2797 _ACEOF
2798 if ac_fn_c_try_compile "$LINENO"; then :
2799   eval "$3=yes"
2800 else
2801   eval "$3=no"
2802 fi
2803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2804 fi
2805 eval ac_res=\$$3
2806                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2807 $as_echo "$ac_res" >&6; }
2808   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2809 
2810 } # ac_fn_c_check_header_compile
2811 cat >config.log <<_ACEOF
2812 This file contains any messages produced by compilers while
2813 running configure, to aid debugging if configure makes a mistake.
2814 
2815 It was created by OpenJDK $as_me jdk8, which was
2816 generated by GNU Autoconf 2.69.  Invocation command line was
2817 
2818   $ $0 $@
2819 
2820 _ACEOF
2821 exec 5>>config.log
2822 {
2823 cat <<_ASUNAME
2824 ## --------- ##
2825 ## Platform. ##
2826 ## --------- ##
2827 
2828 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2829 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2830 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2831 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2832 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2833 
2834 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2835 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2836 
2837 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2838 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2839 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2840 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2841 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2842 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2843 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2844 
2845 _ASUNAME
2846 
2847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2848 for as_dir in $PATH
2849 do
2850   IFS=$as_save_IFS
2851   test -z "$as_dir" && as_dir=.
2852     $as_echo "PATH: $as_dir"
2853   done
2854 IFS=$as_save_IFS
2855 
2856 } >&5
2857 
2858 cat >&5 <<_ACEOF
2859 
2860 
2861 ## ----------- ##
2862 ## Core tests. ##
2863 ## ----------- ##
2864 
2865 _ACEOF
2866 
2867 
2868 # Keep a trace of the command line.
2869 # Strip out --no-create and --no-recursion so they do not pile up.
2870 # Strip out --silent because we don't want to record it for future runs.
2871 # Also quote any args containing shell meta-characters.
2872 # Make two passes to allow for proper duplicate-argument suppression.
2873 ac_configure_args=
2874 ac_configure_args0=
2875 ac_configure_args1=
2876 ac_must_keep_next=false
2877 for ac_pass in 1 2
2878 do
2879   for ac_arg
2880   do
2881     case $ac_arg in
2882     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2883     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2884     | -silent | --silent | --silen | --sile | --sil)
2885       continue ;;
2886     *\'*)
2887       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2888     esac
2889     case $ac_pass in
2890     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2891     2)
2892       as_fn_append ac_configure_args1 " '$ac_arg'"
2893       if test $ac_must_keep_next = true; then
2894         ac_must_keep_next=false # Got value, back to normal.
2895       else
2896         case $ac_arg in
2897           *=* | --config-cache | -C | -disable-* | --disable-* \
2898           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2899           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2900           | -with-* | --with-* | -without-* | --without-* | --x)
2901             case "$ac_configure_args0 " in
2902               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2903             esac
2904             ;;
2905           -* ) ac_must_keep_next=true ;;
2906         esac
2907       fi
2908       as_fn_append ac_configure_args " '$ac_arg'"
2909       ;;
2910     esac
2911   done
2912 done
2913 { ac_configure_args0=; unset ac_configure_args0;}
2914 { ac_configure_args1=; unset ac_configure_args1;}
2915 
2916 # When interrupted or exit'd, cleanup temporary files, and complete
2917 # config.log.  We remove comments because anyway the quotes in there
2918 # would cause problems or look ugly.
2919 # WARNING: Use '\'' to represent an apostrophe within the trap.
2920 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2921 trap 'exit_status=$?
2922   # Save into config.log some information that might help in debugging.
2923   {
2924     echo
2925 
2926     $as_echo "## ---------------- ##
2927 ## Cache variables. ##
2928 ## ---------------- ##"
2929     echo
2930     # The following way of writing the cache mishandles newlines in values,
2931 (
2932   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2933     eval ac_val=\$$ac_var
2934     case $ac_val in #(
2935     *${as_nl}*)
2936       case $ac_var in #(
2937       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2938 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2939       esac
2940       case $ac_var in #(
2941       _ | IFS | as_nl) ;; #(
2942       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2943       *) { eval $ac_var=; unset $ac_var;} ;;
2944       esac ;;
2945     esac
2946   done
2947   (set) 2>&1 |
2948     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2949     *${as_nl}ac_space=\ *)
2950       sed -n \
2951         "s/'\''/'\''\\\\'\'''\''/g;
2952           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2953       ;; #(
2954     *)
2955       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2956       ;;
2957     esac |
2958     sort
2959 )
2960     echo
2961 
2962     $as_echo "## ----------------- ##
2963 ## Output variables. ##
2964 ## ----------------- ##"
2965     echo
2966     for ac_var in $ac_subst_vars
2967     do
2968       eval ac_val=\$$ac_var
2969       case $ac_val in
2970       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2971       esac
2972       $as_echo "$ac_var='\''$ac_val'\''"
2973     done | sort
2974     echo
2975 
2976     if test -n "$ac_subst_files"; then
2977       $as_echo "## ------------------- ##
2978 ## File substitutions. ##
2979 ## ------------------- ##"
2980       echo
2981       for ac_var in $ac_subst_files
2982       do
2983         eval ac_val=\$$ac_var
2984         case $ac_val in
2985         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2986         esac
2987         $as_echo "$ac_var='\''$ac_val'\''"
2988       done | sort
2989       echo
2990     fi
2991 
2992     if test -s confdefs.h; then
2993       $as_echo "## ----------- ##
2994 ## confdefs.h. ##
2995 ## ----------- ##"
2996       echo
2997       cat confdefs.h
2998       echo
2999     fi
3000     test "$ac_signal" != 0 &&
3001       $as_echo "$as_me: caught signal $ac_signal"
3002     $as_echo "$as_me: exit $exit_status"
3003   } >&5
3004   rm -f core *.core core.conftest.* &&
3005     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3006     exit $exit_status
3007 ' 0
3008 for ac_signal in 1 2 13 15; do
3009   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3010 done
3011 ac_signal=0
3012 
3013 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3014 rm -f -r conftest* confdefs.h
3015 
3016 $as_echo "/* confdefs.h */" > confdefs.h
3017 
3018 # Predefined preprocessor variables.
3019 
3020 cat >>confdefs.h <<_ACEOF
3021 #define PACKAGE_NAME "$PACKAGE_NAME"
3022 _ACEOF
3023 
3024 cat >>confdefs.h <<_ACEOF
3025 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3026 _ACEOF
3027 
3028 cat >>confdefs.h <<_ACEOF
3029 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3030 _ACEOF
3031 
3032 cat >>confdefs.h <<_ACEOF
3033 #define PACKAGE_STRING "$PACKAGE_STRING"
3034 _ACEOF
3035 
3036 cat >>confdefs.h <<_ACEOF
3037 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3038 _ACEOF
3039 
3040 cat >>confdefs.h <<_ACEOF
3041 #define PACKAGE_URL "$PACKAGE_URL"
3042 _ACEOF
3043 
3044 
3045 # Let the site file select an alternate cache file if it wants to.
3046 # Prefer an explicitly selected file to automatically selected ones.
3047 ac_site_file1=NONE
3048 ac_site_file2=NONE
3049 if test -n "$CONFIG_SITE"; then
3050   # We do not want a PATH search for config.site.
3051   case $CONFIG_SITE in #((
3052     -*)  ac_site_file1=./$CONFIG_SITE;;
3053     */*) ac_site_file1=$CONFIG_SITE;;
3054     *)   ac_site_file1=./$CONFIG_SITE;;
3055   esac
3056 elif test "x$prefix" != xNONE; then
3057   ac_site_file1=$prefix/share/config.site
3058   ac_site_file2=$prefix/etc/config.site
3059 else
3060   ac_site_file1=$ac_default_prefix/share/config.site
3061   ac_site_file2=$ac_default_prefix/etc/config.site
3062 fi
3063 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3064 do
3065   test "x$ac_site_file" = xNONE && continue
3066   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3067     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3068 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3069     sed 's/^/| /' "$ac_site_file" >&5
3070     . "$ac_site_file" \
3071       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3072 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3073 as_fn_error $? "failed to load site script $ac_site_file
3074 See \`config.log' for more details" "$LINENO" 5; }
3075   fi
3076 done
3077 
3078 if test -r "$cache_file"; then
3079   # Some versions of bash will fail to source /dev/null (special files
3080   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3081   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3082     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3083 $as_echo "$as_me: loading cache $cache_file" >&6;}
3084     case $cache_file in
3085       [\\/]* | ?:[\\/]* ) . "$cache_file";;
3086       *)                      . "./$cache_file";;
3087     esac
3088   fi
3089 else
3090   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3091 $as_echo "$as_me: creating cache $cache_file" >&6;}
3092   >$cache_file
3093 fi
3094 
3095 # Check that the precious variables saved in the cache have kept the same
3096 # value.
3097 ac_cache_corrupted=false
3098 for ac_var in $ac_precious_vars; do
3099   eval ac_old_set=\$ac_cv_env_${ac_var}_set
3100   eval ac_new_set=\$ac_env_${ac_var}_set
3101   eval ac_old_val=\$ac_cv_env_${ac_var}_value
3102   eval ac_new_val=\$ac_env_${ac_var}_value
3103   case $ac_old_set,$ac_new_set in
3104     set,)
3105       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3106 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3107       ac_cache_corrupted=: ;;
3108     ,set)
3109       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3110 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3111       ac_cache_corrupted=: ;;
3112     ,);;
3113     *)
3114       if test "x$ac_old_val" != "x$ac_new_val"; then
3115         # differences in whitespace do not lead to failure.
3116         ac_old_val_w=`echo x $ac_old_val`
3117         ac_new_val_w=`echo x $ac_new_val`
3118         if test "$ac_old_val_w" != "$ac_new_val_w"; then
3119           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3120 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3121           ac_cache_corrupted=:
3122         else
3123           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3124 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3125           eval $ac_var=\$ac_old_val
3126         fi
3127         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
3128 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
3129         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
3130 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
3131       fi;;
3132   esac
3133   # Pass precious variables to config.status.
3134   if test "$ac_new_set" = set; then
3135     case $ac_new_val in
3136     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3137     *) ac_arg=$ac_var=$ac_new_val ;;
3138     esac
3139     case " $ac_configure_args " in
3140       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
3141       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3142     esac
3143   fi
3144 done
3145 if $ac_cache_corrupted; then
3146   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3147 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3148   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3149 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3150   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3151 fi
3152 ## -------------------- ##
3153 ## Main body of script. ##
3154 ## -------------------- ##
3155 
3156 ac_ext=c
3157 ac_cpp='$CPP $CPPFLAGS'
3158 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3159 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3160 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3161 
3162 
3163 
3164 ac_aux_dir=
3165 for ac_dir in common/autoconf/build-aux "$srcdir"/common/autoconf/build-aux; do
3166   if test -f "$ac_dir/install-sh"; then
3167     ac_aux_dir=$ac_dir
3168     ac_install_sh="$ac_aux_dir/install-sh -c"
3169     break
3170   elif test -f "$ac_dir/install.sh"; then
3171     ac_aux_dir=$ac_dir
3172     ac_install_sh="$ac_aux_dir/install.sh -c"
3173     break
3174   elif test -f "$ac_dir/shtool"; then
3175     ac_aux_dir=$ac_dir
3176     ac_install_sh="$ac_aux_dir/shtool install -c"
3177     break
3178   fi
3179 done
3180 if test -z "$ac_aux_dir"; then
3181   as_fn_error $? "cannot find install-sh, install.sh, or shtool in common/autoconf/build-aux \"$srcdir\"/common/autoconf/build-aux" "$LINENO" 5
3182 fi
3183 
3184 # These three variables are undocumented and unsupported,
3185 # and are intended to be withdrawn in a future Autoconf release.
3186 # They can cause serious problems if a builder's source tree is in a directory
3187 # whose full name contains unusual characters.
3188 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3189 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3190 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3191 
3192 
3193 # pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
3194 
3195 #
3196 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
3197 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3198 #
3199 # This code is free software; you can redistribute it and/or modify it
3200 # under the terms of the GNU General Public License version 2 only, as
3201 # published by the Free Software Foundation.  Oracle designates this
3202 # particular file as subject to the "Classpath" exception as provided
3203 # by Oracle in the LICENSE file that accompanied this code.
3204 #
3205 # This code is distributed in the hope that it will be useful, but WITHOUT
3206 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3207 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3208 # version 2 for more details (a copy is included in the LICENSE file that
3209 # accompanied this code).
3210 #
3211 # You should have received a copy of the GNU General Public License version
3212 # 2 along with this work; if not, write to the Free Software Foundation,
3213 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3214 #
3215 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3216 # or visit www.oracle.com if you need additional information or have any
3217 # questions.
3218 #
3219 
3220 #
3221 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
3222 #
3223 # This program is free software; you can redistribute it and/or modify
3224 # it under the terms of the GNU General Public License as published by
3225 # the Free Software Foundation; either version 2 of the License, or
3226 # (at your option) any later version.
3227 #
3228 # This program is distributed in the hope that it will be useful, but
3229 # WITHOUT ANY WARRANTY; without even the implied warranty of
3230 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
3231 # General Public License for more details.
3232 #
3233 # You should have received a copy of the GNU General Public License
3234 # along with this program; if not, write to the Free Software
3235 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
3236 #
3237 # As a special exception to the GNU General Public License, if you
3238 # distribute this file as part of a program that contains a
3239 # configuration script generated by Autoconf, you may include it under
3240 # the same distribution terms that you use for the rest of that program.
3241 
3242 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
3243 # ----------------------------------
3244 # PKG_PROG_PKG_CONFIG
3245 
3246 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
3247 #
3248 # Check to see whether a particular set of modules exists.  Similar
3249 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
3250 #
3251 #
3252 # Similar to PKG_CHECK_MODULES, make sure that the first instance of
3253 # this or PKG_CHECK_MODULES is called, or make sure to call
3254 # PKG_CHECK_EXISTS manually
3255 # --------------------------------------------------------------
3256 
3257 
3258 
3259 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
3260 # ---------------------------------------------
3261 # _PKG_CONFIG
3262 
3263 # _PKG_SHORT_ERRORS_SUPPORTED
3264 # -----------------------------
3265 # _PKG_SHORT_ERRORS_SUPPORTED
3266 
3267 
3268 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
3269 # [ACTION-IF-NOT-FOUND])
3270 #
3271 #
3272 # Note that if there is a possibility the first call to
3273 # PKG_CHECK_MODULES might not happen, you should be sure to include an
3274 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
3275 #
3276 #
3277 # --------------------------------------------------------------
3278 # PKG_CHECK_MODULES
3279 
3280 
3281 # Include these first...
3282 #
3283 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3284 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3285 #
3286 # This code is free software; you can redistribute it and/or modify it
3287 # under the terms of the GNU General Public License version 2 only, as
3288 # published by the Free Software Foundation.  Oracle designates this
3289 # particular file as subject to the "Classpath" exception as provided
3290 # by Oracle in the LICENSE file that accompanied this code.
3291 #
3292 # This code is distributed in the hope that it will be useful, but WITHOUT
3293 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3294 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3295 # version 2 for more details (a copy is included in the LICENSE file that
3296 # accompanied this code).
3297 #
3298 # You should have received a copy of the GNU General Public License version
3299 # 2 along with this work; if not, write to the Free Software Foundation,
3300 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3301 #
3302 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3303 # or visit www.oracle.com if you need additional information or have any
3304 # questions.
3305 #
3306 
3307 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3308 # If so, then append $1 to $2 \
3309 # Also set JVM_ARG_OK to true/false depending on outcome.
3310 
3311 
3312 # Appends a string to a path variable, only adding the : when needed.
3313 
3314 
3315 # This will make sure the given variable points to a full and proper
3316 # path. This means:
3317 # 1) There will be no spaces in the path. On posix platforms,
3318 #    spaces in the path will result in an error. On Windows,
3319 #    the path will be rewritten using short-style to be space-free.
3320 # 2) The path will be absolute, and it will be in unix-style (on
3321 #     cygwin).
3322 # $1: The name of the variable to fix
3323 
3324 
3325 # This will make sure the given variable points to a executable
3326 # with a full and proper path. This means:
3327 # 1) There will be no spaces in the path. On posix platforms,
3328 #    spaces in the path will result in an error. On Windows,
3329 #    the path will be rewritten using short-style to be space-free.
3330 # 2) The path will be absolute, and it will be in unix-style (on
3331 #     cygwin).
3332 # Any arguments given to the executable is preserved.
3333 # If the input variable does not have a directory specification, then
3334 # it need to be in the PATH.
3335 # $1: The name of the variable to fix
3336 
3337 
3338 
3339 
3340 # Register a --with argument but mark it as deprecated
3341 # $1: The name of the with argument to deprecate, not including --with-
3342 
3343 
3344 # Register a --enable argument but mark it as deprecated
3345 # $1: The name of the with argument to deprecate, not including --enable-
3346 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -)
3347 
3348 
3349 
3350 
3351 # Test that variable $1 denoting a program is not empty. If empty, exit with an error.
3352 # $1: variable to check
3353 
3354 
3355 # Check that there are no unprocessed overridden variables left.
3356 # If so, they are an incorrect argument and we will exit with an error.
3357 
3358 
3359 # Setup a tool for the given variable. If correctly specified by the user,
3360 # use that value, otherwise search for the tool using the supplied code snippet.
3361 # $1: variable to set
3362 # $2: code snippet to call to look for the tool
3363 
3364 
3365 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool
3366 # $1: variable to set
3367 # $2: executable name (or list of names) to look for
3368 
3369 
3370 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool
3371 # $1: variable to set
3372 # $2: executable name (or list of names) to look for
3373 
3374 
3375 # Like BASIC_PATH_PROGS but fails if no tool was found.
3376 # $1: variable to set
3377 # $2: executable name (or list of names) to look for
3378 
3379 
3380 # Like BASIC_SETUP_TOOL but fails if no tool was found.
3381 # $1: variable to set
3382 # $2: autoconf macro to call to look for the special tool
3383 
3384 
3385 # Setup the most fundamental tools that relies on not much else to set up,
3386 # but is used by much of the early bootstrap code.
3387 
3388 
3389 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3390 
3391 
3392 
3393 
3394 
3395 
3396 
3397 #%%% Simple tools %%%
3398 
3399 # Check if we have found a usable version of make
3400 # $1: the path to a potential make binary (or empty)
3401 # $2: the description on how we found this
3402 
3403 
3404 # Goes looking for a usable version of GNU make.
3405 
3406 
3407 
3408 
3409 
3410 
3411 # Check if build directory is on local disk. If not possible to determine,
3412 # we prefer to claim it's local.
3413 # Argument 1: directory to test
3414 # Argument 2: what to do if it is on local disk
3415 # Argument 3: what to do otherwise (remote disk or failure)
3416 
3417 
3418 # Check that source files have basic read permissions set. This might
3419 # not be the case in cygwin in certain conditions.
3420 
3421 
3422 
3423 
3424 #
3425 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3426 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3427 #
3428 # This code is free software; you can redistribute it and/or modify it
3429 # under the terms of the GNU General Public License version 2 only, as
3430 # published by the Free Software Foundation.  Oracle designates this
3431 # particular file as subject to the "Classpath" exception as provided
3432 # by Oracle in the LICENSE file that accompanied this code.
3433 #
3434 # This code is distributed in the hope that it will be useful, but WITHOUT
3435 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3436 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3437 # version 2 for more details (a copy is included in the LICENSE file that
3438 # accompanied this code).
3439 #
3440 # You should have received a copy of the GNU General Public License version
3441 # 2 along with this work; if not, write to the Free Software Foundation,
3442 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3443 #
3444 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3445 # or visit www.oracle.com if you need additional information or have any
3446 # questions.
3447 #
3448 
3449 
3450 
3451 
3452 
3453 # Helper function which possibly converts a path using DOS-style short mode.
3454 # If so, the updated path is stored in $new_path.
3455 # $1: The path to check
3456 
3457 
3458 # Helper function which possibly converts a path using DOS-style short mode.
3459 # If so, the updated path is stored in $new_path.
3460 # $1: The path to check
3461 
3462 
3463 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted
3464 # and could probably be heavily simplified. However, all changes in this
3465 # area tend to need lot of testing in different scenarios, and in lack of
3466 # proper unit testing, cleaning this up has not been deemed worth the effort
3467 # at the moment.
3468 
3469 
3470 
3471 
3472 
3473 
3474 
3475 
3476 
3477 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3478 
3479 
3480 
3481 
3482 #
3483 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3484 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3485 #
3486 # This code is free software; you can redistribute it and/or modify it
3487 # under the terms of the GNU General Public License version 2 only, as
3488 # published by the Free Software Foundation.  Oracle designates this
3489 # particular file as subject to the "Classpath" exception as provided
3490 # by Oracle in the LICENSE file that accompanied this code.
3491 #
3492 # This code is distributed in the hope that it will be useful, but WITHOUT
3493 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3494 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3495 # version 2 for more details (a copy is included in the LICENSE file that
3496 # accompanied this code).
3497 #
3498 # You should have received a copy of the GNU General Public License version
3499 # 2 along with this work; if not, write to the Free Software Foundation,
3500 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3501 #
3502 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3503 # or visit www.oracle.com if you need additional information or have any
3504 # questions.
3505 #
3506 
3507 
3508 
3509 
3510 
3511 
3512 
3513 
3514 
3515 
3516 
3517 # ... then the rest
3518 #
3519 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3520 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3521 #
3522 # This code is free software; you can redistribute it and/or modify it
3523 # under the terms of the GNU General Public License version 2 only, as
3524 # published by the Free Software Foundation.  Oracle designates this
3525 # particular file as subject to the "Classpath" exception as provided
3526 # by Oracle in the LICENSE file that accompanied this code.
3527 #
3528 # This code is distributed in the hope that it will be useful, but WITHOUT
3529 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3530 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3531 # version 2 for more details (a copy is included in the LICENSE file that
3532 # accompanied this code).
3533 #
3534 # You should have received a copy of the GNU General Public License version
3535 # 2 along with this work; if not, write to the Free Software Foundation,
3536 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3537 #
3538 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3539 # or visit www.oracle.com if you need additional information or have any
3540 # questions.
3541 #
3542 
3543 ########################################################################
3544 # This file handles detection of the Boot JDK. The Boot JDK detection
3545 # process has been developed as a response to solve a complex real-world
3546 # problem. Initially, it was simple, but it has grown as platform after
3547 # platform, idiosyncracy after idiosyncracy has been supported.
3548 #
3549 # The basic idea is this:
3550 # 1) You need an acceptable *) JDK to use as a Boot JDK
3551 # 2) There are several ways to locate a JDK, that are mostly platform
3552 #    dependent **)
3553 # 3) You can have multiple JDKs installed
3554 # 4) If possible, configure should try to dig out an acceptable JDK
3555 #    automatically, without having to resort to command-line options
3556 #
3557 # *)  acceptable means e.g. JDK7 for building JDK8, a complete JDK (with
3558 #     javac) and not a JRE, etc.
3559 #
3560 # **) On Windows we typically use a well-known path.
3561 #     On MacOSX we typically use the tool java_home.
3562 #     On Linux we typically find javac in the $PATH, and then follow a
3563 #     chain of symlinks that often ends up in a real JDK.
3564 #
3565 # This leads to the code where we check in different ways to locate a
3566 # JDK, and if one is found, check if it is acceptable. If not, we print
3567 # our reasons for rejecting it (useful when debugging non-working
3568 # configure situations) and continue checking the next one.
3569 ########################################################################
3570 
3571 # Execute the check given as argument, and verify the result
3572 # If the Boot JDK was previously found, do nothing
3573 # $1 A command line (typically autoconf macro) to execute
3574 
3575 
3576 # Test: Is bootjdk explicitely set by command line arguments?
3577 
3578 
3579 # Test: Is bootjdk available from builddeps?
3580 
3581 
3582 # Test: Is $JAVA_HOME set?
3583 
3584 
3585 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
3586 
3587 
3588 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX)
3589 # $1: Argument to the java_home binary (optional)
3590 
3591 
3592 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
3593 
3594 
3595 # Look for a jdk in the given path. If there are multiple, try to select the newest.
3596 # If found, set BOOT_JDK and BOOT_JDK_FOUND.
3597 # $1 = Path to directory containing jdk installations.
3598 # $2 = String to append to the found JDK directory to get the proper JDK home
3599 
3600 
3601 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given
3602 # environmental variable as base for where to look.
3603 # $1 Name of an environmal variable, assumed to point to the Program Files directory.
3604 
3605 
3606 # Test: Is there a JDK installed in default, well-known locations?
3607 
3608 
3609 # Check that a command-line tool in the Boot JDK is correct
3610 # $1 = name of variable to assign
3611 # $2 = name of binary
3612 
3613 
3614 ###############################################################################
3615 #
3616 # We need a Boot JDK to bootstrap the build.
3617 #
3618 
3619 
3620 
3621 
3622 
3623 #
3624 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3625 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3626 #
3627 # This code is free software; you can redistribute it and/or modify it
3628 # under the terms of the GNU General Public License version 2 only, as
3629 # published by the Free Software Foundation.  Oracle designates this
3630 # particular file as subject to the "Classpath" exception as provided
3631 # by Oracle in the LICENSE file that accompanied this code.
3632 #
3633 # This code is distributed in the hope that it will be useful, but WITHOUT
3634 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3635 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3636 # version 2 for more details (a copy is included in the LICENSE file that
3637 # accompanied this code).
3638 #
3639 # You should have received a copy of the GNU General Public License version
3640 # 2 along with this work; if not, write to the Free Software Foundation,
3641 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3642 #
3643 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3644 # or visit www.oracle.com if you need additional information or have any
3645 # questions.
3646 #
3647 
3648 
3649 
3650 
3651 
3652 
3653 
3654 
3655 
3656 
3657 
3658 
3659 
3660 
3661 
3662 
3663 
3664 
3665 
3666 
3667 #
3668 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3669 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3670 #
3671 # This code is free software; you can redistribute it and/or modify it
3672 # under the terms of the GNU General Public License version 2 only, as
3673 # published by the Free Software Foundation.  Oracle designates this
3674 # particular file as subject to the "Classpath" exception as provided
3675 # by Oracle in the LICENSE file that accompanied this code.
3676 #
3677 # This code is distributed in the hope that it will be useful, but WITHOUT
3678 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3679 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3680 # version 2 for more details (a copy is included in the LICENSE file that
3681 # accompanied this code).
3682 #
3683 # You should have received a copy of the GNU General Public License version
3684 # 2 along with this work; if not, write to the Free Software Foundation,
3685 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3686 #
3687 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3688 # or visit www.oracle.com if you need additional information or have any
3689 # questions.
3690 #
3691 
3692 
3693 
3694 
3695 
3696 # Documentation on common flags used for solstudio in HIGHEST.
3697 #
3698 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
3699 #          done with care, there are some assumptions below that need to
3700 #          be understood about the use of pointers, and IEEE behavior.
3701 #
3702 # -fns: Use non-standard floating point mode (not IEEE 754)
3703 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754)
3704 # -fsingle: Use single precision floating point with 'float'
3705 # -xalias_level=basic: Assume memory references via basic pointer types do not alias
3706 #   (Source with excessing pointer casting and data access with mixed
3707 #    pointer types are not recommended)
3708 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions
3709 #   (If you expect perfect errno behavior, do not use this)
3710 # -xdepend: Loop data dependency optimizations (need -xO3 or higher)
3711 # -xrestrict: Pointer parameters to functions do not overlap
3712 #   (Similar to -xalias_level=basic usage, but less obvious sometimes.
3713 #    If you pass in multiple pointers to the same data, do not use this)
3714 # -xlibmil: Inline some library routines
3715 #   (If you expect perfect errno behavior, do not use this)
3716 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED)
3717 #   (If you expect perfect errno behavior, do not use this)
3718 #  Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
3719 
3720     # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore.
3721     # Bug?
3722     #if test "x$OPENJDK_TARGET_CPU" = xsparc; then
3723     #  CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s"
3724     #  CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s"
3725     #fi
3726 
3727 
3728 
3729 
3730 
3731 
3732 # FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
3733 #                                   [RUN-IF-FALSE])
3734 # ------------------------------------------------------------
3735 # Check that the c and c++ compilers support an argument
3736 
3737 
3738 
3739 
3740 #
3741 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3742 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3743 #
3744 # This code is free software; you can redistribute it and/or modify it
3745 # under the terms of the GNU General Public License version 2 only, as
3746 # published by the Free Software Foundation.  Oracle designates this
3747 # particular file as subject to the "Classpath" exception as provided
3748 # by Oracle in the LICENSE file that accompanied this code.
3749 #
3750 # This code is distributed in the hope that it will be useful, but WITHOUT
3751 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3752 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3753 # version 2 for more details (a copy is included in the LICENSE file that
3754 # accompanied this code).
3755 #
3756 # You should have received a copy of the GNU General Public License version
3757 # 2 along with this work; if not, write to the Free Software Foundation,
3758 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3759 #
3760 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3761 # or visit www.oracle.com if you need additional information or have any
3762 # questions.
3763 #
3764 
3765 
3766 
3767 
3768 
3769 cygwin_help() {
3770   case $1 in
3771     unzip)
3772       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )"
3773       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3774       ;;
3775     zip)
3776       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )"
3777       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3778       ;;
3779     make)
3780       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )"
3781       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3782       ;;
3783     freetype)
3784       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
3785         HELP_MSG="To install freetype, run:
3786 wget \"http://gnuwin32.sourceforge.net/downlinks/freetype.php\" -O /tmp/freetype-setup.exe
3787 chmod +x /tmp/freetype-setup.exe
3788 /tmp/freetype-setup.exe
3789 Follow GUI prompts, and install to default directory \"C:\Program Files (x86)\GnuWin32\".
3790 After installation, locate lib/libfreetype.dll.a and make a copy with the name freetype.dll."
3791       else
3792         HELP_MSG="You need to build a 64-bit version of freetype.
3793 This is not readily available.
3794 You can find source code and build instructions on
3795 http://www.freetype.org/
3796 If you put the resulting build in \"C:\Program Files\GnuWin32\", it will be found automatically."
3797       fi
3798       ;;
3799   esac
3800 }
3801 
3802 msys_help() {
3803   PKGHANDLER_COMMAND=""
3804 }
3805 
3806 apt_help() {
3807   case $1 in
3808     devkit)
3809       PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;;
3810     openjdk)
3811       PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;;
3812     alsa)
3813       PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;;
3814     cups)
3815       PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;;
3816     freetype)
3817       PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;;
3818     pulse)
3819       PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;;
3820     x11)
3821       PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
3822     ccache)
3823       PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
3824   esac
3825 }
3826 
3827 yum_help() {
3828   case $1 in
3829     devkit)
3830       PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;;
3831     openjdk)
3832       PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;;
3833     alsa)
3834       PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;;
3835     cups)
3836       PKGHANDLER_COMMAND="sudo yum install cups-devel" ;;
3837     freetype)
3838       PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;;
3839     pulse)
3840       PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;;
3841     x11)
3842       PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
3843     ccache)
3844       PKGHANDLER_COMMAND="sudo yum install ccache" ;;
3845   esac
3846 }
3847 
3848 port_help() {
3849   PKGHANDLER_COMMAND=""
3850 }
3851 
3852 pkgutil_help() {
3853   PKGHANDLER_COMMAND=""
3854 }
3855 
3856 pkgadd_help() {
3857   PKGHANDLER_COMMAND=""
3858 }
3859 
3860 # This function will check if we're called from the "configure" wrapper while
3861 # printing --help. If so, we will print out additional information that can
3862 # only be extracted within the autoconf script, and then exit. This must be
3863 # called at the very beginning in configure.ac.
3864 
3865 
3866 
3867 
3868 #
3869 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3870 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3871 #
3872 # This code is free software; you can redistribute it and/or modify it
3873 # under the terms of the GNU General Public License version 2 only, as
3874 # published by the Free Software Foundation.  Oracle designates this
3875 # particular file as subject to the "Classpath" exception as provided
3876 # by Oracle in the LICENSE file that accompanied this code.
3877 #
3878 # This code is distributed in the hope that it will be useful, but WITHOUT
3879 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3880 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3881 # version 2 for more details (a copy is included in the LICENSE file that
3882 # accompanied this code).
3883 #
3884 # You should have received a copy of the GNU General Public License version
3885 # 2 along with this work; if not, write to the Free Software Foundation,
3886 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3887 #
3888 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3889 # or visit www.oracle.com if you need additional information or have any
3890 # questions.
3891 #
3892 
3893 
3894 
3895 
3896 
3897 
3898 
3899 
3900 
3901 
3902 ###############################################################################
3903 #
3904 # Should we build only OpenJDK even if closed sources are present?
3905 #
3906 
3907 
3908 
3909 
3910 ###############################################################################
3911 #
3912 # Setup version numbers
3913 #
3914 
3915 
3916 
3917 
3918 
3919 
3920 #
3921 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3922 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3923 #
3924 # This code is free software; you can redistribute it and/or modify it
3925 # under the terms of the GNU General Public License version 2 only, as
3926 # published by the Free Software Foundation.  Oracle designates this
3927 # particular file as subject to the "Classpath" exception as provided
3928 # by Oracle in the LICENSE file that accompanied this code.
3929 #
3930 # This code is distributed in the hope that it will be useful, but WITHOUT
3931 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3932 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3933 # version 2 for more details (a copy is included in the LICENSE file that
3934 # accompanied this code).
3935 #
3936 # You should have received a copy of the GNU General Public License version
3937 # 2 along with this work; if not, write to the Free Software Foundation,
3938 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3939 #
3940 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3941 # or visit www.oracle.com if you need additional information or have any
3942 # questions.
3943 #
3944 
3945 
3946 
3947 
3948 
3949 
3950 
3951 
3952 
3953 
3954 
3955 
3956 
3957 
3958 
3959 
3960 
3961 
3962 
3963 #
3964 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3965 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3966 #
3967 # This code is free software; you can redistribute it and/or modify it
3968 # under the terms of the GNU General Public License version 2 only, as
3969 # published by the Free Software Foundation.  Oracle designates this
3970 # particular file as subject to the "Classpath" exception as provided
3971 # by Oracle in the LICENSE file that accompanied this code.
3972 #
3973 # This code is distributed in the hope that it will be useful, but WITHOUT
3974 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3975 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3976 # version 2 for more details (a copy is included in the LICENSE file that
3977 # accompanied this code).
3978 #
3979 # You should have received a copy of the GNU General Public License version
3980 # 2 along with this work; if not, write to the Free Software Foundation,
3981 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3982 #
3983 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3984 # or visit www.oracle.com if you need additional information or have any
3985 # questions.
3986 #
3987 
3988 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3989 # Converts autoconf style CPU name to OpenJDK style, into
3990 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN.
3991 
3992 
3993 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3994 # Converts autoconf style OS name to OpenJDK style, into
3995 # VAR_OS and VAR_OS_API.
3996 
3997 
3998 # Expects $host_os $host_cpu $build_os and $build_cpu
3999 # and $with_target_bits to have been setup!
4000 #
4001 # Translate the standard triplet(quadruplet) definition
4002 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU,
4003 # OPENJDK_BUILD_OS, etc.
4004 
4005 
4006 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour
4007 # accordingly. Must be done after setting up build and target system, but before
4008 # doing anything else with these values.
4009 
4010 
4011 # Setup the legacy variables, for controlling the old makefiles.
4012 #
4013 
4014 
4015 
4016 
4017 #%%% Build and target systems %%%
4018 
4019 
4020 
4021 
4022 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS.
4023 # Add -mX to various FLAGS variables.
4024 
4025 
4026 
4027 
4028 
4029 
4030 #
4031 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4032 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4033 #
4034 # This code is free software; you can redistribute it and/or modify it
4035 # under the terms of the GNU General Public License version 2 only, as
4036 # published by the Free Software Foundation.  Oracle designates this
4037 # particular file as subject to the "Classpath" exception as provided
4038 # by Oracle in the LICENSE file that accompanied this code.
4039 #
4040 # This code is distributed in the hope that it will be useful, but WITHOUT
4041 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4042 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4043 # version 2 for more details (a copy is included in the LICENSE file that
4044 # accompanied this code).
4045 #
4046 # You should have received a copy of the GNU General Public License version
4047 # 2 along with this work; if not, write to the Free Software Foundation,
4048 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4049 #
4050 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4051 # or visit www.oracle.com if you need additional information or have any
4052 # questions.
4053 #
4054 
4055 
4056 
4057 
4058 
4059 
4060 
4061 
4062 #
4063 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
4064 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4065 #
4066 # This code is free software; you can redistribute it and/or modify it
4067 # under the terms of the GNU General Public License version 2 only, as
4068 # published by the Free Software Foundation.  Oracle designates this
4069 # particular file as subject to the "Classpath" exception as provided
4070 # by Oracle in the LICENSE file that accompanied this code.
4071 #
4072 # This code is distributed in the hope that it will be useful, but WITHOUT
4073 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4074 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4075 # version 2 for more details (a copy is included in the LICENSE file that
4076 # accompanied this code).
4077 #
4078 # You should have received a copy of the GNU General Public License version
4079 # 2 along with this work; if not, write to the Free Software Foundation,
4080 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4081 #
4082 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4083 # or visit www.oracle.com if you need additional information or have any
4084 # questions.
4085 #
4086 
4087 ########################################################################
4088 # This file is responsible for detecting, verifying and setting up the
4089 # toolchain, i.e. the compiler, linker and related utilities. It will setup
4090 # proper paths to the binaries, but it will not setup any flags.
4091 #
4092 # The binaries used is determined by the toolchain type, which is the family of
4093 # compilers and related tools that are used.
4094 ########################################################################
4095 
4096 
4097 # All valid toolchains, regardless of platform (used by help.m4)
4098 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft"
4099 
4100 # These toolchains are valid on different platforms
4101 VALID_TOOLCHAINS_linux="gcc clang"
4102 VALID_TOOLCHAINS_solaris="solstudio"
4103 VALID_TOOLCHAINS_macosx="gcc clang"
4104 VALID_TOOLCHAINS_aix="xlc"
4105 VALID_TOOLCHAINS_windows="microsoft"
4106 
4107 # Toolchain descriptions
4108 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM"
4109 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection"
4110 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio"
4111 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio"
4112 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
4113 
4114 # Setup a number of variables describing how native output files are
4115 # named on this platform/toolchain.
4116 
4117 
4118 # Determine which toolchain type to use, and make sure it is valid for this
4119 # platform. Setup various information about the selected toolchain.
4120 
4121 
4122 # Before we start detecting the toolchain executables, we might need some
4123 # special setup, e.g. additional paths etc.
4124 
4125 
4126 # Restore path, etc
4127 
4128 
4129 # Check if a compiler is of the toolchain type we expect, and save the version
4130 # information from it. If the compiler does not match the expected type,
4131 # this function will abort using AC_MSG_ERROR. If it matches, the version will
4132 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and
4133 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING.
4134 #
4135 # $1 = compiler to test (CC or CXX)
4136 # $2 = human readable name of compiler (C or C++)
4137 
4138 
4139 # Try to locate the given C or C++ compiler in the path, or otherwise.
4140 #
4141 # $1 = compiler to test (CC or CXX)
4142 # $2 = human readable name of compiler (C or C++)
4143 # $3 = list of compiler names to search for
4144 
4145 
4146 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX),
4147 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the
4148 # archiver (AR). Verify that the compilers are correct according to the
4149 # toolchain type.
4150 
4151 
4152 # Setup additional tools that is considered a part of the toolchain, but not the
4153 # core part. Many of these are highly platform-specific and do not exist,
4154 # and/or are not needed on all platforms.
4155 
4156 
4157 # Setup the build tools (i.e, the compiler and linker used to build programs
4158 # that should be run on the build platform, not the target platform, as a build
4159 # helper). Since the non-cross-compile case uses the normal, target compilers
4160 # for this, we can only do this after these have been setup.
4161 
4162 
4163 # Setup legacy variables that are still needed as alternative ways to refer to
4164 # parts of the toolchain.
4165 
4166 
4167 # Do some additional checks on the detected tools.
4168 
4169 
4170 # Setup the JTReg Regression Test Harness.
4171 
4172 
4173 #
4174 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4175 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4176 #
4177 # This code is free software; you can redistribute it and/or modify it
4178 # under the terms of the GNU General Public License version 2 only, as
4179 # published by the Free Software Foundation.  Oracle designates this
4180 # particular file as subject to the "Classpath" exception as provided
4181 # by Oracle in the LICENSE file that accompanied this code.
4182 #
4183 # This code is distributed in the hope that it will be useful, but WITHOUT
4184 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4185 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4186 # version 2 for more details (a copy is included in the LICENSE file that
4187 # accompanied this code).
4188 #
4189 # You should have received a copy of the GNU General Public License version
4190 # 2 along with this work; if not, write to the Free Software Foundation,
4191 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4192 #
4193 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4194 # or visit www.oracle.com if you need additional information or have any
4195 # questions.
4196 #
4197 
4198 
4199 
4200 
4201 
4202 
4203 
4204 # Check if the VS env variables were setup prior to running configure.
4205 # If not, then find vcvarsall.bat and run it automatically, and integrate
4206 # the set env variables into the spec file.
4207 
4208 
4209 
4210 
4211 
4212 
4213 
4214 
4215 
4216 
4217 # This line needs to be here, verbatim, after all includes and the dummy hook
4218 # definitions. It is replaced with custom functionality when building
4219 # custom sources.
4220 #CUSTOM_AUTOCONF_INCLUDE
4221 
4222 # Do not change or remove the following line, it is needed for consistency checks:
4223 DATE_WHEN_GENERATED=1393396458
4224 
4225 ###############################################################################
4226 #
4227 # Initialization / Boot-strapping
4228 #
4229 # The bootstrapping process needs to solve the "chicken or the egg" problem,
4230 # thus it jumps back and forth, each time gaining something needed later on.
4231 #
4232 ###############################################################################
4233 
4234 # If we are requested to print additional help, do that and then exit.
4235 # This must be the very first call.
4236 
4237   if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4238     $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4239     $PRINTF "Which are valid to use depends on the build platform.\n"
4240     for toolchain in $VALID_TOOLCHAINS_all; do
4241       # Use indirect variable referencing
4242       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4243       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
4244       $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
4245     done
4246 
4247     # And now exit directly
4248     exit 0
4249   fi
4250 
4251 
4252 # Basic initialization that must happen first of all in the normal process.
4253 
4254   # Save the original command line. This is passed to us by the wrapper configure script.
4255 
4256   DATE_WHEN_CONFIGURED=`LANG=C date`
4257 
4258   { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5
4259 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;}
4260   { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5
4261 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;}
4262 
4263 
4264   # Start with tools that do not need have cross compilation support
4265   # and can be expected to be found in the default PATH. These tools are
4266   # used by configure. Nor are these tools expected to be found in the
4267   # devkit from the builddeps server either, since they are
4268   # needed to download the devkit.
4269 
4270   # First are all the simple required tools.
4271 
4272 
4273 
4274   # Publish this variable in the help.
4275 
4276 
4277   if test "x$BASENAME" = x; then
4278     # The variable is not set by user, try to locate tool using the code snippet
4279     for ac_prog in basename
4280 do
4281   # Extract the first word of "$ac_prog", so it can be a program name with args.
4282 set dummy $ac_prog; ac_word=$2
4283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4284 $as_echo_n "checking for $ac_word... " >&6; }
4285 if ${ac_cv_path_BASENAME+:} false; then :
4286   $as_echo_n "(cached) " >&6
4287 else
4288   case $BASENAME in
4289   [\\/]* | ?:[\\/]*)
4290   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4291   ;;
4292   *)
4293   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4294 for as_dir in $PATH
4295 do
4296   IFS=$as_save_IFS
4297   test -z "$as_dir" && as_dir=.
4298     for ac_exec_ext in '' $ac_executable_extensions; do
4299   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4300     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4301     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4302     break 2
4303   fi
4304 done
4305   done
4306 IFS=$as_save_IFS
4307 
4308   ;;
4309 esac
4310 fi
4311 BASENAME=$ac_cv_path_BASENAME
4312 if test -n "$BASENAME"; then
4313   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4314 $as_echo "$BASENAME" >&6; }
4315 else
4316   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4317 $as_echo "no" >&6; }
4318 fi
4319 
4320 
4321   test -n "$BASENAME" && break
4322 done
4323 
4324   else
4325     # The variable is set, but is it from the command line or the environment?
4326 
4327     # Try to remove the string !BASENAME! from our list.
4328     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/}
4329     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4330       # If it failed, the variable was not from the command line. Ignore it,
4331       # but warn the user (except for BASH, which is always set by the calling BASH).
4332       if test "xBASENAME" != xBASH; then
4333         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5
4334 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;}
4335       fi
4336       # Try to locate tool using the code snippet
4337       for ac_prog in basename
4338 do
4339   # Extract the first word of "$ac_prog", so it can be a program name with args.
4340 set dummy $ac_prog; ac_word=$2
4341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4342 $as_echo_n "checking for $ac_word... " >&6; }
4343 if ${ac_cv_path_BASENAME+:} false; then :
4344   $as_echo_n "(cached) " >&6
4345 else
4346   case $BASENAME in
4347   [\\/]* | ?:[\\/]*)
4348   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4349   ;;
4350   *)
4351   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4352 for as_dir in $PATH
4353 do
4354   IFS=$as_save_IFS
4355   test -z "$as_dir" && as_dir=.
4356     for ac_exec_ext in '' $ac_executable_extensions; do
4357   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4358     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4359     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4360     break 2
4361   fi
4362 done
4363   done
4364 IFS=$as_save_IFS
4365 
4366   ;;
4367 esac
4368 fi
4369 BASENAME=$ac_cv_path_BASENAME
4370 if test -n "$BASENAME"; then
4371   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4372 $as_echo "$BASENAME" >&6; }
4373 else
4374   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4375 $as_echo "no" >&6; }
4376 fi
4377 
4378 
4379   test -n "$BASENAME" && break
4380 done
4381 
4382     else
4383       # If it succeeded, then it was overridden by the user. We will use it
4384       # for the tool.
4385 
4386       # First remove it from the list of overridden variables, so we can test
4387       # for unknown variables in the end.
4388       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4389 
4390       # Check if the provided tool contains a complete path.
4391       tool_specified="$BASENAME"
4392       tool_basename="${tool_specified##*/}"
4393       if test "x$tool_basename" = "x$tool_specified"; then
4394         # A command without a complete path is provided, search $PATH.
4395         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5
4396 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;}
4397         # Extract the first word of "$tool_basename", so it can be a program name with args.
4398 set dummy $tool_basename; ac_word=$2
4399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4400 $as_echo_n "checking for $ac_word... " >&6; }
4401 if ${ac_cv_path_BASENAME+:} false; then :
4402   $as_echo_n "(cached) " >&6
4403 else
4404   case $BASENAME in
4405   [\\/]* | ?:[\\/]*)
4406   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4407   ;;
4408   *)
4409   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4410 for as_dir in $PATH
4411 do
4412   IFS=$as_save_IFS
4413   test -z "$as_dir" && as_dir=.
4414     for ac_exec_ext in '' $ac_executable_extensions; do
4415   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4416     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4417     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4418     break 2
4419   fi
4420 done
4421   done
4422 IFS=$as_save_IFS
4423 
4424   ;;
4425 esac
4426 fi
4427 BASENAME=$ac_cv_path_BASENAME
4428 if test -n "$BASENAME"; then
4429   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4430 $as_echo "$BASENAME" >&6; }
4431 else
4432   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4433 $as_echo "no" >&6; }
4434 fi
4435 
4436 
4437         if test "x$BASENAME" = x; then
4438           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4439         fi
4440       else
4441         # Otherwise we believe it is a complete path. Use it as it is.
4442         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5
4443 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;}
4444         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5
4445 $as_echo_n "checking for BASENAME... " >&6; }
4446         if test ! -x "$tool_specified"; then
4447           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4448 $as_echo "not found" >&6; }
4449           as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5
4450         fi
4451         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4452 $as_echo "$tool_specified" >&6; }
4453       fi
4454     fi
4455   fi
4456 
4457 
4458 
4459   if test "x$BASENAME" = x; then
4460     as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5
4461   fi
4462 
4463 
4464 
4465 
4466 
4467   # Publish this variable in the help.
4468 
4469 
4470   if test "x$BASH" = x; then
4471     # The variable is not set by user, try to locate tool using the code snippet
4472     for ac_prog in bash
4473 do
4474   # Extract the first word of "$ac_prog", so it can be a program name with args.
4475 set dummy $ac_prog; ac_word=$2
4476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4477 $as_echo_n "checking for $ac_word... " >&6; }
4478 if ${ac_cv_path_BASH+:} false; then :
4479   $as_echo_n "(cached) " >&6
4480 else
4481   case $BASH in
4482   [\\/]* | ?:[\\/]*)
4483   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4484   ;;
4485   *)
4486   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4487 for as_dir in $PATH
4488 do
4489   IFS=$as_save_IFS
4490   test -z "$as_dir" && as_dir=.
4491     for ac_exec_ext in '' $ac_executable_extensions; do
4492   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4493     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4494     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4495     break 2
4496   fi
4497 done
4498   done
4499 IFS=$as_save_IFS
4500 
4501   ;;
4502 esac
4503 fi
4504 BASH=$ac_cv_path_BASH
4505 if test -n "$BASH"; then
4506   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4507 $as_echo "$BASH" >&6; }
4508 else
4509   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4510 $as_echo "no" >&6; }
4511 fi
4512 
4513 
4514   test -n "$BASH" && break
4515 done
4516 
4517   else
4518     # The variable is set, but is it from the command line or the environment?
4519 
4520     # Try to remove the string !BASH! from our list.
4521     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/}
4522     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4523       # If it failed, the variable was not from the command line. Ignore it,
4524       # but warn the user (except for BASH, which is always set by the calling BASH).
4525       if test "xBASH" != xBASH; then
4526         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5
4527 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;}
4528       fi
4529       # Try to locate tool using the code snippet
4530       for ac_prog in bash
4531 do
4532   # Extract the first word of "$ac_prog", so it can be a program name with args.
4533 set dummy $ac_prog; ac_word=$2
4534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4535 $as_echo_n "checking for $ac_word... " >&6; }
4536 if ${ac_cv_path_BASH+:} false; then :
4537   $as_echo_n "(cached) " >&6
4538 else
4539   case $BASH in
4540   [\\/]* | ?:[\\/]*)
4541   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4542   ;;
4543   *)
4544   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4545 for as_dir in $PATH
4546 do
4547   IFS=$as_save_IFS
4548   test -z "$as_dir" && as_dir=.
4549     for ac_exec_ext in '' $ac_executable_extensions; do
4550   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4551     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4552     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4553     break 2
4554   fi
4555 done
4556   done
4557 IFS=$as_save_IFS
4558 
4559   ;;
4560 esac
4561 fi
4562 BASH=$ac_cv_path_BASH
4563 if test -n "$BASH"; then
4564   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4565 $as_echo "$BASH" >&6; }
4566 else
4567   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4568 $as_echo "no" >&6; }
4569 fi
4570 
4571 
4572   test -n "$BASH" && break
4573 done
4574 
4575     else
4576       # If it succeeded, then it was overridden by the user. We will use it
4577       # for the tool.
4578 
4579       # First remove it from the list of overridden variables, so we can test
4580       # for unknown variables in the end.
4581       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4582 
4583       # Check if the provided tool contains a complete path.
4584       tool_specified="$BASH"
4585       tool_basename="${tool_specified##*/}"
4586       if test "x$tool_basename" = "x$tool_specified"; then
4587         # A command without a complete path is provided, search $PATH.
4588         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5
4589 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;}
4590         # Extract the first word of "$tool_basename", so it can be a program name with args.
4591 set dummy $tool_basename; ac_word=$2
4592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4593 $as_echo_n "checking for $ac_word... " >&6; }
4594 if ${ac_cv_path_BASH+:} false; then :
4595   $as_echo_n "(cached) " >&6
4596 else
4597   case $BASH in
4598   [\\/]* | ?:[\\/]*)
4599   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4600   ;;
4601   *)
4602   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4603 for as_dir in $PATH
4604 do
4605   IFS=$as_save_IFS
4606   test -z "$as_dir" && as_dir=.
4607     for ac_exec_ext in '' $ac_executable_extensions; do
4608   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4609     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4610     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4611     break 2
4612   fi
4613 done
4614   done
4615 IFS=$as_save_IFS
4616 
4617   ;;
4618 esac
4619 fi
4620 BASH=$ac_cv_path_BASH
4621 if test -n "$BASH"; then
4622   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4623 $as_echo "$BASH" >&6; }
4624 else
4625   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4626 $as_echo "no" >&6; }
4627 fi
4628 
4629 
4630         if test "x$BASH" = x; then
4631           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4632         fi
4633       else
4634         # Otherwise we believe it is a complete path. Use it as it is.
4635         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5
4636 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;}
4637         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5
4638 $as_echo_n "checking for BASH... " >&6; }
4639         if test ! -x "$tool_specified"; then
4640           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4641 $as_echo "not found" >&6; }
4642           as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5
4643         fi
4644         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4645 $as_echo "$tool_specified" >&6; }
4646       fi
4647     fi
4648   fi
4649 
4650 
4651 
4652   if test "x$BASH" = x; then
4653     as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5
4654   fi
4655 
4656 
4657 
4658 
4659 
4660   # Publish this variable in the help.
4661 
4662 
4663   if test "x$CAT" = x; then
4664     # The variable is not set by user, try to locate tool using the code snippet
4665     for ac_prog in cat
4666 do
4667   # Extract the first word of "$ac_prog", so it can be a program name with args.
4668 set dummy $ac_prog; ac_word=$2
4669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4670 $as_echo_n "checking for $ac_word... " >&6; }
4671 if ${ac_cv_path_CAT+:} false; then :
4672   $as_echo_n "(cached) " >&6
4673 else
4674   case $CAT in
4675   [\\/]* | ?:[\\/]*)
4676   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4677   ;;
4678   *)
4679   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4680 for as_dir in $PATH
4681 do
4682   IFS=$as_save_IFS
4683   test -z "$as_dir" && as_dir=.
4684     for ac_exec_ext in '' $ac_executable_extensions; do
4685   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4686     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4687     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4688     break 2
4689   fi
4690 done
4691   done
4692 IFS=$as_save_IFS
4693 
4694   ;;
4695 esac
4696 fi
4697 CAT=$ac_cv_path_CAT
4698 if test -n "$CAT"; then
4699   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4700 $as_echo "$CAT" >&6; }
4701 else
4702   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4703 $as_echo "no" >&6; }
4704 fi
4705 
4706 
4707   test -n "$CAT" && break
4708 done
4709 
4710   else
4711     # The variable is set, but is it from the command line or the environment?
4712 
4713     # Try to remove the string !CAT! from our list.
4714     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/}
4715     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4716       # If it failed, the variable was not from the command line. Ignore it,
4717       # but warn the user (except for BASH, which is always set by the calling BASH).
4718       if test "xCAT" != xBASH; then
4719         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5
4720 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;}
4721       fi
4722       # Try to locate tool using the code snippet
4723       for ac_prog in cat
4724 do
4725   # Extract the first word of "$ac_prog", so it can be a program name with args.
4726 set dummy $ac_prog; ac_word=$2
4727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4728 $as_echo_n "checking for $ac_word... " >&6; }
4729 if ${ac_cv_path_CAT+:} false; then :
4730   $as_echo_n "(cached) " >&6
4731 else
4732   case $CAT in
4733   [\\/]* | ?:[\\/]*)
4734   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4735   ;;
4736   *)
4737   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4738 for as_dir in $PATH
4739 do
4740   IFS=$as_save_IFS
4741   test -z "$as_dir" && as_dir=.
4742     for ac_exec_ext in '' $ac_executable_extensions; do
4743   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4744     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4745     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4746     break 2
4747   fi
4748 done
4749   done
4750 IFS=$as_save_IFS
4751 
4752   ;;
4753 esac
4754 fi
4755 CAT=$ac_cv_path_CAT
4756 if test -n "$CAT"; then
4757   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4758 $as_echo "$CAT" >&6; }
4759 else
4760   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4761 $as_echo "no" >&6; }
4762 fi
4763 
4764 
4765   test -n "$CAT" && break
4766 done
4767 
4768     else
4769       # If it succeeded, then it was overridden by the user. We will use it
4770       # for the tool.
4771 
4772       # First remove it from the list of overridden variables, so we can test
4773       # for unknown variables in the end.
4774       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4775 
4776       # Check if the provided tool contains a complete path.
4777       tool_specified="$CAT"
4778       tool_basename="${tool_specified##*/}"
4779       if test "x$tool_basename" = "x$tool_specified"; then
4780         # A command without a complete path is provided, search $PATH.
4781         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5
4782 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;}
4783         # Extract the first word of "$tool_basename", so it can be a program name with args.
4784 set dummy $tool_basename; ac_word=$2
4785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4786 $as_echo_n "checking for $ac_word... " >&6; }
4787 if ${ac_cv_path_CAT+:} false; then :
4788   $as_echo_n "(cached) " >&6
4789 else
4790   case $CAT in
4791   [\\/]* | ?:[\\/]*)
4792   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4793   ;;
4794   *)
4795   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4796 for as_dir in $PATH
4797 do
4798   IFS=$as_save_IFS
4799   test -z "$as_dir" && as_dir=.
4800     for ac_exec_ext in '' $ac_executable_extensions; do
4801   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4802     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4803     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4804     break 2
4805   fi
4806 done
4807   done
4808 IFS=$as_save_IFS
4809 
4810   ;;
4811 esac
4812 fi
4813 CAT=$ac_cv_path_CAT
4814 if test -n "$CAT"; then
4815   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4816 $as_echo "$CAT" >&6; }
4817 else
4818   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4819 $as_echo "no" >&6; }
4820 fi
4821 
4822 
4823         if test "x$CAT" = x; then
4824           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4825         fi
4826       else
4827         # Otherwise we believe it is a complete path. Use it as it is.
4828         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5
4829 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;}
4830         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5
4831 $as_echo_n "checking for CAT... " >&6; }
4832         if test ! -x "$tool_specified"; then
4833           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4834 $as_echo "not found" >&6; }
4835           as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5
4836         fi
4837         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4838 $as_echo "$tool_specified" >&6; }
4839       fi
4840     fi
4841   fi
4842 
4843 
4844 
4845   if test "x$CAT" = x; then
4846     as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5
4847   fi
4848 
4849 
4850 
4851 
4852 
4853   # Publish this variable in the help.
4854 
4855 
4856   if test "x$CHMOD" = x; then
4857     # The variable is not set by user, try to locate tool using the code snippet
4858     for ac_prog in chmod
4859 do
4860   # Extract the first word of "$ac_prog", so it can be a program name with args.
4861 set dummy $ac_prog; ac_word=$2
4862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4863 $as_echo_n "checking for $ac_word... " >&6; }
4864 if ${ac_cv_path_CHMOD+:} false; then :
4865   $as_echo_n "(cached) " >&6
4866 else
4867   case $CHMOD in
4868   [\\/]* | ?:[\\/]*)
4869   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4870   ;;
4871   *)
4872   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4873 for as_dir in $PATH
4874 do
4875   IFS=$as_save_IFS
4876   test -z "$as_dir" && as_dir=.
4877     for ac_exec_ext in '' $ac_executable_extensions; do
4878   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4879     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4880     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4881     break 2
4882   fi
4883 done
4884   done
4885 IFS=$as_save_IFS
4886 
4887   ;;
4888 esac
4889 fi
4890 CHMOD=$ac_cv_path_CHMOD
4891 if test -n "$CHMOD"; then
4892   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4893 $as_echo "$CHMOD" >&6; }
4894 else
4895   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4896 $as_echo "no" >&6; }
4897 fi
4898 
4899 
4900   test -n "$CHMOD" && break
4901 done
4902 
4903   else
4904     # The variable is set, but is it from the command line or the environment?
4905 
4906     # Try to remove the string !CHMOD! from our list.
4907     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/}
4908     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4909       # If it failed, the variable was not from the command line. Ignore it,
4910       # but warn the user (except for BASH, which is always set by the calling BASH).
4911       if test "xCHMOD" != xBASH; then
4912         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5
4913 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;}
4914       fi
4915       # Try to locate tool using the code snippet
4916       for ac_prog in chmod
4917 do
4918   # Extract the first word of "$ac_prog", so it can be a program name with args.
4919 set dummy $ac_prog; ac_word=$2
4920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4921 $as_echo_n "checking for $ac_word... " >&6; }
4922 if ${ac_cv_path_CHMOD+:} false; then :
4923   $as_echo_n "(cached) " >&6
4924 else
4925   case $CHMOD in
4926   [\\/]* | ?:[\\/]*)
4927   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4928   ;;
4929   *)
4930   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4931 for as_dir in $PATH
4932 do
4933   IFS=$as_save_IFS
4934   test -z "$as_dir" && as_dir=.
4935     for ac_exec_ext in '' $ac_executable_extensions; do
4936   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4937     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4938     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4939     break 2
4940   fi
4941 done
4942   done
4943 IFS=$as_save_IFS
4944 
4945   ;;
4946 esac
4947 fi
4948 CHMOD=$ac_cv_path_CHMOD
4949 if test -n "$CHMOD"; then
4950   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4951 $as_echo "$CHMOD" >&6; }
4952 else
4953   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4954 $as_echo "no" >&6; }
4955 fi
4956 
4957 
4958   test -n "$CHMOD" && break
4959 done
4960 
4961     else
4962       # If it succeeded, then it was overridden by the user. We will use it
4963       # for the tool.
4964 
4965       # First remove it from the list of overridden variables, so we can test
4966       # for unknown variables in the end.
4967       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4968 
4969       # Check if the provided tool contains a complete path.
4970       tool_specified="$CHMOD"
4971       tool_basename="${tool_specified##*/}"
4972       if test "x$tool_basename" = "x$tool_specified"; then
4973         # A command without a complete path is provided, search $PATH.
4974         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5
4975 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;}
4976         # Extract the first word of "$tool_basename", so it can be a program name with args.
4977 set dummy $tool_basename; ac_word=$2
4978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4979 $as_echo_n "checking for $ac_word... " >&6; }
4980 if ${ac_cv_path_CHMOD+:} false; then :
4981   $as_echo_n "(cached) " >&6
4982 else
4983   case $CHMOD in
4984   [\\/]* | ?:[\\/]*)
4985   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4986   ;;
4987   *)
4988   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4989 for as_dir in $PATH
4990 do
4991   IFS=$as_save_IFS
4992   test -z "$as_dir" && as_dir=.
4993     for ac_exec_ext in '' $ac_executable_extensions; do
4994   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4995     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4996     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4997     break 2
4998   fi
4999 done
5000   done
5001 IFS=$as_save_IFS
5002 
5003   ;;
5004 esac
5005 fi
5006 CHMOD=$ac_cv_path_CHMOD
5007 if test -n "$CHMOD"; then
5008   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5009 $as_echo "$CHMOD" >&6; }
5010 else
5011   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5012 $as_echo "no" >&6; }
5013 fi
5014 
5015 
5016         if test "x$CHMOD" = x; then
5017           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5018         fi
5019       else
5020         # Otherwise we believe it is a complete path. Use it as it is.
5021         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5
5022 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;}
5023         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5
5024 $as_echo_n "checking for CHMOD... " >&6; }
5025         if test ! -x "$tool_specified"; then
5026           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5027 $as_echo "not found" >&6; }
5028           as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5
5029         fi
5030         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5031 $as_echo "$tool_specified" >&6; }
5032       fi
5033     fi
5034   fi
5035 
5036 
5037 
5038   if test "x$CHMOD" = x; then
5039     as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5
5040   fi
5041 
5042 
5043 
5044 
5045 
5046   # Publish this variable in the help.
5047 
5048 
5049   if test "x$CMP" = x; then
5050     # The variable is not set by user, try to locate tool using the code snippet
5051     for ac_prog in cmp
5052 do
5053   # Extract the first word of "$ac_prog", so it can be a program name with args.
5054 set dummy $ac_prog; ac_word=$2
5055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5056 $as_echo_n "checking for $ac_word... " >&6; }
5057 if ${ac_cv_path_CMP+:} false; then :
5058   $as_echo_n "(cached) " >&6
5059 else
5060   case $CMP in
5061   [\\/]* | ?:[\\/]*)
5062   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5063   ;;
5064   *)
5065   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5066 for as_dir in $PATH
5067 do
5068   IFS=$as_save_IFS
5069   test -z "$as_dir" && as_dir=.
5070     for ac_exec_ext in '' $ac_executable_extensions; do
5071   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5072     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5073     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5074     break 2
5075   fi
5076 done
5077   done
5078 IFS=$as_save_IFS
5079 
5080   ;;
5081 esac
5082 fi
5083 CMP=$ac_cv_path_CMP
5084 if test -n "$CMP"; then
5085   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5086 $as_echo "$CMP" >&6; }
5087 else
5088   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5089 $as_echo "no" >&6; }
5090 fi
5091 
5092 
5093   test -n "$CMP" && break
5094 done
5095 
5096   else
5097     # The variable is set, but is it from the command line or the environment?
5098 
5099     # Try to remove the string !CMP! from our list.
5100     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/}
5101     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5102       # If it failed, the variable was not from the command line. Ignore it,
5103       # but warn the user (except for BASH, which is always set by the calling BASH).
5104       if test "xCMP" != xBASH; then
5105         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5
5106 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;}
5107       fi
5108       # Try to locate tool using the code snippet
5109       for ac_prog in cmp
5110 do
5111   # Extract the first word of "$ac_prog", so it can be a program name with args.
5112 set dummy $ac_prog; ac_word=$2
5113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5114 $as_echo_n "checking for $ac_word... " >&6; }
5115 if ${ac_cv_path_CMP+:} false; then :
5116   $as_echo_n "(cached) " >&6
5117 else
5118   case $CMP in
5119   [\\/]* | ?:[\\/]*)
5120   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5121   ;;
5122   *)
5123   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5124 for as_dir in $PATH
5125 do
5126   IFS=$as_save_IFS
5127   test -z "$as_dir" && as_dir=.
5128     for ac_exec_ext in '' $ac_executable_extensions; do
5129   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5130     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5131     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5132     break 2
5133   fi
5134 done
5135   done
5136 IFS=$as_save_IFS
5137 
5138   ;;
5139 esac
5140 fi
5141 CMP=$ac_cv_path_CMP
5142 if test -n "$CMP"; then
5143   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5144 $as_echo "$CMP" >&6; }
5145 else
5146   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5147 $as_echo "no" >&6; }
5148 fi
5149 
5150 
5151   test -n "$CMP" && break
5152 done
5153 
5154     else
5155       # If it succeeded, then it was overridden by the user. We will use it
5156       # for the tool.
5157 
5158       # First remove it from the list of overridden variables, so we can test
5159       # for unknown variables in the end.
5160       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5161 
5162       # Check if the provided tool contains a complete path.
5163       tool_specified="$CMP"
5164       tool_basename="${tool_specified##*/}"
5165       if test "x$tool_basename" = "x$tool_specified"; then
5166         # A command without a complete path is provided, search $PATH.
5167         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5
5168 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;}
5169         # Extract the first word of "$tool_basename", so it can be a program name with args.
5170 set dummy $tool_basename; ac_word=$2
5171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5172 $as_echo_n "checking for $ac_word... " >&6; }
5173 if ${ac_cv_path_CMP+:} false; then :
5174   $as_echo_n "(cached) " >&6
5175 else
5176   case $CMP in
5177   [\\/]* | ?:[\\/]*)
5178   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5179   ;;
5180   *)
5181   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5182 for as_dir in $PATH
5183 do
5184   IFS=$as_save_IFS
5185   test -z "$as_dir" && as_dir=.
5186     for ac_exec_ext in '' $ac_executable_extensions; do
5187   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5188     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5189     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5190     break 2
5191   fi
5192 done
5193   done
5194 IFS=$as_save_IFS
5195 
5196   ;;
5197 esac
5198 fi
5199 CMP=$ac_cv_path_CMP
5200 if test -n "$CMP"; then
5201   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5202 $as_echo "$CMP" >&6; }
5203 else
5204   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5205 $as_echo "no" >&6; }
5206 fi
5207 
5208 
5209         if test "x$CMP" = x; then
5210           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5211         fi
5212       else
5213         # Otherwise we believe it is a complete path. Use it as it is.
5214         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5
5215 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;}
5216         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5
5217 $as_echo_n "checking for CMP... " >&6; }
5218         if test ! -x "$tool_specified"; then
5219           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5220 $as_echo "not found" >&6; }
5221           as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5
5222         fi
5223         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5224 $as_echo "$tool_specified" >&6; }
5225       fi
5226     fi
5227   fi
5228 
5229 
5230 
5231   if test "x$CMP" = x; then
5232     as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5
5233   fi
5234 
5235 
5236 
5237 
5238 
5239   # Publish this variable in the help.
5240 
5241 
5242   if test "x$COMM" = x; then
5243     # The variable is not set by user, try to locate tool using the code snippet
5244     for ac_prog in comm
5245 do
5246   # Extract the first word of "$ac_prog", so it can be a program name with args.
5247 set dummy $ac_prog; ac_word=$2
5248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5249 $as_echo_n "checking for $ac_word... " >&6; }
5250 if ${ac_cv_path_COMM+:} false; then :
5251   $as_echo_n "(cached) " >&6
5252 else
5253   case $COMM in
5254   [\\/]* | ?:[\\/]*)
5255   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5256   ;;
5257   *)
5258   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5259 for as_dir in $PATH
5260 do
5261   IFS=$as_save_IFS
5262   test -z "$as_dir" && as_dir=.
5263     for ac_exec_ext in '' $ac_executable_extensions; do
5264   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5265     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5266     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5267     break 2
5268   fi
5269 done
5270   done
5271 IFS=$as_save_IFS
5272 
5273   ;;
5274 esac
5275 fi
5276 COMM=$ac_cv_path_COMM
5277 if test -n "$COMM"; then
5278   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5279 $as_echo "$COMM" >&6; }
5280 else
5281   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5282 $as_echo "no" >&6; }
5283 fi
5284 
5285 
5286   test -n "$COMM" && break
5287 done
5288 
5289   else
5290     # The variable is set, but is it from the command line or the environment?
5291 
5292     # Try to remove the string !COMM! from our list.
5293     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
5294     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5295       # If it failed, the variable was not from the command line. Ignore it,
5296       # but warn the user (except for BASH, which is always set by the calling BASH).
5297       if test "xCOMM" != xBASH; then
5298         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
5299 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
5300       fi
5301       # Try to locate tool using the code snippet
5302       for ac_prog in comm
5303 do
5304   # Extract the first word of "$ac_prog", so it can be a program name with args.
5305 set dummy $ac_prog; ac_word=$2
5306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5307 $as_echo_n "checking for $ac_word... " >&6; }
5308 if ${ac_cv_path_COMM+:} false; then :
5309   $as_echo_n "(cached) " >&6
5310 else
5311   case $COMM in
5312   [\\/]* | ?:[\\/]*)
5313   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5314   ;;
5315   *)
5316   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5317 for as_dir in $PATH
5318 do
5319   IFS=$as_save_IFS
5320   test -z "$as_dir" && as_dir=.
5321     for ac_exec_ext in '' $ac_executable_extensions; do
5322   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5323     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5324     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5325     break 2
5326   fi
5327 done
5328   done
5329 IFS=$as_save_IFS
5330 
5331   ;;
5332 esac
5333 fi
5334 COMM=$ac_cv_path_COMM
5335 if test -n "$COMM"; then
5336   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5337 $as_echo "$COMM" >&6; }
5338 else
5339   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5340 $as_echo "no" >&6; }
5341 fi
5342 
5343 
5344   test -n "$COMM" && break
5345 done
5346 
5347     else
5348       # If it succeeded, then it was overridden by the user. We will use it
5349       # for the tool.
5350 
5351       # First remove it from the list of overridden variables, so we can test
5352       # for unknown variables in the end.
5353       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5354 
5355       # Check if the provided tool contains a complete path.
5356       tool_specified="$COMM"
5357       tool_basename="${tool_specified##*/}"
5358       if test "x$tool_basename" = "x$tool_specified"; then
5359         # A command without a complete path is provided, search $PATH.
5360         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
5361 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
5362         # Extract the first word of "$tool_basename", so it can be a program name with args.
5363 set dummy $tool_basename; ac_word=$2
5364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5365 $as_echo_n "checking for $ac_word... " >&6; }
5366 if ${ac_cv_path_COMM+:} false; then :
5367   $as_echo_n "(cached) " >&6
5368 else
5369   case $COMM in
5370   [\\/]* | ?:[\\/]*)
5371   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5372   ;;
5373   *)
5374   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5375 for as_dir in $PATH
5376 do
5377   IFS=$as_save_IFS
5378   test -z "$as_dir" && as_dir=.
5379     for ac_exec_ext in '' $ac_executable_extensions; do
5380   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5381     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5382     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5383     break 2
5384   fi
5385 done
5386   done
5387 IFS=$as_save_IFS
5388 
5389   ;;
5390 esac
5391 fi
5392 COMM=$ac_cv_path_COMM
5393 if test -n "$COMM"; then
5394   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5395 $as_echo "$COMM" >&6; }
5396 else
5397   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5398 $as_echo "no" >&6; }
5399 fi
5400 
5401 
5402         if test "x$COMM" = x; then
5403           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5404         fi
5405       else
5406         # Otherwise we believe it is a complete path. Use it as it is.
5407         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
5408 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
5409         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
5410 $as_echo_n "checking for COMM... " >&6; }
5411         if test ! -x "$tool_specified"; then
5412           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5413 $as_echo "not found" >&6; }
5414           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
5415         fi
5416         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5417 $as_echo "$tool_specified" >&6; }
5418       fi
5419     fi
5420   fi
5421 
5422 
5423 
5424   if test "x$COMM" = x; then
5425     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
5426   fi
5427 
5428 
5429 
5430 
5431 
5432   # Publish this variable in the help.
5433 
5434 
5435   if test "x$CP" = x; then
5436     # The variable is not set by user, try to locate tool using the code snippet
5437     for ac_prog in cp
5438 do
5439   # Extract the first word of "$ac_prog", so it can be a program name with args.
5440 set dummy $ac_prog; ac_word=$2
5441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5442 $as_echo_n "checking for $ac_word... " >&6; }
5443 if ${ac_cv_path_CP+:} false; then :
5444   $as_echo_n "(cached) " >&6
5445 else
5446   case $CP in
5447   [\\/]* | ?:[\\/]*)
5448   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5449   ;;
5450   *)
5451   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5452 for as_dir in $PATH
5453 do
5454   IFS=$as_save_IFS
5455   test -z "$as_dir" && as_dir=.
5456     for ac_exec_ext in '' $ac_executable_extensions; do
5457   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5458     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5459     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5460     break 2
5461   fi
5462 done
5463   done
5464 IFS=$as_save_IFS
5465 
5466   ;;
5467 esac
5468 fi
5469 CP=$ac_cv_path_CP
5470 if test -n "$CP"; then
5471   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5472 $as_echo "$CP" >&6; }
5473 else
5474   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5475 $as_echo "no" >&6; }
5476 fi
5477 
5478 
5479   test -n "$CP" && break
5480 done
5481 
5482   else
5483     # The variable is set, but is it from the command line or the environment?
5484 
5485     # Try to remove the string !CP! from our list.
5486     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/}
5487     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5488       # If it failed, the variable was not from the command line. Ignore it,
5489       # but warn the user (except for BASH, which is always set by the calling BASH).
5490       if test "xCP" != xBASH; then
5491         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5
5492 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;}
5493       fi
5494       # Try to locate tool using the code snippet
5495       for ac_prog in cp
5496 do
5497   # Extract the first word of "$ac_prog", so it can be a program name with args.
5498 set dummy $ac_prog; ac_word=$2
5499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5500 $as_echo_n "checking for $ac_word... " >&6; }
5501 if ${ac_cv_path_CP+:} false; then :
5502   $as_echo_n "(cached) " >&6
5503 else
5504   case $CP in
5505   [\\/]* | ?:[\\/]*)
5506   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5507   ;;
5508   *)
5509   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5510 for as_dir in $PATH
5511 do
5512   IFS=$as_save_IFS
5513   test -z "$as_dir" && as_dir=.
5514     for ac_exec_ext in '' $ac_executable_extensions; do
5515   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5516     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5517     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5518     break 2
5519   fi
5520 done
5521   done
5522 IFS=$as_save_IFS
5523 
5524   ;;
5525 esac
5526 fi
5527 CP=$ac_cv_path_CP
5528 if test -n "$CP"; then
5529   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5530 $as_echo "$CP" >&6; }
5531 else
5532   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5533 $as_echo "no" >&6; }
5534 fi
5535 
5536 
5537   test -n "$CP" && break
5538 done
5539 
5540     else
5541       # If it succeeded, then it was overridden by the user. We will use it
5542       # for the tool.
5543 
5544       # First remove it from the list of overridden variables, so we can test
5545       # for unknown variables in the end.
5546       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5547 
5548       # Check if the provided tool contains a complete path.
5549       tool_specified="$CP"
5550       tool_basename="${tool_specified##*/}"
5551       if test "x$tool_basename" = "x$tool_specified"; then
5552         # A command without a complete path is provided, search $PATH.
5553         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5
5554 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;}
5555         # Extract the first word of "$tool_basename", so it can be a program name with args.
5556 set dummy $tool_basename; ac_word=$2
5557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5558 $as_echo_n "checking for $ac_word... " >&6; }
5559 if ${ac_cv_path_CP+:} false; then :
5560   $as_echo_n "(cached) " >&6
5561 else
5562   case $CP in
5563   [\\/]* | ?:[\\/]*)
5564   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5565   ;;
5566   *)
5567   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5568 for as_dir in $PATH
5569 do
5570   IFS=$as_save_IFS
5571   test -z "$as_dir" && as_dir=.
5572     for ac_exec_ext in '' $ac_executable_extensions; do
5573   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5574     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5575     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5576     break 2
5577   fi
5578 done
5579   done
5580 IFS=$as_save_IFS
5581 
5582   ;;
5583 esac
5584 fi
5585 CP=$ac_cv_path_CP
5586 if test -n "$CP"; then
5587   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5588 $as_echo "$CP" >&6; }
5589 else
5590   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5591 $as_echo "no" >&6; }
5592 fi
5593 
5594 
5595         if test "x$CP" = x; then
5596           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5597         fi
5598       else
5599         # Otherwise we believe it is a complete path. Use it as it is.
5600         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5
5601 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;}
5602         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5
5603 $as_echo_n "checking for CP... " >&6; }
5604         if test ! -x "$tool_specified"; then
5605           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5606 $as_echo "not found" >&6; }
5607           as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5
5608         fi
5609         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5610 $as_echo "$tool_specified" >&6; }
5611       fi
5612     fi
5613   fi
5614 
5615 
5616 
5617   if test "x$CP" = x; then
5618     as_fn_error $? "Could not find required tool for CP" "$LINENO" 5
5619   fi
5620 
5621 
5622 
5623 
5624 
5625   # Publish this variable in the help.
5626 
5627 
5628   if test "x$CPIO" = x; then
5629     # The variable is not set by user, try to locate tool using the code snippet
5630     for ac_prog in cpio
5631 do
5632   # Extract the first word of "$ac_prog", so it can be a program name with args.
5633 set dummy $ac_prog; ac_word=$2
5634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5635 $as_echo_n "checking for $ac_word... " >&6; }
5636 if ${ac_cv_path_CPIO+:} false; then :
5637   $as_echo_n "(cached) " >&6
5638 else
5639   case $CPIO in
5640   [\\/]* | ?:[\\/]*)
5641   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5642   ;;
5643   *)
5644   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5645 for as_dir in $PATH
5646 do
5647   IFS=$as_save_IFS
5648   test -z "$as_dir" && as_dir=.
5649     for ac_exec_ext in '' $ac_executable_extensions; do
5650   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5651     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5652     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5653     break 2
5654   fi
5655 done
5656   done
5657 IFS=$as_save_IFS
5658 
5659   ;;
5660 esac
5661 fi
5662 CPIO=$ac_cv_path_CPIO
5663 if test -n "$CPIO"; then
5664   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5665 $as_echo "$CPIO" >&6; }
5666 else
5667   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5668 $as_echo "no" >&6; }
5669 fi
5670 
5671 
5672   test -n "$CPIO" && break
5673 done
5674 
5675   else
5676     # The variable is set, but is it from the command line or the environment?
5677 
5678     # Try to remove the string !CPIO! from our list.
5679     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/}
5680     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5681       # If it failed, the variable was not from the command line. Ignore it,
5682       # but warn the user (except for BASH, which is always set by the calling BASH).
5683       if test "xCPIO" != xBASH; then
5684         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5
5685 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;}
5686       fi
5687       # Try to locate tool using the code snippet
5688       for ac_prog in cpio
5689 do
5690   # Extract the first word of "$ac_prog", so it can be a program name with args.
5691 set dummy $ac_prog; ac_word=$2
5692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5693 $as_echo_n "checking for $ac_word... " >&6; }
5694 if ${ac_cv_path_CPIO+:} false; then :
5695   $as_echo_n "(cached) " >&6
5696 else
5697   case $CPIO in
5698   [\\/]* | ?:[\\/]*)
5699   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5700   ;;
5701   *)
5702   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5703 for as_dir in $PATH
5704 do
5705   IFS=$as_save_IFS
5706   test -z "$as_dir" && as_dir=.
5707     for ac_exec_ext in '' $ac_executable_extensions; do
5708   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5709     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5710     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5711     break 2
5712   fi
5713 done
5714   done
5715 IFS=$as_save_IFS
5716 
5717   ;;
5718 esac
5719 fi
5720 CPIO=$ac_cv_path_CPIO
5721 if test -n "$CPIO"; then
5722   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5723 $as_echo "$CPIO" >&6; }
5724 else
5725   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5726 $as_echo "no" >&6; }
5727 fi
5728 
5729 
5730   test -n "$CPIO" && break
5731 done
5732 
5733     else
5734       # If it succeeded, then it was overridden by the user. We will use it
5735       # for the tool.
5736 
5737       # First remove it from the list of overridden variables, so we can test
5738       # for unknown variables in the end.
5739       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5740 
5741       # Check if the provided tool contains a complete path.
5742       tool_specified="$CPIO"
5743       tool_basename="${tool_specified##*/}"
5744       if test "x$tool_basename" = "x$tool_specified"; then
5745         # A command without a complete path is provided, search $PATH.
5746         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5
5747 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;}
5748         # Extract the first word of "$tool_basename", so it can be a program name with args.
5749 set dummy $tool_basename; ac_word=$2
5750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5751 $as_echo_n "checking for $ac_word... " >&6; }
5752 if ${ac_cv_path_CPIO+:} false; then :
5753   $as_echo_n "(cached) " >&6
5754 else
5755   case $CPIO in
5756   [\\/]* | ?:[\\/]*)
5757   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5758   ;;
5759   *)
5760   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5761 for as_dir in $PATH
5762 do
5763   IFS=$as_save_IFS
5764   test -z "$as_dir" && as_dir=.
5765     for ac_exec_ext in '' $ac_executable_extensions; do
5766   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5767     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5768     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5769     break 2
5770   fi
5771 done
5772   done
5773 IFS=$as_save_IFS
5774 
5775   ;;
5776 esac
5777 fi
5778 CPIO=$ac_cv_path_CPIO
5779 if test -n "$CPIO"; then
5780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5781 $as_echo "$CPIO" >&6; }
5782 else
5783   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5784 $as_echo "no" >&6; }
5785 fi
5786 
5787 
5788         if test "x$CPIO" = x; then
5789           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5790         fi
5791       else
5792         # Otherwise we believe it is a complete path. Use it as it is.
5793         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5
5794 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;}
5795         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5
5796 $as_echo_n "checking for CPIO... " >&6; }
5797         if test ! -x "$tool_specified"; then
5798           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5799 $as_echo "not found" >&6; }
5800           as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5
5801         fi
5802         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5803 $as_echo "$tool_specified" >&6; }
5804       fi
5805     fi
5806   fi
5807 
5808 
5809 
5810   if test "x$CPIO" = x; then
5811     as_fn_error $? "Could not find required tool for CPIO" "$LINENO" 5
5812   fi
5813 
5814 
5815 
5816 
5817 
5818   # Publish this variable in the help.
5819 
5820 
5821   if test "x$CUT" = x; then
5822     # The variable is not set by user, try to locate tool using the code snippet
5823     for ac_prog in cut
5824 do
5825   # Extract the first word of "$ac_prog", so it can be a program name with args.
5826 set dummy $ac_prog; ac_word=$2
5827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5828 $as_echo_n "checking for $ac_word... " >&6; }
5829 if ${ac_cv_path_CUT+:} false; then :
5830   $as_echo_n "(cached) " >&6
5831 else
5832   case $CUT in
5833   [\\/]* | ?:[\\/]*)
5834   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5835   ;;
5836   *)
5837   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5838 for as_dir in $PATH
5839 do
5840   IFS=$as_save_IFS
5841   test -z "$as_dir" && as_dir=.
5842     for ac_exec_ext in '' $ac_executable_extensions; do
5843   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5844     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5845     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5846     break 2
5847   fi
5848 done
5849   done
5850 IFS=$as_save_IFS
5851 
5852   ;;
5853 esac
5854 fi
5855 CUT=$ac_cv_path_CUT
5856 if test -n "$CUT"; then
5857   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5858 $as_echo "$CUT" >&6; }
5859 else
5860   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5861 $as_echo "no" >&6; }
5862 fi
5863 
5864 
5865   test -n "$CUT" && break
5866 done
5867 
5868   else
5869     # The variable is set, but is it from the command line or the environment?
5870 
5871     # Try to remove the string !CUT! from our list.
5872     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/}
5873     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5874       # If it failed, the variable was not from the command line. Ignore it,
5875       # but warn the user (except for BASH, which is always set by the calling BASH).
5876       if test "xCUT" != xBASH; then
5877         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5
5878 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;}
5879       fi
5880       # Try to locate tool using the code snippet
5881       for ac_prog in cut
5882 do
5883   # Extract the first word of "$ac_prog", so it can be a program name with args.
5884 set dummy $ac_prog; ac_word=$2
5885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5886 $as_echo_n "checking for $ac_word... " >&6; }
5887 if ${ac_cv_path_CUT+:} false; then :
5888   $as_echo_n "(cached) " >&6
5889 else
5890   case $CUT in
5891   [\\/]* | ?:[\\/]*)
5892   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5893   ;;
5894   *)
5895   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5896 for as_dir in $PATH
5897 do
5898   IFS=$as_save_IFS
5899   test -z "$as_dir" && as_dir=.
5900     for ac_exec_ext in '' $ac_executable_extensions; do
5901   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5902     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5903     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5904     break 2
5905   fi
5906 done
5907   done
5908 IFS=$as_save_IFS
5909 
5910   ;;
5911 esac
5912 fi
5913 CUT=$ac_cv_path_CUT
5914 if test -n "$CUT"; then
5915   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5916 $as_echo "$CUT" >&6; }
5917 else
5918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5919 $as_echo "no" >&6; }
5920 fi
5921 
5922 
5923   test -n "$CUT" && break
5924 done
5925 
5926     else
5927       # If it succeeded, then it was overridden by the user. We will use it
5928       # for the tool.
5929 
5930       # First remove it from the list of overridden variables, so we can test
5931       # for unknown variables in the end.
5932       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5933 
5934       # Check if the provided tool contains a complete path.
5935       tool_specified="$CUT"
5936       tool_basename="${tool_specified##*/}"
5937       if test "x$tool_basename" = "x$tool_specified"; then
5938         # A command without a complete path is provided, search $PATH.
5939         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5
5940 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;}
5941         # Extract the first word of "$tool_basename", so it can be a program name with args.
5942 set dummy $tool_basename; ac_word=$2
5943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5944 $as_echo_n "checking for $ac_word... " >&6; }
5945 if ${ac_cv_path_CUT+:} false; then :
5946   $as_echo_n "(cached) " >&6
5947 else
5948   case $CUT in
5949   [\\/]* | ?:[\\/]*)
5950   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5951   ;;
5952   *)
5953   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5954 for as_dir in $PATH
5955 do
5956   IFS=$as_save_IFS
5957   test -z "$as_dir" && as_dir=.
5958     for ac_exec_ext in '' $ac_executable_extensions; do
5959   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5960     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5961     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5962     break 2
5963   fi
5964 done
5965   done
5966 IFS=$as_save_IFS
5967 
5968   ;;
5969 esac
5970 fi
5971 CUT=$ac_cv_path_CUT
5972 if test -n "$CUT"; then
5973   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5974 $as_echo "$CUT" >&6; }
5975 else
5976   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5977 $as_echo "no" >&6; }
5978 fi
5979 
5980 
5981         if test "x$CUT" = x; then
5982           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5983         fi
5984       else
5985         # Otherwise we believe it is a complete path. Use it as it is.
5986         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5
5987 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;}
5988         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5
5989 $as_echo_n "checking for CUT... " >&6; }
5990         if test ! -x "$tool_specified"; then
5991           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5992 $as_echo "not found" >&6; }
5993           as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5
5994         fi
5995         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5996 $as_echo "$tool_specified" >&6; }
5997       fi
5998     fi
5999   fi
6000 
6001 
6002 
6003   if test "x$CUT" = x; then
6004     as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5
6005   fi
6006 
6007 
6008 
6009 
6010 
6011   # Publish this variable in the help.
6012 
6013 
6014   if test "x$DATE" = x; then
6015     # The variable is not set by user, try to locate tool using the code snippet
6016     for ac_prog in date
6017 do
6018   # Extract the first word of "$ac_prog", so it can be a program name with args.
6019 set dummy $ac_prog; ac_word=$2
6020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6021 $as_echo_n "checking for $ac_word... " >&6; }
6022 if ${ac_cv_path_DATE+:} false; then :
6023   $as_echo_n "(cached) " >&6
6024 else
6025   case $DATE in
6026   [\\/]* | ?:[\\/]*)
6027   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6028   ;;
6029   *)
6030   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6031 for as_dir in $PATH
6032 do
6033   IFS=$as_save_IFS
6034   test -z "$as_dir" && as_dir=.
6035     for ac_exec_ext in '' $ac_executable_extensions; do
6036   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6037     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6038     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6039     break 2
6040   fi
6041 done
6042   done
6043 IFS=$as_save_IFS
6044 
6045   ;;
6046 esac
6047 fi
6048 DATE=$ac_cv_path_DATE
6049 if test -n "$DATE"; then
6050   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6051 $as_echo "$DATE" >&6; }
6052 else
6053   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6054 $as_echo "no" >&6; }
6055 fi
6056 
6057 
6058   test -n "$DATE" && break
6059 done
6060 
6061   else
6062     # The variable is set, but is it from the command line or the environment?
6063 
6064     # Try to remove the string !DATE! from our list.
6065     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/}
6066     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6067       # If it failed, the variable was not from the command line. Ignore it,
6068       # but warn the user (except for BASH, which is always set by the calling BASH).
6069       if test "xDATE" != xBASH; then
6070         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5
6071 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;}
6072       fi
6073       # Try to locate tool using the code snippet
6074       for ac_prog in date
6075 do
6076   # Extract the first word of "$ac_prog", so it can be a program name with args.
6077 set dummy $ac_prog; ac_word=$2
6078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6079 $as_echo_n "checking for $ac_word... " >&6; }
6080 if ${ac_cv_path_DATE+:} false; then :
6081   $as_echo_n "(cached) " >&6
6082 else
6083   case $DATE in
6084   [\\/]* | ?:[\\/]*)
6085   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6086   ;;
6087   *)
6088   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6089 for as_dir in $PATH
6090 do
6091   IFS=$as_save_IFS
6092   test -z "$as_dir" && as_dir=.
6093     for ac_exec_ext in '' $ac_executable_extensions; do
6094   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6095     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6096     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6097     break 2
6098   fi
6099 done
6100   done
6101 IFS=$as_save_IFS
6102 
6103   ;;
6104 esac
6105 fi
6106 DATE=$ac_cv_path_DATE
6107 if test -n "$DATE"; then
6108   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6109 $as_echo "$DATE" >&6; }
6110 else
6111   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6112 $as_echo "no" >&6; }
6113 fi
6114 
6115 
6116   test -n "$DATE" && break
6117 done
6118 
6119     else
6120       # If it succeeded, then it was overridden by the user. We will use it
6121       # for the tool.
6122 
6123       # First remove it from the list of overridden variables, so we can test
6124       # for unknown variables in the end.
6125       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6126 
6127       # Check if the provided tool contains a complete path.
6128       tool_specified="$DATE"
6129       tool_basename="${tool_specified##*/}"
6130       if test "x$tool_basename" = "x$tool_specified"; then
6131         # A command without a complete path is provided, search $PATH.
6132         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5
6133 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;}
6134         # Extract the first word of "$tool_basename", so it can be a program name with args.
6135 set dummy $tool_basename; ac_word=$2
6136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6137 $as_echo_n "checking for $ac_word... " >&6; }
6138 if ${ac_cv_path_DATE+:} false; then :
6139   $as_echo_n "(cached) " >&6
6140 else
6141   case $DATE in
6142   [\\/]* | ?:[\\/]*)
6143   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6144   ;;
6145   *)
6146   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6147 for as_dir in $PATH
6148 do
6149   IFS=$as_save_IFS
6150   test -z "$as_dir" && as_dir=.
6151     for ac_exec_ext in '' $ac_executable_extensions; do
6152   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6153     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6154     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6155     break 2
6156   fi
6157 done
6158   done
6159 IFS=$as_save_IFS
6160 
6161   ;;
6162 esac
6163 fi
6164 DATE=$ac_cv_path_DATE
6165 if test -n "$DATE"; then
6166   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6167 $as_echo "$DATE" >&6; }
6168 else
6169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6170 $as_echo "no" >&6; }
6171 fi
6172 
6173 
6174         if test "x$DATE" = x; then
6175           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6176         fi
6177       else
6178         # Otherwise we believe it is a complete path. Use it as it is.
6179         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5
6180 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;}
6181         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5
6182 $as_echo_n "checking for DATE... " >&6; }
6183         if test ! -x "$tool_specified"; then
6184           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6185 $as_echo "not found" >&6; }
6186           as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5
6187         fi
6188         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6189 $as_echo "$tool_specified" >&6; }
6190       fi
6191     fi
6192   fi
6193 
6194 
6195 
6196   if test "x$DATE" = x; then
6197     as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5
6198   fi
6199 
6200 
6201 
6202 
6203 
6204   # Publish this variable in the help.
6205 
6206 
6207   if test "x$DIFF" = x; then
6208     # The variable is not set by user, try to locate tool using the code snippet
6209     for ac_prog in gdiff diff
6210 do
6211   # Extract the first word of "$ac_prog", so it can be a program name with args.
6212 set dummy $ac_prog; ac_word=$2
6213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6214 $as_echo_n "checking for $ac_word... " >&6; }
6215 if ${ac_cv_path_DIFF+:} false; then :
6216   $as_echo_n "(cached) " >&6
6217 else
6218   case $DIFF in
6219   [\\/]* | ?:[\\/]*)
6220   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6221   ;;
6222   *)
6223   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6224 for as_dir in $PATH
6225 do
6226   IFS=$as_save_IFS
6227   test -z "$as_dir" && as_dir=.
6228     for ac_exec_ext in '' $ac_executable_extensions; do
6229   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6230     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6231     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6232     break 2
6233   fi
6234 done
6235   done
6236 IFS=$as_save_IFS
6237 
6238   ;;
6239 esac
6240 fi
6241 DIFF=$ac_cv_path_DIFF
6242 if test -n "$DIFF"; then
6243   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6244 $as_echo "$DIFF" >&6; }
6245 else
6246   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6247 $as_echo "no" >&6; }
6248 fi
6249 
6250 
6251   test -n "$DIFF" && break
6252 done
6253 
6254   else
6255     # The variable is set, but is it from the command line or the environment?
6256 
6257     # Try to remove the string !DIFF! from our list.
6258     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/}
6259     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6260       # If it failed, the variable was not from the command line. Ignore it,
6261       # but warn the user (except for BASH, which is always set by the calling BASH).
6262       if test "xDIFF" != xBASH; then
6263         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5
6264 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;}
6265       fi
6266       # Try to locate tool using the code snippet
6267       for ac_prog in gdiff diff
6268 do
6269   # Extract the first word of "$ac_prog", so it can be a program name with args.
6270 set dummy $ac_prog; ac_word=$2
6271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6272 $as_echo_n "checking for $ac_word... " >&6; }
6273 if ${ac_cv_path_DIFF+:} false; then :
6274   $as_echo_n "(cached) " >&6
6275 else
6276   case $DIFF in
6277   [\\/]* | ?:[\\/]*)
6278   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6279   ;;
6280   *)
6281   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6282 for as_dir in $PATH
6283 do
6284   IFS=$as_save_IFS
6285   test -z "$as_dir" && as_dir=.
6286     for ac_exec_ext in '' $ac_executable_extensions; do
6287   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6288     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6289     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6290     break 2
6291   fi
6292 done
6293   done
6294 IFS=$as_save_IFS
6295 
6296   ;;
6297 esac
6298 fi
6299 DIFF=$ac_cv_path_DIFF
6300 if test -n "$DIFF"; then
6301   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6302 $as_echo "$DIFF" >&6; }
6303 else
6304   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6305 $as_echo "no" >&6; }
6306 fi
6307 
6308 
6309   test -n "$DIFF" && break
6310 done
6311 
6312     else
6313       # If it succeeded, then it was overridden by the user. We will use it
6314       # for the tool.
6315 
6316       # First remove it from the list of overridden variables, so we can test
6317       # for unknown variables in the end.
6318       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6319 
6320       # Check if the provided tool contains a complete path.
6321       tool_specified="$DIFF"
6322       tool_basename="${tool_specified##*/}"
6323       if test "x$tool_basename" = "x$tool_specified"; then
6324         # A command without a complete path is provided, search $PATH.
6325         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5
6326 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;}
6327         # Extract the first word of "$tool_basename", so it can be a program name with args.
6328 set dummy $tool_basename; ac_word=$2
6329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6330 $as_echo_n "checking for $ac_word... " >&6; }
6331 if ${ac_cv_path_DIFF+:} false; then :
6332   $as_echo_n "(cached) " >&6
6333 else
6334   case $DIFF in
6335   [\\/]* | ?:[\\/]*)
6336   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6337   ;;
6338   *)
6339   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6340 for as_dir in $PATH
6341 do
6342   IFS=$as_save_IFS
6343   test -z "$as_dir" && as_dir=.
6344     for ac_exec_ext in '' $ac_executable_extensions; do
6345   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6346     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6347     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6348     break 2
6349   fi
6350 done
6351   done
6352 IFS=$as_save_IFS
6353 
6354   ;;
6355 esac
6356 fi
6357 DIFF=$ac_cv_path_DIFF
6358 if test -n "$DIFF"; then
6359   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6360 $as_echo "$DIFF" >&6; }
6361 else
6362   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6363 $as_echo "no" >&6; }
6364 fi
6365 
6366 
6367         if test "x$DIFF" = x; then
6368           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6369         fi
6370       else
6371         # Otherwise we believe it is a complete path. Use it as it is.
6372         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5
6373 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;}
6374         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5
6375 $as_echo_n "checking for DIFF... " >&6; }
6376         if test ! -x "$tool_specified"; then
6377           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6378 $as_echo "not found" >&6; }
6379           as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5
6380         fi
6381         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6382 $as_echo "$tool_specified" >&6; }
6383       fi
6384     fi
6385   fi
6386 
6387 
6388 
6389   if test "x$DIFF" = x; then
6390     as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5
6391   fi
6392 
6393 
6394 
6395 
6396 
6397   # Publish this variable in the help.
6398 
6399 
6400   if test "x$DIRNAME" = x; then
6401     # The variable is not set by user, try to locate tool using the code snippet
6402     for ac_prog in dirname
6403 do
6404   # Extract the first word of "$ac_prog", so it can be a program name with args.
6405 set dummy $ac_prog; ac_word=$2
6406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6407 $as_echo_n "checking for $ac_word... " >&6; }
6408 if ${ac_cv_path_DIRNAME+:} false; then :
6409   $as_echo_n "(cached) " >&6
6410 else
6411   case $DIRNAME in
6412   [\\/]* | ?:[\\/]*)
6413   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6414   ;;
6415   *)
6416   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6417 for as_dir in $PATH
6418 do
6419   IFS=$as_save_IFS
6420   test -z "$as_dir" && as_dir=.
6421     for ac_exec_ext in '' $ac_executable_extensions; do
6422   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6423     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6424     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6425     break 2
6426   fi
6427 done
6428   done
6429 IFS=$as_save_IFS
6430 
6431   ;;
6432 esac
6433 fi
6434 DIRNAME=$ac_cv_path_DIRNAME
6435 if test -n "$DIRNAME"; then
6436   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6437 $as_echo "$DIRNAME" >&6; }
6438 else
6439   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6440 $as_echo "no" >&6; }
6441 fi
6442 
6443 
6444   test -n "$DIRNAME" && break
6445 done
6446 
6447   else
6448     # The variable is set, but is it from the command line or the environment?
6449 
6450     # Try to remove the string !DIRNAME! from our list.
6451     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/}
6452     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6453       # If it failed, the variable was not from the command line. Ignore it,
6454       # but warn the user (except for BASH, which is always set by the calling BASH).
6455       if test "xDIRNAME" != xBASH; then
6456         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5
6457 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;}
6458       fi
6459       # Try to locate tool using the code snippet
6460       for ac_prog in dirname
6461 do
6462   # Extract the first word of "$ac_prog", so it can be a program name with args.
6463 set dummy $ac_prog; ac_word=$2
6464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6465 $as_echo_n "checking for $ac_word... " >&6; }
6466 if ${ac_cv_path_DIRNAME+:} false; then :
6467   $as_echo_n "(cached) " >&6
6468 else
6469   case $DIRNAME in
6470   [\\/]* | ?:[\\/]*)
6471   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6472   ;;
6473   *)
6474   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6475 for as_dir in $PATH
6476 do
6477   IFS=$as_save_IFS
6478   test -z "$as_dir" && as_dir=.
6479     for ac_exec_ext in '' $ac_executable_extensions; do
6480   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6481     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6482     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6483     break 2
6484   fi
6485 done
6486   done
6487 IFS=$as_save_IFS
6488 
6489   ;;
6490 esac
6491 fi
6492 DIRNAME=$ac_cv_path_DIRNAME
6493 if test -n "$DIRNAME"; then
6494   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6495 $as_echo "$DIRNAME" >&6; }
6496 else
6497   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6498 $as_echo "no" >&6; }
6499 fi
6500 
6501 
6502   test -n "$DIRNAME" && break
6503 done
6504 
6505     else
6506       # If it succeeded, then it was overridden by the user. We will use it
6507       # for the tool.
6508 
6509       # First remove it from the list of overridden variables, so we can test
6510       # for unknown variables in the end.
6511       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6512 
6513       # Check if the provided tool contains a complete path.
6514       tool_specified="$DIRNAME"
6515       tool_basename="${tool_specified##*/}"
6516       if test "x$tool_basename" = "x$tool_specified"; then
6517         # A command without a complete path is provided, search $PATH.
6518         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5
6519 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;}
6520         # Extract the first word of "$tool_basename", so it can be a program name with args.
6521 set dummy $tool_basename; ac_word=$2
6522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6523 $as_echo_n "checking for $ac_word... " >&6; }
6524 if ${ac_cv_path_DIRNAME+:} false; then :
6525   $as_echo_n "(cached) " >&6
6526 else
6527   case $DIRNAME in
6528   [\\/]* | ?:[\\/]*)
6529   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6530   ;;
6531   *)
6532   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6533 for as_dir in $PATH
6534 do
6535   IFS=$as_save_IFS
6536   test -z "$as_dir" && as_dir=.
6537     for ac_exec_ext in '' $ac_executable_extensions; do
6538   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6539     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6540     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6541     break 2
6542   fi
6543 done
6544   done
6545 IFS=$as_save_IFS
6546 
6547   ;;
6548 esac
6549 fi
6550 DIRNAME=$ac_cv_path_DIRNAME
6551 if test -n "$DIRNAME"; then
6552   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6553 $as_echo "$DIRNAME" >&6; }
6554 else
6555   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6556 $as_echo "no" >&6; }
6557 fi
6558 
6559 
6560         if test "x$DIRNAME" = x; then
6561           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6562         fi
6563       else
6564         # Otherwise we believe it is a complete path. Use it as it is.
6565         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5
6566 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;}
6567         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5
6568 $as_echo_n "checking for DIRNAME... " >&6; }
6569         if test ! -x "$tool_specified"; then
6570           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6571 $as_echo "not found" >&6; }
6572           as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
6573         fi
6574         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6575 $as_echo "$tool_specified" >&6; }
6576       fi
6577     fi
6578   fi
6579 
6580 
6581 
6582   if test "x$DIRNAME" = x; then
6583     as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5
6584   fi
6585 
6586 
6587 
6588 
6589 
6590   # Publish this variable in the help.
6591 
6592 
6593   if test "x$ECHO" = x; then
6594     # The variable is not set by user, try to locate tool using the code snippet
6595     for ac_prog in echo
6596 do
6597   # Extract the first word of "$ac_prog", so it can be a program name with args.
6598 set dummy $ac_prog; ac_word=$2
6599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6600 $as_echo_n "checking for $ac_word... " >&6; }
6601 if ${ac_cv_path_ECHO+:} false; then :
6602   $as_echo_n "(cached) " >&6
6603 else
6604   case $ECHO in
6605   [\\/]* | ?:[\\/]*)
6606   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6607   ;;
6608   *)
6609   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6610 for as_dir in $PATH
6611 do
6612   IFS=$as_save_IFS
6613   test -z "$as_dir" && as_dir=.
6614     for ac_exec_ext in '' $ac_executable_extensions; do
6615   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6616     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6617     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6618     break 2
6619   fi
6620 done
6621   done
6622 IFS=$as_save_IFS
6623 
6624   ;;
6625 esac
6626 fi
6627 ECHO=$ac_cv_path_ECHO
6628 if test -n "$ECHO"; then
6629   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6630 $as_echo "$ECHO" >&6; }
6631 else
6632   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6633 $as_echo "no" >&6; }
6634 fi
6635 
6636 
6637   test -n "$ECHO" && break
6638 done
6639 
6640   else
6641     # The variable is set, but is it from the command line or the environment?
6642 
6643     # Try to remove the string !ECHO! from our list.
6644     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/}
6645     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6646       # If it failed, the variable was not from the command line. Ignore it,
6647       # but warn the user (except for BASH, which is always set by the calling BASH).
6648       if test "xECHO" != xBASH; then
6649         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5
6650 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;}
6651       fi
6652       # Try to locate tool using the code snippet
6653       for ac_prog in echo
6654 do
6655   # Extract the first word of "$ac_prog", so it can be a program name with args.
6656 set dummy $ac_prog; ac_word=$2
6657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6658 $as_echo_n "checking for $ac_word... " >&6; }
6659 if ${ac_cv_path_ECHO+:} false; then :
6660   $as_echo_n "(cached) " >&6
6661 else
6662   case $ECHO in
6663   [\\/]* | ?:[\\/]*)
6664   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6665   ;;
6666   *)
6667   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6668 for as_dir in $PATH
6669 do
6670   IFS=$as_save_IFS
6671   test -z "$as_dir" && as_dir=.
6672     for ac_exec_ext in '' $ac_executable_extensions; do
6673   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6674     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6675     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6676     break 2
6677   fi
6678 done
6679   done
6680 IFS=$as_save_IFS
6681 
6682   ;;
6683 esac
6684 fi
6685 ECHO=$ac_cv_path_ECHO
6686 if test -n "$ECHO"; then
6687   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6688 $as_echo "$ECHO" >&6; }
6689 else
6690   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6691 $as_echo "no" >&6; }
6692 fi
6693 
6694 
6695   test -n "$ECHO" && break
6696 done
6697 
6698     else
6699       # If it succeeded, then it was overridden by the user. We will use it
6700       # for the tool.
6701 
6702       # First remove it from the list of overridden variables, so we can test
6703       # for unknown variables in the end.
6704       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6705 
6706       # Check if the provided tool contains a complete path.
6707       tool_specified="$ECHO"
6708       tool_basename="${tool_specified##*/}"
6709       if test "x$tool_basename" = "x$tool_specified"; then
6710         # A command without a complete path is provided, search $PATH.
6711         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5
6712 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;}
6713         # Extract the first word of "$tool_basename", so it can be a program name with args.
6714 set dummy $tool_basename; ac_word=$2
6715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6716 $as_echo_n "checking for $ac_word... " >&6; }
6717 if ${ac_cv_path_ECHO+:} false; then :
6718   $as_echo_n "(cached) " >&6
6719 else
6720   case $ECHO in
6721   [\\/]* | ?:[\\/]*)
6722   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6723   ;;
6724   *)
6725   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6726 for as_dir in $PATH
6727 do
6728   IFS=$as_save_IFS
6729   test -z "$as_dir" && as_dir=.
6730     for ac_exec_ext in '' $ac_executable_extensions; do
6731   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6732     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6733     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6734     break 2
6735   fi
6736 done
6737   done
6738 IFS=$as_save_IFS
6739 
6740   ;;
6741 esac
6742 fi
6743 ECHO=$ac_cv_path_ECHO
6744 if test -n "$ECHO"; then
6745   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6746 $as_echo "$ECHO" >&6; }
6747 else
6748   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6749 $as_echo "no" >&6; }
6750 fi
6751 
6752 
6753         if test "x$ECHO" = x; then
6754           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6755         fi
6756       else
6757         # Otherwise we believe it is a complete path. Use it as it is.
6758         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5
6759 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;}
6760         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5
6761 $as_echo_n "checking for ECHO... " >&6; }
6762         if test ! -x "$tool_specified"; then
6763           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6764 $as_echo "not found" >&6; }
6765           as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5
6766         fi
6767         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6768 $as_echo "$tool_specified" >&6; }
6769       fi
6770     fi
6771   fi
6772 
6773 
6774 
6775   if test "x$ECHO" = x; then
6776     as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5
6777   fi
6778 
6779 
6780 
6781 
6782 
6783   # Publish this variable in the help.
6784 
6785 
6786   if test "x$EXPR" = x; then
6787     # The variable is not set by user, try to locate tool using the code snippet
6788     for ac_prog in expr
6789 do
6790   # Extract the first word of "$ac_prog", so it can be a program name with args.
6791 set dummy $ac_prog; ac_word=$2
6792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6793 $as_echo_n "checking for $ac_word... " >&6; }
6794 if ${ac_cv_path_EXPR+:} false; then :
6795   $as_echo_n "(cached) " >&6
6796 else
6797   case $EXPR in
6798   [\\/]* | ?:[\\/]*)
6799   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6800   ;;
6801   *)
6802   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6803 for as_dir in $PATH
6804 do
6805   IFS=$as_save_IFS
6806   test -z "$as_dir" && as_dir=.
6807     for ac_exec_ext in '' $ac_executable_extensions; do
6808   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6809     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6810     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6811     break 2
6812   fi
6813 done
6814   done
6815 IFS=$as_save_IFS
6816 
6817   ;;
6818 esac
6819 fi
6820 EXPR=$ac_cv_path_EXPR
6821 if test -n "$EXPR"; then
6822   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6823 $as_echo "$EXPR" >&6; }
6824 else
6825   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6826 $as_echo "no" >&6; }
6827 fi
6828 
6829 
6830   test -n "$EXPR" && break
6831 done
6832 
6833   else
6834     # The variable is set, but is it from the command line or the environment?
6835 
6836     # Try to remove the string !EXPR! from our list.
6837     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/}
6838     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6839       # If it failed, the variable was not from the command line. Ignore it,
6840       # but warn the user (except for BASH, which is always set by the calling BASH).
6841       if test "xEXPR" != xBASH; then
6842         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5
6843 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;}
6844       fi
6845       # Try to locate tool using the code snippet
6846       for ac_prog in expr
6847 do
6848   # Extract the first word of "$ac_prog", so it can be a program name with args.
6849 set dummy $ac_prog; ac_word=$2
6850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6851 $as_echo_n "checking for $ac_word... " >&6; }
6852 if ${ac_cv_path_EXPR+:} false; then :
6853   $as_echo_n "(cached) " >&6
6854 else
6855   case $EXPR in
6856   [\\/]* | ?:[\\/]*)
6857   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6858   ;;
6859   *)
6860   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6861 for as_dir in $PATH
6862 do
6863   IFS=$as_save_IFS
6864   test -z "$as_dir" && as_dir=.
6865     for ac_exec_ext in '' $ac_executable_extensions; do
6866   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6867     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6868     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6869     break 2
6870   fi
6871 done
6872   done
6873 IFS=$as_save_IFS
6874 
6875   ;;
6876 esac
6877 fi
6878 EXPR=$ac_cv_path_EXPR
6879 if test -n "$EXPR"; then
6880   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6881 $as_echo "$EXPR" >&6; }
6882 else
6883   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6884 $as_echo "no" >&6; }
6885 fi
6886 
6887 
6888   test -n "$EXPR" && break
6889 done
6890 
6891     else
6892       # If it succeeded, then it was overridden by the user. We will use it
6893       # for the tool.
6894 
6895       # First remove it from the list of overridden variables, so we can test
6896       # for unknown variables in the end.
6897       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6898 
6899       # Check if the provided tool contains a complete path.
6900       tool_specified="$EXPR"
6901       tool_basename="${tool_specified##*/}"
6902       if test "x$tool_basename" = "x$tool_specified"; then
6903         # A command without a complete path is provided, search $PATH.
6904         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5
6905 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;}
6906         # Extract the first word of "$tool_basename", so it can be a program name with args.
6907 set dummy $tool_basename; ac_word=$2
6908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6909 $as_echo_n "checking for $ac_word... " >&6; }
6910 if ${ac_cv_path_EXPR+:} false; then :
6911   $as_echo_n "(cached) " >&6
6912 else
6913   case $EXPR in
6914   [\\/]* | ?:[\\/]*)
6915   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6916   ;;
6917   *)
6918   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6919 for as_dir in $PATH
6920 do
6921   IFS=$as_save_IFS
6922   test -z "$as_dir" && as_dir=.
6923     for ac_exec_ext in '' $ac_executable_extensions; do
6924   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6925     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6926     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6927     break 2
6928   fi
6929 done
6930   done
6931 IFS=$as_save_IFS
6932 
6933   ;;
6934 esac
6935 fi
6936 EXPR=$ac_cv_path_EXPR
6937 if test -n "$EXPR"; then
6938   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6939 $as_echo "$EXPR" >&6; }
6940 else
6941   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6942 $as_echo "no" >&6; }
6943 fi
6944 
6945 
6946         if test "x$EXPR" = x; then
6947           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6948         fi
6949       else
6950         # Otherwise we believe it is a complete path. Use it as it is.
6951         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5
6952 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;}
6953         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5
6954 $as_echo_n "checking for EXPR... " >&6; }
6955         if test ! -x "$tool_specified"; then
6956           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6957 $as_echo "not found" >&6; }
6958           as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5
6959         fi
6960         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6961 $as_echo "$tool_specified" >&6; }
6962       fi
6963     fi
6964   fi
6965 
6966 
6967 
6968   if test "x$EXPR" = x; then
6969     as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5
6970   fi
6971 
6972 
6973 
6974 
6975 
6976   # Publish this variable in the help.
6977 
6978 
6979   if test "x$FILE" = x; then
6980     # The variable is not set by user, try to locate tool using the code snippet
6981     for ac_prog in file
6982 do
6983   # Extract the first word of "$ac_prog", so it can be a program name with args.
6984 set dummy $ac_prog; ac_word=$2
6985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6986 $as_echo_n "checking for $ac_word... " >&6; }
6987 if ${ac_cv_path_FILE+:} false; then :
6988   $as_echo_n "(cached) " >&6
6989 else
6990   case $FILE in
6991   [\\/]* | ?:[\\/]*)
6992   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6993   ;;
6994   *)
6995   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6996 for as_dir in $PATH
6997 do
6998   IFS=$as_save_IFS
6999   test -z "$as_dir" && as_dir=.
7000     for ac_exec_ext in '' $ac_executable_extensions; do
7001   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7002     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7003     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7004     break 2
7005   fi
7006 done
7007   done
7008 IFS=$as_save_IFS
7009 
7010   ;;
7011 esac
7012 fi
7013 FILE=$ac_cv_path_FILE
7014 if test -n "$FILE"; then
7015   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7016 $as_echo "$FILE" >&6; }
7017 else
7018   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7019 $as_echo "no" >&6; }
7020 fi
7021 
7022 
7023   test -n "$FILE" && break
7024 done
7025 
7026   else
7027     # The variable is set, but is it from the command line or the environment?
7028 
7029     # Try to remove the string !FILE! from our list.
7030     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/}
7031     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7032       # If it failed, the variable was not from the command line. Ignore it,
7033       # but warn the user (except for BASH, which is always set by the calling BASH).
7034       if test "xFILE" != xBASH; then
7035         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5
7036 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;}
7037       fi
7038       # Try to locate tool using the code snippet
7039       for ac_prog in file
7040 do
7041   # Extract the first word of "$ac_prog", so it can be a program name with args.
7042 set dummy $ac_prog; ac_word=$2
7043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7044 $as_echo_n "checking for $ac_word... " >&6; }
7045 if ${ac_cv_path_FILE+:} false; then :
7046   $as_echo_n "(cached) " >&6
7047 else
7048   case $FILE in
7049   [\\/]* | ?:[\\/]*)
7050   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7051   ;;
7052   *)
7053   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7054 for as_dir in $PATH
7055 do
7056   IFS=$as_save_IFS
7057   test -z "$as_dir" && as_dir=.
7058     for ac_exec_ext in '' $ac_executable_extensions; do
7059   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7060     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7061     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7062     break 2
7063   fi
7064 done
7065   done
7066 IFS=$as_save_IFS
7067 
7068   ;;
7069 esac
7070 fi
7071 FILE=$ac_cv_path_FILE
7072 if test -n "$FILE"; then
7073   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7074 $as_echo "$FILE" >&6; }
7075 else
7076   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7077 $as_echo "no" >&6; }
7078 fi
7079 
7080 
7081   test -n "$FILE" && break
7082 done
7083 
7084     else
7085       # If it succeeded, then it was overridden by the user. We will use it
7086       # for the tool.
7087 
7088       # First remove it from the list of overridden variables, so we can test
7089       # for unknown variables in the end.
7090       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7091 
7092       # Check if the provided tool contains a complete path.
7093       tool_specified="$FILE"
7094       tool_basename="${tool_specified##*/}"
7095       if test "x$tool_basename" = "x$tool_specified"; then
7096         # A command without a complete path is provided, search $PATH.
7097         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5
7098 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;}
7099         # Extract the first word of "$tool_basename", so it can be a program name with args.
7100 set dummy $tool_basename; ac_word=$2
7101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7102 $as_echo_n "checking for $ac_word... " >&6; }
7103 if ${ac_cv_path_FILE+:} false; then :
7104   $as_echo_n "(cached) " >&6
7105 else
7106   case $FILE in
7107   [\\/]* | ?:[\\/]*)
7108   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7109   ;;
7110   *)
7111   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7112 for as_dir in $PATH
7113 do
7114   IFS=$as_save_IFS
7115   test -z "$as_dir" && as_dir=.
7116     for ac_exec_ext in '' $ac_executable_extensions; do
7117   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7118     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7119     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7120     break 2
7121   fi
7122 done
7123   done
7124 IFS=$as_save_IFS
7125 
7126   ;;
7127 esac
7128 fi
7129 FILE=$ac_cv_path_FILE
7130 if test -n "$FILE"; then
7131   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7132 $as_echo "$FILE" >&6; }
7133 else
7134   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7135 $as_echo "no" >&6; }
7136 fi
7137 
7138 
7139         if test "x$FILE" = x; then
7140           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7141         fi
7142       else
7143         # Otherwise we believe it is a complete path. Use it as it is.
7144         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5
7145 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;}
7146         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5
7147 $as_echo_n "checking for FILE... " >&6; }
7148         if test ! -x "$tool_specified"; then
7149           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7150 $as_echo "not found" >&6; }
7151           as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5
7152         fi
7153         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7154 $as_echo "$tool_specified" >&6; }
7155       fi
7156     fi
7157   fi
7158 
7159 
7160 
7161   if test "x$FILE" = x; then
7162     as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5
7163   fi
7164 
7165 
7166 
7167 
7168 
7169   # Publish this variable in the help.
7170 
7171 
7172   if test "x$FIND" = x; then
7173     # The variable is not set by user, try to locate tool using the code snippet
7174     for ac_prog in find
7175 do
7176   # Extract the first word of "$ac_prog", so it can be a program name with args.
7177 set dummy $ac_prog; ac_word=$2
7178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7179 $as_echo_n "checking for $ac_word... " >&6; }
7180 if ${ac_cv_path_FIND+:} false; then :
7181   $as_echo_n "(cached) " >&6
7182 else
7183   case $FIND in
7184   [\\/]* | ?:[\\/]*)
7185   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7186   ;;
7187   *)
7188   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7189 for as_dir in $PATH
7190 do
7191   IFS=$as_save_IFS
7192   test -z "$as_dir" && as_dir=.
7193     for ac_exec_ext in '' $ac_executable_extensions; do
7194   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7195     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7196     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7197     break 2
7198   fi
7199 done
7200   done
7201 IFS=$as_save_IFS
7202 
7203   ;;
7204 esac
7205 fi
7206 FIND=$ac_cv_path_FIND
7207 if test -n "$FIND"; then
7208   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7209 $as_echo "$FIND" >&6; }
7210 else
7211   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7212 $as_echo "no" >&6; }
7213 fi
7214 
7215 
7216   test -n "$FIND" && break
7217 done
7218 
7219   else
7220     # The variable is set, but is it from the command line or the environment?
7221 
7222     # Try to remove the string !FIND! from our list.
7223     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/}
7224     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7225       # If it failed, the variable was not from the command line. Ignore it,
7226       # but warn the user (except for BASH, which is always set by the calling BASH).
7227       if test "xFIND" != xBASH; then
7228         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5
7229 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;}
7230       fi
7231       # Try to locate tool using the code snippet
7232       for ac_prog in find
7233 do
7234   # Extract the first word of "$ac_prog", so it can be a program name with args.
7235 set dummy $ac_prog; ac_word=$2
7236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7237 $as_echo_n "checking for $ac_word... " >&6; }
7238 if ${ac_cv_path_FIND+:} false; then :
7239   $as_echo_n "(cached) " >&6
7240 else
7241   case $FIND in
7242   [\\/]* | ?:[\\/]*)
7243   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7244   ;;
7245   *)
7246   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7247 for as_dir in $PATH
7248 do
7249   IFS=$as_save_IFS
7250   test -z "$as_dir" && as_dir=.
7251     for ac_exec_ext in '' $ac_executable_extensions; do
7252   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7253     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7254     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7255     break 2
7256   fi
7257 done
7258   done
7259 IFS=$as_save_IFS
7260 
7261   ;;
7262 esac
7263 fi
7264 FIND=$ac_cv_path_FIND
7265 if test -n "$FIND"; then
7266   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7267 $as_echo "$FIND" >&6; }
7268 else
7269   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7270 $as_echo "no" >&6; }
7271 fi
7272 
7273 
7274   test -n "$FIND" && break
7275 done
7276 
7277     else
7278       # If it succeeded, then it was overridden by the user. We will use it
7279       # for the tool.
7280 
7281       # First remove it from the list of overridden variables, so we can test
7282       # for unknown variables in the end.
7283       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7284 
7285       # Check if the provided tool contains a complete path.
7286       tool_specified="$FIND"
7287       tool_basename="${tool_specified##*/}"
7288       if test "x$tool_basename" = "x$tool_specified"; then
7289         # A command without a complete path is provided, search $PATH.
7290         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5
7291 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;}
7292         # Extract the first word of "$tool_basename", so it can be a program name with args.
7293 set dummy $tool_basename; ac_word=$2
7294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7295 $as_echo_n "checking for $ac_word... " >&6; }
7296 if ${ac_cv_path_FIND+:} false; then :
7297   $as_echo_n "(cached) " >&6
7298 else
7299   case $FIND in
7300   [\\/]* | ?:[\\/]*)
7301   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7302   ;;
7303   *)
7304   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7305 for as_dir in $PATH
7306 do
7307   IFS=$as_save_IFS
7308   test -z "$as_dir" && as_dir=.
7309     for ac_exec_ext in '' $ac_executable_extensions; do
7310   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7311     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7312     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7313     break 2
7314   fi
7315 done
7316   done
7317 IFS=$as_save_IFS
7318 
7319   ;;
7320 esac
7321 fi
7322 FIND=$ac_cv_path_FIND
7323 if test -n "$FIND"; then
7324   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7325 $as_echo "$FIND" >&6; }
7326 else
7327   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7328 $as_echo "no" >&6; }
7329 fi
7330 
7331 
7332         if test "x$FIND" = x; then
7333           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7334         fi
7335       else
7336         # Otherwise we believe it is a complete path. Use it as it is.
7337         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5
7338 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;}
7339         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5
7340 $as_echo_n "checking for FIND... " >&6; }
7341         if test ! -x "$tool_specified"; then
7342           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7343 $as_echo "not found" >&6; }
7344           as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5
7345         fi
7346         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7347 $as_echo "$tool_specified" >&6; }
7348       fi
7349     fi
7350   fi
7351 
7352 
7353 
7354   if test "x$FIND" = x; then
7355     as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5
7356   fi
7357 
7358 
7359 
7360 
7361 
7362   # Publish this variable in the help.
7363 
7364 
7365   if test "x$HEAD" = x; then
7366     # The variable is not set by user, try to locate tool using the code snippet
7367     for ac_prog in head
7368 do
7369   # Extract the first word of "$ac_prog", so it can be a program name with args.
7370 set dummy $ac_prog; ac_word=$2
7371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7372 $as_echo_n "checking for $ac_word... " >&6; }
7373 if ${ac_cv_path_HEAD+:} false; then :
7374   $as_echo_n "(cached) " >&6
7375 else
7376   case $HEAD in
7377   [\\/]* | ?:[\\/]*)
7378   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7379   ;;
7380   *)
7381   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7382 for as_dir in $PATH
7383 do
7384   IFS=$as_save_IFS
7385   test -z "$as_dir" && as_dir=.
7386     for ac_exec_ext in '' $ac_executable_extensions; do
7387   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7388     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7389     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7390     break 2
7391   fi
7392 done
7393   done
7394 IFS=$as_save_IFS
7395 
7396   ;;
7397 esac
7398 fi
7399 HEAD=$ac_cv_path_HEAD
7400 if test -n "$HEAD"; then
7401   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7402 $as_echo "$HEAD" >&6; }
7403 else
7404   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7405 $as_echo "no" >&6; }
7406 fi
7407 
7408 
7409   test -n "$HEAD" && break
7410 done
7411 
7412   else
7413     # The variable is set, but is it from the command line or the environment?
7414 
7415     # Try to remove the string !HEAD! from our list.
7416     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/}
7417     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7418       # If it failed, the variable was not from the command line. Ignore it,
7419       # but warn the user (except for BASH, which is always set by the calling BASH).
7420       if test "xHEAD" != xBASH; then
7421         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5
7422 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;}
7423       fi
7424       # Try to locate tool using the code snippet
7425       for ac_prog in head
7426 do
7427   # Extract the first word of "$ac_prog", so it can be a program name with args.
7428 set dummy $ac_prog; ac_word=$2
7429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7430 $as_echo_n "checking for $ac_word... " >&6; }
7431 if ${ac_cv_path_HEAD+:} false; then :
7432   $as_echo_n "(cached) " >&6
7433 else
7434   case $HEAD in
7435   [\\/]* | ?:[\\/]*)
7436   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7437   ;;
7438   *)
7439   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7440 for as_dir in $PATH
7441 do
7442   IFS=$as_save_IFS
7443   test -z "$as_dir" && as_dir=.
7444     for ac_exec_ext in '' $ac_executable_extensions; do
7445   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7446     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7447     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7448     break 2
7449   fi
7450 done
7451   done
7452 IFS=$as_save_IFS
7453 
7454   ;;
7455 esac
7456 fi
7457 HEAD=$ac_cv_path_HEAD
7458 if test -n "$HEAD"; then
7459   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7460 $as_echo "$HEAD" >&6; }
7461 else
7462   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7463 $as_echo "no" >&6; }
7464 fi
7465 
7466 
7467   test -n "$HEAD" && break
7468 done
7469 
7470     else
7471       # If it succeeded, then it was overridden by the user. We will use it
7472       # for the tool.
7473 
7474       # First remove it from the list of overridden variables, so we can test
7475       # for unknown variables in the end.
7476       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7477 
7478       # Check if the provided tool contains a complete path.
7479       tool_specified="$HEAD"
7480       tool_basename="${tool_specified##*/}"
7481       if test "x$tool_basename" = "x$tool_specified"; then
7482         # A command without a complete path is provided, search $PATH.
7483         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5
7484 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;}
7485         # Extract the first word of "$tool_basename", so it can be a program name with args.
7486 set dummy $tool_basename; ac_word=$2
7487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7488 $as_echo_n "checking for $ac_word... " >&6; }
7489 if ${ac_cv_path_HEAD+:} false; then :
7490   $as_echo_n "(cached) " >&6
7491 else
7492   case $HEAD in
7493   [\\/]* | ?:[\\/]*)
7494   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7495   ;;
7496   *)
7497   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7498 for as_dir in $PATH
7499 do
7500   IFS=$as_save_IFS
7501   test -z "$as_dir" && as_dir=.
7502     for ac_exec_ext in '' $ac_executable_extensions; do
7503   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7504     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7505     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7506     break 2
7507   fi
7508 done
7509   done
7510 IFS=$as_save_IFS
7511 
7512   ;;
7513 esac
7514 fi
7515 HEAD=$ac_cv_path_HEAD
7516 if test -n "$HEAD"; then
7517   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7518 $as_echo "$HEAD" >&6; }
7519 else
7520   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7521 $as_echo "no" >&6; }
7522 fi
7523 
7524 
7525         if test "x$HEAD" = x; then
7526           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7527         fi
7528       else
7529         # Otherwise we believe it is a complete path. Use it as it is.
7530         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5
7531 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;}
7532         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5
7533 $as_echo_n "checking for HEAD... " >&6; }
7534         if test ! -x "$tool_specified"; then
7535           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7536 $as_echo "not found" >&6; }
7537           as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5
7538         fi
7539         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7540 $as_echo "$tool_specified" >&6; }
7541       fi
7542     fi
7543   fi
7544 
7545 
7546 
7547   if test "x$HEAD" = x; then
7548     as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5
7549   fi
7550 
7551 
7552 
7553 
7554 
7555   # Publish this variable in the help.
7556 
7557 
7558   if test "x$LN" = x; then
7559     # The variable is not set by user, try to locate tool using the code snippet
7560     for ac_prog in ln
7561 do
7562   # Extract the first word of "$ac_prog", so it can be a program name with args.
7563 set dummy $ac_prog; ac_word=$2
7564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7565 $as_echo_n "checking for $ac_word... " >&6; }
7566 if ${ac_cv_path_LN+:} false; then :
7567   $as_echo_n "(cached) " >&6
7568 else
7569   case $LN in
7570   [\\/]* | ?:[\\/]*)
7571   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7572   ;;
7573   *)
7574   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7575 for as_dir in $PATH
7576 do
7577   IFS=$as_save_IFS
7578   test -z "$as_dir" && as_dir=.
7579     for ac_exec_ext in '' $ac_executable_extensions; do
7580   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7581     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7582     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7583     break 2
7584   fi
7585 done
7586   done
7587 IFS=$as_save_IFS
7588 
7589   ;;
7590 esac
7591 fi
7592 LN=$ac_cv_path_LN
7593 if test -n "$LN"; then
7594   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7595 $as_echo "$LN" >&6; }
7596 else
7597   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7598 $as_echo "no" >&6; }
7599 fi
7600 
7601 
7602   test -n "$LN" && break
7603 done
7604 
7605   else
7606     # The variable is set, but is it from the command line or the environment?
7607 
7608     # Try to remove the string !LN! from our list.
7609     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/}
7610     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7611       # If it failed, the variable was not from the command line. Ignore it,
7612       # but warn the user (except for BASH, which is always set by the calling BASH).
7613       if test "xLN" != xBASH; then
7614         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5
7615 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;}
7616       fi
7617       # Try to locate tool using the code snippet
7618       for ac_prog in ln
7619 do
7620   # Extract the first word of "$ac_prog", so it can be a program name with args.
7621 set dummy $ac_prog; ac_word=$2
7622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7623 $as_echo_n "checking for $ac_word... " >&6; }
7624 if ${ac_cv_path_LN+:} false; then :
7625   $as_echo_n "(cached) " >&6
7626 else
7627   case $LN in
7628   [\\/]* | ?:[\\/]*)
7629   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7630   ;;
7631   *)
7632   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7633 for as_dir in $PATH
7634 do
7635   IFS=$as_save_IFS
7636   test -z "$as_dir" && as_dir=.
7637     for ac_exec_ext in '' $ac_executable_extensions; do
7638   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7639     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7640     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7641     break 2
7642   fi
7643 done
7644   done
7645 IFS=$as_save_IFS
7646 
7647   ;;
7648 esac
7649 fi
7650 LN=$ac_cv_path_LN
7651 if test -n "$LN"; then
7652   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7653 $as_echo "$LN" >&6; }
7654 else
7655   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7656 $as_echo "no" >&6; }
7657 fi
7658 
7659 
7660   test -n "$LN" && break
7661 done
7662 
7663     else
7664       # If it succeeded, then it was overridden by the user. We will use it
7665       # for the tool.
7666 
7667       # First remove it from the list of overridden variables, so we can test
7668       # for unknown variables in the end.
7669       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7670 
7671       # Check if the provided tool contains a complete path.
7672       tool_specified="$LN"
7673       tool_basename="${tool_specified##*/}"
7674       if test "x$tool_basename" = "x$tool_specified"; then
7675         # A command without a complete path is provided, search $PATH.
7676         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5
7677 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;}
7678         # Extract the first word of "$tool_basename", so it can be a program name with args.
7679 set dummy $tool_basename; ac_word=$2
7680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7681 $as_echo_n "checking for $ac_word... " >&6; }
7682 if ${ac_cv_path_LN+:} false; then :
7683   $as_echo_n "(cached) " >&6
7684 else
7685   case $LN in
7686   [\\/]* | ?:[\\/]*)
7687   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7688   ;;
7689   *)
7690   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7691 for as_dir in $PATH
7692 do
7693   IFS=$as_save_IFS
7694   test -z "$as_dir" && as_dir=.
7695     for ac_exec_ext in '' $ac_executable_extensions; do
7696   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7697     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7698     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7699     break 2
7700   fi
7701 done
7702   done
7703 IFS=$as_save_IFS
7704 
7705   ;;
7706 esac
7707 fi
7708 LN=$ac_cv_path_LN
7709 if test -n "$LN"; then
7710   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7711 $as_echo "$LN" >&6; }
7712 else
7713   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7714 $as_echo "no" >&6; }
7715 fi
7716 
7717 
7718         if test "x$LN" = x; then
7719           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7720         fi
7721       else
7722         # Otherwise we believe it is a complete path. Use it as it is.
7723         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5
7724 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;}
7725         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5
7726 $as_echo_n "checking for LN... " >&6; }
7727         if test ! -x "$tool_specified"; then
7728           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7729 $as_echo "not found" >&6; }
7730           as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5
7731         fi
7732         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7733 $as_echo "$tool_specified" >&6; }
7734       fi
7735     fi
7736   fi
7737 
7738 
7739 
7740   if test "x$LN" = x; then
7741     as_fn_error $? "Could not find required tool for LN" "$LINENO" 5
7742   fi
7743 
7744 
7745 
7746 
7747 
7748   # Publish this variable in the help.
7749 
7750 
7751   if test "x$LS" = x; then
7752     # The variable is not set by user, try to locate tool using the code snippet
7753     for ac_prog in ls
7754 do
7755   # Extract the first word of "$ac_prog", so it can be a program name with args.
7756 set dummy $ac_prog; ac_word=$2
7757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7758 $as_echo_n "checking for $ac_word... " >&6; }
7759 if ${ac_cv_path_LS+:} false; then :
7760   $as_echo_n "(cached) " >&6
7761 else
7762   case $LS in
7763   [\\/]* | ?:[\\/]*)
7764   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7765   ;;
7766   *)
7767   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7768 for as_dir in $PATH
7769 do
7770   IFS=$as_save_IFS
7771   test -z "$as_dir" && as_dir=.
7772     for ac_exec_ext in '' $ac_executable_extensions; do
7773   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7774     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7775     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7776     break 2
7777   fi
7778 done
7779   done
7780 IFS=$as_save_IFS
7781 
7782   ;;
7783 esac
7784 fi
7785 LS=$ac_cv_path_LS
7786 if test -n "$LS"; then
7787   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7788 $as_echo "$LS" >&6; }
7789 else
7790   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7791 $as_echo "no" >&6; }
7792 fi
7793 
7794 
7795   test -n "$LS" && break
7796 done
7797 
7798   else
7799     # The variable is set, but is it from the command line or the environment?
7800 
7801     # Try to remove the string !LS! from our list.
7802     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/}
7803     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7804       # If it failed, the variable was not from the command line. Ignore it,
7805       # but warn the user (except for BASH, which is always set by the calling BASH).
7806       if test "xLS" != xBASH; then
7807         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5
7808 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;}
7809       fi
7810       # Try to locate tool using the code snippet
7811       for ac_prog in ls
7812 do
7813   # Extract the first word of "$ac_prog", so it can be a program name with args.
7814 set dummy $ac_prog; ac_word=$2
7815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7816 $as_echo_n "checking for $ac_word... " >&6; }
7817 if ${ac_cv_path_LS+:} false; then :
7818   $as_echo_n "(cached) " >&6
7819 else
7820   case $LS in
7821   [\\/]* | ?:[\\/]*)
7822   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7823   ;;
7824   *)
7825   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7826 for as_dir in $PATH
7827 do
7828   IFS=$as_save_IFS
7829   test -z "$as_dir" && as_dir=.
7830     for ac_exec_ext in '' $ac_executable_extensions; do
7831   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7832     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7833     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7834     break 2
7835   fi
7836 done
7837   done
7838 IFS=$as_save_IFS
7839 
7840   ;;
7841 esac
7842 fi
7843 LS=$ac_cv_path_LS
7844 if test -n "$LS"; then
7845   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7846 $as_echo "$LS" >&6; }
7847 else
7848   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7849 $as_echo "no" >&6; }
7850 fi
7851 
7852 
7853   test -n "$LS" && break
7854 done
7855 
7856     else
7857       # If it succeeded, then it was overridden by the user. We will use it
7858       # for the tool.
7859 
7860       # First remove it from the list of overridden variables, so we can test
7861       # for unknown variables in the end.
7862       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7863 
7864       # Check if the provided tool contains a complete path.
7865       tool_specified="$LS"
7866       tool_basename="${tool_specified##*/}"
7867       if test "x$tool_basename" = "x$tool_specified"; then
7868         # A command without a complete path is provided, search $PATH.
7869         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5
7870 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;}
7871         # Extract the first word of "$tool_basename", so it can be a program name with args.
7872 set dummy $tool_basename; ac_word=$2
7873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7874 $as_echo_n "checking for $ac_word... " >&6; }
7875 if ${ac_cv_path_LS+:} false; then :
7876   $as_echo_n "(cached) " >&6
7877 else
7878   case $LS in
7879   [\\/]* | ?:[\\/]*)
7880   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7881   ;;
7882   *)
7883   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7884 for as_dir in $PATH
7885 do
7886   IFS=$as_save_IFS
7887   test -z "$as_dir" && as_dir=.
7888     for ac_exec_ext in '' $ac_executable_extensions; do
7889   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7890     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7891     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7892     break 2
7893   fi
7894 done
7895   done
7896 IFS=$as_save_IFS
7897 
7898   ;;
7899 esac
7900 fi
7901 LS=$ac_cv_path_LS
7902 if test -n "$LS"; then
7903   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7904 $as_echo "$LS" >&6; }
7905 else
7906   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7907 $as_echo "no" >&6; }
7908 fi
7909 
7910 
7911         if test "x$LS" = x; then
7912           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7913         fi
7914       else
7915         # Otherwise we believe it is a complete path. Use it as it is.
7916         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5
7917 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;}
7918         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5
7919 $as_echo_n "checking for LS... " >&6; }
7920         if test ! -x "$tool_specified"; then
7921           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7922 $as_echo "not found" >&6; }
7923           as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5
7924         fi
7925         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7926 $as_echo "$tool_specified" >&6; }
7927       fi
7928     fi
7929   fi
7930 
7931 
7932 
7933   if test "x$LS" = x; then
7934     as_fn_error $? "Could not find required tool for LS" "$LINENO" 5
7935   fi
7936 
7937 
7938 
7939 
7940 
7941   # Publish this variable in the help.
7942 
7943 
7944   if test "x$MKDIR" = x; then
7945     # The variable is not set by user, try to locate tool using the code snippet
7946     for ac_prog in mkdir
7947 do
7948   # Extract the first word of "$ac_prog", so it can be a program name with args.
7949 set dummy $ac_prog; ac_word=$2
7950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7951 $as_echo_n "checking for $ac_word... " >&6; }
7952 if ${ac_cv_path_MKDIR+:} false; then :
7953   $as_echo_n "(cached) " >&6
7954 else
7955   case $MKDIR in
7956   [\\/]* | ?:[\\/]*)
7957   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7958   ;;
7959   *)
7960   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7961 for as_dir in $PATH
7962 do
7963   IFS=$as_save_IFS
7964   test -z "$as_dir" && as_dir=.
7965     for ac_exec_ext in '' $ac_executable_extensions; do
7966   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7967     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7968     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7969     break 2
7970   fi
7971 done
7972   done
7973 IFS=$as_save_IFS
7974 
7975   ;;
7976 esac
7977 fi
7978 MKDIR=$ac_cv_path_MKDIR
7979 if test -n "$MKDIR"; then
7980   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7981 $as_echo "$MKDIR" >&6; }
7982 else
7983   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7984 $as_echo "no" >&6; }
7985 fi
7986 
7987 
7988   test -n "$MKDIR" && break
7989 done
7990 
7991   else
7992     # The variable is set, but is it from the command line or the environment?
7993 
7994     # Try to remove the string !MKDIR! from our list.
7995     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/}
7996     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7997       # If it failed, the variable was not from the command line. Ignore it,
7998       # but warn the user (except for BASH, which is always set by the calling BASH).
7999       if test "xMKDIR" != xBASH; then
8000         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5
8001 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;}
8002       fi
8003       # Try to locate tool using the code snippet
8004       for ac_prog in mkdir
8005 do
8006   # Extract the first word of "$ac_prog", so it can be a program name with args.
8007 set dummy $ac_prog; ac_word=$2
8008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8009 $as_echo_n "checking for $ac_word... " >&6; }
8010 if ${ac_cv_path_MKDIR+:} false; then :
8011   $as_echo_n "(cached) " >&6
8012 else
8013   case $MKDIR in
8014   [\\/]* | ?:[\\/]*)
8015   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8016   ;;
8017   *)
8018   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8019 for as_dir in $PATH
8020 do
8021   IFS=$as_save_IFS
8022   test -z "$as_dir" && as_dir=.
8023     for ac_exec_ext in '' $ac_executable_extensions; do
8024   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8025     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8026     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8027     break 2
8028   fi
8029 done
8030   done
8031 IFS=$as_save_IFS
8032 
8033   ;;
8034 esac
8035 fi
8036 MKDIR=$ac_cv_path_MKDIR
8037 if test -n "$MKDIR"; then
8038   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8039 $as_echo "$MKDIR" >&6; }
8040 else
8041   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8042 $as_echo "no" >&6; }
8043 fi
8044 
8045 
8046   test -n "$MKDIR" && break
8047 done
8048 
8049     else
8050       # If it succeeded, then it was overridden by the user. We will use it
8051       # for the tool.
8052 
8053       # First remove it from the list of overridden variables, so we can test
8054       # for unknown variables in the end.
8055       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8056 
8057       # Check if the provided tool contains a complete path.
8058       tool_specified="$MKDIR"
8059       tool_basename="${tool_specified##*/}"
8060       if test "x$tool_basename" = "x$tool_specified"; then
8061         # A command without a complete path is provided, search $PATH.
8062         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5
8063 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;}
8064         # Extract the first word of "$tool_basename", so it can be a program name with args.
8065 set dummy $tool_basename; ac_word=$2
8066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8067 $as_echo_n "checking for $ac_word... " >&6; }
8068 if ${ac_cv_path_MKDIR+:} false; then :
8069   $as_echo_n "(cached) " >&6
8070 else
8071   case $MKDIR in
8072   [\\/]* | ?:[\\/]*)
8073   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8074   ;;
8075   *)
8076   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8077 for as_dir in $PATH
8078 do
8079   IFS=$as_save_IFS
8080   test -z "$as_dir" && as_dir=.
8081     for ac_exec_ext in '' $ac_executable_extensions; do
8082   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8083     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8084     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8085     break 2
8086   fi
8087 done
8088   done
8089 IFS=$as_save_IFS
8090 
8091   ;;
8092 esac
8093 fi
8094 MKDIR=$ac_cv_path_MKDIR
8095 if test -n "$MKDIR"; then
8096   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8097 $as_echo "$MKDIR" >&6; }
8098 else
8099   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8100 $as_echo "no" >&6; }
8101 fi
8102 
8103 
8104         if test "x$MKDIR" = x; then
8105           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8106         fi
8107       else
8108         # Otherwise we believe it is a complete path. Use it as it is.
8109         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5
8110 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;}
8111         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5
8112 $as_echo_n "checking for MKDIR... " >&6; }
8113         if test ! -x "$tool_specified"; then
8114           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8115 $as_echo "not found" >&6; }
8116           as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5
8117         fi
8118         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8119 $as_echo "$tool_specified" >&6; }
8120       fi
8121     fi
8122   fi
8123 
8124 
8125 
8126   if test "x$MKDIR" = x; then
8127     as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5
8128   fi
8129 
8130 
8131 
8132 
8133 
8134   # Publish this variable in the help.
8135 
8136 
8137   if test "x$MKTEMP" = x; then
8138     # The variable is not set by user, try to locate tool using the code snippet
8139     for ac_prog in mktemp
8140 do
8141   # Extract the first word of "$ac_prog", so it can be a program name with args.
8142 set dummy $ac_prog; ac_word=$2
8143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8144 $as_echo_n "checking for $ac_word... " >&6; }
8145 if ${ac_cv_path_MKTEMP+:} false; then :
8146   $as_echo_n "(cached) " >&6
8147 else
8148   case $MKTEMP in
8149   [\\/]* | ?:[\\/]*)
8150   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8151   ;;
8152   *)
8153   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8154 for as_dir in $PATH
8155 do
8156   IFS=$as_save_IFS
8157   test -z "$as_dir" && as_dir=.
8158     for ac_exec_ext in '' $ac_executable_extensions; do
8159   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8160     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8161     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8162     break 2
8163   fi
8164 done
8165   done
8166 IFS=$as_save_IFS
8167 
8168   ;;
8169 esac
8170 fi
8171 MKTEMP=$ac_cv_path_MKTEMP
8172 if test -n "$MKTEMP"; then
8173   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8174 $as_echo "$MKTEMP" >&6; }
8175 else
8176   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8177 $as_echo "no" >&6; }
8178 fi
8179 
8180 
8181   test -n "$MKTEMP" && break
8182 done
8183 
8184   else
8185     # The variable is set, but is it from the command line or the environment?
8186 
8187     # Try to remove the string !MKTEMP! from our list.
8188     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/}
8189     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8190       # If it failed, the variable was not from the command line. Ignore it,
8191       # but warn the user (except for BASH, which is always set by the calling BASH).
8192       if test "xMKTEMP" != xBASH; then
8193         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5
8194 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;}
8195       fi
8196       # Try to locate tool using the code snippet
8197       for ac_prog in mktemp
8198 do
8199   # Extract the first word of "$ac_prog", so it can be a program name with args.
8200 set dummy $ac_prog; ac_word=$2
8201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8202 $as_echo_n "checking for $ac_word... " >&6; }
8203 if ${ac_cv_path_MKTEMP+:} false; then :
8204   $as_echo_n "(cached) " >&6
8205 else
8206   case $MKTEMP in
8207   [\\/]* | ?:[\\/]*)
8208   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8209   ;;
8210   *)
8211   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8212 for as_dir in $PATH
8213 do
8214   IFS=$as_save_IFS
8215   test -z "$as_dir" && as_dir=.
8216     for ac_exec_ext in '' $ac_executable_extensions; do
8217   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8218     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8219     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8220     break 2
8221   fi
8222 done
8223   done
8224 IFS=$as_save_IFS
8225 
8226   ;;
8227 esac
8228 fi
8229 MKTEMP=$ac_cv_path_MKTEMP
8230 if test -n "$MKTEMP"; then
8231   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8232 $as_echo "$MKTEMP" >&6; }
8233 else
8234   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8235 $as_echo "no" >&6; }
8236 fi
8237 
8238 
8239   test -n "$MKTEMP" && break
8240 done
8241 
8242     else
8243       # If it succeeded, then it was overridden by the user. We will use it
8244       # for the tool.
8245 
8246       # First remove it from the list of overridden variables, so we can test
8247       # for unknown variables in the end.
8248       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8249 
8250       # Check if the provided tool contains a complete path.
8251       tool_specified="$MKTEMP"
8252       tool_basename="${tool_specified##*/}"
8253       if test "x$tool_basename" = "x$tool_specified"; then
8254         # A command without a complete path is provided, search $PATH.
8255         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5
8256 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;}
8257         # Extract the first word of "$tool_basename", so it can be a program name with args.
8258 set dummy $tool_basename; ac_word=$2
8259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8260 $as_echo_n "checking for $ac_word... " >&6; }
8261 if ${ac_cv_path_MKTEMP+:} false; then :
8262   $as_echo_n "(cached) " >&6
8263 else
8264   case $MKTEMP in
8265   [\\/]* | ?:[\\/]*)
8266   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8267   ;;
8268   *)
8269   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8270 for as_dir in $PATH
8271 do
8272   IFS=$as_save_IFS
8273   test -z "$as_dir" && as_dir=.
8274     for ac_exec_ext in '' $ac_executable_extensions; do
8275   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8276     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8277     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8278     break 2
8279   fi
8280 done
8281   done
8282 IFS=$as_save_IFS
8283 
8284   ;;
8285 esac
8286 fi
8287 MKTEMP=$ac_cv_path_MKTEMP
8288 if test -n "$MKTEMP"; then
8289   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8290 $as_echo "$MKTEMP" >&6; }
8291 else
8292   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8293 $as_echo "no" >&6; }
8294 fi
8295 
8296 
8297         if test "x$MKTEMP" = x; then
8298           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8299         fi
8300       else
8301         # Otherwise we believe it is a complete path. Use it as it is.
8302         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5
8303 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;}
8304         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5
8305 $as_echo_n "checking for MKTEMP... " >&6; }
8306         if test ! -x "$tool_specified"; then
8307           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8308 $as_echo "not found" >&6; }
8309           as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5
8310         fi
8311         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8312 $as_echo "$tool_specified" >&6; }
8313       fi
8314     fi
8315   fi
8316 
8317 
8318 
8319   if test "x$MKTEMP" = x; then
8320     as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5
8321   fi
8322 
8323 
8324 
8325 
8326 
8327   # Publish this variable in the help.
8328 
8329 
8330   if test "x$MV" = x; then
8331     # The variable is not set by user, try to locate tool using the code snippet
8332     for ac_prog in mv
8333 do
8334   # Extract the first word of "$ac_prog", so it can be a program name with args.
8335 set dummy $ac_prog; ac_word=$2
8336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8337 $as_echo_n "checking for $ac_word... " >&6; }
8338 if ${ac_cv_path_MV+:} false; then :
8339   $as_echo_n "(cached) " >&6
8340 else
8341   case $MV in
8342   [\\/]* | ?:[\\/]*)
8343   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8344   ;;
8345   *)
8346   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8347 for as_dir in $PATH
8348 do
8349   IFS=$as_save_IFS
8350   test -z "$as_dir" && as_dir=.
8351     for ac_exec_ext in '' $ac_executable_extensions; do
8352   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8353     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8354     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8355     break 2
8356   fi
8357 done
8358   done
8359 IFS=$as_save_IFS
8360 
8361   ;;
8362 esac
8363 fi
8364 MV=$ac_cv_path_MV
8365 if test -n "$MV"; then
8366   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8367 $as_echo "$MV" >&6; }
8368 else
8369   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8370 $as_echo "no" >&6; }
8371 fi
8372 
8373 
8374   test -n "$MV" && break
8375 done
8376 
8377   else
8378     # The variable is set, but is it from the command line or the environment?
8379 
8380     # Try to remove the string !MV! from our list.
8381     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/}
8382     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8383       # If it failed, the variable was not from the command line. Ignore it,
8384       # but warn the user (except for BASH, which is always set by the calling BASH).
8385       if test "xMV" != xBASH; then
8386         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5
8387 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;}
8388       fi
8389       # Try to locate tool using the code snippet
8390       for ac_prog in mv
8391 do
8392   # Extract the first word of "$ac_prog", so it can be a program name with args.
8393 set dummy $ac_prog; ac_word=$2
8394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8395 $as_echo_n "checking for $ac_word... " >&6; }
8396 if ${ac_cv_path_MV+:} false; then :
8397   $as_echo_n "(cached) " >&6
8398 else
8399   case $MV in
8400   [\\/]* | ?:[\\/]*)
8401   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8402   ;;
8403   *)
8404   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8405 for as_dir in $PATH
8406 do
8407   IFS=$as_save_IFS
8408   test -z "$as_dir" && as_dir=.
8409     for ac_exec_ext in '' $ac_executable_extensions; do
8410   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8411     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8412     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8413     break 2
8414   fi
8415 done
8416   done
8417 IFS=$as_save_IFS
8418 
8419   ;;
8420 esac
8421 fi
8422 MV=$ac_cv_path_MV
8423 if test -n "$MV"; then
8424   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8425 $as_echo "$MV" >&6; }
8426 else
8427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8428 $as_echo "no" >&6; }
8429 fi
8430 
8431 
8432   test -n "$MV" && break
8433 done
8434 
8435     else
8436       # If it succeeded, then it was overridden by the user. We will use it
8437       # for the tool.
8438 
8439       # First remove it from the list of overridden variables, so we can test
8440       # for unknown variables in the end.
8441       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8442 
8443       # Check if the provided tool contains a complete path.
8444       tool_specified="$MV"
8445       tool_basename="${tool_specified##*/}"
8446       if test "x$tool_basename" = "x$tool_specified"; then
8447         # A command without a complete path is provided, search $PATH.
8448         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5
8449 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;}
8450         # Extract the first word of "$tool_basename", so it can be a program name with args.
8451 set dummy $tool_basename; ac_word=$2
8452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8453 $as_echo_n "checking for $ac_word... " >&6; }
8454 if ${ac_cv_path_MV+:} false; then :
8455   $as_echo_n "(cached) " >&6
8456 else
8457   case $MV in
8458   [\\/]* | ?:[\\/]*)
8459   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8460   ;;
8461   *)
8462   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8463 for as_dir in $PATH
8464 do
8465   IFS=$as_save_IFS
8466   test -z "$as_dir" && as_dir=.
8467     for ac_exec_ext in '' $ac_executable_extensions; do
8468   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8469     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8470     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8471     break 2
8472   fi
8473 done
8474   done
8475 IFS=$as_save_IFS
8476 
8477   ;;
8478 esac
8479 fi
8480 MV=$ac_cv_path_MV
8481 if test -n "$MV"; then
8482   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8483 $as_echo "$MV" >&6; }
8484 else
8485   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8486 $as_echo "no" >&6; }
8487 fi
8488 
8489 
8490         if test "x$MV" = x; then
8491           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8492         fi
8493       else
8494         # Otherwise we believe it is a complete path. Use it as it is.
8495         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5
8496 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;}
8497         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5
8498 $as_echo_n "checking for MV... " >&6; }
8499         if test ! -x "$tool_specified"; then
8500           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8501 $as_echo "not found" >&6; }
8502           as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5
8503         fi
8504         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8505 $as_echo "$tool_specified" >&6; }
8506       fi
8507     fi
8508   fi
8509 
8510 
8511 
8512   if test "x$MV" = x; then
8513     as_fn_error $? "Could not find required tool for MV" "$LINENO" 5
8514   fi
8515 
8516 
8517 
8518 
8519 
8520   # Publish this variable in the help.
8521 
8522 
8523   if test "x$NAWK" = x; then
8524     # The variable is not set by user, try to locate tool using the code snippet
8525     for ac_prog in nawk gawk awk
8526 do
8527   # Extract the first word of "$ac_prog", so it can be a program name with args.
8528 set dummy $ac_prog; ac_word=$2
8529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8530 $as_echo_n "checking for $ac_word... " >&6; }
8531 if ${ac_cv_path_NAWK+:} false; then :
8532   $as_echo_n "(cached) " >&6
8533 else
8534   case $NAWK in
8535   [\\/]* | ?:[\\/]*)
8536   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8537   ;;
8538   *)
8539   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8540 for as_dir in $PATH
8541 do
8542   IFS=$as_save_IFS
8543   test -z "$as_dir" && as_dir=.
8544     for ac_exec_ext in '' $ac_executable_extensions; do
8545   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8546     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8547     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8548     break 2
8549   fi
8550 done
8551   done
8552 IFS=$as_save_IFS
8553 
8554   ;;
8555 esac
8556 fi
8557 NAWK=$ac_cv_path_NAWK
8558 if test -n "$NAWK"; then
8559   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8560 $as_echo "$NAWK" >&6; }
8561 else
8562   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8563 $as_echo "no" >&6; }
8564 fi
8565 
8566 
8567   test -n "$NAWK" && break
8568 done
8569 
8570   else
8571     # The variable is set, but is it from the command line or the environment?
8572 
8573     # Try to remove the string !NAWK! from our list.
8574     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/}
8575     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8576       # If it failed, the variable was not from the command line. Ignore it,
8577       # but warn the user (except for BASH, which is always set by the calling BASH).
8578       if test "xNAWK" != xBASH; then
8579         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5
8580 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;}
8581       fi
8582       # Try to locate tool using the code snippet
8583       for ac_prog in nawk gawk awk
8584 do
8585   # Extract the first word of "$ac_prog", so it can be a program name with args.
8586 set dummy $ac_prog; ac_word=$2
8587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8588 $as_echo_n "checking for $ac_word... " >&6; }
8589 if ${ac_cv_path_NAWK+:} false; then :
8590   $as_echo_n "(cached) " >&6
8591 else
8592   case $NAWK in
8593   [\\/]* | ?:[\\/]*)
8594   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8595   ;;
8596   *)
8597   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8598 for as_dir in $PATH
8599 do
8600   IFS=$as_save_IFS
8601   test -z "$as_dir" && as_dir=.
8602     for ac_exec_ext in '' $ac_executable_extensions; do
8603   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8604     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8605     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8606     break 2
8607   fi
8608 done
8609   done
8610 IFS=$as_save_IFS
8611 
8612   ;;
8613 esac
8614 fi
8615 NAWK=$ac_cv_path_NAWK
8616 if test -n "$NAWK"; then
8617   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8618 $as_echo "$NAWK" >&6; }
8619 else
8620   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8621 $as_echo "no" >&6; }
8622 fi
8623 
8624 
8625   test -n "$NAWK" && break
8626 done
8627 
8628     else
8629       # If it succeeded, then it was overridden by the user. We will use it
8630       # for the tool.
8631 
8632       # First remove it from the list of overridden variables, so we can test
8633       # for unknown variables in the end.
8634       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8635 
8636       # Check if the provided tool contains a complete path.
8637       tool_specified="$NAWK"
8638       tool_basename="${tool_specified##*/}"
8639       if test "x$tool_basename" = "x$tool_specified"; then
8640         # A command without a complete path is provided, search $PATH.
8641         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5
8642 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;}
8643         # Extract the first word of "$tool_basename", so it can be a program name with args.
8644 set dummy $tool_basename; ac_word=$2
8645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8646 $as_echo_n "checking for $ac_word... " >&6; }
8647 if ${ac_cv_path_NAWK+:} false; then :
8648   $as_echo_n "(cached) " >&6
8649 else
8650   case $NAWK in
8651   [\\/]* | ?:[\\/]*)
8652   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8653   ;;
8654   *)
8655   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8656 for as_dir in $PATH
8657 do
8658   IFS=$as_save_IFS
8659   test -z "$as_dir" && as_dir=.
8660     for ac_exec_ext in '' $ac_executable_extensions; do
8661   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8662     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8663     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8664     break 2
8665   fi
8666 done
8667   done
8668 IFS=$as_save_IFS
8669 
8670   ;;
8671 esac
8672 fi
8673 NAWK=$ac_cv_path_NAWK
8674 if test -n "$NAWK"; then
8675   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8676 $as_echo "$NAWK" >&6; }
8677 else
8678   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8679 $as_echo "no" >&6; }
8680 fi
8681 
8682 
8683         if test "x$NAWK" = x; then
8684           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8685         fi
8686       else
8687         # Otherwise we believe it is a complete path. Use it as it is.
8688         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5
8689 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;}
8690         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5
8691 $as_echo_n "checking for NAWK... " >&6; }
8692         if test ! -x "$tool_specified"; then
8693           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8694 $as_echo "not found" >&6; }
8695           as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5
8696         fi
8697         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8698 $as_echo "$tool_specified" >&6; }
8699       fi
8700     fi
8701   fi
8702 
8703 
8704 
8705   if test "x$NAWK" = x; then
8706     as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5
8707   fi
8708 
8709 
8710 
8711 
8712 
8713   # Publish this variable in the help.
8714 
8715 
8716   if test "x$PRINTF" = x; then
8717     # The variable is not set by user, try to locate tool using the code snippet
8718     for ac_prog in printf
8719 do
8720   # Extract the first word of "$ac_prog", so it can be a program name with args.
8721 set dummy $ac_prog; ac_word=$2
8722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8723 $as_echo_n "checking for $ac_word... " >&6; }
8724 if ${ac_cv_path_PRINTF+:} false; then :
8725   $as_echo_n "(cached) " >&6
8726 else
8727   case $PRINTF in
8728   [\\/]* | ?:[\\/]*)
8729   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8730   ;;
8731   *)
8732   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8733 for as_dir in $PATH
8734 do
8735   IFS=$as_save_IFS
8736   test -z "$as_dir" && as_dir=.
8737     for ac_exec_ext in '' $ac_executable_extensions; do
8738   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8739     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8740     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8741     break 2
8742   fi
8743 done
8744   done
8745 IFS=$as_save_IFS
8746 
8747   ;;
8748 esac
8749 fi
8750 PRINTF=$ac_cv_path_PRINTF
8751 if test -n "$PRINTF"; then
8752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8753 $as_echo "$PRINTF" >&6; }
8754 else
8755   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8756 $as_echo "no" >&6; }
8757 fi
8758 
8759 
8760   test -n "$PRINTF" && break
8761 done
8762 
8763   else
8764     # The variable is set, but is it from the command line or the environment?
8765 
8766     # Try to remove the string !PRINTF! from our list.
8767     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/}
8768     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8769       # If it failed, the variable was not from the command line. Ignore it,
8770       # but warn the user (except for BASH, which is always set by the calling BASH).
8771       if test "xPRINTF" != xBASH; then
8772         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5
8773 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;}
8774       fi
8775       # Try to locate tool using the code snippet
8776       for ac_prog in printf
8777 do
8778   # Extract the first word of "$ac_prog", so it can be a program name with args.
8779 set dummy $ac_prog; ac_word=$2
8780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8781 $as_echo_n "checking for $ac_word... " >&6; }
8782 if ${ac_cv_path_PRINTF+:} false; then :
8783   $as_echo_n "(cached) " >&6
8784 else
8785   case $PRINTF in
8786   [\\/]* | ?:[\\/]*)
8787   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8788   ;;
8789   *)
8790   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8791 for as_dir in $PATH
8792 do
8793   IFS=$as_save_IFS
8794   test -z "$as_dir" && as_dir=.
8795     for ac_exec_ext in '' $ac_executable_extensions; do
8796   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8797     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8798     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8799     break 2
8800   fi
8801 done
8802   done
8803 IFS=$as_save_IFS
8804 
8805   ;;
8806 esac
8807 fi
8808 PRINTF=$ac_cv_path_PRINTF
8809 if test -n "$PRINTF"; then
8810   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8811 $as_echo "$PRINTF" >&6; }
8812 else
8813   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8814 $as_echo "no" >&6; }
8815 fi
8816 
8817 
8818   test -n "$PRINTF" && break
8819 done
8820 
8821     else
8822       # If it succeeded, then it was overridden by the user. We will use it
8823       # for the tool.
8824 
8825       # First remove it from the list of overridden variables, so we can test
8826       # for unknown variables in the end.
8827       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8828 
8829       # Check if the provided tool contains a complete path.
8830       tool_specified="$PRINTF"
8831       tool_basename="${tool_specified##*/}"
8832       if test "x$tool_basename" = "x$tool_specified"; then
8833         # A command without a complete path is provided, search $PATH.
8834         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5
8835 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;}
8836         # Extract the first word of "$tool_basename", so it can be a program name with args.
8837 set dummy $tool_basename; ac_word=$2
8838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8839 $as_echo_n "checking for $ac_word... " >&6; }
8840 if ${ac_cv_path_PRINTF+:} false; then :
8841   $as_echo_n "(cached) " >&6
8842 else
8843   case $PRINTF in
8844   [\\/]* | ?:[\\/]*)
8845   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8846   ;;
8847   *)
8848   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8849 for as_dir in $PATH
8850 do
8851   IFS=$as_save_IFS
8852   test -z "$as_dir" && as_dir=.
8853     for ac_exec_ext in '' $ac_executable_extensions; do
8854   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8855     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8856     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8857     break 2
8858   fi
8859 done
8860   done
8861 IFS=$as_save_IFS
8862 
8863   ;;
8864 esac
8865 fi
8866 PRINTF=$ac_cv_path_PRINTF
8867 if test -n "$PRINTF"; then
8868   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8869 $as_echo "$PRINTF" >&6; }
8870 else
8871   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8872 $as_echo "no" >&6; }
8873 fi
8874 
8875 
8876         if test "x$PRINTF" = x; then
8877           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8878         fi
8879       else
8880         # Otherwise we believe it is a complete path. Use it as it is.
8881         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5
8882 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;}
8883         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5
8884 $as_echo_n "checking for PRINTF... " >&6; }
8885         if test ! -x "$tool_specified"; then
8886           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8887 $as_echo "not found" >&6; }
8888           as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5
8889         fi
8890         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8891 $as_echo "$tool_specified" >&6; }
8892       fi
8893     fi
8894   fi
8895 
8896 
8897 
8898   if test "x$PRINTF" = x; then
8899     as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5
8900   fi
8901 
8902 
8903 
8904 
8905 
8906   # Publish this variable in the help.
8907 
8908 
8909   if test "x$RM" = x; then
8910     # The variable is not set by user, try to locate tool using the code snippet
8911     for ac_prog in rm
8912 do
8913   # Extract the first word of "$ac_prog", so it can be a program name with args.
8914 set dummy $ac_prog; ac_word=$2
8915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8916 $as_echo_n "checking for $ac_word... " >&6; }
8917 if ${ac_cv_path_RM+:} false; then :
8918   $as_echo_n "(cached) " >&6
8919 else
8920   case $RM in
8921   [\\/]* | ?:[\\/]*)
8922   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8923   ;;
8924   *)
8925   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8926 for as_dir in $PATH
8927 do
8928   IFS=$as_save_IFS
8929   test -z "$as_dir" && as_dir=.
8930     for ac_exec_ext in '' $ac_executable_extensions; do
8931   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8932     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8933     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8934     break 2
8935   fi
8936 done
8937   done
8938 IFS=$as_save_IFS
8939 
8940   ;;
8941 esac
8942 fi
8943 RM=$ac_cv_path_RM
8944 if test -n "$RM"; then
8945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8946 $as_echo "$RM" >&6; }
8947 else
8948   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8949 $as_echo "no" >&6; }
8950 fi
8951 
8952 
8953   test -n "$RM" && break
8954 done
8955 
8956   else
8957     # The variable is set, but is it from the command line or the environment?
8958 
8959     # Try to remove the string !RM! from our list.
8960     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/}
8961     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8962       # If it failed, the variable was not from the command line. Ignore it,
8963       # but warn the user (except for BASH, which is always set by the calling BASH).
8964       if test "xRM" != xBASH; then
8965         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5
8966 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;}
8967       fi
8968       # Try to locate tool using the code snippet
8969       for ac_prog in rm
8970 do
8971   # Extract the first word of "$ac_prog", so it can be a program name with args.
8972 set dummy $ac_prog; ac_word=$2
8973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8974 $as_echo_n "checking for $ac_word... " >&6; }
8975 if ${ac_cv_path_RM+:} false; then :
8976   $as_echo_n "(cached) " >&6
8977 else
8978   case $RM in
8979   [\\/]* | ?:[\\/]*)
8980   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8981   ;;
8982   *)
8983   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8984 for as_dir in $PATH
8985 do
8986   IFS=$as_save_IFS
8987   test -z "$as_dir" && as_dir=.
8988     for ac_exec_ext in '' $ac_executable_extensions; do
8989   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8990     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8991     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8992     break 2
8993   fi
8994 done
8995   done
8996 IFS=$as_save_IFS
8997 
8998   ;;
8999 esac
9000 fi
9001 RM=$ac_cv_path_RM
9002 if test -n "$RM"; then
9003   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9004 $as_echo "$RM" >&6; }
9005 else
9006   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9007 $as_echo "no" >&6; }
9008 fi
9009 
9010 
9011   test -n "$RM" && break
9012 done
9013 
9014     else
9015       # If it succeeded, then it was overridden by the user. We will use it
9016       # for the tool.
9017 
9018       # First remove it from the list of overridden variables, so we can test
9019       # for unknown variables in the end.
9020       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9021 
9022       # Check if the provided tool contains a complete path.
9023       tool_specified="$RM"
9024       tool_basename="${tool_specified##*/}"
9025       if test "x$tool_basename" = "x$tool_specified"; then
9026         # A command without a complete path is provided, search $PATH.
9027         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5
9028 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;}
9029         # Extract the first word of "$tool_basename", so it can be a program name with args.
9030 set dummy $tool_basename; ac_word=$2
9031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9032 $as_echo_n "checking for $ac_word... " >&6; }
9033 if ${ac_cv_path_RM+:} false; then :
9034   $as_echo_n "(cached) " >&6
9035 else
9036   case $RM in
9037   [\\/]* | ?:[\\/]*)
9038   ac_cv_path_RM="$RM" # Let the user override the test with a path.
9039   ;;
9040   *)
9041   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9042 for as_dir in $PATH
9043 do
9044   IFS=$as_save_IFS
9045   test -z "$as_dir" && as_dir=.
9046     for ac_exec_ext in '' $ac_executable_extensions; do
9047   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9048     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
9049     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9050     break 2
9051   fi
9052 done
9053   done
9054 IFS=$as_save_IFS
9055 
9056   ;;
9057 esac
9058 fi
9059 RM=$ac_cv_path_RM
9060 if test -n "$RM"; then
9061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9062 $as_echo "$RM" >&6; }
9063 else
9064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9065 $as_echo "no" >&6; }
9066 fi
9067 
9068 
9069         if test "x$RM" = x; then
9070           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9071         fi
9072       else
9073         # Otherwise we believe it is a complete path. Use it as it is.
9074         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5
9075 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;}
9076         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5
9077 $as_echo_n "checking for RM... " >&6; }
9078         if test ! -x "$tool_specified"; then
9079           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9080 $as_echo "not found" >&6; }
9081           as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5
9082         fi
9083         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9084 $as_echo "$tool_specified" >&6; }
9085       fi
9086     fi
9087   fi
9088 
9089 
9090 
9091   if test "x$RM" = x; then
9092     as_fn_error $? "Could not find required tool for RM" "$LINENO" 5
9093   fi
9094 
9095 
9096 
9097 
9098 
9099   # Publish this variable in the help.
9100 
9101 
9102   if test "x$SH" = x; then
9103     # The variable is not set by user, try to locate tool using the code snippet
9104     for ac_prog in sh
9105 do
9106   # Extract the first word of "$ac_prog", so it can be a program name with args.
9107 set dummy $ac_prog; ac_word=$2
9108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9109 $as_echo_n "checking for $ac_word... " >&6; }
9110 if ${ac_cv_path_SH+:} false; then :
9111   $as_echo_n "(cached) " >&6
9112 else
9113   case $SH in
9114   [\\/]* | ?:[\\/]*)
9115   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9116   ;;
9117   *)
9118   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9119 for as_dir in $PATH
9120 do
9121   IFS=$as_save_IFS
9122   test -z "$as_dir" && as_dir=.
9123     for ac_exec_ext in '' $ac_executable_extensions; do
9124   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9125     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9126     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9127     break 2
9128   fi
9129 done
9130   done
9131 IFS=$as_save_IFS
9132 
9133   ;;
9134 esac
9135 fi
9136 SH=$ac_cv_path_SH
9137 if test -n "$SH"; then
9138   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9139 $as_echo "$SH" >&6; }
9140 else
9141   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9142 $as_echo "no" >&6; }
9143 fi
9144 
9145 
9146   test -n "$SH" && break
9147 done
9148 
9149   else
9150     # The variable is set, but is it from the command line or the environment?
9151 
9152     # Try to remove the string !SH! from our list.
9153     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/}
9154     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9155       # If it failed, the variable was not from the command line. Ignore it,
9156       # but warn the user (except for BASH, which is always set by the calling BASH).
9157       if test "xSH" != xBASH; then
9158         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5
9159 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;}
9160       fi
9161       # Try to locate tool using the code snippet
9162       for ac_prog in sh
9163 do
9164   # Extract the first word of "$ac_prog", so it can be a program name with args.
9165 set dummy $ac_prog; ac_word=$2
9166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9167 $as_echo_n "checking for $ac_word... " >&6; }
9168 if ${ac_cv_path_SH+:} false; then :
9169   $as_echo_n "(cached) " >&6
9170 else
9171   case $SH in
9172   [\\/]* | ?:[\\/]*)
9173   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9174   ;;
9175   *)
9176   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9177 for as_dir in $PATH
9178 do
9179   IFS=$as_save_IFS
9180   test -z "$as_dir" && as_dir=.
9181     for ac_exec_ext in '' $ac_executable_extensions; do
9182   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9183     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9184     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9185     break 2
9186   fi
9187 done
9188   done
9189 IFS=$as_save_IFS
9190 
9191   ;;
9192 esac
9193 fi
9194 SH=$ac_cv_path_SH
9195 if test -n "$SH"; then
9196   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9197 $as_echo "$SH" >&6; }
9198 else
9199   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9200 $as_echo "no" >&6; }
9201 fi
9202 
9203 
9204   test -n "$SH" && break
9205 done
9206 
9207     else
9208       # If it succeeded, then it was overridden by the user. We will use it
9209       # for the tool.
9210 
9211       # First remove it from the list of overridden variables, so we can test
9212       # for unknown variables in the end.
9213       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9214 
9215       # Check if the provided tool contains a complete path.
9216       tool_specified="$SH"
9217       tool_basename="${tool_specified##*/}"
9218       if test "x$tool_basename" = "x$tool_specified"; then
9219         # A command without a complete path is provided, search $PATH.
9220         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5
9221 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;}
9222         # Extract the first word of "$tool_basename", so it can be a program name with args.
9223 set dummy $tool_basename; ac_word=$2
9224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9225 $as_echo_n "checking for $ac_word... " >&6; }
9226 if ${ac_cv_path_SH+:} false; then :
9227   $as_echo_n "(cached) " >&6
9228 else
9229   case $SH in
9230   [\\/]* | ?:[\\/]*)
9231   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9232   ;;
9233   *)
9234   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9235 for as_dir in $PATH
9236 do
9237   IFS=$as_save_IFS
9238   test -z "$as_dir" && as_dir=.
9239     for ac_exec_ext in '' $ac_executable_extensions; do
9240   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9241     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9242     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9243     break 2
9244   fi
9245 done
9246   done
9247 IFS=$as_save_IFS
9248 
9249   ;;
9250 esac
9251 fi
9252 SH=$ac_cv_path_SH
9253 if test -n "$SH"; then
9254   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9255 $as_echo "$SH" >&6; }
9256 else
9257   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9258 $as_echo "no" >&6; }
9259 fi
9260 
9261 
9262         if test "x$SH" = x; then
9263           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9264         fi
9265       else
9266         # Otherwise we believe it is a complete path. Use it as it is.
9267         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5
9268 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;}
9269         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5
9270 $as_echo_n "checking for SH... " >&6; }
9271         if test ! -x "$tool_specified"; then
9272           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9273 $as_echo "not found" >&6; }
9274           as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5
9275         fi
9276         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9277 $as_echo "$tool_specified" >&6; }
9278       fi
9279     fi
9280   fi
9281 
9282 
9283 
9284   if test "x$SH" = x; then
9285     as_fn_error $? "Could not find required tool for SH" "$LINENO" 5
9286   fi
9287 
9288 
9289 
9290 
9291 
9292   # Publish this variable in the help.
9293 
9294 
9295   if test "x$SORT" = x; then
9296     # The variable is not set by user, try to locate tool using the code snippet
9297     for ac_prog in sort
9298 do
9299   # Extract the first word of "$ac_prog", so it can be a program name with args.
9300 set dummy $ac_prog; ac_word=$2
9301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9302 $as_echo_n "checking for $ac_word... " >&6; }
9303 if ${ac_cv_path_SORT+:} false; then :
9304   $as_echo_n "(cached) " >&6
9305 else
9306   case $SORT in
9307   [\\/]* | ?:[\\/]*)
9308   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9309   ;;
9310   *)
9311   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9312 for as_dir in $PATH
9313 do
9314   IFS=$as_save_IFS
9315   test -z "$as_dir" && as_dir=.
9316     for ac_exec_ext in '' $ac_executable_extensions; do
9317   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9318     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9319     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9320     break 2
9321   fi
9322 done
9323   done
9324 IFS=$as_save_IFS
9325 
9326   ;;
9327 esac
9328 fi
9329 SORT=$ac_cv_path_SORT
9330 if test -n "$SORT"; then
9331   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9332 $as_echo "$SORT" >&6; }
9333 else
9334   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9335 $as_echo "no" >&6; }
9336 fi
9337 
9338 
9339   test -n "$SORT" && break
9340 done
9341 
9342   else
9343     # The variable is set, but is it from the command line or the environment?
9344 
9345     # Try to remove the string !SORT! from our list.
9346     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/}
9347     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9348       # If it failed, the variable was not from the command line. Ignore it,
9349       # but warn the user (except for BASH, which is always set by the calling BASH).
9350       if test "xSORT" != xBASH; then
9351         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5
9352 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;}
9353       fi
9354       # Try to locate tool using the code snippet
9355       for ac_prog in sort
9356 do
9357   # Extract the first word of "$ac_prog", so it can be a program name with args.
9358 set dummy $ac_prog; ac_word=$2
9359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9360 $as_echo_n "checking for $ac_word... " >&6; }
9361 if ${ac_cv_path_SORT+:} false; then :
9362   $as_echo_n "(cached) " >&6
9363 else
9364   case $SORT in
9365   [\\/]* | ?:[\\/]*)
9366   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9367   ;;
9368   *)
9369   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9370 for as_dir in $PATH
9371 do
9372   IFS=$as_save_IFS
9373   test -z "$as_dir" && as_dir=.
9374     for ac_exec_ext in '' $ac_executable_extensions; do
9375   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9376     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9377     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9378     break 2
9379   fi
9380 done
9381   done
9382 IFS=$as_save_IFS
9383 
9384   ;;
9385 esac
9386 fi
9387 SORT=$ac_cv_path_SORT
9388 if test -n "$SORT"; then
9389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9390 $as_echo "$SORT" >&6; }
9391 else
9392   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9393 $as_echo "no" >&6; }
9394 fi
9395 
9396 
9397   test -n "$SORT" && break
9398 done
9399 
9400     else
9401       # If it succeeded, then it was overridden by the user. We will use it
9402       # for the tool.
9403 
9404       # First remove it from the list of overridden variables, so we can test
9405       # for unknown variables in the end.
9406       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9407 
9408       # Check if the provided tool contains a complete path.
9409       tool_specified="$SORT"
9410       tool_basename="${tool_specified##*/}"
9411       if test "x$tool_basename" = "x$tool_specified"; then
9412         # A command without a complete path is provided, search $PATH.
9413         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5
9414 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;}
9415         # Extract the first word of "$tool_basename", so it can be a program name with args.
9416 set dummy $tool_basename; ac_word=$2
9417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9418 $as_echo_n "checking for $ac_word... " >&6; }
9419 if ${ac_cv_path_SORT+:} false; then :
9420   $as_echo_n "(cached) " >&6
9421 else
9422   case $SORT in
9423   [\\/]* | ?:[\\/]*)
9424   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9425   ;;
9426   *)
9427   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9428 for as_dir in $PATH
9429 do
9430   IFS=$as_save_IFS
9431   test -z "$as_dir" && as_dir=.
9432     for ac_exec_ext in '' $ac_executable_extensions; do
9433   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9434     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9435     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9436     break 2
9437   fi
9438 done
9439   done
9440 IFS=$as_save_IFS
9441 
9442   ;;
9443 esac
9444 fi
9445 SORT=$ac_cv_path_SORT
9446 if test -n "$SORT"; then
9447   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9448 $as_echo "$SORT" >&6; }
9449 else
9450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9451 $as_echo "no" >&6; }
9452 fi
9453 
9454 
9455         if test "x$SORT" = x; then
9456           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9457         fi
9458       else
9459         # Otherwise we believe it is a complete path. Use it as it is.
9460         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5
9461 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;}
9462         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5
9463 $as_echo_n "checking for SORT... " >&6; }
9464         if test ! -x "$tool_specified"; then
9465           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9466 $as_echo "not found" >&6; }
9467           as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5
9468         fi
9469         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9470 $as_echo "$tool_specified" >&6; }
9471       fi
9472     fi
9473   fi
9474 
9475 
9476 
9477   if test "x$SORT" = x; then
9478     as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5
9479   fi
9480 
9481 
9482 
9483 
9484 
9485   # Publish this variable in the help.
9486 
9487 
9488   if test "x$TAIL" = x; then
9489     # The variable is not set by user, try to locate tool using the code snippet
9490     for ac_prog in tail
9491 do
9492   # Extract the first word of "$ac_prog", so it can be a program name with args.
9493 set dummy $ac_prog; ac_word=$2
9494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9495 $as_echo_n "checking for $ac_word... " >&6; }
9496 if ${ac_cv_path_TAIL+:} false; then :
9497   $as_echo_n "(cached) " >&6
9498 else
9499   case $TAIL in
9500   [\\/]* | ?:[\\/]*)
9501   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9502   ;;
9503   *)
9504   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9505 for as_dir in $PATH
9506 do
9507   IFS=$as_save_IFS
9508   test -z "$as_dir" && as_dir=.
9509     for ac_exec_ext in '' $ac_executable_extensions; do
9510   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9511     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9512     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9513     break 2
9514   fi
9515 done
9516   done
9517 IFS=$as_save_IFS
9518 
9519   ;;
9520 esac
9521 fi
9522 TAIL=$ac_cv_path_TAIL
9523 if test -n "$TAIL"; then
9524   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9525 $as_echo "$TAIL" >&6; }
9526 else
9527   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9528 $as_echo "no" >&6; }
9529 fi
9530 
9531 
9532   test -n "$TAIL" && break
9533 done
9534 
9535   else
9536     # The variable is set, but is it from the command line or the environment?
9537 
9538     # Try to remove the string !TAIL! from our list.
9539     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/}
9540     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9541       # If it failed, the variable was not from the command line. Ignore it,
9542       # but warn the user (except for BASH, which is always set by the calling BASH).
9543       if test "xTAIL" != xBASH; then
9544         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5
9545 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;}
9546       fi
9547       # Try to locate tool using the code snippet
9548       for ac_prog in tail
9549 do
9550   # Extract the first word of "$ac_prog", so it can be a program name with args.
9551 set dummy $ac_prog; ac_word=$2
9552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9553 $as_echo_n "checking for $ac_word... " >&6; }
9554 if ${ac_cv_path_TAIL+:} false; then :
9555   $as_echo_n "(cached) " >&6
9556 else
9557   case $TAIL in
9558   [\\/]* | ?:[\\/]*)
9559   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9560   ;;
9561   *)
9562   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9563 for as_dir in $PATH
9564 do
9565   IFS=$as_save_IFS
9566   test -z "$as_dir" && as_dir=.
9567     for ac_exec_ext in '' $ac_executable_extensions; do
9568   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9569     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9570     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9571     break 2
9572   fi
9573 done
9574   done
9575 IFS=$as_save_IFS
9576 
9577   ;;
9578 esac
9579 fi
9580 TAIL=$ac_cv_path_TAIL
9581 if test -n "$TAIL"; then
9582   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9583 $as_echo "$TAIL" >&6; }
9584 else
9585   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9586 $as_echo "no" >&6; }
9587 fi
9588 
9589 
9590   test -n "$TAIL" && break
9591 done
9592 
9593     else
9594       # If it succeeded, then it was overridden by the user. We will use it
9595       # for the tool.
9596 
9597       # First remove it from the list of overridden variables, so we can test
9598       # for unknown variables in the end.
9599       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9600 
9601       # Check if the provided tool contains a complete path.
9602       tool_specified="$TAIL"
9603       tool_basename="${tool_specified##*/}"
9604       if test "x$tool_basename" = "x$tool_specified"; then
9605         # A command without a complete path is provided, search $PATH.
9606         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5
9607 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;}
9608         # Extract the first word of "$tool_basename", so it can be a program name with args.
9609 set dummy $tool_basename; ac_word=$2
9610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9611 $as_echo_n "checking for $ac_word... " >&6; }
9612 if ${ac_cv_path_TAIL+:} false; then :
9613   $as_echo_n "(cached) " >&6
9614 else
9615   case $TAIL in
9616   [\\/]* | ?:[\\/]*)
9617   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9618   ;;
9619   *)
9620   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9621 for as_dir in $PATH
9622 do
9623   IFS=$as_save_IFS
9624   test -z "$as_dir" && as_dir=.
9625     for ac_exec_ext in '' $ac_executable_extensions; do
9626   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9627     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9628     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9629     break 2
9630   fi
9631 done
9632   done
9633 IFS=$as_save_IFS
9634 
9635   ;;
9636 esac
9637 fi
9638 TAIL=$ac_cv_path_TAIL
9639 if test -n "$TAIL"; then
9640   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9641 $as_echo "$TAIL" >&6; }
9642 else
9643   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9644 $as_echo "no" >&6; }
9645 fi
9646 
9647 
9648         if test "x$TAIL" = x; then
9649           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9650         fi
9651       else
9652         # Otherwise we believe it is a complete path. Use it as it is.
9653         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5
9654 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;}
9655         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5
9656 $as_echo_n "checking for TAIL... " >&6; }
9657         if test ! -x "$tool_specified"; then
9658           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9659 $as_echo "not found" >&6; }
9660           as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5
9661         fi
9662         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9663 $as_echo "$tool_specified" >&6; }
9664       fi
9665     fi
9666   fi
9667 
9668 
9669 
9670   if test "x$TAIL" = x; then
9671     as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5
9672   fi
9673 
9674 
9675 
9676 
9677 
9678   # Publish this variable in the help.
9679 
9680 
9681   if test "x$TAR" = x; then
9682     # The variable is not set by user, try to locate tool using the code snippet
9683     for ac_prog in tar
9684 do
9685   # Extract the first word of "$ac_prog", so it can be a program name with args.
9686 set dummy $ac_prog; ac_word=$2
9687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9688 $as_echo_n "checking for $ac_word... " >&6; }
9689 if ${ac_cv_path_TAR+:} false; then :
9690   $as_echo_n "(cached) " >&6
9691 else
9692   case $TAR in
9693   [\\/]* | ?:[\\/]*)
9694   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9695   ;;
9696   *)
9697   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9698 for as_dir in $PATH
9699 do
9700   IFS=$as_save_IFS
9701   test -z "$as_dir" && as_dir=.
9702     for ac_exec_ext in '' $ac_executable_extensions; do
9703   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9704     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9705     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9706     break 2
9707   fi
9708 done
9709   done
9710 IFS=$as_save_IFS
9711 
9712   ;;
9713 esac
9714 fi
9715 TAR=$ac_cv_path_TAR
9716 if test -n "$TAR"; then
9717   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9718 $as_echo "$TAR" >&6; }
9719 else
9720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9721 $as_echo "no" >&6; }
9722 fi
9723 
9724 
9725   test -n "$TAR" && break
9726 done
9727 
9728   else
9729     # The variable is set, but is it from the command line or the environment?
9730 
9731     # Try to remove the string !TAR! from our list.
9732     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/}
9733     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9734       # If it failed, the variable was not from the command line. Ignore it,
9735       # but warn the user (except for BASH, which is always set by the calling BASH).
9736       if test "xTAR" != xBASH; then
9737         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5
9738 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;}
9739       fi
9740       # Try to locate tool using the code snippet
9741       for ac_prog in tar
9742 do
9743   # Extract the first word of "$ac_prog", so it can be a program name with args.
9744 set dummy $ac_prog; ac_word=$2
9745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9746 $as_echo_n "checking for $ac_word... " >&6; }
9747 if ${ac_cv_path_TAR+:} false; then :
9748   $as_echo_n "(cached) " >&6
9749 else
9750   case $TAR in
9751   [\\/]* | ?:[\\/]*)
9752   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9753   ;;
9754   *)
9755   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9756 for as_dir in $PATH
9757 do
9758   IFS=$as_save_IFS
9759   test -z "$as_dir" && as_dir=.
9760     for ac_exec_ext in '' $ac_executable_extensions; do
9761   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9762     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9763     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9764     break 2
9765   fi
9766 done
9767   done
9768 IFS=$as_save_IFS
9769 
9770   ;;
9771 esac
9772 fi
9773 TAR=$ac_cv_path_TAR
9774 if test -n "$TAR"; then
9775   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9776 $as_echo "$TAR" >&6; }
9777 else
9778   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9779 $as_echo "no" >&6; }
9780 fi
9781 
9782 
9783   test -n "$TAR" && break
9784 done
9785 
9786     else
9787       # If it succeeded, then it was overridden by the user. We will use it
9788       # for the tool.
9789 
9790       # First remove it from the list of overridden variables, so we can test
9791       # for unknown variables in the end.
9792       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9793 
9794       # Check if the provided tool contains a complete path.
9795       tool_specified="$TAR"
9796       tool_basename="${tool_specified##*/}"
9797       if test "x$tool_basename" = "x$tool_specified"; then
9798         # A command without a complete path is provided, search $PATH.
9799         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5
9800 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;}
9801         # Extract the first word of "$tool_basename", so it can be a program name with args.
9802 set dummy $tool_basename; ac_word=$2
9803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9804 $as_echo_n "checking for $ac_word... " >&6; }
9805 if ${ac_cv_path_TAR+:} false; then :
9806   $as_echo_n "(cached) " >&6
9807 else
9808   case $TAR in
9809   [\\/]* | ?:[\\/]*)
9810   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9811   ;;
9812   *)
9813   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9814 for as_dir in $PATH
9815 do
9816   IFS=$as_save_IFS
9817   test -z "$as_dir" && as_dir=.
9818     for ac_exec_ext in '' $ac_executable_extensions; do
9819   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9820     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9821     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9822     break 2
9823   fi
9824 done
9825   done
9826 IFS=$as_save_IFS
9827 
9828   ;;
9829 esac
9830 fi
9831 TAR=$ac_cv_path_TAR
9832 if test -n "$TAR"; then
9833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9834 $as_echo "$TAR" >&6; }
9835 else
9836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9837 $as_echo "no" >&6; }
9838 fi
9839 
9840 
9841         if test "x$TAR" = x; then
9842           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9843         fi
9844       else
9845         # Otherwise we believe it is a complete path. Use it as it is.
9846         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5
9847 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;}
9848         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9849 $as_echo_n "checking for TAR... " >&6; }
9850         if test ! -x "$tool_specified"; then
9851           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9852 $as_echo "not found" >&6; }
9853           as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5
9854         fi
9855         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9856 $as_echo "$tool_specified" >&6; }
9857       fi
9858     fi
9859   fi
9860 
9861 
9862 
9863   if test "x$TAR" = x; then
9864     as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5
9865   fi
9866 
9867 
9868 
9869 
9870 
9871   # Publish this variable in the help.
9872 
9873 
9874   if test "x$TEE" = x; then
9875     # The variable is not set by user, try to locate tool using the code snippet
9876     for ac_prog in tee
9877 do
9878   # Extract the first word of "$ac_prog", so it can be a program name with args.
9879 set dummy $ac_prog; ac_word=$2
9880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9881 $as_echo_n "checking for $ac_word... " >&6; }
9882 if ${ac_cv_path_TEE+:} false; then :
9883   $as_echo_n "(cached) " >&6
9884 else
9885   case $TEE in
9886   [\\/]* | ?:[\\/]*)
9887   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9888   ;;
9889   *)
9890   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9891 for as_dir in $PATH
9892 do
9893   IFS=$as_save_IFS
9894   test -z "$as_dir" && as_dir=.
9895     for ac_exec_ext in '' $ac_executable_extensions; do
9896   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9897     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9898     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9899     break 2
9900   fi
9901 done
9902   done
9903 IFS=$as_save_IFS
9904 
9905   ;;
9906 esac
9907 fi
9908 TEE=$ac_cv_path_TEE
9909 if test -n "$TEE"; then
9910   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9911 $as_echo "$TEE" >&6; }
9912 else
9913   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9914 $as_echo "no" >&6; }
9915 fi
9916 
9917 
9918   test -n "$TEE" && break
9919 done
9920 
9921   else
9922     # The variable is set, but is it from the command line or the environment?
9923 
9924     # Try to remove the string !TEE! from our list.
9925     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/}
9926     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9927       # If it failed, the variable was not from the command line. Ignore it,
9928       # but warn the user (except for BASH, which is always set by the calling BASH).
9929       if test "xTEE" != xBASH; then
9930         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5
9931 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;}
9932       fi
9933       # Try to locate tool using the code snippet
9934       for ac_prog in tee
9935 do
9936   # Extract the first word of "$ac_prog", so it can be a program name with args.
9937 set dummy $ac_prog; ac_word=$2
9938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9939 $as_echo_n "checking for $ac_word... " >&6; }
9940 if ${ac_cv_path_TEE+:} false; then :
9941   $as_echo_n "(cached) " >&6
9942 else
9943   case $TEE in
9944   [\\/]* | ?:[\\/]*)
9945   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9946   ;;
9947   *)
9948   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9949 for as_dir in $PATH
9950 do
9951   IFS=$as_save_IFS
9952   test -z "$as_dir" && as_dir=.
9953     for ac_exec_ext in '' $ac_executable_extensions; do
9954   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9955     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9956     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9957     break 2
9958   fi
9959 done
9960   done
9961 IFS=$as_save_IFS
9962 
9963   ;;
9964 esac
9965 fi
9966 TEE=$ac_cv_path_TEE
9967 if test -n "$TEE"; then
9968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9969 $as_echo "$TEE" >&6; }
9970 else
9971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9972 $as_echo "no" >&6; }
9973 fi
9974 
9975 
9976   test -n "$TEE" && break
9977 done
9978 
9979     else
9980       # If it succeeded, then it was overridden by the user. We will use it
9981       # for the tool.
9982 
9983       # First remove it from the list of overridden variables, so we can test
9984       # for unknown variables in the end.
9985       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9986 
9987       # Check if the provided tool contains a complete path.
9988       tool_specified="$TEE"
9989       tool_basename="${tool_specified##*/}"
9990       if test "x$tool_basename" = "x$tool_specified"; then
9991         # A command without a complete path is provided, search $PATH.
9992         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5
9993 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;}
9994         # Extract the first word of "$tool_basename", so it can be a program name with args.
9995 set dummy $tool_basename; ac_word=$2
9996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9997 $as_echo_n "checking for $ac_word... " >&6; }
9998 if ${ac_cv_path_TEE+:} false; then :
9999   $as_echo_n "(cached) " >&6
10000 else
10001   case $TEE in
10002   [\\/]* | ?:[\\/]*)
10003   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
10004   ;;
10005   *)
10006   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10007 for as_dir in $PATH
10008 do
10009   IFS=$as_save_IFS
10010   test -z "$as_dir" && as_dir=.
10011     for ac_exec_ext in '' $ac_executable_extensions; do
10012   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10013     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
10014     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10015     break 2
10016   fi
10017 done
10018   done
10019 IFS=$as_save_IFS
10020 
10021   ;;
10022 esac
10023 fi
10024 TEE=$ac_cv_path_TEE
10025 if test -n "$TEE"; then
10026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
10027 $as_echo "$TEE" >&6; }
10028 else
10029   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10030 $as_echo "no" >&6; }
10031 fi
10032 
10033 
10034         if test "x$TEE" = x; then
10035           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10036         fi
10037       else
10038         # Otherwise we believe it is a complete path. Use it as it is.
10039         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5
10040 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;}
10041         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5
10042 $as_echo_n "checking for TEE... " >&6; }
10043         if test ! -x "$tool_specified"; then
10044           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10045 $as_echo "not found" >&6; }
10046           as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5
10047         fi
10048         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10049 $as_echo "$tool_specified" >&6; }
10050       fi
10051     fi
10052   fi
10053 
10054 
10055 
10056   if test "x$TEE" = x; then
10057     as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5
10058   fi
10059 
10060 
10061 
10062 
10063 
10064   # Publish this variable in the help.
10065 
10066 
10067   if test "x$TOUCH" = x; then
10068     # The variable is not set by user, try to locate tool using the code snippet
10069     for ac_prog in touch
10070 do
10071   # Extract the first word of "$ac_prog", so it can be a program name with args.
10072 set dummy $ac_prog; ac_word=$2
10073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10074 $as_echo_n "checking for $ac_word... " >&6; }
10075 if ${ac_cv_path_TOUCH+:} false; then :
10076   $as_echo_n "(cached) " >&6
10077 else
10078   case $TOUCH in
10079   [\\/]* | ?:[\\/]*)
10080   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10081   ;;
10082   *)
10083   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10084 for as_dir in $PATH
10085 do
10086   IFS=$as_save_IFS
10087   test -z "$as_dir" && as_dir=.
10088     for ac_exec_ext in '' $ac_executable_extensions; do
10089   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10090     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10091     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10092     break 2
10093   fi
10094 done
10095   done
10096 IFS=$as_save_IFS
10097 
10098   ;;
10099 esac
10100 fi
10101 TOUCH=$ac_cv_path_TOUCH
10102 if test -n "$TOUCH"; then
10103   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10104 $as_echo "$TOUCH" >&6; }
10105 else
10106   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10107 $as_echo "no" >&6; }
10108 fi
10109 
10110 
10111   test -n "$TOUCH" && break
10112 done
10113 
10114   else
10115     # The variable is set, but is it from the command line or the environment?
10116 
10117     # Try to remove the string !TOUCH! from our list.
10118     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/}
10119     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10120       # If it failed, the variable was not from the command line. Ignore it,
10121       # but warn the user (except for BASH, which is always set by the calling BASH).
10122       if test "xTOUCH" != xBASH; then
10123         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5
10124 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;}
10125       fi
10126       # Try to locate tool using the code snippet
10127       for ac_prog in touch
10128 do
10129   # Extract the first word of "$ac_prog", so it can be a program name with args.
10130 set dummy $ac_prog; ac_word=$2
10131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10132 $as_echo_n "checking for $ac_word... " >&6; }
10133 if ${ac_cv_path_TOUCH+:} false; then :
10134   $as_echo_n "(cached) " >&6
10135 else
10136   case $TOUCH in
10137   [\\/]* | ?:[\\/]*)
10138   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10139   ;;
10140   *)
10141   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10142 for as_dir in $PATH
10143 do
10144   IFS=$as_save_IFS
10145   test -z "$as_dir" && as_dir=.
10146     for ac_exec_ext in '' $ac_executable_extensions; do
10147   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10148     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10149     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10150     break 2
10151   fi
10152 done
10153   done
10154 IFS=$as_save_IFS
10155 
10156   ;;
10157 esac
10158 fi
10159 TOUCH=$ac_cv_path_TOUCH
10160 if test -n "$TOUCH"; then
10161   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10162 $as_echo "$TOUCH" >&6; }
10163 else
10164   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10165 $as_echo "no" >&6; }
10166 fi
10167 
10168 
10169   test -n "$TOUCH" && break
10170 done
10171 
10172     else
10173       # If it succeeded, then it was overridden by the user. We will use it
10174       # for the tool.
10175 
10176       # First remove it from the list of overridden variables, so we can test
10177       # for unknown variables in the end.
10178       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10179 
10180       # Check if the provided tool contains a complete path.
10181       tool_specified="$TOUCH"
10182       tool_basename="${tool_specified##*/}"
10183       if test "x$tool_basename" = "x$tool_specified"; then
10184         # A command without a complete path is provided, search $PATH.
10185         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5
10186 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;}
10187         # Extract the first word of "$tool_basename", so it can be a program name with args.
10188 set dummy $tool_basename; ac_word=$2
10189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10190 $as_echo_n "checking for $ac_word... " >&6; }
10191 if ${ac_cv_path_TOUCH+:} false; then :
10192   $as_echo_n "(cached) " >&6
10193 else
10194   case $TOUCH in
10195   [\\/]* | ?:[\\/]*)
10196   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10197   ;;
10198   *)
10199   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10200 for as_dir in $PATH
10201 do
10202   IFS=$as_save_IFS
10203   test -z "$as_dir" && as_dir=.
10204     for ac_exec_ext in '' $ac_executable_extensions; do
10205   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10206     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10207     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10208     break 2
10209   fi
10210 done
10211   done
10212 IFS=$as_save_IFS
10213 
10214   ;;
10215 esac
10216 fi
10217 TOUCH=$ac_cv_path_TOUCH
10218 if test -n "$TOUCH"; then
10219   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10220 $as_echo "$TOUCH" >&6; }
10221 else
10222   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10223 $as_echo "no" >&6; }
10224 fi
10225 
10226 
10227         if test "x$TOUCH" = x; then
10228           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10229         fi
10230       else
10231         # Otherwise we believe it is a complete path. Use it as it is.
10232         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5
10233 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;}
10234         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5
10235 $as_echo_n "checking for TOUCH... " >&6; }
10236         if test ! -x "$tool_specified"; then
10237           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10238 $as_echo "not found" >&6; }
10239           as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5
10240         fi
10241         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10242 $as_echo "$tool_specified" >&6; }
10243       fi
10244     fi
10245   fi
10246 
10247 
10248 
10249   if test "x$TOUCH" = x; then
10250     as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5
10251   fi
10252 
10253 
10254 
10255 
10256 
10257   # Publish this variable in the help.
10258 
10259 
10260   if test "x$TR" = x; then
10261     # The variable is not set by user, try to locate tool using the code snippet
10262     for ac_prog in tr
10263 do
10264   # Extract the first word of "$ac_prog", so it can be a program name with args.
10265 set dummy $ac_prog; ac_word=$2
10266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10267 $as_echo_n "checking for $ac_word... " >&6; }
10268 if ${ac_cv_path_TR+:} false; then :
10269   $as_echo_n "(cached) " >&6
10270 else
10271   case $TR in
10272   [\\/]* | ?:[\\/]*)
10273   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10274   ;;
10275   *)
10276   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10277 for as_dir in $PATH
10278 do
10279   IFS=$as_save_IFS
10280   test -z "$as_dir" && as_dir=.
10281     for ac_exec_ext in '' $ac_executable_extensions; do
10282   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10283     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10284     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10285     break 2
10286   fi
10287 done
10288   done
10289 IFS=$as_save_IFS
10290 
10291   ;;
10292 esac
10293 fi
10294 TR=$ac_cv_path_TR
10295 if test -n "$TR"; then
10296   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10297 $as_echo "$TR" >&6; }
10298 else
10299   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10300 $as_echo "no" >&6; }
10301 fi
10302 
10303 
10304   test -n "$TR" && break
10305 done
10306 
10307   else
10308     # The variable is set, but is it from the command line or the environment?
10309 
10310     # Try to remove the string !TR! from our list.
10311     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/}
10312     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10313       # If it failed, the variable was not from the command line. Ignore it,
10314       # but warn the user (except for BASH, which is always set by the calling BASH).
10315       if test "xTR" != xBASH; then
10316         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5
10317 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;}
10318       fi
10319       # Try to locate tool using the code snippet
10320       for ac_prog in tr
10321 do
10322   # Extract the first word of "$ac_prog", so it can be a program name with args.
10323 set dummy $ac_prog; ac_word=$2
10324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10325 $as_echo_n "checking for $ac_word... " >&6; }
10326 if ${ac_cv_path_TR+:} false; then :
10327   $as_echo_n "(cached) " >&6
10328 else
10329   case $TR in
10330   [\\/]* | ?:[\\/]*)
10331   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10332   ;;
10333   *)
10334   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10335 for as_dir in $PATH
10336 do
10337   IFS=$as_save_IFS
10338   test -z "$as_dir" && as_dir=.
10339     for ac_exec_ext in '' $ac_executable_extensions; do
10340   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10341     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10342     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10343     break 2
10344   fi
10345 done
10346   done
10347 IFS=$as_save_IFS
10348 
10349   ;;
10350 esac
10351 fi
10352 TR=$ac_cv_path_TR
10353 if test -n "$TR"; then
10354   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10355 $as_echo "$TR" >&6; }
10356 else
10357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10358 $as_echo "no" >&6; }
10359 fi
10360 
10361 
10362   test -n "$TR" && break
10363 done
10364 
10365     else
10366       # If it succeeded, then it was overridden by the user. We will use it
10367       # for the tool.
10368 
10369       # First remove it from the list of overridden variables, so we can test
10370       # for unknown variables in the end.
10371       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10372 
10373       # Check if the provided tool contains a complete path.
10374       tool_specified="$TR"
10375       tool_basename="${tool_specified##*/}"
10376       if test "x$tool_basename" = "x$tool_specified"; then
10377         # A command without a complete path is provided, search $PATH.
10378         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5
10379 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;}
10380         # Extract the first word of "$tool_basename", so it can be a program name with args.
10381 set dummy $tool_basename; ac_word=$2
10382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10383 $as_echo_n "checking for $ac_word... " >&6; }
10384 if ${ac_cv_path_TR+:} false; then :
10385   $as_echo_n "(cached) " >&6
10386 else
10387   case $TR in
10388   [\\/]* | ?:[\\/]*)
10389   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10390   ;;
10391   *)
10392   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10393 for as_dir in $PATH
10394 do
10395   IFS=$as_save_IFS
10396   test -z "$as_dir" && as_dir=.
10397     for ac_exec_ext in '' $ac_executable_extensions; do
10398   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10399     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10400     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10401     break 2
10402   fi
10403 done
10404   done
10405 IFS=$as_save_IFS
10406 
10407   ;;
10408 esac
10409 fi
10410 TR=$ac_cv_path_TR
10411 if test -n "$TR"; then
10412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10413 $as_echo "$TR" >&6; }
10414 else
10415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10416 $as_echo "no" >&6; }
10417 fi
10418 
10419 
10420         if test "x$TR" = x; then
10421           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10422         fi
10423       else
10424         # Otherwise we believe it is a complete path. Use it as it is.
10425         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5
10426 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;}
10427         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5
10428 $as_echo_n "checking for TR... " >&6; }
10429         if test ! -x "$tool_specified"; then
10430           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10431 $as_echo "not found" >&6; }
10432           as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5
10433         fi
10434         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10435 $as_echo "$tool_specified" >&6; }
10436       fi
10437     fi
10438   fi
10439 
10440 
10441 
10442   if test "x$TR" = x; then
10443     as_fn_error $? "Could not find required tool for TR" "$LINENO" 5
10444   fi
10445 
10446 
10447 
10448 
10449 
10450   # Publish this variable in the help.
10451 
10452 
10453   if test "x$UNAME" = x; then
10454     # The variable is not set by user, try to locate tool using the code snippet
10455     for ac_prog in uname
10456 do
10457   # Extract the first word of "$ac_prog", so it can be a program name with args.
10458 set dummy $ac_prog; ac_word=$2
10459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10460 $as_echo_n "checking for $ac_word... " >&6; }
10461 if ${ac_cv_path_UNAME+:} false; then :
10462   $as_echo_n "(cached) " >&6
10463 else
10464   case $UNAME in
10465   [\\/]* | ?:[\\/]*)
10466   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10467   ;;
10468   *)
10469   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10470 for as_dir in $PATH
10471 do
10472   IFS=$as_save_IFS
10473   test -z "$as_dir" && as_dir=.
10474     for ac_exec_ext in '' $ac_executable_extensions; do
10475   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10476     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10477     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10478     break 2
10479   fi
10480 done
10481   done
10482 IFS=$as_save_IFS
10483 
10484   ;;
10485 esac
10486 fi
10487 UNAME=$ac_cv_path_UNAME
10488 if test -n "$UNAME"; then
10489   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10490 $as_echo "$UNAME" >&6; }
10491 else
10492   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10493 $as_echo "no" >&6; }
10494 fi
10495 
10496 
10497   test -n "$UNAME" && break
10498 done
10499 
10500   else
10501     # The variable is set, but is it from the command line or the environment?
10502 
10503     # Try to remove the string !UNAME! from our list.
10504     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/}
10505     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10506       # If it failed, the variable was not from the command line. Ignore it,
10507       # but warn the user (except for BASH, which is always set by the calling BASH).
10508       if test "xUNAME" != xBASH; then
10509         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5
10510 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;}
10511       fi
10512       # Try to locate tool using the code snippet
10513       for ac_prog in uname
10514 do
10515   # Extract the first word of "$ac_prog", so it can be a program name with args.
10516 set dummy $ac_prog; ac_word=$2
10517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10518 $as_echo_n "checking for $ac_word... " >&6; }
10519 if ${ac_cv_path_UNAME+:} false; then :
10520   $as_echo_n "(cached) " >&6
10521 else
10522   case $UNAME in
10523   [\\/]* | ?:[\\/]*)
10524   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10525   ;;
10526   *)
10527   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10528 for as_dir in $PATH
10529 do
10530   IFS=$as_save_IFS
10531   test -z "$as_dir" && as_dir=.
10532     for ac_exec_ext in '' $ac_executable_extensions; do
10533   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10534     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10535     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10536     break 2
10537   fi
10538 done
10539   done
10540 IFS=$as_save_IFS
10541 
10542   ;;
10543 esac
10544 fi
10545 UNAME=$ac_cv_path_UNAME
10546 if test -n "$UNAME"; then
10547   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10548 $as_echo "$UNAME" >&6; }
10549 else
10550   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10551 $as_echo "no" >&6; }
10552 fi
10553 
10554 
10555   test -n "$UNAME" && break
10556 done
10557 
10558     else
10559       # If it succeeded, then it was overridden by the user. We will use it
10560       # for the tool.
10561 
10562       # First remove it from the list of overridden variables, so we can test
10563       # for unknown variables in the end.
10564       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10565 
10566       # Check if the provided tool contains a complete path.
10567       tool_specified="$UNAME"
10568       tool_basename="${tool_specified##*/}"
10569       if test "x$tool_basename" = "x$tool_specified"; then
10570         # A command without a complete path is provided, search $PATH.
10571         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5
10572 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;}
10573         # Extract the first word of "$tool_basename", so it can be a program name with args.
10574 set dummy $tool_basename; ac_word=$2
10575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10576 $as_echo_n "checking for $ac_word... " >&6; }
10577 if ${ac_cv_path_UNAME+:} false; then :
10578   $as_echo_n "(cached) " >&6
10579 else
10580   case $UNAME in
10581   [\\/]* | ?:[\\/]*)
10582   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10583   ;;
10584   *)
10585   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10586 for as_dir in $PATH
10587 do
10588   IFS=$as_save_IFS
10589   test -z "$as_dir" && as_dir=.
10590     for ac_exec_ext in '' $ac_executable_extensions; do
10591   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10592     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10593     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10594     break 2
10595   fi
10596 done
10597   done
10598 IFS=$as_save_IFS
10599 
10600   ;;
10601 esac
10602 fi
10603 UNAME=$ac_cv_path_UNAME
10604 if test -n "$UNAME"; then
10605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10606 $as_echo "$UNAME" >&6; }
10607 else
10608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10609 $as_echo "no" >&6; }
10610 fi
10611 
10612 
10613         if test "x$UNAME" = x; then
10614           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10615         fi
10616       else
10617         # Otherwise we believe it is a complete path. Use it as it is.
10618         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5
10619 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;}
10620         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5
10621 $as_echo_n "checking for UNAME... " >&6; }
10622         if test ! -x "$tool_specified"; then
10623           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10624 $as_echo "not found" >&6; }
10625           as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
10626         fi
10627         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10628 $as_echo "$tool_specified" >&6; }
10629       fi
10630     fi
10631   fi
10632 
10633 
10634 
10635   if test "x$UNAME" = x; then
10636     as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5
10637   fi
10638 
10639 
10640 
10641 
10642 
10643   # Publish this variable in the help.
10644 
10645 
10646   if test "x$UNIQ" = x; then
10647     # The variable is not set by user, try to locate tool using the code snippet
10648     for ac_prog in uniq
10649 do
10650   # Extract the first word of "$ac_prog", so it can be a program name with args.
10651 set dummy $ac_prog; ac_word=$2
10652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10653 $as_echo_n "checking for $ac_word... " >&6; }
10654 if ${ac_cv_path_UNIQ+:} false; then :
10655   $as_echo_n "(cached) " >&6
10656 else
10657   case $UNIQ in
10658   [\\/]* | ?:[\\/]*)
10659   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10660   ;;
10661   *)
10662   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10663 for as_dir in $PATH
10664 do
10665   IFS=$as_save_IFS
10666   test -z "$as_dir" && as_dir=.
10667     for ac_exec_ext in '' $ac_executable_extensions; do
10668   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10669     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10670     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10671     break 2
10672   fi
10673 done
10674   done
10675 IFS=$as_save_IFS
10676 
10677   ;;
10678 esac
10679 fi
10680 UNIQ=$ac_cv_path_UNIQ
10681 if test -n "$UNIQ"; then
10682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10683 $as_echo "$UNIQ" >&6; }
10684 else
10685   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10686 $as_echo "no" >&6; }
10687 fi
10688 
10689 
10690   test -n "$UNIQ" && break
10691 done
10692 
10693   else
10694     # The variable is set, but is it from the command line or the environment?
10695 
10696     # Try to remove the string !UNIQ! from our list.
10697     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/}
10698     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10699       # If it failed, the variable was not from the command line. Ignore it,
10700       # but warn the user (except for BASH, which is always set by the calling BASH).
10701       if test "xUNIQ" != xBASH; then
10702         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5
10703 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;}
10704       fi
10705       # Try to locate tool using the code snippet
10706       for ac_prog in uniq
10707 do
10708   # Extract the first word of "$ac_prog", so it can be a program name with args.
10709 set dummy $ac_prog; ac_word=$2
10710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10711 $as_echo_n "checking for $ac_word... " >&6; }
10712 if ${ac_cv_path_UNIQ+:} false; then :
10713   $as_echo_n "(cached) " >&6
10714 else
10715   case $UNIQ in
10716   [\\/]* | ?:[\\/]*)
10717   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10718   ;;
10719   *)
10720   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10721 for as_dir in $PATH
10722 do
10723   IFS=$as_save_IFS
10724   test -z "$as_dir" && as_dir=.
10725     for ac_exec_ext in '' $ac_executable_extensions; do
10726   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10727     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10728     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10729     break 2
10730   fi
10731 done
10732   done
10733 IFS=$as_save_IFS
10734 
10735   ;;
10736 esac
10737 fi
10738 UNIQ=$ac_cv_path_UNIQ
10739 if test -n "$UNIQ"; then
10740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10741 $as_echo "$UNIQ" >&6; }
10742 else
10743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10744 $as_echo "no" >&6; }
10745 fi
10746 
10747 
10748   test -n "$UNIQ" && break
10749 done
10750 
10751     else
10752       # If it succeeded, then it was overridden by the user. We will use it
10753       # for the tool.
10754 
10755       # First remove it from the list of overridden variables, so we can test
10756       # for unknown variables in the end.
10757       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10758 
10759       # Check if the provided tool contains a complete path.
10760       tool_specified="$UNIQ"
10761       tool_basename="${tool_specified##*/}"
10762       if test "x$tool_basename" = "x$tool_specified"; then
10763         # A command without a complete path is provided, search $PATH.
10764         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5
10765 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;}
10766         # Extract the first word of "$tool_basename", so it can be a program name with args.
10767 set dummy $tool_basename; ac_word=$2
10768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10769 $as_echo_n "checking for $ac_word... " >&6; }
10770 if ${ac_cv_path_UNIQ+:} false; then :
10771   $as_echo_n "(cached) " >&6
10772 else
10773   case $UNIQ in
10774   [\\/]* | ?:[\\/]*)
10775   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10776   ;;
10777   *)
10778   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10779 for as_dir in $PATH
10780 do
10781   IFS=$as_save_IFS
10782   test -z "$as_dir" && as_dir=.
10783     for ac_exec_ext in '' $ac_executable_extensions; do
10784   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10785     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10786     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10787     break 2
10788   fi
10789 done
10790   done
10791 IFS=$as_save_IFS
10792 
10793   ;;
10794 esac
10795 fi
10796 UNIQ=$ac_cv_path_UNIQ
10797 if test -n "$UNIQ"; then
10798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10799 $as_echo "$UNIQ" >&6; }
10800 else
10801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10802 $as_echo "no" >&6; }
10803 fi
10804 
10805 
10806         if test "x$UNIQ" = x; then
10807           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10808         fi
10809       else
10810         # Otherwise we believe it is a complete path. Use it as it is.
10811         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5
10812 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;}
10813         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5
10814 $as_echo_n "checking for UNIQ... " >&6; }
10815         if test ! -x "$tool_specified"; then
10816           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10817 $as_echo "not found" >&6; }
10818           as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5
10819         fi
10820         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10821 $as_echo "$tool_specified" >&6; }
10822       fi
10823     fi
10824   fi
10825 
10826 
10827 
10828   if test "x$UNIQ" = x; then
10829     as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5
10830   fi
10831 
10832 
10833 
10834 
10835 
10836   # Publish this variable in the help.
10837 
10838 
10839   if test "x$WC" = x; then
10840     # The variable is not set by user, try to locate tool using the code snippet
10841     for ac_prog in wc
10842 do
10843   # Extract the first word of "$ac_prog", so it can be a program name with args.
10844 set dummy $ac_prog; ac_word=$2
10845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10846 $as_echo_n "checking for $ac_word... " >&6; }
10847 if ${ac_cv_path_WC+:} false; then :
10848   $as_echo_n "(cached) " >&6
10849 else
10850   case $WC in
10851   [\\/]* | ?:[\\/]*)
10852   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10853   ;;
10854   *)
10855   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10856 for as_dir in $PATH
10857 do
10858   IFS=$as_save_IFS
10859   test -z "$as_dir" && as_dir=.
10860     for ac_exec_ext in '' $ac_executable_extensions; do
10861   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10862     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10864     break 2
10865   fi
10866 done
10867   done
10868 IFS=$as_save_IFS
10869 
10870   ;;
10871 esac
10872 fi
10873 WC=$ac_cv_path_WC
10874 if test -n "$WC"; then
10875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10876 $as_echo "$WC" >&6; }
10877 else
10878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10879 $as_echo "no" >&6; }
10880 fi
10881 
10882 
10883   test -n "$WC" && break
10884 done
10885 
10886   else
10887     # The variable is set, but is it from the command line or the environment?
10888 
10889     # Try to remove the string !WC! from our list.
10890     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/}
10891     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10892       # If it failed, the variable was not from the command line. Ignore it,
10893       # but warn the user (except for BASH, which is always set by the calling BASH).
10894       if test "xWC" != xBASH; then
10895         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5
10896 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;}
10897       fi
10898       # Try to locate tool using the code snippet
10899       for ac_prog in wc
10900 do
10901   # Extract the first word of "$ac_prog", so it can be a program name with args.
10902 set dummy $ac_prog; ac_word=$2
10903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10904 $as_echo_n "checking for $ac_word... " >&6; }
10905 if ${ac_cv_path_WC+:} false; then :
10906   $as_echo_n "(cached) " >&6
10907 else
10908   case $WC in
10909   [\\/]* | ?:[\\/]*)
10910   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10911   ;;
10912   *)
10913   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10914 for as_dir in $PATH
10915 do
10916   IFS=$as_save_IFS
10917   test -z "$as_dir" && as_dir=.
10918     for ac_exec_ext in '' $ac_executable_extensions; do
10919   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10920     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10921     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10922     break 2
10923   fi
10924 done
10925   done
10926 IFS=$as_save_IFS
10927 
10928   ;;
10929 esac
10930 fi
10931 WC=$ac_cv_path_WC
10932 if test -n "$WC"; then
10933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10934 $as_echo "$WC" >&6; }
10935 else
10936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10937 $as_echo "no" >&6; }
10938 fi
10939 
10940 
10941   test -n "$WC" && break
10942 done
10943 
10944     else
10945       # If it succeeded, then it was overridden by the user. We will use it
10946       # for the tool.
10947 
10948       # First remove it from the list of overridden variables, so we can test
10949       # for unknown variables in the end.
10950       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10951 
10952       # Check if the provided tool contains a complete path.
10953       tool_specified="$WC"
10954       tool_basename="${tool_specified##*/}"
10955       if test "x$tool_basename" = "x$tool_specified"; then
10956         # A command without a complete path is provided, search $PATH.
10957         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5
10958 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;}
10959         # Extract the first word of "$tool_basename", so it can be a program name with args.
10960 set dummy $tool_basename; ac_word=$2
10961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10962 $as_echo_n "checking for $ac_word... " >&6; }
10963 if ${ac_cv_path_WC+:} false; then :
10964   $as_echo_n "(cached) " >&6
10965 else
10966   case $WC in
10967   [\\/]* | ?:[\\/]*)
10968   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10969   ;;
10970   *)
10971   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10972 for as_dir in $PATH
10973 do
10974   IFS=$as_save_IFS
10975   test -z "$as_dir" && as_dir=.
10976     for ac_exec_ext in '' $ac_executable_extensions; do
10977   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10978     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10979     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10980     break 2
10981   fi
10982 done
10983   done
10984 IFS=$as_save_IFS
10985 
10986   ;;
10987 esac
10988 fi
10989 WC=$ac_cv_path_WC
10990 if test -n "$WC"; then
10991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10992 $as_echo "$WC" >&6; }
10993 else
10994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10995 $as_echo "no" >&6; }
10996 fi
10997 
10998 
10999         if test "x$WC" = x; then
11000           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11001         fi
11002       else
11003         # Otherwise we believe it is a complete path. Use it as it is.
11004         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5
11005 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;}
11006         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5
11007 $as_echo_n "checking for WC... " >&6; }
11008         if test ! -x "$tool_specified"; then
11009           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11010 $as_echo "not found" >&6; }
11011           as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5
11012         fi
11013         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11014 $as_echo "$tool_specified" >&6; }
11015       fi
11016     fi
11017   fi
11018 
11019 
11020 
11021   if test "x$WC" = x; then
11022     as_fn_error $? "Could not find required tool for WC" "$LINENO" 5
11023   fi
11024 
11025 
11026 
11027 
11028 
11029   # Publish this variable in the help.
11030 
11031 
11032   if test "x$WHICH" = x; then
11033     # The variable is not set by user, try to locate tool using the code snippet
11034     for ac_prog in which
11035 do
11036   # Extract the first word of "$ac_prog", so it can be a program name with args.
11037 set dummy $ac_prog; ac_word=$2
11038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11039 $as_echo_n "checking for $ac_word... " >&6; }
11040 if ${ac_cv_path_WHICH+:} false; then :
11041   $as_echo_n "(cached) " >&6
11042 else
11043   case $WHICH in
11044   [\\/]* | ?:[\\/]*)
11045   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11046   ;;
11047   *)
11048   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11049 for as_dir in $PATH
11050 do
11051   IFS=$as_save_IFS
11052   test -z "$as_dir" && as_dir=.
11053     for ac_exec_ext in '' $ac_executable_extensions; do
11054   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11055     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11056     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11057     break 2
11058   fi
11059 done
11060   done
11061 IFS=$as_save_IFS
11062 
11063   ;;
11064 esac
11065 fi
11066 WHICH=$ac_cv_path_WHICH
11067 if test -n "$WHICH"; then
11068   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11069 $as_echo "$WHICH" >&6; }
11070 else
11071   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11072 $as_echo "no" >&6; }
11073 fi
11074 
11075 
11076   test -n "$WHICH" && break
11077 done
11078 
11079   else
11080     # The variable is set, but is it from the command line or the environment?
11081 
11082     # Try to remove the string !WHICH! from our list.
11083     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/}
11084     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11085       # If it failed, the variable was not from the command line. Ignore it,
11086       # but warn the user (except for BASH, which is always set by the calling BASH).
11087       if test "xWHICH" != xBASH; then
11088         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5
11089 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;}
11090       fi
11091       # Try to locate tool using the code snippet
11092       for ac_prog in which
11093 do
11094   # Extract the first word of "$ac_prog", so it can be a program name with args.
11095 set dummy $ac_prog; ac_word=$2
11096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11097 $as_echo_n "checking for $ac_word... " >&6; }
11098 if ${ac_cv_path_WHICH+:} false; then :
11099   $as_echo_n "(cached) " >&6
11100 else
11101   case $WHICH in
11102   [\\/]* | ?:[\\/]*)
11103   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11104   ;;
11105   *)
11106   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11107 for as_dir in $PATH
11108 do
11109   IFS=$as_save_IFS
11110   test -z "$as_dir" && as_dir=.
11111     for ac_exec_ext in '' $ac_executable_extensions; do
11112   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11113     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11114     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11115     break 2
11116   fi
11117 done
11118   done
11119 IFS=$as_save_IFS
11120 
11121   ;;
11122 esac
11123 fi
11124 WHICH=$ac_cv_path_WHICH
11125 if test -n "$WHICH"; then
11126   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11127 $as_echo "$WHICH" >&6; }
11128 else
11129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11130 $as_echo "no" >&6; }
11131 fi
11132 
11133 
11134   test -n "$WHICH" && break
11135 done
11136 
11137     else
11138       # If it succeeded, then it was overridden by the user. We will use it
11139       # for the tool.
11140 
11141       # First remove it from the list of overridden variables, so we can test
11142       # for unknown variables in the end.
11143       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11144 
11145       # Check if the provided tool contains a complete path.
11146       tool_specified="$WHICH"
11147       tool_basename="${tool_specified##*/}"
11148       if test "x$tool_basename" = "x$tool_specified"; then
11149         # A command without a complete path is provided, search $PATH.
11150         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5
11151 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;}
11152         # Extract the first word of "$tool_basename", so it can be a program name with args.
11153 set dummy $tool_basename; ac_word=$2
11154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11155 $as_echo_n "checking for $ac_word... " >&6; }
11156 if ${ac_cv_path_WHICH+:} false; then :
11157   $as_echo_n "(cached) " >&6
11158 else
11159   case $WHICH in
11160   [\\/]* | ?:[\\/]*)
11161   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11162   ;;
11163   *)
11164   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11165 for as_dir in $PATH
11166 do
11167   IFS=$as_save_IFS
11168   test -z "$as_dir" && as_dir=.
11169     for ac_exec_ext in '' $ac_executable_extensions; do
11170   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11171     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11172     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11173     break 2
11174   fi
11175 done
11176   done
11177 IFS=$as_save_IFS
11178 
11179   ;;
11180 esac
11181 fi
11182 WHICH=$ac_cv_path_WHICH
11183 if test -n "$WHICH"; then
11184   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11185 $as_echo "$WHICH" >&6; }
11186 else
11187   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11188 $as_echo "no" >&6; }
11189 fi
11190 
11191 
11192         if test "x$WHICH" = x; then
11193           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11194         fi
11195       else
11196         # Otherwise we believe it is a complete path. Use it as it is.
11197         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5
11198 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;}
11199         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5
11200 $as_echo_n "checking for WHICH... " >&6; }
11201         if test ! -x "$tool_specified"; then
11202           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11203 $as_echo "not found" >&6; }
11204           as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5
11205         fi
11206         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11207 $as_echo "$tool_specified" >&6; }
11208       fi
11209     fi
11210   fi
11211 
11212 
11213 
11214   if test "x$WHICH" = x; then
11215     as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5
11216   fi
11217 
11218 
11219 
11220 
11221 
11222   # Publish this variable in the help.
11223 
11224 
11225   if test "x$XARGS" = x; then
11226     # The variable is not set by user, try to locate tool using the code snippet
11227     for ac_prog in xargs
11228 do
11229   # Extract the first word of "$ac_prog", so it can be a program name with args.
11230 set dummy $ac_prog; ac_word=$2
11231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11232 $as_echo_n "checking for $ac_word... " >&6; }
11233 if ${ac_cv_path_XARGS+:} false; then :
11234   $as_echo_n "(cached) " >&6
11235 else
11236   case $XARGS in
11237   [\\/]* | ?:[\\/]*)
11238   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11239   ;;
11240   *)
11241   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11242 for as_dir in $PATH
11243 do
11244   IFS=$as_save_IFS
11245   test -z "$as_dir" && as_dir=.
11246     for ac_exec_ext in '' $ac_executable_extensions; do
11247   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11248     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11249     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11250     break 2
11251   fi
11252 done
11253   done
11254 IFS=$as_save_IFS
11255 
11256   ;;
11257 esac
11258 fi
11259 XARGS=$ac_cv_path_XARGS
11260 if test -n "$XARGS"; then
11261   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11262 $as_echo "$XARGS" >&6; }
11263 else
11264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11265 $as_echo "no" >&6; }
11266 fi
11267 
11268 
11269   test -n "$XARGS" && break
11270 done
11271 
11272   else
11273     # The variable is set, but is it from the command line or the environment?
11274 
11275     # Try to remove the string !XARGS! from our list.
11276     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/}
11277     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11278       # If it failed, the variable was not from the command line. Ignore it,
11279       # but warn the user (except for BASH, which is always set by the calling BASH).
11280       if test "xXARGS" != xBASH; then
11281         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5
11282 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;}
11283       fi
11284       # Try to locate tool using the code snippet
11285       for ac_prog in xargs
11286 do
11287   # Extract the first word of "$ac_prog", so it can be a program name with args.
11288 set dummy $ac_prog; ac_word=$2
11289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11290 $as_echo_n "checking for $ac_word... " >&6; }
11291 if ${ac_cv_path_XARGS+:} false; then :
11292   $as_echo_n "(cached) " >&6
11293 else
11294   case $XARGS in
11295   [\\/]* | ?:[\\/]*)
11296   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11297   ;;
11298   *)
11299   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11300 for as_dir in $PATH
11301 do
11302   IFS=$as_save_IFS
11303   test -z "$as_dir" && as_dir=.
11304     for ac_exec_ext in '' $ac_executable_extensions; do
11305   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11306     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11307     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11308     break 2
11309   fi
11310 done
11311   done
11312 IFS=$as_save_IFS
11313 
11314   ;;
11315 esac
11316 fi
11317 XARGS=$ac_cv_path_XARGS
11318 if test -n "$XARGS"; then
11319   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11320 $as_echo "$XARGS" >&6; }
11321 else
11322   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11323 $as_echo "no" >&6; }
11324 fi
11325 
11326 
11327   test -n "$XARGS" && break
11328 done
11329 
11330     else
11331       # If it succeeded, then it was overridden by the user. We will use it
11332       # for the tool.
11333 
11334       # First remove it from the list of overridden variables, so we can test
11335       # for unknown variables in the end.
11336       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11337 
11338       # Check if the provided tool contains a complete path.
11339       tool_specified="$XARGS"
11340       tool_basename="${tool_specified##*/}"
11341       if test "x$tool_basename" = "x$tool_specified"; then
11342         # A command without a complete path is provided, search $PATH.
11343         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5
11344 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;}
11345         # Extract the first word of "$tool_basename", so it can be a program name with args.
11346 set dummy $tool_basename; ac_word=$2
11347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11348 $as_echo_n "checking for $ac_word... " >&6; }
11349 if ${ac_cv_path_XARGS+:} false; then :
11350   $as_echo_n "(cached) " >&6
11351 else
11352   case $XARGS in
11353   [\\/]* | ?:[\\/]*)
11354   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11355   ;;
11356   *)
11357   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11358 for as_dir in $PATH
11359 do
11360   IFS=$as_save_IFS
11361   test -z "$as_dir" && as_dir=.
11362     for ac_exec_ext in '' $ac_executable_extensions; do
11363   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11364     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11365     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11366     break 2
11367   fi
11368 done
11369   done
11370 IFS=$as_save_IFS
11371 
11372   ;;
11373 esac
11374 fi
11375 XARGS=$ac_cv_path_XARGS
11376 if test -n "$XARGS"; then
11377   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11378 $as_echo "$XARGS" >&6; }
11379 else
11380   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11381 $as_echo "no" >&6; }
11382 fi
11383 
11384 
11385         if test "x$XARGS" = x; then
11386           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11387         fi
11388       else
11389         # Otherwise we believe it is a complete path. Use it as it is.
11390         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5
11391 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;}
11392         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5
11393 $as_echo_n "checking for XARGS... " >&6; }
11394         if test ! -x "$tool_specified"; then
11395           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11396 $as_echo "not found" >&6; }
11397           as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5
11398         fi
11399         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11400 $as_echo "$tool_specified" >&6; }
11401       fi
11402     fi
11403   fi
11404 
11405 
11406 
11407   if test "x$XARGS" = x; then
11408     as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5
11409   fi
11410 
11411 
11412 
11413   # Then required tools that require some special treatment.
11414 
11415 
11416   # Publish this variable in the help.
11417 
11418 
11419   if test "x$AWK" = x; then
11420     # The variable is not set by user, try to locate tool using the code snippet
11421     for ac_prog in gawk mawk nawk awk
11422 do
11423   # Extract the first word of "$ac_prog", so it can be a program name with args.
11424 set dummy $ac_prog; ac_word=$2
11425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11426 $as_echo_n "checking for $ac_word... " >&6; }
11427 if ${ac_cv_prog_AWK+:} false; then :
11428   $as_echo_n "(cached) " >&6
11429 else
11430   if test -n "$AWK"; then
11431   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11432 else
11433 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11434 for as_dir in $PATH
11435 do
11436   IFS=$as_save_IFS
11437   test -z "$as_dir" && as_dir=.
11438     for ac_exec_ext in '' $ac_executable_extensions; do
11439   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11440     ac_cv_prog_AWK="$ac_prog"
11441     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11442     break 2
11443   fi
11444 done
11445   done
11446 IFS=$as_save_IFS
11447 
11448 fi
11449 fi
11450 AWK=$ac_cv_prog_AWK
11451 if test -n "$AWK"; then
11452   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11453 $as_echo "$AWK" >&6; }
11454 else
11455   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11456 $as_echo "no" >&6; }
11457 fi
11458 
11459 
11460   test -n "$AWK" && break
11461 done
11462 
11463   else
11464     # The variable is set, but is it from the command line or the environment?
11465 
11466     # Try to remove the string !AWK! from our list.
11467     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/}
11468     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11469       # If it failed, the variable was not from the command line. Ignore it,
11470       # but warn the user (except for BASH, which is always set by the calling BASH).
11471       if test "xAWK" != xBASH; then
11472         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5
11473 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;}
11474       fi
11475       # Try to locate tool using the code snippet
11476       for ac_prog in gawk mawk nawk awk
11477 do
11478   # Extract the first word of "$ac_prog", so it can be a program name with args.
11479 set dummy $ac_prog; ac_word=$2
11480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11481 $as_echo_n "checking for $ac_word... " >&6; }
11482 if ${ac_cv_prog_AWK+:} false; then :
11483   $as_echo_n "(cached) " >&6
11484 else
11485   if test -n "$AWK"; then
11486   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11487 else
11488 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11489 for as_dir in $PATH
11490 do
11491   IFS=$as_save_IFS
11492   test -z "$as_dir" && as_dir=.
11493     for ac_exec_ext in '' $ac_executable_extensions; do
11494   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11495     ac_cv_prog_AWK="$ac_prog"
11496     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11497     break 2
11498   fi
11499 done
11500   done
11501 IFS=$as_save_IFS
11502 
11503 fi
11504 fi
11505 AWK=$ac_cv_prog_AWK
11506 if test -n "$AWK"; then
11507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11508 $as_echo "$AWK" >&6; }
11509 else
11510   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11511 $as_echo "no" >&6; }
11512 fi
11513 
11514 
11515   test -n "$AWK" && break
11516 done
11517 
11518     else
11519       # If it succeeded, then it was overridden by the user. We will use it
11520       # for the tool.
11521 
11522       # First remove it from the list of overridden variables, so we can test
11523       # for unknown variables in the end.
11524       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11525 
11526       # Check if the provided tool contains a complete path.
11527       tool_specified="$AWK"
11528       tool_basename="${tool_specified##*/}"
11529       if test "x$tool_basename" = "x$tool_specified"; then
11530         # A command without a complete path is provided, search $PATH.
11531         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5
11532 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;}
11533         # Extract the first word of "$tool_basename", so it can be a program name with args.
11534 set dummy $tool_basename; ac_word=$2
11535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11536 $as_echo_n "checking for $ac_word... " >&6; }
11537 if ${ac_cv_path_AWK+:} false; then :
11538   $as_echo_n "(cached) " >&6
11539 else
11540   case $AWK in
11541   [\\/]* | ?:[\\/]*)
11542   ac_cv_path_AWK="$AWK" # Let the user override the test with a path.
11543   ;;
11544   *)
11545   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11546 for as_dir in $PATH
11547 do
11548   IFS=$as_save_IFS
11549   test -z "$as_dir" && as_dir=.
11550     for ac_exec_ext in '' $ac_executable_extensions; do
11551   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11552     ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext"
11553     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11554     break 2
11555   fi
11556 done
11557   done
11558 IFS=$as_save_IFS
11559 
11560   ;;
11561 esac
11562 fi
11563 AWK=$ac_cv_path_AWK
11564 if test -n "$AWK"; then
11565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11566 $as_echo "$AWK" >&6; }
11567 else
11568   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11569 $as_echo "no" >&6; }
11570 fi
11571 
11572 
11573         if test "x$AWK" = x; then
11574           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11575         fi
11576       else
11577         # Otherwise we believe it is a complete path. Use it as it is.
11578         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5
11579 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;}
11580         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5
11581 $as_echo_n "checking for AWK... " >&6; }
11582         if test ! -x "$tool_specified"; then
11583           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11584 $as_echo "not found" >&6; }
11585           as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5
11586         fi
11587         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11588 $as_echo "$tool_specified" >&6; }
11589       fi
11590     fi
11591   fi
11592 
11593 
11594   if test "x$AWK" = x; then
11595     as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5
11596   fi
11597 
11598 
11599 
11600 
11601   # Publish this variable in the help.
11602 
11603 
11604   if test "x$GREP" = x; then
11605     # The variable is not set by user, try to locate tool using the code snippet
11606     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11607 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11608 if ${ac_cv_path_GREP+:} false; then :
11609   $as_echo_n "(cached) " >&6
11610 else
11611   if test -z "$GREP"; then
11612   ac_path_GREP_found=false
11613   # Loop through the user's path and test for each of PROGNAME-LIST
11614   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11615 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11616 do
11617   IFS=$as_save_IFS
11618   test -z "$as_dir" && as_dir=.
11619     for ac_prog in grep ggrep; do
11620     for ac_exec_ext in '' $ac_executable_extensions; do
11621       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11622       as_fn_executable_p "$ac_path_GREP" || continue
11623 # Check for GNU ac_path_GREP and select it if it is found.
11624   # Check for GNU $ac_path_GREP
11625 case `"$ac_path_GREP" --version 2>&1` in
11626 *GNU*)
11627   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11628 *)
11629   ac_count=0
11630   $as_echo_n 0123456789 >"conftest.in"
11631   while :
11632   do
11633     cat "conftest.in" "conftest.in" >"conftest.tmp"
11634     mv "conftest.tmp" "conftest.in"
11635     cp "conftest.in" "conftest.nl"
11636     $as_echo 'GREP' >> "conftest.nl"
11637     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11638     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11639     as_fn_arith $ac_count + 1 && ac_count=$as_val
11640     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11641       # Best one so far, save it but keep looking for a better one
11642       ac_cv_path_GREP="$ac_path_GREP"
11643       ac_path_GREP_max=$ac_count
11644     fi
11645     # 10*(2^10) chars as input seems more than enough
11646     test $ac_count -gt 10 && break
11647   done
11648   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11649 esac
11650 
11651       $ac_path_GREP_found && break 3
11652     done
11653   done
11654   done
11655 IFS=$as_save_IFS
11656   if test -z "$ac_cv_path_GREP"; then
11657     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11658   fi
11659 else
11660   ac_cv_path_GREP=$GREP
11661 fi
11662 
11663 fi
11664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11665 $as_echo "$ac_cv_path_GREP" >&6; }
11666  GREP="$ac_cv_path_GREP"
11667 
11668 
11669   else
11670     # The variable is set, but is it from the command line or the environment?
11671 
11672     # Try to remove the string !GREP! from our list.
11673     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/}
11674     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11675       # If it failed, the variable was not from the command line. Ignore it,
11676       # but warn the user (except for BASH, which is always set by the calling BASH).
11677       if test "xGREP" != xBASH; then
11678         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5
11679 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;}
11680       fi
11681       # Try to locate tool using the code snippet
11682       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11683 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11684 if ${ac_cv_path_GREP+:} false; then :
11685   $as_echo_n "(cached) " >&6
11686 else
11687   if test -z "$GREP"; then
11688   ac_path_GREP_found=false
11689   # Loop through the user's path and test for each of PROGNAME-LIST
11690   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11691 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11692 do
11693   IFS=$as_save_IFS
11694   test -z "$as_dir" && as_dir=.
11695     for ac_prog in grep ggrep; do
11696     for ac_exec_ext in '' $ac_executable_extensions; do
11697       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11698       as_fn_executable_p "$ac_path_GREP" || continue
11699 # Check for GNU ac_path_GREP and select it if it is found.
11700   # Check for GNU $ac_path_GREP
11701 case `"$ac_path_GREP" --version 2>&1` in
11702 *GNU*)
11703   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11704 *)
11705   ac_count=0
11706   $as_echo_n 0123456789 >"conftest.in"
11707   while :
11708   do
11709     cat "conftest.in" "conftest.in" >"conftest.tmp"
11710     mv "conftest.tmp" "conftest.in"
11711     cp "conftest.in" "conftest.nl"
11712     $as_echo 'GREP' >> "conftest.nl"
11713     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11714     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11715     as_fn_arith $ac_count + 1 && ac_count=$as_val
11716     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11717       # Best one so far, save it but keep looking for a better one
11718       ac_cv_path_GREP="$ac_path_GREP"
11719       ac_path_GREP_max=$ac_count
11720     fi
11721     # 10*(2^10) chars as input seems more than enough
11722     test $ac_count -gt 10 && break
11723   done
11724   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11725 esac
11726 
11727       $ac_path_GREP_found && break 3
11728     done
11729   done
11730   done
11731 IFS=$as_save_IFS
11732   if test -z "$ac_cv_path_GREP"; then
11733     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11734   fi
11735 else
11736   ac_cv_path_GREP=$GREP
11737 fi
11738 
11739 fi
11740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11741 $as_echo "$ac_cv_path_GREP" >&6; }
11742  GREP="$ac_cv_path_GREP"
11743 
11744 
11745     else
11746       # If it succeeded, then it was overridden by the user. We will use it
11747       # for the tool.
11748 
11749       # First remove it from the list of overridden variables, so we can test
11750       # for unknown variables in the end.
11751       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11752 
11753       # Check if the provided tool contains a complete path.
11754       tool_specified="$GREP"
11755       tool_basename="${tool_specified##*/}"
11756       if test "x$tool_basename" = "x$tool_specified"; then
11757         # A command without a complete path is provided, search $PATH.
11758         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5
11759 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;}
11760         # Extract the first word of "$tool_basename", so it can be a program name with args.
11761 set dummy $tool_basename; ac_word=$2
11762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11763 $as_echo_n "checking for $ac_word... " >&6; }
11764 if ${ac_cv_path_GREP+:} false; then :
11765   $as_echo_n "(cached) " >&6
11766 else
11767   case $GREP in
11768   [\\/]* | ?:[\\/]*)
11769   ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
11770   ;;
11771   *)
11772   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11773 for as_dir in $PATH
11774 do
11775   IFS=$as_save_IFS
11776   test -z "$as_dir" && as_dir=.
11777     for ac_exec_ext in '' $ac_executable_extensions; do
11778   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11779     ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
11780     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11781     break 2
11782   fi
11783 done
11784   done
11785 IFS=$as_save_IFS
11786 
11787   ;;
11788 esac
11789 fi
11790 GREP=$ac_cv_path_GREP
11791 if test -n "$GREP"; then
11792   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
11793 $as_echo "$GREP" >&6; }
11794 else
11795   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11796 $as_echo "no" >&6; }
11797 fi
11798 
11799 
11800         if test "x$GREP" = x; then
11801           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11802         fi
11803       else
11804         # Otherwise we believe it is a complete path. Use it as it is.
11805         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5
11806 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;}
11807         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5
11808 $as_echo_n "checking for GREP... " >&6; }
11809         if test ! -x "$tool_specified"; then
11810           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11811 $as_echo "not found" >&6; }
11812           as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11813         fi
11814         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11815 $as_echo "$tool_specified" >&6; }
11816       fi
11817     fi
11818   fi
11819 
11820 
11821   if test "x$GREP" = x; then
11822     as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5
11823   fi
11824 
11825 
11826 
11827 
11828   # Publish this variable in the help.
11829 
11830 
11831   if test "x$EGREP" = x; then
11832     # The variable is not set by user, try to locate tool using the code snippet
11833     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11834 $as_echo_n "checking for egrep... " >&6; }
11835 if ${ac_cv_path_EGREP+:} false; then :
11836   $as_echo_n "(cached) " >&6
11837 else
11838   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11839    then ac_cv_path_EGREP="$GREP -E"
11840    else
11841      if test -z "$EGREP"; then
11842   ac_path_EGREP_found=false
11843   # Loop through the user's path and test for each of PROGNAME-LIST
11844   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11845 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11846 do
11847   IFS=$as_save_IFS
11848   test -z "$as_dir" && as_dir=.
11849     for ac_prog in egrep; do
11850     for ac_exec_ext in '' $ac_executable_extensions; do
11851       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11852       as_fn_executable_p "$ac_path_EGREP" || continue
11853 # Check for GNU ac_path_EGREP and select it if it is found.
11854   # Check for GNU $ac_path_EGREP
11855 case `"$ac_path_EGREP" --version 2>&1` in
11856 *GNU*)
11857   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11858 *)
11859   ac_count=0
11860   $as_echo_n 0123456789 >"conftest.in"
11861   while :
11862   do
11863     cat "conftest.in" "conftest.in" >"conftest.tmp"
11864     mv "conftest.tmp" "conftest.in"
11865     cp "conftest.in" "conftest.nl"
11866     $as_echo 'EGREP' >> "conftest.nl"
11867     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11868     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11869     as_fn_arith $ac_count + 1 && ac_count=$as_val
11870     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11871       # Best one so far, save it but keep looking for a better one
11872       ac_cv_path_EGREP="$ac_path_EGREP"
11873       ac_path_EGREP_max=$ac_count
11874     fi
11875     # 10*(2^10) chars as input seems more than enough
11876     test $ac_count -gt 10 && break
11877   done
11878   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11879 esac
11880 
11881       $ac_path_EGREP_found && break 3
11882     done
11883   done
11884   done
11885 IFS=$as_save_IFS
11886   if test -z "$ac_cv_path_EGREP"; then
11887     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11888   fi
11889 else
11890   ac_cv_path_EGREP=$EGREP
11891 fi
11892 
11893    fi
11894 fi
11895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11896 $as_echo "$ac_cv_path_EGREP" >&6; }
11897  EGREP="$ac_cv_path_EGREP"
11898 
11899 
11900   else
11901     # The variable is set, but is it from the command line or the environment?
11902 
11903     # Try to remove the string !EGREP! from our list.
11904     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/}
11905     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11906       # If it failed, the variable was not from the command line. Ignore it,
11907       # but warn the user (except for BASH, which is always set by the calling BASH).
11908       if test "xEGREP" != xBASH; then
11909         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5
11910 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;}
11911       fi
11912       # Try to locate tool using the code snippet
11913       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11914 $as_echo_n "checking for egrep... " >&6; }
11915 if ${ac_cv_path_EGREP+:} false; then :
11916   $as_echo_n "(cached) " >&6
11917 else
11918   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11919    then ac_cv_path_EGREP="$GREP -E"
11920    else
11921      if test -z "$EGREP"; then
11922   ac_path_EGREP_found=false
11923   # Loop through the user's path and test for each of PROGNAME-LIST
11924   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11925 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11926 do
11927   IFS=$as_save_IFS
11928   test -z "$as_dir" && as_dir=.
11929     for ac_prog in egrep; do
11930     for ac_exec_ext in '' $ac_executable_extensions; do
11931       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11932       as_fn_executable_p "$ac_path_EGREP" || continue
11933 # Check for GNU ac_path_EGREP and select it if it is found.
11934   # Check for GNU $ac_path_EGREP
11935 case `"$ac_path_EGREP" --version 2>&1` in
11936 *GNU*)
11937   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11938 *)
11939   ac_count=0
11940   $as_echo_n 0123456789 >"conftest.in"
11941   while :
11942   do
11943     cat "conftest.in" "conftest.in" >"conftest.tmp"
11944     mv "conftest.tmp" "conftest.in"
11945     cp "conftest.in" "conftest.nl"
11946     $as_echo 'EGREP' >> "conftest.nl"
11947     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11948     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11949     as_fn_arith $ac_count + 1 && ac_count=$as_val
11950     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11951       # Best one so far, save it but keep looking for a better one
11952       ac_cv_path_EGREP="$ac_path_EGREP"
11953       ac_path_EGREP_max=$ac_count
11954     fi
11955     # 10*(2^10) chars as input seems more than enough
11956     test $ac_count -gt 10 && break
11957   done
11958   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11959 esac
11960 
11961       $ac_path_EGREP_found && break 3
11962     done
11963   done
11964   done
11965 IFS=$as_save_IFS
11966   if test -z "$ac_cv_path_EGREP"; then
11967     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11968   fi
11969 else
11970   ac_cv_path_EGREP=$EGREP
11971 fi
11972 
11973    fi
11974 fi
11975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11976 $as_echo "$ac_cv_path_EGREP" >&6; }
11977  EGREP="$ac_cv_path_EGREP"
11978 
11979 
11980     else
11981       # If it succeeded, then it was overridden by the user. We will use it
11982       # for the tool.
11983 
11984       # First remove it from the list of overridden variables, so we can test
11985       # for unknown variables in the end.
11986       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11987 
11988       # Check if the provided tool contains a complete path.
11989       tool_specified="$EGREP"
11990       tool_basename="${tool_specified##*/}"
11991       if test "x$tool_basename" = "x$tool_specified"; then
11992         # A command without a complete path is provided, search $PATH.
11993         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5
11994 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;}
11995         # Extract the first word of "$tool_basename", so it can be a program name with args.
11996 set dummy $tool_basename; ac_word=$2
11997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11998 $as_echo_n "checking for $ac_word... " >&6; }
11999 if ${ac_cv_path_EGREP+:} false; then :
12000   $as_echo_n "(cached) " >&6
12001 else
12002   case $EGREP in
12003   [\\/]* | ?:[\\/]*)
12004   ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
12005   ;;
12006   *)
12007   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12008 for as_dir in $PATH
12009 do
12010   IFS=$as_save_IFS
12011   test -z "$as_dir" && as_dir=.
12012     for ac_exec_ext in '' $ac_executable_extensions; do
12013   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12014     ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
12015     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12016     break 2
12017   fi
12018 done
12019   done
12020 IFS=$as_save_IFS
12021 
12022   ;;
12023 esac
12024 fi
12025 EGREP=$ac_cv_path_EGREP
12026 if test -n "$EGREP"; then
12027   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
12028 $as_echo "$EGREP" >&6; }
12029 else
12030   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12031 $as_echo "no" >&6; }
12032 fi
12033 
12034 
12035         if test "x$EGREP" = x; then
12036           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12037         fi
12038       else
12039         # Otherwise we believe it is a complete path. Use it as it is.
12040         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5
12041 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;}
12042         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5
12043 $as_echo_n "checking for EGREP... " >&6; }
12044         if test ! -x "$tool_specified"; then
12045           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12046 $as_echo "not found" >&6; }
12047           as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12048         fi
12049         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12050 $as_echo "$tool_specified" >&6; }
12051       fi
12052     fi
12053   fi
12054 
12055 
12056   if test "x$EGREP" = x; then
12057     as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5
12058   fi
12059 
12060 
12061 
12062 
12063   # Publish this variable in the help.
12064 
12065 
12066   if test "x$FGREP" = x; then
12067     # The variable is not set by user, try to locate tool using the code snippet
12068     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12069 $as_echo_n "checking for fgrep... " >&6; }
12070 if ${ac_cv_path_FGREP+:} false; then :
12071   $as_echo_n "(cached) " >&6
12072 else
12073   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12074    then ac_cv_path_FGREP="$GREP -F"
12075    else
12076      if test -z "$FGREP"; then
12077   ac_path_FGREP_found=false
12078   # Loop through the user's path and test for each of PROGNAME-LIST
12079   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12080 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12081 do
12082   IFS=$as_save_IFS
12083   test -z "$as_dir" && as_dir=.
12084     for ac_prog in fgrep; do
12085     for ac_exec_ext in '' $ac_executable_extensions; do
12086       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12087       as_fn_executable_p "$ac_path_FGREP" || continue
12088 # Check for GNU ac_path_FGREP and select it if it is found.
12089   # Check for GNU $ac_path_FGREP
12090 case `"$ac_path_FGREP" --version 2>&1` in
12091 *GNU*)
12092   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12093 *)
12094   ac_count=0
12095   $as_echo_n 0123456789 >"conftest.in"
12096   while :
12097   do
12098     cat "conftest.in" "conftest.in" >"conftest.tmp"
12099     mv "conftest.tmp" "conftest.in"
12100     cp "conftest.in" "conftest.nl"
12101     $as_echo 'FGREP' >> "conftest.nl"
12102     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12103     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12104     as_fn_arith $ac_count + 1 && ac_count=$as_val
12105     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12106       # Best one so far, save it but keep looking for a better one
12107       ac_cv_path_FGREP="$ac_path_FGREP"
12108       ac_path_FGREP_max=$ac_count
12109     fi
12110     # 10*(2^10) chars as input seems more than enough
12111     test $ac_count -gt 10 && break
12112   done
12113   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12114 esac
12115 
12116       $ac_path_FGREP_found && break 3
12117     done
12118   done
12119   done
12120 IFS=$as_save_IFS
12121   if test -z "$ac_cv_path_FGREP"; then
12122     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12123   fi
12124 else
12125   ac_cv_path_FGREP=$FGREP
12126 fi
12127 
12128    fi
12129 fi
12130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12131 $as_echo "$ac_cv_path_FGREP" >&6; }
12132  FGREP="$ac_cv_path_FGREP"
12133 
12134 
12135   else
12136     # The variable is set, but is it from the command line or the environment?
12137 
12138     # Try to remove the string !FGREP! from our list.
12139     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/}
12140     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12141       # If it failed, the variable was not from the command line. Ignore it,
12142       # but warn the user (except for BASH, which is always set by the calling BASH).
12143       if test "xFGREP" != xBASH; then
12144         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5
12145 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;}
12146       fi
12147       # Try to locate tool using the code snippet
12148       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12149 $as_echo_n "checking for fgrep... " >&6; }
12150 if ${ac_cv_path_FGREP+:} false; then :
12151   $as_echo_n "(cached) " >&6
12152 else
12153   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12154    then ac_cv_path_FGREP="$GREP -F"
12155    else
12156      if test -z "$FGREP"; then
12157   ac_path_FGREP_found=false
12158   # Loop through the user's path and test for each of PROGNAME-LIST
12159   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12160 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12161 do
12162   IFS=$as_save_IFS
12163   test -z "$as_dir" && as_dir=.
12164     for ac_prog in fgrep; do
12165     for ac_exec_ext in '' $ac_executable_extensions; do
12166       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12167       as_fn_executable_p "$ac_path_FGREP" || continue
12168 # Check for GNU ac_path_FGREP and select it if it is found.
12169   # Check for GNU $ac_path_FGREP
12170 case `"$ac_path_FGREP" --version 2>&1` in
12171 *GNU*)
12172   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12173 *)
12174   ac_count=0
12175   $as_echo_n 0123456789 >"conftest.in"
12176   while :
12177   do
12178     cat "conftest.in" "conftest.in" >"conftest.tmp"
12179     mv "conftest.tmp" "conftest.in"
12180     cp "conftest.in" "conftest.nl"
12181     $as_echo 'FGREP' >> "conftest.nl"
12182     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12183     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12184     as_fn_arith $ac_count + 1 && ac_count=$as_val
12185     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12186       # Best one so far, save it but keep looking for a better one
12187       ac_cv_path_FGREP="$ac_path_FGREP"
12188       ac_path_FGREP_max=$ac_count
12189     fi
12190     # 10*(2^10) chars as input seems more than enough
12191     test $ac_count -gt 10 && break
12192   done
12193   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12194 esac
12195 
12196       $ac_path_FGREP_found && break 3
12197     done
12198   done
12199   done
12200 IFS=$as_save_IFS
12201   if test -z "$ac_cv_path_FGREP"; then
12202     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12203   fi
12204 else
12205   ac_cv_path_FGREP=$FGREP
12206 fi
12207 
12208    fi
12209 fi
12210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12211 $as_echo "$ac_cv_path_FGREP" >&6; }
12212  FGREP="$ac_cv_path_FGREP"
12213 
12214 
12215     else
12216       # If it succeeded, then it was overridden by the user. We will use it
12217       # for the tool.
12218 
12219       # First remove it from the list of overridden variables, so we can test
12220       # for unknown variables in the end.
12221       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12222 
12223       # Check if the provided tool contains a complete path.
12224       tool_specified="$FGREP"
12225       tool_basename="${tool_specified##*/}"
12226       if test "x$tool_basename" = "x$tool_specified"; then
12227         # A command without a complete path is provided, search $PATH.
12228         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5
12229 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;}
12230         # Extract the first word of "$tool_basename", so it can be a program name with args.
12231 set dummy $tool_basename; ac_word=$2
12232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12233 $as_echo_n "checking for $ac_word... " >&6; }
12234 if ${ac_cv_path_FGREP+:} false; then :
12235   $as_echo_n "(cached) " >&6
12236 else
12237   case $FGREP in
12238   [\\/]* | ?:[\\/]*)
12239   ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
12240   ;;
12241   *)
12242   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12243 for as_dir in $PATH
12244 do
12245   IFS=$as_save_IFS
12246   test -z "$as_dir" && as_dir=.
12247     for ac_exec_ext in '' $ac_executable_extensions; do
12248   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12249     ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext"
12250     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12251     break 2
12252   fi
12253 done
12254   done
12255 IFS=$as_save_IFS
12256 
12257   ;;
12258 esac
12259 fi
12260 FGREP=$ac_cv_path_FGREP
12261 if test -n "$FGREP"; then
12262   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5
12263 $as_echo "$FGREP" >&6; }
12264 else
12265   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12266 $as_echo "no" >&6; }
12267 fi
12268 
12269 
12270         if test "x$FGREP" = x; then
12271           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12272         fi
12273       else
12274         # Otherwise we believe it is a complete path. Use it as it is.
12275         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5
12276 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;}
12277         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5
12278 $as_echo_n "checking for FGREP... " >&6; }
12279         if test ! -x "$tool_specified"; then
12280           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12281 $as_echo "not found" >&6; }
12282           as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12283         fi
12284         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12285 $as_echo "$tool_specified" >&6; }
12286       fi
12287     fi
12288   fi
12289 
12290 
12291   if test "x$FGREP" = x; then
12292     as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5
12293   fi
12294 
12295 
12296 
12297 
12298   # Publish this variable in the help.
12299 
12300 
12301   if test "x$SED" = x; then
12302     # The variable is not set by user, 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     # The variable is set, but is it from the command line or the environment?
12374 
12375     # Try to remove the string !SED! from our list.
12376     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/}
12377     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12378       # If it failed, the variable was not from the command line. Ignore it,
12379       # but warn the user (except for BASH, which is always set by the calling BASH).
12380       if test "xSED" != xBASH; then
12381         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5
12382 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;}
12383       fi
12384       # Try to locate tool using the code snippet
12385       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12386 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12387 if ${ac_cv_path_SED+:} false; then :
12388   $as_echo_n "(cached) " >&6
12389 else
12390             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12391      for ac_i in 1 2 3 4 5 6 7; do
12392        ac_script="$ac_script$as_nl$ac_script"
12393      done
12394      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12395      { ac_script=; unset ac_script;}
12396      if test -z "$SED"; then
12397   ac_path_SED_found=false
12398   # Loop through the user's path and test for each of PROGNAME-LIST
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_prog in sed gsed; do
12405     for ac_exec_ext in '' $ac_executable_extensions; do
12406       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12407       as_fn_executable_p "$ac_path_SED" || continue
12408 # Check for GNU ac_path_SED and select it if it is found.
12409   # Check for GNU $ac_path_SED
12410 case `"$ac_path_SED" --version 2>&1` in
12411 *GNU*)
12412   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12413 *)
12414   ac_count=0
12415   $as_echo_n 0123456789 >"conftest.in"
12416   while :
12417   do
12418     cat "conftest.in" "conftest.in" >"conftest.tmp"
12419     mv "conftest.tmp" "conftest.in"
12420     cp "conftest.in" "conftest.nl"
12421     $as_echo '' >> "conftest.nl"
12422     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12423     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12424     as_fn_arith $ac_count + 1 && ac_count=$as_val
12425     if test $ac_count -gt ${ac_path_SED_max-0}; then
12426       # Best one so far, save it but keep looking for a better one
12427       ac_cv_path_SED="$ac_path_SED"
12428       ac_path_SED_max=$ac_count
12429     fi
12430     # 10*(2^10) chars as input seems more than enough
12431     test $ac_count -gt 10 && break
12432   done
12433   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12434 esac
12435 
12436       $ac_path_SED_found && break 3
12437     done
12438   done
12439   done
12440 IFS=$as_save_IFS
12441   if test -z "$ac_cv_path_SED"; then
12442     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12443   fi
12444 else
12445   ac_cv_path_SED=$SED
12446 fi
12447 
12448 fi
12449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12450 $as_echo "$ac_cv_path_SED" >&6; }
12451  SED="$ac_cv_path_SED"
12452   rm -f conftest.sed
12453 
12454     else
12455       # If it succeeded, then it was overridden by the user. We will use it
12456       # for the tool.
12457 
12458       # First remove it from the list of overridden variables, so we can test
12459       # for unknown variables in the end.
12460       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12461 
12462       # Check if the provided tool contains a complete path.
12463       tool_specified="$SED"
12464       tool_basename="${tool_specified##*/}"
12465       if test "x$tool_basename" = "x$tool_specified"; then
12466         # A command without a complete path is provided, search $PATH.
12467         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5
12468 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;}
12469         # Extract the first word of "$tool_basename", so it can be a program name with args.
12470 set dummy $tool_basename; ac_word=$2
12471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12472 $as_echo_n "checking for $ac_word... " >&6; }
12473 if ${ac_cv_path_SED+:} false; then :
12474   $as_echo_n "(cached) " >&6
12475 else
12476   case $SED in
12477   [\\/]* | ?:[\\/]*)
12478   ac_cv_path_SED="$SED" # Let the user override the test with a path.
12479   ;;
12480   *)
12481   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12482 for as_dir in $PATH
12483 do
12484   IFS=$as_save_IFS
12485   test -z "$as_dir" && as_dir=.
12486     for ac_exec_ext in '' $ac_executable_extensions; do
12487   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12488     ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
12489     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12490     break 2
12491   fi
12492 done
12493   done
12494 IFS=$as_save_IFS
12495 
12496   ;;
12497 esac
12498 fi
12499 SED=$ac_cv_path_SED
12500 if test -n "$SED"; then
12501   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
12502 $as_echo "$SED" >&6; }
12503 else
12504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12505 $as_echo "no" >&6; }
12506 fi
12507 
12508 
12509         if test "x$SED" = x; then
12510           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12511         fi
12512       else
12513         # Otherwise we believe it is a complete path. Use it as it is.
12514         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5
12515 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;}
12516         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5
12517 $as_echo_n "checking for SED... " >&6; }
12518         if test ! -x "$tool_specified"; then
12519           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12520 $as_echo "not found" >&6; }
12521           as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5
12522         fi
12523         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12524 $as_echo "$tool_specified" >&6; }
12525       fi
12526     fi
12527   fi
12528 
12529 
12530   if test "x$SED" = x; then
12531     as_fn_error $? "Could not find required tool for SED" "$LINENO" 5
12532   fi
12533 
12534 
12535 
12536   # Always force rm.
12537   RM="$RM -f"
12538 
12539   # pwd behaves differently on various platforms and some don't support the -L flag.
12540   # Always use the bash builtin pwd to get uniform behavior.
12541   THEPWDCMD=pwd
12542 
12543   # These are not required on all platforms
12544 
12545 
12546   # Publish this variable in the help.
12547 
12548 
12549   if test "x$CYGPATH" = x; then
12550     # The variable is not set by user, try to locate tool using the code snippet
12551     for ac_prog in cygpath
12552 do
12553   # Extract the first word of "$ac_prog", so it can be a program name with args.
12554 set dummy $ac_prog; ac_word=$2
12555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12556 $as_echo_n "checking for $ac_word... " >&6; }
12557 if ${ac_cv_path_CYGPATH+:} false; then :
12558   $as_echo_n "(cached) " >&6
12559 else
12560   case $CYGPATH in
12561   [\\/]* | ?:[\\/]*)
12562   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12563   ;;
12564   *)
12565   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12566 for as_dir in $PATH
12567 do
12568   IFS=$as_save_IFS
12569   test -z "$as_dir" && as_dir=.
12570     for ac_exec_ext in '' $ac_executable_extensions; do
12571   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12572     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12573     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12574     break 2
12575   fi
12576 done
12577   done
12578 IFS=$as_save_IFS
12579 
12580   ;;
12581 esac
12582 fi
12583 CYGPATH=$ac_cv_path_CYGPATH
12584 if test -n "$CYGPATH"; then
12585   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12586 $as_echo "$CYGPATH" >&6; }
12587 else
12588   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12589 $as_echo "no" >&6; }
12590 fi
12591 
12592 
12593   test -n "$CYGPATH" && break
12594 done
12595 
12596   else
12597     # The variable is set, but is it from the command line or the environment?
12598 
12599     # Try to remove the string !CYGPATH! from our list.
12600     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/}
12601     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12602       # If it failed, the variable was not from the command line. Ignore it,
12603       # but warn the user (except for BASH, which is always set by the calling BASH).
12604       if test "xCYGPATH" != xBASH; then
12605         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5
12606 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;}
12607       fi
12608       # Try to locate tool using the code snippet
12609       for ac_prog in cygpath
12610 do
12611   # Extract the first word of "$ac_prog", so it can be a program name with args.
12612 set dummy $ac_prog; ac_word=$2
12613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12614 $as_echo_n "checking for $ac_word... " >&6; }
12615 if ${ac_cv_path_CYGPATH+:} false; then :
12616   $as_echo_n "(cached) " >&6
12617 else
12618   case $CYGPATH in
12619   [\\/]* | ?:[\\/]*)
12620   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12621   ;;
12622   *)
12623   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12624 for as_dir in $PATH
12625 do
12626   IFS=$as_save_IFS
12627   test -z "$as_dir" && as_dir=.
12628     for ac_exec_ext in '' $ac_executable_extensions; do
12629   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12630     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12631     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12632     break 2
12633   fi
12634 done
12635   done
12636 IFS=$as_save_IFS
12637 
12638   ;;
12639 esac
12640 fi
12641 CYGPATH=$ac_cv_path_CYGPATH
12642 if test -n "$CYGPATH"; then
12643   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12644 $as_echo "$CYGPATH" >&6; }
12645 else
12646   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12647 $as_echo "no" >&6; }
12648 fi
12649 
12650 
12651   test -n "$CYGPATH" && break
12652 done
12653 
12654     else
12655       # If it succeeded, then it was overridden by the user. We will use it
12656       # for the tool.
12657 
12658       # First remove it from the list of overridden variables, so we can test
12659       # for unknown variables in the end.
12660       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12661 
12662       # Check if the provided tool contains a complete path.
12663       tool_specified="$CYGPATH"
12664       tool_basename="${tool_specified##*/}"
12665       if test "x$tool_basename" = "x$tool_specified"; then
12666         # A command without a complete path is provided, search $PATH.
12667         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5
12668 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;}
12669         # Extract the first word of "$tool_basename", so it can be a program name with args.
12670 set dummy $tool_basename; ac_word=$2
12671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12672 $as_echo_n "checking for $ac_word... " >&6; }
12673 if ${ac_cv_path_CYGPATH+:} false; then :
12674   $as_echo_n "(cached) " >&6
12675 else
12676   case $CYGPATH in
12677   [\\/]* | ?:[\\/]*)
12678   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12679   ;;
12680   *)
12681   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12682 for as_dir in $PATH
12683 do
12684   IFS=$as_save_IFS
12685   test -z "$as_dir" && as_dir=.
12686     for ac_exec_ext in '' $ac_executable_extensions; do
12687   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12688     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12689     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12690     break 2
12691   fi
12692 done
12693   done
12694 IFS=$as_save_IFS
12695 
12696   ;;
12697 esac
12698 fi
12699 CYGPATH=$ac_cv_path_CYGPATH
12700 if test -n "$CYGPATH"; then
12701   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12702 $as_echo "$CYGPATH" >&6; }
12703 else
12704   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12705 $as_echo "no" >&6; }
12706 fi
12707 
12708 
12709         if test "x$CYGPATH" = x; then
12710           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12711         fi
12712       else
12713         # Otherwise we believe it is a complete path. Use it as it is.
12714         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5
12715 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;}
12716         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5
12717 $as_echo_n "checking for CYGPATH... " >&6; }
12718         if test ! -x "$tool_specified"; then
12719           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12720 $as_echo "not found" >&6; }
12721           as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5
12722         fi
12723         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12724 $as_echo "$tool_specified" >&6; }
12725       fi
12726     fi
12727   fi
12728 
12729 
12730 
12731 
12732   # Publish this variable in the help.
12733 
12734 
12735   if test "x$READLINK" = x; then
12736     # The variable is not set by user, try to locate tool using the code snippet
12737     for ac_prog in greadlink readlink
12738 do
12739   # Extract the first word of "$ac_prog", so it can be a program name with args.
12740 set dummy $ac_prog; ac_word=$2
12741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12742 $as_echo_n "checking for $ac_word... " >&6; }
12743 if ${ac_cv_path_READLINK+:} false; then :
12744   $as_echo_n "(cached) " >&6
12745 else
12746   case $READLINK in
12747   [\\/]* | ?:[\\/]*)
12748   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12749   ;;
12750   *)
12751   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12752 for as_dir in $PATH
12753 do
12754   IFS=$as_save_IFS
12755   test -z "$as_dir" && as_dir=.
12756     for ac_exec_ext in '' $ac_executable_extensions; do
12757   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12758     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12759     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12760     break 2
12761   fi
12762 done
12763   done
12764 IFS=$as_save_IFS
12765 
12766   ;;
12767 esac
12768 fi
12769 READLINK=$ac_cv_path_READLINK
12770 if test -n "$READLINK"; then
12771   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12772 $as_echo "$READLINK" >&6; }
12773 else
12774   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12775 $as_echo "no" >&6; }
12776 fi
12777 
12778 
12779   test -n "$READLINK" && break
12780 done
12781 
12782   else
12783     # The variable is set, but is it from the command line or the environment?
12784 
12785     # Try to remove the string !READLINK! from our list.
12786     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/}
12787     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12788       # If it failed, the variable was not from the command line. Ignore it,
12789       # but warn the user (except for BASH, which is always set by the calling BASH).
12790       if test "xREADLINK" != xBASH; then
12791         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5
12792 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;}
12793       fi
12794       # Try to locate tool using the code snippet
12795       for ac_prog in greadlink readlink
12796 do
12797   # Extract the first word of "$ac_prog", so it can be a program name with args.
12798 set dummy $ac_prog; ac_word=$2
12799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12800 $as_echo_n "checking for $ac_word... " >&6; }
12801 if ${ac_cv_path_READLINK+:} false; then :
12802   $as_echo_n "(cached) " >&6
12803 else
12804   case $READLINK in
12805   [\\/]* | ?:[\\/]*)
12806   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12807   ;;
12808   *)
12809   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12810 for as_dir in $PATH
12811 do
12812   IFS=$as_save_IFS
12813   test -z "$as_dir" && as_dir=.
12814     for ac_exec_ext in '' $ac_executable_extensions; do
12815   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12816     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12817     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12818     break 2
12819   fi
12820 done
12821   done
12822 IFS=$as_save_IFS
12823 
12824   ;;
12825 esac
12826 fi
12827 READLINK=$ac_cv_path_READLINK
12828 if test -n "$READLINK"; then
12829   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12830 $as_echo "$READLINK" >&6; }
12831 else
12832   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12833 $as_echo "no" >&6; }
12834 fi
12835 
12836 
12837   test -n "$READLINK" && break
12838 done
12839 
12840     else
12841       # If it succeeded, then it was overridden by the user. We will use it
12842       # for the tool.
12843 
12844       # First remove it from the list of overridden variables, so we can test
12845       # for unknown variables in the end.
12846       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12847 
12848       # Check if the provided tool contains a complete path.
12849       tool_specified="$READLINK"
12850       tool_basename="${tool_specified##*/}"
12851       if test "x$tool_basename" = "x$tool_specified"; then
12852         # A command without a complete path is provided, search $PATH.
12853         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5
12854 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;}
12855         # Extract the first word of "$tool_basename", so it can be a program name with args.
12856 set dummy $tool_basename; ac_word=$2
12857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12858 $as_echo_n "checking for $ac_word... " >&6; }
12859 if ${ac_cv_path_READLINK+:} false; then :
12860   $as_echo_n "(cached) " >&6
12861 else
12862   case $READLINK in
12863   [\\/]* | ?:[\\/]*)
12864   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12865   ;;
12866   *)
12867   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12868 for as_dir in $PATH
12869 do
12870   IFS=$as_save_IFS
12871   test -z "$as_dir" && as_dir=.
12872     for ac_exec_ext in '' $ac_executable_extensions; do
12873   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12874     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12875     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12876     break 2
12877   fi
12878 done
12879   done
12880 IFS=$as_save_IFS
12881 
12882   ;;
12883 esac
12884 fi
12885 READLINK=$ac_cv_path_READLINK
12886 if test -n "$READLINK"; then
12887   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12888 $as_echo "$READLINK" >&6; }
12889 else
12890   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12891 $as_echo "no" >&6; }
12892 fi
12893 
12894 
12895         if test "x$READLINK" = x; then
12896           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12897         fi
12898       else
12899         # Otherwise we believe it is a complete path. Use it as it is.
12900         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5
12901 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;}
12902         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5
12903 $as_echo_n "checking for READLINK... " >&6; }
12904         if test ! -x "$tool_specified"; then
12905           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12906 $as_echo "not found" >&6; }
12907           as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5
12908         fi
12909         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12910 $as_echo "$tool_specified" >&6; }
12911       fi
12912     fi
12913   fi
12914 
12915 
12916 
12917 
12918   # Publish this variable in the help.
12919 
12920 
12921   if test "x$DF" = x; then
12922     # The variable is not set by user, try to locate tool using the code snippet
12923     for ac_prog in df
12924 do
12925   # Extract the first word of "$ac_prog", so it can be a program name with args.
12926 set dummy $ac_prog; ac_word=$2
12927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12928 $as_echo_n "checking for $ac_word... " >&6; }
12929 if ${ac_cv_path_DF+:} false; then :
12930   $as_echo_n "(cached) " >&6
12931 else
12932   case $DF in
12933   [\\/]* | ?:[\\/]*)
12934   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12935   ;;
12936   *)
12937   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12938 for as_dir in $PATH
12939 do
12940   IFS=$as_save_IFS
12941   test -z "$as_dir" && as_dir=.
12942     for ac_exec_ext in '' $ac_executable_extensions; do
12943   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12944     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12945     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12946     break 2
12947   fi
12948 done
12949   done
12950 IFS=$as_save_IFS
12951 
12952   ;;
12953 esac
12954 fi
12955 DF=$ac_cv_path_DF
12956 if test -n "$DF"; then
12957   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12958 $as_echo "$DF" >&6; }
12959 else
12960   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12961 $as_echo "no" >&6; }
12962 fi
12963 
12964 
12965   test -n "$DF" && break
12966 done
12967 
12968   else
12969     # The variable is set, but is it from the command line or the environment?
12970 
12971     # Try to remove the string !DF! from our list.
12972     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/}
12973     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12974       # If it failed, the variable was not from the command line. Ignore it,
12975       # but warn the user (except for BASH, which is always set by the calling BASH).
12976       if test "xDF" != xBASH; then
12977         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5
12978 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;}
12979       fi
12980       # Try to locate tool using the code snippet
12981       for ac_prog in df
12982 do
12983   # Extract the first word of "$ac_prog", so it can be a program name with args.
12984 set dummy $ac_prog; ac_word=$2
12985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12986 $as_echo_n "checking for $ac_word... " >&6; }
12987 if ${ac_cv_path_DF+:} false; then :
12988   $as_echo_n "(cached) " >&6
12989 else
12990   case $DF in
12991   [\\/]* | ?:[\\/]*)
12992   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12993   ;;
12994   *)
12995   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12996 for as_dir in $PATH
12997 do
12998   IFS=$as_save_IFS
12999   test -z "$as_dir" && as_dir=.
13000     for ac_exec_ext in '' $ac_executable_extensions; do
13001   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13002     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13003     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13004     break 2
13005   fi
13006 done
13007   done
13008 IFS=$as_save_IFS
13009 
13010   ;;
13011 esac
13012 fi
13013 DF=$ac_cv_path_DF
13014 if test -n "$DF"; then
13015   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13016 $as_echo "$DF" >&6; }
13017 else
13018   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13019 $as_echo "no" >&6; }
13020 fi
13021 
13022 
13023   test -n "$DF" && break
13024 done
13025 
13026     else
13027       # If it succeeded, then it was overridden by the user. We will use it
13028       # for the tool.
13029 
13030       # First remove it from the list of overridden variables, so we can test
13031       # for unknown variables in the end.
13032       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13033 
13034       # Check if the provided tool contains a complete path.
13035       tool_specified="$DF"
13036       tool_basename="${tool_specified##*/}"
13037       if test "x$tool_basename" = "x$tool_specified"; then
13038         # A command without a complete path is provided, search $PATH.
13039         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5
13040 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;}
13041         # Extract the first word of "$tool_basename", so it can be a program name with args.
13042 set dummy $tool_basename; ac_word=$2
13043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13044 $as_echo_n "checking for $ac_word... " >&6; }
13045 if ${ac_cv_path_DF+:} false; then :
13046   $as_echo_n "(cached) " >&6
13047 else
13048   case $DF in
13049   [\\/]* | ?:[\\/]*)
13050   ac_cv_path_DF="$DF" # Let the user override the test with a path.
13051   ;;
13052   *)
13053   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13054 for as_dir in $PATH
13055 do
13056   IFS=$as_save_IFS
13057   test -z "$as_dir" && as_dir=.
13058     for ac_exec_ext in '' $ac_executable_extensions; do
13059   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13060     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13061     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13062     break 2
13063   fi
13064 done
13065   done
13066 IFS=$as_save_IFS
13067 
13068   ;;
13069 esac
13070 fi
13071 DF=$ac_cv_path_DF
13072 if test -n "$DF"; then
13073   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13074 $as_echo "$DF" >&6; }
13075 else
13076   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13077 $as_echo "no" >&6; }
13078 fi
13079 
13080 
13081         if test "x$DF" = x; then
13082           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13083         fi
13084       else
13085         # Otherwise we believe it is a complete path. Use it as it is.
13086         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5
13087 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;}
13088         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5
13089 $as_echo_n "checking for DF... " >&6; }
13090         if test ! -x "$tool_specified"; then
13091           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13092 $as_echo "not found" >&6; }
13093           as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5
13094         fi
13095         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13096 $as_echo "$tool_specified" >&6; }
13097       fi
13098     fi
13099   fi
13100 
13101 
13102 
13103 
13104   # Publish this variable in the help.
13105 
13106 
13107   if test "x$SETFILE" = x; then
13108     # The variable is not set by user, try to locate tool using the code snippet
13109     for ac_prog in SetFile
13110 do
13111   # Extract the first word of "$ac_prog", so it can be a program name with args.
13112 set dummy $ac_prog; ac_word=$2
13113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13114 $as_echo_n "checking for $ac_word... " >&6; }
13115 if ${ac_cv_path_SETFILE+:} false; then :
13116   $as_echo_n "(cached) " >&6
13117 else
13118   case $SETFILE in
13119   [\\/]* | ?:[\\/]*)
13120   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13121   ;;
13122   *)
13123   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13124 for as_dir in $PATH
13125 do
13126   IFS=$as_save_IFS
13127   test -z "$as_dir" && as_dir=.
13128     for ac_exec_ext in '' $ac_executable_extensions; do
13129   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13130     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13131     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13132     break 2
13133   fi
13134 done
13135   done
13136 IFS=$as_save_IFS
13137 
13138   ;;
13139 esac
13140 fi
13141 SETFILE=$ac_cv_path_SETFILE
13142 if test -n "$SETFILE"; then
13143   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13144 $as_echo "$SETFILE" >&6; }
13145 else
13146   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13147 $as_echo "no" >&6; }
13148 fi
13149 
13150 
13151   test -n "$SETFILE" && break
13152 done
13153 
13154   else
13155     # The variable is set, but is it from the command line or the environment?
13156 
13157     # Try to remove the string !SETFILE! from our list.
13158     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/}
13159     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13160       # If it failed, the variable was not from the command line. Ignore it,
13161       # but warn the user (except for BASH, which is always set by the calling BASH).
13162       if test "xSETFILE" != xBASH; then
13163         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5
13164 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;}
13165       fi
13166       # Try to locate tool using the code snippet
13167       for ac_prog in SetFile
13168 do
13169   # Extract the first word of "$ac_prog", so it can be a program name with args.
13170 set dummy $ac_prog; ac_word=$2
13171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13172 $as_echo_n "checking for $ac_word... " >&6; }
13173 if ${ac_cv_path_SETFILE+:} false; then :
13174   $as_echo_n "(cached) " >&6
13175 else
13176   case $SETFILE in
13177   [\\/]* | ?:[\\/]*)
13178   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13179   ;;
13180   *)
13181   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13182 for as_dir in $PATH
13183 do
13184   IFS=$as_save_IFS
13185   test -z "$as_dir" && as_dir=.
13186     for ac_exec_ext in '' $ac_executable_extensions; do
13187   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13188     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13189     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13190     break 2
13191   fi
13192 done
13193   done
13194 IFS=$as_save_IFS
13195 
13196   ;;
13197 esac
13198 fi
13199 SETFILE=$ac_cv_path_SETFILE
13200 if test -n "$SETFILE"; then
13201   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13202 $as_echo "$SETFILE" >&6; }
13203 else
13204   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13205 $as_echo "no" >&6; }
13206 fi
13207 
13208 
13209   test -n "$SETFILE" && break
13210 done
13211 
13212     else
13213       # If it succeeded, then it was overridden by the user. We will use it
13214       # for the tool.
13215 
13216       # First remove it from the list of overridden variables, so we can test
13217       # for unknown variables in the end.
13218       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13219 
13220       # Check if the provided tool contains a complete path.
13221       tool_specified="$SETFILE"
13222       tool_basename="${tool_specified##*/}"
13223       if test "x$tool_basename" = "x$tool_specified"; then
13224         # A command without a complete path is provided, search $PATH.
13225         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5
13226 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;}
13227         # Extract the first word of "$tool_basename", so it can be a program name with args.
13228 set dummy $tool_basename; ac_word=$2
13229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13230 $as_echo_n "checking for $ac_word... " >&6; }
13231 if ${ac_cv_path_SETFILE+:} false; then :
13232   $as_echo_n "(cached) " >&6
13233 else
13234   case $SETFILE in
13235   [\\/]* | ?:[\\/]*)
13236   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13237   ;;
13238   *)
13239   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13240 for as_dir in $PATH
13241 do
13242   IFS=$as_save_IFS
13243   test -z "$as_dir" && as_dir=.
13244     for ac_exec_ext in '' $ac_executable_extensions; do
13245   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13246     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13247     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13248     break 2
13249   fi
13250 done
13251   done
13252 IFS=$as_save_IFS
13253 
13254   ;;
13255 esac
13256 fi
13257 SETFILE=$ac_cv_path_SETFILE
13258 if test -n "$SETFILE"; then
13259   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13260 $as_echo "$SETFILE" >&6; }
13261 else
13262   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13263 $as_echo "no" >&6; }
13264 fi
13265 
13266 
13267         if test "x$SETFILE" = x; then
13268           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13269         fi
13270       else
13271         # Otherwise we believe it is a complete path. Use it as it is.
13272         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5
13273 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;}
13274         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5
13275 $as_echo_n "checking for SETFILE... " >&6; }
13276         if test ! -x "$tool_specified"; then
13277           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13278 $as_echo "not found" >&6; }
13279           as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5
13280         fi
13281         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13282 $as_echo "$tool_specified" >&6; }
13283       fi
13284     fi
13285   fi
13286 
13287 
13288 
13289 
13290 # Now we can determine OpenJDK build and target platforms. This is required to
13291 # have early on.
13292 # Make sure we can run config.sub.
13293 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
13294   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
13295 
13296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
13297 $as_echo_n "checking build system type... " >&6; }
13298 if ${ac_cv_build+:} false; then :
13299   $as_echo_n "(cached) " >&6
13300 else
13301   ac_build_alias=$build_alias
13302 test "x$ac_build_alias" = x &&
13303   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
13304 test "x$ac_build_alias" = x &&
13305   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
13306 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
13307   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
13308 
13309 fi
13310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
13311 $as_echo "$ac_cv_build" >&6; }
13312 case $ac_cv_build in
13313 *-*-*) ;;
13314 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
13315 esac
13316 build=$ac_cv_build
13317 ac_save_IFS=$IFS; IFS='-'
13318 set x $ac_cv_build
13319 shift
13320 build_cpu=$1
13321 build_vendor=$2
13322 shift; shift
13323 # Remember, the first character of IFS is used to create $*,
13324 # except with old shells:
13325 build_os=$*
13326 IFS=$ac_save_IFS
13327 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
13328 
13329 
13330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
13331 $as_echo_n "checking host system type... " >&6; }
13332 if ${ac_cv_host+:} false; then :
13333   $as_echo_n "(cached) " >&6
13334 else
13335   if test "x$host_alias" = x; then
13336   ac_cv_host=$ac_cv_build
13337 else
13338   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
13339     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
13340 fi
13341 
13342 fi
13343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
13344 $as_echo "$ac_cv_host" >&6; }
13345 case $ac_cv_host in
13346 *-*-*) ;;
13347 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
13348 esac
13349 host=$ac_cv_host
13350 ac_save_IFS=$IFS; IFS='-'
13351 set x $ac_cv_host
13352 shift
13353 host_cpu=$1
13354 host_vendor=$2
13355 shift; shift
13356 # Remember, the first character of IFS is used to create $*,
13357 # except with old shells:
13358 host_os=$*
13359 IFS=$ac_save_IFS
13360 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
13361 
13362 
13363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
13364 $as_echo_n "checking target system type... " >&6; }
13365 if ${ac_cv_target+:} false; then :
13366   $as_echo_n "(cached) " >&6
13367 else
13368   if test "x$target_alias" = x; then
13369   ac_cv_target=$ac_cv_host
13370 else
13371   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
13372     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
13373 fi
13374 
13375 fi
13376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
13377 $as_echo "$ac_cv_target" >&6; }
13378 case $ac_cv_target in
13379 *-*-*) ;;
13380 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
13381 esac
13382 target=$ac_cv_target
13383 ac_save_IFS=$IFS; IFS='-'
13384 set x $ac_cv_target
13385 shift
13386 target_cpu=$1
13387 target_vendor=$2
13388 shift; shift
13389 # Remember, the first character of IFS is used to create $*,
13390 # except with old shells:
13391 target_os=$*
13392 IFS=$ac_save_IFS
13393 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
13394 
13395 
13396 # The aliases save the names the user supplied, while $host etc.
13397 # will get canonicalized.
13398 test -n "$target_alias" &&
13399   test "$program_prefix$program_suffix$program_transform_name" = \
13400     NONENONEs,x,x, &&
13401   program_prefix=${target_alias}-
13402 
13403   # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target"
13404   # is confusing; it assumes you are cross-compiling a cross-compiler (!)  and "target" is thus the target of the
13405   # product you're building. The target of this build is called "host". Since this is confusing to most people, we
13406   # have not adopted that system, but use "target" as the platform we are building for. In some places though we need
13407   # to use the configure naming style.
13408 
13409 
13410 
13411 
13412 
13413   # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME
13414   # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME
13415   # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build,
13416   # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME.
13417   OPENJDK_TARGET_AUTOCONF_NAME="$host"
13418   OPENJDK_BUILD_AUTOCONF_NAME="$build"
13419 
13420 
13421 
13422   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13423 
13424   case "$build_os" in
13425     *linux*)
13426       VAR_OS=linux
13427       VAR_OS_API=posix
13428       VAR_OS_ENV=linux
13429       ;;
13430     *solaris*)
13431       VAR_OS=solaris
13432       VAR_OS_API=posix
13433       VAR_OS_ENV=solaris
13434       ;;
13435     *darwin*)
13436       VAR_OS=macosx
13437       VAR_OS_API=posix
13438       VAR_OS_ENV=macosx
13439       ;;
13440     *bsd*)
13441       VAR_OS=bsd
13442       VAR_OS_API=posix
13443       VAR_OS_ENV=bsd
13444       ;;
13445     *cygwin*)
13446       VAR_OS=windows
13447       VAR_OS_API=winapi
13448       VAR_OS_ENV=windows.cygwin
13449       ;;
13450     *mingw*)
13451       VAR_OS=windows
13452       VAR_OS_API=winapi
13453       VAR_OS_ENV=windows.msys
13454       ;;
13455     *aix*)
13456       VAR_OS=aix
13457       VAR_OS_API=posix
13458       VAR_OS_ENV=aix
13459       ;;
13460     *)
13461       as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
13462       ;;
13463   esac
13464 
13465 
13466   # First argument is the cpu name from the trip/quad
13467   case "$build_cpu" in
13468     x86_64)
13469       VAR_CPU=x86_64
13470       VAR_CPU_ARCH=x86
13471       VAR_CPU_BITS=64
13472       VAR_CPU_ENDIAN=little
13473       ;;
13474     i?86)
13475       VAR_CPU=x86
13476       VAR_CPU_ARCH=x86
13477       VAR_CPU_BITS=32
13478       VAR_CPU_ENDIAN=little
13479       ;;
13480     arm*)
13481       VAR_CPU=arm
13482       VAR_CPU_ARCH=arm
13483       VAR_CPU_BITS=32
13484       VAR_CPU_ENDIAN=little
13485       ;;
13486     powerpc)
13487       VAR_CPU=ppc
13488       VAR_CPU_ARCH=ppc
13489       VAR_CPU_BITS=32
13490       VAR_CPU_ENDIAN=big
13491       ;;
13492     powerpc64)
13493       VAR_CPU=ppc64
13494       VAR_CPU_ARCH=ppc
13495       VAR_CPU_BITS=64
13496       VAR_CPU_ENDIAN=big
13497       ;;
13498     s390)
13499       VAR_CPU=s390
13500       VAR_CPU_ARCH=s390
13501       VAR_CPU_BITS=32
13502       VAR_CPU_ENDIAN=big
13503       ;;
13504     s390x)
13505       VAR_CPU=s390x
13506       VAR_CPU_ARCH=s390
13507       VAR_CPU_BITS=64
13508       VAR_CPU_ENDIAN=big
13509       ;;
13510     sparc)
13511       VAR_CPU=sparc
13512       VAR_CPU_ARCH=sparc
13513       VAR_CPU_BITS=32
13514       VAR_CPU_ENDIAN=big
13515       ;;
13516     sparcv9)
13517       VAR_CPU=sparcv9
13518       VAR_CPU_ARCH=sparc
13519       VAR_CPU_BITS=64
13520       VAR_CPU_ENDIAN=big
13521       ;;
13522     *)
13523       as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5
13524       ;;
13525   esac
13526 
13527   # ..and setup our own variables. (Do this explicitely to facilitate searching)
13528   OPENJDK_BUILD_OS="$VAR_OS"
13529   OPENJDK_BUILD_OS_API="$VAR_OS_API"
13530   OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV"
13531   OPENJDK_BUILD_CPU="$VAR_CPU"
13532   OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH"
13533   OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS"
13534   OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13535 
13536 
13537 
13538 
13539 
13540 
13541 
13542   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5
13543 $as_echo_n "checking openjdk-build os-cpu... " >&6; }
13544   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5
13545 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; }
13546 
13547   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13548 
13549   case "$host_os" in
13550     *linux*)
13551       VAR_OS=linux
13552       VAR_OS_API=posix
13553       VAR_OS_ENV=linux
13554       ;;
13555     *solaris*)
13556       VAR_OS=solaris
13557       VAR_OS_API=posix
13558       VAR_OS_ENV=solaris
13559       ;;
13560     *darwin*)
13561       VAR_OS=macosx
13562       VAR_OS_API=posix
13563       VAR_OS_ENV=macosx
13564       ;;
13565     *bsd*)
13566       VAR_OS=bsd
13567       VAR_OS_API=posix
13568       VAR_OS_ENV=bsd
13569       ;;
13570     *cygwin*)
13571       VAR_OS=windows
13572       VAR_OS_API=winapi
13573       VAR_OS_ENV=windows.cygwin
13574       ;;
13575     *mingw*)
13576       VAR_OS=windows
13577       VAR_OS_API=winapi
13578       VAR_OS_ENV=windows.msys
13579       ;;
13580     *aix*)
13581       VAR_OS=aix
13582       VAR_OS_API=posix
13583       VAR_OS_ENV=aix
13584       ;;
13585     *)
13586       as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
13587       ;;
13588   esac
13589 
13590 
13591   # First argument is the cpu name from the trip/quad
13592   case "$host_cpu" in
13593     x86_64)
13594       VAR_CPU=x86_64
13595       VAR_CPU_ARCH=x86
13596       VAR_CPU_BITS=64
13597       VAR_CPU_ENDIAN=little
13598       ;;
13599     i?86)
13600       VAR_CPU=x86
13601       VAR_CPU_ARCH=x86
13602       VAR_CPU_BITS=32
13603       VAR_CPU_ENDIAN=little
13604       ;;
13605     arm*)
13606       VAR_CPU=arm
13607       VAR_CPU_ARCH=arm
13608       VAR_CPU_BITS=32
13609       VAR_CPU_ENDIAN=little
13610       ;;
13611     powerpc)
13612       VAR_CPU=ppc
13613       VAR_CPU_ARCH=ppc
13614       VAR_CPU_BITS=32
13615       VAR_CPU_ENDIAN=big
13616       ;;
13617     powerpc64)
13618       VAR_CPU=ppc64
13619       VAR_CPU_ARCH=ppc
13620       VAR_CPU_BITS=64
13621       VAR_CPU_ENDIAN=big
13622       ;;
13623     s390)
13624       VAR_CPU=s390
13625       VAR_CPU_ARCH=s390
13626       VAR_CPU_BITS=32
13627       VAR_CPU_ENDIAN=big
13628       ;;
13629     s390x)
13630       VAR_CPU=s390x
13631       VAR_CPU_ARCH=s390
13632       VAR_CPU_BITS=64
13633       VAR_CPU_ENDIAN=big
13634       ;;
13635     sparc)
13636       VAR_CPU=sparc
13637       VAR_CPU_ARCH=sparc
13638       VAR_CPU_BITS=32
13639       VAR_CPU_ENDIAN=big
13640       ;;
13641     sparcv9)
13642       VAR_CPU=sparcv9
13643       VAR_CPU_ARCH=sparc
13644       VAR_CPU_BITS=64
13645       VAR_CPU_ENDIAN=big
13646       ;;
13647     *)
13648       as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5
13649       ;;
13650   esac
13651 
13652   # ... and setup our own variables. (Do this explicitely to facilitate searching)
13653   OPENJDK_TARGET_OS="$VAR_OS"
13654   OPENJDK_TARGET_OS_API="$VAR_OS_API"
13655   OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV"
13656   OPENJDK_TARGET_CPU="$VAR_CPU"
13657   OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH"
13658   OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS"
13659   OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13660 
13661 
13662 
13663 
13664 
13665 
13666 
13667   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5
13668 $as_echo_n "checking openjdk-target os-cpu... " >&6; }
13669   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5
13670 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; }
13671 
13672 
13673 
13674 # Check whether --with-target-bits was given.
13675 if test "${with_target_bits+set}" = set; then :
13676   withval=$with_target_bits;
13677 fi
13678 
13679 
13680   # We have three types of compiles:
13681   # native  == normal compilation, target system == build system
13682   # cross   == traditional cross compilation, target system != build system; special toolchain needed
13683   # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines
13684   #
13685   if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then
13686     # We're doing a proper cross-compilation
13687     COMPILE_TYPE="cross"
13688   else
13689     COMPILE_TYPE="native"
13690   fi
13691 
13692   if test "x$with_target_bits" != x; then
13693     if test "x$COMPILE_TYPE" = "xcross"; then
13694       as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5
13695     fi
13696 
13697     if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13698       # A reduced build is requested
13699       COMPILE_TYPE="reduced"
13700       OPENJDK_TARGET_CPU_BITS=32
13701       if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
13702         OPENJDK_TARGET_CPU=x86
13703       elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
13704         OPENJDK_TARGET_CPU=sparc
13705       else
13706         as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5
13707       fi
13708     elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
13709       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
13710     elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then
13711       { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5
13712 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;}
13713     else
13714       as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5
13715     fi
13716   fi
13717 
13718 
13719   { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5
13720 $as_echo_n "checking compilation type... " >&6; }
13721   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5
13722 $as_echo "$COMPILE_TYPE" >&6; }
13723 
13724 
13725   if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
13726     REQUIRED_OS_NAME=SunOS
13727     REQUIRED_OS_VERSION=5.10
13728   fi
13729   if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
13730     REQUIRED_OS_NAME=Linux
13731     REQUIRED_OS_VERSION=2.6
13732   fi
13733   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13734     REQUIRED_OS_NAME=Windows
13735     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
13736       REQUIRED_OS_VERSION=5.2
13737     else
13738       REQUIRED_OS_VERSION=5.1
13739     fi
13740   fi
13741   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
13742     REQUIRED_OS_NAME=Darwin
13743     REQUIRED_OS_VERSION=11.2
13744   fi
13745 
13746 
13747 
13748 
13749 
13750   # Also store the legacy naming of the cpu.
13751   # Ie i586 and amd64 instead of x86 and x86_64
13752   OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU"
13753   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13754     OPENJDK_TARGET_CPU_LEGACY="i586"
13755   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13756     # On all platforms except MacOSX replace x86_64 with amd64.
13757     OPENJDK_TARGET_CPU_LEGACY="amd64"
13758   fi
13759 
13760 
13761   # And the second legacy naming of the cpu.
13762   # Ie i386 and amd64 instead of x86 and x86_64.
13763   OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU"
13764   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13765     OPENJDK_TARGET_CPU_LEGACY_LIB="i386"
13766   elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13767     OPENJDK_TARGET_CPU_LEGACY_LIB="amd64"
13768   fi
13769 
13770 
13771   # This is the name of the cpu (but using i386 and amd64 instead of
13772   # x86 and x86_64, respectively), preceeded by a /, to be used when
13773   # locating libraries. On macosx, it's empty, though.
13774   OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB"
13775   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13776     OPENJDK_TARGET_CPU_LIBDIR=""
13777   fi
13778 
13779 
13780   # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to
13781   # /amd64 or /sparcv9. This string is appended to some library paths, like this:
13782   # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so
13783   OPENJDK_TARGET_CPU_ISADIR=""
13784   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13785     if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13786       OPENJDK_TARGET_CPU_ISADIR="/amd64"
13787     elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then
13788       OPENJDK_TARGET_CPU_ISADIR="/sparcv9"
13789     fi
13790   fi
13791 
13792 
13793   # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property
13794   OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU"
13795   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then
13796     # On linux only, we replace x86 with i386.
13797     OPENJDK_TARGET_CPU_OSARCH="i386"
13798   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13799     # On all platforms except macosx, we replace x86_64 with amd64.
13800     OPENJDK_TARGET_CPU_OSARCH="amd64"
13801   fi
13802 
13803 
13804   OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU"
13805   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13806     OPENJDK_TARGET_CPU_JLI="i386"
13807   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13808     # On all platforms except macosx, we replace x86_64 with amd64.
13809     OPENJDK_TARGET_CPU_JLI="amd64"
13810   fi
13811   # Now setup the -D flags for building libjli.
13812   OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'"
13813   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13814     if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then
13815       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'"
13816     elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
13817       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'"
13818     fi
13819   fi
13820 
13821 
13822   # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths.
13823   if test "x$OPENJDK_TARGET_OS_API" = xposix; then
13824     OPENJDK_TARGET_OS_API_DIR="solaris"
13825   fi
13826   if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then
13827     OPENJDK_TARGET_OS_API_DIR="windows"
13828   fi
13829 
13830 
13831   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13832       OPENJDK_TARGET_OS_EXPORT_DIR=macosx
13833   else
13834       OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_API_DIR}
13835   fi
13836 
13837 
13838   if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13839     A_LP64="LP64:="
13840     # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
13841     # unpack200.exe
13842     if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then
13843       ADD_LP64="-D_LP64=1"
13844     fi
13845   fi
13846   LP64=$A_LP64
13847 
13848 
13849   if test "x$COMPILE_TYPE" = "xcross"; then
13850     # FIXME: ... or should this include reduced builds..?
13851     DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY"
13852   else
13853     DEFINE_CROSS_COMPILE_ARCH=""
13854   fi
13855 
13856 
13857   # ZERO_ARCHDEF is used to enable architecture-specific code
13858   case "${OPENJDK_TARGET_CPU}" in
13859     ppc*)    ZERO_ARCHDEF=PPC   ;;
13860     s390*)   ZERO_ARCHDEF=S390  ;;
13861     sparc*)  ZERO_ARCHDEF=SPARC ;;
13862     x86_64*) ZERO_ARCHDEF=AMD64 ;;
13863     x86)     ZERO_ARCHDEF=IA32  ;;
13864     *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
13865   esac
13866 
13867 
13868 
13869 
13870 # Continue setting up basic stuff. Most remaining code require fundamental tools.
13871 
13872   # We get the top-level directory from the supporting wrappers.
13873   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5
13874 $as_echo_n "checking for top-level directory... " >&6; }
13875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5
13876 $as_echo "$TOPDIR" >&6; }
13877 
13878   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13879 
13880   # Input might be given as Windows format, start by converting to
13881   # unix format.
13882   path="$TOPDIR"
13883   new_path=`$CYGPATH -u "$path"`
13884 
13885   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
13886   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
13887   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
13888   # "foo.exe" is OK but "foo" is an error.
13889   #
13890   # This test is therefore slightly more accurate than "test -f" to check for file precense.
13891   # It is also a way to make sure we got the proper file name for the real test later on.
13892   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
13893   if test "x$test_shortpath" = x; then
13894     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13895 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13896     as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5
13897   fi
13898 
13899   # Call helper function which possibly converts this using DOS-style short mode.
13900   # If so, the updated path is stored in $new_path.
13901 
13902   input_path="$new_path"
13903   # Check if we need to convert this using DOS-style short mode. If the path
13904   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13905   # take no chances and rewrite it.
13906   # Note: m4 eats our [], so we need to use [ and ] instead.
13907   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
13908   if test "x$has_forbidden_chars" != x; then
13909     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13910     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
13911     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
13912     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
13913       # Going to short mode and back again did indeed matter. Since short mode is
13914       # case insensitive, let's make it lowercase to improve readability.
13915       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13916       # Now convert it back to Unix-stile (cygpath)
13917       input_path=`$CYGPATH -u "$shortmode_path"`
13918       new_path="$input_path"
13919     fi
13920   fi
13921 
13922   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
13923   if test "x$test_cygdrive_prefix" = x; then
13924     # As a simple fix, exclude /usr/bin since it's not a real path.
13925     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
13926       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
13927       # a path prefixed by /cygdrive for fixpath to work.
13928       new_path="$CYGWIN_ROOT_PATH$input_path"
13929     fi
13930   fi
13931 
13932 
13933   if test "x$path" != "x$new_path"; then
13934     TOPDIR="$new_path"
13935     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13936 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13937   fi
13938 
13939   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13940 
13941   path="$TOPDIR"
13942   has_colon=`$ECHO $path | $GREP ^.:`
13943   new_path="$path"
13944   if test "x$has_colon" = x; then
13945     # Not in mixed or Windows style, start by that.
13946     new_path=`cmd //c echo $path`
13947   fi
13948 
13949 
13950   input_path="$new_path"
13951   # Check if we need to convert this using DOS-style short mode. If the path
13952   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13953   # take no chances and rewrite it.
13954   # Note: m4 eats our [], so we need to use [ and ] instead.
13955   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
13956   if test "x$has_forbidden_chars" != x; then
13957     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13958     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13959   fi
13960 
13961 
13962   windows_path="$new_path"
13963   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13964     unix_path=`$CYGPATH -u "$windows_path"`
13965     new_path="$unix_path"
13966   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13967     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
13968     new_path="$unix_path"
13969   fi
13970 
13971   if test "x$path" != "x$new_path"; then
13972     TOPDIR="$new_path"
13973     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13974 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13975   fi
13976 
13977   # Save the first 10 bytes of this path to the storage, so fixpath can work.
13978   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
13979 
13980   else
13981     # We're on a posix platform. Hooray! :)
13982     path="$TOPDIR"
13983     has_space=`$ECHO "$path" | $GREP " "`
13984     if test "x$has_space" != x; then
13985       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13986 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13987       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
13988     fi
13989 
13990     # Use eval to expand a potential ~
13991     eval path="$path"
13992     if test ! -f "$path" && test ! -d "$path"; then
13993       as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
13994     fi
13995 
13996     TOPDIR="`cd "$path"; $THEPWDCMD -L`"
13997   fi
13998 
13999 
14000 
14001   # SRC_ROOT is a traditional alias for TOPDIR.
14002   SRC_ROOT=$TOPDIR
14003 
14004   # Locate the directory of this script.
14005   AUTOCONF_DIR=$TOPDIR/common/autoconf
14006 
14007   # Save the current directory this script was started from
14008   CURDIR="$PWD"
14009 
14010   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14011 
14012   # Input might be given as Windows format, start by converting to
14013   # unix format.
14014   path="$CURDIR"
14015   new_path=`$CYGPATH -u "$path"`
14016 
14017   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14018   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14019   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14020   # "foo.exe" is OK but "foo" is an error.
14021   #
14022   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14023   # It is also a way to make sure we got the proper file name for the real test later on.
14024   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14025   if test "x$test_shortpath" = x; then
14026     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14027 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14028     as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5
14029   fi
14030 
14031   # Call helper function which possibly converts this using DOS-style short mode.
14032   # If so, the updated path is stored in $new_path.
14033 
14034   input_path="$new_path"
14035   # Check if we need to convert this using DOS-style short mode. If the path
14036   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14037   # take no chances and rewrite it.
14038   # Note: m4 eats our [], so we need to use [ and ] instead.
14039   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14040   if test "x$has_forbidden_chars" != x; then
14041     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14042     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14043     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14044     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14045       # Going to short mode and back again did indeed matter. Since short mode is
14046       # case insensitive, let's make it lowercase to improve readability.
14047       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14048       # Now convert it back to Unix-stile (cygpath)
14049       input_path=`$CYGPATH -u "$shortmode_path"`
14050       new_path="$input_path"
14051     fi
14052   fi
14053 
14054   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14055   if test "x$test_cygdrive_prefix" = x; then
14056     # As a simple fix, exclude /usr/bin since it's not a real path.
14057     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14058       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14059       # a path prefixed by /cygdrive for fixpath to work.
14060       new_path="$CYGWIN_ROOT_PATH$input_path"
14061     fi
14062   fi
14063 
14064 
14065   if test "x$path" != "x$new_path"; then
14066     CURDIR="$new_path"
14067     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14068 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14069   fi
14070 
14071   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14072 
14073   path="$CURDIR"
14074   has_colon=`$ECHO $path | $GREP ^.:`
14075   new_path="$path"
14076   if test "x$has_colon" = x; then
14077     # Not in mixed or Windows style, start by that.
14078     new_path=`cmd //c echo $path`
14079   fi
14080 
14081 
14082   input_path="$new_path"
14083   # Check if we need to convert this using DOS-style short mode. If the path
14084   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14085   # take no chances and rewrite it.
14086   # Note: m4 eats our [], so we need to use [ and ] instead.
14087   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14088   if test "x$has_forbidden_chars" != x; then
14089     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14090     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14091   fi
14092 
14093 
14094   windows_path="$new_path"
14095   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14096     unix_path=`$CYGPATH -u "$windows_path"`
14097     new_path="$unix_path"
14098   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14099     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14100     new_path="$unix_path"
14101   fi
14102 
14103   if test "x$path" != "x$new_path"; then
14104     CURDIR="$new_path"
14105     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14106 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14107   fi
14108 
14109   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14110   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14111 
14112   else
14113     # We're on a posix platform. Hooray! :)
14114     path="$CURDIR"
14115     has_space=`$ECHO "$path" | $GREP " "`
14116     if test "x$has_space" != x; then
14117       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14118 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14119       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14120     fi
14121 
14122     # Use eval to expand a potential ~
14123     eval path="$path"
14124     if test ! -f "$path" && test ! -d "$path"; then
14125       as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14126     fi
14127 
14128     CURDIR="`cd "$path"; $THEPWDCMD -L`"
14129   fi
14130 
14131 
14132   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
14133     PATH_SEP=";"
14134 
14135   SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m`
14136   if test $SRC_ROOT_LENGTH -gt 100; then
14137     as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5
14138   fi
14139 
14140   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14141     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5
14142 $as_echo_n "checking cygwin release... " >&6; }
14143     CYGWIN_VERSION=`$UNAME -r`
14144     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5
14145 $as_echo "$CYGWIN_VERSION" >&6; }
14146     WINDOWS_ENV_VENDOR='cygwin'
14147     WINDOWS_ENV_VERSION="$CYGWIN_VERSION"
14148 
14149     CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.`
14150     if test "x$CYGWIN_VERSION_OK" = x; then
14151       { $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
14152 $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;}
14153       as_fn_error $? "Cannot continue" "$LINENO" 5
14154     fi
14155     if test "x$CYGPATH" = x; then
14156       as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5
14157     fi
14158     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5
14159 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; }
14160     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14161     cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"`
14162     # Force cygpath to report the proper root by including a trailing space, and then stripping it off again.
14163     CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "`
14164     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5
14165 $as_echo "$CYGWIN_ROOT_PATH" >&6; }
14166     WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH"
14167     test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/`
14168     if test "x$test_cygdrive_prefix" = x; then
14169       as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5
14170     fi
14171   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14172     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5
14173 $as_echo_n "checking msys release... " >&6; }
14174     MSYS_VERSION=`$UNAME -r`
14175     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5
14176 $as_echo "$MSYS_VERSION" >&6; }
14177 
14178     WINDOWS_ENV_VENDOR='msys'
14179     WINDOWS_ENV_VERSION="$MSYS_VERSION"
14180 
14181     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5
14182 $as_echo_n "checking msys root directory as unix-style path... " >&6; }
14183     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14184     MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"`
14185 
14186   windows_path="$MSYS_ROOT_PATH"
14187   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14188     unix_path=`$CYGPATH -u "$windows_path"`
14189     MSYS_ROOT_PATH="$unix_path"
14190   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14191     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14192     MSYS_ROOT_PATH="$unix_path"
14193   fi
14194 
14195     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5
14196 $as_echo "$MSYS_ROOT_PATH" >&6; }
14197     WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH"
14198   else
14199     as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5
14200   fi
14201 
14202   # Test if windows or unix (cygwin/msys) find is first in path.
14203   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5
14204 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; }
14205   FIND_BINARY_OUTPUT=`find --version 2>&1`
14206   if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then
14207     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5
14208 $as_echo "unix style" >&6; }
14209   elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then
14210     { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5
14211 $as_echo "Windows" >&6; }
14212     { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5
14213 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;}
14214     { $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
14215 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;}
14216     as_fn_error $? "Cannot continue" "$LINENO" 5
14217   else
14218     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
14219 $as_echo "unknown" >&6; }
14220     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5
14221 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;}
14222   fi
14223 
14224   else
14225     PATH_SEP=":"
14226   fi
14227 
14228 
14229   if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14230     # Add extra search paths on solaris for utilities like ar and as etc...
14231     PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14232   fi
14233 
14234   # You can force the sys-root if the sys-root encoded into the cross compiler tools
14235   # is not correct.
14236 
14237 # Check whether --with-sys-root was given.
14238 if test "${with_sys_root+set}" = set; then :
14239   withval=$with_sys_root;
14240 fi
14241 
14242 
14243   if test "x$with_sys_root" != x; then
14244     SYS_ROOT=$with_sys_root
14245   else
14246     SYS_ROOT=/
14247   fi
14248 
14249 
14250 
14251 # Check whether --with-tools-dir was given.
14252 if test "${with_tools_dir+set}" = set; then :
14253   withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir
14254 
14255 fi
14256 
14257 
14258 
14259 # Check whether --with-devkit was given.
14260 if test "${with_devkit+set}" = set; then :
14261   withval=$with_devkit;
14262         if test "x$with_sys_root" != x; then
14263           as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5
14264         fi
14265 
14266   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14267 
14268   # Input might be given as Windows format, start by converting to
14269   # unix format.
14270   path="$with_devkit"
14271   new_path=`$CYGPATH -u "$path"`
14272 
14273   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14274   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14275   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14276   # "foo.exe" is OK but "foo" is an error.
14277   #
14278   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14279   # It is also a way to make sure we got the proper file name for the real test later on.
14280   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14281   if test "x$test_shortpath" = x; then
14282     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14283 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14284     as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5
14285   fi
14286 
14287   # Call helper function which possibly converts this using DOS-style short mode.
14288   # If so, the updated path is stored in $new_path.
14289 
14290   input_path="$new_path"
14291   # Check if we need to convert this using DOS-style short mode. If the path
14292   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14293   # take no chances and rewrite it.
14294   # Note: m4 eats our [], so we need to use [ and ] instead.
14295   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14296   if test "x$has_forbidden_chars" != x; then
14297     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14298     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14299     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14300     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14301       # Going to short mode and back again did indeed matter. Since short mode is
14302       # case insensitive, let's make it lowercase to improve readability.
14303       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14304       # Now convert it back to Unix-stile (cygpath)
14305       input_path=`$CYGPATH -u "$shortmode_path"`
14306       new_path="$input_path"
14307     fi
14308   fi
14309 
14310   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14311   if test "x$test_cygdrive_prefix" = x; then
14312     # As a simple fix, exclude /usr/bin since it's not a real path.
14313     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14314       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14315       # a path prefixed by /cygdrive for fixpath to work.
14316       new_path="$CYGWIN_ROOT_PATH$input_path"
14317     fi
14318   fi
14319 
14320 
14321   if test "x$path" != "x$new_path"; then
14322     with_devkit="$new_path"
14323     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14324 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14325   fi
14326 
14327   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14328 
14329   path="$with_devkit"
14330   has_colon=`$ECHO $path | $GREP ^.:`
14331   new_path="$path"
14332   if test "x$has_colon" = x; then
14333     # Not in mixed or Windows style, start by that.
14334     new_path=`cmd //c echo $path`
14335   fi
14336 
14337 
14338   input_path="$new_path"
14339   # Check if we need to convert this using DOS-style short mode. If the path
14340   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14341   # take no chances and rewrite it.
14342   # Note: m4 eats our [], so we need to use [ and ] instead.
14343   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14344   if test "x$has_forbidden_chars" != x; then
14345     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14346     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14347   fi
14348 
14349 
14350   windows_path="$new_path"
14351   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14352     unix_path=`$CYGPATH -u "$windows_path"`
14353     new_path="$unix_path"
14354   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14355     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14356     new_path="$unix_path"
14357   fi
14358 
14359   if test "x$path" != "x$new_path"; then
14360     with_devkit="$new_path"
14361     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14362 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14363   fi
14364 
14365   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14366   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14367 
14368   else
14369     # We're on a posix platform. Hooray! :)
14370     path="$with_devkit"
14371     has_space=`$ECHO "$path" | $GREP " "`
14372     if test "x$has_space" != x; then
14373       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14374 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14375       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14376     fi
14377 
14378     # Use eval to expand a potential ~
14379     eval path="$path"
14380     if test ! -f "$path" && test ! -d "$path"; then
14381       as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14382     fi
14383 
14384     with_devkit="`cd "$path"; $THEPWDCMD -L`"
14385   fi
14386 
14387 
14388   if test "x$TOOLS_DIR" = x; then
14389     TOOLS_DIR="$with_devkit/bin"
14390   else
14391     TOOLS_DIR="$TOOLS_DIR:$with_devkit/bin"
14392   fi
14393 
14394         if test -d "$with_devkit/$host_alias/libc"; then
14395           SYS_ROOT=$with_devkit/$host_alias/libc
14396         elif test -d "$with_devkit/$host/sys-root"; then
14397           SYS_ROOT=$with_devkit/$host/sys-root
14398         fi
14399 
14400 fi
14401 
14402 
14403 
14404   # Setup default logging of stdout and stderr to build.log in the output root.
14405   BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14406   BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14407   BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14408 
14409 
14410 
14411 
14412 
14413 # Check if it's a pure open build or if custom sources are to be used.
14414 
14415   # Check whether --enable-openjdk-only was given.
14416 if test "${enable_openjdk_only+set}" = set; then :
14417   enableval=$enable_openjdk_only;
14418 else
14419   enable_openjdk_only="no"
14420 fi
14421 
14422 
14423   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5
14424 $as_echo_n "checking for presence of closed sources... " >&6; }
14425   if test -d "$SRC_ROOT/jdk/src/closed"; then
14426     CLOSED_SOURCE_PRESENT=yes
14427   else
14428     CLOSED_SOURCE_PRESENT=no
14429   fi
14430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5
14431 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; }
14432 
14433   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5
14434 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; }
14435   SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only"
14436   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5
14437 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; }
14438 
14439   if test "x$CLOSED_SOURCE_PRESENT" = xno; then
14440     OPENJDK=true
14441     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14442       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5
14443 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;}
14444     fi
14445   else
14446     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14447       OPENJDK=true
14448     else
14449       OPENJDK=false
14450     fi
14451   fi
14452 
14453   if test "x$OPENJDK" = "xtrue"; then
14454     SET_OPENJDK="OPENJDK=true"
14455   fi
14456 
14457 
14458 
14459   # custom-make-dir is deprecated. Please use your custom-hook.m4 to override
14460   # the IncludeCustomExtension macro.
14461 
14462 
14463 # Check whether --with-custom-make-dir was given.
14464 if test "${with_custom_make_dir+set}" = set; then :
14465   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
14466 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;}
14467 fi
14468 
14469 
14470 
14471 
14472 # These are needed to be able to create a configuration name (and thus the output directory)
14473 
14474   ###############################################################################
14475   #
14476   # Check which variant of the JDK that we want to build.
14477   # Currently we have:
14478   #    normal:   standard edition
14479   # but the custom make system may add other variants
14480   #
14481   # Effectively the JDK variant gives a name to a specific set of
14482   # modules to compile into the JDK. In the future, these modules
14483   # might even be Jigsaw modules.
14484   #
14485   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5
14486 $as_echo_n "checking which variant of the JDK to build... " >&6; }
14487 
14488 # Check whether --with-jdk-variant was given.
14489 if test "${with_jdk_variant+set}" = set; then :
14490   withval=$with_jdk_variant;
14491 fi
14492 
14493 
14494   if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then
14495     JDK_VARIANT="normal"
14496   else
14497     as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5
14498   fi
14499 
14500 
14501 
14502   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5
14503 $as_echo "$JDK_VARIANT" >&6; }
14504 
14505 
14506 ###############################################################################
14507 #
14508 # Check which interpreter of the JVM we want to build.
14509 # Currently we have:
14510 #    template: Template interpreter (the default)
14511 #    cpp     : C++ interpreter
14512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5
14513 $as_echo_n "checking which interpreter of the JVM to build... " >&6; }
14514 
14515 # Check whether --with-jvm-interpreter was given.
14516 if test "${with_jvm_interpreter+set}" = set; then :
14517   withval=$with_jvm_interpreter;
14518 fi
14519 
14520 
14521 if test "x$with_jvm_interpreter" = x; then
14522      with_jvm_interpreter="template"
14523 fi
14524 
14525 JVM_INTERPRETER="$with_jvm_interpreter"
14526 
14527 if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then
14528    as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5
14529 fi
14530 
14531 
14532 
14533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_interpreter" >&5
14534 $as_echo "$with_jvm_interpreter" >&6; }
14535 
14536 
14537 
14538   ###############################################################################
14539   #
14540   # Check which variants of the JVM that we want to build.
14541   # Currently we have:
14542   #    server: normal interpreter and a tiered C1/C2 compiler
14543   #    client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms)
14544   #    minimal1: reduced form of client with optional VM services and features stripped out
14545   #    kernel: kernel footprint JVM that passes the TCK without major performance problems,
14546   #             ie normal interpreter and C1, only the serial GC, kernel jvmti etc
14547   #    zero: no machine code interpreter, no compiler
14548   #    zeroshark: zero interpreter and shark/llvm compiler backend
14549 #    core: interpreter only, no compiler (only works on some platforms)
14550   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5
14551 $as_echo_n "checking which variants of the JVM to build... " >&6; }
14552 
14553 # Check whether --with-jvm-variants was given.
14554 if test "${with_jvm_variants+set}" = set; then :
14555   withval=$with_jvm_variants;
14556 fi
14557 
14558 
14559   if test "x$with_jvm_variants" = x; then
14560     with_jvm_variants="server"
14561   fi
14562 
14563   JVM_VARIANTS=",$with_jvm_variants,"
14564   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,//'`
14565 
14566   if test "x$TEST_VARIANTS" != "x,"; then
14567      as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark, core" "$LINENO" 5
14568   fi
14569   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5
14570 $as_echo "$with_jvm_variants" >&6; }
14571 
14572   JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
14573   JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
14574   JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'`
14575   JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'`
14576   JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
14577   JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
14578   JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
14579 
14580   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14581     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14582       as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5
14583     fi
14584   fi
14585   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14586     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14587       as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5
14588     fi
14589   fi
14590   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14591     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14592       as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5
14593     fi
14594   fi
14595 
14596   # Replace the commas with AND for use in the build directory name.
14597   ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'`
14598   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/'`
14599   if test "x$COUNT_VARIANTS" != "x,1"; then
14600     BUILDING_MULTIPLE_JVM_VARIANTS=yes
14601   else
14602     BUILDING_MULTIPLE_JVM_VARIANTS=no
14603   fi
14604 
14605 
14606 
14607 
14608 
14609 
14610 
14611 
14612 
14613 
14614   INCLUDE_SA=true
14615   if test "x$JVM_VARIANT_ZERO" = xtrue ; then
14616     INCLUDE_SA=false
14617   fi
14618   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then
14619     INCLUDE_SA=false
14620   fi
14621   if test "x$VAR_CPU" = xppc64 ; then
14622     INCLUDE_SA=false
14623   fi
14624 
14625 
14626   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
14627     MACOSX_UNIVERSAL="true"
14628   fi
14629 
14630 
14631 
14632 
14633   ###############################################################################
14634   #
14635   # Set the debug level
14636   #    release: no debug information, all optimizations, no asserts.
14637   #    fastdebug: debug information (-g), all optimizations, all asserts
14638   #    slowdebug: debug information (-g), no optimizations, all asserts
14639   #
14640   DEBUG_LEVEL="release"
14641   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5
14642 $as_echo_n "checking which debug level to use... " >&6; }
14643   # Check whether --enable-debug was given.
14644 if test "${enable_debug+set}" = set; then :
14645   enableval=$enable_debug;
14646         ENABLE_DEBUG="${enableval}"
14647         DEBUG_LEVEL="fastdebug"
14648 
14649 else
14650   ENABLE_DEBUG="no"
14651 fi
14652 
14653 
14654 
14655 # Check whether --with-debug-level was given.
14656 if test "${with_debug_level+set}" = set; then :
14657   withval=$with_debug_level;
14658         DEBUG_LEVEL="${withval}"
14659         if test "x$ENABLE_DEBUG" = xyes; then
14660           as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5
14661         fi
14662 
14663 fi
14664 
14665   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5
14666 $as_echo "$DEBUG_LEVEL" >&6; }
14667 
14668   if test "x$DEBUG_LEVEL" != xrelease && \
14669       test "x$DEBUG_LEVEL" != xfastdebug && \
14670       test "x$DEBUG_LEVEL" != xslowdebug; then
14671     as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5
14672   fi
14673 
14674 
14675   ###############################################################################
14676   #
14677   # Setup legacy vars/targets and new vars to deal with different debug levels.
14678   #
14679 
14680   case $DEBUG_LEVEL in
14681     release )
14682       VARIANT="OPT"
14683       FASTDEBUG="false"
14684       DEBUG_CLASSFILES="false"
14685       BUILD_VARIANT_RELEASE=""
14686       HOTSPOT_DEBUG_LEVEL="product"
14687       HOTSPOT_EXPORT="product"
14688       ;;
14689     fastdebug )
14690       VARIANT="DBG"
14691       FASTDEBUG="true"
14692       DEBUG_CLASSFILES="true"
14693       BUILD_VARIANT_RELEASE="-fastdebug"
14694       HOTSPOT_DEBUG_LEVEL="fastdebug"
14695       HOTSPOT_EXPORT="fastdebug"
14696       ;;
14697     slowdebug )
14698       VARIANT="DBG"
14699       FASTDEBUG="false"
14700       DEBUG_CLASSFILES="true"
14701       BUILD_VARIANT_RELEASE="-debug"
14702       HOTSPOT_DEBUG_LEVEL="jvmg"
14703       HOTSPOT_EXPORT="debug"
14704       ;;
14705   esac
14706 
14707   #####
14708   # Generate the legacy makefile targets for hotspot.
14709   # The hotspot api for selecting the build artifacts, really, needs to be improved.
14710   # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to
14711   # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc
14712   # But until then ...
14713   HOTSPOT_TARGET=""
14714 
14715   if test "x$JVM_VARIANT_SERVER" = xtrue; then
14716     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
14717   fi
14718 
14719   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14720     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
14721   fi
14722 
14723   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14724     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
14725   fi
14726 
14727   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14728     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel "
14729   fi
14730 
14731   if test "x$JVM_VARIANT_ZERO" = xtrue; then
14732     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
14733   fi
14734 
14735   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
14736     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
14737   fi
14738 
14739   if test "x$JVM_VARIANT_CORE" = xtrue; then
14740     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
14741   fi
14742 
14743   HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT"
14744 
14745   # On Macosx universal binaries are produced, but they only contain
14746   # 64 bit intel. This invalidates control of which jvms are built
14747   # from configure, but only server is valid anyway. Fix this
14748   # when hotspot makefiles are rewritten.
14749   if test "x$MACOSX_UNIVERSAL" = xtrue; then
14750     HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT}
14751   fi
14752 
14753   #####
14754 
14755 
14756 
14757 
14758 
14759 
14760 
14761 
14762 # With basic setup done, call the custom early hook.
14763 
14764 
14765 # To properly create a configuration name, we need to have the OpenJDK target
14766 # and options (variants and debug level) parsed.
14767 
14768 
14769 
14770 # Check whether --with-conf-name was given.
14771 if test "${with_conf_name+set}" = set; then :
14772   withval=$with_conf_name;  CONF_NAME=${with_conf_name}
14773 fi
14774 
14775 
14776   # Test from where we are running configure, in or outside of src root.
14777   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5
14778 $as_echo_n "checking where to store configuration... " >&6; }
14779   if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \
14780       || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \
14781       || test "x$CURDIR" = "x$SRC_ROOT/make" ; then
14782     # We are running configure from the src root.
14783     # Create a default ./build/target-variant-debuglevel output root.
14784     if test "x${CONF_NAME}" = x; then
14785       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5
14786 $as_echo "in default location" >&6; }
14787       CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}"
14788     else
14789       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5
14790 $as_echo "in build directory with custom name" >&6; }
14791     fi
14792     OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}"
14793     $MKDIR -p "$OUTPUT_ROOT"
14794     if test ! -d "$OUTPUT_ROOT"; then
14795       as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5
14796     fi
14797   else
14798     # We are running configure from outside of the src dir.
14799     # Then use the current directory as output dir!
14800     # If configuration is situated in normal build directory, just use the build
14801     # directory name as configuration name, otherwise use the complete path.
14802     if test "x${CONF_NAME}" = x; then
14803       CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"`
14804     fi
14805     OUTPUT_ROOT="$CURDIR"
14806     { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5
14807 $as_echo "in current directory" >&6; }
14808 
14809     # WARNING: This might be a bad thing to do. You need to be sure you want to
14810     # have a configuration in this directory. Do some sanity checks!
14811 
14812     if test ! -e "$OUTPUT_ROOT/spec.gmk"; then
14813       # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for
14814       # other files
14815       files_present=`$LS $OUTPUT_ROOT`
14816       # Configure has already touched config.log and confdefs.h in the current dir when this check
14817       # is performed.
14818       filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \
14819       | $TR -d '\n'`
14820       if test "x$filtered_files" != x; then
14821         { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5
14822 $as_echo "$as_me: Current directory is $CURDIR." >&6;}
14823         { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5
14824 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;}
14825         { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5
14826 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;}
14827         { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5
14828 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;}
14829         { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5
14830 $as_echo "$as_me: seriously mess up just about everything." >&6;}
14831         { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5
14832 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;}
14833         { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5
14834 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;}
14835         as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5
14836       fi
14837     fi
14838   fi
14839   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5
14840 $as_echo_n "checking what configuration name to use... " >&6; }
14841   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5
14842 $as_echo "$CONF_NAME" >&6; }
14843 
14844 
14845   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14846 
14847   # Input might be given as Windows format, start by converting to
14848   # unix format.
14849   path="$OUTPUT_ROOT"
14850   new_path=`$CYGPATH -u "$path"`
14851 
14852   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14853   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14854   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14855   # "foo.exe" is OK but "foo" is an error.
14856   #
14857   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14858   # It is also a way to make sure we got the proper file name for the real test later on.
14859   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14860   if test "x$test_shortpath" = x; then
14861     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14862 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14863     as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5
14864   fi
14865 
14866   # Call helper function which possibly converts this using DOS-style short mode.
14867   # If so, the updated path is stored in $new_path.
14868 
14869   input_path="$new_path"
14870   # Check if we need to convert this using DOS-style short mode. If the path
14871   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14872   # take no chances and rewrite it.
14873   # Note: m4 eats our [], so we need to use [ and ] instead.
14874   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14875   if test "x$has_forbidden_chars" != x; then
14876     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14877     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14878     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14879     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14880       # Going to short mode and back again did indeed matter. Since short mode is
14881       # case insensitive, let's make it lowercase to improve readability.
14882       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14883       # Now convert it back to Unix-stile (cygpath)
14884       input_path=`$CYGPATH -u "$shortmode_path"`
14885       new_path="$input_path"
14886     fi
14887   fi
14888 
14889   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14890   if test "x$test_cygdrive_prefix" = x; then
14891     # As a simple fix, exclude /usr/bin since it's not a real path.
14892     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14893       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14894       # a path prefixed by /cygdrive for fixpath to work.
14895       new_path="$CYGWIN_ROOT_PATH$input_path"
14896     fi
14897   fi
14898 
14899 
14900   if test "x$path" != "x$new_path"; then
14901     OUTPUT_ROOT="$new_path"
14902     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14903 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14904   fi
14905 
14906   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14907 
14908   path="$OUTPUT_ROOT"
14909   has_colon=`$ECHO $path | $GREP ^.:`
14910   new_path="$path"
14911   if test "x$has_colon" = x; then
14912     # Not in mixed or Windows style, start by that.
14913     new_path=`cmd //c echo $path`
14914   fi
14915 
14916 
14917   input_path="$new_path"
14918   # Check if we need to convert this using DOS-style short mode. If the path
14919   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14920   # take no chances and rewrite it.
14921   # Note: m4 eats our [], so we need to use [ and ] instead.
14922   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14923   if test "x$has_forbidden_chars" != x; then
14924     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14925     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14926   fi
14927 
14928 
14929   windows_path="$new_path"
14930   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14931     unix_path=`$CYGPATH -u "$windows_path"`
14932     new_path="$unix_path"
14933   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14934     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14935     new_path="$unix_path"
14936   fi
14937 
14938   if test "x$path" != "x$new_path"; then
14939     OUTPUT_ROOT="$new_path"
14940     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14941 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14942   fi
14943 
14944   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14945   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14946 
14947   else
14948     # We're on a posix platform. Hooray! :)
14949     path="$OUTPUT_ROOT"
14950     has_space=`$ECHO "$path" | $GREP " "`
14951     if test "x$has_space" != x; then
14952       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14953 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14954       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14955     fi
14956 
14957     # Use eval to expand a potential ~
14958     eval path="$path"
14959     if test ! -f "$path" && test ! -d "$path"; then
14960       as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5
14961     fi
14962 
14963     OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`"
14964   fi
14965 
14966 
14967   SPEC=$OUTPUT_ROOT/spec.gmk
14968 
14969   CONF_NAME=$CONF_NAME
14970 
14971   OUTPUT_ROOT=$OUTPUT_ROOT
14972 
14973 
14974   # Most of the probed defines are put into config.h
14975   ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in"
14976 
14977   # The spec.gmk file contains all variables for the make system.
14978   ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in"
14979 
14980   # The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
14981   ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in"
14982 
14983   # The bootcycle-spec.gmk file contains support for boot cycle builds.
14984   ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in"
14985 
14986   # The compare.sh is used to compare the build output to other builds.
14987   ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in"
14988 
14989   # Spec.sh is currently used by compare-objects.sh
14990   ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in"
14991 
14992   # The generated Makefile knows where the spec.gmk is and where the source is.
14993   # You can run make from the OUTPUT_ROOT, or from the top-level Makefile
14994   # which will look for generated configurations
14995   ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in"
14996 
14997 
14998 
14999 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY.
15000 
15001   for ac_prog in apt-get yum port pkgutil pkgadd
15002 do
15003   # Extract the first word of "$ac_prog", so it can be a program name with args.
15004 set dummy $ac_prog; ac_word=$2
15005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15006 $as_echo_n "checking for $ac_word... " >&6; }
15007 if ${ac_cv_prog_PKGHANDLER+:} false; then :
15008   $as_echo_n "(cached) " >&6
15009 else
15010   if test -n "$PKGHANDLER"; then
15011   ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test.
15012 else
15013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15014 for as_dir in $PATH
15015 do
15016   IFS=$as_save_IFS
15017   test -z "$as_dir" && as_dir=.
15018     for ac_exec_ext in '' $ac_executable_extensions; do
15019   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15020     ac_cv_prog_PKGHANDLER="$ac_prog"
15021     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15022     break 2
15023   fi
15024 done
15025   done
15026 IFS=$as_save_IFS
15027 
15028 fi
15029 fi
15030 PKGHANDLER=$ac_cv_prog_PKGHANDLER
15031 if test -n "$PKGHANDLER"; then
15032   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5
15033 $as_echo "$PKGHANDLER" >&6; }
15034 else
15035   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15036 $as_echo "no" >&6; }
15037 fi
15038 
15039 
15040   test -n "$PKGHANDLER" && break
15041 done
15042 
15043 
15044 
15045 # Setup tools that requires more complex handling, or that is not needed by the configure script.
15046 
15047 
15048   # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky.
15049   if test "x$MAKE" != x; then
15050     # User has supplied a make, test it.
15051     if test ! -f "$MAKE"; then
15052       as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5
15053     fi
15054 
15055   MAKE_CANDIDATE=""$MAKE""
15056   DESCRIPTION="user supplied MAKE=$MAKE"
15057   if test "x$MAKE_CANDIDATE" != x; then
15058     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15059 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15060     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15061     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15062     if test "x$IS_GNU_MAKE" = x; then
15063       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15064 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15065     else
15066       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15067       if test "x$IS_MODERN_MAKE" = x; then
15068         { $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
15069 $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;}
15070       else
15071         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15072           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15073             MAKE_EXPECTED_ENV='cygwin'
15074           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15075             MAKE_EXPECTED_ENV='msys'
15076           else
15077             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15078           fi
15079           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15080           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15081         else
15082           # Not relevant for non-Windows
15083           IS_MAKE_CORRECT_ENV=true
15084         fi
15085         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15086           { $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
15087 $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;}
15088         else
15089           FOUND_MAKE=$MAKE_CANDIDATE
15090 
15091   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15092 
15093   # First separate the path from the arguments. This will split at the first
15094   # space.
15095   complete="$FOUND_MAKE"
15096   path="${complete%% *}"
15097   tmp="$complete EOL"
15098   arguments="${tmp#* }"
15099 
15100   # Input might be given as Windows format, start by converting to
15101   # unix format.
15102   new_path=`$CYGPATH -u "$path"`
15103 
15104   # Now try to locate executable using which
15105   new_path=`$WHICH "$new_path" 2> /dev/null`
15106   # bat and cmd files are not always considered executable in cygwin causing which
15107   # to not find them
15108   if test "x$new_path" = x \
15109       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15110       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15111     new_path=`$CYGPATH -u "$path"`
15112   fi
15113   if test "x$new_path" = x; then
15114     # Oops. Which didn't find the executable.
15115     # The splitting of arguments from the executable at a space might have been incorrect,
15116     # since paths with space are more likely in Windows. Give it another try with the whole
15117     # argument.
15118     path="$complete"
15119     arguments="EOL"
15120     new_path=`$CYGPATH -u "$path"`
15121     new_path=`$WHICH "$new_path" 2> /dev/null`
15122     # bat and cmd files are not always considered executable in cygwin causing which
15123     # to not find them
15124     if test "x$new_path" = x \
15125         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15126         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15127       new_path=`$CYGPATH -u "$path"`
15128     fi
15129     if test "x$new_path" = x; then
15130       # It's still not found. Now this is an unrecoverable error.
15131       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15132 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15133       has_space=`$ECHO "$complete" | $GREP " "`
15134       if test "x$has_space" != x; then
15135         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15136 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15137       fi
15138       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15139     fi
15140   fi
15141 
15142   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15143   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15144   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15145   # "foo.exe" is OK but "foo" is an error.
15146   #
15147   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15148   # It is also a way to make sure we got the proper file name for the real test later on.
15149   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15150   if test "x$test_shortpath" = x; then
15151     # Short path failed, file does not exist as specified.
15152     # Try adding .exe or .cmd
15153     if test -f "${new_path}.exe"; then
15154       input_to_shortpath="${new_path}.exe"
15155     elif test -f "${new_path}.cmd"; then
15156       input_to_shortpath="${new_path}.cmd"
15157     else
15158       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15159 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15160       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15161 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15162       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15163     fi
15164   else
15165     input_to_shortpath="$new_path"
15166   fi
15167 
15168   # Call helper function which possibly converts this using DOS-style short mode.
15169   # If so, the updated path is stored in $new_path.
15170   new_path="$input_to_shortpath"
15171 
15172   input_path="$input_to_shortpath"
15173   # Check if we need to convert this using DOS-style short mode. If the path
15174   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15175   # take no chances and rewrite it.
15176   # Note: m4 eats our [], so we need to use [ and ] instead.
15177   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15178   if test "x$has_forbidden_chars" != x; then
15179     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15180     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15181     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15182     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15183       # Going to short mode and back again did indeed matter. Since short mode is
15184       # case insensitive, let's make it lowercase to improve readability.
15185       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15186       # Now convert it back to Unix-stile (cygpath)
15187       input_path=`$CYGPATH -u "$shortmode_path"`
15188       new_path="$input_path"
15189     fi
15190   fi
15191 
15192   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15193   if test "x$test_cygdrive_prefix" = x; then
15194     # As a simple fix, exclude /usr/bin since it's not a real path.
15195     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15196       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15197       # a path prefixed by /cygdrive for fixpath to work.
15198       new_path="$CYGWIN_ROOT_PATH$input_path"
15199     fi
15200   fi
15201 
15202   # remove trailing .exe if any
15203   new_path="${new_path/%.exe/}"
15204 
15205   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15206 
15207   # First separate the path from the arguments. This will split at the first
15208   # space.
15209   complete="$FOUND_MAKE"
15210   path="${complete%% *}"
15211   tmp="$complete EOL"
15212   arguments="${tmp#* }"
15213 
15214   # Input might be given as Windows format, start by converting to
15215   # unix format.
15216   new_path="$path"
15217 
15218   windows_path="$new_path"
15219   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15220     unix_path=`$CYGPATH -u "$windows_path"`
15221     new_path="$unix_path"
15222   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15223     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15224     new_path="$unix_path"
15225   fi
15226 
15227 
15228   # Now try to locate executable using which
15229   new_path=`$WHICH "$new_path" 2> /dev/null`
15230 
15231   if test "x$new_path" = x; then
15232     # Oops. Which didn't find the executable.
15233     # The splitting of arguments from the executable at a space might have been incorrect,
15234     # since paths with space are more likely in Windows. Give it another try with the whole
15235     # argument.
15236     path="$complete"
15237     arguments="EOL"
15238     new_path="$path"
15239 
15240   windows_path="$new_path"
15241   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15242     unix_path=`$CYGPATH -u "$windows_path"`
15243     new_path="$unix_path"
15244   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15245     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15246     new_path="$unix_path"
15247   fi
15248 
15249 
15250     new_path=`$WHICH "$new_path" 2> /dev/null`
15251 
15252     if test "x$new_path" = x; then
15253       # It's still not found. Now this is an unrecoverable error.
15254       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15255 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15256       has_space=`$ECHO "$complete" | $GREP " "`
15257       if test "x$has_space" != x; then
15258         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15259 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15260       fi
15261       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15262     fi
15263   fi
15264 
15265   # Now new_path has a complete unix path to the binary
15266   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15267     # Keep paths in /bin as-is, but remove trailing .exe if any
15268     new_path="${new_path/%.exe/}"
15269     # Do not save /bin paths to all_fixpath_prefixes!
15270   else
15271     # Not in mixed or Windows style, start by that.
15272     new_path=`cmd //c echo $new_path`
15273 
15274   input_path="$new_path"
15275   # Check if we need to convert this using DOS-style short mode. If the path
15276   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15277   # take no chances and rewrite it.
15278   # Note: m4 eats our [], so we need to use [ and ] instead.
15279   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15280   if test "x$has_forbidden_chars" != x; then
15281     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15282     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15283   fi
15284 
15285     # Output is in $new_path
15286 
15287   windows_path="$new_path"
15288   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15289     unix_path=`$CYGPATH -u "$windows_path"`
15290     new_path="$unix_path"
15291   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15292     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15293     new_path="$unix_path"
15294   fi
15295 
15296     # remove trailing .exe if any
15297     new_path="${new_path/%.exe/}"
15298 
15299     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15300     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15301   fi
15302 
15303   else
15304     # We're on a posix platform. Hooray! :)
15305     # First separate the path from the arguments. This will split at the first
15306     # space.
15307     complete="$FOUND_MAKE"
15308     path="${complete%% *}"
15309     tmp="$complete EOL"
15310     arguments="${tmp#* }"
15311 
15312     # Cannot rely on the command "which" here since it doesn't always work.
15313     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15314     if test -z "$is_absolute_path"; then
15315       # Path to executable is not absolute. Find it.
15316       IFS_save="$IFS"
15317       IFS=:
15318       for p in $PATH; do
15319         if test -f "$p/$path" && test -x "$p/$path"; then
15320           new_path="$p/$path"
15321           break
15322         fi
15323       done
15324       IFS="$IFS_save"
15325     else
15326       # This is an absolute path, we can use it without further modifications.
15327       new_path="$path"
15328     fi
15329 
15330     if test "x$new_path" = x; then
15331       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15332 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15333       has_space=`$ECHO "$complete" | $GREP " "`
15334       if test "x$has_space" != x; then
15335         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15336 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15337       fi
15338       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15339     fi
15340   fi
15341 
15342   # Now join together the path and the arguments once again
15343   if test "x$arguments" != xEOL; then
15344     new_complete="$new_path ${arguments% *}"
15345   else
15346     new_complete="$new_path"
15347   fi
15348 
15349   if test "x$complete" != "x$new_complete"; then
15350     FOUND_MAKE="$new_complete"
15351     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15352 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15353   fi
15354 
15355         fi
15356       fi
15357     fi
15358   fi
15359 
15360     if test "x$FOUND_MAKE" = x; then
15361       as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5
15362     fi
15363   else
15364     # Try our hardest to locate a correct version of GNU make
15365     for ac_prog in gmake
15366 do
15367   # Extract the first word of "$ac_prog", so it can be a program name with args.
15368 set dummy $ac_prog; ac_word=$2
15369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15370 $as_echo_n "checking for $ac_word... " >&6; }
15371 if ${ac_cv_path_CHECK_GMAKE+:} false; then :
15372   $as_echo_n "(cached) " >&6
15373 else
15374   case $CHECK_GMAKE in
15375   [\\/]* | ?:[\\/]*)
15376   ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path.
15377   ;;
15378   *)
15379   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15380 for as_dir in $PATH
15381 do
15382   IFS=$as_save_IFS
15383   test -z "$as_dir" && as_dir=.
15384     for ac_exec_ext in '' $ac_executable_extensions; do
15385   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15386     ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15387     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15388     break 2
15389   fi
15390 done
15391   done
15392 IFS=$as_save_IFS
15393 
15394   ;;
15395 esac
15396 fi
15397 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE
15398 if test -n "$CHECK_GMAKE"; then
15399   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5
15400 $as_echo "$CHECK_GMAKE" >&6; }
15401 else
15402   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15403 $as_echo "no" >&6; }
15404 fi
15405 
15406 
15407   test -n "$CHECK_GMAKE" && break
15408 done
15409 
15410 
15411   MAKE_CANDIDATE=""$CHECK_GMAKE""
15412   DESCRIPTION="gmake in PATH"
15413   if test "x$MAKE_CANDIDATE" != x; then
15414     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15415 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15416     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15417     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15418     if test "x$IS_GNU_MAKE" = x; then
15419       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15420 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15421     else
15422       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15423       if test "x$IS_MODERN_MAKE" = x; then
15424         { $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
15425 $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;}
15426       else
15427         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15428           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15429             MAKE_EXPECTED_ENV='cygwin'
15430           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15431             MAKE_EXPECTED_ENV='msys'
15432           else
15433             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15434           fi
15435           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15436           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15437         else
15438           # Not relevant for non-Windows
15439           IS_MAKE_CORRECT_ENV=true
15440         fi
15441         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15442           { $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
15443 $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;}
15444         else
15445           FOUND_MAKE=$MAKE_CANDIDATE
15446 
15447   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15448 
15449   # First separate the path from the arguments. This will split at the first
15450   # space.
15451   complete="$FOUND_MAKE"
15452   path="${complete%% *}"
15453   tmp="$complete EOL"
15454   arguments="${tmp#* }"
15455 
15456   # Input might be given as Windows format, start by converting to
15457   # unix format.
15458   new_path=`$CYGPATH -u "$path"`
15459 
15460   # Now try to locate executable using which
15461   new_path=`$WHICH "$new_path" 2> /dev/null`
15462   # bat and cmd files are not always considered executable in cygwin causing which
15463   # to not find them
15464   if test "x$new_path" = x \
15465       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15466       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15467     new_path=`$CYGPATH -u "$path"`
15468   fi
15469   if test "x$new_path" = x; then
15470     # Oops. Which didn't find the executable.
15471     # The splitting of arguments from the executable at a space might have been incorrect,
15472     # since paths with space are more likely in Windows. Give it another try with the whole
15473     # argument.
15474     path="$complete"
15475     arguments="EOL"
15476     new_path=`$CYGPATH -u "$path"`
15477     new_path=`$WHICH "$new_path" 2> /dev/null`
15478     # bat and cmd files are not always considered executable in cygwin causing which
15479     # to not find them
15480     if test "x$new_path" = x \
15481         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15482         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15483       new_path=`$CYGPATH -u "$path"`
15484     fi
15485     if test "x$new_path" = x; then
15486       # It's still not found. Now this is an unrecoverable error.
15487       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15488 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15489       has_space=`$ECHO "$complete" | $GREP " "`
15490       if test "x$has_space" != x; then
15491         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15492 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15493       fi
15494       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15495     fi
15496   fi
15497 
15498   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15499   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15500   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15501   # "foo.exe" is OK but "foo" is an error.
15502   #
15503   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15504   # It is also a way to make sure we got the proper file name for the real test later on.
15505   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15506   if test "x$test_shortpath" = x; then
15507     # Short path failed, file does not exist as specified.
15508     # Try adding .exe or .cmd
15509     if test -f "${new_path}.exe"; then
15510       input_to_shortpath="${new_path}.exe"
15511     elif test -f "${new_path}.cmd"; then
15512       input_to_shortpath="${new_path}.cmd"
15513     else
15514       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15515 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15516       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15517 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15518       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15519     fi
15520   else
15521     input_to_shortpath="$new_path"
15522   fi
15523 
15524   # Call helper function which possibly converts this using DOS-style short mode.
15525   # If so, the updated path is stored in $new_path.
15526   new_path="$input_to_shortpath"
15527 
15528   input_path="$input_to_shortpath"
15529   # Check if we need to convert this using DOS-style short mode. If the path
15530   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15531   # take no chances and rewrite it.
15532   # Note: m4 eats our [], so we need to use [ and ] instead.
15533   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15534   if test "x$has_forbidden_chars" != x; then
15535     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15536     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15537     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15538     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15539       # Going to short mode and back again did indeed matter. Since short mode is
15540       # case insensitive, let's make it lowercase to improve readability.
15541       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15542       # Now convert it back to Unix-stile (cygpath)
15543       input_path=`$CYGPATH -u "$shortmode_path"`
15544       new_path="$input_path"
15545     fi
15546   fi
15547 
15548   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15549   if test "x$test_cygdrive_prefix" = x; then
15550     # As a simple fix, exclude /usr/bin since it's not a real path.
15551     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15552       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15553       # a path prefixed by /cygdrive for fixpath to work.
15554       new_path="$CYGWIN_ROOT_PATH$input_path"
15555     fi
15556   fi
15557 
15558   # remove trailing .exe if any
15559   new_path="${new_path/%.exe/}"
15560 
15561   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15562 
15563   # First separate the path from the arguments. This will split at the first
15564   # space.
15565   complete="$FOUND_MAKE"
15566   path="${complete%% *}"
15567   tmp="$complete EOL"
15568   arguments="${tmp#* }"
15569 
15570   # Input might be given as Windows format, start by converting to
15571   # unix format.
15572   new_path="$path"
15573 
15574   windows_path="$new_path"
15575   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15576     unix_path=`$CYGPATH -u "$windows_path"`
15577     new_path="$unix_path"
15578   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15579     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15580     new_path="$unix_path"
15581   fi
15582 
15583 
15584   # Now try to locate executable using which
15585   new_path=`$WHICH "$new_path" 2> /dev/null`
15586 
15587   if test "x$new_path" = x; then
15588     # Oops. Which didn't find the executable.
15589     # The splitting of arguments from the executable at a space might have been incorrect,
15590     # since paths with space are more likely in Windows. Give it another try with the whole
15591     # argument.
15592     path="$complete"
15593     arguments="EOL"
15594     new_path="$path"
15595 
15596   windows_path="$new_path"
15597   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15598     unix_path=`$CYGPATH -u "$windows_path"`
15599     new_path="$unix_path"
15600   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15601     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15602     new_path="$unix_path"
15603   fi
15604 
15605 
15606     new_path=`$WHICH "$new_path" 2> /dev/null`
15607 
15608     if test "x$new_path" = x; then
15609       # It's still not found. Now this is an unrecoverable error.
15610       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15611 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15612       has_space=`$ECHO "$complete" | $GREP " "`
15613       if test "x$has_space" != x; then
15614         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15615 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15616       fi
15617       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15618     fi
15619   fi
15620 
15621   # Now new_path has a complete unix path to the binary
15622   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15623     # Keep paths in /bin as-is, but remove trailing .exe if any
15624     new_path="${new_path/%.exe/}"
15625     # Do not save /bin paths to all_fixpath_prefixes!
15626   else
15627     # Not in mixed or Windows style, start by that.
15628     new_path=`cmd //c echo $new_path`
15629 
15630   input_path="$new_path"
15631   # Check if we need to convert this using DOS-style short mode. If the path
15632   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15633   # take no chances and rewrite it.
15634   # Note: m4 eats our [], so we need to use [ and ] instead.
15635   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15636   if test "x$has_forbidden_chars" != x; then
15637     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15638     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15639   fi
15640 
15641     # Output is in $new_path
15642 
15643   windows_path="$new_path"
15644   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15645     unix_path=`$CYGPATH -u "$windows_path"`
15646     new_path="$unix_path"
15647   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15648     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15649     new_path="$unix_path"
15650   fi
15651 
15652     # remove trailing .exe if any
15653     new_path="${new_path/%.exe/}"
15654 
15655     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15656     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15657   fi
15658 
15659   else
15660     # We're on a posix platform. Hooray! :)
15661     # First separate the path from the arguments. This will split at the first
15662     # space.
15663     complete="$FOUND_MAKE"
15664     path="${complete%% *}"
15665     tmp="$complete EOL"
15666     arguments="${tmp#* }"
15667 
15668     # Cannot rely on the command "which" here since it doesn't always work.
15669     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15670     if test -z "$is_absolute_path"; then
15671       # Path to executable is not absolute. Find it.
15672       IFS_save="$IFS"
15673       IFS=:
15674       for p in $PATH; do
15675         if test -f "$p/$path" && test -x "$p/$path"; then
15676           new_path="$p/$path"
15677           break
15678         fi
15679       done
15680       IFS="$IFS_save"
15681     else
15682       # This is an absolute path, we can use it without further modifications.
15683       new_path="$path"
15684     fi
15685 
15686     if test "x$new_path" = x; then
15687       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15688 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15689       has_space=`$ECHO "$complete" | $GREP " "`
15690       if test "x$has_space" != x; then
15691         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15692 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15693       fi
15694       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15695     fi
15696   fi
15697 
15698   # Now join together the path and the arguments once again
15699   if test "x$arguments" != xEOL; then
15700     new_complete="$new_path ${arguments% *}"
15701   else
15702     new_complete="$new_path"
15703   fi
15704 
15705   if test "x$complete" != "x$new_complete"; then
15706     FOUND_MAKE="$new_complete"
15707     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15708 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15709   fi
15710 
15711         fi
15712       fi
15713     fi
15714   fi
15715 
15716 
15717     if test "x$FOUND_MAKE" = x; then
15718       for ac_prog in make
15719 do
15720   # Extract the first word of "$ac_prog", so it can be a program name with args.
15721 set dummy $ac_prog; ac_word=$2
15722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15723 $as_echo_n "checking for $ac_word... " >&6; }
15724 if ${ac_cv_path_CHECK_MAKE+:} false; then :
15725   $as_echo_n "(cached) " >&6
15726 else
15727   case $CHECK_MAKE in
15728   [\\/]* | ?:[\\/]*)
15729   ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path.
15730   ;;
15731   *)
15732   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15733 for as_dir in $PATH
15734 do
15735   IFS=$as_save_IFS
15736   test -z "$as_dir" && as_dir=.
15737     for ac_exec_ext in '' $ac_executable_extensions; do
15738   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15739     ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext"
15740     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15741     break 2
15742   fi
15743 done
15744   done
15745 IFS=$as_save_IFS
15746 
15747   ;;
15748 esac
15749 fi
15750 CHECK_MAKE=$ac_cv_path_CHECK_MAKE
15751 if test -n "$CHECK_MAKE"; then
15752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5
15753 $as_echo "$CHECK_MAKE" >&6; }
15754 else
15755   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15756 $as_echo "no" >&6; }
15757 fi
15758 
15759 
15760   test -n "$CHECK_MAKE" && break
15761 done
15762 
15763 
15764   MAKE_CANDIDATE=""$CHECK_MAKE""
15765   DESCRIPTION="make in PATH"
15766   if test "x$MAKE_CANDIDATE" != x; then
15767     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15768 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15769     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15770     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15771     if test "x$IS_GNU_MAKE" = x; then
15772       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15773 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15774     else
15775       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15776       if test "x$IS_MODERN_MAKE" = x; then
15777         { $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
15778 $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;}
15779       else
15780         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15781           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15782             MAKE_EXPECTED_ENV='cygwin'
15783           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15784             MAKE_EXPECTED_ENV='msys'
15785           else
15786             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15787           fi
15788           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15789           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15790         else
15791           # Not relevant for non-Windows
15792           IS_MAKE_CORRECT_ENV=true
15793         fi
15794         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15795           { $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
15796 $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;}
15797         else
15798           FOUND_MAKE=$MAKE_CANDIDATE
15799 
15800   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15801 
15802   # First separate the path from the arguments. This will split at the first
15803   # space.
15804   complete="$FOUND_MAKE"
15805   path="${complete%% *}"
15806   tmp="$complete EOL"
15807   arguments="${tmp#* }"
15808 
15809   # Input might be given as Windows format, start by converting to
15810   # unix format.
15811   new_path=`$CYGPATH -u "$path"`
15812 
15813   # Now try to locate executable using which
15814   new_path=`$WHICH "$new_path" 2> /dev/null`
15815   # bat and cmd files are not always considered executable in cygwin causing which
15816   # to not find them
15817   if test "x$new_path" = x \
15818       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15819       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15820     new_path=`$CYGPATH -u "$path"`
15821   fi
15822   if test "x$new_path" = x; then
15823     # Oops. Which didn't find the executable.
15824     # The splitting of arguments from the executable at a space might have been incorrect,
15825     # since paths with space are more likely in Windows. Give it another try with the whole
15826     # argument.
15827     path="$complete"
15828     arguments="EOL"
15829     new_path=`$CYGPATH -u "$path"`
15830     new_path=`$WHICH "$new_path" 2> /dev/null`
15831     # bat and cmd files are not always considered executable in cygwin causing which
15832     # to not find them
15833     if test "x$new_path" = x \
15834         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15835         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15836       new_path=`$CYGPATH -u "$path"`
15837     fi
15838     if test "x$new_path" = x; then
15839       # It's still not found. Now this is an unrecoverable error.
15840       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15841 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15842       has_space=`$ECHO "$complete" | $GREP " "`
15843       if test "x$has_space" != x; then
15844         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15845 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15846       fi
15847       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15848     fi
15849   fi
15850 
15851   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15852   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15853   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15854   # "foo.exe" is OK but "foo" is an error.
15855   #
15856   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15857   # It is also a way to make sure we got the proper file name for the real test later on.
15858   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15859   if test "x$test_shortpath" = x; then
15860     # Short path failed, file does not exist as specified.
15861     # Try adding .exe or .cmd
15862     if test -f "${new_path}.exe"; then
15863       input_to_shortpath="${new_path}.exe"
15864     elif test -f "${new_path}.cmd"; then
15865       input_to_shortpath="${new_path}.cmd"
15866     else
15867       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15868 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15869       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15870 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15871       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15872     fi
15873   else
15874     input_to_shortpath="$new_path"
15875   fi
15876 
15877   # Call helper function which possibly converts this using DOS-style short mode.
15878   # If so, the updated path is stored in $new_path.
15879   new_path="$input_to_shortpath"
15880 
15881   input_path="$input_to_shortpath"
15882   # Check if we need to convert this using DOS-style short mode. If the path
15883   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15884   # take no chances and rewrite it.
15885   # Note: m4 eats our [], so we need to use [ and ] instead.
15886   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15887   if test "x$has_forbidden_chars" != x; then
15888     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15889     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15890     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15891     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15892       # Going to short mode and back again did indeed matter. Since short mode is
15893       # case insensitive, let's make it lowercase to improve readability.
15894       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15895       # Now convert it back to Unix-stile (cygpath)
15896       input_path=`$CYGPATH -u "$shortmode_path"`
15897       new_path="$input_path"
15898     fi
15899   fi
15900 
15901   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15902   if test "x$test_cygdrive_prefix" = x; then
15903     # As a simple fix, exclude /usr/bin since it's not a real path.
15904     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15905       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15906       # a path prefixed by /cygdrive for fixpath to work.
15907       new_path="$CYGWIN_ROOT_PATH$input_path"
15908     fi
15909   fi
15910 
15911   # remove trailing .exe if any
15912   new_path="${new_path/%.exe/}"
15913 
15914   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15915 
15916   # First separate the path from the arguments. This will split at the first
15917   # space.
15918   complete="$FOUND_MAKE"
15919   path="${complete%% *}"
15920   tmp="$complete EOL"
15921   arguments="${tmp#* }"
15922 
15923   # Input might be given as Windows format, start by converting to
15924   # unix format.
15925   new_path="$path"
15926 
15927   windows_path="$new_path"
15928   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15929     unix_path=`$CYGPATH -u "$windows_path"`
15930     new_path="$unix_path"
15931   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15932     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15933     new_path="$unix_path"
15934   fi
15935 
15936 
15937   # Now try to locate executable using which
15938   new_path=`$WHICH "$new_path" 2> /dev/null`
15939 
15940   if test "x$new_path" = x; then
15941     # Oops. Which didn't find the executable.
15942     # The splitting of arguments from the executable at a space might have been incorrect,
15943     # since paths with space are more likely in Windows. Give it another try with the whole
15944     # argument.
15945     path="$complete"
15946     arguments="EOL"
15947     new_path="$path"
15948 
15949   windows_path="$new_path"
15950   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15951     unix_path=`$CYGPATH -u "$windows_path"`
15952     new_path="$unix_path"
15953   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15954     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15955     new_path="$unix_path"
15956   fi
15957 
15958 
15959     new_path=`$WHICH "$new_path" 2> /dev/null`
15960 
15961     if test "x$new_path" = x; then
15962       # It's still not found. Now this is an unrecoverable error.
15963       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15964 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15965       has_space=`$ECHO "$complete" | $GREP " "`
15966       if test "x$has_space" != x; then
15967         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15968 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15969       fi
15970       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15971     fi
15972   fi
15973 
15974   # Now new_path has a complete unix path to the binary
15975   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15976     # Keep paths in /bin as-is, but remove trailing .exe if any
15977     new_path="${new_path/%.exe/}"
15978     # Do not save /bin paths to all_fixpath_prefixes!
15979   else
15980     # Not in mixed or Windows style, start by that.
15981     new_path=`cmd //c echo $new_path`
15982 
15983   input_path="$new_path"
15984   # Check if we need to convert this using DOS-style short mode. If the path
15985   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15986   # take no chances and rewrite it.
15987   # Note: m4 eats our [], so we need to use [ and ] instead.
15988   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15989   if test "x$has_forbidden_chars" != x; then
15990     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15991     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15992   fi
15993 
15994     # Output is in $new_path
15995 
15996   windows_path="$new_path"
15997   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15998     unix_path=`$CYGPATH -u "$windows_path"`
15999     new_path="$unix_path"
16000   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16001     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16002     new_path="$unix_path"
16003   fi
16004 
16005     # remove trailing .exe if any
16006     new_path="${new_path/%.exe/}"
16007 
16008     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16009     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16010   fi
16011 
16012   else
16013     # We're on a posix platform. Hooray! :)
16014     # First separate the path from the arguments. This will split at the first
16015     # space.
16016     complete="$FOUND_MAKE"
16017     path="${complete%% *}"
16018     tmp="$complete EOL"
16019     arguments="${tmp#* }"
16020 
16021     # Cannot rely on the command "which" here since it doesn't always work.
16022     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16023     if test -z "$is_absolute_path"; then
16024       # Path to executable is not absolute. Find it.
16025       IFS_save="$IFS"
16026       IFS=:
16027       for p in $PATH; do
16028         if test -f "$p/$path" && test -x "$p/$path"; then
16029           new_path="$p/$path"
16030           break
16031         fi
16032       done
16033       IFS="$IFS_save"
16034     else
16035       # This is an absolute path, we can use it without further modifications.
16036       new_path="$path"
16037     fi
16038 
16039     if test "x$new_path" = x; then
16040       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16041 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16042       has_space=`$ECHO "$complete" | $GREP " "`
16043       if test "x$has_space" != x; then
16044         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16045 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16046       fi
16047       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16048     fi
16049   fi
16050 
16051   # Now join together the path and the arguments once again
16052   if test "x$arguments" != xEOL; then
16053     new_complete="$new_path ${arguments% *}"
16054   else
16055     new_complete="$new_path"
16056   fi
16057 
16058   if test "x$complete" != "x$new_complete"; then
16059     FOUND_MAKE="$new_complete"
16060     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16061 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16062   fi
16063 
16064         fi
16065       fi
16066     fi
16067   fi
16068 
16069     fi
16070 
16071     if test "x$FOUND_MAKE" = x; then
16072       if test "x$TOOLS_DIR" != x; then
16073         # We have a tools-dir, check that as well before giving up.
16074         OLD_PATH=$PATH
16075         PATH=$TOOLS_DIR:$PATH
16076         for ac_prog in gmake
16077 do
16078   # Extract the first word of "$ac_prog", so it can be a program name with args.
16079 set dummy $ac_prog; ac_word=$2
16080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16081 $as_echo_n "checking for $ac_word... " >&6; }
16082 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16083   $as_echo_n "(cached) " >&6
16084 else
16085   case $CHECK_TOOLSDIR_GMAKE in
16086   [\\/]* | ?:[\\/]*)
16087   ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16088   ;;
16089   *)
16090   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16091 for as_dir in $PATH
16092 do
16093   IFS=$as_save_IFS
16094   test -z "$as_dir" && as_dir=.
16095     for ac_exec_ext in '' $ac_executable_extensions; do
16096   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16097     ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext"
16098     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16099     break 2
16100   fi
16101 done
16102   done
16103 IFS=$as_save_IFS
16104 
16105   ;;
16106 esac
16107 fi
16108 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE
16109 if test -n "$CHECK_TOOLSDIR_GMAKE"; then
16110   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5
16111 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; }
16112 else
16113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16114 $as_echo "no" >&6; }
16115 fi
16116 
16117 
16118   test -n "$CHECK_TOOLSDIR_GMAKE" && break
16119 done
16120 
16121 
16122   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE""
16123   DESCRIPTION="gmake in tools-dir"
16124   if test "x$MAKE_CANDIDATE" != x; then
16125     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16126 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16127     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16128     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16129     if test "x$IS_GNU_MAKE" = x; then
16130       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16131 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16132     else
16133       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16134       if test "x$IS_MODERN_MAKE" = x; then
16135         { $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
16136 $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;}
16137       else
16138         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16139           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16140             MAKE_EXPECTED_ENV='cygwin'
16141           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16142             MAKE_EXPECTED_ENV='msys'
16143           else
16144             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16145           fi
16146           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16147           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16148         else
16149           # Not relevant for non-Windows
16150           IS_MAKE_CORRECT_ENV=true
16151         fi
16152         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16153           { $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
16154 $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;}
16155         else
16156           FOUND_MAKE=$MAKE_CANDIDATE
16157 
16158   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16159 
16160   # First separate the path from the arguments. This will split at the first
16161   # space.
16162   complete="$FOUND_MAKE"
16163   path="${complete%% *}"
16164   tmp="$complete EOL"
16165   arguments="${tmp#* }"
16166 
16167   # Input might be given as Windows format, start by converting to
16168   # unix format.
16169   new_path=`$CYGPATH -u "$path"`
16170 
16171   # Now try to locate executable using which
16172   new_path=`$WHICH "$new_path" 2> /dev/null`
16173   # bat and cmd files are not always considered executable in cygwin causing which
16174   # to not find them
16175   if test "x$new_path" = x \
16176       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16177       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16178     new_path=`$CYGPATH -u "$path"`
16179   fi
16180   if test "x$new_path" = x; then
16181     # Oops. Which didn't find the executable.
16182     # The splitting of arguments from the executable at a space might have been incorrect,
16183     # since paths with space are more likely in Windows. Give it another try with the whole
16184     # argument.
16185     path="$complete"
16186     arguments="EOL"
16187     new_path=`$CYGPATH -u "$path"`
16188     new_path=`$WHICH "$new_path" 2> /dev/null`
16189     # bat and cmd files are not always considered executable in cygwin causing which
16190     # to not find them
16191     if test "x$new_path" = x \
16192         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16193         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16194       new_path=`$CYGPATH -u "$path"`
16195     fi
16196     if test "x$new_path" = x; then
16197       # It's still not found. Now this is an unrecoverable error.
16198       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16199 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16200       has_space=`$ECHO "$complete" | $GREP " "`
16201       if test "x$has_space" != x; then
16202         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16203 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16204       fi
16205       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16206     fi
16207   fi
16208 
16209   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16210   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16211   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16212   # "foo.exe" is OK but "foo" is an error.
16213   #
16214   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16215   # It is also a way to make sure we got the proper file name for the real test later on.
16216   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16217   if test "x$test_shortpath" = x; then
16218     # Short path failed, file does not exist as specified.
16219     # Try adding .exe or .cmd
16220     if test -f "${new_path}.exe"; then
16221       input_to_shortpath="${new_path}.exe"
16222     elif test -f "${new_path}.cmd"; then
16223       input_to_shortpath="${new_path}.cmd"
16224     else
16225       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16226 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16227       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16228 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16229       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16230     fi
16231   else
16232     input_to_shortpath="$new_path"
16233   fi
16234 
16235   # Call helper function which possibly converts this using DOS-style short mode.
16236   # If so, the updated path is stored in $new_path.
16237   new_path="$input_to_shortpath"
16238 
16239   input_path="$input_to_shortpath"
16240   # Check if we need to convert this using DOS-style short mode. If the path
16241   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16242   # take no chances and rewrite it.
16243   # Note: m4 eats our [], so we need to use [ and ] instead.
16244   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16245   if test "x$has_forbidden_chars" != x; then
16246     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16247     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16248     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16249     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16250       # Going to short mode and back again did indeed matter. Since short mode is
16251       # case insensitive, let's make it lowercase to improve readability.
16252       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16253       # Now convert it back to Unix-stile (cygpath)
16254       input_path=`$CYGPATH -u "$shortmode_path"`
16255       new_path="$input_path"
16256     fi
16257   fi
16258 
16259   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16260   if test "x$test_cygdrive_prefix" = x; then
16261     # As a simple fix, exclude /usr/bin since it's not a real path.
16262     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16263       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16264       # a path prefixed by /cygdrive for fixpath to work.
16265       new_path="$CYGWIN_ROOT_PATH$input_path"
16266     fi
16267   fi
16268 
16269   # remove trailing .exe if any
16270   new_path="${new_path/%.exe/}"
16271 
16272   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16273 
16274   # First separate the path from the arguments. This will split at the first
16275   # space.
16276   complete="$FOUND_MAKE"
16277   path="${complete%% *}"
16278   tmp="$complete EOL"
16279   arguments="${tmp#* }"
16280 
16281   # Input might be given as Windows format, start by converting to
16282   # unix format.
16283   new_path="$path"
16284 
16285   windows_path="$new_path"
16286   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16287     unix_path=`$CYGPATH -u "$windows_path"`
16288     new_path="$unix_path"
16289   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16290     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16291     new_path="$unix_path"
16292   fi
16293 
16294 
16295   # Now try to locate executable using which
16296   new_path=`$WHICH "$new_path" 2> /dev/null`
16297 
16298   if test "x$new_path" = x; then
16299     # Oops. Which didn't find the executable.
16300     # The splitting of arguments from the executable at a space might have been incorrect,
16301     # since paths with space are more likely in Windows. Give it another try with the whole
16302     # argument.
16303     path="$complete"
16304     arguments="EOL"
16305     new_path="$path"
16306 
16307   windows_path="$new_path"
16308   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16309     unix_path=`$CYGPATH -u "$windows_path"`
16310     new_path="$unix_path"
16311   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16312     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16313     new_path="$unix_path"
16314   fi
16315 
16316 
16317     new_path=`$WHICH "$new_path" 2> /dev/null`
16318 
16319     if test "x$new_path" = x; then
16320       # It's still not found. Now this is an unrecoverable error.
16321       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16322 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16323       has_space=`$ECHO "$complete" | $GREP " "`
16324       if test "x$has_space" != x; then
16325         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16326 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16327       fi
16328       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16329     fi
16330   fi
16331 
16332   # Now new_path has a complete unix path to the binary
16333   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16334     # Keep paths in /bin as-is, but remove trailing .exe if any
16335     new_path="${new_path/%.exe/}"
16336     # Do not save /bin paths to all_fixpath_prefixes!
16337   else
16338     # Not in mixed or Windows style, start by that.
16339     new_path=`cmd //c echo $new_path`
16340 
16341   input_path="$new_path"
16342   # Check if we need to convert this using DOS-style short mode. If the path
16343   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16344   # take no chances and rewrite it.
16345   # Note: m4 eats our [], so we need to use [ and ] instead.
16346   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16347   if test "x$has_forbidden_chars" != x; then
16348     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16349     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16350   fi
16351 
16352     # Output is in $new_path
16353 
16354   windows_path="$new_path"
16355   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16356     unix_path=`$CYGPATH -u "$windows_path"`
16357     new_path="$unix_path"
16358   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16359     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16360     new_path="$unix_path"
16361   fi
16362 
16363     # remove trailing .exe if any
16364     new_path="${new_path/%.exe/}"
16365 
16366     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16367     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16368   fi
16369 
16370   else
16371     # We're on a posix platform. Hooray! :)
16372     # First separate the path from the arguments. This will split at the first
16373     # space.
16374     complete="$FOUND_MAKE"
16375     path="${complete%% *}"
16376     tmp="$complete EOL"
16377     arguments="${tmp#* }"
16378 
16379     # Cannot rely on the command "which" here since it doesn't always work.
16380     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16381     if test -z "$is_absolute_path"; then
16382       # Path to executable is not absolute. Find it.
16383       IFS_save="$IFS"
16384       IFS=:
16385       for p in $PATH; do
16386         if test -f "$p/$path" && test -x "$p/$path"; then
16387           new_path="$p/$path"
16388           break
16389         fi
16390       done
16391       IFS="$IFS_save"
16392     else
16393       # This is an absolute path, we can use it without further modifications.
16394       new_path="$path"
16395     fi
16396 
16397     if test "x$new_path" = x; then
16398       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16399 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16400       has_space=`$ECHO "$complete" | $GREP " "`
16401       if test "x$has_space" != x; then
16402         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16403 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16404       fi
16405       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16406     fi
16407   fi
16408 
16409   # Now join together the path and the arguments once again
16410   if test "x$arguments" != xEOL; then
16411     new_complete="$new_path ${arguments% *}"
16412   else
16413     new_complete="$new_path"
16414   fi
16415 
16416   if test "x$complete" != "x$new_complete"; then
16417     FOUND_MAKE="$new_complete"
16418     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16419 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16420   fi
16421 
16422         fi
16423       fi
16424     fi
16425   fi
16426 
16427         if test "x$FOUND_MAKE" = x; then
16428           for ac_prog in make
16429 do
16430   # Extract the first word of "$ac_prog", so it can be a program name with args.
16431 set dummy $ac_prog; ac_word=$2
16432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16433 $as_echo_n "checking for $ac_word... " >&6; }
16434 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then :
16435   $as_echo_n "(cached) " >&6
16436 else
16437   case $CHECK_TOOLSDIR_MAKE in
16438   [\\/]* | ?:[\\/]*)
16439   ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path.
16440   ;;
16441   *)
16442   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16443 for as_dir in $PATH
16444 do
16445   IFS=$as_save_IFS
16446   test -z "$as_dir" && as_dir=.
16447     for ac_exec_ext in '' $ac_executable_extensions; do
16448   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16449     ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext"
16450     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16451     break 2
16452   fi
16453 done
16454   done
16455 IFS=$as_save_IFS
16456 
16457   ;;
16458 esac
16459 fi
16460 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE
16461 if test -n "$CHECK_TOOLSDIR_MAKE"; then
16462   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5
16463 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; }
16464 else
16465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16466 $as_echo "no" >&6; }
16467 fi
16468 
16469 
16470   test -n "$CHECK_TOOLSDIR_MAKE" && break
16471 done
16472 
16473 
16474   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE""
16475   DESCRIPTION="make in tools-dir"
16476   if test "x$MAKE_CANDIDATE" != x; then
16477     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16478 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16479     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16480     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16481     if test "x$IS_GNU_MAKE" = x; then
16482       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16483 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16484     else
16485       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16486       if test "x$IS_MODERN_MAKE" = x; then
16487         { $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
16488 $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;}
16489       else
16490         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16491           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16492             MAKE_EXPECTED_ENV='cygwin'
16493           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16494             MAKE_EXPECTED_ENV='msys'
16495           else
16496             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16497           fi
16498           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16499           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16500         else
16501           # Not relevant for non-Windows
16502           IS_MAKE_CORRECT_ENV=true
16503         fi
16504         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16505           { $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
16506 $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;}
16507         else
16508           FOUND_MAKE=$MAKE_CANDIDATE
16509 
16510   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16511 
16512   # First separate the path from the arguments. This will split at the first
16513   # space.
16514   complete="$FOUND_MAKE"
16515   path="${complete%% *}"
16516   tmp="$complete EOL"
16517   arguments="${tmp#* }"
16518 
16519   # Input might be given as Windows format, start by converting to
16520   # unix format.
16521   new_path=`$CYGPATH -u "$path"`
16522 
16523   # Now try to locate executable using which
16524   new_path=`$WHICH "$new_path" 2> /dev/null`
16525   # bat and cmd files are not always considered executable in cygwin causing which
16526   # to not find them
16527   if test "x$new_path" = x \
16528       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16529       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16530     new_path=`$CYGPATH -u "$path"`
16531   fi
16532   if test "x$new_path" = x; then
16533     # Oops. Which didn't find the executable.
16534     # The splitting of arguments from the executable at a space might have been incorrect,
16535     # since paths with space are more likely in Windows. Give it another try with the whole
16536     # argument.
16537     path="$complete"
16538     arguments="EOL"
16539     new_path=`$CYGPATH -u "$path"`
16540     new_path=`$WHICH "$new_path" 2> /dev/null`
16541     # bat and cmd files are not always considered executable in cygwin causing which
16542     # to not find them
16543     if test "x$new_path" = x \
16544         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16545         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16546       new_path=`$CYGPATH -u "$path"`
16547     fi
16548     if test "x$new_path" = x; then
16549       # It's still not found. Now this is an unrecoverable error.
16550       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16551 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16552       has_space=`$ECHO "$complete" | $GREP " "`
16553       if test "x$has_space" != x; then
16554         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16555 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16556       fi
16557       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16558     fi
16559   fi
16560 
16561   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16562   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16563   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16564   # "foo.exe" is OK but "foo" is an error.
16565   #
16566   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16567   # It is also a way to make sure we got the proper file name for the real test later on.
16568   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16569   if test "x$test_shortpath" = x; then
16570     # Short path failed, file does not exist as specified.
16571     # Try adding .exe or .cmd
16572     if test -f "${new_path}.exe"; then
16573       input_to_shortpath="${new_path}.exe"
16574     elif test -f "${new_path}.cmd"; then
16575       input_to_shortpath="${new_path}.cmd"
16576     else
16577       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16578 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16579       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16580 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16581       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16582     fi
16583   else
16584     input_to_shortpath="$new_path"
16585   fi
16586 
16587   # Call helper function which possibly converts this using DOS-style short mode.
16588   # If so, the updated path is stored in $new_path.
16589   new_path="$input_to_shortpath"
16590 
16591   input_path="$input_to_shortpath"
16592   # Check if we need to convert this using DOS-style short mode. If the path
16593   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16594   # take no chances and rewrite it.
16595   # Note: m4 eats our [], so we need to use [ and ] instead.
16596   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16597   if test "x$has_forbidden_chars" != x; then
16598     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16599     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16600     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16601     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16602       # Going to short mode and back again did indeed matter. Since short mode is
16603       # case insensitive, let's make it lowercase to improve readability.
16604       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16605       # Now convert it back to Unix-stile (cygpath)
16606       input_path=`$CYGPATH -u "$shortmode_path"`
16607       new_path="$input_path"
16608     fi
16609   fi
16610 
16611   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16612   if test "x$test_cygdrive_prefix" = x; then
16613     # As a simple fix, exclude /usr/bin since it's not a real path.
16614     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16615       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16616       # a path prefixed by /cygdrive for fixpath to work.
16617       new_path="$CYGWIN_ROOT_PATH$input_path"
16618     fi
16619   fi
16620 
16621   # remove trailing .exe if any
16622   new_path="${new_path/%.exe/}"
16623 
16624   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16625 
16626   # First separate the path from the arguments. This will split at the first
16627   # space.
16628   complete="$FOUND_MAKE"
16629   path="${complete%% *}"
16630   tmp="$complete EOL"
16631   arguments="${tmp#* }"
16632 
16633   # Input might be given as Windows format, start by converting to
16634   # unix format.
16635   new_path="$path"
16636 
16637   windows_path="$new_path"
16638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16639     unix_path=`$CYGPATH -u "$windows_path"`
16640     new_path="$unix_path"
16641   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16642     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16643     new_path="$unix_path"
16644   fi
16645 
16646 
16647   # Now try to locate executable using which
16648   new_path=`$WHICH "$new_path" 2> /dev/null`
16649 
16650   if test "x$new_path" = x; then
16651     # Oops. Which didn't find the executable.
16652     # The splitting of arguments from the executable at a space might have been incorrect,
16653     # since paths with space are more likely in Windows. Give it another try with the whole
16654     # argument.
16655     path="$complete"
16656     arguments="EOL"
16657     new_path="$path"
16658 
16659   windows_path="$new_path"
16660   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16661     unix_path=`$CYGPATH -u "$windows_path"`
16662     new_path="$unix_path"
16663   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16664     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16665     new_path="$unix_path"
16666   fi
16667 
16668 
16669     new_path=`$WHICH "$new_path" 2> /dev/null`
16670 
16671     if test "x$new_path" = x; then
16672       # It's still not found. Now this is an unrecoverable error.
16673       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16674 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16675       has_space=`$ECHO "$complete" | $GREP " "`
16676       if test "x$has_space" != x; then
16677         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16678 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16679       fi
16680       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16681     fi
16682   fi
16683 
16684   # Now new_path has a complete unix path to the binary
16685   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16686     # Keep paths in /bin as-is, but remove trailing .exe if any
16687     new_path="${new_path/%.exe/}"
16688     # Do not save /bin paths to all_fixpath_prefixes!
16689   else
16690     # Not in mixed or Windows style, start by that.
16691     new_path=`cmd //c echo $new_path`
16692 
16693   input_path="$new_path"
16694   # Check if we need to convert this using DOS-style short mode. If the path
16695   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16696   # take no chances and rewrite it.
16697   # Note: m4 eats our [], so we need to use [ and ] instead.
16698   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16699   if test "x$has_forbidden_chars" != x; then
16700     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16701     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16702   fi
16703 
16704     # Output is in $new_path
16705 
16706   windows_path="$new_path"
16707   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16708     unix_path=`$CYGPATH -u "$windows_path"`
16709     new_path="$unix_path"
16710   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16711     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16712     new_path="$unix_path"
16713   fi
16714 
16715     # remove trailing .exe if any
16716     new_path="${new_path/%.exe/}"
16717 
16718     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16719     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16720   fi
16721 
16722   else
16723     # We're on a posix platform. Hooray! :)
16724     # First separate the path from the arguments. This will split at the first
16725     # space.
16726     complete="$FOUND_MAKE"
16727     path="${complete%% *}"
16728     tmp="$complete EOL"
16729     arguments="${tmp#* }"
16730 
16731     # Cannot rely on the command "which" here since it doesn't always work.
16732     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16733     if test -z "$is_absolute_path"; then
16734       # Path to executable is not absolute. Find it.
16735       IFS_save="$IFS"
16736       IFS=:
16737       for p in $PATH; do
16738         if test -f "$p/$path" && test -x "$p/$path"; then
16739           new_path="$p/$path"
16740           break
16741         fi
16742       done
16743       IFS="$IFS_save"
16744     else
16745       # This is an absolute path, we can use it without further modifications.
16746       new_path="$path"
16747     fi
16748 
16749     if test "x$new_path" = x; then
16750       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16751 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16752       has_space=`$ECHO "$complete" | $GREP " "`
16753       if test "x$has_space" != x; then
16754         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16755 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16756       fi
16757       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16758     fi
16759   fi
16760 
16761   # Now join together the path and the arguments once again
16762   if test "x$arguments" != xEOL; then
16763     new_complete="$new_path ${arguments% *}"
16764   else
16765     new_complete="$new_path"
16766   fi
16767 
16768   if test "x$complete" != "x$new_complete"; then
16769     FOUND_MAKE="$new_complete"
16770     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16771 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16772   fi
16773 
16774         fi
16775       fi
16776     fi
16777   fi
16778 
16779         fi
16780         PATH=$OLD_PATH
16781       fi
16782     fi
16783 
16784     if test "x$FOUND_MAKE" = x; then
16785       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
16786     fi
16787   fi
16788 
16789   MAKE=$FOUND_MAKE
16790 
16791   { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5
16792 $as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;}
16793 
16794 
16795 
16796   # Test if find supports -delete
16797   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5
16798 $as_echo_n "checking if find supports -delete... " >&6; }
16799   FIND_DELETE="-delete"
16800 
16801   DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?)
16802 
16803   echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete
16804 
16805   TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1`
16806   if test -f $DELETEDIR/TestIfFindSupportsDelete; then
16807     # No, it does not.
16808     rm $DELETEDIR/TestIfFindSupportsDelete
16809     FIND_DELETE="-exec rm \{\} \+"
16810     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16811 $as_echo "no" >&6; }
16812   else
16813     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16814 $as_echo "yes" >&6; }
16815   fi
16816   rmdir $DELETEDIR
16817 
16818 
16819 
16820   # These tools might not be installed by default,
16821   # need hint on how to install them.
16822 
16823 
16824 
16825   # Publish this variable in the help.
16826 
16827 
16828   if test "x$UNZIP" = x; then
16829     # The variable is not set by user, try to locate tool using the code snippet
16830     for ac_prog in unzip
16831 do
16832   # Extract the first word of "$ac_prog", so it can be a program name with args.
16833 set dummy $ac_prog; ac_word=$2
16834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16835 $as_echo_n "checking for $ac_word... " >&6; }
16836 if ${ac_cv_path_UNZIP+:} false; then :
16837   $as_echo_n "(cached) " >&6
16838 else
16839   case $UNZIP in
16840   [\\/]* | ?:[\\/]*)
16841   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16842   ;;
16843   *)
16844   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16845 for as_dir in $PATH
16846 do
16847   IFS=$as_save_IFS
16848   test -z "$as_dir" && as_dir=.
16849     for ac_exec_ext in '' $ac_executable_extensions; do
16850   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16851     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16852     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16853     break 2
16854   fi
16855 done
16856   done
16857 IFS=$as_save_IFS
16858 
16859   ;;
16860 esac
16861 fi
16862 UNZIP=$ac_cv_path_UNZIP
16863 if test -n "$UNZIP"; then
16864   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16865 $as_echo "$UNZIP" >&6; }
16866 else
16867   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16868 $as_echo "no" >&6; }
16869 fi
16870 
16871 
16872   test -n "$UNZIP" && break
16873 done
16874 
16875   else
16876     # The variable is set, but is it from the command line or the environment?
16877 
16878     # Try to remove the string !UNZIP! from our list.
16879     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/}
16880     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
16881       # If it failed, the variable was not from the command line. Ignore it,
16882       # but warn the user (except for BASH, which is always set by the calling BASH).
16883       if test "xUNZIP" != xBASH; then
16884         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5
16885 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;}
16886       fi
16887       # Try to locate tool using the code snippet
16888       for ac_prog in unzip
16889 do
16890   # Extract the first word of "$ac_prog", so it can be a program name with args.
16891 set dummy $ac_prog; ac_word=$2
16892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16893 $as_echo_n "checking for $ac_word... " >&6; }
16894 if ${ac_cv_path_UNZIP+:} false; then :
16895   $as_echo_n "(cached) " >&6
16896 else
16897   case $UNZIP in
16898   [\\/]* | ?:[\\/]*)
16899   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16900   ;;
16901   *)
16902   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16903 for as_dir in $PATH
16904 do
16905   IFS=$as_save_IFS
16906   test -z "$as_dir" && as_dir=.
16907     for ac_exec_ext in '' $ac_executable_extensions; do
16908   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16909     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16910     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16911     break 2
16912   fi
16913 done
16914   done
16915 IFS=$as_save_IFS
16916 
16917   ;;
16918 esac
16919 fi
16920 UNZIP=$ac_cv_path_UNZIP
16921 if test -n "$UNZIP"; then
16922   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16923 $as_echo "$UNZIP" >&6; }
16924 else
16925   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16926 $as_echo "no" >&6; }
16927 fi
16928 
16929 
16930   test -n "$UNZIP" && break
16931 done
16932 
16933     else
16934       # If it succeeded, then it was overridden by the user. We will use it
16935       # for the tool.
16936 
16937       # First remove it from the list of overridden variables, so we can test
16938       # for unknown variables in the end.
16939       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
16940 
16941       # Check if the provided tool contains a complete path.
16942       tool_specified="$UNZIP"
16943       tool_basename="${tool_specified##*/}"
16944       if test "x$tool_basename" = "x$tool_specified"; then
16945         # A command without a complete path is provided, search $PATH.
16946         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5
16947 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;}
16948         # Extract the first word of "$tool_basename", so it can be a program name with args.
16949 set dummy $tool_basename; ac_word=$2
16950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16951 $as_echo_n "checking for $ac_word... " >&6; }
16952 if ${ac_cv_path_UNZIP+:} false; then :
16953   $as_echo_n "(cached) " >&6
16954 else
16955   case $UNZIP in
16956   [\\/]* | ?:[\\/]*)
16957   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16958   ;;
16959   *)
16960   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16961 for as_dir in $PATH
16962 do
16963   IFS=$as_save_IFS
16964   test -z "$as_dir" && as_dir=.
16965     for ac_exec_ext in '' $ac_executable_extensions; do
16966   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16967     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16968     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16969     break 2
16970   fi
16971 done
16972   done
16973 IFS=$as_save_IFS
16974 
16975   ;;
16976 esac
16977 fi
16978 UNZIP=$ac_cv_path_UNZIP
16979 if test -n "$UNZIP"; then
16980   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16981 $as_echo "$UNZIP" >&6; }
16982 else
16983   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16984 $as_echo "no" >&6; }
16985 fi
16986 
16987 
16988         if test "x$UNZIP" = x; then
16989           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
16990         fi
16991       else
16992         # Otherwise we believe it is a complete path. Use it as it is.
16993         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5
16994 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;}
16995         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5
16996 $as_echo_n "checking for UNZIP... " >&6; }
16997         if test ! -x "$tool_specified"; then
16998           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
16999 $as_echo "not found" >&6; }
17000           as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17001         fi
17002         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17003 $as_echo "$tool_specified" >&6; }
17004       fi
17005     fi
17006   fi
17007 
17008 
17009 
17010   if test "x$UNZIP" = x; then
17011     as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5
17012   fi
17013 
17014 
17015 
17016 
17017 
17018   # Publish this variable in the help.
17019 
17020 
17021   if test "x$ZIP" = x; then
17022     # The variable is not set by user, try to locate tool using the code snippet
17023     for ac_prog in zip
17024 do
17025   # Extract the first word of "$ac_prog", so it can be a program name with args.
17026 set dummy $ac_prog; ac_word=$2
17027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17028 $as_echo_n "checking for $ac_word... " >&6; }
17029 if ${ac_cv_path_ZIP+:} false; then :
17030   $as_echo_n "(cached) " >&6
17031 else
17032   case $ZIP in
17033   [\\/]* | ?:[\\/]*)
17034   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17035   ;;
17036   *)
17037   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17038 for as_dir in $PATH
17039 do
17040   IFS=$as_save_IFS
17041   test -z "$as_dir" && as_dir=.
17042     for ac_exec_ext in '' $ac_executable_extensions; do
17043   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17044     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17045     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17046     break 2
17047   fi
17048 done
17049   done
17050 IFS=$as_save_IFS
17051 
17052   ;;
17053 esac
17054 fi
17055 ZIP=$ac_cv_path_ZIP
17056 if test -n "$ZIP"; then
17057   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17058 $as_echo "$ZIP" >&6; }
17059 else
17060   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17061 $as_echo "no" >&6; }
17062 fi
17063 
17064 
17065   test -n "$ZIP" && break
17066 done
17067 
17068   else
17069     # The variable is set, but is it from the command line or the environment?
17070 
17071     # Try to remove the string !ZIP! from our list.
17072     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/}
17073     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17074       # If it failed, the variable was not from the command line. Ignore it,
17075       # but warn the user (except for BASH, which is always set by the calling BASH).
17076       if test "xZIP" != xBASH; then
17077         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5
17078 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;}
17079       fi
17080       # Try to locate tool using the code snippet
17081       for ac_prog in zip
17082 do
17083   # Extract the first word of "$ac_prog", so it can be a program name with args.
17084 set dummy $ac_prog; ac_word=$2
17085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17086 $as_echo_n "checking for $ac_word... " >&6; }
17087 if ${ac_cv_path_ZIP+:} false; then :
17088   $as_echo_n "(cached) " >&6
17089 else
17090   case $ZIP in
17091   [\\/]* | ?:[\\/]*)
17092   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17093   ;;
17094   *)
17095   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17096 for as_dir in $PATH
17097 do
17098   IFS=$as_save_IFS
17099   test -z "$as_dir" && as_dir=.
17100     for ac_exec_ext in '' $ac_executable_extensions; do
17101   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17102     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17103     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17104     break 2
17105   fi
17106 done
17107   done
17108 IFS=$as_save_IFS
17109 
17110   ;;
17111 esac
17112 fi
17113 ZIP=$ac_cv_path_ZIP
17114 if test -n "$ZIP"; then
17115   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17116 $as_echo "$ZIP" >&6; }
17117 else
17118   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17119 $as_echo "no" >&6; }
17120 fi
17121 
17122 
17123   test -n "$ZIP" && break
17124 done
17125 
17126     else
17127       # If it succeeded, then it was overridden by the user. We will use it
17128       # for the tool.
17129 
17130       # First remove it from the list of overridden variables, so we can test
17131       # for unknown variables in the end.
17132       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17133 
17134       # Check if the provided tool contains a complete path.
17135       tool_specified="$ZIP"
17136       tool_basename="${tool_specified##*/}"
17137       if test "x$tool_basename" = "x$tool_specified"; then
17138         # A command without a complete path is provided, search $PATH.
17139         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5
17140 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;}
17141         # Extract the first word of "$tool_basename", so it can be a program name with args.
17142 set dummy $tool_basename; ac_word=$2
17143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17144 $as_echo_n "checking for $ac_word... " >&6; }
17145 if ${ac_cv_path_ZIP+:} false; then :
17146   $as_echo_n "(cached) " >&6
17147 else
17148   case $ZIP in
17149   [\\/]* | ?:[\\/]*)
17150   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17151   ;;
17152   *)
17153   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17154 for as_dir in $PATH
17155 do
17156   IFS=$as_save_IFS
17157   test -z "$as_dir" && as_dir=.
17158     for ac_exec_ext in '' $ac_executable_extensions; do
17159   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17160     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17161     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17162     break 2
17163   fi
17164 done
17165   done
17166 IFS=$as_save_IFS
17167 
17168   ;;
17169 esac
17170 fi
17171 ZIP=$ac_cv_path_ZIP
17172 if test -n "$ZIP"; then
17173   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17174 $as_echo "$ZIP" >&6; }
17175 else
17176   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17177 $as_echo "no" >&6; }
17178 fi
17179 
17180 
17181         if test "x$ZIP" = x; then
17182           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17183         fi
17184       else
17185         # Otherwise we believe it is a complete path. Use it as it is.
17186         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5
17187 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;}
17188         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5
17189 $as_echo_n "checking for ZIP... " >&6; }
17190         if test ! -x "$tool_specified"; then
17191           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17192 $as_echo "not found" >&6; }
17193           as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17194         fi
17195         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17196 $as_echo "$tool_specified" >&6; }
17197       fi
17198     fi
17199   fi
17200 
17201 
17202 
17203   if test "x$ZIP" = x; then
17204     as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5
17205   fi
17206 
17207 
17208 
17209   # Non-required basic tools
17210 
17211 
17212 
17213   # Publish this variable in the help.
17214 
17215 
17216   if test "x$LDD" = x; then
17217     # The variable is not set by user, try to locate tool using the code snippet
17218     for ac_prog in ldd
17219 do
17220   # Extract the first word of "$ac_prog", so it can be a program name with args.
17221 set dummy $ac_prog; ac_word=$2
17222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17223 $as_echo_n "checking for $ac_word... " >&6; }
17224 if ${ac_cv_path_LDD+:} false; then :
17225   $as_echo_n "(cached) " >&6
17226 else
17227   case $LDD in
17228   [\\/]* | ?:[\\/]*)
17229   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17230   ;;
17231   *)
17232   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17233 for as_dir in $PATH
17234 do
17235   IFS=$as_save_IFS
17236   test -z "$as_dir" && as_dir=.
17237     for ac_exec_ext in '' $ac_executable_extensions; do
17238   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17239     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17240     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17241     break 2
17242   fi
17243 done
17244   done
17245 IFS=$as_save_IFS
17246 
17247   ;;
17248 esac
17249 fi
17250 LDD=$ac_cv_path_LDD
17251 if test -n "$LDD"; then
17252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17253 $as_echo "$LDD" >&6; }
17254 else
17255   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17256 $as_echo "no" >&6; }
17257 fi
17258 
17259 
17260   test -n "$LDD" && break
17261 done
17262 
17263   else
17264     # The variable is set, but is it from the command line or the environment?
17265 
17266     # Try to remove the string !LDD! from our list.
17267     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/}
17268     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17269       # If it failed, the variable was not from the command line. Ignore it,
17270       # but warn the user (except for BASH, which is always set by the calling BASH).
17271       if test "xLDD" != xBASH; then
17272         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5
17273 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;}
17274       fi
17275       # Try to locate tool using the code snippet
17276       for ac_prog in ldd
17277 do
17278   # Extract the first word of "$ac_prog", so it can be a program name with args.
17279 set dummy $ac_prog; ac_word=$2
17280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17281 $as_echo_n "checking for $ac_word... " >&6; }
17282 if ${ac_cv_path_LDD+:} false; then :
17283   $as_echo_n "(cached) " >&6
17284 else
17285   case $LDD in
17286   [\\/]* | ?:[\\/]*)
17287   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17288   ;;
17289   *)
17290   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17291 for as_dir in $PATH
17292 do
17293   IFS=$as_save_IFS
17294   test -z "$as_dir" && as_dir=.
17295     for ac_exec_ext in '' $ac_executable_extensions; do
17296   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17297     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17298     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17299     break 2
17300   fi
17301 done
17302   done
17303 IFS=$as_save_IFS
17304 
17305   ;;
17306 esac
17307 fi
17308 LDD=$ac_cv_path_LDD
17309 if test -n "$LDD"; then
17310   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17311 $as_echo "$LDD" >&6; }
17312 else
17313   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17314 $as_echo "no" >&6; }
17315 fi
17316 
17317 
17318   test -n "$LDD" && break
17319 done
17320 
17321     else
17322       # If it succeeded, then it was overridden by the user. We will use it
17323       # for the tool.
17324 
17325       # First remove it from the list of overridden variables, so we can test
17326       # for unknown variables in the end.
17327       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17328 
17329       # Check if the provided tool contains a complete path.
17330       tool_specified="$LDD"
17331       tool_basename="${tool_specified##*/}"
17332       if test "x$tool_basename" = "x$tool_specified"; then
17333         # A command without a complete path is provided, search $PATH.
17334         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5
17335 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;}
17336         # Extract the first word of "$tool_basename", so it can be a program name with args.
17337 set dummy $tool_basename; ac_word=$2
17338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17339 $as_echo_n "checking for $ac_word... " >&6; }
17340 if ${ac_cv_path_LDD+:} false; then :
17341   $as_echo_n "(cached) " >&6
17342 else
17343   case $LDD in
17344   [\\/]* | ?:[\\/]*)
17345   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17346   ;;
17347   *)
17348   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17349 for as_dir in $PATH
17350 do
17351   IFS=$as_save_IFS
17352   test -z "$as_dir" && as_dir=.
17353     for ac_exec_ext in '' $ac_executable_extensions; do
17354   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17355     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17356     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17357     break 2
17358   fi
17359 done
17360   done
17361 IFS=$as_save_IFS
17362 
17363   ;;
17364 esac
17365 fi
17366 LDD=$ac_cv_path_LDD
17367 if test -n "$LDD"; then
17368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17369 $as_echo "$LDD" >&6; }
17370 else
17371   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17372 $as_echo "no" >&6; }
17373 fi
17374 
17375 
17376         if test "x$LDD" = x; then
17377           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17378         fi
17379       else
17380         # Otherwise we believe it is a complete path. Use it as it is.
17381         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5
17382 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;}
17383         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5
17384 $as_echo_n "checking for LDD... " >&6; }
17385         if test ! -x "$tool_specified"; then
17386           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17387 $as_echo "not found" >&6; }
17388           as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5
17389         fi
17390         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17391 $as_echo "$tool_specified" >&6; }
17392       fi
17393     fi
17394   fi
17395 
17396 
17397   if test "x$LDD" = "x"; then
17398     # List shared lib dependencies is used for
17399     # debug output and checking for forbidden dependencies.
17400     # We can build without it.
17401     LDD="true"
17402   fi
17403 
17404 
17405   # Publish this variable in the help.
17406 
17407 
17408   if test "x$OTOOL" = x; then
17409     # The variable is not set by user, try to locate tool using the code snippet
17410     for ac_prog in otool
17411 do
17412   # Extract the first word of "$ac_prog", so it can be a program name with args.
17413 set dummy $ac_prog; ac_word=$2
17414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17415 $as_echo_n "checking for $ac_word... " >&6; }
17416 if ${ac_cv_path_OTOOL+:} false; then :
17417   $as_echo_n "(cached) " >&6
17418 else
17419   case $OTOOL in
17420   [\\/]* | ?:[\\/]*)
17421   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17422   ;;
17423   *)
17424   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17425 for as_dir in $PATH
17426 do
17427   IFS=$as_save_IFS
17428   test -z "$as_dir" && as_dir=.
17429     for ac_exec_ext in '' $ac_executable_extensions; do
17430   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17431     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17432     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17433     break 2
17434   fi
17435 done
17436   done
17437 IFS=$as_save_IFS
17438 
17439   ;;
17440 esac
17441 fi
17442 OTOOL=$ac_cv_path_OTOOL
17443 if test -n "$OTOOL"; then
17444   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17445 $as_echo "$OTOOL" >&6; }
17446 else
17447   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17448 $as_echo "no" >&6; }
17449 fi
17450 
17451 
17452   test -n "$OTOOL" && break
17453 done
17454 
17455   else
17456     # The variable is set, but is it from the command line or the environment?
17457 
17458     # Try to remove the string !OTOOL! from our list.
17459     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/}
17460     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17461       # If it failed, the variable was not from the command line. Ignore it,
17462       # but warn the user (except for BASH, which is always set by the calling BASH).
17463       if test "xOTOOL" != xBASH; then
17464         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5
17465 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;}
17466       fi
17467       # Try to locate tool using the code snippet
17468       for ac_prog in otool
17469 do
17470   # Extract the first word of "$ac_prog", so it can be a program name with args.
17471 set dummy $ac_prog; ac_word=$2
17472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17473 $as_echo_n "checking for $ac_word... " >&6; }
17474 if ${ac_cv_path_OTOOL+:} false; then :
17475   $as_echo_n "(cached) " >&6
17476 else
17477   case $OTOOL in
17478   [\\/]* | ?:[\\/]*)
17479   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17480   ;;
17481   *)
17482   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17483 for as_dir in $PATH
17484 do
17485   IFS=$as_save_IFS
17486   test -z "$as_dir" && as_dir=.
17487     for ac_exec_ext in '' $ac_executable_extensions; do
17488   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17489     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17490     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17491     break 2
17492   fi
17493 done
17494   done
17495 IFS=$as_save_IFS
17496 
17497   ;;
17498 esac
17499 fi
17500 OTOOL=$ac_cv_path_OTOOL
17501 if test -n "$OTOOL"; then
17502   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17503 $as_echo "$OTOOL" >&6; }
17504 else
17505   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17506 $as_echo "no" >&6; }
17507 fi
17508 
17509 
17510   test -n "$OTOOL" && break
17511 done
17512 
17513     else
17514       # If it succeeded, then it was overridden by the user. We will use it
17515       # for the tool.
17516 
17517       # First remove it from the list of overridden variables, so we can test
17518       # for unknown variables in the end.
17519       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17520 
17521       # Check if the provided tool contains a complete path.
17522       tool_specified="$OTOOL"
17523       tool_basename="${tool_specified##*/}"
17524       if test "x$tool_basename" = "x$tool_specified"; then
17525         # A command without a complete path is provided, search $PATH.
17526         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5
17527 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;}
17528         # Extract the first word of "$tool_basename", so it can be a program name with args.
17529 set dummy $tool_basename; ac_word=$2
17530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17531 $as_echo_n "checking for $ac_word... " >&6; }
17532 if ${ac_cv_path_OTOOL+:} false; then :
17533   $as_echo_n "(cached) " >&6
17534 else
17535   case $OTOOL in
17536   [\\/]* | ?:[\\/]*)
17537   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17538   ;;
17539   *)
17540   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17541 for as_dir in $PATH
17542 do
17543   IFS=$as_save_IFS
17544   test -z "$as_dir" && as_dir=.
17545     for ac_exec_ext in '' $ac_executable_extensions; do
17546   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17547     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17548     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17549     break 2
17550   fi
17551 done
17552   done
17553 IFS=$as_save_IFS
17554 
17555   ;;
17556 esac
17557 fi
17558 OTOOL=$ac_cv_path_OTOOL
17559 if test -n "$OTOOL"; then
17560   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17561 $as_echo "$OTOOL" >&6; }
17562 else
17563   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17564 $as_echo "no" >&6; }
17565 fi
17566 
17567 
17568         if test "x$OTOOL" = x; then
17569           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17570         fi
17571       else
17572         # Otherwise we believe it is a complete path. Use it as it is.
17573         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5
17574 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;}
17575         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5
17576 $as_echo_n "checking for OTOOL... " >&6; }
17577         if test ! -x "$tool_specified"; then
17578           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17579 $as_echo "not found" >&6; }
17580           as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5
17581         fi
17582         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17583 $as_echo "$tool_specified" >&6; }
17584       fi
17585     fi
17586   fi
17587 
17588 
17589   if test "x$OTOOL" = "x"; then
17590     OTOOL="true"
17591   fi
17592 
17593 
17594   # Publish this variable in the help.
17595 
17596 
17597   if test "x$READELF" = x; then
17598     # The variable is not set by user, try to locate tool using the code snippet
17599     for ac_prog in greadelf readelf
17600 do
17601   # Extract the first word of "$ac_prog", so it can be a program name with args.
17602 set dummy $ac_prog; ac_word=$2
17603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17604 $as_echo_n "checking for $ac_word... " >&6; }
17605 if ${ac_cv_path_READELF+:} false; then :
17606   $as_echo_n "(cached) " >&6
17607 else
17608   case $READELF in
17609   [\\/]* | ?:[\\/]*)
17610   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17611   ;;
17612   *)
17613   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17614 for as_dir in $PATH
17615 do
17616   IFS=$as_save_IFS
17617   test -z "$as_dir" && as_dir=.
17618     for ac_exec_ext in '' $ac_executable_extensions; do
17619   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17620     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17621     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17622     break 2
17623   fi
17624 done
17625   done
17626 IFS=$as_save_IFS
17627 
17628   ;;
17629 esac
17630 fi
17631 READELF=$ac_cv_path_READELF
17632 if test -n "$READELF"; then
17633   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17634 $as_echo "$READELF" >&6; }
17635 else
17636   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17637 $as_echo "no" >&6; }
17638 fi
17639 
17640 
17641   test -n "$READELF" && break
17642 done
17643 
17644   else
17645     # The variable is set, but is it from the command line or the environment?
17646 
17647     # Try to remove the string !READELF! from our list.
17648     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/}
17649     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17650       # If it failed, the variable was not from the command line. Ignore it,
17651       # but warn the user (except for BASH, which is always set by the calling BASH).
17652       if test "xREADELF" != xBASH; then
17653         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5
17654 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;}
17655       fi
17656       # Try to locate tool using the code snippet
17657       for ac_prog in greadelf readelf
17658 do
17659   # Extract the first word of "$ac_prog", so it can be a program name with args.
17660 set dummy $ac_prog; ac_word=$2
17661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17662 $as_echo_n "checking for $ac_word... " >&6; }
17663 if ${ac_cv_path_READELF+:} false; then :
17664   $as_echo_n "(cached) " >&6
17665 else
17666   case $READELF in
17667   [\\/]* | ?:[\\/]*)
17668   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17669   ;;
17670   *)
17671   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17672 for as_dir in $PATH
17673 do
17674   IFS=$as_save_IFS
17675   test -z "$as_dir" && as_dir=.
17676     for ac_exec_ext in '' $ac_executable_extensions; do
17677   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17678     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17679     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17680     break 2
17681   fi
17682 done
17683   done
17684 IFS=$as_save_IFS
17685 
17686   ;;
17687 esac
17688 fi
17689 READELF=$ac_cv_path_READELF
17690 if test -n "$READELF"; then
17691   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17692 $as_echo "$READELF" >&6; }
17693 else
17694   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17695 $as_echo "no" >&6; }
17696 fi
17697 
17698 
17699   test -n "$READELF" && break
17700 done
17701 
17702     else
17703       # If it succeeded, then it was overridden by the user. We will use it
17704       # for the tool.
17705 
17706       # First remove it from the list of overridden variables, so we can test
17707       # for unknown variables in the end.
17708       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17709 
17710       # Check if the provided tool contains a complete path.
17711       tool_specified="$READELF"
17712       tool_basename="${tool_specified##*/}"
17713       if test "x$tool_basename" = "x$tool_specified"; then
17714         # A command without a complete path is provided, search $PATH.
17715         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5
17716 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;}
17717         # Extract the first word of "$tool_basename", so it can be a program name with args.
17718 set dummy $tool_basename; ac_word=$2
17719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17720 $as_echo_n "checking for $ac_word... " >&6; }
17721 if ${ac_cv_path_READELF+:} false; then :
17722   $as_echo_n "(cached) " >&6
17723 else
17724   case $READELF in
17725   [\\/]* | ?:[\\/]*)
17726   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17727   ;;
17728   *)
17729   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17730 for as_dir in $PATH
17731 do
17732   IFS=$as_save_IFS
17733   test -z "$as_dir" && as_dir=.
17734     for ac_exec_ext in '' $ac_executable_extensions; do
17735   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17736     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17737     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17738     break 2
17739   fi
17740 done
17741   done
17742 IFS=$as_save_IFS
17743 
17744   ;;
17745 esac
17746 fi
17747 READELF=$ac_cv_path_READELF
17748 if test -n "$READELF"; then
17749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17750 $as_echo "$READELF" >&6; }
17751 else
17752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17753 $as_echo "no" >&6; }
17754 fi
17755 
17756 
17757         if test "x$READELF" = x; then
17758           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17759         fi
17760       else
17761         # Otherwise we believe it is a complete path. Use it as it is.
17762         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5
17763 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;}
17764         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5
17765 $as_echo_n "checking for READELF... " >&6; }
17766         if test ! -x "$tool_specified"; then
17767           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17768 $as_echo "not found" >&6; }
17769           as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5
17770         fi
17771         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17772 $as_echo "$tool_specified" >&6; }
17773       fi
17774     fi
17775   fi
17776 
17777 
17778 
17779 
17780   # Publish this variable in the help.
17781 
17782 
17783   if test "x$HG" = x; then
17784     # The variable is not set by user, try to locate tool using the code snippet
17785     for ac_prog in hg
17786 do
17787   # Extract the first word of "$ac_prog", so it can be a program name with args.
17788 set dummy $ac_prog; ac_word=$2
17789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17790 $as_echo_n "checking for $ac_word... " >&6; }
17791 if ${ac_cv_path_HG+:} false; then :
17792   $as_echo_n "(cached) " >&6
17793 else
17794   case $HG in
17795   [\\/]* | ?:[\\/]*)
17796   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17797   ;;
17798   *)
17799   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17800 for as_dir in $PATH
17801 do
17802   IFS=$as_save_IFS
17803   test -z "$as_dir" && as_dir=.
17804     for ac_exec_ext in '' $ac_executable_extensions; do
17805   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17806     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17807     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17808     break 2
17809   fi
17810 done
17811   done
17812 IFS=$as_save_IFS
17813 
17814   ;;
17815 esac
17816 fi
17817 HG=$ac_cv_path_HG
17818 if test -n "$HG"; then
17819   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17820 $as_echo "$HG" >&6; }
17821 else
17822   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17823 $as_echo "no" >&6; }
17824 fi
17825 
17826 
17827   test -n "$HG" && break
17828 done
17829 
17830   else
17831     # The variable is set, but is it from the command line or the environment?
17832 
17833     # Try to remove the string !HG! from our list.
17834     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/}
17835     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17836       # If it failed, the variable was not from the command line. Ignore it,
17837       # but warn the user (except for BASH, which is always set by the calling BASH).
17838       if test "xHG" != xBASH; then
17839         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5
17840 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;}
17841       fi
17842       # Try to locate tool using the code snippet
17843       for ac_prog in hg
17844 do
17845   # Extract the first word of "$ac_prog", so it can be a program name with args.
17846 set dummy $ac_prog; ac_word=$2
17847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17848 $as_echo_n "checking for $ac_word... " >&6; }
17849 if ${ac_cv_path_HG+:} false; then :
17850   $as_echo_n "(cached) " >&6
17851 else
17852   case $HG in
17853   [\\/]* | ?:[\\/]*)
17854   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17855   ;;
17856   *)
17857   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17858 for as_dir in $PATH
17859 do
17860   IFS=$as_save_IFS
17861   test -z "$as_dir" && as_dir=.
17862     for ac_exec_ext in '' $ac_executable_extensions; do
17863   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17864     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17865     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17866     break 2
17867   fi
17868 done
17869   done
17870 IFS=$as_save_IFS
17871 
17872   ;;
17873 esac
17874 fi
17875 HG=$ac_cv_path_HG
17876 if test -n "$HG"; then
17877   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17878 $as_echo "$HG" >&6; }
17879 else
17880   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17881 $as_echo "no" >&6; }
17882 fi
17883 
17884 
17885   test -n "$HG" && break
17886 done
17887 
17888     else
17889       # If it succeeded, then it was overridden by the user. We will use it
17890       # for the tool.
17891 
17892       # First remove it from the list of overridden variables, so we can test
17893       # for unknown variables in the end.
17894       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17895 
17896       # Check if the provided tool contains a complete path.
17897       tool_specified="$HG"
17898       tool_basename="${tool_specified##*/}"
17899       if test "x$tool_basename" = "x$tool_specified"; then
17900         # A command without a complete path is provided, search $PATH.
17901         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5
17902 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;}
17903         # Extract the first word of "$tool_basename", so it can be a program name with args.
17904 set dummy $tool_basename; ac_word=$2
17905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17906 $as_echo_n "checking for $ac_word... " >&6; }
17907 if ${ac_cv_path_HG+:} false; then :
17908   $as_echo_n "(cached) " >&6
17909 else
17910   case $HG in
17911   [\\/]* | ?:[\\/]*)
17912   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17913   ;;
17914   *)
17915   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17916 for as_dir in $PATH
17917 do
17918   IFS=$as_save_IFS
17919   test -z "$as_dir" && as_dir=.
17920     for ac_exec_ext in '' $ac_executable_extensions; do
17921   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17922     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17923     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17924     break 2
17925   fi
17926 done
17927   done
17928 IFS=$as_save_IFS
17929 
17930   ;;
17931 esac
17932 fi
17933 HG=$ac_cv_path_HG
17934 if test -n "$HG"; then
17935   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17936 $as_echo "$HG" >&6; }
17937 else
17938   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17939 $as_echo "no" >&6; }
17940 fi
17941 
17942 
17943         if test "x$HG" = x; then
17944           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17945         fi
17946       else
17947         # Otherwise we believe it is a complete path. Use it as it is.
17948         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5
17949 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;}
17950         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5
17951 $as_echo_n "checking for HG... " >&6; }
17952         if test ! -x "$tool_specified"; then
17953           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17954 $as_echo "not found" >&6; }
17955           as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5
17956         fi
17957         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17958 $as_echo "$tool_specified" >&6; }
17959       fi
17960     fi
17961   fi
17962 
17963 
17964 
17965 
17966   # Publish this variable in the help.
17967 
17968 
17969   if test "x$STAT" = x; then
17970     # The variable is not set by user, try to locate tool using the code snippet
17971     for ac_prog in stat
17972 do
17973   # Extract the first word of "$ac_prog", so it can be a program name with args.
17974 set dummy $ac_prog; ac_word=$2
17975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17976 $as_echo_n "checking for $ac_word... " >&6; }
17977 if ${ac_cv_path_STAT+:} false; then :
17978   $as_echo_n "(cached) " >&6
17979 else
17980   case $STAT in
17981   [\\/]* | ?:[\\/]*)
17982   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
17983   ;;
17984   *)
17985   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17986 for as_dir in $PATH
17987 do
17988   IFS=$as_save_IFS
17989   test -z "$as_dir" && as_dir=.
17990     for ac_exec_ext in '' $ac_executable_extensions; do
17991   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17992     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
17993     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17994     break 2
17995   fi
17996 done
17997   done
17998 IFS=$as_save_IFS
17999 
18000   ;;
18001 esac
18002 fi
18003 STAT=$ac_cv_path_STAT
18004 if test -n "$STAT"; then
18005   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18006 $as_echo "$STAT" >&6; }
18007 else
18008   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18009 $as_echo "no" >&6; }
18010 fi
18011 
18012 
18013   test -n "$STAT" && break
18014 done
18015 
18016   else
18017     # The variable is set, but is it from the command line or the environment?
18018 
18019     # Try to remove the string !STAT! from our list.
18020     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/}
18021     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18022       # If it failed, the variable was not from the command line. Ignore it,
18023       # but warn the user (except for BASH, which is always set by the calling BASH).
18024       if test "xSTAT" != xBASH; then
18025         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5
18026 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;}
18027       fi
18028       # Try to locate tool using the code snippet
18029       for ac_prog in stat
18030 do
18031   # Extract the first word of "$ac_prog", so it can be a program name with args.
18032 set dummy $ac_prog; ac_word=$2
18033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18034 $as_echo_n "checking for $ac_word... " >&6; }
18035 if ${ac_cv_path_STAT+:} false; then :
18036   $as_echo_n "(cached) " >&6
18037 else
18038   case $STAT in
18039   [\\/]* | ?:[\\/]*)
18040   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18041   ;;
18042   *)
18043   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18044 for as_dir in $PATH
18045 do
18046   IFS=$as_save_IFS
18047   test -z "$as_dir" && as_dir=.
18048     for ac_exec_ext in '' $ac_executable_extensions; do
18049   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18050     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18051     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18052     break 2
18053   fi
18054 done
18055   done
18056 IFS=$as_save_IFS
18057 
18058   ;;
18059 esac
18060 fi
18061 STAT=$ac_cv_path_STAT
18062 if test -n "$STAT"; then
18063   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18064 $as_echo "$STAT" >&6; }
18065 else
18066   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18067 $as_echo "no" >&6; }
18068 fi
18069 
18070 
18071   test -n "$STAT" && break
18072 done
18073 
18074     else
18075       # If it succeeded, then it was overridden by the user. We will use it
18076       # for the tool.
18077 
18078       # First remove it from the list of overridden variables, so we can test
18079       # for unknown variables in the end.
18080       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18081 
18082       # Check if the provided tool contains a complete path.
18083       tool_specified="$STAT"
18084       tool_basename="${tool_specified##*/}"
18085       if test "x$tool_basename" = "x$tool_specified"; then
18086         # A command without a complete path is provided, search $PATH.
18087         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5
18088 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;}
18089         # Extract the first word of "$tool_basename", so it can be a program name with args.
18090 set dummy $tool_basename; ac_word=$2
18091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18092 $as_echo_n "checking for $ac_word... " >&6; }
18093 if ${ac_cv_path_STAT+:} false; then :
18094   $as_echo_n "(cached) " >&6
18095 else
18096   case $STAT in
18097   [\\/]* | ?:[\\/]*)
18098   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18099   ;;
18100   *)
18101   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18102 for as_dir in $PATH
18103 do
18104   IFS=$as_save_IFS
18105   test -z "$as_dir" && as_dir=.
18106     for ac_exec_ext in '' $ac_executable_extensions; do
18107   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18108     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18109     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18110     break 2
18111   fi
18112 done
18113   done
18114 IFS=$as_save_IFS
18115 
18116   ;;
18117 esac
18118 fi
18119 STAT=$ac_cv_path_STAT
18120 if test -n "$STAT"; then
18121   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18122 $as_echo "$STAT" >&6; }
18123 else
18124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18125 $as_echo "no" >&6; }
18126 fi
18127 
18128 
18129         if test "x$STAT" = x; then
18130           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18131         fi
18132       else
18133         # Otherwise we believe it is a complete path. Use it as it is.
18134         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5
18135 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;}
18136         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5
18137 $as_echo_n "checking for STAT... " >&6; }
18138         if test ! -x "$tool_specified"; then
18139           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18140 $as_echo "not found" >&6; }
18141           as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5
18142         fi
18143         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18144 $as_echo "$tool_specified" >&6; }
18145       fi
18146     fi
18147   fi
18148 
18149 
18150 
18151 
18152   # Publish this variable in the help.
18153 
18154 
18155   if test "x$TIME" = x; then
18156     # The variable is not set by user, try to locate tool using the code snippet
18157     for ac_prog in time
18158 do
18159   # Extract the first word of "$ac_prog", so it can be a program name with args.
18160 set dummy $ac_prog; ac_word=$2
18161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18162 $as_echo_n "checking for $ac_word... " >&6; }
18163 if ${ac_cv_path_TIME+:} false; then :
18164   $as_echo_n "(cached) " >&6
18165 else
18166   case $TIME in
18167   [\\/]* | ?:[\\/]*)
18168   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18169   ;;
18170   *)
18171   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18172 for as_dir in $PATH
18173 do
18174   IFS=$as_save_IFS
18175   test -z "$as_dir" && as_dir=.
18176     for ac_exec_ext in '' $ac_executable_extensions; do
18177   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18178     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18179     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18180     break 2
18181   fi
18182 done
18183   done
18184 IFS=$as_save_IFS
18185 
18186   ;;
18187 esac
18188 fi
18189 TIME=$ac_cv_path_TIME
18190 if test -n "$TIME"; then
18191   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18192 $as_echo "$TIME" >&6; }
18193 else
18194   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18195 $as_echo "no" >&6; }
18196 fi
18197 
18198 
18199   test -n "$TIME" && break
18200 done
18201 
18202   else
18203     # The variable is set, but is it from the command line or the environment?
18204 
18205     # Try to remove the string !TIME! from our list.
18206     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/}
18207     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18208       # If it failed, the variable was not from the command line. Ignore it,
18209       # but warn the user (except for BASH, which is always set by the calling BASH).
18210       if test "xTIME" != xBASH; then
18211         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5
18212 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;}
18213       fi
18214       # Try to locate tool using the code snippet
18215       for ac_prog in time
18216 do
18217   # Extract the first word of "$ac_prog", so it can be a program name with args.
18218 set dummy $ac_prog; ac_word=$2
18219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18220 $as_echo_n "checking for $ac_word... " >&6; }
18221 if ${ac_cv_path_TIME+:} false; then :
18222   $as_echo_n "(cached) " >&6
18223 else
18224   case $TIME in
18225   [\\/]* | ?:[\\/]*)
18226   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18227   ;;
18228   *)
18229   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18230 for as_dir in $PATH
18231 do
18232   IFS=$as_save_IFS
18233   test -z "$as_dir" && as_dir=.
18234     for ac_exec_ext in '' $ac_executable_extensions; do
18235   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18236     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18237     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18238     break 2
18239   fi
18240 done
18241   done
18242 IFS=$as_save_IFS
18243 
18244   ;;
18245 esac
18246 fi
18247 TIME=$ac_cv_path_TIME
18248 if test -n "$TIME"; then
18249   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18250 $as_echo "$TIME" >&6; }
18251 else
18252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18253 $as_echo "no" >&6; }
18254 fi
18255 
18256 
18257   test -n "$TIME" && break
18258 done
18259 
18260     else
18261       # If it succeeded, then it was overridden by the user. We will use it
18262       # for the tool.
18263 
18264       # First remove it from the list of overridden variables, so we can test
18265       # for unknown variables in the end.
18266       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18267 
18268       # Check if the provided tool contains a complete path.
18269       tool_specified="$TIME"
18270       tool_basename="${tool_specified##*/}"
18271       if test "x$tool_basename" = "x$tool_specified"; then
18272         # A command without a complete path is provided, search $PATH.
18273         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5
18274 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;}
18275         # Extract the first word of "$tool_basename", so it can be a program name with args.
18276 set dummy $tool_basename; ac_word=$2
18277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18278 $as_echo_n "checking for $ac_word... " >&6; }
18279 if ${ac_cv_path_TIME+:} false; then :
18280   $as_echo_n "(cached) " >&6
18281 else
18282   case $TIME in
18283   [\\/]* | ?:[\\/]*)
18284   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18285   ;;
18286   *)
18287   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18288 for as_dir in $PATH
18289 do
18290   IFS=$as_save_IFS
18291   test -z "$as_dir" && as_dir=.
18292     for ac_exec_ext in '' $ac_executable_extensions; do
18293   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18294     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18295     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18296     break 2
18297   fi
18298 done
18299   done
18300 IFS=$as_save_IFS
18301 
18302   ;;
18303 esac
18304 fi
18305 TIME=$ac_cv_path_TIME
18306 if test -n "$TIME"; then
18307   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18308 $as_echo "$TIME" >&6; }
18309 else
18310   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18311 $as_echo "no" >&6; }
18312 fi
18313 
18314 
18315         if test "x$TIME" = x; then
18316           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18317         fi
18318       else
18319         # Otherwise we believe it is a complete path. Use it as it is.
18320         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5
18321 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;}
18322         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5
18323 $as_echo_n "checking for TIME... " >&6; }
18324         if test ! -x "$tool_specified"; then
18325           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18326 $as_echo "not found" >&6; }
18327           as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5
18328         fi
18329         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18330 $as_echo "$tool_specified" >&6; }
18331       fi
18332     fi
18333   fi
18334 
18335 
18336   # Check if it's GNU time
18337   IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'`
18338   if test "x$IS_GNU_TIME" != x; then
18339     IS_GNU_TIME=yes
18340   else
18341     IS_GNU_TIME=no
18342   fi
18343 
18344 
18345   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
18346 
18347 
18348 
18349   # Publish this variable in the help.
18350 
18351 
18352   if test "x$COMM" = x; then
18353     # The variable is not set by user, try to locate tool using the code snippet
18354     for ac_prog in comm
18355 do
18356   # Extract the first word of "$ac_prog", so it can be a program name with args.
18357 set dummy $ac_prog; ac_word=$2
18358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18359 $as_echo_n "checking for $ac_word... " >&6; }
18360 if ${ac_cv_path_COMM+:} false; then :
18361   $as_echo_n "(cached) " >&6
18362 else
18363   case $COMM in
18364   [\\/]* | ?:[\\/]*)
18365   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18366   ;;
18367   *)
18368   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18369 for as_dir in $PATH
18370 do
18371   IFS=$as_save_IFS
18372   test -z "$as_dir" && as_dir=.
18373     for ac_exec_ext in '' $ac_executable_extensions; do
18374   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18375     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18376     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18377     break 2
18378   fi
18379 done
18380   done
18381 IFS=$as_save_IFS
18382 
18383   ;;
18384 esac
18385 fi
18386 COMM=$ac_cv_path_COMM
18387 if test -n "$COMM"; then
18388   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18389 $as_echo "$COMM" >&6; }
18390 else
18391   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18392 $as_echo "no" >&6; }
18393 fi
18394 
18395 
18396   test -n "$COMM" && break
18397 done
18398 
18399   else
18400     # The variable is set, but is it from the command line or the environment?
18401 
18402     # Try to remove the string !COMM! from our list.
18403     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
18404     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18405       # If it failed, the variable was not from the command line. Ignore it,
18406       # but warn the user (except for BASH, which is always set by the calling BASH).
18407       if test "xCOMM" != xBASH; then
18408         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
18409 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
18410       fi
18411       # Try to locate tool using the code snippet
18412       for ac_prog in comm
18413 do
18414   # Extract the first word of "$ac_prog", so it can be a program name with args.
18415 set dummy $ac_prog; ac_word=$2
18416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18417 $as_echo_n "checking for $ac_word... " >&6; }
18418 if ${ac_cv_path_COMM+:} false; then :
18419   $as_echo_n "(cached) " >&6
18420 else
18421   case $COMM in
18422   [\\/]* | ?:[\\/]*)
18423   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18424   ;;
18425   *)
18426   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18427 for as_dir in $PATH
18428 do
18429   IFS=$as_save_IFS
18430   test -z "$as_dir" && as_dir=.
18431     for ac_exec_ext in '' $ac_executable_extensions; do
18432   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18433     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18434     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18435     break 2
18436   fi
18437 done
18438   done
18439 IFS=$as_save_IFS
18440 
18441   ;;
18442 esac
18443 fi
18444 COMM=$ac_cv_path_COMM
18445 if test -n "$COMM"; then
18446   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18447 $as_echo "$COMM" >&6; }
18448 else
18449   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18450 $as_echo "no" >&6; }
18451 fi
18452 
18453 
18454   test -n "$COMM" && break
18455 done
18456 
18457     else
18458       # If it succeeded, then it was overridden by the user. We will use it
18459       # for the tool.
18460 
18461       # First remove it from the list of overridden variables, so we can test
18462       # for unknown variables in the end.
18463       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18464 
18465       # Check if the provided tool contains a complete path.
18466       tool_specified="$COMM"
18467       tool_basename="${tool_specified##*/}"
18468       if test "x$tool_basename" = "x$tool_specified"; then
18469         # A command without a complete path is provided, search $PATH.
18470         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
18471 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
18472         # Extract the first word of "$tool_basename", so it can be a program name with args.
18473 set dummy $tool_basename; ac_word=$2
18474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18475 $as_echo_n "checking for $ac_word... " >&6; }
18476 if ${ac_cv_path_COMM+:} false; then :
18477   $as_echo_n "(cached) " >&6
18478 else
18479   case $COMM in
18480   [\\/]* | ?:[\\/]*)
18481   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18482   ;;
18483   *)
18484   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18485 for as_dir in $PATH
18486 do
18487   IFS=$as_save_IFS
18488   test -z "$as_dir" && as_dir=.
18489     for ac_exec_ext in '' $ac_executable_extensions; do
18490   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18491     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18492     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18493     break 2
18494   fi
18495 done
18496   done
18497 IFS=$as_save_IFS
18498 
18499   ;;
18500 esac
18501 fi
18502 COMM=$ac_cv_path_COMM
18503 if test -n "$COMM"; then
18504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18505 $as_echo "$COMM" >&6; }
18506 else
18507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18508 $as_echo "no" >&6; }
18509 fi
18510 
18511 
18512         if test "x$COMM" = x; then
18513           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18514         fi
18515       else
18516         # Otherwise we believe it is a complete path. Use it as it is.
18517         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
18518 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
18519         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
18520 $as_echo_n "checking for COMM... " >&6; }
18521         if test ! -x "$tool_specified"; then
18522           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18523 $as_echo "not found" >&6; }
18524           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
18525         fi
18526         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18527 $as_echo "$tool_specified" >&6; }
18528       fi
18529     fi
18530   fi
18531 
18532 
18533 
18534   if test "x$COMM" = x; then
18535     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
18536   fi
18537 
18538 
18539   fi
18540 
18541   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
18542 
18543 
18544 
18545   # Publish this variable in the help.
18546 
18547 
18548   if test "x$DSYMUTIL" = x; then
18549     # The variable is not set by user, try to locate tool using the code snippet
18550     for ac_prog in dsymutil
18551 do
18552   # Extract the first word of "$ac_prog", so it can be a program name with args.
18553 set dummy $ac_prog; ac_word=$2
18554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18555 $as_echo_n "checking for $ac_word... " >&6; }
18556 if ${ac_cv_path_DSYMUTIL+:} false; then :
18557   $as_echo_n "(cached) " >&6
18558 else
18559   case $DSYMUTIL in
18560   [\\/]* | ?:[\\/]*)
18561   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18562   ;;
18563   *)
18564   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18565 for as_dir in $PATH
18566 do
18567   IFS=$as_save_IFS
18568   test -z "$as_dir" && as_dir=.
18569     for ac_exec_ext in '' $ac_executable_extensions; do
18570   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18571     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18572     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18573     break 2
18574   fi
18575 done
18576   done
18577 IFS=$as_save_IFS
18578 
18579   ;;
18580 esac
18581 fi
18582 DSYMUTIL=$ac_cv_path_DSYMUTIL
18583 if test -n "$DSYMUTIL"; then
18584   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18585 $as_echo "$DSYMUTIL" >&6; }
18586 else
18587   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18588 $as_echo "no" >&6; }
18589 fi
18590 
18591 
18592   test -n "$DSYMUTIL" && break
18593 done
18594 
18595   else
18596     # The variable is set, but is it from the command line or the environment?
18597 
18598     # Try to remove the string !DSYMUTIL! from our list.
18599     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/}
18600     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18601       # If it failed, the variable was not from the command line. Ignore it,
18602       # but warn the user (except for BASH, which is always set by the calling BASH).
18603       if test "xDSYMUTIL" != xBASH; then
18604         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5
18605 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;}
18606       fi
18607       # Try to locate tool using the code snippet
18608       for ac_prog in dsymutil
18609 do
18610   # Extract the first word of "$ac_prog", so it can be a program name with args.
18611 set dummy $ac_prog; ac_word=$2
18612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18613 $as_echo_n "checking for $ac_word... " >&6; }
18614 if ${ac_cv_path_DSYMUTIL+:} false; then :
18615   $as_echo_n "(cached) " >&6
18616 else
18617   case $DSYMUTIL in
18618   [\\/]* | ?:[\\/]*)
18619   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18620   ;;
18621   *)
18622   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18623 for as_dir in $PATH
18624 do
18625   IFS=$as_save_IFS
18626   test -z "$as_dir" && as_dir=.
18627     for ac_exec_ext in '' $ac_executable_extensions; do
18628   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18629     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18630     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18631     break 2
18632   fi
18633 done
18634   done
18635 IFS=$as_save_IFS
18636 
18637   ;;
18638 esac
18639 fi
18640 DSYMUTIL=$ac_cv_path_DSYMUTIL
18641 if test -n "$DSYMUTIL"; then
18642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18643 $as_echo "$DSYMUTIL" >&6; }
18644 else
18645   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18646 $as_echo "no" >&6; }
18647 fi
18648 
18649 
18650   test -n "$DSYMUTIL" && break
18651 done
18652 
18653     else
18654       # If it succeeded, then it was overridden by the user. We will use it
18655       # for the tool.
18656 
18657       # First remove it from the list of overridden variables, so we can test
18658       # for unknown variables in the end.
18659       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18660 
18661       # Check if the provided tool contains a complete path.
18662       tool_specified="$DSYMUTIL"
18663       tool_basename="${tool_specified##*/}"
18664       if test "x$tool_basename" = "x$tool_specified"; then
18665         # A command without a complete path is provided, search $PATH.
18666         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5
18667 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;}
18668         # Extract the first word of "$tool_basename", so it can be a program name with args.
18669 set dummy $tool_basename; ac_word=$2
18670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18671 $as_echo_n "checking for $ac_word... " >&6; }
18672 if ${ac_cv_path_DSYMUTIL+:} false; then :
18673   $as_echo_n "(cached) " >&6
18674 else
18675   case $DSYMUTIL in
18676   [\\/]* | ?:[\\/]*)
18677   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18678   ;;
18679   *)
18680   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18681 for as_dir in $PATH
18682 do
18683   IFS=$as_save_IFS
18684   test -z "$as_dir" && as_dir=.
18685     for ac_exec_ext in '' $ac_executable_extensions; do
18686   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18687     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18688     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18689     break 2
18690   fi
18691 done
18692   done
18693 IFS=$as_save_IFS
18694 
18695   ;;
18696 esac
18697 fi
18698 DSYMUTIL=$ac_cv_path_DSYMUTIL
18699 if test -n "$DSYMUTIL"; then
18700   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18701 $as_echo "$DSYMUTIL" >&6; }
18702 else
18703   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18704 $as_echo "no" >&6; }
18705 fi
18706 
18707 
18708         if test "x$DSYMUTIL" = x; then
18709           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18710         fi
18711       else
18712         # Otherwise we believe it is a complete path. Use it as it is.
18713         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5
18714 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;}
18715         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5
18716 $as_echo_n "checking for DSYMUTIL... " >&6; }
18717         if test ! -x "$tool_specified"; then
18718           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18719 $as_echo "not found" >&6; }
18720           as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5
18721         fi
18722         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18723 $as_echo "$tool_specified" >&6; }
18724       fi
18725     fi
18726   fi
18727 
18728 
18729 
18730   if test "x$DSYMUTIL" = x; then
18731     as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5
18732   fi
18733 
18734 
18735 
18736 
18737 
18738   # Publish this variable in the help.
18739 
18740 
18741   if test "x$XATTR" = x; then
18742     # The variable is not set by user, try to locate tool using the code snippet
18743     for ac_prog in xattr
18744 do
18745   # Extract the first word of "$ac_prog", so it can be a program name with args.
18746 set dummy $ac_prog; ac_word=$2
18747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18748 $as_echo_n "checking for $ac_word... " >&6; }
18749 if ${ac_cv_path_XATTR+:} false; then :
18750   $as_echo_n "(cached) " >&6
18751 else
18752   case $XATTR in
18753   [\\/]* | ?:[\\/]*)
18754   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18755   ;;
18756   *)
18757   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18758 for as_dir in $PATH
18759 do
18760   IFS=$as_save_IFS
18761   test -z "$as_dir" && as_dir=.
18762     for ac_exec_ext in '' $ac_executable_extensions; do
18763   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18764     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18765     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18766     break 2
18767   fi
18768 done
18769   done
18770 IFS=$as_save_IFS
18771 
18772   ;;
18773 esac
18774 fi
18775 XATTR=$ac_cv_path_XATTR
18776 if test -n "$XATTR"; then
18777   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18778 $as_echo "$XATTR" >&6; }
18779 else
18780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18781 $as_echo "no" >&6; }
18782 fi
18783 
18784 
18785   test -n "$XATTR" && break
18786 done
18787 
18788   else
18789     # The variable is set, but is it from the command line or the environment?
18790 
18791     # Try to remove the string !XATTR! from our list.
18792     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/}
18793     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18794       # If it failed, the variable was not from the command line. Ignore it,
18795       # but warn the user (except for BASH, which is always set by the calling BASH).
18796       if test "xXATTR" != xBASH; then
18797         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5
18798 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;}
18799       fi
18800       # Try to locate tool using the code snippet
18801       for ac_prog in xattr
18802 do
18803   # Extract the first word of "$ac_prog", so it can be a program name with args.
18804 set dummy $ac_prog; ac_word=$2
18805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18806 $as_echo_n "checking for $ac_word... " >&6; }
18807 if ${ac_cv_path_XATTR+:} false; then :
18808   $as_echo_n "(cached) " >&6
18809 else
18810   case $XATTR in
18811   [\\/]* | ?:[\\/]*)
18812   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18813   ;;
18814   *)
18815   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18816 for as_dir in $PATH
18817 do
18818   IFS=$as_save_IFS
18819   test -z "$as_dir" && as_dir=.
18820     for ac_exec_ext in '' $ac_executable_extensions; do
18821   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18822     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18823     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18824     break 2
18825   fi
18826 done
18827   done
18828 IFS=$as_save_IFS
18829 
18830   ;;
18831 esac
18832 fi
18833 XATTR=$ac_cv_path_XATTR
18834 if test -n "$XATTR"; then
18835   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18836 $as_echo "$XATTR" >&6; }
18837 else
18838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18839 $as_echo "no" >&6; }
18840 fi
18841 
18842 
18843   test -n "$XATTR" && break
18844 done
18845 
18846     else
18847       # If it succeeded, then it was overridden by the user. We will use it
18848       # for the tool.
18849 
18850       # First remove it from the list of overridden variables, so we can test
18851       # for unknown variables in the end.
18852       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18853 
18854       # Check if the provided tool contains a complete path.
18855       tool_specified="$XATTR"
18856       tool_basename="${tool_specified##*/}"
18857       if test "x$tool_basename" = "x$tool_specified"; then
18858         # A command without a complete path is provided, search $PATH.
18859         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5
18860 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;}
18861         # Extract the first word of "$tool_basename", so it can be a program name with args.
18862 set dummy $tool_basename; ac_word=$2
18863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18864 $as_echo_n "checking for $ac_word... " >&6; }
18865 if ${ac_cv_path_XATTR+:} false; then :
18866   $as_echo_n "(cached) " >&6
18867 else
18868   case $XATTR in
18869   [\\/]* | ?:[\\/]*)
18870   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18871   ;;
18872   *)
18873   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18874 for as_dir in $PATH
18875 do
18876   IFS=$as_save_IFS
18877   test -z "$as_dir" && as_dir=.
18878     for ac_exec_ext in '' $ac_executable_extensions; do
18879   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18880     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18881     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18882     break 2
18883   fi
18884 done
18885   done
18886 IFS=$as_save_IFS
18887 
18888   ;;
18889 esac
18890 fi
18891 XATTR=$ac_cv_path_XATTR
18892 if test -n "$XATTR"; then
18893   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18894 $as_echo "$XATTR" >&6; }
18895 else
18896   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18897 $as_echo "no" >&6; }
18898 fi
18899 
18900 
18901         if test "x$XATTR" = x; then
18902           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18903         fi
18904       else
18905         # Otherwise we believe it is a complete path. Use it as it is.
18906         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5
18907 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;}
18908         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5
18909 $as_echo_n "checking for XATTR... " >&6; }
18910         if test ! -x "$tool_specified"; then
18911           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18912 $as_echo "not found" >&6; }
18913           as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5
18914         fi
18915         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18916 $as_echo "$tool_specified" >&6; }
18917       fi
18918     fi
18919   fi
18920 
18921 
18922 
18923   if test "x$XATTR" = x; then
18924     as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5
18925   fi
18926 
18927 
18928 
18929 
18930   # Publish this variable in the help.
18931 
18932 
18933   if test "x$CODESIGN" = x; then
18934     # The variable is not set by user, try to locate tool using the code snippet
18935     for ac_prog in codesign
18936 do
18937   # Extract the first word of "$ac_prog", so it can be a program name with args.
18938 set dummy $ac_prog; ac_word=$2
18939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18940 $as_echo_n "checking for $ac_word... " >&6; }
18941 if ${ac_cv_path_CODESIGN+:} false; then :
18942   $as_echo_n "(cached) " >&6
18943 else
18944   case $CODESIGN in
18945   [\\/]* | ?:[\\/]*)
18946   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
18947   ;;
18948   *)
18949   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18950 for as_dir in $PATH
18951 do
18952   IFS=$as_save_IFS
18953   test -z "$as_dir" && as_dir=.
18954     for ac_exec_ext in '' $ac_executable_extensions; do
18955   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18956     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
18957     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18958     break 2
18959   fi
18960 done
18961   done
18962 IFS=$as_save_IFS
18963 
18964   ;;
18965 esac
18966 fi
18967 CODESIGN=$ac_cv_path_CODESIGN
18968 if test -n "$CODESIGN"; then
18969   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
18970 $as_echo "$CODESIGN" >&6; }
18971 else
18972   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18973 $as_echo "no" >&6; }
18974 fi
18975 
18976 
18977   test -n "$CODESIGN" && break
18978 done
18979 
18980   else
18981     # The variable is set, but is it from the command line or the environment?
18982 
18983     # Try to remove the string !CODESIGN! from our list.
18984     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/}
18985     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18986       # If it failed, the variable was not from the command line. Ignore it,
18987       # but warn the user (except for BASH, which is always set by the calling BASH).
18988       if test "xCODESIGN" != xBASH; then
18989         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5
18990 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;}
18991       fi
18992       # Try to locate tool using the code snippet
18993       for ac_prog in codesign
18994 do
18995   # Extract the first word of "$ac_prog", so it can be a program name with args.
18996 set dummy $ac_prog; ac_word=$2
18997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18998 $as_echo_n "checking for $ac_word... " >&6; }
18999 if ${ac_cv_path_CODESIGN+:} false; then :
19000   $as_echo_n "(cached) " >&6
19001 else
19002   case $CODESIGN in
19003   [\\/]* | ?:[\\/]*)
19004   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19005   ;;
19006   *)
19007   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19008 for as_dir in $PATH
19009 do
19010   IFS=$as_save_IFS
19011   test -z "$as_dir" && as_dir=.
19012     for ac_exec_ext in '' $ac_executable_extensions; do
19013   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19014     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19015     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19016     break 2
19017   fi
19018 done
19019   done
19020 IFS=$as_save_IFS
19021 
19022   ;;
19023 esac
19024 fi
19025 CODESIGN=$ac_cv_path_CODESIGN
19026 if test -n "$CODESIGN"; then
19027   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19028 $as_echo "$CODESIGN" >&6; }
19029 else
19030   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19031 $as_echo "no" >&6; }
19032 fi
19033 
19034 
19035   test -n "$CODESIGN" && break
19036 done
19037 
19038     else
19039       # If it succeeded, then it was overridden by the user. We will use it
19040       # for the tool.
19041 
19042       # First remove it from the list of overridden variables, so we can test
19043       # for unknown variables in the end.
19044       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19045 
19046       # Check if the provided tool contains a complete path.
19047       tool_specified="$CODESIGN"
19048       tool_basename="${tool_specified##*/}"
19049       if test "x$tool_basename" = "x$tool_specified"; then
19050         # A command without a complete path is provided, search $PATH.
19051         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5
19052 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;}
19053         # Extract the first word of "$tool_basename", so it can be a program name with args.
19054 set dummy $tool_basename; ac_word=$2
19055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19056 $as_echo_n "checking for $ac_word... " >&6; }
19057 if ${ac_cv_path_CODESIGN+:} false; then :
19058   $as_echo_n "(cached) " >&6
19059 else
19060   case $CODESIGN in
19061   [\\/]* | ?:[\\/]*)
19062   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19063   ;;
19064   *)
19065   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19066 for as_dir in $PATH
19067 do
19068   IFS=$as_save_IFS
19069   test -z "$as_dir" && as_dir=.
19070     for ac_exec_ext in '' $ac_executable_extensions; do
19071   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19072     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19073     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19074     break 2
19075   fi
19076 done
19077   done
19078 IFS=$as_save_IFS
19079 
19080   ;;
19081 esac
19082 fi
19083 CODESIGN=$ac_cv_path_CODESIGN
19084 if test -n "$CODESIGN"; then
19085   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19086 $as_echo "$CODESIGN" >&6; }
19087 else
19088   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19089 $as_echo "no" >&6; }
19090 fi
19091 
19092 
19093         if test "x$CODESIGN" = x; then
19094           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19095         fi
19096       else
19097         # Otherwise we believe it is a complete path. Use it as it is.
19098         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5
19099 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;}
19100         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5
19101 $as_echo_n "checking for CODESIGN... " >&6; }
19102         if test ! -x "$tool_specified"; then
19103           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19104 $as_echo "not found" >&6; }
19105           as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5
19106         fi
19107         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19108 $as_echo "$tool_specified" >&6; }
19109       fi
19110     fi
19111   fi
19112 
19113 
19114     if test "x$CODESIGN" != "x"; then
19115       # Verify that the openjdk_codesign certificate is present
19116       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5
19117 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; }
19118       rm -f codesign-testfile
19119       touch codesign-testfile
19120       codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN=
19121       rm -f codesign-testfile
19122       if test "x$CODESIGN" = x; then
19123         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19124 $as_echo "no" >&6; }
19125       else
19126         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19127 $as_echo "yes" >&6; }
19128       fi
19129     fi
19130   fi
19131 
19132 
19133 # Check if pkg-config is available.
19134 
19135 
19136 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
19137         if test -n "$ac_tool_prefix"; then
19138   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
19139 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
19140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19141 $as_echo_n "checking for $ac_word... " >&6; }
19142 if ${ac_cv_path_PKG_CONFIG+:} false; then :
19143   $as_echo_n "(cached) " >&6
19144 else
19145   case $PKG_CONFIG in
19146   [\\/]* | ?:[\\/]*)
19147   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
19148   ;;
19149   *)
19150   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19151 for as_dir in $PATH
19152 do
19153   IFS=$as_save_IFS
19154   test -z "$as_dir" && as_dir=.
19155     for ac_exec_ext in '' $ac_executable_extensions; do
19156   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19157     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19158     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19159     break 2
19160   fi
19161 done
19162   done
19163 IFS=$as_save_IFS
19164 
19165   ;;
19166 esac
19167 fi
19168 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
19169 if test -n "$PKG_CONFIG"; then
19170   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19171 $as_echo "$PKG_CONFIG" >&6; }
19172 else
19173   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19174 $as_echo "no" >&6; }
19175 fi
19176 
19177 
19178 fi
19179 if test -z "$ac_cv_path_PKG_CONFIG"; then
19180   ac_pt_PKG_CONFIG=$PKG_CONFIG
19181   # Extract the first word of "pkg-config", so it can be a program name with args.
19182 set dummy pkg-config; ac_word=$2
19183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19184 $as_echo_n "checking for $ac_word... " >&6; }
19185 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
19186   $as_echo_n "(cached) " >&6
19187 else
19188   case $ac_pt_PKG_CONFIG in
19189   [\\/]* | ?:[\\/]*)
19190   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
19191   ;;
19192   *)
19193   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19194 for as_dir in $PATH
19195 do
19196   IFS=$as_save_IFS
19197   test -z "$as_dir" && as_dir=.
19198     for ac_exec_ext in '' $ac_executable_extensions; do
19199   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19200     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19201     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19202     break 2
19203   fi
19204 done
19205   done
19206 IFS=$as_save_IFS
19207 
19208   ;;
19209 esac
19210 fi
19211 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
19212 if test -n "$ac_pt_PKG_CONFIG"; then
19213   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
19214 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
19215 else
19216   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19217 $as_echo "no" >&6; }
19218 fi
19219 
19220   if test "x$ac_pt_PKG_CONFIG" = x; then
19221     PKG_CONFIG=""
19222   else
19223     case $cross_compiling:$ac_tool_warned in
19224 yes:)
19225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19226 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19227 ac_tool_warned=yes ;;
19228 esac
19229     PKG_CONFIG=$ac_pt_PKG_CONFIG
19230   fi
19231 else
19232   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
19233 fi
19234 
19235 fi
19236 if test -n "$PKG_CONFIG"; then
19237         _pkg_min_version=0.9.0
19238         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
19239 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
19240         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
19241                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19242 $as_echo "yes" >&6; }
19243         else
19244                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19245 $as_echo "no" >&6; }
19246                 PKG_CONFIG=""
19247         fi
19248 
19249 fi
19250 
19251 # After basic tools have been setup, we can check build os specific details.
19252 
19253   ###############################################################################
19254 
19255   # Note that this is the build platform OS version!
19256 
19257   OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`"
19258   OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`"
19259   OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`"
19260   OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`"
19261 
19262 
19263 
19264 
19265 
19266 # Setup builddeps, for automatic downloading of tools we need.
19267 # This is needed before we can call BDEPS_CHECK_MODULE, which is done in
19268 # boot-jdk setup, but we need to have basic tools setup first.
19269 
19270 
19271 # Check whether --with-builddeps-conf was given.
19272 if test "${with_builddeps_conf+set}" = set; then :
19273   withval=$with_builddeps_conf;
19274 fi
19275 
19276 
19277 
19278 # Check whether --with-builddeps-server was given.
19279 if test "${with_builddeps_server+set}" = set; then :
19280   withval=$with_builddeps_server;
19281 fi
19282 
19283 
19284 
19285 # Check whether --with-builddeps-dir was given.
19286 if test "${with_builddeps_dir+set}" = set; then :
19287   withval=$with_builddeps_dir;
19288 else
19289   with_builddeps_dir=/localhome/builddeps
19290 fi
19291 
19292 
19293 
19294 # Check whether --with-builddeps-group was given.
19295 if test "${with_builddeps_group+set}" = set; then :
19296   withval=$with_builddeps_group;
19297 fi
19298 
19299 
19300 
19301 
19302   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19303     if test "x$with_builddeps_conf" != x; then
19304       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5
19305 $as_echo_n "checking for supplied builddeps configuration file... " >&6; }
19306       builddepsfile=$with_builddeps_conf
19307       if test -s $builddepsfile; then
19308         . $builddepsfile
19309         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5
19310 $as_echo "loaded!" >&6; }
19311       else
19312         as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5
19313       fi
19314     else
19315       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5
19316 $as_echo_n "checking for builddeps.conf files in sources...... " >&6; }
19317       builddepsfile=`mktemp`
19318       touch $builddepsfile
19319       # Put all found confs into a single file.
19320       find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile
19321       # Source the file to acquire the variables
19322       if test -s $builddepsfile; then
19323         . $builddepsfile
19324         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5
19325 $as_echo "found at least one!" >&6; }
19326       else
19327         as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5
19328       fi
19329     fi
19330     # Create build and target names that use _ instead of "-" and ".".
19331     # This is necessary to use them in variable names.
19332     build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19333     target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19334     # Extract rewrite information for build and target
19335     eval rewritten_build=\${REWRITE_${build_var}}
19336     if test "x$rewritten_build" = x; then
19337       rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME}
19338       echo Build stays the same $rewritten_build
19339     else
19340       echo Rewriting build for builddeps into $rewritten_build
19341     fi
19342     eval rewritten_target=\${REWRITE_${target_var}}
19343     if test "x$rewritten_target" = x; then
19344       rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME}
19345       echo Target stays the same $rewritten_target
19346     else
19347       echo Rewriting target for builddeps into $rewritten_target
19348     fi
19349     rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'`
19350     rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'`
19351   fi
19352   for ac_prog in 7z unzip
19353 do
19354   # Extract the first word of "$ac_prog", so it can be a program name with args.
19355 set dummy $ac_prog; ac_word=$2
19356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19357 $as_echo_n "checking for $ac_word... " >&6; }
19358 if ${ac_cv_prog_BDEPS_UNZIP+:} false; then :
19359   $as_echo_n "(cached) " >&6
19360 else
19361   if test -n "$BDEPS_UNZIP"; then
19362   ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test.
19363 else
19364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19365 for as_dir in $PATH
19366 do
19367   IFS=$as_save_IFS
19368   test -z "$as_dir" && as_dir=.
19369     for ac_exec_ext in '' $ac_executable_extensions; do
19370   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19371     ac_cv_prog_BDEPS_UNZIP="$ac_prog"
19372     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19373     break 2
19374   fi
19375 done
19376   done
19377 IFS=$as_save_IFS
19378 
19379 fi
19380 fi
19381 BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP
19382 if test -n "$BDEPS_UNZIP"; then
19383   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5
19384 $as_echo "$BDEPS_UNZIP" >&6; }
19385 else
19386   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19387 $as_echo "no" >&6; }
19388 fi
19389 
19390 
19391   test -n "$BDEPS_UNZIP" && break
19392 done
19393 
19394   if test "x$BDEPS_UNZIP" = x7z; then
19395     BDEPS_UNZIP="7z x"
19396   fi
19397 
19398   for ac_prog in wget lftp ftp
19399 do
19400   # Extract the first word of "$ac_prog", so it can be a program name with args.
19401 set dummy $ac_prog; ac_word=$2
19402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19403 $as_echo_n "checking for $ac_word... " >&6; }
19404 if ${ac_cv_prog_BDEPS_FTP+:} false; then :
19405   $as_echo_n "(cached) " >&6
19406 else
19407   if test -n "$BDEPS_FTP"; then
19408   ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test.
19409 else
19410 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19411 for as_dir in $PATH
19412 do
19413   IFS=$as_save_IFS
19414   test -z "$as_dir" && as_dir=.
19415     for ac_exec_ext in '' $ac_executable_extensions; do
19416   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19417     ac_cv_prog_BDEPS_FTP="$ac_prog"
19418     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19419     break 2
19420   fi
19421 done
19422   done
19423 IFS=$as_save_IFS
19424 
19425 fi
19426 fi
19427 BDEPS_FTP=$ac_cv_prog_BDEPS_FTP
19428 if test -n "$BDEPS_FTP"; then
19429   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5
19430 $as_echo "$BDEPS_FTP" >&6; }
19431 else
19432   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19433 $as_echo "no" >&6; }
19434 fi
19435 
19436 
19437   test -n "$BDEPS_FTP" && break
19438 done
19439 
19440 
19441 
19442 ###############################################################################
19443 #
19444 # Determine OpenJDK variants, options and version numbers.
19445 #
19446 ###############################################################################
19447 
19448 # We need build & target for this.
19449 
19450 
19451   ###############################################################################
19452   #
19453   # Should we build a JDK/JVM with headful support (ie a graphical ui)?
19454   # We always build headless support.
19455   #
19456   { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5
19457 $as_echo_n "checking headful support... " >&6; }
19458   # Check whether --enable-headful was given.
19459 if test "${enable_headful+set}" = set; then :
19460   enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful}
19461 else
19462   SUPPORT_HEADFUL=yes
19463 fi
19464 
19465 
19466   SUPPORT_HEADLESS=yes
19467   BUILD_HEADLESS="BUILD_HEADLESS:=true"
19468 
19469   if test "x$SUPPORT_HEADFUL" = xyes; then
19470     # We are building both headful and headless.
19471     headful_msg="include support for both headful and headless"
19472   fi
19473 
19474   if test "x$SUPPORT_HEADFUL" = xno; then
19475     # Thus we are building headless only.
19476     BUILD_HEADLESS="BUILD_HEADLESS:=true"
19477     headful_msg="headless only"
19478   fi
19479 
19480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5
19481 $as_echo "$headful_msg" >&6; }
19482 
19483 
19484 
19485 
19486 
19487   # Control wether Hotspot runs Queens test after build.
19488   # Check whether --enable-hotspot-test-in-build was given.
19489 if test "${enable_hotspot_test_in_build+set}" = set; then :
19490   enableval=$enable_hotspot_test_in_build;
19491 else
19492   enable_hotspot_test_in_build=no
19493 fi
19494 
19495   if test "x$enable_hotspot_test_in_build" = "xyes"; then
19496     TEST_IN_BUILD=true
19497   else
19498     TEST_IN_BUILD=false
19499   fi
19500 
19501 
19502   ###############################################################################
19503   #
19504   # Choose cacerts source file
19505   #
19506 
19507 # Check whether --with-cacerts-file was given.
19508 if test "${with_cacerts_file+set}" = set; then :
19509   withval=$with_cacerts_file;
19510 fi
19511 
19512   if test "x$with_cacerts_file" != x; then
19513     CACERTS_FILE=$with_cacerts_file
19514   else
19515     CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts
19516   fi
19517 
19518 
19519   ###############################################################################
19520   #
19521   # Enable or disable unlimited crypto
19522   #
19523   # Check whether --enable-unlimited-crypto was given.
19524 if test "${enable_unlimited_crypto+set}" = set; then :
19525   enableval=$enable_unlimited_crypto;
19526 else
19527   enable_unlimited_crypto=no
19528 fi
19529 
19530   if test "x$enable_unlimited_crypto" = "xyes"; then
19531     UNLIMITED_CRYPTO=true
19532   else
19533     UNLIMITED_CRYPTO=false
19534   fi
19535 
19536 
19537   ###############################################################################
19538   #
19539   # Enable or disable the elliptic curve crypto implementation
19540   #
19541 
19542 
19543   ###############################################################################
19544   #
19545   # --enable-rmiconnector-iiop
19546   #
19547   # Check whether --enable-rmiconnector-iiop was given.
19548 if test "${enable_rmiconnector_iiop+set}" = set; then :
19549   enableval=$enable_rmiconnector_iiop;
19550 fi
19551 
19552   if test "x$enable_rmiconnector_iiop" = "xyes"; then
19553     RMICONNECTOR_IIOP=true
19554   else
19555     RMICONNECTOR_IIOP=false
19556   fi
19557 
19558 
19559   ###############################################################################
19560   #
19561   # Compress jars
19562   #
19563   COMPRESS_JARS=false
19564 
19565 
19566 
19567 
19568   # Source the version numbers
19569   . $AUTOCONF_DIR/version-numbers
19570 
19571   # Get the settings from parameters
19572 
19573 # Check whether --with-milestone was given.
19574 if test "${with_milestone+set}" = set; then :
19575   withval=$with_milestone;
19576 fi
19577 
19578   if test "x$with_milestone" = xyes; then
19579     as_fn_error $? "Milestone must have a value" "$LINENO" 5
19580   elif test "x$with_milestone" != x; then
19581     MILESTONE="$with_milestone"
19582   fi
19583   if test "x$MILESTONE" = x; then
19584     MILESTONE=internal
19585   fi
19586 
19587 
19588 # Check whether --with-update-version was given.
19589 if test "${with_update_version+set}" = set; then :
19590   withval=$with_update_version;
19591 fi
19592 
19593   if test "x$with_update_version" = xyes; then
19594     as_fn_error $? "Update version must have a value" "$LINENO" 5
19595   elif test "x$with_update_version" != x; then
19596     JDK_UPDATE_VERSION="$with_update_version"
19597     # On macosx 10.7, it's not possible to set --with-update-version=0X due
19598     # to a bug in expr (which reduces it to just X). To work around this, we
19599     # always add a 0 to one digit update versions.
19600     if test "${#JDK_UPDATE_VERSION}" = "1"; then
19601       JDK_UPDATE_VERSION="0${JDK_UPDATE_VERSION}"
19602     fi
19603   fi
19604 
19605 
19606 # Check whether --with-user-release-suffix was given.
19607 if test "${with_user_release_suffix+set}" = set; then :
19608   withval=$with_user_release_suffix;
19609 fi
19610 
19611   if test "x$with_user_release_suffix" = xyes; then
19612     as_fn_error $? "Release suffix must have a value" "$LINENO" 5
19613   elif test "x$with_user_release_suffix" != x; then
19614     USER_RELEASE_SUFFIX="$with_user_release_suffix"
19615   fi
19616 
19617 
19618 # Check whether --with-build-number was given.
19619 if test "${with_build_number+set}" = set; then :
19620   withval=$with_build_number;
19621 fi
19622 
19623   if test "x$with_build_number" = xyes; then
19624     as_fn_error $? "Build number must have a value" "$LINENO" 5
19625   elif test "x$with_build_number" != x; then
19626     JDK_BUILD_NUMBER="$with_build_number"
19627   fi
19628   # Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
19629   if test "x$JDK_BUILD_NUMBER" = x; then
19630     JDK_BUILD_NUMBER=b00
19631     if test "x$USER_RELEASE_SUFFIX" = x; then
19632       BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
19633       # Avoid [:alnum:] since it depends on the locale.
19634       CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
19635       USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19636     fi
19637   fi
19638 
19639   # Now set the JDK version, milestone, build number etc.
19640 
19641 
19642 
19643 
19644 
19645 
19646 
19647 
19648 
19649 
19650 
19651 
19652 
19653 
19654 
19655   COPYRIGHT_YEAR=`date +'%Y'`
19656 
19657 
19658   if test "x$JDK_UPDATE_VERSION" != x; then
19659     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}"
19660   else
19661     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}"
19662   fi
19663 
19664 
19665   COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'`
19666 
19667 
19668 
19669 ###############################################################################
19670 #
19671 # Setup BootJDK, used to bootstrap the build.
19672 #
19673 ###############################################################################
19674 
19675 
19676   BOOT_JDK_FOUND=no
19677 
19678 # Check whether --with-boot-jdk was given.
19679 if test "${with_boot_jdk+set}" = set; then :
19680   withval=$with_boot_jdk;
19681 fi
19682 
19683 
19684   # We look for the Boot JDK through various means, going from more certain to
19685   # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if
19686   # we detected something (if so, the path to the jdk is in BOOT_JDK). But we
19687   # must check if this is indeed valid; otherwise we'll continue looking.
19688 
19689   # Test: Is bootjdk explicitely set by command line arguments?
19690 
19691   if test "x$BOOT_JDK_FOUND" = xno; then
19692     # Now execute the test
19693 
19694   if test "x$with_boot_jdk" != x; then
19695     BOOT_JDK=$with_boot_jdk
19696     BOOT_JDK_FOUND=maybe
19697     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5
19698 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;}
19699   fi
19700 
19701 
19702     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
19703     if test "x$BOOT_JDK_FOUND" = xmaybe; then
19704       # Do we have a bin/java?
19705       if test ! -x "$BOOT_JDK/bin/java"; then
19706         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
19707 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
19708         BOOT_JDK_FOUND=no
19709       else
19710         # Do we have a bin/javac?
19711         if test ! -x "$BOOT_JDK/bin/javac"; then
19712           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
19713 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
19714           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
19715 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
19716           BOOT_JDK_FOUND=no
19717         else
19718           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
19719           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
19720             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
19721 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
19722             BOOT_JDK_FOUND=no
19723           else
19724             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
19725             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
19726 
19727             # Extra M4 quote needed to protect [] in grep expression.
19728             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
19729             if test "x$FOUND_CORRECT_VERSION" = x; then
19730               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
19731 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
19732               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
19733 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
19734               BOOT_JDK_FOUND=no
19735             else
19736               # We're done! :-)
19737               BOOT_JDK_FOUND=yes
19738 
19739   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19740 
19741   # Input might be given as Windows format, start by converting to
19742   # unix format.
19743   path="$BOOT_JDK"
19744   new_path=`$CYGPATH -u "$path"`
19745 
19746   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
19747   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
19748   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
19749   # "foo.exe" is OK but "foo" is an error.
19750   #
19751   # This test is therefore slightly more accurate than "test -f" to check for file precense.
19752   # It is also a way to make sure we got the proper file name for the real test later on.
19753   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
19754   if test "x$test_shortpath" = x; then
19755     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19756 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19757     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
19758   fi
19759 
19760   # Call helper function which possibly converts this using DOS-style short mode.
19761   # If so, the updated path is stored in $new_path.
19762 
19763   input_path="$new_path"
19764   # Check if we need to convert this using DOS-style short mode. If the path
19765   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19766   # take no chances and rewrite it.
19767   # Note: m4 eats our [], so we need to use [ and ] instead.
19768   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
19769   if test "x$has_forbidden_chars" != x; then
19770     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19771     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
19772     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
19773     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
19774       # Going to short mode and back again did indeed matter. Since short mode is
19775       # case insensitive, let's make it lowercase to improve readability.
19776       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19777       # Now convert it back to Unix-stile (cygpath)
19778       input_path=`$CYGPATH -u "$shortmode_path"`
19779       new_path="$input_path"
19780     fi
19781   fi
19782 
19783   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
19784   if test "x$test_cygdrive_prefix" = x; then
19785     # As a simple fix, exclude /usr/bin since it's not a real path.
19786     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
19787       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
19788       # a path prefixed by /cygdrive for fixpath to work.
19789       new_path="$CYGWIN_ROOT_PATH$input_path"
19790     fi
19791   fi
19792 
19793 
19794   if test "x$path" != "x$new_path"; then
19795     BOOT_JDK="$new_path"
19796     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19797 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19798   fi
19799 
19800   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19801 
19802   path="$BOOT_JDK"
19803   has_colon=`$ECHO $path | $GREP ^.:`
19804   new_path="$path"
19805   if test "x$has_colon" = x; then
19806     # Not in mixed or Windows style, start by that.
19807     new_path=`cmd //c echo $path`
19808   fi
19809 
19810 
19811   input_path="$new_path"
19812   # Check if we need to convert this using DOS-style short mode. If the path
19813   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19814   # take no chances and rewrite it.
19815   # Note: m4 eats our [], so we need to use [ and ] instead.
19816   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
19817   if test "x$has_forbidden_chars" != x; then
19818     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19819     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19820   fi
19821 
19822 
19823   windows_path="$new_path"
19824   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19825     unix_path=`$CYGPATH -u "$windows_path"`
19826     new_path="$unix_path"
19827   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19828     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
19829     new_path="$unix_path"
19830   fi
19831 
19832   if test "x$path" != "x$new_path"; then
19833     BOOT_JDK="$new_path"
19834     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19835 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19836   fi
19837 
19838   # Save the first 10 bytes of this path to the storage, so fixpath can work.
19839   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
19840 
19841   else
19842     # We're on a posix platform. Hooray! :)
19843     path="$BOOT_JDK"
19844     has_space=`$ECHO "$path" | $GREP " "`
19845     if test "x$has_space" != x; then
19846       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19847 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19848       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
19849     fi
19850 
19851     # Use eval to expand a potential ~
19852     eval path="$path"
19853     if test ! -f "$path" && test ! -d "$path"; then
19854       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
19855     fi
19856 
19857     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
19858   fi
19859 
19860               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
19861 $as_echo_n "checking for Boot JDK... " >&6; }
19862               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
19863 $as_echo "$BOOT_JDK" >&6; }
19864               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
19865 $as_echo_n "checking Boot JDK version... " >&6; }
19866               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
19867               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
19868 $as_echo "$BOOT_JDK_VERSION" >&6; }
19869             fi # end check jdk version
19870           fi # end check rt.jar
19871         fi # end check javac
19872       fi # end check java
19873     fi # end check boot jdk found
19874   fi
19875 
19876   if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then
19877     # Having specified an argument which is incorrect will produce an instant failure;
19878     # we should not go on looking
19879     as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5
19880   fi
19881 
19882   # Test: Is bootjdk available from builddeps?
19883 
19884   if test "x$BOOT_JDK_FOUND" = xno; then
19885     # Now execute the test
19886 
19887 
19888 
19889   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19890     # Source the builddeps file again, to make sure it uses the latest variables!
19891     . $builddepsfile
19892     # Look for a target and build machine specific resource!
19893     eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
19894     if test "x$resource" = x; then
19895       # Ok, lets instead look for a target specific resource
19896       eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}}
19897     fi
19898     if test "x$resource" = x; then
19899       # Ok, lets instead look for a build specific resource
19900       eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}}
19901     fi
19902     if test "x$resource" = x; then
19903       # Ok, lets instead look for a generic resource
19904       # (The bootjdk comes from M4 and not the shell, thus no need for eval here.)
19905       resource=${builddep_bootjdk}
19906     fi
19907     if test "x$resource" != x; then
19908       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5
19909 $as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;}
19910       # If the resource in the builddeps.conf file is an existing directory,
19911       # for example /java/linux/cups
19912       if test -d ${resource}; then
19913         depdir=${resource}
19914       else
19915 
19916   # bootjdk is for example mymodule
19917   # $resource is for example libs/general/libmymod_1_2_3.zip
19918   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
19919   # $with_builddeps_dir is for example /localhome/builddeps
19920   # depdir is the name of the variable into which we store the depdir, eg MYMOD
19921   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
19922   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
19923   filename=`basename $resource`
19924   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
19925   filebase=${filename%%.*}
19926   extension=${filename#*.}
19927   installdir=$with_builddeps_dir/$filebase
19928   if test ! -f $installdir/$filename.unpacked; then
19929     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5
19930 $as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;}
19931     if test ! -d $installdir; then
19932       mkdir -p $installdir
19933     fi
19934     if test ! -d $installdir; then
19935       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
19936     fi
19937     tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX`
19938     touch $tmpfile
19939     if test ! -f $tmpfile; then
19940       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
19941     fi
19942 
19943   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
19944   # $tmpfile is the local file name for the downloaded file.
19945   VALID_TOOL=no
19946   if test "x$BDEPS_FTP" = xwget; then
19947     VALID_TOOL=yes
19948     wget -O $tmpfile $with_builddeps_server/$resource
19949   fi
19950   if test "x$BDEPS_FTP" = xlftp; then
19951     VALID_TOOL=yes
19952     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
19953   fi
19954   if test "x$BDEPS_FTP" = xftp; then
19955     VALID_TOOL=yes
19956     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
19957     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
19958     FTPUSERPWD=${FTPSERVER%%@*}
19959     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
19960       FTPUSER=${userpwd%%:*}
19961       FTPPWD=${userpwd#*@}
19962       FTPSERVER=${FTPSERVER#*@}
19963     else
19964       FTPUSER=ftp
19965       FTPPWD=ftp
19966     fi
19967     # the "pass" command does not work on some
19968     # ftp clients (read ftp.exe) but if it works,
19969     # passive mode is better!
19970     ( \
19971         echo "user $FTPUSER $FTPPWD"        ; \
19972         echo "pass"                         ; \
19973         echo "bin"                          ; \
19974         echo "get $FTPPATH $tmpfile"              ; \
19975     ) | ftp -in $FTPSERVER
19976   fi
19977   if test "x$VALID_TOOL" != xyes; then
19978     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
19979   fi
19980 
19981     mv $tmpfile $installdir/$filename
19982     if test ! -s $installdir/$filename; then
19983       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
19984     fi
19985     case "$extension" in
19986       zip)  echo "Unzipping $installdir/$filename..."
19987         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
19988         ;;
19989       tar.gz) echo "Untaring $installdir/$filename..."
19990         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19991         ;;
19992       tgz) echo "Untaring $installdir/$filename..."
19993         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19994         ;;
19995       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
19996         ;;
19997     esac
19998   fi
19999   if test -f $installdir/$filename.unpacked; then
20000     depdir=$installdir
20001   fi
20002 
20003       fi
20004       # Source the builddeps file again, because in the previous command, the depdir
20005       # was updated to point at the current build dependency install directory.
20006       . $builddepsfile
20007       # Now extract variables from the builddeps.conf files.
20008       theroot=${builddep_bootjdk_ROOT}
20009       thecflags=${builddep_bootjdk_CFLAGS}
20010       thelibs=${builddep_bootjdk_LIBS}
20011       if test "x$depdir" = x; then
20012         as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5
20013       fi
20014       BOOT_JDK=$depdir
20015       if test "x$theroot" != x; then
20016         BOOT_JDK="$theroot"
20017       fi
20018       if test "x$thecflags" != x; then
20019         BOOT_JDK_CFLAGS="$thecflags"
20020       fi
20021       if test "x$thelibs" != x; then
20022         BOOT_JDK_LIBS="$thelibs"
20023       fi
20024       BOOT_JDK_FOUND=maybe
20025       else BOOT_JDK_FOUND=no
20026 
20027     fi
20028     else BOOT_JDK_FOUND=no
20029 
20030   fi
20031 
20032 
20033 
20034     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20035     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20036       # Do we have a bin/java?
20037       if test ! -x "$BOOT_JDK/bin/java"; then
20038         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20039 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20040         BOOT_JDK_FOUND=no
20041       else
20042         # Do we have a bin/javac?
20043         if test ! -x "$BOOT_JDK/bin/javac"; then
20044           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20045 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20046           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20047 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20048           BOOT_JDK_FOUND=no
20049         else
20050           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20051           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20052             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20053 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20054             BOOT_JDK_FOUND=no
20055           else
20056             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20057             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20058 
20059             # Extra M4 quote needed to protect [] in grep expression.
20060             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20061             if test "x$FOUND_CORRECT_VERSION" = x; then
20062               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20063 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20064               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20065 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20066               BOOT_JDK_FOUND=no
20067             else
20068               # We're done! :-)
20069               BOOT_JDK_FOUND=yes
20070 
20071   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20072 
20073   # Input might be given as Windows format, start by converting to
20074   # unix format.
20075   path="$BOOT_JDK"
20076   new_path=`$CYGPATH -u "$path"`
20077 
20078   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20079   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20080   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20081   # "foo.exe" is OK but "foo" is an error.
20082   #
20083   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20084   # It is also a way to make sure we got the proper file name for the real test later on.
20085   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20086   if test "x$test_shortpath" = x; then
20087     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20088 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20089     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20090   fi
20091 
20092   # Call helper function which possibly converts this using DOS-style short mode.
20093   # If so, the updated path is stored in $new_path.
20094 
20095   input_path="$new_path"
20096   # Check if we need to convert this using DOS-style short mode. If the path
20097   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20098   # take no chances and rewrite it.
20099   # Note: m4 eats our [], so we need to use [ and ] instead.
20100   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20101   if test "x$has_forbidden_chars" != x; then
20102     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20103     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20104     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20105     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20106       # Going to short mode and back again did indeed matter. Since short mode is
20107       # case insensitive, let's make it lowercase to improve readability.
20108       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20109       # Now convert it back to Unix-stile (cygpath)
20110       input_path=`$CYGPATH -u "$shortmode_path"`
20111       new_path="$input_path"
20112     fi
20113   fi
20114 
20115   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20116   if test "x$test_cygdrive_prefix" = x; then
20117     # As a simple fix, exclude /usr/bin since it's not a real path.
20118     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20119       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20120       # a path prefixed by /cygdrive for fixpath to work.
20121       new_path="$CYGWIN_ROOT_PATH$input_path"
20122     fi
20123   fi
20124 
20125 
20126   if test "x$path" != "x$new_path"; then
20127     BOOT_JDK="$new_path"
20128     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20129 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20130   fi
20131 
20132   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20133 
20134   path="$BOOT_JDK"
20135   has_colon=`$ECHO $path | $GREP ^.:`
20136   new_path="$path"
20137   if test "x$has_colon" = x; then
20138     # Not in mixed or Windows style, start by that.
20139     new_path=`cmd //c echo $path`
20140   fi
20141 
20142 
20143   input_path="$new_path"
20144   # Check if we need to convert this using DOS-style short mode. If the path
20145   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20146   # take no chances and rewrite it.
20147   # Note: m4 eats our [], so we need to use [ and ] instead.
20148   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20149   if test "x$has_forbidden_chars" != x; then
20150     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20151     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20152   fi
20153 
20154 
20155   windows_path="$new_path"
20156   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20157     unix_path=`$CYGPATH -u "$windows_path"`
20158     new_path="$unix_path"
20159   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20160     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20161     new_path="$unix_path"
20162   fi
20163 
20164   if test "x$path" != "x$new_path"; then
20165     BOOT_JDK="$new_path"
20166     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20167 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20168   fi
20169 
20170   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20171   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20172 
20173   else
20174     # We're on a posix platform. Hooray! :)
20175     path="$BOOT_JDK"
20176     has_space=`$ECHO "$path" | $GREP " "`
20177     if test "x$has_space" != x; then
20178       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20179 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20180       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20181     fi
20182 
20183     # Use eval to expand a potential ~
20184     eval path="$path"
20185     if test ! -f "$path" && test ! -d "$path"; then
20186       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20187     fi
20188 
20189     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20190   fi
20191 
20192               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20193 $as_echo_n "checking for Boot JDK... " >&6; }
20194               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20195 $as_echo "$BOOT_JDK" >&6; }
20196               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20197 $as_echo_n "checking Boot JDK version... " >&6; }
20198               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20199               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20200 $as_echo "$BOOT_JDK_VERSION" >&6; }
20201             fi # end check jdk version
20202           fi # end check rt.jar
20203         fi # end check javac
20204       fi # end check java
20205     fi # end check boot jdk found
20206   fi
20207 
20208 
20209   # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
20210 
20211   if test "x$BOOT_JDK_FOUND" = xno; then
20212     # Now execute the test
20213 
20214   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
20215     # First check at user selected default
20216 
20217   if test "x$BOOT_JDK_FOUND" = xno; then
20218     # Now execute the test
20219 
20220   if test -x /usr/libexec/java_home; then
20221     BOOT_JDK=`/usr/libexec/java_home `
20222     BOOT_JDK_FOUND=maybe
20223     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5
20224 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;}
20225   fi
20226 
20227 
20228     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20229     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20230       # Do we have a bin/java?
20231       if test ! -x "$BOOT_JDK/bin/java"; then
20232         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20233 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20234         BOOT_JDK_FOUND=no
20235       else
20236         # Do we have a bin/javac?
20237         if test ! -x "$BOOT_JDK/bin/javac"; then
20238           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20239 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20240           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20241 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20242           BOOT_JDK_FOUND=no
20243         else
20244           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20245           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20246             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20247 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20248             BOOT_JDK_FOUND=no
20249           else
20250             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20251             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20252 
20253             # Extra M4 quote needed to protect [] in grep expression.
20254             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20255             if test "x$FOUND_CORRECT_VERSION" = x; then
20256               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20257 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20258               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20259 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20260               BOOT_JDK_FOUND=no
20261             else
20262               # We're done! :-)
20263               BOOT_JDK_FOUND=yes
20264 
20265   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20266 
20267   # Input might be given as Windows format, start by converting to
20268   # unix format.
20269   path="$BOOT_JDK"
20270   new_path=`$CYGPATH -u "$path"`
20271 
20272   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20273   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20274   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20275   # "foo.exe" is OK but "foo" is an error.
20276   #
20277   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20278   # It is also a way to make sure we got the proper file name for the real test later on.
20279   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20280   if test "x$test_shortpath" = x; then
20281     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20282 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20283     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20284   fi
20285 
20286   # Call helper function which possibly converts this using DOS-style short mode.
20287   # If so, the updated path is stored in $new_path.
20288 
20289   input_path="$new_path"
20290   # Check if we need to convert this using DOS-style short mode. If the path
20291   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20292   # take no chances and rewrite it.
20293   # Note: m4 eats our [], so we need to use [ and ] instead.
20294   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20295   if test "x$has_forbidden_chars" != x; then
20296     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20297     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20298     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20299     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20300       # Going to short mode and back again did indeed matter. Since short mode is
20301       # case insensitive, let's make it lowercase to improve readability.
20302       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20303       # Now convert it back to Unix-stile (cygpath)
20304       input_path=`$CYGPATH -u "$shortmode_path"`
20305       new_path="$input_path"
20306     fi
20307   fi
20308 
20309   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20310   if test "x$test_cygdrive_prefix" = x; then
20311     # As a simple fix, exclude /usr/bin since it's not a real path.
20312     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20313       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20314       # a path prefixed by /cygdrive for fixpath to work.
20315       new_path="$CYGWIN_ROOT_PATH$input_path"
20316     fi
20317   fi
20318 
20319 
20320   if test "x$path" != "x$new_path"; then
20321     BOOT_JDK="$new_path"
20322     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20323 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20324   fi
20325 
20326   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20327 
20328   path="$BOOT_JDK"
20329   has_colon=`$ECHO $path | $GREP ^.:`
20330   new_path="$path"
20331   if test "x$has_colon" = x; then
20332     # Not in mixed or Windows style, start by that.
20333     new_path=`cmd //c echo $path`
20334   fi
20335 
20336 
20337   input_path="$new_path"
20338   # Check if we need to convert this using DOS-style short mode. If the path
20339   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20340   # take no chances and rewrite it.
20341   # Note: m4 eats our [], so we need to use [ and ] instead.
20342   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20343   if test "x$has_forbidden_chars" != x; then
20344     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20345     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20346   fi
20347 
20348 
20349   windows_path="$new_path"
20350   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20351     unix_path=`$CYGPATH -u "$windows_path"`
20352     new_path="$unix_path"
20353   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20354     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20355     new_path="$unix_path"
20356   fi
20357 
20358   if test "x$path" != "x$new_path"; then
20359     BOOT_JDK="$new_path"
20360     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20361 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20362   fi
20363 
20364   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20365   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20366 
20367   else
20368     # We're on a posix platform. Hooray! :)
20369     path="$BOOT_JDK"
20370     has_space=`$ECHO "$path" | $GREP " "`
20371     if test "x$has_space" != x; then
20372       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20373 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20374       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20375     fi
20376 
20377     # Use eval to expand a potential ~
20378     eval path="$path"
20379     if test ! -f "$path" && test ! -d "$path"; then
20380       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20381     fi
20382 
20383     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20384   fi
20385 
20386               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20387 $as_echo_n "checking for Boot JDK... " >&6; }
20388               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20389 $as_echo "$BOOT_JDK" >&6; }
20390               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20391 $as_echo_n "checking Boot JDK version... " >&6; }
20392               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20393               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20394 $as_echo "$BOOT_JDK_VERSION" >&6; }
20395             fi # end check jdk version
20396           fi # end check rt.jar
20397         fi # end check javac
20398       fi # end check java
20399     fi # end check boot jdk found
20400   fi
20401 
20402     # If that did not work out (e.g. too old), try explicit versions instead
20403 
20404   if test "x$BOOT_JDK_FOUND" = xno; then
20405     # Now execute the test
20406 
20407   if test -x /usr/libexec/java_home; then
20408     BOOT_JDK=`/usr/libexec/java_home -v 1.9`
20409     BOOT_JDK_FOUND=maybe
20410     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5
20411 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;}
20412   fi
20413 
20414 
20415     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20416     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20417       # Do we have a bin/java?
20418       if test ! -x "$BOOT_JDK/bin/java"; then
20419         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20420 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20421         BOOT_JDK_FOUND=no
20422       else
20423         # Do we have a bin/javac?
20424         if test ! -x "$BOOT_JDK/bin/javac"; then
20425           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20426 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20427           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20428 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20429           BOOT_JDK_FOUND=no
20430         else
20431           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20432           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20433             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20434 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20435             BOOT_JDK_FOUND=no
20436           else
20437             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20438             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20439 
20440             # Extra M4 quote needed to protect [] in grep expression.
20441             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20442             if test "x$FOUND_CORRECT_VERSION" = x; then
20443               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20444 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20445               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20446 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20447               BOOT_JDK_FOUND=no
20448             else
20449               # We're done! :-)
20450               BOOT_JDK_FOUND=yes
20451 
20452   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20453 
20454   # Input might be given as Windows format, start by converting to
20455   # unix format.
20456   path="$BOOT_JDK"
20457   new_path=`$CYGPATH -u "$path"`
20458 
20459   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20460   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20461   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20462   # "foo.exe" is OK but "foo" is an error.
20463   #
20464   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20465   # It is also a way to make sure we got the proper file name for the real test later on.
20466   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20467   if test "x$test_shortpath" = x; then
20468     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20469 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20470     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20471   fi
20472 
20473   # Call helper function which possibly converts this using DOS-style short mode.
20474   # If so, the updated path is stored in $new_path.
20475 
20476   input_path="$new_path"
20477   # Check if we need to convert this using DOS-style short mode. If the path
20478   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20479   # take no chances and rewrite it.
20480   # Note: m4 eats our [], so we need to use [ and ] instead.
20481   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20482   if test "x$has_forbidden_chars" != x; then
20483     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20484     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20485     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20486     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20487       # Going to short mode and back again did indeed matter. Since short mode is
20488       # case insensitive, let's make it lowercase to improve readability.
20489       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20490       # Now convert it back to Unix-stile (cygpath)
20491       input_path=`$CYGPATH -u "$shortmode_path"`
20492       new_path="$input_path"
20493     fi
20494   fi
20495 
20496   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20497   if test "x$test_cygdrive_prefix" = x; then
20498     # As a simple fix, exclude /usr/bin since it's not a real path.
20499     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20500       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20501       # a path prefixed by /cygdrive for fixpath to work.
20502       new_path="$CYGWIN_ROOT_PATH$input_path"
20503     fi
20504   fi
20505 
20506 
20507   if test "x$path" != "x$new_path"; then
20508     BOOT_JDK="$new_path"
20509     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20510 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20511   fi
20512 
20513   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20514 
20515   path="$BOOT_JDK"
20516   has_colon=`$ECHO $path | $GREP ^.:`
20517   new_path="$path"
20518   if test "x$has_colon" = x; then
20519     # Not in mixed or Windows style, start by that.
20520     new_path=`cmd //c echo $path`
20521   fi
20522 
20523 
20524   input_path="$new_path"
20525   # Check if we need to convert this using DOS-style short mode. If the path
20526   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20527   # take no chances and rewrite it.
20528   # Note: m4 eats our [], so we need to use [ and ] instead.
20529   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20530   if test "x$has_forbidden_chars" != x; then
20531     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20532     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20533   fi
20534 
20535 
20536   windows_path="$new_path"
20537   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20538     unix_path=`$CYGPATH -u "$windows_path"`
20539     new_path="$unix_path"
20540   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20541     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20542     new_path="$unix_path"
20543   fi
20544 
20545   if test "x$path" != "x$new_path"; then
20546     BOOT_JDK="$new_path"
20547     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20548 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20549   fi
20550 
20551   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20552   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20553 
20554   else
20555     # We're on a posix platform. Hooray! :)
20556     path="$BOOT_JDK"
20557     has_space=`$ECHO "$path" | $GREP " "`
20558     if test "x$has_space" != x; then
20559       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20560 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20561       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20562     fi
20563 
20564     # Use eval to expand a potential ~
20565     eval path="$path"
20566     if test ! -f "$path" && test ! -d "$path"; then
20567       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20568     fi
20569 
20570     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20571   fi
20572 
20573               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20574 $as_echo_n "checking for Boot JDK... " >&6; }
20575               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20576 $as_echo "$BOOT_JDK" >&6; }
20577               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20578 $as_echo_n "checking Boot JDK version... " >&6; }
20579               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20580               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20581 $as_echo "$BOOT_JDK_VERSION" >&6; }
20582             fi # end check jdk version
20583           fi # end check rt.jar
20584         fi # end check javac
20585       fi # end check java
20586     fi # end check boot jdk found
20587   fi
20588 
20589 
20590   if test "x$BOOT_JDK_FOUND" = xno; then
20591     # Now execute the test
20592 
20593   if test -x /usr/libexec/java_home; then
20594     BOOT_JDK=`/usr/libexec/java_home -v 1.8`
20595     BOOT_JDK_FOUND=maybe
20596     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5
20597 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;}
20598   fi
20599 
20600 
20601     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20602     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20603       # Do we have a bin/java?
20604       if test ! -x "$BOOT_JDK/bin/java"; then
20605         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20606 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20607         BOOT_JDK_FOUND=no
20608       else
20609         # Do we have a bin/javac?
20610         if test ! -x "$BOOT_JDK/bin/javac"; then
20611           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20612 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20613           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20614 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20615           BOOT_JDK_FOUND=no
20616         else
20617           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20618           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20619             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20620 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20621             BOOT_JDK_FOUND=no
20622           else
20623             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20624             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20625 
20626             # Extra M4 quote needed to protect [] in grep expression.
20627             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20628             if test "x$FOUND_CORRECT_VERSION" = x; then
20629               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20630 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20631               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20632 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20633               BOOT_JDK_FOUND=no
20634             else
20635               # We're done! :-)
20636               BOOT_JDK_FOUND=yes
20637 
20638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20639 
20640   # Input might be given as Windows format, start by converting to
20641   # unix format.
20642   path="$BOOT_JDK"
20643   new_path=`$CYGPATH -u "$path"`
20644 
20645   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20646   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20647   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20648   # "foo.exe" is OK but "foo" is an error.
20649   #
20650   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20651   # It is also a way to make sure we got the proper file name for the real test later on.
20652   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20653   if test "x$test_shortpath" = x; then
20654     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20655 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20656     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20657   fi
20658 
20659   # Call helper function which possibly converts this using DOS-style short mode.
20660   # If so, the updated path is stored in $new_path.
20661 
20662   input_path="$new_path"
20663   # Check if we need to convert this using DOS-style short mode. If the path
20664   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20665   # take no chances and rewrite it.
20666   # Note: m4 eats our [], so we need to use [ and ] instead.
20667   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20668   if test "x$has_forbidden_chars" != x; then
20669     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20670     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20671     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20672     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20673       # Going to short mode and back again did indeed matter. Since short mode is
20674       # case insensitive, let's make it lowercase to improve readability.
20675       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20676       # Now convert it back to Unix-stile (cygpath)
20677       input_path=`$CYGPATH -u "$shortmode_path"`
20678       new_path="$input_path"
20679     fi
20680   fi
20681 
20682   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20683   if test "x$test_cygdrive_prefix" = x; then
20684     # As a simple fix, exclude /usr/bin since it's not a real path.
20685     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20686       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20687       # a path prefixed by /cygdrive for fixpath to work.
20688       new_path="$CYGWIN_ROOT_PATH$input_path"
20689     fi
20690   fi
20691 
20692 
20693   if test "x$path" != "x$new_path"; then
20694     BOOT_JDK="$new_path"
20695     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20696 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20697   fi
20698 
20699   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20700 
20701   path="$BOOT_JDK"
20702   has_colon=`$ECHO $path | $GREP ^.:`
20703   new_path="$path"
20704   if test "x$has_colon" = x; then
20705     # Not in mixed or Windows style, start by that.
20706     new_path=`cmd //c echo $path`
20707   fi
20708 
20709 
20710   input_path="$new_path"
20711   # Check if we need to convert this using DOS-style short mode. If the path
20712   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20713   # take no chances and rewrite it.
20714   # Note: m4 eats our [], so we need to use [ and ] instead.
20715   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20716   if test "x$has_forbidden_chars" != x; then
20717     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20718     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20719   fi
20720 
20721 
20722   windows_path="$new_path"
20723   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20724     unix_path=`$CYGPATH -u "$windows_path"`
20725     new_path="$unix_path"
20726   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20727     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20728     new_path="$unix_path"
20729   fi
20730 
20731   if test "x$path" != "x$new_path"; then
20732     BOOT_JDK="$new_path"
20733     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20734 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20735   fi
20736 
20737   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20738   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20739 
20740   else
20741     # We're on a posix platform. Hooray! :)
20742     path="$BOOT_JDK"
20743     has_space=`$ECHO "$path" | $GREP " "`
20744     if test "x$has_space" != x; then
20745       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20746 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20747       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20748     fi
20749 
20750     # Use eval to expand a potential ~
20751     eval path="$path"
20752     if test ! -f "$path" && test ! -d "$path"; then
20753       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20754     fi
20755 
20756     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20757   fi
20758 
20759               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20760 $as_echo_n "checking for Boot JDK... " >&6; }
20761               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20762 $as_echo "$BOOT_JDK" >&6; }
20763               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20764 $as_echo_n "checking Boot JDK version... " >&6; }
20765               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20766               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20767 $as_echo "$BOOT_JDK_VERSION" >&6; }
20768             fi # end check jdk version
20769           fi # end check rt.jar
20770         fi # end check javac
20771       fi # end check java
20772     fi # end check boot jdk found
20773   fi
20774 
20775 
20776   if test "x$BOOT_JDK_FOUND" = xno; then
20777     # Now execute the test
20778 
20779   if test -x /usr/libexec/java_home; then
20780     BOOT_JDK=`/usr/libexec/java_home -v 1.7`
20781     BOOT_JDK_FOUND=maybe
20782     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5
20783 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;}
20784   fi
20785 
20786 
20787     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20788     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20789       # Do we have a bin/java?
20790       if test ! -x "$BOOT_JDK/bin/java"; then
20791         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20792 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20793         BOOT_JDK_FOUND=no
20794       else
20795         # Do we have a bin/javac?
20796         if test ! -x "$BOOT_JDK/bin/javac"; then
20797           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20798 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20799           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20800 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20801           BOOT_JDK_FOUND=no
20802         else
20803           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20804           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20805             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20806 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20807             BOOT_JDK_FOUND=no
20808           else
20809             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20810             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20811 
20812             # Extra M4 quote needed to protect [] in grep expression.
20813             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20814             if test "x$FOUND_CORRECT_VERSION" = x; then
20815               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20816 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20817               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20818 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20819               BOOT_JDK_FOUND=no
20820             else
20821               # We're done! :-)
20822               BOOT_JDK_FOUND=yes
20823 
20824   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20825 
20826   # Input might be given as Windows format, start by converting to
20827   # unix format.
20828   path="$BOOT_JDK"
20829   new_path=`$CYGPATH -u "$path"`
20830 
20831   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20832   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20833   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20834   # "foo.exe" is OK but "foo" is an error.
20835   #
20836   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20837   # It is also a way to make sure we got the proper file name for the real test later on.
20838   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20839   if test "x$test_shortpath" = x; then
20840     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20841 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20842     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20843   fi
20844 
20845   # Call helper function which possibly converts this using DOS-style short mode.
20846   # If so, the updated path is stored in $new_path.
20847 
20848   input_path="$new_path"
20849   # Check if we need to convert this using DOS-style short mode. If the path
20850   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20851   # take no chances and rewrite it.
20852   # Note: m4 eats our [], so we need to use [ and ] instead.
20853   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20854   if test "x$has_forbidden_chars" != x; then
20855     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20856     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20857     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20858     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20859       # Going to short mode and back again did indeed matter. Since short mode is
20860       # case insensitive, let's make it lowercase to improve readability.
20861       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20862       # Now convert it back to Unix-stile (cygpath)
20863       input_path=`$CYGPATH -u "$shortmode_path"`
20864       new_path="$input_path"
20865     fi
20866   fi
20867 
20868   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20869   if test "x$test_cygdrive_prefix" = x; then
20870     # As a simple fix, exclude /usr/bin since it's not a real path.
20871     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20872       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20873       # a path prefixed by /cygdrive for fixpath to work.
20874       new_path="$CYGWIN_ROOT_PATH$input_path"
20875     fi
20876   fi
20877 
20878 
20879   if test "x$path" != "x$new_path"; then
20880     BOOT_JDK="$new_path"
20881     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20882 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20883   fi
20884 
20885   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20886 
20887   path="$BOOT_JDK"
20888   has_colon=`$ECHO $path | $GREP ^.:`
20889   new_path="$path"
20890   if test "x$has_colon" = x; then
20891     # Not in mixed or Windows style, start by that.
20892     new_path=`cmd //c echo $path`
20893   fi
20894 
20895 
20896   input_path="$new_path"
20897   # Check if we need to convert this using DOS-style short mode. If the path
20898   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20899   # take no chances and rewrite it.
20900   # Note: m4 eats our [], so we need to use [ and ] instead.
20901   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20902   if test "x$has_forbidden_chars" != x; then
20903     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20904     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20905   fi
20906 
20907 
20908   windows_path="$new_path"
20909   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20910     unix_path=`$CYGPATH -u "$windows_path"`
20911     new_path="$unix_path"
20912   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20913     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20914     new_path="$unix_path"
20915   fi
20916 
20917   if test "x$path" != "x$new_path"; then
20918     BOOT_JDK="$new_path"
20919     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20920 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20921   fi
20922 
20923   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20924   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20925 
20926   else
20927     # We're on a posix platform. Hooray! :)
20928     path="$BOOT_JDK"
20929     has_space=`$ECHO "$path" | $GREP " "`
20930     if test "x$has_space" != x; then
20931       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20932 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20933       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20934     fi
20935 
20936     # Use eval to expand a potential ~
20937     eval path="$path"
20938     if test ! -f "$path" && test ! -d "$path"; then
20939       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20940     fi
20941 
20942     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20943   fi
20944 
20945               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20946 $as_echo_n "checking for Boot JDK... " >&6; }
20947               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20948 $as_echo "$BOOT_JDK" >&6; }
20949               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20950 $as_echo_n "checking Boot JDK version... " >&6; }
20951               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20952               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20953 $as_echo "$BOOT_JDK_VERSION" >&6; }
20954             fi # end check jdk version
20955           fi # end check rt.jar
20956         fi # end check javac
20957       fi # end check java
20958     fi # end check boot jdk found
20959   fi
20960 
20961   fi
20962 
20963 
20964     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20965     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20966       # Do we have a bin/java?
20967       if test ! -x "$BOOT_JDK/bin/java"; then
20968         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20969 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20970         BOOT_JDK_FOUND=no
20971       else
20972         # Do we have a bin/javac?
20973         if test ! -x "$BOOT_JDK/bin/javac"; then
20974           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20975 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20976           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20977 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20978           BOOT_JDK_FOUND=no
20979         else
20980           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20981           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20982             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20983 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20984             BOOT_JDK_FOUND=no
20985           else
20986             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20987             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20988 
20989             # Extra M4 quote needed to protect [] in grep expression.
20990             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20991             if test "x$FOUND_CORRECT_VERSION" = x; then
20992               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20993 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20994               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20995 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20996               BOOT_JDK_FOUND=no
20997             else
20998               # We're done! :-)
20999               BOOT_JDK_FOUND=yes
21000 
21001   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21002 
21003   # Input might be given as Windows format, start by converting to
21004   # unix format.
21005   path="$BOOT_JDK"
21006   new_path=`$CYGPATH -u "$path"`
21007 
21008   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21009   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21010   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21011   # "foo.exe" is OK but "foo" is an error.
21012   #
21013   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21014   # It is also a way to make sure we got the proper file name for the real test later on.
21015   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21016   if test "x$test_shortpath" = x; then
21017     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21018 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21019     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21020   fi
21021 
21022   # Call helper function which possibly converts this using DOS-style short mode.
21023   # If so, the updated path is stored in $new_path.
21024 
21025   input_path="$new_path"
21026   # Check if we need to convert this using DOS-style short mode. If the path
21027   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21028   # take no chances and rewrite it.
21029   # Note: m4 eats our [], so we need to use [ and ] instead.
21030   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21031   if test "x$has_forbidden_chars" != x; then
21032     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21033     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21034     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21035     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21036       # Going to short mode and back again did indeed matter. Since short mode is
21037       # case insensitive, let's make it lowercase to improve readability.
21038       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21039       # Now convert it back to Unix-stile (cygpath)
21040       input_path=`$CYGPATH -u "$shortmode_path"`
21041       new_path="$input_path"
21042     fi
21043   fi
21044 
21045   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21046   if test "x$test_cygdrive_prefix" = x; then
21047     # As a simple fix, exclude /usr/bin since it's not a real path.
21048     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21049       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21050       # a path prefixed by /cygdrive for fixpath to work.
21051       new_path="$CYGWIN_ROOT_PATH$input_path"
21052     fi
21053   fi
21054 
21055 
21056   if test "x$path" != "x$new_path"; then
21057     BOOT_JDK="$new_path"
21058     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21059 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21060   fi
21061 
21062   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21063 
21064   path="$BOOT_JDK"
21065   has_colon=`$ECHO $path | $GREP ^.:`
21066   new_path="$path"
21067   if test "x$has_colon" = x; then
21068     # Not in mixed or Windows style, start by that.
21069     new_path=`cmd //c echo $path`
21070   fi
21071 
21072 
21073   input_path="$new_path"
21074   # Check if we need to convert this using DOS-style short mode. If the path
21075   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21076   # take no chances and rewrite it.
21077   # Note: m4 eats our [], so we need to use [ and ] instead.
21078   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21079   if test "x$has_forbidden_chars" != x; then
21080     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21081     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21082   fi
21083 
21084 
21085   windows_path="$new_path"
21086   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21087     unix_path=`$CYGPATH -u "$windows_path"`
21088     new_path="$unix_path"
21089   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21090     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21091     new_path="$unix_path"
21092   fi
21093 
21094   if test "x$path" != "x$new_path"; then
21095     BOOT_JDK="$new_path"
21096     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21097 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21098   fi
21099 
21100   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21101   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21102 
21103   else
21104     # We're on a posix platform. Hooray! :)
21105     path="$BOOT_JDK"
21106     has_space=`$ECHO "$path" | $GREP " "`
21107     if test "x$has_space" != x; then
21108       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21109 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21110       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21111     fi
21112 
21113     # Use eval to expand a potential ~
21114     eval path="$path"
21115     if test ! -f "$path" && test ! -d "$path"; then
21116       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21117     fi
21118 
21119     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21120   fi
21121 
21122               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21123 $as_echo_n "checking for Boot JDK... " >&6; }
21124               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21125 $as_echo "$BOOT_JDK" >&6; }
21126               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21127 $as_echo_n "checking Boot JDK version... " >&6; }
21128               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21129               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21130 $as_echo "$BOOT_JDK_VERSION" >&6; }
21131             fi # end check jdk version
21132           fi # end check rt.jar
21133         fi # end check javac
21134       fi # end check java
21135     fi # end check boot jdk found
21136   fi
21137 
21138 
21139   # Test: Is $JAVA_HOME set?
21140 
21141   if test "x$BOOT_JDK_FOUND" = xno; then
21142     # Now execute the test
21143 
21144   if test "x$JAVA_HOME" != x; then
21145     JAVA_HOME_PROCESSED="$JAVA_HOME"
21146 
21147   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21148 
21149   # Input might be given as Windows format, start by converting to
21150   # unix format.
21151   path="$JAVA_HOME_PROCESSED"
21152   new_path=`$CYGPATH -u "$path"`
21153 
21154   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21155   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21156   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21157   # "foo.exe" is OK but "foo" is an error.
21158   #
21159   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21160   # It is also a way to make sure we got the proper file name for the real test later on.
21161   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21162   if test "x$test_shortpath" = x; then
21163     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21164 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21165     as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5
21166   fi
21167 
21168   # Call helper function which possibly converts this using DOS-style short mode.
21169   # If so, the updated path is stored in $new_path.
21170 
21171   input_path="$new_path"
21172   # Check if we need to convert this using DOS-style short mode. If the path
21173   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21174   # take no chances and rewrite it.
21175   # Note: m4 eats our [], so we need to use [ and ] instead.
21176   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21177   if test "x$has_forbidden_chars" != x; then
21178     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21179     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21180     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21181     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21182       # Going to short mode and back again did indeed matter. Since short mode is
21183       # case insensitive, let's make it lowercase to improve readability.
21184       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21185       # Now convert it back to Unix-stile (cygpath)
21186       input_path=`$CYGPATH -u "$shortmode_path"`
21187       new_path="$input_path"
21188     fi
21189   fi
21190 
21191   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21192   if test "x$test_cygdrive_prefix" = x; then
21193     # As a simple fix, exclude /usr/bin since it's not a real path.
21194     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21195       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21196       # a path prefixed by /cygdrive for fixpath to work.
21197       new_path="$CYGWIN_ROOT_PATH$input_path"
21198     fi
21199   fi
21200 
21201 
21202   if test "x$path" != "x$new_path"; then
21203     JAVA_HOME_PROCESSED="$new_path"
21204     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21205 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21206   fi
21207 
21208   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21209 
21210   path="$JAVA_HOME_PROCESSED"
21211   has_colon=`$ECHO $path | $GREP ^.:`
21212   new_path="$path"
21213   if test "x$has_colon" = x; then
21214     # Not in mixed or Windows style, start by that.
21215     new_path=`cmd //c echo $path`
21216   fi
21217 
21218 
21219   input_path="$new_path"
21220   # Check if we need to convert this using DOS-style short mode. If the path
21221   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21222   # take no chances and rewrite it.
21223   # Note: m4 eats our [], so we need to use [ and ] instead.
21224   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21225   if test "x$has_forbidden_chars" != x; then
21226     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21227     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21228   fi
21229 
21230 
21231   windows_path="$new_path"
21232   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21233     unix_path=`$CYGPATH -u "$windows_path"`
21234     new_path="$unix_path"
21235   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21236     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21237     new_path="$unix_path"
21238   fi
21239 
21240   if test "x$path" != "x$new_path"; then
21241     JAVA_HOME_PROCESSED="$new_path"
21242     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21243 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21244   fi
21245 
21246   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21247   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21248 
21249   else
21250     # We're on a posix platform. Hooray! :)
21251     path="$JAVA_HOME_PROCESSED"
21252     has_space=`$ECHO "$path" | $GREP " "`
21253     if test "x$has_space" != x; then
21254       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21255 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21256       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21257     fi
21258 
21259     # Use eval to expand a potential ~
21260     eval path="$path"
21261     if test ! -f "$path" && test ! -d "$path"; then
21262       as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5
21263     fi
21264 
21265     JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`"
21266   fi
21267 
21268     if test ! -d "$JAVA_HOME_PROCESSED"; then
21269       { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5
21270 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;}
21271     else
21272       # Aha, the user has set a JAVA_HOME
21273       # let us use that as the Boot JDK.
21274       BOOT_JDK="$JAVA_HOME_PROCESSED"
21275       BOOT_JDK_FOUND=maybe
21276       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5
21277 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;}
21278     fi
21279   fi
21280 
21281 
21282     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21283     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21284       # Do we have a bin/java?
21285       if test ! -x "$BOOT_JDK/bin/java"; then
21286         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21287 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21288         BOOT_JDK_FOUND=no
21289       else
21290         # Do we have a bin/javac?
21291         if test ! -x "$BOOT_JDK/bin/javac"; then
21292           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21293 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21294           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21295 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21296           BOOT_JDK_FOUND=no
21297         else
21298           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21299           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21300             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21301 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21302             BOOT_JDK_FOUND=no
21303           else
21304             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21305             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21306 
21307             # Extra M4 quote needed to protect [] in grep expression.
21308             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21309             if test "x$FOUND_CORRECT_VERSION" = x; then
21310               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21311 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21312               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21313 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21314               BOOT_JDK_FOUND=no
21315             else
21316               # We're done! :-)
21317               BOOT_JDK_FOUND=yes
21318 
21319   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21320 
21321   # Input might be given as Windows format, start by converting to
21322   # unix format.
21323   path="$BOOT_JDK"
21324   new_path=`$CYGPATH -u "$path"`
21325 
21326   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21327   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21328   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21329   # "foo.exe" is OK but "foo" is an error.
21330   #
21331   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21332   # It is also a way to make sure we got the proper file name for the real test later on.
21333   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21334   if test "x$test_shortpath" = x; then
21335     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21336 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21337     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21338   fi
21339 
21340   # Call helper function which possibly converts this using DOS-style short mode.
21341   # If so, the updated path is stored in $new_path.
21342 
21343   input_path="$new_path"
21344   # Check if we need to convert this using DOS-style short mode. If the path
21345   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21346   # take no chances and rewrite it.
21347   # Note: m4 eats our [], so we need to use [ and ] instead.
21348   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21349   if test "x$has_forbidden_chars" != x; then
21350     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21351     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21352     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21353     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21354       # Going to short mode and back again did indeed matter. Since short mode is
21355       # case insensitive, let's make it lowercase to improve readability.
21356       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21357       # Now convert it back to Unix-stile (cygpath)
21358       input_path=`$CYGPATH -u "$shortmode_path"`
21359       new_path="$input_path"
21360     fi
21361   fi
21362 
21363   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21364   if test "x$test_cygdrive_prefix" = x; then
21365     # As a simple fix, exclude /usr/bin since it's not a real path.
21366     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21367       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21368       # a path prefixed by /cygdrive for fixpath to work.
21369       new_path="$CYGWIN_ROOT_PATH$input_path"
21370     fi
21371   fi
21372 
21373 
21374   if test "x$path" != "x$new_path"; then
21375     BOOT_JDK="$new_path"
21376     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21377 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21378   fi
21379 
21380   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21381 
21382   path="$BOOT_JDK"
21383   has_colon=`$ECHO $path | $GREP ^.:`
21384   new_path="$path"
21385   if test "x$has_colon" = x; then
21386     # Not in mixed or Windows style, start by that.
21387     new_path=`cmd //c echo $path`
21388   fi
21389 
21390 
21391   input_path="$new_path"
21392   # Check if we need to convert this using DOS-style short mode. If the path
21393   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21394   # take no chances and rewrite it.
21395   # Note: m4 eats our [], so we need to use [ and ] instead.
21396   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21397   if test "x$has_forbidden_chars" != x; then
21398     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21399     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21400   fi
21401 
21402 
21403   windows_path="$new_path"
21404   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21405     unix_path=`$CYGPATH -u "$windows_path"`
21406     new_path="$unix_path"
21407   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21408     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21409     new_path="$unix_path"
21410   fi
21411 
21412   if test "x$path" != "x$new_path"; then
21413     BOOT_JDK="$new_path"
21414     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21415 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21416   fi
21417 
21418   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21419   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21420 
21421   else
21422     # We're on a posix platform. Hooray! :)
21423     path="$BOOT_JDK"
21424     has_space=`$ECHO "$path" | $GREP " "`
21425     if test "x$has_space" != x; then
21426       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21427 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21428       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21429     fi
21430 
21431     # Use eval to expand a potential ~
21432     eval path="$path"
21433     if test ! -f "$path" && test ! -d "$path"; then
21434       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21435     fi
21436 
21437     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21438   fi
21439 
21440               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21441 $as_echo_n "checking for Boot JDK... " >&6; }
21442               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21443 $as_echo "$BOOT_JDK" >&6; }
21444               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21445 $as_echo_n "checking Boot JDK version... " >&6; }
21446               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21447               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21448 $as_echo "$BOOT_JDK_VERSION" >&6; }
21449             fi # end check jdk version
21450           fi # end check rt.jar
21451         fi # end check javac
21452       fi # end check java
21453     fi # end check boot jdk found
21454   fi
21455 
21456 
21457   # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
21458 
21459   if test "x$BOOT_JDK_FOUND" = xno; then
21460     # Now execute the test
21461 
21462   # Extract the first word of "javac", so it can be a program name with args.
21463 set dummy javac; ac_word=$2
21464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21465 $as_echo_n "checking for $ac_word... " >&6; }
21466 if ${ac_cv_path_JAVAC_CHECK+:} false; then :
21467   $as_echo_n "(cached) " >&6
21468 else
21469   case $JAVAC_CHECK in
21470   [\\/]* | ?:[\\/]*)
21471   ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path.
21472   ;;
21473   *)
21474   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21475 for as_dir in $PATH
21476 do
21477   IFS=$as_save_IFS
21478   test -z "$as_dir" && as_dir=.
21479     for ac_exec_ext in '' $ac_executable_extensions; do
21480   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21481     ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext"
21482     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21483     break 2
21484   fi
21485 done
21486   done
21487 IFS=$as_save_IFS
21488 
21489   ;;
21490 esac
21491 fi
21492 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK
21493 if test -n "$JAVAC_CHECK"; then
21494   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5
21495 $as_echo "$JAVAC_CHECK" >&6; }
21496 else
21497   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21498 $as_echo "no" >&6; }
21499 fi
21500 
21501 
21502   # Extract the first word of "java", so it can be a program name with args.
21503 set dummy java; ac_word=$2
21504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21505 $as_echo_n "checking for $ac_word... " >&6; }
21506 if ${ac_cv_path_JAVA_CHECK+:} false; then :
21507   $as_echo_n "(cached) " >&6
21508 else
21509   case $JAVA_CHECK in
21510   [\\/]* | ?:[\\/]*)
21511   ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path.
21512   ;;
21513   *)
21514   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21515 for as_dir in $PATH
21516 do
21517   IFS=$as_save_IFS
21518   test -z "$as_dir" && as_dir=.
21519     for ac_exec_ext in '' $ac_executable_extensions; do
21520   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21521     ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext"
21522     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21523     break 2
21524   fi
21525 done
21526   done
21527 IFS=$as_save_IFS
21528 
21529   ;;
21530 esac
21531 fi
21532 JAVA_CHECK=$ac_cv_path_JAVA_CHECK
21533 if test -n "$JAVA_CHECK"; then
21534   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5
21535 $as_echo "$JAVA_CHECK" >&6; }
21536 else
21537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21538 $as_echo "no" >&6; }
21539 fi
21540 
21541 
21542   BINARY="$JAVAC_CHECK"
21543   if test "x$JAVAC_CHECK" = x; then
21544     BINARY="$JAVA_CHECK"
21545   fi
21546   if test "x$BINARY" != x; then
21547     # So there is a java(c) binary, it might be part of a JDK.
21548     # Lets find the JDK/JRE directory by following symbolic links.
21549     # Linux/GNU systems often have links from /usr/bin/java to
21550     # /etc/alternatives/java to the real JDK binary.
21551 
21552   if test "x$OPENJDK_BUILD_OS" != xwindows; then
21553     # Follow a chain of symbolic links. Use readlink
21554     # where it exists, else fall back to horribly
21555     # complicated shell code.
21556     if test "x$READLINK_TESTED" != yes; then
21557       # On MacOSX there is a readlink tool with a different
21558       # purpose than the GNU readlink tool. Check the found readlink.
21559       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
21560       if test "x$ISGNU" = x; then
21561         # A readlink that we do not know how to use.
21562         # Are there other non-GNU readlinks out there?
21563         READLINK_TESTED=yes
21564         READLINK=
21565       fi
21566     fi
21567 
21568     if test "x$READLINK" != x; then
21569       BINARY=`$READLINK -f $BINARY`
21570     else
21571       # Save the current directory for restoring afterwards
21572       STARTDIR=$PWD
21573       COUNTER=0
21574       sym_link_dir=`$DIRNAME $BINARY`
21575       sym_link_file=`$BASENAME $BINARY`
21576       cd $sym_link_dir
21577       # Use -P flag to resolve symlinks in directories.
21578       cd `$THEPWDCMD -P`
21579       sym_link_dir=`$THEPWDCMD -P`
21580       # Resolve file symlinks
21581       while test $COUNTER -lt 20; do
21582         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
21583         if test "x$ISLINK" == x; then
21584           # This is not a symbolic link! We are done!
21585           break
21586         fi
21587         # Again resolve directory symlinks since the target of the just found
21588         # link could be in a different directory
21589         cd `$DIRNAME $ISLINK`
21590         sym_link_dir=`$THEPWDCMD -P`
21591         sym_link_file=`$BASENAME $ISLINK`
21592         let COUNTER=COUNTER+1
21593       done
21594       cd $STARTDIR
21595       BINARY=$sym_link_dir/$sym_link_file
21596     fi
21597   fi
21598 
21599     BOOT_JDK=`dirname "$BINARY"`
21600     BOOT_JDK=`cd "$BOOT_JDK/.."; pwd`
21601     if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then
21602       # Looks like we found ourselves an JDK
21603       BOOT_JDK_FOUND=maybe
21604       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5
21605 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;}
21606     fi
21607   fi
21608 
21609 
21610     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21611     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21612       # Do we have a bin/java?
21613       if test ! -x "$BOOT_JDK/bin/java"; then
21614         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21615 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21616         BOOT_JDK_FOUND=no
21617       else
21618         # Do we have a bin/javac?
21619         if test ! -x "$BOOT_JDK/bin/javac"; then
21620           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21621 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21622           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21623 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21624           BOOT_JDK_FOUND=no
21625         else
21626           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21627           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21628             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21629 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21630             BOOT_JDK_FOUND=no
21631           else
21632             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21633             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21634 
21635             # Extra M4 quote needed to protect [] in grep expression.
21636             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21637             if test "x$FOUND_CORRECT_VERSION" = x; then
21638               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21639 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21640               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21641 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21642               BOOT_JDK_FOUND=no
21643             else
21644               # We're done! :-)
21645               BOOT_JDK_FOUND=yes
21646 
21647   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21648 
21649   # Input might be given as Windows format, start by converting to
21650   # unix format.
21651   path="$BOOT_JDK"
21652   new_path=`$CYGPATH -u "$path"`
21653 
21654   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21655   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21656   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21657   # "foo.exe" is OK but "foo" is an error.
21658   #
21659   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21660   # It is also a way to make sure we got the proper file name for the real test later on.
21661   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21662   if test "x$test_shortpath" = x; then
21663     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21664 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21665     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21666   fi
21667 
21668   # Call helper function which possibly converts this using DOS-style short mode.
21669   # If so, the updated path is stored in $new_path.
21670 
21671   input_path="$new_path"
21672   # Check if we need to convert this using DOS-style short mode. If the path
21673   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21674   # take no chances and rewrite it.
21675   # Note: m4 eats our [], so we need to use [ and ] instead.
21676   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21677   if test "x$has_forbidden_chars" != x; then
21678     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21679     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21680     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21681     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21682       # Going to short mode and back again did indeed matter. Since short mode is
21683       # case insensitive, let's make it lowercase to improve readability.
21684       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21685       # Now convert it back to Unix-stile (cygpath)
21686       input_path=`$CYGPATH -u "$shortmode_path"`
21687       new_path="$input_path"
21688     fi
21689   fi
21690 
21691   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21692   if test "x$test_cygdrive_prefix" = x; then
21693     # As a simple fix, exclude /usr/bin since it's not a real path.
21694     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21695       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21696       # a path prefixed by /cygdrive for fixpath to work.
21697       new_path="$CYGWIN_ROOT_PATH$input_path"
21698     fi
21699   fi
21700 
21701 
21702   if test "x$path" != "x$new_path"; then
21703     BOOT_JDK="$new_path"
21704     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21705 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21706   fi
21707 
21708   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21709 
21710   path="$BOOT_JDK"
21711   has_colon=`$ECHO $path | $GREP ^.:`
21712   new_path="$path"
21713   if test "x$has_colon" = x; then
21714     # Not in mixed or Windows style, start by that.
21715     new_path=`cmd //c echo $path`
21716   fi
21717 
21718 
21719   input_path="$new_path"
21720   # Check if we need to convert this using DOS-style short mode. If the path
21721   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21722   # take no chances and rewrite it.
21723   # Note: m4 eats our [], so we need to use [ and ] instead.
21724   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21725   if test "x$has_forbidden_chars" != x; then
21726     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21727     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21728   fi
21729 
21730 
21731   windows_path="$new_path"
21732   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21733     unix_path=`$CYGPATH -u "$windows_path"`
21734     new_path="$unix_path"
21735   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21736     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21737     new_path="$unix_path"
21738   fi
21739 
21740   if test "x$path" != "x$new_path"; then
21741     BOOT_JDK="$new_path"
21742     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21743 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21744   fi
21745 
21746   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21747   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21748 
21749   else
21750     # We're on a posix platform. Hooray! :)
21751     path="$BOOT_JDK"
21752     has_space=`$ECHO "$path" | $GREP " "`
21753     if test "x$has_space" != x; then
21754       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21755 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21756       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21757     fi
21758 
21759     # Use eval to expand a potential ~
21760     eval path="$path"
21761     if test ! -f "$path" && test ! -d "$path"; then
21762       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21763     fi
21764 
21765     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21766   fi
21767 
21768               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21769 $as_echo_n "checking for Boot JDK... " >&6; }
21770               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21771 $as_echo "$BOOT_JDK" >&6; }
21772               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21773 $as_echo_n "checking Boot JDK version... " >&6; }
21774               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21775               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21776 $as_echo "$BOOT_JDK_VERSION" >&6; }
21777             fi # end check jdk version
21778           fi # end check rt.jar
21779         fi # end check javac
21780       fi # end check java
21781     fi # end check boot jdk found
21782   fi
21783 
21784 
21785   # Test: Is there a JDK installed in default, well-known locations?
21786 
21787   if test "x$BOOT_JDK_FOUND" = xno; then
21788     # Now execute the test
21789 
21790   if test "x$OPENJDK_TARGET_OS" = xwindows; then
21791 
21792   if test "x$BOOT_JDK_FOUND" = xno; then
21793     # Now execute the test
21794 
21795   if test "x$ProgramW6432" != x; then
21796     VIRTUAL_DIR="$ProgramW6432/Java"
21797 
21798   windows_path="$VIRTUAL_DIR"
21799   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21800     unix_path=`$CYGPATH -u "$windows_path"`
21801     VIRTUAL_DIR="$unix_path"
21802   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21803     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21804     VIRTUAL_DIR="$unix_path"
21805   fi
21806 
21807 
21808   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
21809   BOOT_JDK_SUFFIX=""
21810   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
21811   if test "x$ALL_JDKS_FOUND" != x; then
21812     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
21813 
21814   if test "x$BOOT_JDK_FOUND" = xno; then
21815     # Now execute the test
21816 
21817         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
21818         if test -d "$BOOT_JDK"; then
21819           BOOT_JDK_FOUND=maybe
21820           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
21821 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
21822         fi
21823 
21824 
21825     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21826     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21827       # Do we have a bin/java?
21828       if test ! -x "$BOOT_JDK/bin/java"; then
21829         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21830 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21831         BOOT_JDK_FOUND=no
21832       else
21833         # Do we have a bin/javac?
21834         if test ! -x "$BOOT_JDK/bin/javac"; then
21835           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21836 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21837           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21838 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21839           BOOT_JDK_FOUND=no
21840         else
21841           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21842           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21843             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21844 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21845             BOOT_JDK_FOUND=no
21846           else
21847             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21848             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21849 
21850             # Extra M4 quote needed to protect [] in grep expression.
21851             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21852             if test "x$FOUND_CORRECT_VERSION" = x; then
21853               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21854 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21855               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21856 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21857               BOOT_JDK_FOUND=no
21858             else
21859               # We're done! :-)
21860               BOOT_JDK_FOUND=yes
21861 
21862   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21863 
21864   # Input might be given as Windows format, start by converting to
21865   # unix format.
21866   path="$BOOT_JDK"
21867   new_path=`$CYGPATH -u "$path"`
21868 
21869   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21870   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21871   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21872   # "foo.exe" is OK but "foo" is an error.
21873   #
21874   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21875   # It is also a way to make sure we got the proper file name for the real test later on.
21876   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21877   if test "x$test_shortpath" = x; then
21878     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21879 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21880     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21881   fi
21882 
21883   # Call helper function which possibly converts this using DOS-style short mode.
21884   # If so, the updated path is stored in $new_path.
21885 
21886   input_path="$new_path"
21887   # Check if we need to convert this using DOS-style short mode. If the path
21888   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21889   # take no chances and rewrite it.
21890   # Note: m4 eats our [], so we need to use [ and ] instead.
21891   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21892   if test "x$has_forbidden_chars" != x; then
21893     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21894     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21895     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21896     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21897       # Going to short mode and back again did indeed matter. Since short mode is
21898       # case insensitive, let's make it lowercase to improve readability.
21899       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21900       # Now convert it back to Unix-stile (cygpath)
21901       input_path=`$CYGPATH -u "$shortmode_path"`
21902       new_path="$input_path"
21903     fi
21904   fi
21905 
21906   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21907   if test "x$test_cygdrive_prefix" = x; then
21908     # As a simple fix, exclude /usr/bin since it's not a real path.
21909     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21910       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21911       # a path prefixed by /cygdrive for fixpath to work.
21912       new_path="$CYGWIN_ROOT_PATH$input_path"
21913     fi
21914   fi
21915 
21916 
21917   if test "x$path" != "x$new_path"; then
21918     BOOT_JDK="$new_path"
21919     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21920 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21921   fi
21922 
21923   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21924 
21925   path="$BOOT_JDK"
21926   has_colon=`$ECHO $path | $GREP ^.:`
21927   new_path="$path"
21928   if test "x$has_colon" = x; then
21929     # Not in mixed or Windows style, start by that.
21930     new_path=`cmd //c echo $path`
21931   fi
21932 
21933 
21934   input_path="$new_path"
21935   # Check if we need to convert this using DOS-style short mode. If the path
21936   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21937   # take no chances and rewrite it.
21938   # Note: m4 eats our [], so we need to use [ and ] instead.
21939   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21940   if test "x$has_forbidden_chars" != x; then
21941     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21942     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21943   fi
21944 
21945 
21946   windows_path="$new_path"
21947   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21948     unix_path=`$CYGPATH -u "$windows_path"`
21949     new_path="$unix_path"
21950   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21951     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21952     new_path="$unix_path"
21953   fi
21954 
21955   if test "x$path" != "x$new_path"; then
21956     BOOT_JDK="$new_path"
21957     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21958 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21959   fi
21960 
21961   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21962   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21963 
21964   else
21965     # We're on a posix platform. Hooray! :)
21966     path="$BOOT_JDK"
21967     has_space=`$ECHO "$path" | $GREP " "`
21968     if test "x$has_space" != x; then
21969       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21970 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21971       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21972     fi
21973 
21974     # Use eval to expand a potential ~
21975     eval path="$path"
21976     if test ! -f "$path" && test ! -d "$path"; then
21977       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21978     fi
21979 
21980     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21981   fi
21982 
21983               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21984 $as_echo_n "checking for Boot JDK... " >&6; }
21985               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21986 $as_echo "$BOOT_JDK" >&6; }
21987               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21988 $as_echo_n "checking Boot JDK version... " >&6; }
21989               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21990               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21991 $as_echo "$BOOT_JDK_VERSION" >&6; }
21992             fi # end check jdk version
21993           fi # end check rt.jar
21994         fi # end check javac
21995       fi # end check java
21996     fi # end check boot jdk found
21997   fi
21998 
21999     done
22000   fi
22001 
22002   fi
22003 
22004 
22005     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22006     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22007       # Do we have a bin/java?
22008       if test ! -x "$BOOT_JDK/bin/java"; then
22009         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22010 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22011         BOOT_JDK_FOUND=no
22012       else
22013         # Do we have a bin/javac?
22014         if test ! -x "$BOOT_JDK/bin/javac"; then
22015           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22016 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22017           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22018 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22019           BOOT_JDK_FOUND=no
22020         else
22021           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22022           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22023             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22024 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22025             BOOT_JDK_FOUND=no
22026           else
22027             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22028             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22029 
22030             # Extra M4 quote needed to protect [] in grep expression.
22031             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22032             if test "x$FOUND_CORRECT_VERSION" = x; then
22033               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22034 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22035               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22036 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22037               BOOT_JDK_FOUND=no
22038             else
22039               # We're done! :-)
22040               BOOT_JDK_FOUND=yes
22041 
22042   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22043 
22044   # Input might be given as Windows format, start by converting to
22045   # unix format.
22046   path="$BOOT_JDK"
22047   new_path=`$CYGPATH -u "$path"`
22048 
22049   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22050   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22051   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22052   # "foo.exe" is OK but "foo" is an error.
22053   #
22054   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22055   # It is also a way to make sure we got the proper file name for the real test later on.
22056   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22057   if test "x$test_shortpath" = x; then
22058     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22059 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22060     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22061   fi
22062 
22063   # Call helper function which possibly converts this using DOS-style short mode.
22064   # If so, the updated path is stored in $new_path.
22065 
22066   input_path="$new_path"
22067   # Check if we need to convert this using DOS-style short mode. If the path
22068   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22069   # take no chances and rewrite it.
22070   # Note: m4 eats our [], so we need to use [ and ] instead.
22071   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22072   if test "x$has_forbidden_chars" != x; then
22073     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22074     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22075     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22076     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22077       # Going to short mode and back again did indeed matter. Since short mode is
22078       # case insensitive, let's make it lowercase to improve readability.
22079       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22080       # Now convert it back to Unix-stile (cygpath)
22081       input_path=`$CYGPATH -u "$shortmode_path"`
22082       new_path="$input_path"
22083     fi
22084   fi
22085 
22086   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22087   if test "x$test_cygdrive_prefix" = x; then
22088     # As a simple fix, exclude /usr/bin since it's not a real path.
22089     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22090       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22091       # a path prefixed by /cygdrive for fixpath to work.
22092       new_path="$CYGWIN_ROOT_PATH$input_path"
22093     fi
22094   fi
22095 
22096 
22097   if test "x$path" != "x$new_path"; then
22098     BOOT_JDK="$new_path"
22099     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22100 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22101   fi
22102 
22103   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22104 
22105   path="$BOOT_JDK"
22106   has_colon=`$ECHO $path | $GREP ^.:`
22107   new_path="$path"
22108   if test "x$has_colon" = x; then
22109     # Not in mixed or Windows style, start by that.
22110     new_path=`cmd //c echo $path`
22111   fi
22112 
22113 
22114   input_path="$new_path"
22115   # Check if we need to convert this using DOS-style short mode. If the path
22116   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22117   # take no chances and rewrite it.
22118   # Note: m4 eats our [], so we need to use [ and ] instead.
22119   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22120   if test "x$has_forbidden_chars" != x; then
22121     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22122     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22123   fi
22124 
22125 
22126   windows_path="$new_path"
22127   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22128     unix_path=`$CYGPATH -u "$windows_path"`
22129     new_path="$unix_path"
22130   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22131     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22132     new_path="$unix_path"
22133   fi
22134 
22135   if test "x$path" != "x$new_path"; then
22136     BOOT_JDK="$new_path"
22137     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22138 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22139   fi
22140 
22141   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22142   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22143 
22144   else
22145     # We're on a posix platform. Hooray! :)
22146     path="$BOOT_JDK"
22147     has_space=`$ECHO "$path" | $GREP " "`
22148     if test "x$has_space" != x; then
22149       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22150 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22151       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22152     fi
22153 
22154     # Use eval to expand a potential ~
22155     eval path="$path"
22156     if test ! -f "$path" && test ! -d "$path"; then
22157       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22158     fi
22159 
22160     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22161   fi
22162 
22163               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22164 $as_echo_n "checking for Boot JDK... " >&6; }
22165               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22166 $as_echo "$BOOT_JDK" >&6; }
22167               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22168 $as_echo_n "checking Boot JDK version... " >&6; }
22169               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22170               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22171 $as_echo "$BOOT_JDK_VERSION" >&6; }
22172             fi # end check jdk version
22173           fi # end check rt.jar
22174         fi # end check javac
22175       fi # end check java
22176     fi # end check boot jdk found
22177   fi
22178 
22179 
22180   if test "x$BOOT_JDK_FOUND" = xno; then
22181     # Now execute the test
22182 
22183   if test "x$PROGRAMW6432" != x; then
22184     VIRTUAL_DIR="$PROGRAMW6432/Java"
22185 
22186   windows_path="$VIRTUAL_DIR"
22187   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22188     unix_path=`$CYGPATH -u "$windows_path"`
22189     VIRTUAL_DIR="$unix_path"
22190   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22191     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22192     VIRTUAL_DIR="$unix_path"
22193   fi
22194 
22195 
22196   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22197   BOOT_JDK_SUFFIX=""
22198   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22199   if test "x$ALL_JDKS_FOUND" != x; then
22200     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22201 
22202   if test "x$BOOT_JDK_FOUND" = xno; then
22203     # Now execute the test
22204 
22205         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22206         if test -d "$BOOT_JDK"; then
22207           BOOT_JDK_FOUND=maybe
22208           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22209 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22210         fi
22211 
22212 
22213     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22214     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22215       # Do we have a bin/java?
22216       if test ! -x "$BOOT_JDK/bin/java"; then
22217         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22218 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22219         BOOT_JDK_FOUND=no
22220       else
22221         # Do we have a bin/javac?
22222         if test ! -x "$BOOT_JDK/bin/javac"; then
22223           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22224 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22225           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22226 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22227           BOOT_JDK_FOUND=no
22228         else
22229           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22230           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22231             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22232 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22233             BOOT_JDK_FOUND=no
22234           else
22235             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22236             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22237 
22238             # Extra M4 quote needed to protect [] in grep expression.
22239             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22240             if test "x$FOUND_CORRECT_VERSION" = x; then
22241               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22242 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22243               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22244 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22245               BOOT_JDK_FOUND=no
22246             else
22247               # We're done! :-)
22248               BOOT_JDK_FOUND=yes
22249 
22250   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22251 
22252   # Input might be given as Windows format, start by converting to
22253   # unix format.
22254   path="$BOOT_JDK"
22255   new_path=`$CYGPATH -u "$path"`
22256 
22257   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22258   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22259   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22260   # "foo.exe" is OK but "foo" is an error.
22261   #
22262   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22263   # It is also a way to make sure we got the proper file name for the real test later on.
22264   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22265   if test "x$test_shortpath" = x; then
22266     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22267 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22268     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22269   fi
22270 
22271   # Call helper function which possibly converts this using DOS-style short mode.
22272   # If so, the updated path is stored in $new_path.
22273 
22274   input_path="$new_path"
22275   # Check if we need to convert this using DOS-style short mode. If the path
22276   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22277   # take no chances and rewrite it.
22278   # Note: m4 eats our [], so we need to use [ and ] instead.
22279   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22280   if test "x$has_forbidden_chars" != x; then
22281     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22282     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22283     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22284     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22285       # Going to short mode and back again did indeed matter. Since short mode is
22286       # case insensitive, let's make it lowercase to improve readability.
22287       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22288       # Now convert it back to Unix-stile (cygpath)
22289       input_path=`$CYGPATH -u "$shortmode_path"`
22290       new_path="$input_path"
22291     fi
22292   fi
22293 
22294   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22295   if test "x$test_cygdrive_prefix" = x; then
22296     # As a simple fix, exclude /usr/bin since it's not a real path.
22297     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22298       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22299       # a path prefixed by /cygdrive for fixpath to work.
22300       new_path="$CYGWIN_ROOT_PATH$input_path"
22301     fi
22302   fi
22303 
22304 
22305   if test "x$path" != "x$new_path"; then
22306     BOOT_JDK="$new_path"
22307     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22308 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22309   fi
22310 
22311   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22312 
22313   path="$BOOT_JDK"
22314   has_colon=`$ECHO $path | $GREP ^.:`
22315   new_path="$path"
22316   if test "x$has_colon" = x; then
22317     # Not in mixed or Windows style, start by that.
22318     new_path=`cmd //c echo $path`
22319   fi
22320 
22321 
22322   input_path="$new_path"
22323   # Check if we need to convert this using DOS-style short mode. If the path
22324   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22325   # take no chances and rewrite it.
22326   # Note: m4 eats our [], so we need to use [ and ] instead.
22327   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22328   if test "x$has_forbidden_chars" != x; then
22329     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22330     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22331   fi
22332 
22333 
22334   windows_path="$new_path"
22335   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22336     unix_path=`$CYGPATH -u "$windows_path"`
22337     new_path="$unix_path"
22338   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22339     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22340     new_path="$unix_path"
22341   fi
22342 
22343   if test "x$path" != "x$new_path"; then
22344     BOOT_JDK="$new_path"
22345     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22346 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22347   fi
22348 
22349   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22350   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22351 
22352   else
22353     # We're on a posix platform. Hooray! :)
22354     path="$BOOT_JDK"
22355     has_space=`$ECHO "$path" | $GREP " "`
22356     if test "x$has_space" != x; then
22357       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22358 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22359       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22360     fi
22361 
22362     # Use eval to expand a potential ~
22363     eval path="$path"
22364     if test ! -f "$path" && test ! -d "$path"; then
22365       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22366     fi
22367 
22368     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22369   fi
22370 
22371               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22372 $as_echo_n "checking for Boot JDK... " >&6; }
22373               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22374 $as_echo "$BOOT_JDK" >&6; }
22375               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22376 $as_echo_n "checking Boot JDK version... " >&6; }
22377               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22378               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22379 $as_echo "$BOOT_JDK_VERSION" >&6; }
22380             fi # end check jdk version
22381           fi # end check rt.jar
22382         fi # end check javac
22383       fi # end check java
22384     fi # end check boot jdk found
22385   fi
22386 
22387     done
22388   fi
22389 
22390   fi
22391 
22392 
22393     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22394     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22395       # Do we have a bin/java?
22396       if test ! -x "$BOOT_JDK/bin/java"; then
22397         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22398 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22399         BOOT_JDK_FOUND=no
22400       else
22401         # Do we have a bin/javac?
22402         if test ! -x "$BOOT_JDK/bin/javac"; then
22403           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22404 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22405           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22406 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22407           BOOT_JDK_FOUND=no
22408         else
22409           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22410           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22411             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22412 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22413             BOOT_JDK_FOUND=no
22414           else
22415             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22416             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22417 
22418             # Extra M4 quote needed to protect [] in grep expression.
22419             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22420             if test "x$FOUND_CORRECT_VERSION" = x; then
22421               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22422 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22423               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22424 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22425               BOOT_JDK_FOUND=no
22426             else
22427               # We're done! :-)
22428               BOOT_JDK_FOUND=yes
22429 
22430   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22431 
22432   # Input might be given as Windows format, start by converting to
22433   # unix format.
22434   path="$BOOT_JDK"
22435   new_path=`$CYGPATH -u "$path"`
22436 
22437   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22438   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22439   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22440   # "foo.exe" is OK but "foo" is an error.
22441   #
22442   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22443   # It is also a way to make sure we got the proper file name for the real test later on.
22444   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22445   if test "x$test_shortpath" = x; then
22446     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22447 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22448     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22449   fi
22450 
22451   # Call helper function which possibly converts this using DOS-style short mode.
22452   # If so, the updated path is stored in $new_path.
22453 
22454   input_path="$new_path"
22455   # Check if we need to convert this using DOS-style short mode. If the path
22456   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22457   # take no chances and rewrite it.
22458   # Note: m4 eats our [], so we need to use [ and ] instead.
22459   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22460   if test "x$has_forbidden_chars" != x; then
22461     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22462     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22463     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22464     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22465       # Going to short mode and back again did indeed matter. Since short mode is
22466       # case insensitive, let's make it lowercase to improve readability.
22467       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22468       # Now convert it back to Unix-stile (cygpath)
22469       input_path=`$CYGPATH -u "$shortmode_path"`
22470       new_path="$input_path"
22471     fi
22472   fi
22473 
22474   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22475   if test "x$test_cygdrive_prefix" = x; then
22476     # As a simple fix, exclude /usr/bin since it's not a real path.
22477     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22478       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22479       # a path prefixed by /cygdrive for fixpath to work.
22480       new_path="$CYGWIN_ROOT_PATH$input_path"
22481     fi
22482   fi
22483 
22484 
22485   if test "x$path" != "x$new_path"; then
22486     BOOT_JDK="$new_path"
22487     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22488 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22489   fi
22490 
22491   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22492 
22493   path="$BOOT_JDK"
22494   has_colon=`$ECHO $path | $GREP ^.:`
22495   new_path="$path"
22496   if test "x$has_colon" = x; then
22497     # Not in mixed or Windows style, start by that.
22498     new_path=`cmd //c echo $path`
22499   fi
22500 
22501 
22502   input_path="$new_path"
22503   # Check if we need to convert this using DOS-style short mode. If the path
22504   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22505   # take no chances and rewrite it.
22506   # Note: m4 eats our [], so we need to use [ and ] instead.
22507   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22508   if test "x$has_forbidden_chars" != x; then
22509     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22510     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22511   fi
22512 
22513 
22514   windows_path="$new_path"
22515   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22516     unix_path=`$CYGPATH -u "$windows_path"`
22517     new_path="$unix_path"
22518   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22519     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22520     new_path="$unix_path"
22521   fi
22522 
22523   if test "x$path" != "x$new_path"; then
22524     BOOT_JDK="$new_path"
22525     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22526 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22527   fi
22528 
22529   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22530   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22531 
22532   else
22533     # We're on a posix platform. Hooray! :)
22534     path="$BOOT_JDK"
22535     has_space=`$ECHO "$path" | $GREP " "`
22536     if test "x$has_space" != x; then
22537       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22538 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22539       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22540     fi
22541 
22542     # Use eval to expand a potential ~
22543     eval path="$path"
22544     if test ! -f "$path" && test ! -d "$path"; then
22545       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22546     fi
22547 
22548     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22549   fi
22550 
22551               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22552 $as_echo_n "checking for Boot JDK... " >&6; }
22553               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22554 $as_echo "$BOOT_JDK" >&6; }
22555               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22556 $as_echo_n "checking Boot JDK version... " >&6; }
22557               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22558               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22559 $as_echo "$BOOT_JDK_VERSION" >&6; }
22560             fi # end check jdk version
22561           fi # end check rt.jar
22562         fi # end check javac
22563       fi # end check java
22564     fi # end check boot jdk found
22565   fi
22566 
22567 
22568   if test "x$BOOT_JDK_FOUND" = xno; then
22569     # Now execute the test
22570 
22571   if test "x$PROGRAMFILES" != x; then
22572     VIRTUAL_DIR="$PROGRAMFILES/Java"
22573 
22574   windows_path="$VIRTUAL_DIR"
22575   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22576     unix_path=`$CYGPATH -u "$windows_path"`
22577     VIRTUAL_DIR="$unix_path"
22578   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22579     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22580     VIRTUAL_DIR="$unix_path"
22581   fi
22582 
22583 
22584   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22585   BOOT_JDK_SUFFIX=""
22586   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22587   if test "x$ALL_JDKS_FOUND" != x; then
22588     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22589 
22590   if test "x$BOOT_JDK_FOUND" = xno; then
22591     # Now execute the test
22592 
22593         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22594         if test -d "$BOOT_JDK"; then
22595           BOOT_JDK_FOUND=maybe
22596           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22597 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22598         fi
22599 
22600 
22601     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22602     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22603       # Do we have a bin/java?
22604       if test ! -x "$BOOT_JDK/bin/java"; then
22605         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22606 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22607         BOOT_JDK_FOUND=no
22608       else
22609         # Do we have a bin/javac?
22610         if test ! -x "$BOOT_JDK/bin/javac"; then
22611           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22612 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22613           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22614 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22615           BOOT_JDK_FOUND=no
22616         else
22617           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22618           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22619             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22620 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22621             BOOT_JDK_FOUND=no
22622           else
22623             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22624             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22625 
22626             # Extra M4 quote needed to protect [] in grep expression.
22627             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22628             if test "x$FOUND_CORRECT_VERSION" = x; then
22629               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22630 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22631               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22632 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22633               BOOT_JDK_FOUND=no
22634             else
22635               # We're done! :-)
22636               BOOT_JDK_FOUND=yes
22637 
22638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22639 
22640   # Input might be given as Windows format, start by converting to
22641   # unix format.
22642   path="$BOOT_JDK"
22643   new_path=`$CYGPATH -u "$path"`
22644 
22645   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22646   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22647   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22648   # "foo.exe" is OK but "foo" is an error.
22649   #
22650   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22651   # It is also a way to make sure we got the proper file name for the real test later on.
22652   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22653   if test "x$test_shortpath" = x; then
22654     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22655 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22656     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22657   fi
22658 
22659   # Call helper function which possibly converts this using DOS-style short mode.
22660   # If so, the updated path is stored in $new_path.
22661 
22662   input_path="$new_path"
22663   # Check if we need to convert this using DOS-style short mode. If the path
22664   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22665   # take no chances and rewrite it.
22666   # Note: m4 eats our [], so we need to use [ and ] instead.
22667   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22668   if test "x$has_forbidden_chars" != x; then
22669     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22670     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22671     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22672     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22673       # Going to short mode and back again did indeed matter. Since short mode is
22674       # case insensitive, let's make it lowercase to improve readability.
22675       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22676       # Now convert it back to Unix-stile (cygpath)
22677       input_path=`$CYGPATH -u "$shortmode_path"`
22678       new_path="$input_path"
22679     fi
22680   fi
22681 
22682   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22683   if test "x$test_cygdrive_prefix" = x; then
22684     # As a simple fix, exclude /usr/bin since it's not a real path.
22685     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22686       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22687       # a path prefixed by /cygdrive for fixpath to work.
22688       new_path="$CYGWIN_ROOT_PATH$input_path"
22689     fi
22690   fi
22691 
22692 
22693   if test "x$path" != "x$new_path"; then
22694     BOOT_JDK="$new_path"
22695     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22696 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22697   fi
22698 
22699   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22700 
22701   path="$BOOT_JDK"
22702   has_colon=`$ECHO $path | $GREP ^.:`
22703   new_path="$path"
22704   if test "x$has_colon" = x; then
22705     # Not in mixed or Windows style, start by that.
22706     new_path=`cmd //c echo $path`
22707   fi
22708 
22709 
22710   input_path="$new_path"
22711   # Check if we need to convert this using DOS-style short mode. If the path
22712   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22713   # take no chances and rewrite it.
22714   # Note: m4 eats our [], so we need to use [ and ] instead.
22715   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22716   if test "x$has_forbidden_chars" != x; then
22717     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22718     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22719   fi
22720 
22721 
22722   windows_path="$new_path"
22723   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22724     unix_path=`$CYGPATH -u "$windows_path"`
22725     new_path="$unix_path"
22726   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22727     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22728     new_path="$unix_path"
22729   fi
22730 
22731   if test "x$path" != "x$new_path"; then
22732     BOOT_JDK="$new_path"
22733     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22734 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22735   fi
22736 
22737   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22738   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22739 
22740   else
22741     # We're on a posix platform. Hooray! :)
22742     path="$BOOT_JDK"
22743     has_space=`$ECHO "$path" | $GREP " "`
22744     if test "x$has_space" != x; then
22745       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22746 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22747       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22748     fi
22749 
22750     # Use eval to expand a potential ~
22751     eval path="$path"
22752     if test ! -f "$path" && test ! -d "$path"; then
22753       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22754     fi
22755 
22756     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22757   fi
22758 
22759               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22760 $as_echo_n "checking for Boot JDK... " >&6; }
22761               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22762 $as_echo "$BOOT_JDK" >&6; }
22763               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22764 $as_echo_n "checking Boot JDK version... " >&6; }
22765               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22766               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22767 $as_echo "$BOOT_JDK_VERSION" >&6; }
22768             fi # end check jdk version
22769           fi # end check rt.jar
22770         fi # end check javac
22771       fi # end check java
22772     fi # end check boot jdk found
22773   fi
22774 
22775     done
22776   fi
22777 
22778   fi
22779 
22780 
22781     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22782     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22783       # Do we have a bin/java?
22784       if test ! -x "$BOOT_JDK/bin/java"; then
22785         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22786 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22787         BOOT_JDK_FOUND=no
22788       else
22789         # Do we have a bin/javac?
22790         if test ! -x "$BOOT_JDK/bin/javac"; then
22791           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22792 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22793           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22794 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22795           BOOT_JDK_FOUND=no
22796         else
22797           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22798           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22799             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22800 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22801             BOOT_JDK_FOUND=no
22802           else
22803             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22804             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22805 
22806             # Extra M4 quote needed to protect [] in grep expression.
22807             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22808             if test "x$FOUND_CORRECT_VERSION" = x; then
22809               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22810 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22811               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22812 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22813               BOOT_JDK_FOUND=no
22814             else
22815               # We're done! :-)
22816               BOOT_JDK_FOUND=yes
22817 
22818   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22819 
22820   # Input might be given as Windows format, start by converting to
22821   # unix format.
22822   path="$BOOT_JDK"
22823   new_path=`$CYGPATH -u "$path"`
22824 
22825   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22826   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22827   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22828   # "foo.exe" is OK but "foo" is an error.
22829   #
22830   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22831   # It is also a way to make sure we got the proper file name for the real test later on.
22832   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22833   if test "x$test_shortpath" = x; then
22834     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22835 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22836     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22837   fi
22838 
22839   # Call helper function which possibly converts this using DOS-style short mode.
22840   # If so, the updated path is stored in $new_path.
22841 
22842   input_path="$new_path"
22843   # Check if we need to convert this using DOS-style short mode. If the path
22844   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22845   # take no chances and rewrite it.
22846   # Note: m4 eats our [], so we need to use [ and ] instead.
22847   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22848   if test "x$has_forbidden_chars" != x; then
22849     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22850     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22851     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22852     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22853       # Going to short mode and back again did indeed matter. Since short mode is
22854       # case insensitive, let's make it lowercase to improve readability.
22855       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22856       # Now convert it back to Unix-stile (cygpath)
22857       input_path=`$CYGPATH -u "$shortmode_path"`
22858       new_path="$input_path"
22859     fi
22860   fi
22861 
22862   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22863   if test "x$test_cygdrive_prefix" = x; then
22864     # As a simple fix, exclude /usr/bin since it's not a real path.
22865     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22866       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22867       # a path prefixed by /cygdrive for fixpath to work.
22868       new_path="$CYGWIN_ROOT_PATH$input_path"
22869     fi
22870   fi
22871 
22872 
22873   if test "x$path" != "x$new_path"; then
22874     BOOT_JDK="$new_path"
22875     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22876 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22877   fi
22878 
22879   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22880 
22881   path="$BOOT_JDK"
22882   has_colon=`$ECHO $path | $GREP ^.:`
22883   new_path="$path"
22884   if test "x$has_colon" = x; then
22885     # Not in mixed or Windows style, start by that.
22886     new_path=`cmd //c echo $path`
22887   fi
22888 
22889 
22890   input_path="$new_path"
22891   # Check if we need to convert this using DOS-style short mode. If the path
22892   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22893   # take no chances and rewrite it.
22894   # Note: m4 eats our [], so we need to use [ and ] instead.
22895   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22896   if test "x$has_forbidden_chars" != x; then
22897     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22898     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22899   fi
22900 
22901 
22902   windows_path="$new_path"
22903   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22904     unix_path=`$CYGPATH -u "$windows_path"`
22905     new_path="$unix_path"
22906   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22907     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22908     new_path="$unix_path"
22909   fi
22910 
22911   if test "x$path" != "x$new_path"; then
22912     BOOT_JDK="$new_path"
22913     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22914 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22915   fi
22916 
22917   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22918   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22919 
22920   else
22921     # We're on a posix platform. Hooray! :)
22922     path="$BOOT_JDK"
22923     has_space=`$ECHO "$path" | $GREP " "`
22924     if test "x$has_space" != x; then
22925       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22926 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22927       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22928     fi
22929 
22930     # Use eval to expand a potential ~
22931     eval path="$path"
22932     if test ! -f "$path" && test ! -d "$path"; then
22933       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22934     fi
22935 
22936     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22937   fi
22938 
22939               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22940 $as_echo_n "checking for Boot JDK... " >&6; }
22941               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22942 $as_echo "$BOOT_JDK" >&6; }
22943               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22944 $as_echo_n "checking Boot JDK version... " >&6; }
22945               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22946               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22947 $as_echo "$BOOT_JDK_VERSION" >&6; }
22948             fi # end check jdk version
22949           fi # end check rt.jar
22950         fi # end check javac
22951       fi # end check java
22952     fi # end check boot jdk found
22953   fi
22954 
22955 
22956   if test "x$BOOT_JDK_FOUND" = xno; then
22957     # Now execute the test
22958 
22959   if test "x$ProgramFiles" != x; then
22960     VIRTUAL_DIR="$ProgramFiles/Java"
22961 
22962   windows_path="$VIRTUAL_DIR"
22963   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22964     unix_path=`$CYGPATH -u "$windows_path"`
22965     VIRTUAL_DIR="$unix_path"
22966   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22967     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22968     VIRTUAL_DIR="$unix_path"
22969   fi
22970 
22971 
22972   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22973   BOOT_JDK_SUFFIX=""
22974   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22975   if test "x$ALL_JDKS_FOUND" != x; then
22976     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22977 
22978   if test "x$BOOT_JDK_FOUND" = xno; then
22979     # Now execute the test
22980 
22981         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22982         if test -d "$BOOT_JDK"; then
22983           BOOT_JDK_FOUND=maybe
22984           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22985 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22986         fi
22987 
22988 
22989     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22990     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22991       # Do we have a bin/java?
22992       if test ! -x "$BOOT_JDK/bin/java"; then
22993         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22994 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22995         BOOT_JDK_FOUND=no
22996       else
22997         # Do we have a bin/javac?
22998         if test ! -x "$BOOT_JDK/bin/javac"; then
22999           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23000 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23001           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23002 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23003           BOOT_JDK_FOUND=no
23004         else
23005           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23006           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23007             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23008 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23009             BOOT_JDK_FOUND=no
23010           else
23011             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23012             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23013 
23014             # Extra M4 quote needed to protect [] in grep expression.
23015             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23016             if test "x$FOUND_CORRECT_VERSION" = x; then
23017               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23018 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23019               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23020 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23021               BOOT_JDK_FOUND=no
23022             else
23023               # We're done! :-)
23024               BOOT_JDK_FOUND=yes
23025 
23026   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23027 
23028   # Input might be given as Windows format, start by converting to
23029   # unix format.
23030   path="$BOOT_JDK"
23031   new_path=`$CYGPATH -u "$path"`
23032 
23033   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23034   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23035   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23036   # "foo.exe" is OK but "foo" is an error.
23037   #
23038   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23039   # It is also a way to make sure we got the proper file name for the real test later on.
23040   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23041   if test "x$test_shortpath" = x; then
23042     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23043 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23044     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23045   fi
23046 
23047   # Call helper function which possibly converts this using DOS-style short mode.
23048   # If so, the updated path is stored in $new_path.
23049 
23050   input_path="$new_path"
23051   # Check if we need to convert this using DOS-style short mode. If the path
23052   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23053   # take no chances and rewrite it.
23054   # Note: m4 eats our [], so we need to use [ and ] instead.
23055   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23056   if test "x$has_forbidden_chars" != x; then
23057     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23058     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23059     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23060     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23061       # Going to short mode and back again did indeed matter. Since short mode is
23062       # case insensitive, let's make it lowercase to improve readability.
23063       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23064       # Now convert it back to Unix-stile (cygpath)
23065       input_path=`$CYGPATH -u "$shortmode_path"`
23066       new_path="$input_path"
23067     fi
23068   fi
23069 
23070   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23071   if test "x$test_cygdrive_prefix" = x; then
23072     # As a simple fix, exclude /usr/bin since it's not a real path.
23073     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23074       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23075       # a path prefixed by /cygdrive for fixpath to work.
23076       new_path="$CYGWIN_ROOT_PATH$input_path"
23077     fi
23078   fi
23079 
23080 
23081   if test "x$path" != "x$new_path"; then
23082     BOOT_JDK="$new_path"
23083     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23084 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23085   fi
23086 
23087   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23088 
23089   path="$BOOT_JDK"
23090   has_colon=`$ECHO $path | $GREP ^.:`
23091   new_path="$path"
23092   if test "x$has_colon" = x; then
23093     # Not in mixed or Windows style, start by that.
23094     new_path=`cmd //c echo $path`
23095   fi
23096 
23097 
23098   input_path="$new_path"
23099   # Check if we need to convert this using DOS-style short mode. If the path
23100   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23101   # take no chances and rewrite it.
23102   # Note: m4 eats our [], so we need to use [ and ] instead.
23103   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23104   if test "x$has_forbidden_chars" != x; then
23105     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23106     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23107   fi
23108 
23109 
23110   windows_path="$new_path"
23111   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23112     unix_path=`$CYGPATH -u "$windows_path"`
23113     new_path="$unix_path"
23114   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23115     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23116     new_path="$unix_path"
23117   fi
23118 
23119   if test "x$path" != "x$new_path"; then
23120     BOOT_JDK="$new_path"
23121     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23122 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23123   fi
23124 
23125   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23126   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23127 
23128   else
23129     # We're on a posix platform. Hooray! :)
23130     path="$BOOT_JDK"
23131     has_space=`$ECHO "$path" | $GREP " "`
23132     if test "x$has_space" != x; then
23133       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23134 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23135       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23136     fi
23137 
23138     # Use eval to expand a potential ~
23139     eval path="$path"
23140     if test ! -f "$path" && test ! -d "$path"; then
23141       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23142     fi
23143 
23144     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23145   fi
23146 
23147               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23148 $as_echo_n "checking for Boot JDK... " >&6; }
23149               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23150 $as_echo "$BOOT_JDK" >&6; }
23151               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23152 $as_echo_n "checking Boot JDK version... " >&6; }
23153               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23154               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23155 $as_echo "$BOOT_JDK_VERSION" >&6; }
23156             fi # end check jdk version
23157           fi # end check rt.jar
23158         fi # end check javac
23159       fi # end check java
23160     fi # end check boot jdk found
23161   fi
23162 
23163     done
23164   fi
23165 
23166   fi
23167 
23168 
23169     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23170     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23171       # Do we have a bin/java?
23172       if test ! -x "$BOOT_JDK/bin/java"; then
23173         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23174 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23175         BOOT_JDK_FOUND=no
23176       else
23177         # Do we have a bin/javac?
23178         if test ! -x "$BOOT_JDK/bin/javac"; then
23179           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23180 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23181           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23182 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23183           BOOT_JDK_FOUND=no
23184         else
23185           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23186           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23187             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23188 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23189             BOOT_JDK_FOUND=no
23190           else
23191             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23192             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23193 
23194             # Extra M4 quote needed to protect [] in grep expression.
23195             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23196             if test "x$FOUND_CORRECT_VERSION" = x; then
23197               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23198 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23199               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23200 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23201               BOOT_JDK_FOUND=no
23202             else
23203               # We're done! :-)
23204               BOOT_JDK_FOUND=yes
23205 
23206   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23207 
23208   # Input might be given as Windows format, start by converting to
23209   # unix format.
23210   path="$BOOT_JDK"
23211   new_path=`$CYGPATH -u "$path"`
23212 
23213   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23214   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23215   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23216   # "foo.exe" is OK but "foo" is an error.
23217   #
23218   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23219   # It is also a way to make sure we got the proper file name for the real test later on.
23220   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23221   if test "x$test_shortpath" = x; then
23222     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23223 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23224     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23225   fi
23226 
23227   # Call helper function which possibly converts this using DOS-style short mode.
23228   # If so, the updated path is stored in $new_path.
23229 
23230   input_path="$new_path"
23231   # Check if we need to convert this using DOS-style short mode. If the path
23232   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23233   # take no chances and rewrite it.
23234   # Note: m4 eats our [], so we need to use [ and ] instead.
23235   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23236   if test "x$has_forbidden_chars" != x; then
23237     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23238     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23239     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23240     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23241       # Going to short mode and back again did indeed matter. Since short mode is
23242       # case insensitive, let's make it lowercase to improve readability.
23243       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23244       # Now convert it back to Unix-stile (cygpath)
23245       input_path=`$CYGPATH -u "$shortmode_path"`
23246       new_path="$input_path"
23247     fi
23248   fi
23249 
23250   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23251   if test "x$test_cygdrive_prefix" = x; then
23252     # As a simple fix, exclude /usr/bin since it's not a real path.
23253     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23254       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23255       # a path prefixed by /cygdrive for fixpath to work.
23256       new_path="$CYGWIN_ROOT_PATH$input_path"
23257     fi
23258   fi
23259 
23260 
23261   if test "x$path" != "x$new_path"; then
23262     BOOT_JDK="$new_path"
23263     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23264 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23265   fi
23266 
23267   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23268 
23269   path="$BOOT_JDK"
23270   has_colon=`$ECHO $path | $GREP ^.:`
23271   new_path="$path"
23272   if test "x$has_colon" = x; then
23273     # Not in mixed or Windows style, start by that.
23274     new_path=`cmd //c echo $path`
23275   fi
23276 
23277 
23278   input_path="$new_path"
23279   # Check if we need to convert this using DOS-style short mode. If the path
23280   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23281   # take no chances and rewrite it.
23282   # Note: m4 eats our [], so we need to use [ and ] instead.
23283   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23284   if test "x$has_forbidden_chars" != x; then
23285     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23286     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23287   fi
23288 
23289 
23290   windows_path="$new_path"
23291   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23292     unix_path=`$CYGPATH -u "$windows_path"`
23293     new_path="$unix_path"
23294   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23295     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23296     new_path="$unix_path"
23297   fi
23298 
23299   if test "x$path" != "x$new_path"; then
23300     BOOT_JDK="$new_path"
23301     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23302 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23303   fi
23304 
23305   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23306   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23307 
23308   else
23309     # We're on a posix platform. Hooray! :)
23310     path="$BOOT_JDK"
23311     has_space=`$ECHO "$path" | $GREP " "`
23312     if test "x$has_space" != x; then
23313       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23314 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23315       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23316     fi
23317 
23318     # Use eval to expand a potential ~
23319     eval path="$path"
23320     if test ! -f "$path" && test ! -d "$path"; then
23321       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23322     fi
23323 
23324     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23325   fi
23326 
23327               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23328 $as_echo_n "checking for Boot JDK... " >&6; }
23329               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23330 $as_echo "$BOOT_JDK" >&6; }
23331               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23332 $as_echo_n "checking Boot JDK version... " >&6; }
23333               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23334               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23335 $as_echo "$BOOT_JDK_VERSION" >&6; }
23336             fi # end check jdk version
23337           fi # end check rt.jar
23338         fi # end check javac
23339       fi # end check java
23340     fi # end check boot jdk found
23341   fi
23342 
23343 
23344   if test "x$BOOT_JDK_FOUND" = xno; then
23345     # Now execute the test
23346 
23347   BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java"
23348   BOOT_JDK_SUFFIX=""
23349   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23350   if test "x$ALL_JDKS_FOUND" != x; then
23351     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23352 
23353   if test "x$BOOT_JDK_FOUND" = xno; then
23354     # Now execute the test
23355 
23356         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23357         if test -d "$BOOT_JDK"; then
23358           BOOT_JDK_FOUND=maybe
23359           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23360 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23361         fi
23362 
23363 
23364     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23365     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23366       # Do we have a bin/java?
23367       if test ! -x "$BOOT_JDK/bin/java"; then
23368         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23369 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23370         BOOT_JDK_FOUND=no
23371       else
23372         # Do we have a bin/javac?
23373         if test ! -x "$BOOT_JDK/bin/javac"; then
23374           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23375 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23376           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23377 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23378           BOOT_JDK_FOUND=no
23379         else
23380           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23381           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23382             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23383 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23384             BOOT_JDK_FOUND=no
23385           else
23386             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23387             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23388 
23389             # Extra M4 quote needed to protect [] in grep expression.
23390             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23391             if test "x$FOUND_CORRECT_VERSION" = x; then
23392               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23393 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23394               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23395 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23396               BOOT_JDK_FOUND=no
23397             else
23398               # We're done! :-)
23399               BOOT_JDK_FOUND=yes
23400 
23401   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23402 
23403   # Input might be given as Windows format, start by converting to
23404   # unix format.
23405   path="$BOOT_JDK"
23406   new_path=`$CYGPATH -u "$path"`
23407 
23408   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23409   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23410   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23411   # "foo.exe" is OK but "foo" is an error.
23412   #
23413   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23414   # It is also a way to make sure we got the proper file name for the real test later on.
23415   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23416   if test "x$test_shortpath" = x; then
23417     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23418 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23419     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23420   fi
23421 
23422   # Call helper function which possibly converts this using DOS-style short mode.
23423   # If so, the updated path is stored in $new_path.
23424 
23425   input_path="$new_path"
23426   # Check if we need to convert this using DOS-style short mode. If the path
23427   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23428   # take no chances and rewrite it.
23429   # Note: m4 eats our [], so we need to use [ and ] instead.
23430   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23431   if test "x$has_forbidden_chars" != x; then
23432     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23433     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23434     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23435     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23436       # Going to short mode and back again did indeed matter. Since short mode is
23437       # case insensitive, let's make it lowercase to improve readability.
23438       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23439       # Now convert it back to Unix-stile (cygpath)
23440       input_path=`$CYGPATH -u "$shortmode_path"`
23441       new_path="$input_path"
23442     fi
23443   fi
23444 
23445   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23446   if test "x$test_cygdrive_prefix" = x; then
23447     # As a simple fix, exclude /usr/bin since it's not a real path.
23448     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23449       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23450       # a path prefixed by /cygdrive for fixpath to work.
23451       new_path="$CYGWIN_ROOT_PATH$input_path"
23452     fi
23453   fi
23454 
23455 
23456   if test "x$path" != "x$new_path"; then
23457     BOOT_JDK="$new_path"
23458     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23459 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23460   fi
23461 
23462   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23463 
23464   path="$BOOT_JDK"
23465   has_colon=`$ECHO $path | $GREP ^.:`
23466   new_path="$path"
23467   if test "x$has_colon" = x; then
23468     # Not in mixed or Windows style, start by that.
23469     new_path=`cmd //c echo $path`
23470   fi
23471 
23472 
23473   input_path="$new_path"
23474   # Check if we need to convert this using DOS-style short mode. If the path
23475   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23476   # take no chances and rewrite it.
23477   # Note: m4 eats our [], so we need to use [ and ] instead.
23478   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23479   if test "x$has_forbidden_chars" != x; then
23480     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23481     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23482   fi
23483 
23484 
23485   windows_path="$new_path"
23486   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23487     unix_path=`$CYGPATH -u "$windows_path"`
23488     new_path="$unix_path"
23489   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23490     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23491     new_path="$unix_path"
23492   fi
23493 
23494   if test "x$path" != "x$new_path"; then
23495     BOOT_JDK="$new_path"
23496     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23497 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23498   fi
23499 
23500   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23501   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23502 
23503   else
23504     # We're on a posix platform. Hooray! :)
23505     path="$BOOT_JDK"
23506     has_space=`$ECHO "$path" | $GREP " "`
23507     if test "x$has_space" != x; then
23508       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23509 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23510       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23511     fi
23512 
23513     # Use eval to expand a potential ~
23514     eval path="$path"
23515     if test ! -f "$path" && test ! -d "$path"; then
23516       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23517     fi
23518 
23519     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23520   fi
23521 
23522               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23523 $as_echo_n "checking for Boot JDK... " >&6; }
23524               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23525 $as_echo "$BOOT_JDK" >&6; }
23526               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23527 $as_echo_n "checking Boot JDK version... " >&6; }
23528               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23529               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23530 $as_echo "$BOOT_JDK_VERSION" >&6; }
23531             fi # end check jdk version
23532           fi # end check rt.jar
23533         fi # end check javac
23534       fi # end check java
23535     fi # end check boot jdk found
23536   fi
23537 
23538     done
23539   fi
23540 
23541 
23542     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23543     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23544       # Do we have a bin/java?
23545       if test ! -x "$BOOT_JDK/bin/java"; then
23546         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23547 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23548         BOOT_JDK_FOUND=no
23549       else
23550         # Do we have a bin/javac?
23551         if test ! -x "$BOOT_JDK/bin/javac"; then
23552           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23554           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23555 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23556           BOOT_JDK_FOUND=no
23557         else
23558           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23559           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23560             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23561 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23562             BOOT_JDK_FOUND=no
23563           else
23564             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23565             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23566 
23567             # Extra M4 quote needed to protect [] in grep expression.
23568             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23569             if test "x$FOUND_CORRECT_VERSION" = x; then
23570               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23571 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23572               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23573 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23574               BOOT_JDK_FOUND=no
23575             else
23576               # We're done! :-)
23577               BOOT_JDK_FOUND=yes
23578 
23579   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23580 
23581   # Input might be given as Windows format, start by converting to
23582   # unix format.
23583   path="$BOOT_JDK"
23584   new_path=`$CYGPATH -u "$path"`
23585 
23586   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23587   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23588   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23589   # "foo.exe" is OK but "foo" is an error.
23590   #
23591   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23592   # It is also a way to make sure we got the proper file name for the real test later on.
23593   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23594   if test "x$test_shortpath" = x; then
23595     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23596 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23597     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23598   fi
23599 
23600   # Call helper function which possibly converts this using DOS-style short mode.
23601   # If so, the updated path is stored in $new_path.
23602 
23603   input_path="$new_path"
23604   # Check if we need to convert this using DOS-style short mode. If the path
23605   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23606   # take no chances and rewrite it.
23607   # Note: m4 eats our [], so we need to use [ and ] instead.
23608   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23609   if test "x$has_forbidden_chars" != x; then
23610     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23611     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23612     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23613     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23614       # Going to short mode and back again did indeed matter. Since short mode is
23615       # case insensitive, let's make it lowercase to improve readability.
23616       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23617       # Now convert it back to Unix-stile (cygpath)
23618       input_path=`$CYGPATH -u "$shortmode_path"`
23619       new_path="$input_path"
23620     fi
23621   fi
23622 
23623   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23624   if test "x$test_cygdrive_prefix" = x; then
23625     # As a simple fix, exclude /usr/bin since it's not a real path.
23626     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23627       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23628       # a path prefixed by /cygdrive for fixpath to work.
23629       new_path="$CYGWIN_ROOT_PATH$input_path"
23630     fi
23631   fi
23632 
23633 
23634   if test "x$path" != "x$new_path"; then
23635     BOOT_JDK="$new_path"
23636     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23637 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23638   fi
23639 
23640   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23641 
23642   path="$BOOT_JDK"
23643   has_colon=`$ECHO $path | $GREP ^.:`
23644   new_path="$path"
23645   if test "x$has_colon" = x; then
23646     # Not in mixed or Windows style, start by that.
23647     new_path=`cmd //c echo $path`
23648   fi
23649 
23650 
23651   input_path="$new_path"
23652   # Check if we need to convert this using DOS-style short mode. If the path
23653   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23654   # take no chances and rewrite it.
23655   # Note: m4 eats our [], so we need to use [ and ] instead.
23656   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23657   if test "x$has_forbidden_chars" != x; then
23658     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23659     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23660   fi
23661 
23662 
23663   windows_path="$new_path"
23664   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23665     unix_path=`$CYGPATH -u "$windows_path"`
23666     new_path="$unix_path"
23667   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23668     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23669     new_path="$unix_path"
23670   fi
23671 
23672   if test "x$path" != "x$new_path"; then
23673     BOOT_JDK="$new_path"
23674     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23675 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23676   fi
23677 
23678   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23679   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23680 
23681   else
23682     # We're on a posix platform. Hooray! :)
23683     path="$BOOT_JDK"
23684     has_space=`$ECHO "$path" | $GREP " "`
23685     if test "x$has_space" != x; then
23686       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23687 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23688       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23689     fi
23690 
23691     # Use eval to expand a potential ~
23692     eval path="$path"
23693     if test ! -f "$path" && test ! -d "$path"; then
23694       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23695     fi
23696 
23697     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23698   fi
23699 
23700               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23701 $as_echo_n "checking for Boot JDK... " >&6; }
23702               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23703 $as_echo "$BOOT_JDK" >&6; }
23704               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23705 $as_echo_n "checking Boot JDK version... " >&6; }
23706               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23707               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23708 $as_echo "$BOOT_JDK_VERSION" >&6; }
23709             fi # end check jdk version
23710           fi # end check rt.jar
23711         fi # end check javac
23712       fi # end check java
23713     fi # end check boot jdk found
23714   fi
23715 
23716   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
23717 
23718   if test "x$BOOT_JDK_FOUND" = xno; then
23719     # Now execute the test
23720 
23721   BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines"
23722   BOOT_JDK_SUFFIX="/Contents/Home"
23723   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23724   if test "x$ALL_JDKS_FOUND" != x; then
23725     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23726 
23727   if test "x$BOOT_JDK_FOUND" = xno; then
23728     # Now execute the test
23729 
23730         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23731         if test -d "$BOOT_JDK"; then
23732           BOOT_JDK_FOUND=maybe
23733           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23734 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23735         fi
23736 
23737 
23738     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23739     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23740       # Do we have a bin/java?
23741       if test ! -x "$BOOT_JDK/bin/java"; then
23742         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23743 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23744         BOOT_JDK_FOUND=no
23745       else
23746         # Do we have a bin/javac?
23747         if test ! -x "$BOOT_JDK/bin/javac"; then
23748           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23749 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23750           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23751 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23752           BOOT_JDK_FOUND=no
23753         else
23754           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23755           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23756             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23757 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23758             BOOT_JDK_FOUND=no
23759           else
23760             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23761             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23762 
23763             # Extra M4 quote needed to protect [] in grep expression.
23764             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23765             if test "x$FOUND_CORRECT_VERSION" = x; then
23766               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23767 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23768               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23769 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23770               BOOT_JDK_FOUND=no
23771             else
23772               # We're done! :-)
23773               BOOT_JDK_FOUND=yes
23774 
23775   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23776 
23777   # Input might be given as Windows format, start by converting to
23778   # unix format.
23779   path="$BOOT_JDK"
23780   new_path=`$CYGPATH -u "$path"`
23781 
23782   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23783   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23784   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23785   # "foo.exe" is OK but "foo" is an error.
23786   #
23787   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23788   # It is also a way to make sure we got the proper file name for the real test later on.
23789   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23790   if test "x$test_shortpath" = x; then
23791     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23792 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23793     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23794   fi
23795 
23796   # Call helper function which possibly converts this using DOS-style short mode.
23797   # If so, the updated path is stored in $new_path.
23798 
23799   input_path="$new_path"
23800   # Check if we need to convert this using DOS-style short mode. If the path
23801   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23802   # take no chances and rewrite it.
23803   # Note: m4 eats our [], so we need to use [ and ] instead.
23804   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23805   if test "x$has_forbidden_chars" != x; then
23806     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23807     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23808     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23809     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23810       # Going to short mode and back again did indeed matter. Since short mode is
23811       # case insensitive, let's make it lowercase to improve readability.
23812       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23813       # Now convert it back to Unix-stile (cygpath)
23814       input_path=`$CYGPATH -u "$shortmode_path"`
23815       new_path="$input_path"
23816     fi
23817   fi
23818 
23819   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23820   if test "x$test_cygdrive_prefix" = x; then
23821     # As a simple fix, exclude /usr/bin since it's not a real path.
23822     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23823       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23824       # a path prefixed by /cygdrive for fixpath to work.
23825       new_path="$CYGWIN_ROOT_PATH$input_path"
23826     fi
23827   fi
23828 
23829 
23830   if test "x$path" != "x$new_path"; then
23831     BOOT_JDK="$new_path"
23832     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23833 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23834   fi
23835 
23836   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23837 
23838   path="$BOOT_JDK"
23839   has_colon=`$ECHO $path | $GREP ^.:`
23840   new_path="$path"
23841   if test "x$has_colon" = x; then
23842     # Not in mixed or Windows style, start by that.
23843     new_path=`cmd //c echo $path`
23844   fi
23845 
23846 
23847   input_path="$new_path"
23848   # Check if we need to convert this using DOS-style short mode. If the path
23849   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23850   # take no chances and rewrite it.
23851   # Note: m4 eats our [], so we need to use [ and ] instead.
23852   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23853   if test "x$has_forbidden_chars" != x; then
23854     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23855     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23856   fi
23857 
23858 
23859   windows_path="$new_path"
23860   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23861     unix_path=`$CYGPATH -u "$windows_path"`
23862     new_path="$unix_path"
23863   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23864     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23865     new_path="$unix_path"
23866   fi
23867 
23868   if test "x$path" != "x$new_path"; then
23869     BOOT_JDK="$new_path"
23870     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23871 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23872   fi
23873 
23874   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23875   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23876 
23877   else
23878     # We're on a posix platform. Hooray! :)
23879     path="$BOOT_JDK"
23880     has_space=`$ECHO "$path" | $GREP " "`
23881     if test "x$has_space" != x; then
23882       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23883 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23884       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23885     fi
23886 
23887     # Use eval to expand a potential ~
23888     eval path="$path"
23889     if test ! -f "$path" && test ! -d "$path"; then
23890       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23891     fi
23892 
23893     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23894   fi
23895 
23896               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23897 $as_echo_n "checking for Boot JDK... " >&6; }
23898               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23899 $as_echo "$BOOT_JDK" >&6; }
23900               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23901 $as_echo_n "checking Boot JDK version... " >&6; }
23902               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23903               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23904 $as_echo "$BOOT_JDK_VERSION" >&6; }
23905             fi # end check jdk version
23906           fi # end check rt.jar
23907         fi # end check javac
23908       fi # end check java
23909     fi # end check boot jdk found
23910   fi
23911 
23912     done
23913   fi
23914 
23915 
23916     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23917     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23918       # Do we have a bin/java?
23919       if test ! -x "$BOOT_JDK/bin/java"; then
23920         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23921 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23922         BOOT_JDK_FOUND=no
23923       else
23924         # Do we have a bin/javac?
23925         if test ! -x "$BOOT_JDK/bin/javac"; then
23926           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23927 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23928           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23929 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23930           BOOT_JDK_FOUND=no
23931         else
23932           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23933           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23934             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23935 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23936             BOOT_JDK_FOUND=no
23937           else
23938             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23939             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23940 
23941             # Extra M4 quote needed to protect [] in grep expression.
23942             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23943             if test "x$FOUND_CORRECT_VERSION" = x; then
23944               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23945 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23946               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23947 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23948               BOOT_JDK_FOUND=no
23949             else
23950               # We're done! :-)
23951               BOOT_JDK_FOUND=yes
23952 
23953   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23954 
23955   # Input might be given as Windows format, start by converting to
23956   # unix format.
23957   path="$BOOT_JDK"
23958   new_path=`$CYGPATH -u "$path"`
23959 
23960   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23961   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23962   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23963   # "foo.exe" is OK but "foo" is an error.
23964   #
23965   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23966   # It is also a way to make sure we got the proper file name for the real test later on.
23967   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23968   if test "x$test_shortpath" = x; then
23969     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23970 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23971     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23972   fi
23973 
23974   # Call helper function which possibly converts this using DOS-style short mode.
23975   # If so, the updated path is stored in $new_path.
23976 
23977   input_path="$new_path"
23978   # Check if we need to convert this using DOS-style short mode. If the path
23979   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23980   # take no chances and rewrite it.
23981   # Note: m4 eats our [], so we need to use [ and ] instead.
23982   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23983   if test "x$has_forbidden_chars" != x; then
23984     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23985     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23986     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23987     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23988       # Going to short mode and back again did indeed matter. Since short mode is
23989       # case insensitive, let's make it lowercase to improve readability.
23990       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23991       # Now convert it back to Unix-stile (cygpath)
23992       input_path=`$CYGPATH -u "$shortmode_path"`
23993       new_path="$input_path"
23994     fi
23995   fi
23996 
23997   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23998   if test "x$test_cygdrive_prefix" = x; then
23999     # As a simple fix, exclude /usr/bin since it's not a real path.
24000     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24001       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24002       # a path prefixed by /cygdrive for fixpath to work.
24003       new_path="$CYGWIN_ROOT_PATH$input_path"
24004     fi
24005   fi
24006 
24007 
24008   if test "x$path" != "x$new_path"; then
24009     BOOT_JDK="$new_path"
24010     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24011 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24012   fi
24013 
24014   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24015 
24016   path="$BOOT_JDK"
24017   has_colon=`$ECHO $path | $GREP ^.:`
24018   new_path="$path"
24019   if test "x$has_colon" = x; then
24020     # Not in mixed or Windows style, start by that.
24021     new_path=`cmd //c echo $path`
24022   fi
24023 
24024 
24025   input_path="$new_path"
24026   # Check if we need to convert this using DOS-style short mode. If the path
24027   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24028   # take no chances and rewrite it.
24029   # Note: m4 eats our [], so we need to use [ and ] instead.
24030   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24031   if test "x$has_forbidden_chars" != x; then
24032     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24033     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24034   fi
24035 
24036 
24037   windows_path="$new_path"
24038   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24039     unix_path=`$CYGPATH -u "$windows_path"`
24040     new_path="$unix_path"
24041   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24042     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24043     new_path="$unix_path"
24044   fi
24045 
24046   if test "x$path" != "x$new_path"; then
24047     BOOT_JDK="$new_path"
24048     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24049 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24050   fi
24051 
24052   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24053   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24054 
24055   else
24056     # We're on a posix platform. Hooray! :)
24057     path="$BOOT_JDK"
24058     has_space=`$ECHO "$path" | $GREP " "`
24059     if test "x$has_space" != x; then
24060       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24061 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24062       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24063     fi
24064 
24065     # Use eval to expand a potential ~
24066     eval path="$path"
24067     if test ! -f "$path" && test ! -d "$path"; then
24068       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24069     fi
24070 
24071     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24072   fi
24073 
24074               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24075 $as_echo_n "checking for Boot JDK... " >&6; }
24076               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24077 $as_echo "$BOOT_JDK" >&6; }
24078               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24079 $as_echo_n "checking Boot JDK version... " >&6; }
24080               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24081               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24082 $as_echo "$BOOT_JDK_VERSION" >&6; }
24083             fi # end check jdk version
24084           fi # end check rt.jar
24085         fi # end check javac
24086       fi # end check java
24087     fi # end check boot jdk found
24088   fi
24089 
24090 
24091   if test "x$BOOT_JDK_FOUND" = xno; then
24092     # Now execute the test
24093 
24094   BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines"
24095   BOOT_JDK_SUFFIX="/Contents/Home"
24096   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24097   if test "x$ALL_JDKS_FOUND" != x; then
24098     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24099 
24100   if test "x$BOOT_JDK_FOUND" = xno; then
24101     # Now execute the test
24102 
24103         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24104         if test -d "$BOOT_JDK"; then
24105           BOOT_JDK_FOUND=maybe
24106           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24107 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24108         fi
24109 
24110 
24111     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24112     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24113       # Do we have a bin/java?
24114       if test ! -x "$BOOT_JDK/bin/java"; then
24115         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24116 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24117         BOOT_JDK_FOUND=no
24118       else
24119         # Do we have a bin/javac?
24120         if test ! -x "$BOOT_JDK/bin/javac"; then
24121           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24122 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24123           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24124 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24125           BOOT_JDK_FOUND=no
24126         else
24127           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24128           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24129             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24130 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24131             BOOT_JDK_FOUND=no
24132           else
24133             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24134             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24135 
24136             # Extra M4 quote needed to protect [] in grep expression.
24137             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24138             if test "x$FOUND_CORRECT_VERSION" = x; then
24139               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24140 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24141               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24142 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24143               BOOT_JDK_FOUND=no
24144             else
24145               # We're done! :-)
24146               BOOT_JDK_FOUND=yes
24147 
24148   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24149 
24150   # Input might be given as Windows format, start by converting to
24151   # unix format.
24152   path="$BOOT_JDK"
24153   new_path=`$CYGPATH -u "$path"`
24154 
24155   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24156   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24157   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24158   # "foo.exe" is OK but "foo" is an error.
24159   #
24160   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24161   # It is also a way to make sure we got the proper file name for the real test later on.
24162   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24163   if test "x$test_shortpath" = x; then
24164     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24165 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24166     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24167   fi
24168 
24169   # Call helper function which possibly converts this using DOS-style short mode.
24170   # If so, the updated path is stored in $new_path.
24171 
24172   input_path="$new_path"
24173   # Check if we need to convert this using DOS-style short mode. If the path
24174   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24175   # take no chances and rewrite it.
24176   # Note: m4 eats our [], so we need to use [ and ] instead.
24177   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24178   if test "x$has_forbidden_chars" != x; then
24179     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24180     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24181     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24182     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24183       # Going to short mode and back again did indeed matter. Since short mode is
24184       # case insensitive, let's make it lowercase to improve readability.
24185       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24186       # Now convert it back to Unix-stile (cygpath)
24187       input_path=`$CYGPATH -u "$shortmode_path"`
24188       new_path="$input_path"
24189     fi
24190   fi
24191 
24192   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24193   if test "x$test_cygdrive_prefix" = x; then
24194     # As a simple fix, exclude /usr/bin since it's not a real path.
24195     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24196       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24197       # a path prefixed by /cygdrive for fixpath to work.
24198       new_path="$CYGWIN_ROOT_PATH$input_path"
24199     fi
24200   fi
24201 
24202 
24203   if test "x$path" != "x$new_path"; then
24204     BOOT_JDK="$new_path"
24205     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24206 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24207   fi
24208 
24209   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24210 
24211   path="$BOOT_JDK"
24212   has_colon=`$ECHO $path | $GREP ^.:`
24213   new_path="$path"
24214   if test "x$has_colon" = x; then
24215     # Not in mixed or Windows style, start by that.
24216     new_path=`cmd //c echo $path`
24217   fi
24218 
24219 
24220   input_path="$new_path"
24221   # Check if we need to convert this using DOS-style short mode. If the path
24222   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24223   # take no chances and rewrite it.
24224   # Note: m4 eats our [], so we need to use [ and ] instead.
24225   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24226   if test "x$has_forbidden_chars" != x; then
24227     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24228     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24229   fi
24230 
24231 
24232   windows_path="$new_path"
24233   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24234     unix_path=`$CYGPATH -u "$windows_path"`
24235     new_path="$unix_path"
24236   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24237     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24238     new_path="$unix_path"
24239   fi
24240 
24241   if test "x$path" != "x$new_path"; then
24242     BOOT_JDK="$new_path"
24243     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24244 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24245   fi
24246 
24247   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24248   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24249 
24250   else
24251     # We're on a posix platform. Hooray! :)
24252     path="$BOOT_JDK"
24253     has_space=`$ECHO "$path" | $GREP " "`
24254     if test "x$has_space" != x; then
24255       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24256 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24257       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24258     fi
24259 
24260     # Use eval to expand a potential ~
24261     eval path="$path"
24262     if test ! -f "$path" && test ! -d "$path"; then
24263       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24264     fi
24265 
24266     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24267   fi
24268 
24269               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24270 $as_echo_n "checking for Boot JDK... " >&6; }
24271               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24272 $as_echo "$BOOT_JDK" >&6; }
24273               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24274 $as_echo_n "checking Boot JDK version... " >&6; }
24275               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24276               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24277 $as_echo "$BOOT_JDK_VERSION" >&6; }
24278             fi # end check jdk version
24279           fi # end check rt.jar
24280         fi # end check javac
24281       fi # end check java
24282     fi # end check boot jdk found
24283   fi
24284 
24285     done
24286   fi
24287 
24288 
24289     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24290     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24291       # Do we have a bin/java?
24292       if test ! -x "$BOOT_JDK/bin/java"; then
24293         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24294 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24295         BOOT_JDK_FOUND=no
24296       else
24297         # Do we have a bin/javac?
24298         if test ! -x "$BOOT_JDK/bin/javac"; then
24299           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24300 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24301           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24302 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24303           BOOT_JDK_FOUND=no
24304         else
24305           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24306           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24307             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24308 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24309             BOOT_JDK_FOUND=no
24310           else
24311             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24312             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24313 
24314             # Extra M4 quote needed to protect [] in grep expression.
24315             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24316             if test "x$FOUND_CORRECT_VERSION" = x; then
24317               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24318 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24319               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24320 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24321               BOOT_JDK_FOUND=no
24322             else
24323               # We're done! :-)
24324               BOOT_JDK_FOUND=yes
24325 
24326   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24327 
24328   # Input might be given as Windows format, start by converting to
24329   # unix format.
24330   path="$BOOT_JDK"
24331   new_path=`$CYGPATH -u "$path"`
24332 
24333   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24334   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24335   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24336   # "foo.exe" is OK but "foo" is an error.
24337   #
24338   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24339   # It is also a way to make sure we got the proper file name for the real test later on.
24340   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24341   if test "x$test_shortpath" = x; then
24342     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24343 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24344     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24345   fi
24346 
24347   # Call helper function which possibly converts this using DOS-style short mode.
24348   # If so, the updated path is stored in $new_path.
24349 
24350   input_path="$new_path"
24351   # Check if we need to convert this using DOS-style short mode. If the path
24352   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24353   # take no chances and rewrite it.
24354   # Note: m4 eats our [], so we need to use [ and ] instead.
24355   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24356   if test "x$has_forbidden_chars" != x; then
24357     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24358     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24359     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24360     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24361       # Going to short mode and back again did indeed matter. Since short mode is
24362       # case insensitive, let's make it lowercase to improve readability.
24363       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24364       # Now convert it back to Unix-stile (cygpath)
24365       input_path=`$CYGPATH -u "$shortmode_path"`
24366       new_path="$input_path"
24367     fi
24368   fi
24369 
24370   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24371   if test "x$test_cygdrive_prefix" = x; then
24372     # As a simple fix, exclude /usr/bin since it's not a real path.
24373     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24374       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24375       # a path prefixed by /cygdrive for fixpath to work.
24376       new_path="$CYGWIN_ROOT_PATH$input_path"
24377     fi
24378   fi
24379 
24380 
24381   if test "x$path" != "x$new_path"; then
24382     BOOT_JDK="$new_path"
24383     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24384 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24385   fi
24386 
24387   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24388 
24389   path="$BOOT_JDK"
24390   has_colon=`$ECHO $path | $GREP ^.:`
24391   new_path="$path"
24392   if test "x$has_colon" = x; then
24393     # Not in mixed or Windows style, start by that.
24394     new_path=`cmd //c echo $path`
24395   fi
24396 
24397 
24398   input_path="$new_path"
24399   # Check if we need to convert this using DOS-style short mode. If the path
24400   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24401   # take no chances and rewrite it.
24402   # Note: m4 eats our [], so we need to use [ and ] instead.
24403   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24404   if test "x$has_forbidden_chars" != x; then
24405     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24406     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24407   fi
24408 
24409 
24410   windows_path="$new_path"
24411   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24412     unix_path=`$CYGPATH -u "$windows_path"`
24413     new_path="$unix_path"
24414   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24415     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24416     new_path="$unix_path"
24417   fi
24418 
24419   if test "x$path" != "x$new_path"; then
24420     BOOT_JDK="$new_path"
24421     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24422 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24423   fi
24424 
24425   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24426   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24427 
24428   else
24429     # We're on a posix platform. Hooray! :)
24430     path="$BOOT_JDK"
24431     has_space=`$ECHO "$path" | $GREP " "`
24432     if test "x$has_space" != x; then
24433       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24434 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24435       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24436     fi
24437 
24438     # Use eval to expand a potential ~
24439     eval path="$path"
24440     if test ! -f "$path" && test ! -d "$path"; then
24441       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24442     fi
24443 
24444     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24445   fi
24446 
24447               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24448 $as_echo_n "checking for Boot JDK... " >&6; }
24449               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24450 $as_echo "$BOOT_JDK" >&6; }
24451               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24452 $as_echo_n "checking Boot JDK version... " >&6; }
24453               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24454               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24455 $as_echo "$BOOT_JDK_VERSION" >&6; }
24456             fi # end check jdk version
24457           fi # end check rt.jar
24458         fi # end check javac
24459       fi # end check java
24460     fi # end check boot jdk found
24461   fi
24462 
24463   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
24464 
24465   if test "x$BOOT_JDK_FOUND" = xno; then
24466     # Now execute the test
24467 
24468   BOOT_JDK_PREFIX="/usr/lib/jvm"
24469   BOOT_JDK_SUFFIX=""
24470   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24471   if test "x$ALL_JDKS_FOUND" != x; then
24472     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24473 
24474   if test "x$BOOT_JDK_FOUND" = xno; then
24475     # Now execute the test
24476 
24477         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24478         if test -d "$BOOT_JDK"; then
24479           BOOT_JDK_FOUND=maybe
24480           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24481 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24482         fi
24483 
24484 
24485     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24486     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24487       # Do we have a bin/java?
24488       if test ! -x "$BOOT_JDK/bin/java"; then
24489         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24490 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24491         BOOT_JDK_FOUND=no
24492       else
24493         # Do we have a bin/javac?
24494         if test ! -x "$BOOT_JDK/bin/javac"; then
24495           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24496 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24497           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24498 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24499           BOOT_JDK_FOUND=no
24500         else
24501           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24502           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24503             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24504 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24505             BOOT_JDK_FOUND=no
24506           else
24507             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24508             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24509 
24510             # Extra M4 quote needed to protect [] in grep expression.
24511             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24512             if test "x$FOUND_CORRECT_VERSION" = x; then
24513               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24514 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24515               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24516 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24517               BOOT_JDK_FOUND=no
24518             else
24519               # We're done! :-)
24520               BOOT_JDK_FOUND=yes
24521 
24522   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24523 
24524   # Input might be given as Windows format, start by converting to
24525   # unix format.
24526   path="$BOOT_JDK"
24527   new_path=`$CYGPATH -u "$path"`
24528 
24529   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24530   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24531   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24532   # "foo.exe" is OK but "foo" is an error.
24533   #
24534   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24535   # It is also a way to make sure we got the proper file name for the real test later on.
24536   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24537   if test "x$test_shortpath" = x; then
24538     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24539 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24540     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24541   fi
24542 
24543   # Call helper function which possibly converts this using DOS-style short mode.
24544   # If so, the updated path is stored in $new_path.
24545 
24546   input_path="$new_path"
24547   # Check if we need to convert this using DOS-style short mode. If the path
24548   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24549   # take no chances and rewrite it.
24550   # Note: m4 eats our [], so we need to use [ and ] instead.
24551   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24552   if test "x$has_forbidden_chars" != x; then
24553     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24554     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24555     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24556     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24557       # Going to short mode and back again did indeed matter. Since short mode is
24558       # case insensitive, let's make it lowercase to improve readability.
24559       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24560       # Now convert it back to Unix-stile (cygpath)
24561       input_path=`$CYGPATH -u "$shortmode_path"`
24562       new_path="$input_path"
24563     fi
24564   fi
24565 
24566   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24567   if test "x$test_cygdrive_prefix" = x; then
24568     # As a simple fix, exclude /usr/bin since it's not a real path.
24569     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24570       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24571       # a path prefixed by /cygdrive for fixpath to work.
24572       new_path="$CYGWIN_ROOT_PATH$input_path"
24573     fi
24574   fi
24575 
24576 
24577   if test "x$path" != "x$new_path"; then
24578     BOOT_JDK="$new_path"
24579     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24580 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24581   fi
24582 
24583   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24584 
24585   path="$BOOT_JDK"
24586   has_colon=`$ECHO $path | $GREP ^.:`
24587   new_path="$path"
24588   if test "x$has_colon" = x; then
24589     # Not in mixed or Windows style, start by that.
24590     new_path=`cmd //c echo $path`
24591   fi
24592 
24593 
24594   input_path="$new_path"
24595   # Check if we need to convert this using DOS-style short mode. If the path
24596   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24597   # take no chances and rewrite it.
24598   # Note: m4 eats our [], so we need to use [ and ] instead.
24599   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24600   if test "x$has_forbidden_chars" != x; then
24601     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24602     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24603   fi
24604 
24605 
24606   windows_path="$new_path"
24607   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24608     unix_path=`$CYGPATH -u "$windows_path"`
24609     new_path="$unix_path"
24610   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24611     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24612     new_path="$unix_path"
24613   fi
24614 
24615   if test "x$path" != "x$new_path"; then
24616     BOOT_JDK="$new_path"
24617     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24618 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24619   fi
24620 
24621   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24622   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24623 
24624   else
24625     # We're on a posix platform. Hooray! :)
24626     path="$BOOT_JDK"
24627     has_space=`$ECHO "$path" | $GREP " "`
24628     if test "x$has_space" != x; then
24629       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24630 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24631       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24632     fi
24633 
24634     # Use eval to expand a potential ~
24635     eval path="$path"
24636     if test ! -f "$path" && test ! -d "$path"; then
24637       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24638     fi
24639 
24640     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24641   fi
24642 
24643               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24644 $as_echo_n "checking for Boot JDK... " >&6; }
24645               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24646 $as_echo "$BOOT_JDK" >&6; }
24647               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24648 $as_echo_n "checking Boot JDK version... " >&6; }
24649               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24650               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24651 $as_echo "$BOOT_JDK_VERSION" >&6; }
24652             fi # end check jdk version
24653           fi # end check rt.jar
24654         fi # end check javac
24655       fi # end check java
24656     fi # end check boot jdk found
24657   fi
24658 
24659     done
24660   fi
24661 
24662 
24663     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24664     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24665       # Do we have a bin/java?
24666       if test ! -x "$BOOT_JDK/bin/java"; then
24667         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24668 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24669         BOOT_JDK_FOUND=no
24670       else
24671         # Do we have a bin/javac?
24672         if test ! -x "$BOOT_JDK/bin/javac"; then
24673           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24674 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24675           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24676 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24677           BOOT_JDK_FOUND=no
24678         else
24679           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24680           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24681             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24682 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24683             BOOT_JDK_FOUND=no
24684           else
24685             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24686             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24687 
24688             # Extra M4 quote needed to protect [] in grep expression.
24689             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24690             if test "x$FOUND_CORRECT_VERSION" = x; then
24691               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24692 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24693               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24694 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24695               BOOT_JDK_FOUND=no
24696             else
24697               # We're done! :-)
24698               BOOT_JDK_FOUND=yes
24699 
24700   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24701 
24702   # Input might be given as Windows format, start by converting to
24703   # unix format.
24704   path="$BOOT_JDK"
24705   new_path=`$CYGPATH -u "$path"`
24706 
24707   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24708   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24709   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24710   # "foo.exe" is OK but "foo" is an error.
24711   #
24712   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24713   # It is also a way to make sure we got the proper file name for the real test later on.
24714   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24715   if test "x$test_shortpath" = x; then
24716     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24717 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24718     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24719   fi
24720 
24721   # Call helper function which possibly converts this using DOS-style short mode.
24722   # If so, the updated path is stored in $new_path.
24723 
24724   input_path="$new_path"
24725   # Check if we need to convert this using DOS-style short mode. If the path
24726   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24727   # take no chances and rewrite it.
24728   # Note: m4 eats our [], so we need to use [ and ] instead.
24729   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24730   if test "x$has_forbidden_chars" != x; then
24731     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24732     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24733     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24734     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24735       # Going to short mode and back again did indeed matter. Since short mode is
24736       # case insensitive, let's make it lowercase to improve readability.
24737       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24738       # Now convert it back to Unix-stile (cygpath)
24739       input_path=`$CYGPATH -u "$shortmode_path"`
24740       new_path="$input_path"
24741     fi
24742   fi
24743 
24744   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24745   if test "x$test_cygdrive_prefix" = x; then
24746     # As a simple fix, exclude /usr/bin since it's not a real path.
24747     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24748       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24749       # a path prefixed by /cygdrive for fixpath to work.
24750       new_path="$CYGWIN_ROOT_PATH$input_path"
24751     fi
24752   fi
24753 
24754 
24755   if test "x$path" != "x$new_path"; then
24756     BOOT_JDK="$new_path"
24757     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24758 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24759   fi
24760 
24761   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24762 
24763   path="$BOOT_JDK"
24764   has_colon=`$ECHO $path | $GREP ^.:`
24765   new_path="$path"
24766   if test "x$has_colon" = x; then
24767     # Not in mixed or Windows style, start by that.
24768     new_path=`cmd //c echo $path`
24769   fi
24770 
24771 
24772   input_path="$new_path"
24773   # Check if we need to convert this using DOS-style short mode. If the path
24774   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24775   # take no chances and rewrite it.
24776   # Note: m4 eats our [], so we need to use [ and ] instead.
24777   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24778   if test "x$has_forbidden_chars" != x; then
24779     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24780     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24781   fi
24782 
24783 
24784   windows_path="$new_path"
24785   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24786     unix_path=`$CYGPATH -u "$windows_path"`
24787     new_path="$unix_path"
24788   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24789     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24790     new_path="$unix_path"
24791   fi
24792 
24793   if test "x$path" != "x$new_path"; then
24794     BOOT_JDK="$new_path"
24795     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24796 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24797   fi
24798 
24799   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24800   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24801 
24802   else
24803     # We're on a posix platform. Hooray! :)
24804     path="$BOOT_JDK"
24805     has_space=`$ECHO "$path" | $GREP " "`
24806     if test "x$has_space" != x; then
24807       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24808 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24809       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24810     fi
24811 
24812     # Use eval to expand a potential ~
24813     eval path="$path"
24814     if test ! -f "$path" && test ! -d "$path"; then
24815       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24816     fi
24817 
24818     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24819   fi
24820 
24821               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24822 $as_echo_n "checking for Boot JDK... " >&6; }
24823               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24824 $as_echo "$BOOT_JDK" >&6; }
24825               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24826 $as_echo_n "checking Boot JDK version... " >&6; }
24827               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24828               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24829 $as_echo "$BOOT_JDK_VERSION" >&6; }
24830             fi # end check jdk version
24831           fi # end check rt.jar
24832         fi # end check javac
24833       fi # end check java
24834     fi # end check boot jdk found
24835   fi
24836 
24837   fi
24838 
24839 
24840     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24841     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24842       # Do we have a bin/java?
24843       if test ! -x "$BOOT_JDK/bin/java"; then
24844         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24845 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24846         BOOT_JDK_FOUND=no
24847       else
24848         # Do we have a bin/javac?
24849         if test ! -x "$BOOT_JDK/bin/javac"; then
24850           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24851 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24852           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24853 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24854           BOOT_JDK_FOUND=no
24855         else
24856           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24857           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24858             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24859 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24860             BOOT_JDK_FOUND=no
24861           else
24862             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24863             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24864 
24865             # Extra M4 quote needed to protect [] in grep expression.
24866             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24867             if test "x$FOUND_CORRECT_VERSION" = x; then
24868               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24869 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24870               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24871 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24872               BOOT_JDK_FOUND=no
24873             else
24874               # We're done! :-)
24875               BOOT_JDK_FOUND=yes
24876 
24877   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24878 
24879   # Input might be given as Windows format, start by converting to
24880   # unix format.
24881   path="$BOOT_JDK"
24882   new_path=`$CYGPATH -u "$path"`
24883 
24884   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24885   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24886   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24887   # "foo.exe" is OK but "foo" is an error.
24888   #
24889   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24890   # It is also a way to make sure we got the proper file name for the real test later on.
24891   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24892   if test "x$test_shortpath" = x; then
24893     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24894 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24895     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24896   fi
24897 
24898   # Call helper function which possibly converts this using DOS-style short mode.
24899   # If so, the updated path is stored in $new_path.
24900 
24901   input_path="$new_path"
24902   # Check if we need to convert this using DOS-style short mode. If the path
24903   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24904   # take no chances and rewrite it.
24905   # Note: m4 eats our [], so we need to use [ and ] instead.
24906   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24907   if test "x$has_forbidden_chars" != x; then
24908     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24909     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24910     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24911     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24912       # Going to short mode and back again did indeed matter. Since short mode is
24913       # case insensitive, let's make it lowercase to improve readability.
24914       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24915       # Now convert it back to Unix-stile (cygpath)
24916       input_path=`$CYGPATH -u "$shortmode_path"`
24917       new_path="$input_path"
24918     fi
24919   fi
24920 
24921   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24922   if test "x$test_cygdrive_prefix" = x; then
24923     # As a simple fix, exclude /usr/bin since it's not a real path.
24924     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24925       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24926       # a path prefixed by /cygdrive for fixpath to work.
24927       new_path="$CYGWIN_ROOT_PATH$input_path"
24928     fi
24929   fi
24930 
24931 
24932   if test "x$path" != "x$new_path"; then
24933     BOOT_JDK="$new_path"
24934     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24935 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24936   fi
24937 
24938   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24939 
24940   path="$BOOT_JDK"
24941   has_colon=`$ECHO $path | $GREP ^.:`
24942   new_path="$path"
24943   if test "x$has_colon" = x; then
24944     # Not in mixed or Windows style, start by that.
24945     new_path=`cmd //c echo $path`
24946   fi
24947 
24948 
24949   input_path="$new_path"
24950   # Check if we need to convert this using DOS-style short mode. If the path
24951   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24952   # take no chances and rewrite it.
24953   # Note: m4 eats our [], so we need to use [ and ] instead.
24954   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24955   if test "x$has_forbidden_chars" != x; then
24956     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24957     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24958   fi
24959 
24960 
24961   windows_path="$new_path"
24962   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24963     unix_path=`$CYGPATH -u "$windows_path"`
24964     new_path="$unix_path"
24965   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24966     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24967     new_path="$unix_path"
24968   fi
24969 
24970   if test "x$path" != "x$new_path"; then
24971     BOOT_JDK="$new_path"
24972     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24973 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24974   fi
24975 
24976   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24977   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24978 
24979   else
24980     # We're on a posix platform. Hooray! :)
24981     path="$BOOT_JDK"
24982     has_space=`$ECHO "$path" | $GREP " "`
24983     if test "x$has_space" != x; then
24984       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24985 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24986       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24987     fi
24988 
24989     # Use eval to expand a potential ~
24990     eval path="$path"
24991     if test ! -f "$path" && test ! -d "$path"; then
24992       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24993     fi
24994 
24995     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24996   fi
24997 
24998               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24999 $as_echo_n "checking for Boot JDK... " >&6; }
25000               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25001 $as_echo "$BOOT_JDK" >&6; }
25002               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25003 $as_echo_n "checking Boot JDK version... " >&6; }
25004               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25005               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25006 $as_echo "$BOOT_JDK_VERSION" >&6; }
25007             fi # end check jdk version
25008           fi # end check rt.jar
25009         fi # end check javac
25010       fi # end check java
25011     fi # end check boot jdk found
25012   fi
25013 
25014 
25015   # If we haven't found anything yet, we've truly lost. Give up.
25016   if test "x$BOOT_JDK_FOUND" = xno; then
25017 
25018   # Print a helpful message on how to acquire the necessary build dependency.
25019   # openjdk is the help tag: freetype, cups, pulse, alsa etc
25020   MISSING_DEPENDENCY=openjdk
25021 
25022   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25023     cygwin_help $MISSING_DEPENDENCY
25024   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25025     msys_help $MISSING_DEPENDENCY
25026   else
25027     PKGHANDLER_COMMAND=
25028 
25029     case $PKGHANDLER in
25030       apt-get)
25031         apt_help     $MISSING_DEPENDENCY ;;
25032       yum)
25033         yum_help     $MISSING_DEPENDENCY ;;
25034       port)
25035         port_help    $MISSING_DEPENDENCY ;;
25036       pkgutil)
25037         pkgutil_help $MISSING_DEPENDENCY ;;
25038       pkgadd)
25039         pkgadd_help  $MISSING_DEPENDENCY ;;
25040     esac
25041 
25042     if test "x$PKGHANDLER_COMMAND" != x; then
25043       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
25044     fi
25045   fi
25046 
25047     { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5
25048 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;}
25049     { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5
25050 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25051     as_fn_error $? "Cannot continue" "$LINENO" 5
25052   fi
25053 
25054   # Setup proper paths for what we found
25055   BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar"
25056   if test ! -f "$BOOT_RTJAR"; then
25057     # On MacOSX it is called classes.jar
25058     BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar"
25059     if test -f "$BOOT_RTJAR"; then
25060       # Remove the ..
25061       BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}"
25062     fi
25063   fi
25064   BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar"
25065   BOOT_JDK="$BOOT_JDK"
25066 
25067 
25068 
25069 
25070   # Setup tools from the Boot JDK.
25071 
25072   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25073 
25074   # Publish this variable in the help.
25075 
25076 
25077   if test "x$JAVA" = x; then
25078     # The variable is not set by user, try to locate tool using the code snippet
25079 
25080       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25081 $as_echo_n "checking for java in Boot JDK... " >&6; }
25082       JAVA=$BOOT_JDK/bin/java
25083       if test ! -x $JAVA; then
25084         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25085 $as_echo "not found" >&6; }
25086         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25087 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25088         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25089       fi
25090       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25091 $as_echo "ok" >&6; }
25092 
25093 
25094   else
25095     # The variable is set, but is it from the command line or the environment?
25096 
25097     # Try to remove the string !JAVA! from our list.
25098     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/}
25099     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25100       # If it failed, the variable was not from the command line. Ignore it,
25101       # but warn the user (except for BASH, which is always set by the calling BASH).
25102       if test "xJAVA" != xBASH; then
25103         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5
25104 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;}
25105       fi
25106       # Try to locate tool using the code snippet
25107 
25108       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25109 $as_echo_n "checking for java in Boot JDK... " >&6; }
25110       JAVA=$BOOT_JDK/bin/java
25111       if test ! -x $JAVA; then
25112         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25113 $as_echo "not found" >&6; }
25114         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25115 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25116         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25117       fi
25118       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25119 $as_echo "ok" >&6; }
25120 
25121 
25122     else
25123       # If it succeeded, then it was overridden by the user. We will use it
25124       # for the tool.
25125 
25126       # First remove it from the list of overridden variables, so we can test
25127       # for unknown variables in the end.
25128       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25129 
25130       # Check if the provided tool contains a complete path.
25131       tool_specified="$JAVA"
25132       tool_basename="${tool_specified##*/}"
25133       if test "x$tool_basename" = "x$tool_specified"; then
25134         # A command without a complete path is provided, search $PATH.
25135         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5
25136 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;}
25137         # Extract the first word of "$tool_basename", so it can be a program name with args.
25138 set dummy $tool_basename; ac_word=$2
25139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25140 $as_echo_n "checking for $ac_word... " >&6; }
25141 if ${ac_cv_path_JAVA+:} false; then :
25142   $as_echo_n "(cached) " >&6
25143 else
25144   case $JAVA in
25145   [\\/]* | ?:[\\/]*)
25146   ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path.
25147   ;;
25148   *)
25149   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25150 for as_dir in $PATH
25151 do
25152   IFS=$as_save_IFS
25153   test -z "$as_dir" && as_dir=.
25154     for ac_exec_ext in '' $ac_executable_extensions; do
25155   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25156     ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext"
25157     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25158     break 2
25159   fi
25160 done
25161   done
25162 IFS=$as_save_IFS
25163 
25164   ;;
25165 esac
25166 fi
25167 JAVA=$ac_cv_path_JAVA
25168 if test -n "$JAVA"; then
25169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5
25170 $as_echo "$JAVA" >&6; }
25171 else
25172   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25173 $as_echo "no" >&6; }
25174 fi
25175 
25176 
25177         if test "x$JAVA" = x; then
25178           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25179         fi
25180       else
25181         # Otherwise we believe it is a complete path. Use it as it is.
25182         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5
25183 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;}
25184         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5
25185 $as_echo_n "checking for JAVA... " >&6; }
25186         if test ! -x "$tool_specified"; then
25187           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25188 $as_echo "not found" >&6; }
25189           as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5
25190         fi
25191         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25192 $as_echo "$tool_specified" >&6; }
25193       fi
25194     fi
25195   fi
25196 
25197 
25198 
25199   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25200 
25201   # Publish this variable in the help.
25202 
25203 
25204   if test "x$JAVAC" = x; then
25205     # The variable is not set by user, try to locate tool using the code snippet
25206 
25207       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25208 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25209       JAVAC=$BOOT_JDK/bin/javac
25210       if test ! -x $JAVAC; then
25211         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25212 $as_echo "not found" >&6; }
25213         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25214 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25215         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25216       fi
25217       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25218 $as_echo "ok" >&6; }
25219 
25220 
25221   else
25222     # The variable is set, but is it from the command line or the environment?
25223 
25224     # Try to remove the string !JAVAC! from our list.
25225     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/}
25226     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25227       # If it failed, the variable was not from the command line. Ignore it,
25228       # but warn the user (except for BASH, which is always set by the calling BASH).
25229       if test "xJAVAC" != xBASH; then
25230         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5
25231 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;}
25232       fi
25233       # Try to locate tool using the code snippet
25234 
25235       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25236 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25237       JAVAC=$BOOT_JDK/bin/javac
25238       if test ! -x $JAVAC; then
25239         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25240 $as_echo "not found" >&6; }
25241         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25242 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25243         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25244       fi
25245       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25246 $as_echo "ok" >&6; }
25247 
25248 
25249     else
25250       # If it succeeded, then it was overridden by the user. We will use it
25251       # for the tool.
25252 
25253       # First remove it from the list of overridden variables, so we can test
25254       # for unknown variables in the end.
25255       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25256 
25257       # Check if the provided tool contains a complete path.
25258       tool_specified="$JAVAC"
25259       tool_basename="${tool_specified##*/}"
25260       if test "x$tool_basename" = "x$tool_specified"; then
25261         # A command without a complete path is provided, search $PATH.
25262         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5
25263 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;}
25264         # Extract the first word of "$tool_basename", so it can be a program name with args.
25265 set dummy $tool_basename; ac_word=$2
25266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25267 $as_echo_n "checking for $ac_word... " >&6; }
25268 if ${ac_cv_path_JAVAC+:} false; then :
25269   $as_echo_n "(cached) " >&6
25270 else
25271   case $JAVAC in
25272   [\\/]* | ?:[\\/]*)
25273   ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path.
25274   ;;
25275   *)
25276   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25277 for as_dir in $PATH
25278 do
25279   IFS=$as_save_IFS
25280   test -z "$as_dir" && as_dir=.
25281     for ac_exec_ext in '' $ac_executable_extensions; do
25282   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25283     ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext"
25284     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25285     break 2
25286   fi
25287 done
25288   done
25289 IFS=$as_save_IFS
25290 
25291   ;;
25292 esac
25293 fi
25294 JAVAC=$ac_cv_path_JAVAC
25295 if test -n "$JAVAC"; then
25296   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5
25297 $as_echo "$JAVAC" >&6; }
25298 else
25299   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25300 $as_echo "no" >&6; }
25301 fi
25302 
25303 
25304         if test "x$JAVAC" = x; then
25305           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25306         fi
25307       else
25308         # Otherwise we believe it is a complete path. Use it as it is.
25309         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5
25310 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;}
25311         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5
25312 $as_echo_n "checking for JAVAC... " >&6; }
25313         if test ! -x "$tool_specified"; then
25314           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25315 $as_echo "not found" >&6; }
25316           as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5
25317         fi
25318         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25319 $as_echo "$tool_specified" >&6; }
25320       fi
25321     fi
25322   fi
25323 
25324 
25325 
25326   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25327 
25328   # Publish this variable in the help.
25329 
25330 
25331   if test "x$JAVAH" = x; then
25332     # The variable is not set by user, try to locate tool using the code snippet
25333 
25334       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25335 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25336       JAVAH=$BOOT_JDK/bin/javah
25337       if test ! -x $JAVAH; then
25338         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25339 $as_echo "not found" >&6; }
25340         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25341 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25342         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25343       fi
25344       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25345 $as_echo "ok" >&6; }
25346 
25347 
25348   else
25349     # The variable is set, but is it from the command line or the environment?
25350 
25351     # Try to remove the string !JAVAH! from our list.
25352     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/}
25353     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25354       # If it failed, the variable was not from the command line. Ignore it,
25355       # but warn the user (except for BASH, which is always set by the calling BASH).
25356       if test "xJAVAH" != xBASH; then
25357         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5
25358 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;}
25359       fi
25360       # Try to locate tool using the code snippet
25361 
25362       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25363 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25364       JAVAH=$BOOT_JDK/bin/javah
25365       if test ! -x $JAVAH; then
25366         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25367 $as_echo "not found" >&6; }
25368         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25369 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25370         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25371       fi
25372       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25373 $as_echo "ok" >&6; }
25374 
25375 
25376     else
25377       # If it succeeded, then it was overridden by the user. We will use it
25378       # for the tool.
25379 
25380       # First remove it from the list of overridden variables, so we can test
25381       # for unknown variables in the end.
25382       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25383 
25384       # Check if the provided tool contains a complete path.
25385       tool_specified="$JAVAH"
25386       tool_basename="${tool_specified##*/}"
25387       if test "x$tool_basename" = "x$tool_specified"; then
25388         # A command without a complete path is provided, search $PATH.
25389         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5
25390 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;}
25391         # Extract the first word of "$tool_basename", so it can be a program name with args.
25392 set dummy $tool_basename; ac_word=$2
25393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25394 $as_echo_n "checking for $ac_word... " >&6; }
25395 if ${ac_cv_path_JAVAH+:} false; then :
25396   $as_echo_n "(cached) " >&6
25397 else
25398   case $JAVAH in
25399   [\\/]* | ?:[\\/]*)
25400   ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path.
25401   ;;
25402   *)
25403   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25404 for as_dir in $PATH
25405 do
25406   IFS=$as_save_IFS
25407   test -z "$as_dir" && as_dir=.
25408     for ac_exec_ext in '' $ac_executable_extensions; do
25409   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25410     ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext"
25411     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25412     break 2
25413   fi
25414 done
25415   done
25416 IFS=$as_save_IFS
25417 
25418   ;;
25419 esac
25420 fi
25421 JAVAH=$ac_cv_path_JAVAH
25422 if test -n "$JAVAH"; then
25423   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5
25424 $as_echo "$JAVAH" >&6; }
25425 else
25426   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25427 $as_echo "no" >&6; }
25428 fi
25429 
25430 
25431         if test "x$JAVAH" = x; then
25432           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25433         fi
25434       else
25435         # Otherwise we believe it is a complete path. Use it as it is.
25436         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5
25437 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;}
25438         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5
25439 $as_echo_n "checking for JAVAH... " >&6; }
25440         if test ! -x "$tool_specified"; then
25441           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25442 $as_echo "not found" >&6; }
25443           as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5
25444         fi
25445         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25446 $as_echo "$tool_specified" >&6; }
25447       fi
25448     fi
25449   fi
25450 
25451 
25452 
25453   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25454 
25455   # Publish this variable in the help.
25456 
25457 
25458   if test "x$JAR" = x; then
25459     # The variable is not set by user, try to locate tool using the code snippet
25460 
25461       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25462 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25463       JAR=$BOOT_JDK/bin/jar
25464       if test ! -x $JAR; then
25465         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25466 $as_echo "not found" >&6; }
25467         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25468 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25469         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25470       fi
25471       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25472 $as_echo "ok" >&6; }
25473 
25474 
25475   else
25476     # The variable is set, but is it from the command line or the environment?
25477 
25478     # Try to remove the string !JAR! from our list.
25479     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/}
25480     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25481       # If it failed, the variable was not from the command line. Ignore it,
25482       # but warn the user (except for BASH, which is always set by the calling BASH).
25483       if test "xJAR" != xBASH; then
25484         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5
25485 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;}
25486       fi
25487       # Try to locate tool using the code snippet
25488 
25489       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25490 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25491       JAR=$BOOT_JDK/bin/jar
25492       if test ! -x $JAR; then
25493         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25494 $as_echo "not found" >&6; }
25495         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25496 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25497         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25498       fi
25499       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25500 $as_echo "ok" >&6; }
25501 
25502 
25503     else
25504       # If it succeeded, then it was overridden by the user. We will use it
25505       # for the tool.
25506 
25507       # First remove it from the list of overridden variables, so we can test
25508       # for unknown variables in the end.
25509       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25510 
25511       # Check if the provided tool contains a complete path.
25512       tool_specified="$JAR"
25513       tool_basename="${tool_specified##*/}"
25514       if test "x$tool_basename" = "x$tool_specified"; then
25515         # A command without a complete path is provided, search $PATH.
25516         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5
25517 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;}
25518         # Extract the first word of "$tool_basename", so it can be a program name with args.
25519 set dummy $tool_basename; ac_word=$2
25520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25521 $as_echo_n "checking for $ac_word... " >&6; }
25522 if ${ac_cv_path_JAR+:} false; then :
25523   $as_echo_n "(cached) " >&6
25524 else
25525   case $JAR in
25526   [\\/]* | ?:[\\/]*)
25527   ac_cv_path_JAR="$JAR" # Let the user override the test with a path.
25528   ;;
25529   *)
25530   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25531 for as_dir in $PATH
25532 do
25533   IFS=$as_save_IFS
25534   test -z "$as_dir" && as_dir=.
25535     for ac_exec_ext in '' $ac_executable_extensions; do
25536   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25537     ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext"
25538     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25539     break 2
25540   fi
25541 done
25542   done
25543 IFS=$as_save_IFS
25544 
25545   ;;
25546 esac
25547 fi
25548 JAR=$ac_cv_path_JAR
25549 if test -n "$JAR"; then
25550   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5
25551 $as_echo "$JAR" >&6; }
25552 else
25553   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25554 $as_echo "no" >&6; }
25555 fi
25556 
25557 
25558         if test "x$JAR" = x; then
25559           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25560         fi
25561       else
25562         # Otherwise we believe it is a complete path. Use it as it is.
25563         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5
25564 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;}
25565         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5
25566 $as_echo_n "checking for JAR... " >&6; }
25567         if test ! -x "$tool_specified"; then
25568           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25569 $as_echo "not found" >&6; }
25570           as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5
25571         fi
25572         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25573 $as_echo "$tool_specified" >&6; }
25574       fi
25575     fi
25576   fi
25577 
25578 
25579 
25580   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25581 
25582   # Publish this variable in the help.
25583 
25584 
25585   if test "x$NATIVE2ASCII" = x; then
25586     # The variable is not set by user, try to locate tool using the code snippet
25587 
25588       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25589 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25590       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25591       if test ! -x $NATIVE2ASCII; then
25592         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25593 $as_echo "not found" >&6; }
25594         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25595 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25596         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25597       fi
25598       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25599 $as_echo "ok" >&6; }
25600 
25601 
25602   else
25603     # The variable is set, but is it from the command line or the environment?
25604 
25605     # Try to remove the string !NATIVE2ASCII! from our list.
25606     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NATIVE2ASCII!/}
25607     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25608       # If it failed, the variable was not from the command line. Ignore it,
25609       # but warn the user (except for BASH, which is always set by the calling BASH).
25610       if test "xNATIVE2ASCII" != xBASH; then
25611         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&5
25612 $as_echo "$as_me: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&2;}
25613       fi
25614       # Try to locate tool using the code snippet
25615 
25616       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25617 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25618       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25619       if test ! -x $NATIVE2ASCII; then
25620         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25621 $as_echo "not found" >&6; }
25622         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25623 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25624         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25625       fi
25626       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25627 $as_echo "ok" >&6; }
25628 
25629 
25630     else
25631       # If it succeeded, then it was overridden by the user. We will use it
25632       # for the tool.
25633 
25634       # First remove it from the list of overridden variables, so we can test
25635       # for unknown variables in the end.
25636       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25637 
25638       # Check if the provided tool contains a complete path.
25639       tool_specified="$NATIVE2ASCII"
25640       tool_basename="${tool_specified##*/}"
25641       if test "x$tool_basename" = "x$tool_specified"; then
25642         # A command without a complete path is provided, search $PATH.
25643         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&5
25644 $as_echo "$as_me: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&6;}
25645         # Extract the first word of "$tool_basename", so it can be a program name with args.
25646 set dummy $tool_basename; ac_word=$2
25647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25648 $as_echo_n "checking for $ac_word... " >&6; }
25649 if ${ac_cv_path_NATIVE2ASCII+:} false; then :
25650   $as_echo_n "(cached) " >&6
25651 else
25652   case $NATIVE2ASCII in
25653   [\\/]* | ?:[\\/]*)
25654   ac_cv_path_NATIVE2ASCII="$NATIVE2ASCII" # Let the user override the test with a path.
25655   ;;
25656   *)
25657   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25658 for as_dir in $PATH
25659 do
25660   IFS=$as_save_IFS
25661   test -z "$as_dir" && as_dir=.
25662     for ac_exec_ext in '' $ac_executable_extensions; do
25663   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25664     ac_cv_path_NATIVE2ASCII="$as_dir/$ac_word$ac_exec_ext"
25665     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25666     break 2
25667   fi
25668 done
25669   done
25670 IFS=$as_save_IFS
25671 
25672   ;;
25673 esac
25674 fi
25675 NATIVE2ASCII=$ac_cv_path_NATIVE2ASCII
25676 if test -n "$NATIVE2ASCII"; then
25677   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE2ASCII" >&5
25678 $as_echo "$NATIVE2ASCII" >&6; }
25679 else
25680   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25681 $as_echo "no" >&6; }
25682 fi
25683 
25684 
25685         if test "x$NATIVE2ASCII" = x; then
25686           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25687         fi
25688       else
25689         # Otherwise we believe it is a complete path. Use it as it is.
25690         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&5
25691 $as_echo "$as_me: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&6;}
25692         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NATIVE2ASCII" >&5
25693 $as_echo_n "checking for NATIVE2ASCII... " >&6; }
25694         if test ! -x "$tool_specified"; then
25695           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25696 $as_echo "not found" >&6; }
25697           as_fn_error $? "User supplied tool NATIVE2ASCII=$tool_specified does not exist or is not executable" "$LINENO" 5
25698         fi
25699         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25700 $as_echo "$tool_specified" >&6; }
25701       fi
25702     fi
25703   fi
25704 
25705 
25706 
25707   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25708 
25709   # Publish this variable in the help.
25710 
25711 
25712   if test "x$JARSIGNER" = x; then
25713     # The variable is not set by user, try to locate tool using the code snippet
25714 
25715       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25716 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25717       JARSIGNER=$BOOT_JDK/bin/jarsigner
25718       if test ! -x $JARSIGNER; then
25719         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25720 $as_echo "not found" >&6; }
25721         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25722 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25723         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25724       fi
25725       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25726 $as_echo "ok" >&6; }
25727 
25728 
25729   else
25730     # The variable is set, but is it from the command line or the environment?
25731 
25732     # Try to remove the string !JARSIGNER! from our list.
25733     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/}
25734     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25735       # If it failed, the variable was not from the command line. Ignore it,
25736       # but warn the user (except for BASH, which is always set by the calling BASH).
25737       if test "xJARSIGNER" != xBASH; then
25738         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5
25739 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;}
25740       fi
25741       # Try to locate tool using the code snippet
25742 
25743       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25744 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25745       JARSIGNER=$BOOT_JDK/bin/jarsigner
25746       if test ! -x $JARSIGNER; then
25747         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25748 $as_echo "not found" >&6; }
25749         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25750 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25751         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25752       fi
25753       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25754 $as_echo "ok" >&6; }
25755 
25756 
25757     else
25758       # If it succeeded, then it was overridden by the user. We will use it
25759       # for the tool.
25760 
25761       # First remove it from the list of overridden variables, so we can test
25762       # for unknown variables in the end.
25763       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25764 
25765       # Check if the provided tool contains a complete path.
25766       tool_specified="$JARSIGNER"
25767       tool_basename="${tool_specified##*/}"
25768       if test "x$tool_basename" = "x$tool_specified"; then
25769         # A command without a complete path is provided, search $PATH.
25770         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5
25771 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;}
25772         # Extract the first word of "$tool_basename", so it can be a program name with args.
25773 set dummy $tool_basename; ac_word=$2
25774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25775 $as_echo_n "checking for $ac_word... " >&6; }
25776 if ${ac_cv_path_JARSIGNER+:} false; then :
25777   $as_echo_n "(cached) " >&6
25778 else
25779   case $JARSIGNER in
25780   [\\/]* | ?:[\\/]*)
25781   ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path.
25782   ;;
25783   *)
25784   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25785 for as_dir in $PATH
25786 do
25787   IFS=$as_save_IFS
25788   test -z "$as_dir" && as_dir=.
25789     for ac_exec_ext in '' $ac_executable_extensions; do
25790   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25791     ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext"
25792     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25793     break 2
25794   fi
25795 done
25796   done
25797 IFS=$as_save_IFS
25798 
25799   ;;
25800 esac
25801 fi
25802 JARSIGNER=$ac_cv_path_JARSIGNER
25803 if test -n "$JARSIGNER"; then
25804   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5
25805 $as_echo "$JARSIGNER" >&6; }
25806 else
25807   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25808 $as_echo "no" >&6; }
25809 fi
25810 
25811 
25812         if test "x$JARSIGNER" = x; then
25813           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25814         fi
25815       else
25816         # Otherwise we believe it is a complete path. Use it as it is.
25817         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5
25818 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;}
25819         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5
25820 $as_echo_n "checking for JARSIGNER... " >&6; }
25821         if test ! -x "$tool_specified"; then
25822           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25823 $as_echo "not found" >&6; }
25824           as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5
25825         fi
25826         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25827 $as_echo "$tool_specified" >&6; }
25828       fi
25829     fi
25830   fi
25831 
25832 
25833 
25834   # Finally, set some other options...
25835 
25836   # When compiling code to be executed by the Boot JDK, force jdk7 compatibility.
25837   BOOT_JDK_SOURCETARGET="-source 7 -target 7"
25838 
25839 
25840 
25841 
25842   ##############################################################################
25843   #
25844   # Specify options for anything that is run with the Boot JDK.
25845   #
25846 
25847 # Check whether --with-boot-jdk-jvmargs was given.
25848 if test "${with_boot_jdk_jvmargs+set}" = set; then :
25849   withval=$with_boot_jdk_jvmargs;
25850 fi
25851 
25852 
25853   if test "x$with_boot_jdk_jvmargs" = x; then
25854     # Not all JVM:s accept the same arguments on the command line.
25855     # OpenJDK specific increase in thread stack for JDK build,
25856     # well more specifically, when running javac.
25857     if test "x$BUILD_NUM_BITS" = x32; then
25858       STACK_SIZE=768
25859     else
25860       # Running Javac on a JVM on a 64-bit machine, the stack takes more space
25861       # since 64-bit pointers are pushed on the stach. Apparently, we need
25862       # to increase the stack space when javacing the JDK....
25863       STACK_SIZE=1536
25864     fi
25865 
25866     # Minimum amount of heap memory.
25867 
25868   $ECHO "Check if jvm arg is ok: -Xms64M" >&5
25869   $ECHO "Command: $JAVA -Xms64M -version" >&5
25870   OUTPUT=`$JAVA -Xms64M -version 2>&1`
25871   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25872   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25873   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25874     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xms64M"
25875     JVM_ARG_OK=true
25876   else
25877     $ECHO "Arg failed:" >&5
25878     $ECHO "$OUTPUT" >&5
25879     JVM_ARG_OK=false
25880   fi
25881 
25882     if test "x$OPENJDK_TARGET_OS" = "xmacosx" || test "x$OPENJDK_TARGET_CPU" = "xppc64" ; then
25883       # Why does macosx need more heap? Its the huge JDK batch.
25884 
25885   $ECHO "Check if jvm arg is ok: -Xmx1600M" >&5
25886   $ECHO "Command: $JAVA -Xmx1600M -version" >&5
25887   OUTPUT=`$JAVA -Xmx1600M -version 2>&1`
25888   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25889   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25890   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25891     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1600M"
25892     JVM_ARG_OK=true
25893   else
25894     $ECHO "Arg failed:" >&5
25895     $ECHO "$OUTPUT" >&5
25896     JVM_ARG_OK=false
25897   fi
25898 
25899     else
25900 
25901   $ECHO "Check if jvm arg is ok: -Xmx1100M" >&5
25902   $ECHO "Command: $JAVA -Xmx1100M -version" >&5
25903   OUTPUT=`$JAVA -Xmx1100M -version 2>&1`
25904   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25905   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25906   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25907     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1100M"
25908     JVM_ARG_OK=true
25909   else
25910     $ECHO "Arg failed:" >&5
25911     $ECHO "$OUTPUT" >&5
25912     JVM_ARG_OK=false
25913   fi
25914 
25915     fi
25916     # When is adding -client something that speeds up the JVM?
25917     # ADD_JVM_ARG_IF_OK([-client],boot_jdk_jvmargs,[$JAVA])
25918 
25919   $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5
25920   $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5
25921   OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1`
25922   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25923   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25924   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25925     boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:ThreadStackSize=$STACK_SIZE"
25926     JVM_ARG_OK=true
25927   else
25928     $ECHO "Arg failed:" >&5
25929     $ECHO "$OUTPUT" >&5
25930     JVM_ARG_OK=false
25931   fi
25932 
25933     # Disable special log output when a debug build is used as Boot JDK...
25934 
25935   $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5
25936   $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5
25937   OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1`
25938   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25939   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25940   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25941     boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput"
25942     JVM_ARG_OK=true
25943   else
25944     $ECHO "Arg failed:" >&5
25945     $ECHO "$OUTPUT" >&5
25946     JVM_ARG_OK=false
25947   fi
25948 
25949   fi
25950 
25951   BOOT_JDK_JVMARGS=$boot_jdk_jvmargs
25952 
25953 
25954 
25955 ###############################################################################
25956 #
25957 # Configure the sources to use. We can add or override individual directories.
25958 #
25959 ###############################################################################
25960 
25961 
25962   # Where are the sources. Any of these can be overridden
25963   # using --with-override-corba and the likes.
25964   LANGTOOLS_TOPDIR="$SRC_ROOT/langtools"
25965   CORBA_TOPDIR="$SRC_ROOT/corba"
25966   JAXP_TOPDIR="$SRC_ROOT/jaxp"
25967   JAXWS_TOPDIR="$SRC_ROOT/jaxws"
25968   HOTSPOT_TOPDIR="$SRC_ROOT/hotspot"
25969   NASHORN_TOPDIR="$SRC_ROOT/nashorn"
25970   JDK_TOPDIR="$SRC_ROOT/jdk"
25971 
25972 
25973 
25974 
25975 
25976 
25977 
25978 
25979 
25980 
25981   ###############################################################################
25982   #
25983   # Pickup additional source for a component from outside of the source root
25984   # or override source for a component.
25985   #
25986 
25987 # Check whether --with-add-source-root was given.
25988 if test "${with_add_source_root+set}" = set; then :
25989   withval=$with_add_source_root;
25990 fi
25991 
25992 
25993 
25994 # Check whether --with-override-source-root was given.
25995 if test "${with_override_source_root+set}" = set; then :
25996   withval=$with_override_source_root;
25997 fi
25998 
25999 
26000 
26001 # Check whether --with-adds-and-overrides was given.
26002 if test "${with_adds_and_overrides+set}" = set; then :
26003   withval=$with_adds_and_overrides;
26004 fi
26005 
26006 
26007   if test "x$with_adds_and_overrides" != x; then
26008     with_add_source_root="$with_adds_and_overrides/adds"
26009     with_override_source_root="$with_adds_and_overrides/overrides"
26010   fi
26011 
26012   if test "x$with_add_source_root" != x; then
26013     if ! test -d $with_add_source_root; then
26014       as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5
26015     fi
26016     CURDIR="$PWD"
26017     cd "$with_add_source_root"
26018     ADD_SRC_ROOT="`pwd`"
26019     cd "$CURDIR"
26020     # Verify that the addon source root does not have any root makefiles.
26021     # If it does, then it is usually an error, prevent this.
26022     if test -f $with_add_source_root/langtools/make/Makefile; then
26023       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
26024     fi
26025     if test -f $with_add_source_root/corba/make/Makefile; then
26026       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
26027     fi
26028     if test -f $with_add_source_root/jaxp/make/Makefile; then
26029       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
26030     fi
26031     if test -f $with_add_source_root/jaxws/make/Makefile; then
26032       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
26033     fi
26034     if test -f $with_add_source_root/hotspot/make/Makefile; then
26035       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
26036     fi
26037     if test -f $with_add_source_root/nashorn/make/Makefile; then
26038       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
26039     fi
26040     if test -f $with_add_source_root/jdk/make/Makefile; then
26041       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
26042     fi
26043   fi
26044 
26045 
26046   if test "x$with_override_source_root" != x; then
26047     if ! test -d $with_override_source_root; then
26048       as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5
26049     fi
26050     CURDIR="$PWD"
26051     cd "$with_override_source_root"
26052     OVERRIDE_SRC_ROOT="`pwd`"
26053     cd "$CURDIR"
26054     if test -f $with_override_source_root/langtools/make/Makefile; then
26055       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
26056     fi
26057     if test -f $with_override_source_root/corba/make/Makefile; then
26058       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
26059     fi
26060     if test -f $with_override_source_root/jaxp/make/Makefile; then
26061       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
26062     fi
26063     if test -f $with_override_source_root/jaxws/make/Makefile; then
26064       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
26065     fi
26066     if test -f $with_override_source_root/hotspot/make/Makefile; then
26067       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
26068     fi
26069     if test -f $with_override_source_root/nashorn/make/Makefile; then
26070       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
26071     fi
26072     if test -f $with_override_source_root/jdk/make/Makefile; then
26073       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
26074     fi
26075   fi
26076 
26077 
26078   ###############################################################################
26079   #
26080   # Override a repo completely, this is used for example when you have 3 small
26081   # development sandboxes of the langtools sources and want to avoid having 3 full
26082   # OpenJDK sources checked out on disk.
26083   #
26084   # Assuming that the 3 langtools sandboxes are located here:
26085   # /home/fredrik/sandbox1/langtools
26086   # /home/fredrik/sandbox2/langtools
26087   # /home/fredrik/sandbox3/langtools
26088   #
26089   # From the source root you create build subdirs manually:
26090   #     mkdir -p build1 build2 build3
26091   # in each build directory run:
26092   #     (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make)
26093   #     (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make)
26094   #     (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make)
26095   #
26096 
26097 
26098 # Check whether --with-override-langtools was given.
26099 if test "${with_override_langtools+set}" = set; then :
26100   withval=$with_override_langtools;
26101 fi
26102 
26103 
26104 
26105 # Check whether --with-override-corba was given.
26106 if test "${with_override_corba+set}" = set; then :
26107   withval=$with_override_corba;
26108 fi
26109 
26110 
26111 
26112 # Check whether --with-override-jaxp was given.
26113 if test "${with_override_jaxp+set}" = set; then :
26114   withval=$with_override_jaxp;
26115 fi
26116 
26117 
26118 
26119 # Check whether --with-override-jaxws was given.
26120 if test "${with_override_jaxws+set}" = set; then :
26121   withval=$with_override_jaxws;
26122 fi
26123 
26124 
26125 
26126 # Check whether --with-override-hotspot was given.
26127 if test "${with_override_hotspot+set}" = set; then :
26128   withval=$with_override_hotspot;
26129 fi
26130 
26131 
26132 
26133 # Check whether --with-override-nashorn was given.
26134 if test "${with_override_nashorn+set}" = set; then :
26135   withval=$with_override_nashorn;
26136 fi
26137 
26138 
26139 
26140 # Check whether --with-override-jdk was given.
26141 if test "${with_override_jdk+set}" = set; then :
26142   withval=$with_override_jdk;
26143 fi
26144 
26145 
26146   if test "x$with_override_langtools" != x; then
26147     CURDIR="$PWD"
26148     cd "$with_override_langtools"
26149     LANGTOOLS_TOPDIR="`pwd`"
26150     cd "$CURDIR"
26151     if ! test -f $LANGTOOLS_TOPDIR/make/Makefile; then
26152       as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5
26153     fi
26154     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5
26155 $as_echo_n "checking if langtools should be overridden... " >&6; }
26156     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5
26157 $as_echo "yes with $LANGTOOLS_TOPDIR" >&6; }
26158   fi
26159   if test "x$with_override_corba" != x; then
26160     CURDIR="$PWD"
26161     cd "$with_override_corba"
26162     CORBA_TOPDIR="`pwd`"
26163     cd "$CURDIR"
26164     if ! test -f $CORBA_TOPDIR/make/Makefile; then
26165       as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5
26166     fi
26167     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5
26168 $as_echo_n "checking if corba should be overridden... " >&6; }
26169     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5
26170 $as_echo "yes with $CORBA_TOPDIR" >&6; }
26171   fi
26172   if test "x$with_override_jaxp" != x; then
26173     CURDIR="$PWD"
26174     cd "$with_override_jaxp"
26175     JAXP_TOPDIR="`pwd`"
26176     cd "$CURDIR"
26177     if ! test -f $JAXP_TOPDIR/make/Makefile; then
26178       as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5
26179     fi
26180     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5
26181 $as_echo_n "checking if jaxp should be overridden... " >&6; }
26182     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5
26183 $as_echo "yes with $JAXP_TOPDIR" >&6; }
26184   fi
26185   if test "x$with_override_jaxws" != x; then
26186     CURDIR="$PWD"
26187     cd "$with_override_jaxws"
26188     JAXWS_TOPDIR="`pwd`"
26189     cd "$CURDIR"
26190     if ! test -f $JAXWS_TOPDIR/make/Makefile; then
26191       as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5
26192     fi
26193     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5
26194 $as_echo_n "checking if jaxws should be overridden... " >&6; }
26195     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5
26196 $as_echo "yes with $JAXWS_TOPDIR" >&6; }
26197   fi
26198   if test "x$with_override_hotspot" != x; then
26199     CURDIR="$PWD"
26200     cd "$with_override_hotspot"
26201     HOTSPOT_TOPDIR="`pwd`"
26202     cd "$CURDIR"
26203     if ! test -f $HOTSPOT_TOPDIR/make/Makefile; then
26204       as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5
26205     fi
26206     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5
26207 $as_echo_n "checking if hotspot should be overridden... " >&6; }
26208     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5
26209 $as_echo "yes with $HOTSPOT_TOPDIR" >&6; }
26210   fi
26211   if test "x$with_override_nashorn" != x; then
26212     CURDIR="$PWD"
26213     cd "$with_override_nashorn"
26214     NASHORN_TOPDIR="`pwd`"
26215     cd "$CURDIR"
26216     if ! test -f $NASHORN_TOPDIR/make/Makefile; then
26217       as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
26218     fi
26219     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
26220 $as_echo_n "checking if nashorn should be overridden... " >&6; }
26221     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5
26222 $as_echo "yes with $NASHORN_TOPDIR" >&6; }
26223   fi
26224   if test "x$with_override_jdk" != x; then
26225     CURDIR="$PWD"
26226     cd "$with_override_jdk"
26227     JDK_TOPDIR="`pwd`"
26228     cd "$CURDIR"
26229     if ! test -f $JDK_TOPDIR/make/Makefile; then
26230       as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5
26231     fi
26232     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5
26233 $as_echo_n "checking if JDK should be overridden... " >&6; }
26234     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5
26235 $as_echo "yes with $JDK_TOPDIR" >&6; }
26236   fi
26237 
26238 
26239   BUILD_OUTPUT="$OUTPUT_ROOT"
26240 
26241 
26242   HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist"
26243   BUILD_HOTSPOT=true
26244 
26245 
26246 
26247 # Check whether --with-import-hotspot was given.
26248 if test "${with_import_hotspot+set}" = set; then :
26249   withval=$with_import_hotspot;
26250 fi
26251 
26252   if test "x$with_import_hotspot" != x; then
26253     CURDIR="$PWD"
26254     cd "$with_import_hotspot"
26255     HOTSPOT_DIST="`pwd`"
26256     cd "$CURDIR"
26257     if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then
26258       as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5
26259     fi
26260     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5
26261 $as_echo_n "checking if hotspot should be imported... " >&6; }
26262     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5
26263 $as_echo "yes from $HOTSPOT_DIST" >&6; }
26264     BUILD_HOTSPOT=false
26265   fi
26266 
26267   JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk"
26268 
26269 
26270 ###############################################################################
26271 #
26272 # Setup the toolchain (compilers etc), i.e. tools used to compile and process
26273 # native code.
26274 #
26275 ###############################################################################
26276 
26277 # First determine the toolchain type (compiler family)
26278 
26279 
26280 # Check whether --with-toolchain-type was given.
26281 if test "${with_toolchain_type+set}" = set; then :
26282   withval=$with_toolchain_type;
26283 fi
26284 
26285 
26286   # Use indirect variable referencing
26287   toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS
26288   VALID_TOOLCHAINS=${!toolchain_var_name}
26289 
26290   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26291     # On Mac OS X, default toolchain to clang after Xcode 5
26292     XCODE_VERSION_OUTPUT=`xcodebuild -version 2>&1 | $HEAD -n 1`
26293     $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null
26294     if test $? -ne 0; then
26295       as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5
26296     fi
26297     XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \
26298         $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \
26299         $CUT -f 1 -d .`
26300     { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5
26301 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;}
26302     if test $XCODE_MAJOR_VERSION -ge 5; then
26303         DEFAULT_TOOLCHAIN="clang"
26304     else
26305         DEFAULT_TOOLCHAIN="gcc"
26306     fi
26307   else
26308     # First toolchain type in the list is the default
26309     DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *}
26310   fi
26311 
26312   if test "x$with_toolchain_type" = xlist; then
26313     # List all toolchains
26314     { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5
26315 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;}
26316     for toolchain in $VALID_TOOLCHAINS; do
26317       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
26318       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26319       $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
26320     done
26321 
26322     exit 0
26323   elif test "x$with_toolchain_type" != x; then
26324     # User override; check that it is valid
26325     if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then
26326       { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5
26327 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;}
26328       { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5
26329 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;}
26330       as_fn_error $? "Cannot continue." "$LINENO" 5
26331     fi
26332     TOOLCHAIN_TYPE=$with_toolchain_type
26333   else
26334     # No flag given, use default
26335     TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN
26336   fi
26337 
26338 
26339   TOOLCHAIN_CC_BINARY_clang="clang"
26340   TOOLCHAIN_CC_BINARY_gcc="gcc"
26341   TOOLCHAIN_CC_BINARY_microsoft="cl"
26342   TOOLCHAIN_CC_BINARY_solstudio="cc"
26343   TOOLCHAIN_CC_BINARY_xlc="xlc_r"
26344 
26345   TOOLCHAIN_CXX_BINARY_clang="clang++"
26346   TOOLCHAIN_CXX_BINARY_gcc="g++"
26347   TOOLCHAIN_CXX_BINARY_microsoft="cl"
26348   TOOLCHAIN_CXX_BINARY_solstudio="CC"
26349   TOOLCHAIN_CXX_BINARY_xlc="xlC_r"
26350 
26351   # Use indirect variable referencing
26352   toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE
26353   TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26354   toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE
26355   TOOLCHAIN_CC_BINARY=${!toolchain_var_name}
26356   toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE
26357   TOOLCHAIN_CXX_BINARY=${!toolchain_var_name}
26358 
26359 
26360   # Define filename patterns
26361   if test "x$OPENJDK_TARGET_OS" = xwindows; then
26362     LIBRARY_PREFIX=
26363     SHARED_LIBRARY_SUFFIX='.dll'
26364     STATIC_LIBRARY_SUFFIX='.lib'
26365     SHARED_LIBRARY='$1.dll'
26366     STATIC_LIBRARY='$1.lib'
26367     OBJ_SUFFIX='.obj'
26368     EXE_SUFFIX='.exe'
26369   else
26370     LIBRARY_PREFIX=lib
26371     SHARED_LIBRARY_SUFFIX='.so'
26372     STATIC_LIBRARY_SUFFIX='.a'
26373     SHARED_LIBRARY='lib$1.so'
26374     STATIC_LIBRARY='lib$1.a'
26375     OBJ_SUFFIX='.o'
26376     EXE_SUFFIX=''
26377     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26378       SHARED_LIBRARY='lib$1.dylib'
26379       SHARED_LIBRARY_SUFFIX='.dylib'
26380     fi
26381   fi
26382 
26383 
26384 
26385 
26386 
26387 
26388 
26389 
26390 
26391 
26392   if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then
26393     { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5
26394 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;}
26395   else
26396     { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5
26397 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;}
26398   fi
26399 
26400 
26401 # Then detect the actual binaries needed
26402 
26403   # FIXME: Is this needed?
26404   ac_ext=cpp
26405 ac_cpp='$CXXCPP $CPPFLAGS'
26406 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26407 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26408 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26409 
26410 
26411   # Store the CFLAGS etc passed to the configure script.
26412   ORG_CFLAGS="$CFLAGS"
26413   ORG_CXXFLAGS="$CXXFLAGS"
26414   ORG_OBJCFLAGS="$OBJCFLAGS"
26415 
26416   # On Windows, we need to detect the visual studio installation first.
26417   # This will change the PATH, but we need to keep that new PATH even
26418   # after toolchain detection is done, since the compiler (on x86) uses
26419   # it for DLL resolution in runtime.
26420   if test "x$OPENJDK_BUILD_OS" = "xwindows" && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then
26421 
26422   # Store path to cygwin link.exe to help excluding it when searching for
26423   # VS linker. This must be done before changing the PATH when looking for VS.
26424   # Extract the first word of "link", so it can be a program name with args.
26425 set dummy link; ac_word=$2
26426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26427 $as_echo_n "checking for $ac_word... " >&6; }
26428 if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26429   $as_echo_n "(cached) " >&6
26430 else
26431   case $CYGWIN_LINK in
26432   [\\/]* | ?:[\\/]*)
26433   ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26434   ;;
26435   *)
26436   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26437 for as_dir in $PATH
26438 do
26439   IFS=$as_save_IFS
26440   test -z "$as_dir" && as_dir=.
26441     for ac_exec_ext in '' $ac_executable_extensions; do
26442   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26443     ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26444     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26445     break 2
26446   fi
26447 done
26448   done
26449 IFS=$as_save_IFS
26450 
26451   ;;
26452 esac
26453 fi
26454 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26455 if test -n "$CYGWIN_LINK"; then
26456   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26457 $as_echo "$CYGWIN_LINK" >&6; }
26458 else
26459   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26460 $as_echo "no" >&6; }
26461 fi
26462 
26463 
26464   if test "x$CYGWIN_LINK" != x; then
26465     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26466 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26467     "$CYGWIN_LINK" --version > /dev/null
26468     if test $? -eq 0 ; then
26469       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26470 $as_echo "yes" >&6; }
26471     else
26472       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26473 $as_echo "no" >&6; }
26474       # This might be the VS linker. Don't exclude it later on.
26475       CYGWIN_LINK=""
26476     fi
26477   fi
26478 
26479   # First-hand choice is to locate and run the vsvars bat file.
26480 
26481   if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26482     VCVARSFILE="vc/bin/vcvars32.bat"
26483   else
26484     VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26485   fi
26486 
26487   VS_ENV_CMD=""
26488   VS_ENV_ARGS=""
26489   if test "x$with_toolsdir" != x; then
26490 
26491   if test "x$VS_ENV_CMD" = x; then
26492     VS100BASE="$with_toolsdir/../.."
26493     METHOD="--with-tools-dir"
26494 
26495   windows_path="$VS100BASE"
26496   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26497     unix_path=`$CYGPATH -u "$windows_path"`
26498     VS100BASE="$unix_path"
26499   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26500     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26501     VS100BASE="$unix_path"
26502   fi
26503 
26504     if test -d "$VS100BASE"; then
26505       if test -f "$VS100BASE/$VCVARSFILE"; then
26506         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26507 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26508         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26509       else
26510         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26511 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26512         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26513 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26514       fi
26515     fi
26516   fi
26517 
26518   fi
26519 
26520   if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26521     # Having specified an argument which is incorrect will produce an instant failure;
26522     # we should not go on looking
26523     { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26524 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26525     { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26526 $as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26527     as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26528   fi
26529 
26530   if test "x$VS100COMNTOOLS" != x; then
26531 
26532   if test "x$VS_ENV_CMD" = x; then
26533     VS100BASE="$VS100COMNTOOLS/../.."
26534     METHOD="VS100COMNTOOLS variable"
26535 
26536   windows_path="$VS100BASE"
26537   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26538     unix_path=`$CYGPATH -u "$windows_path"`
26539     VS100BASE="$unix_path"
26540   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26541     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26542     VS100BASE="$unix_path"
26543   fi
26544 
26545     if test -d "$VS100BASE"; then
26546       if test -f "$VS100BASE/$VCVARSFILE"; then
26547         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26548 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26549         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26550       else
26551         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26552 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26553         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26554 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26555       fi
26556     fi
26557   fi
26558 
26559   fi
26560   if test "x$PROGRAMFILES" != x; then
26561 
26562   if test "x$VS_ENV_CMD" = x; then
26563     VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26564     METHOD="well-known name"
26565 
26566   windows_path="$VS100BASE"
26567   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26568     unix_path=`$CYGPATH -u "$windows_path"`
26569     VS100BASE="$unix_path"
26570   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26571     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26572     VS100BASE="$unix_path"
26573   fi
26574 
26575     if test -d "$VS100BASE"; then
26576       if test -f "$VS100BASE/$VCVARSFILE"; then
26577         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26578 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26579         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26580       else
26581         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26582 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26583         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26584 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26585       fi
26586     fi
26587   fi
26588 
26589   fi
26590 
26591   if test "x$VS_ENV_CMD" = x; then
26592     VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26593     METHOD="well-known name"
26594 
26595   windows_path="$VS100BASE"
26596   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26597     unix_path=`$CYGPATH -u "$windows_path"`
26598     VS100BASE="$unix_path"
26599   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26600     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26601     VS100BASE="$unix_path"
26602   fi
26603 
26604     if test -d "$VS100BASE"; then
26605       if test -f "$VS100BASE/$VCVARSFILE"; then
26606         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26607 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26608         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26609       else
26610         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26611 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26612         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26613 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26614       fi
26615     fi
26616   fi
26617 
26618 
26619   if test "x$VS_ENV_CMD" = x; then
26620     VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
26621     METHOD="well-known name"
26622 
26623   windows_path="$VS100BASE"
26624   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26625     unix_path=`$CYGPATH -u "$windows_path"`
26626     VS100BASE="$unix_path"
26627   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26628     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26629     VS100BASE="$unix_path"
26630   fi
26631 
26632     if test -d "$VS100BASE"; then
26633       if test -f "$VS100BASE/$VCVARSFILE"; then
26634         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26635 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26636         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26637       else
26638         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26639 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26640         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26641 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26642       fi
26643     fi
26644   fi
26645 
26646 
26647   if test "x$ProgramW6432" != x; then
26648 
26649   if test "x$VS_ENV_CMD" = x; then
26650     WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
26651     METHOD="well-known name"
26652 
26653   windows_path="$WIN_SDK_BASE"
26654   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26655     unix_path=`$CYGPATH -u "$windows_path"`
26656     WIN_SDK_BASE="$unix_path"
26657   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26658     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26659     WIN_SDK_BASE="$unix_path"
26660   fi
26661 
26662     if test -d "$WIN_SDK_BASE"; then
26663       # There have been cases of partial or broken SDK installations. A missing
26664       # lib dir is not going to work.
26665       if test ! -d "$WIN_SDK_BASE/../lib"; then
26666         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26667 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26668         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26669 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26670       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26671         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26672 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26673         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26674         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26675           VS_ENV_ARGS="/x86"
26676         else
26677           VS_ENV_ARGS="/x64"
26678         fi
26679       else
26680         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26681 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26682         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26683 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26684       fi
26685     fi
26686   fi
26687 
26688   fi
26689   if test "x$PROGRAMW6432" != x; then
26690 
26691   if test "x$VS_ENV_CMD" = x; then
26692     WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
26693     METHOD="well-known name"
26694 
26695   windows_path="$WIN_SDK_BASE"
26696   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26697     unix_path=`$CYGPATH -u "$windows_path"`
26698     WIN_SDK_BASE="$unix_path"
26699   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26700     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26701     WIN_SDK_BASE="$unix_path"
26702   fi
26703 
26704     if test -d "$WIN_SDK_BASE"; then
26705       # There have been cases of partial or broken SDK installations. A missing
26706       # lib dir is not going to work.
26707       if test ! -d "$WIN_SDK_BASE/../lib"; then
26708         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26709 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26710         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26711 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26712       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26713         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26714 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26715         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26716         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26717           VS_ENV_ARGS="/x86"
26718         else
26719           VS_ENV_ARGS="/x64"
26720         fi
26721       else
26722         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26723 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26724         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26725 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26726       fi
26727     fi
26728   fi
26729 
26730   fi
26731   if test "x$PROGRAMFILES" != x; then
26732 
26733   if test "x$VS_ENV_CMD" = x; then
26734     WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
26735     METHOD="well-known name"
26736 
26737   windows_path="$WIN_SDK_BASE"
26738   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26739     unix_path=`$CYGPATH -u "$windows_path"`
26740     WIN_SDK_BASE="$unix_path"
26741   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26742     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26743     WIN_SDK_BASE="$unix_path"
26744   fi
26745 
26746     if test -d "$WIN_SDK_BASE"; then
26747       # There have been cases of partial or broken SDK installations. A missing
26748       # lib dir is not going to work.
26749       if test ! -d "$WIN_SDK_BASE/../lib"; then
26750         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26751 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26752         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26753 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26754       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26755         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26756 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26757         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26758         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26759           VS_ENV_ARGS="/x86"
26760         else
26761           VS_ENV_ARGS="/x64"
26762         fi
26763       else
26764         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26765 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26766         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26767 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26768       fi
26769     fi
26770   fi
26771 
26772   fi
26773 
26774   if test "x$VS_ENV_CMD" = x; then
26775     WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
26776     METHOD="well-known name"
26777 
26778   windows_path="$WIN_SDK_BASE"
26779   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26780     unix_path=`$CYGPATH -u "$windows_path"`
26781     WIN_SDK_BASE="$unix_path"
26782   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26783     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26784     WIN_SDK_BASE="$unix_path"
26785   fi
26786 
26787     if test -d "$WIN_SDK_BASE"; then
26788       # There have been cases of partial or broken SDK installations. A missing
26789       # lib dir is not going to work.
26790       if test ! -d "$WIN_SDK_BASE/../lib"; then
26791         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26792 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26793         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26794 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26795       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26796         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26797 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26798         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26799         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26800           VS_ENV_ARGS="/x86"
26801         else
26802           VS_ENV_ARGS="/x64"
26803         fi
26804       else
26805         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26806 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26807         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26808 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26809       fi
26810     fi
26811   fi
26812 
26813 
26814   if test "x$VS_ENV_CMD" = x; then
26815     WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
26816     METHOD="well-known name"
26817 
26818   windows_path="$WIN_SDK_BASE"
26819   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26820     unix_path=`$CYGPATH -u "$windows_path"`
26821     WIN_SDK_BASE="$unix_path"
26822   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26823     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26824     WIN_SDK_BASE="$unix_path"
26825   fi
26826 
26827     if test -d "$WIN_SDK_BASE"; then
26828       # There have been cases of partial or broken SDK installations. A missing
26829       # lib dir is not going to work.
26830       if test ! -d "$WIN_SDK_BASE/../lib"; then
26831         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26832 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26833         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26834 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26835       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26836         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26837 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26838         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26839         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26840           VS_ENV_ARGS="/x86"
26841         else
26842           VS_ENV_ARGS="/x64"
26843         fi
26844       else
26845         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26846 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26847         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26848 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26849       fi
26850     fi
26851   fi
26852 
26853 
26854   if test "x$VS_ENV_CMD" != x; then
26855     # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
26856 
26857   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26858 
26859   # First separate the path from the arguments. This will split at the first
26860   # space.
26861   complete="$VS_ENV_CMD"
26862   path="${complete%% *}"
26863   tmp="$complete EOL"
26864   arguments="${tmp#* }"
26865 
26866   # Input might be given as Windows format, start by converting to
26867   # unix format.
26868   new_path=`$CYGPATH -u "$path"`
26869 
26870   # Now try to locate executable using which
26871   new_path=`$WHICH "$new_path" 2> /dev/null`
26872   # bat and cmd files are not always considered executable in cygwin causing which
26873   # to not find them
26874   if test "x$new_path" = x \
26875       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26876       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26877     new_path=`$CYGPATH -u "$path"`
26878   fi
26879   if test "x$new_path" = x; then
26880     # Oops. Which didn't find the executable.
26881     # The splitting of arguments from the executable at a space might have been incorrect,
26882     # since paths with space are more likely in Windows. Give it another try with the whole
26883     # argument.
26884     path="$complete"
26885     arguments="EOL"
26886     new_path=`$CYGPATH -u "$path"`
26887     new_path=`$WHICH "$new_path" 2> /dev/null`
26888     # bat and cmd files are not always considered executable in cygwin causing which
26889     # to not find them
26890     if test "x$new_path" = x \
26891         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26892         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26893       new_path=`$CYGPATH -u "$path"`
26894     fi
26895     if test "x$new_path" = x; then
26896       # It's still not found. Now this is an unrecoverable error.
26897       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
26898 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
26899       has_space=`$ECHO "$complete" | $GREP " "`
26900       if test "x$has_space" != x; then
26901         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
26902 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
26903       fi
26904       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26905     fi
26906   fi
26907 
26908   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
26909   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
26910   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
26911   # "foo.exe" is OK but "foo" is an error.
26912   #
26913   # This test is therefore slightly more accurate than "test -f" to check for file presence.
26914   # It is also a way to make sure we got the proper file name for the real test later on.
26915   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
26916   if test "x$test_shortpath" = x; then
26917     # Short path failed, file does not exist as specified.
26918     # Try adding .exe or .cmd
26919     if test -f "${new_path}.exe"; then
26920       input_to_shortpath="${new_path}.exe"
26921     elif test -f "${new_path}.cmd"; then
26922       input_to_shortpath="${new_path}.cmd"
26923     else
26924       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
26925 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
26926       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
26927 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
26928       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26929     fi
26930   else
26931     input_to_shortpath="$new_path"
26932   fi
26933 
26934   # Call helper function which possibly converts this using DOS-style short mode.
26935   # If so, the updated path is stored in $new_path.
26936   new_path="$input_to_shortpath"
26937 
26938   input_path="$input_to_shortpath"
26939   # Check if we need to convert this using DOS-style short mode. If the path
26940   # contains just simple characters, use it. Otherwise (spaces, weird characters),
26941   # take no chances and rewrite it.
26942   # Note: m4 eats our [], so we need to use [ and ] instead.
26943   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
26944   if test "x$has_forbidden_chars" != x; then
26945     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
26946     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
26947     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
26948     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
26949       # Going to short mode and back again did indeed matter. Since short mode is
26950       # case insensitive, let's make it lowercase to improve readability.
26951       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
26952       # Now convert it back to Unix-stile (cygpath)
26953       input_path=`$CYGPATH -u "$shortmode_path"`
26954       new_path="$input_path"
26955     fi
26956   fi
26957 
26958   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
26959   if test "x$test_cygdrive_prefix" = x; then
26960     # As a simple fix, exclude /usr/bin since it's not a real path.
26961     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
26962       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
26963       # a path prefixed by /cygdrive for fixpath to work.
26964       new_path="$CYGWIN_ROOT_PATH$input_path"
26965     fi
26966   fi
26967 
26968   # remove trailing .exe if any
26969   new_path="${new_path/%.exe/}"
26970 
26971   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26972 
26973   # First separate the path from the arguments. This will split at the first
26974   # space.
26975   complete="$VS_ENV_CMD"
26976   path="${complete%% *}"
26977   tmp="$complete EOL"
26978   arguments="${tmp#* }"
26979 
26980   # Input might be given as Windows format, start by converting to
26981   # unix format.
26982   new_path="$path"
26983 
26984   windows_path="$new_path"
26985   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26986     unix_path=`$CYGPATH -u "$windows_path"`
26987     new_path="$unix_path"
26988   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26989     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26990     new_path="$unix_path"
26991   fi
26992 
26993 
26994   # Now try to locate executable using which
26995   new_path=`$WHICH "$new_path" 2> /dev/null`
26996 
26997   if test "x$new_path" = x; then
26998     # Oops. Which didn't find the executable.
26999     # The splitting of arguments from the executable at a space might have been incorrect,
27000     # since paths with space are more likely in Windows. Give it another try with the whole
27001     # argument.
27002     path="$complete"
27003     arguments="EOL"
27004     new_path="$path"
27005 
27006   windows_path="$new_path"
27007   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27008     unix_path=`$CYGPATH -u "$windows_path"`
27009     new_path="$unix_path"
27010   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27011     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27012     new_path="$unix_path"
27013   fi
27014 
27015 
27016     new_path=`$WHICH "$new_path" 2> /dev/null`
27017 
27018     if test "x$new_path" = x; then
27019       # It's still not found. Now this is an unrecoverable error.
27020       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27021 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27022       has_space=`$ECHO "$complete" | $GREP " "`
27023       if test "x$has_space" != x; then
27024         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27025 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27026       fi
27027       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27028     fi
27029   fi
27030 
27031   # Now new_path has a complete unix path to the binary
27032   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27033     # Keep paths in /bin as-is, but remove trailing .exe if any
27034     new_path="${new_path/%.exe/}"
27035     # Do not save /bin paths to all_fixpath_prefixes!
27036   else
27037     # Not in mixed or Windows style, start by that.
27038     new_path=`cmd //c echo $new_path`
27039 
27040   input_path="$new_path"
27041   # Check if we need to convert this using DOS-style short mode. If the path
27042   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27043   # take no chances and rewrite it.
27044   # Note: m4 eats our [], so we need to use [ and ] instead.
27045   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27046   if test "x$has_forbidden_chars" != x; then
27047     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27048     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27049   fi
27050 
27051     # Output is in $new_path
27052 
27053   windows_path="$new_path"
27054   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27055     unix_path=`$CYGPATH -u "$windows_path"`
27056     new_path="$unix_path"
27057   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27058     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27059     new_path="$unix_path"
27060   fi
27061 
27062     # remove trailing .exe if any
27063     new_path="${new_path/%.exe/}"
27064 
27065     # Save the first 10 bytes of this path to the storage, so fixpath can work.
27066     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27067   fi
27068 
27069   else
27070     # We're on a posix platform. Hooray! :)
27071     # First separate the path from the arguments. This will split at the first
27072     # space.
27073     complete="$VS_ENV_CMD"
27074     path="${complete%% *}"
27075     tmp="$complete EOL"
27076     arguments="${tmp#* }"
27077 
27078     # Cannot rely on the command "which" here since it doesn't always work.
27079     is_absolute_path=`$ECHO "$path" | $GREP ^/`
27080     if test -z "$is_absolute_path"; then
27081       # Path to executable is not absolute. Find it.
27082       IFS_save="$IFS"
27083       IFS=:
27084       for p in $PATH; do
27085         if test -f "$p/$path" && test -x "$p/$path"; then
27086           new_path="$p/$path"
27087           break
27088         fi
27089       done
27090       IFS="$IFS_save"
27091     else
27092       # This is an absolute path, we can use it without further modifications.
27093       new_path="$path"
27094     fi
27095 
27096     if test "x$new_path" = x; then
27097       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27098 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27099       has_space=`$ECHO "$complete" | $GREP " "`
27100       if test "x$has_space" != x; then
27101         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27102 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27103       fi
27104       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27105     fi
27106   fi
27107 
27108   # Now join together the path and the arguments once again
27109   if test "x$arguments" != xEOL; then
27110     new_complete="$new_path ${arguments% *}"
27111   else
27112     new_complete="$new_path"
27113   fi
27114 
27115   if test "x$complete" != "x$new_complete"; then
27116     VS_ENV_CMD="$new_complete"
27117     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27118 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27119   fi
27120 
27121 
27122     # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27123     { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27124 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27125     cd $OUTPUT_ROOT
27126     # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted
27127     # to autoconf standards.
27128 
27129     #----
27130 
27131     # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment)
27132     # but calculate the difference in Cygwin environment before/after running it and then
27133     # apply the diff.
27134 
27135     if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
27136       _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"`
27137       _dosvs10varsall=`cygpath -a -w -s $_vs10varsall`
27138       _dosbash=`cygpath -a -w -s \`which bash\`.*`
27139     else
27140       _dosvs10varsall=`cmd //c echo $VS_ENV_CMD`
27141       _dosbash=`cmd //c echo \`which bash\``
27142     fi
27143 
27144     # generate the set of exported vars before/after the vs10 setup
27145     $ECHO "@echo off"                                           >  localdevenvtmp.bat
27146     $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat
27147     $ECHO "call $_dosvs10varsall $VS_ENV_ARGS"                  >> localdevenvtmp.bat
27148     $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat
27149 
27150     # Now execute the newly created bat file.
27151     # The | cat is to stop SetEnv.Cmd to mess with system colors on msys
27152     cmd /c localdevenvtmp.bat | cat
27153 
27154     # apply the diff (less some non-vs10 vars named by "!")
27155     $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort
27156     $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort
27157     $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh
27158 
27159     # cleanup
27160     $RM localdevenvtmp*
27161     #----
27162     cd $CURDIR
27163     if test ! -s $OUTPUT_ROOT/localdevenv.sh; then
27164       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27165 $as_echo "no" >&6; }
27166       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27167 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27168       { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27169 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27170       { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27171 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27172       as_fn_error $? "Cannot continue" "$LINENO" 5
27173     fi
27174 
27175     # Now set all paths and other env variables. This will allow the rest of
27176     # the configure script to find and run the compiler in the proper way.
27177     { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27178 $as_echo "$as_me: Setting extracted environment variables" >&6;}
27179     . $OUTPUT_ROOT/localdevenv.sh
27180   else
27181     # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27182     { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27183 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27184   fi
27185 
27186   # At this point, we should have corrent variables in the environment, or we can't continue.
27187   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27188 $as_echo_n "checking for Visual Studio variables... " >&6; }
27189 
27190   if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27191     if test "x$INCLUDE" = x || test "x$LIB" = x; then
27192       { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27193 $as_echo "present but broken" >&6; }
27194       as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27195     else
27196       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27197 $as_echo "ok" >&6; }
27198       # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk.
27199       VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'`
27200       VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'`
27201       # Remove any paths containing # (typically F#) as that messes up make
27202       PATH=`$ECHO "$PATH" | $SED 's/[^:#]*#[^:]*://g'`
27203       VS_PATH="$PATH"
27204 
27205 
27206 
27207     fi
27208   else
27209     { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27210 $as_echo "not found" >&6; }
27211 
27212     if test "x$VS_ENV_CMD" = x; then
27213       { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27214 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27215       { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27216 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27217     else
27218       { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27219 $as_echo "$as_me: Running the extraction script failed." >&6;}
27220     fi
27221     { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27222 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27223     { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27224 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27225     as_fn_error $? "Cannot continue" "$LINENO" 5
27226   fi
27227 
27228   fi
27229 
27230   # autoconf magic only relies on PATH, so update it if tools dir is specified
27231   OLD_PATH="$PATH"
27232 
27233   # For solaris we really need solaris tools, and not the GNU equivalent.
27234   # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27235   # so add that to path before starting to probe.
27236   # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27237   if test "x$OPENJDK_BUILD_OS" = xsolaris; then
27238     PATH="/usr/ccs/bin:$PATH"
27239   fi
27240 
27241   # Finally add TOOLS_DIR at the beginning, to allow --with-tools-dir to
27242   # override all other locations.
27243   if test "x$TOOLS_DIR" != x; then
27244     PATH=$TOOLS_DIR:$PATH
27245   fi
27246 
27247   # If a devkit is found on the builddeps server, then prepend its path to the
27248   # PATH variable. If there are cross compilers available in the devkit, these
27249   # will be found by AC_PROG_CC et al.
27250   DEVKIT=
27251 
27252 
27253   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
27254     # Source the builddeps file again, to make sure it uses the latest variables!
27255     . $builddepsfile
27256     # Look for a target and build machine specific resource!
27257     eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
27258     if test "x$resource" = x; then
27259       # Ok, lets instead look for a target specific resource
27260       eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}}
27261     fi
27262     if test "x$resource" = x; then
27263       # Ok, lets instead look for a build specific resource
27264       eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}}
27265     fi
27266     if test "x$resource" = x; then
27267       # Ok, lets instead look for a generic resource
27268       # (The devkit comes from M4 and not the shell, thus no need for eval here.)
27269       resource=${builddep_devkit}
27270     fi
27271     if test "x$resource" != x; then
27272       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5
27273 $as_echo "$as_me: Using builddeps $resource for devkit" >&6;}
27274       # If the resource in the builddeps.conf file is an existing directory,
27275       # for example /java/linux/cups
27276       if test -d ${resource}; then
27277         depdir=${resource}
27278       else
27279 
27280   # devkit is for example mymodule
27281   # $resource is for example libs/general/libmymod_1_2_3.zip
27282   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
27283   # $with_builddeps_dir is for example /localhome/builddeps
27284   # depdir is the name of the variable into which we store the depdir, eg MYMOD
27285   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
27286   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
27287   filename=`basename $resource`
27288   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
27289   filebase=${filename%%.*}
27290   extension=${filename#*.}
27291   installdir=$with_builddeps_dir/$filebase
27292   if test ! -f $installdir/$filename.unpacked; then
27293     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5
27294 $as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;}
27295     if test ! -d $installdir; then
27296       mkdir -p $installdir
27297     fi
27298     if test ! -d $installdir; then
27299       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
27300     fi
27301     tmpfile=`mktemp $installdir/devkit.XXXXXXXXX`
27302     touch $tmpfile
27303     if test ! -f $tmpfile; then
27304       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
27305     fi
27306 
27307   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
27308   # $tmpfile is the local file name for the downloaded file.
27309   VALID_TOOL=no
27310   if test "x$BDEPS_FTP" = xwget; then
27311     VALID_TOOL=yes
27312     wget -O $tmpfile $with_builddeps_server/$resource
27313   fi
27314   if test "x$BDEPS_FTP" = xlftp; then
27315     VALID_TOOL=yes
27316     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
27317   fi
27318   if test "x$BDEPS_FTP" = xftp; then
27319     VALID_TOOL=yes
27320     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
27321     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
27322     FTPUSERPWD=${FTPSERVER%%@*}
27323     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
27324       FTPUSER=${userpwd%%:*}
27325       FTPPWD=${userpwd#*@}
27326       FTPSERVER=${FTPSERVER#*@}
27327     else
27328       FTPUSER=ftp
27329       FTPPWD=ftp
27330     fi
27331     # the "pass" command does not work on some
27332     # ftp clients (read ftp.exe) but if it works,
27333     # passive mode is better!
27334     ( \
27335         echo "user $FTPUSER $FTPPWD"        ; \
27336         echo "pass"                         ; \
27337         echo "bin"                          ; \
27338         echo "get $FTPPATH $tmpfile"              ; \
27339     ) | ftp -in $FTPSERVER
27340   fi
27341   if test "x$VALID_TOOL" != xyes; then
27342     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
27343   fi
27344 
27345     mv $tmpfile $installdir/$filename
27346     if test ! -s $installdir/$filename; then
27347       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
27348     fi
27349     case "$extension" in
27350       zip)  echo "Unzipping $installdir/$filename..."
27351         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
27352         ;;
27353       tar.gz) echo "Untaring $installdir/$filename..."
27354         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27355         ;;
27356       tgz) echo "Untaring $installdir/$filename..."
27357         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27358         ;;
27359       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
27360         ;;
27361     esac
27362   fi
27363   if test -f $installdir/$filename.unpacked; then
27364     depdir=$installdir
27365   fi
27366 
27367       fi
27368       # Source the builddeps file again, because in the previous command, the depdir
27369       # was updated to point at the current build dependency install directory.
27370       . $builddepsfile
27371       # Now extract variables from the builddeps.conf files.
27372       theroot=${builddep_devkit_ROOT}
27373       thecflags=${builddep_devkit_CFLAGS}
27374       thelibs=${builddep_devkit_LIBS}
27375       if test "x$depdir" = x; then
27376         as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5
27377       fi
27378       DEVKIT=$depdir
27379       if test "x$theroot" != x; then
27380         DEVKIT="$theroot"
27381       fi
27382       if test "x$thecflags" != x; then
27383         DEVKIT_CFLAGS="$thecflags"
27384       fi
27385       if test "x$thelibs" != x; then
27386         DEVKIT_LIBS="$thelibs"
27387       fi
27388 
27389         # Found devkit
27390         PATH="$DEVKIT/bin:$PATH"
27391         SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root"
27392         if test "x$x_includes" = "xNONE"; then
27393           x_includes="$SYS_ROOT/usr/include/X11"
27394         fi
27395         if test "x$x_libraries" = "xNONE"; then
27396           x_libraries="$SYS_ROOT/usr/lib"
27397         fi
27398 
27399 
27400     fi
27401 
27402   fi
27403 
27404 
27405 
27406   #
27407   # Setup the compilers (CC and CXX)
27408   #
27409 
27410   COMPILER_NAME=C
27411   SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27412 
27413   if test "x$CC" != x; then
27414     # User has supplied compiler name already, always let that override.
27415     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27416 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27417     if test "x`basename $CC`" = "x$CC"; then
27418       # A command without a complete path is provided, search $PATH.
27419 
27420       for ac_prog in $CC
27421 do
27422   # Extract the first word of "$ac_prog", so it can be a program name with args.
27423 set dummy $ac_prog; ac_word=$2
27424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27425 $as_echo_n "checking for $ac_word... " >&6; }
27426 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27427   $as_echo_n "(cached) " >&6
27428 else
27429   case $POTENTIAL_CC in
27430   [\\/]* | ?:[\\/]*)
27431   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27432   ;;
27433   *)
27434   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27435 for as_dir in $PATH
27436 do
27437   IFS=$as_save_IFS
27438   test -z "$as_dir" && as_dir=.
27439     for ac_exec_ext in '' $ac_executable_extensions; do
27440   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27441     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27442     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27443     break 2
27444   fi
27445 done
27446   done
27447 IFS=$as_save_IFS
27448 
27449   ;;
27450 esac
27451 fi
27452 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27453 if test -n "$POTENTIAL_CC"; then
27454   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27455 $as_echo "$POTENTIAL_CC" >&6; }
27456 else
27457   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27458 $as_echo "no" >&6; }
27459 fi
27460 
27461 
27462   test -n "$POTENTIAL_CC" && break
27463 done
27464 
27465       if test "x$POTENTIAL_CC" != x; then
27466         CC=$POTENTIAL_CC
27467       else
27468         as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27469       fi
27470     else
27471       # Otherwise it might already be a complete path
27472       if test ! -x "$CC"; then
27473         as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27474       fi
27475     fi
27476   else
27477     # No user supplied value. Locate compiler ourselves.
27478 
27479     # If we are cross compiling, assume cross compilation tools follows the
27480     # cross compilation standard where they are prefixed with the autoconf
27481     # standard name for the target. For example the binary
27482     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27483     # If we are not cross compiling, then the default compiler name will be
27484     # used.
27485 
27486     CC=
27487     # If TOOLS_DIR is set, check for all compiler names in there first
27488     # before checking the rest of the PATH.
27489     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27490     # step, this should not be necessary.
27491     if test -n "$TOOLS_DIR"; then
27492       PATH_save="$PATH"
27493       PATH="$TOOLS_DIR"
27494       for ac_prog in $SEARCH_LIST
27495 do
27496   # Extract the first word of "$ac_prog", so it can be a program name with args.
27497 set dummy $ac_prog; ac_word=$2
27498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27499 $as_echo_n "checking for $ac_word... " >&6; }
27500 if ${ac_cv_path_TOOLS_DIR_CC+:} false; then :
27501   $as_echo_n "(cached) " >&6
27502 else
27503   case $TOOLS_DIR_CC in
27504   [\\/]* | ?:[\\/]*)
27505   ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path.
27506   ;;
27507   *)
27508   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27509 for as_dir in $PATH
27510 do
27511   IFS=$as_save_IFS
27512   test -z "$as_dir" && as_dir=.
27513     for ac_exec_ext in '' $ac_executable_extensions; do
27514   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27515     ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext"
27516     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27517     break 2
27518   fi
27519 done
27520   done
27521 IFS=$as_save_IFS
27522 
27523   ;;
27524 esac
27525 fi
27526 TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC
27527 if test -n "$TOOLS_DIR_CC"; then
27528   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5
27529 $as_echo "$TOOLS_DIR_CC" >&6; }
27530 else
27531   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27532 $as_echo "no" >&6; }
27533 fi
27534 
27535 
27536   test -n "$TOOLS_DIR_CC" && break
27537 done
27538 
27539       CC=$TOOLS_DIR_CC
27540       PATH="$PATH_save"
27541     fi
27542 
27543     # AC_PATH_PROGS can't be run multiple times with the same variable,
27544     # so create a new name for this run.
27545     if test "x$CC" = x; then
27546       for ac_prog in $SEARCH_LIST
27547 do
27548   # Extract the first word of "$ac_prog", so it can be a program name with args.
27549 set dummy $ac_prog; ac_word=$2
27550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27551 $as_echo_n "checking for $ac_word... " >&6; }
27552 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27553   $as_echo_n "(cached) " >&6
27554 else
27555   case $POTENTIAL_CC in
27556   [\\/]* | ?:[\\/]*)
27557   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27558   ;;
27559   *)
27560   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27561 for as_dir in $PATH
27562 do
27563   IFS=$as_save_IFS
27564   test -z "$as_dir" && as_dir=.
27565     for ac_exec_ext in '' $ac_executable_extensions; do
27566   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27567     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27568     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27569     break 2
27570   fi
27571 done
27572   done
27573 IFS=$as_save_IFS
27574 
27575   ;;
27576 esac
27577 fi
27578 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27579 if test -n "$POTENTIAL_CC"; then
27580   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27581 $as_echo "$POTENTIAL_CC" >&6; }
27582 else
27583   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27584 $as_echo "no" >&6; }
27585 fi
27586 
27587 
27588   test -n "$POTENTIAL_CC" && break
27589 done
27590 
27591       CC=$POTENTIAL_CC
27592     fi
27593 
27594     if test "x$CC" = x; then
27595 
27596   # Print a helpful message on how to acquire the necessary build dependency.
27597   # devkit is the help tag: freetype, cups, pulse, alsa etc
27598   MISSING_DEPENDENCY=devkit
27599 
27600   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27601     cygwin_help $MISSING_DEPENDENCY
27602   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27603     msys_help $MISSING_DEPENDENCY
27604   else
27605     PKGHANDLER_COMMAND=
27606 
27607     case $PKGHANDLER in
27608       apt-get)
27609         apt_help     $MISSING_DEPENDENCY ;;
27610       yum)
27611         yum_help     $MISSING_DEPENDENCY ;;
27612       port)
27613         port_help    $MISSING_DEPENDENCY ;;
27614       pkgutil)
27615         pkgutil_help $MISSING_DEPENDENCY ;;
27616       pkgadd)
27617         pkgadd_help  $MISSING_DEPENDENCY ;;
27618     esac
27619 
27620     if test "x$PKGHANDLER_COMMAND" != x; then
27621       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
27622     fi
27623   fi
27624 
27625       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
27626     fi
27627   fi
27628 
27629   # Now we have a compiler binary in CC. Make sure it's okay.
27630 
27631   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27632 
27633   # First separate the path from the arguments. This will split at the first
27634   # space.
27635   complete="$CC"
27636   path="${complete%% *}"
27637   tmp="$complete EOL"
27638   arguments="${tmp#* }"
27639 
27640   # Input might be given as Windows format, start by converting to
27641   # unix format.
27642   new_path=`$CYGPATH -u "$path"`
27643 
27644   # Now try to locate executable using which
27645   new_path=`$WHICH "$new_path" 2> /dev/null`
27646   # bat and cmd files are not always considered executable in cygwin causing which
27647   # to not find them
27648   if test "x$new_path" = x \
27649       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27650       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27651     new_path=`$CYGPATH -u "$path"`
27652   fi
27653   if test "x$new_path" = x; then
27654     # Oops. Which didn't find the executable.
27655     # The splitting of arguments from the executable at a space might have been incorrect,
27656     # since paths with space are more likely in Windows. Give it another try with the whole
27657     # argument.
27658     path="$complete"
27659     arguments="EOL"
27660     new_path=`$CYGPATH -u "$path"`
27661     new_path=`$WHICH "$new_path" 2> /dev/null`
27662     # bat and cmd files are not always considered executable in cygwin causing which
27663     # to not find them
27664     if test "x$new_path" = x \
27665         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27666         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27667       new_path=`$CYGPATH -u "$path"`
27668     fi
27669     if test "x$new_path" = x; then
27670       # It's still not found. Now this is an unrecoverable error.
27671       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27672 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27673       has_space=`$ECHO "$complete" | $GREP " "`
27674       if test "x$has_space" != x; then
27675         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27676 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27677       fi
27678       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27679     fi
27680   fi
27681 
27682   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27683   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27684   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27685   # "foo.exe" is OK but "foo" is an error.
27686   #
27687   # This test is therefore slightly more accurate than "test -f" to check for file presence.
27688   # It is also a way to make sure we got the proper file name for the real test later on.
27689   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27690   if test "x$test_shortpath" = x; then
27691     # Short path failed, file does not exist as specified.
27692     # Try adding .exe or .cmd
27693     if test -f "${new_path}.exe"; then
27694       input_to_shortpath="${new_path}.exe"
27695     elif test -f "${new_path}.cmd"; then
27696       input_to_shortpath="${new_path}.cmd"
27697     else
27698       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
27699 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
27700       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27701 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27702       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27703     fi
27704   else
27705     input_to_shortpath="$new_path"
27706   fi
27707 
27708   # Call helper function which possibly converts this using DOS-style short mode.
27709   # If so, the updated path is stored in $new_path.
27710   new_path="$input_to_shortpath"
27711 
27712   input_path="$input_to_shortpath"
27713   # Check if we need to convert this using DOS-style short mode. If the path
27714   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27715   # take no chances and rewrite it.
27716   # Note: m4 eats our [], so we need to use [ and ] instead.
27717   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27718   if test "x$has_forbidden_chars" != x; then
27719     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27720     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27721     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27722     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27723       # Going to short mode and back again did indeed matter. Since short mode is
27724       # case insensitive, let's make it lowercase to improve readability.
27725       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27726       # Now convert it back to Unix-stile (cygpath)
27727       input_path=`$CYGPATH -u "$shortmode_path"`
27728       new_path="$input_path"
27729     fi
27730   fi
27731 
27732   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27733   if test "x$test_cygdrive_prefix" = x; then
27734     # As a simple fix, exclude /usr/bin since it's not a real path.
27735     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27736       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27737       # a path prefixed by /cygdrive for fixpath to work.
27738       new_path="$CYGWIN_ROOT_PATH$input_path"
27739     fi
27740   fi
27741 
27742   # remove trailing .exe if any
27743   new_path="${new_path/%.exe/}"
27744 
27745   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27746 
27747   # First separate the path from the arguments. This will split at the first
27748   # space.
27749   complete="$CC"
27750   path="${complete%% *}"
27751   tmp="$complete EOL"
27752   arguments="${tmp#* }"
27753 
27754   # Input might be given as Windows format, start by converting to
27755   # unix format.
27756   new_path="$path"
27757 
27758   windows_path="$new_path"
27759   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27760     unix_path=`$CYGPATH -u "$windows_path"`
27761     new_path="$unix_path"
27762   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27763     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27764     new_path="$unix_path"
27765   fi
27766 
27767 
27768   # Now try to locate executable using which
27769   new_path=`$WHICH "$new_path" 2> /dev/null`
27770 
27771   if test "x$new_path" = x; then
27772     # Oops. Which didn't find the executable.
27773     # The splitting of arguments from the executable at a space might have been incorrect,
27774     # since paths with space are more likely in Windows. Give it another try with the whole
27775     # argument.
27776     path="$complete"
27777     arguments="EOL"
27778     new_path="$path"
27779 
27780   windows_path="$new_path"
27781   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27782     unix_path=`$CYGPATH -u "$windows_path"`
27783     new_path="$unix_path"
27784   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27785     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27786     new_path="$unix_path"
27787   fi
27788 
27789 
27790     new_path=`$WHICH "$new_path" 2> /dev/null`
27791 
27792     if test "x$new_path" = x; then
27793       # It's still not found. Now this is an unrecoverable error.
27794       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27795 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27796       has_space=`$ECHO "$complete" | $GREP " "`
27797       if test "x$has_space" != x; then
27798         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27799 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27800       fi
27801       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27802     fi
27803   fi
27804 
27805   # Now new_path has a complete unix path to the binary
27806   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27807     # Keep paths in /bin as-is, but remove trailing .exe if any
27808     new_path="${new_path/%.exe/}"
27809     # Do not save /bin paths to all_fixpath_prefixes!
27810   else
27811     # Not in mixed or Windows style, start by that.
27812     new_path=`cmd //c echo $new_path`
27813 
27814   input_path="$new_path"
27815   # Check if we need to convert this using DOS-style short mode. If the path
27816   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27817   # take no chances and rewrite it.
27818   # Note: m4 eats our [], so we need to use [ and ] instead.
27819   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27820   if test "x$has_forbidden_chars" != x; then
27821     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27822     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27823   fi
27824 
27825     # Output is in $new_path
27826 
27827   windows_path="$new_path"
27828   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27829     unix_path=`$CYGPATH -u "$windows_path"`
27830     new_path="$unix_path"
27831   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27832     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27833     new_path="$unix_path"
27834   fi
27835 
27836     # remove trailing .exe if any
27837     new_path="${new_path/%.exe/}"
27838 
27839     # Save the first 10 bytes of this path to the storage, so fixpath can work.
27840     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27841   fi
27842 
27843   else
27844     # We're on a posix platform. Hooray! :)
27845     # First separate the path from the arguments. This will split at the first
27846     # space.
27847     complete="$CC"
27848     path="${complete%% *}"
27849     tmp="$complete EOL"
27850     arguments="${tmp#* }"
27851 
27852     # Cannot rely on the command "which" here since it doesn't always work.
27853     is_absolute_path=`$ECHO "$path" | $GREP ^/`
27854     if test -z "$is_absolute_path"; then
27855       # Path to executable is not absolute. Find it.
27856       IFS_save="$IFS"
27857       IFS=:
27858       for p in $PATH; do
27859         if test -f "$p/$path" && test -x "$p/$path"; then
27860           new_path="$p/$path"
27861           break
27862         fi
27863       done
27864       IFS="$IFS_save"
27865     else
27866       # This is an absolute path, we can use it without further modifications.
27867       new_path="$path"
27868     fi
27869 
27870     if test "x$new_path" = x; then
27871       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27872 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27873       has_space=`$ECHO "$complete" | $GREP " "`
27874       if test "x$has_space" != x; then
27875         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27876 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27877       fi
27878       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27879     fi
27880   fi
27881 
27882   # Now join together the path and the arguments once again
27883   if test "x$arguments" != xEOL; then
27884     new_complete="$new_path ${arguments% *}"
27885   else
27886     new_complete="$new_path"
27887   fi
27888 
27889   if test "x$complete" != "x$new_complete"; then
27890     CC="$new_complete"
27891     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
27892 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
27893   fi
27894 
27895   TEST_COMPILER="$CC"
27896   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
27897   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
27898   if test "x$OPENJDK_BUILD_OS" != xaix; then
27899     # FIXME: This test should not be needed anymore; we don't do that for any platform.
27900     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
27901 $as_echo_n "checking resolved symbolic links for CC... " >&6; }
27902 
27903   if test "x$OPENJDK_BUILD_OS" != xwindows; then
27904     # Follow a chain of symbolic links. Use readlink
27905     # where it exists, else fall back to horribly
27906     # complicated shell code.
27907     if test "x$READLINK_TESTED" != yes; then
27908       # On MacOSX there is a readlink tool with a different
27909       # purpose than the GNU readlink tool. Check the found readlink.
27910       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
27911       if test "x$ISGNU" = x; then
27912         # A readlink that we do not know how to use.
27913         # Are there other non-GNU readlinks out there?
27914         READLINK_TESTED=yes
27915         READLINK=
27916       fi
27917     fi
27918 
27919     if test "x$READLINK" != x; then
27920       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
27921     else
27922       # Save the current directory for restoring afterwards
27923       STARTDIR=$PWD
27924       COUNTER=0
27925       sym_link_dir=`$DIRNAME $TEST_COMPILER`
27926       sym_link_file=`$BASENAME $TEST_COMPILER`
27927       cd $sym_link_dir
27928       # Use -P flag to resolve symlinks in directories.
27929       cd `$THEPWDCMD -P`
27930       sym_link_dir=`$THEPWDCMD -P`
27931       # Resolve file symlinks
27932       while test $COUNTER -lt 20; do
27933         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
27934         if test "x$ISLINK" == x; then
27935           # This is not a symbolic link! We are done!
27936           break
27937         fi
27938         # Again resolve directory symlinks since the target of the just found
27939         # link could be in a different directory
27940         cd `$DIRNAME $ISLINK`
27941         sym_link_dir=`$THEPWDCMD -P`
27942         sym_link_file=`$BASENAME $ISLINK`
27943         let COUNTER=COUNTER+1
27944       done
27945       cd $STARTDIR
27946       TEST_COMPILER=$sym_link_dir/$sym_link_file
27947     fi
27948   fi
27949 
27950     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
27951 $as_echo "$TEST_COMPILER" >&6; }
27952   fi
27953   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
27954 $as_echo_n "checking if CC is disguised ccache... " >&6; }
27955 
27956   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
27957   if test "x$COMPILER_BASENAME" = "xccache"; then
27958     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
27959 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
27960     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
27961     # We want to control ccache invocation ourselves, so ignore this cc and try
27962     # searching again.
27963 
27964     # Remove the path to the fake ccache cc from the PATH
27965     RETRY_COMPILER_SAVED_PATH="$PATH"
27966     COMPILER_DIRNAME=`$DIRNAME $CC`
27967     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
27968 
27969     # Try again looking for our compiler
27970     if test -n "$ac_tool_prefix"; then
27971   for ac_prog in $TOOLCHAIN_CC_BINARY
27972   do
27973     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
27974 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
27975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27976 $as_echo_n "checking for $ac_word... " >&6; }
27977 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
27978   $as_echo_n "(cached) " >&6
27979 else
27980   if test -n "$PROPER_COMPILER_CC"; then
27981   ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
27982 else
27983 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27984 for as_dir in $PATH
27985 do
27986   IFS=$as_save_IFS
27987   test -z "$as_dir" && as_dir=.
27988     for ac_exec_ext in '' $ac_executable_extensions; do
27989   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27990     ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
27991     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27992     break 2
27993   fi
27994 done
27995   done
27996 IFS=$as_save_IFS
27997 
27998 fi
27999 fi
28000 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
28001 if test -n "$PROPER_COMPILER_CC"; then
28002   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28003 $as_echo "$PROPER_COMPILER_CC" >&6; }
28004 else
28005   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28006 $as_echo "no" >&6; }
28007 fi
28008 
28009 
28010     test -n "$PROPER_COMPILER_CC" && break
28011   done
28012 fi
28013 if test -z "$PROPER_COMPILER_CC"; then
28014   ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
28015   for ac_prog in $TOOLCHAIN_CC_BINARY
28016 do
28017   # Extract the first word of "$ac_prog", so it can be a program name with args.
28018 set dummy $ac_prog; ac_word=$2
28019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28020 $as_echo_n "checking for $ac_word... " >&6; }
28021 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
28022   $as_echo_n "(cached) " >&6
28023 else
28024   if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28025   ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
28026 else
28027 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28028 for as_dir in $PATH
28029 do
28030   IFS=$as_save_IFS
28031   test -z "$as_dir" && as_dir=.
28032     for ac_exec_ext in '' $ac_executable_extensions; do
28033   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28034     ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
28035     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28036     break 2
28037   fi
28038 done
28039   done
28040 IFS=$as_save_IFS
28041 
28042 fi
28043 fi
28044 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
28045 if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28046   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
28047 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
28048 else
28049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28050 $as_echo "no" >&6; }
28051 fi
28052 
28053 
28054   test -n "$ac_ct_PROPER_COMPILER_CC" && break
28055 done
28056 
28057   if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
28058     PROPER_COMPILER_CC=""
28059   else
28060     case $cross_compiling:$ac_tool_warned in
28061 yes:)
28062 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28063 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28064 ac_tool_warned=yes ;;
28065 esac
28066     PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
28067   fi
28068 fi
28069 
28070 
28071   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28072 
28073   # First separate the path from the arguments. This will split at the first
28074   # space.
28075   complete="$PROPER_COMPILER_CC"
28076   path="${complete%% *}"
28077   tmp="$complete EOL"
28078   arguments="${tmp#* }"
28079 
28080   # Input might be given as Windows format, start by converting to
28081   # unix format.
28082   new_path=`$CYGPATH -u "$path"`
28083 
28084   # Now try to locate executable using which
28085   new_path=`$WHICH "$new_path" 2> /dev/null`
28086   # bat and cmd files are not always considered executable in cygwin causing which
28087   # to not find them
28088   if test "x$new_path" = x \
28089       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28090       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28091     new_path=`$CYGPATH -u "$path"`
28092   fi
28093   if test "x$new_path" = x; then
28094     # Oops. Which didn't find the executable.
28095     # The splitting of arguments from the executable at a space might have been incorrect,
28096     # since paths with space are more likely in Windows. Give it another try with the whole
28097     # argument.
28098     path="$complete"
28099     arguments="EOL"
28100     new_path=`$CYGPATH -u "$path"`
28101     new_path=`$WHICH "$new_path" 2> /dev/null`
28102     # bat and cmd files are not always considered executable in cygwin causing which
28103     # to not find them
28104     if test "x$new_path" = x \
28105         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28106         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28107       new_path=`$CYGPATH -u "$path"`
28108     fi
28109     if test "x$new_path" = x; then
28110       # It's still not found. Now this is an unrecoverable error.
28111       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28112 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28113       has_space=`$ECHO "$complete" | $GREP " "`
28114       if test "x$has_space" != x; then
28115         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28116 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28117       fi
28118       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28119     fi
28120   fi
28121 
28122   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28123   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28124   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28125   # "foo.exe" is OK but "foo" is an error.
28126   #
28127   # This test is therefore slightly more accurate than "test -f" to check for file presence.
28128   # It is also a way to make sure we got the proper file name for the real test later on.
28129   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28130   if test "x$test_shortpath" = x; then
28131     # Short path failed, file does not exist as specified.
28132     # Try adding .exe or .cmd
28133     if test -f "${new_path}.exe"; then
28134       input_to_shortpath="${new_path}.exe"
28135     elif test -f "${new_path}.cmd"; then
28136       input_to_shortpath="${new_path}.cmd"
28137     else
28138       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
28139 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
28140       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28141 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28142       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28143     fi
28144   else
28145     input_to_shortpath="$new_path"
28146   fi
28147 
28148   # Call helper function which possibly converts this using DOS-style short mode.
28149   # If so, the updated path is stored in $new_path.
28150   new_path="$input_to_shortpath"
28151 
28152   input_path="$input_to_shortpath"
28153   # Check if we need to convert this using DOS-style short mode. If the path
28154   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28155   # take no chances and rewrite it.
28156   # Note: m4 eats our [], so we need to use [ and ] instead.
28157   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28158   if test "x$has_forbidden_chars" != x; then
28159     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28160     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28161     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28162     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28163       # Going to short mode and back again did indeed matter. Since short mode is
28164       # case insensitive, let's make it lowercase to improve readability.
28165       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28166       # Now convert it back to Unix-stile (cygpath)
28167       input_path=`$CYGPATH -u "$shortmode_path"`
28168       new_path="$input_path"
28169     fi
28170   fi
28171 
28172   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28173   if test "x$test_cygdrive_prefix" = x; then
28174     # As a simple fix, exclude /usr/bin since it's not a real path.
28175     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28176       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28177       # a path prefixed by /cygdrive for fixpath to work.
28178       new_path="$CYGWIN_ROOT_PATH$input_path"
28179     fi
28180   fi
28181 
28182   # remove trailing .exe if any
28183   new_path="${new_path/%.exe/}"
28184 
28185   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28186 
28187   # First separate the path from the arguments. This will split at the first
28188   # space.
28189   complete="$PROPER_COMPILER_CC"
28190   path="${complete%% *}"
28191   tmp="$complete EOL"
28192   arguments="${tmp#* }"
28193 
28194   # Input might be given as Windows format, start by converting to
28195   # unix format.
28196   new_path="$path"
28197 
28198   windows_path="$new_path"
28199   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28200     unix_path=`$CYGPATH -u "$windows_path"`
28201     new_path="$unix_path"
28202   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28203     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28204     new_path="$unix_path"
28205   fi
28206 
28207 
28208   # Now try to locate executable using which
28209   new_path=`$WHICH "$new_path" 2> /dev/null`
28210 
28211   if test "x$new_path" = x; then
28212     # Oops. Which didn't find the executable.
28213     # The splitting of arguments from the executable at a space might have been incorrect,
28214     # since paths with space are more likely in Windows. Give it another try with the whole
28215     # argument.
28216     path="$complete"
28217     arguments="EOL"
28218     new_path="$path"
28219 
28220   windows_path="$new_path"
28221   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28222     unix_path=`$CYGPATH -u "$windows_path"`
28223     new_path="$unix_path"
28224   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28225     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28226     new_path="$unix_path"
28227   fi
28228 
28229 
28230     new_path=`$WHICH "$new_path" 2> /dev/null`
28231 
28232     if test "x$new_path" = x; then
28233       # It's still not found. Now this is an unrecoverable error.
28234       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28235 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28236       has_space=`$ECHO "$complete" | $GREP " "`
28237       if test "x$has_space" != x; then
28238         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28239 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28240       fi
28241       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28242     fi
28243   fi
28244 
28245   # Now new_path has a complete unix path to the binary
28246   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28247     # Keep paths in /bin as-is, but remove trailing .exe if any
28248     new_path="${new_path/%.exe/}"
28249     # Do not save /bin paths to all_fixpath_prefixes!
28250   else
28251     # Not in mixed or Windows style, start by that.
28252     new_path=`cmd //c echo $new_path`
28253 
28254   input_path="$new_path"
28255   # Check if we need to convert this using DOS-style short mode. If the path
28256   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28257   # take no chances and rewrite it.
28258   # Note: m4 eats our [], so we need to use [ and ] instead.
28259   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28260   if test "x$has_forbidden_chars" != x; then
28261     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28262     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28263   fi
28264 
28265     # Output is in $new_path
28266 
28267   windows_path="$new_path"
28268   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28269     unix_path=`$CYGPATH -u "$windows_path"`
28270     new_path="$unix_path"
28271   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28272     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28273     new_path="$unix_path"
28274   fi
28275 
28276     # remove trailing .exe if any
28277     new_path="${new_path/%.exe/}"
28278 
28279     # Save the first 10 bytes of this path to the storage, so fixpath can work.
28280     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28281   fi
28282 
28283   else
28284     # We're on a posix platform. Hooray! :)
28285     # First separate the path from the arguments. This will split at the first
28286     # space.
28287     complete="$PROPER_COMPILER_CC"
28288     path="${complete%% *}"
28289     tmp="$complete EOL"
28290     arguments="${tmp#* }"
28291 
28292     # Cannot rely on the command "which" here since it doesn't always work.
28293     is_absolute_path=`$ECHO "$path" | $GREP ^/`
28294     if test -z "$is_absolute_path"; then
28295       # Path to executable is not absolute. Find it.
28296       IFS_save="$IFS"
28297       IFS=:
28298       for p in $PATH; do
28299         if test -f "$p/$path" && test -x "$p/$path"; then
28300           new_path="$p/$path"
28301           break
28302         fi
28303       done
28304       IFS="$IFS_save"
28305     else
28306       # This is an absolute path, we can use it without further modifications.
28307       new_path="$path"
28308     fi
28309 
28310     if test "x$new_path" = x; then
28311       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28312 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28313       has_space=`$ECHO "$complete" | $GREP " "`
28314       if test "x$has_space" != x; then
28315         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28316 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28317       fi
28318       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28319     fi
28320   fi
28321 
28322   # Now join together the path and the arguments once again
28323   if test "x$arguments" != xEOL; then
28324     new_complete="$new_path ${arguments% *}"
28325   else
28326     new_complete="$new_path"
28327   fi
28328 
28329   if test "x$complete" != "x$new_complete"; then
28330     PROPER_COMPILER_CC="$new_complete"
28331     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
28332 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
28333   fi
28334 
28335     PATH="$RETRY_COMPILER_SAVED_PATH"
28336 
28337     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
28338 $as_echo_n "checking for resolved symbolic links for CC... " >&6; }
28339 
28340   if test "x$OPENJDK_BUILD_OS" != xwindows; then
28341     # Follow a chain of symbolic links. Use readlink
28342     # where it exists, else fall back to horribly
28343     # complicated shell code.
28344     if test "x$READLINK_TESTED" != yes; then
28345       # On MacOSX there is a readlink tool with a different
28346       # purpose than the GNU readlink tool. Check the found readlink.
28347       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28348       if test "x$ISGNU" = x; then
28349         # A readlink that we do not know how to use.
28350         # Are there other non-GNU readlinks out there?
28351         READLINK_TESTED=yes
28352         READLINK=
28353       fi
28354     fi
28355 
28356     if test "x$READLINK" != x; then
28357       PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
28358     else
28359       # Save the current directory for restoring afterwards
28360       STARTDIR=$PWD
28361       COUNTER=0
28362       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
28363       sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
28364       cd $sym_link_dir
28365       # Use -P flag to resolve symlinks in directories.
28366       cd `$THEPWDCMD -P`
28367       sym_link_dir=`$THEPWDCMD -P`
28368       # Resolve file symlinks
28369       while test $COUNTER -lt 20; do
28370         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28371         if test "x$ISLINK" == x; then
28372           # This is not a symbolic link! We are done!
28373           break
28374         fi
28375         # Again resolve directory symlinks since the target of the just found
28376         # link could be in a different directory
28377         cd `$DIRNAME $ISLINK`
28378         sym_link_dir=`$THEPWDCMD -P`
28379         sym_link_file=`$BASENAME $ISLINK`
28380         let COUNTER=COUNTER+1
28381       done
28382       cd $STARTDIR
28383       PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
28384     fi
28385   fi
28386 
28387     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28388 $as_echo "$PROPER_COMPILER_CC" >&6; }
28389     CC="$PROPER_COMPILER_CC"
28390   else
28391     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
28392 $as_echo "no, keeping CC" >&6; }
28393   fi
28394 
28395 
28396   COMPILER=$CC
28397   COMPILER_NAME=$COMPILER_NAME
28398 
28399   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
28400     # cc -V output typically looks like
28401     #     cc: Sun C 5.12 Linux_i386 2011/11/16
28402     COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
28403     # Check that this is likely to be the Solaris Studio cc.
28404     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
28405     if test $? -ne 0; then
28406       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28407       { $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
28408 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28409       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28410 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28411       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28412 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28413       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28414     fi
28415     # Remove usage instructions (if present), and
28416     # collapse compiler output into a single line
28417     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28418         $SED -e 's/ *[Uu]sage:.*//'`
28419     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28420         $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
28421   elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
28422     # xlc -qversion output typically looks like
28423     #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
28424     #     Version: 11.01.0000.0015
28425     COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
28426     # Check that this is likely to be the IBM XL C compiler.
28427     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
28428     if test $? -ne 0; then
28429       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28430       { $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
28431 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28432       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28433 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28434       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28435 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28436       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28437     fi
28438     # Collapse compiler output into a single line
28439     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28440     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28441         $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
28442   elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
28443     # There is no specific version flag, but all output starts with a version string.
28444     # First line typically looks something like:
28445     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
28446     COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
28447     # Check that this is likely to be Microsoft CL.EXE.
28448     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
28449     if test $? -ne 0; then
28450       { $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
28451 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28452       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28453 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28454       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28455     fi
28456     # Collapse compiler output into a single line
28457     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28458     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28459         $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
28460   elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
28461     # gcc --version output typically looks like
28462     #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
28463     #     Copyright (C) 2013 Free Software Foundation, Inc.
28464     #     This is free software; see the source for copying conditions.  There is NO
28465     #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28466     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28467     # Check that this is likely to be GCC.
28468     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
28469     if test $? -ne 0; then
28470       { $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
28471 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28472       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
28473 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
28474       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28475     fi
28476     # Remove Copyright and legalese from version string, and
28477     # collapse into a single line
28478     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28479         $SED -e 's/ *Copyright .*//'`
28480     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28481         $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
28482   elif test  "x$TOOLCHAIN_TYPE" = xclang; then
28483     # clang --version output typically looks like
28484     #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
28485     #    clang version 3.3 (tags/RELEASE_33/final)
28486     # or
28487     #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
28488     #    Target: x86_64-pc-linux-gnu
28489     #    Thread model: posix
28490     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28491     # Check that this is likely to be clang
28492     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
28493     if test $? -ne 0; then
28494       { $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
28495 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28496       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28497 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28498       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28499     fi
28500     # Collapse compiler output into a single line
28501     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28502     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28503         $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
28504   else
28505       as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
28506   fi
28507   # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
28508   CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
28509   # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
28510   CC_VERSION_STRING="$COMPILER_VERSION_STRING"
28511 
28512   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
28513 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
28514 
28515 
28516   # Now that we have resolved CC ourself, let autoconf have its go at it
28517   ac_ext=c
28518 ac_cpp='$CPP $CPPFLAGS'
28519 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28520 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28521 ac_compiler_gnu=$ac_cv_c_compiler_gnu
28522 if test -n "$ac_tool_prefix"; then
28523   for ac_prog in $CC
28524   do
28525     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28526 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28528 $as_echo_n "checking for $ac_word... " >&6; }
28529 if ${ac_cv_prog_CC+:} false; then :
28530   $as_echo_n "(cached) " >&6
28531 else
28532   if test -n "$CC"; then
28533   ac_cv_prog_CC="$CC" # Let the user override the test.
28534 else
28535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28536 for as_dir in $PATH
28537 do
28538   IFS=$as_save_IFS
28539   test -z "$as_dir" && as_dir=.
28540     for ac_exec_ext in '' $ac_executable_extensions; do
28541   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28542     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
28543     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28544     break 2
28545   fi
28546 done
28547   done
28548 IFS=$as_save_IFS
28549 
28550 fi
28551 fi
28552 CC=$ac_cv_prog_CC
28553 if test -n "$CC"; then
28554   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
28555 $as_echo "$CC" >&6; }
28556 else
28557   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28558 $as_echo "no" >&6; }
28559 fi
28560 
28561 
28562     test -n "$CC" && break
28563   done
28564 fi
28565 if test -z "$CC"; then
28566   ac_ct_CC=$CC
28567   for ac_prog in $CC
28568 do
28569   # Extract the first word of "$ac_prog", so it can be a program name with args.
28570 set dummy $ac_prog; ac_word=$2
28571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28572 $as_echo_n "checking for $ac_word... " >&6; }
28573 if ${ac_cv_prog_ac_ct_CC+:} false; then :
28574   $as_echo_n "(cached) " >&6
28575 else
28576   if test -n "$ac_ct_CC"; then
28577   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
28578 else
28579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28580 for as_dir in $PATH
28581 do
28582   IFS=$as_save_IFS
28583   test -z "$as_dir" && as_dir=.
28584     for ac_exec_ext in '' $ac_executable_extensions; do
28585   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28586     ac_cv_prog_ac_ct_CC="$ac_prog"
28587     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28588     break 2
28589   fi
28590 done
28591   done
28592 IFS=$as_save_IFS
28593 
28594 fi
28595 fi
28596 ac_ct_CC=$ac_cv_prog_ac_ct_CC
28597 if test -n "$ac_ct_CC"; then
28598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
28599 $as_echo "$ac_ct_CC" >&6; }
28600 else
28601   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28602 $as_echo "no" >&6; }
28603 fi
28604 
28605 
28606   test -n "$ac_ct_CC" && break
28607 done
28608 
28609   if test "x$ac_ct_CC" = x; then
28610     CC=""
28611   else
28612     case $cross_compiling:$ac_tool_warned in
28613 yes:)
28614 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28615 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28616 ac_tool_warned=yes ;;
28617 esac
28618     CC=$ac_ct_CC
28619   fi
28620 fi
28621 
28622 
28623 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28624 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28625 as_fn_error $? "no acceptable C compiler found in \$PATH
28626 See \`config.log' for more details" "$LINENO" 5; }
28627 
28628 # Provide some information about the compiler.
28629 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
28630 set X $ac_compile
28631 ac_compiler=$2
28632 for ac_option in --version -v -V -qversion; do
28633   { { ac_try="$ac_compiler $ac_option >&5"
28634 case "(($ac_try" in
28635   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28636   *) ac_try_echo=$ac_try;;
28637 esac
28638 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28639 $as_echo "$ac_try_echo"; } >&5
28640   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
28641   ac_status=$?
28642   if test -s conftest.err; then
28643     sed '10a\
28644 ... rest of stderr output deleted ...
28645          10q' conftest.err >conftest.er1
28646     cat conftest.er1 >&5
28647   fi
28648   rm -f conftest.er1 conftest.err
28649   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28650   test $ac_status = 0; }
28651 done
28652 
28653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28654 /* end confdefs.h.  */
28655 
28656 int
28657 main ()
28658 {
28659 
28660   ;
28661   return 0;
28662 }
28663 _ACEOF
28664 ac_clean_files_save=$ac_clean_files
28665 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
28666 # Try to create an executable without -o first, disregard a.out.
28667 # It will help us diagnose broken compilers, and finding out an intuition
28668 # of exeext.
28669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
28670 $as_echo_n "checking whether the C compiler works... " >&6; }
28671 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
28672 
28673 # The possible output files:
28674 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
28675 
28676 ac_rmfiles=
28677 for ac_file in $ac_files
28678 do
28679   case $ac_file in
28680     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28681     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
28682   esac
28683 done
28684 rm -f $ac_rmfiles
28685 
28686 if { { ac_try="$ac_link_default"
28687 case "(($ac_try" in
28688   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28689   *) ac_try_echo=$ac_try;;
28690 esac
28691 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28692 $as_echo "$ac_try_echo"; } >&5
28693   (eval "$ac_link_default") 2>&5
28694   ac_status=$?
28695   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28696   test $ac_status = 0; }; then :
28697   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
28698 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
28699 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
28700 # so that the user can short-circuit this test for compilers unknown to
28701 # Autoconf.
28702 for ac_file in $ac_files ''
28703 do
28704   test -f "$ac_file" || continue
28705   case $ac_file in
28706     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
28707         ;;
28708     [ab].out )
28709         # We found the default executable, but exeext='' is most
28710         # certainly right.
28711         break;;
28712     *.* )
28713         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
28714         then :; else
28715            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28716         fi
28717         # We set ac_cv_exeext here because the later test for it is not
28718         # safe: cross compilers may not add the suffix if given an `-o'
28719         # argument, so we may need to know it at that point already.
28720         # Even if this section looks crufty: it has the advantage of
28721         # actually working.
28722         break;;
28723     * )
28724         break;;
28725   esac
28726 done
28727 test "$ac_cv_exeext" = no && ac_cv_exeext=
28728 
28729 else
28730   ac_file=''
28731 fi
28732 if test -z "$ac_file"; then :
28733   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28734 $as_echo "no" >&6; }
28735 $as_echo "$as_me: failed program was:" >&5
28736 sed 's/^/| /' conftest.$ac_ext >&5
28737 
28738 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28739 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28740 as_fn_error 77 "C compiler cannot create executables
28741 See \`config.log' for more details" "$LINENO" 5; }
28742 else
28743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28744 $as_echo "yes" >&6; }
28745 fi
28746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
28747 $as_echo_n "checking for C compiler default output file name... " >&6; }
28748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
28749 $as_echo "$ac_file" >&6; }
28750 ac_exeext=$ac_cv_exeext
28751 
28752 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
28753 ac_clean_files=$ac_clean_files_save
28754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
28755 $as_echo_n "checking for suffix of executables... " >&6; }
28756 if { { ac_try="$ac_link"
28757 case "(($ac_try" in
28758   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28759   *) ac_try_echo=$ac_try;;
28760 esac
28761 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28762 $as_echo "$ac_try_echo"; } >&5
28763   (eval "$ac_link") 2>&5
28764   ac_status=$?
28765   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28766   test $ac_status = 0; }; then :
28767   # If both `conftest.exe' and `conftest' are `present' (well, observable)
28768 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
28769 # work properly (i.e., refer to `conftest.exe'), while it won't with
28770 # `rm'.
28771 for ac_file in conftest.exe conftest conftest.*; do
28772   test -f "$ac_file" || continue
28773   case $ac_file in
28774     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28775     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28776           break;;
28777     * ) break;;
28778   esac
28779 done
28780 else
28781   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28782 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28783 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
28784 See \`config.log' for more details" "$LINENO" 5; }
28785 fi
28786 rm -f conftest conftest$ac_cv_exeext
28787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
28788 $as_echo "$ac_cv_exeext" >&6; }
28789 
28790 rm -f conftest.$ac_ext
28791 EXEEXT=$ac_cv_exeext
28792 ac_exeext=$EXEEXT
28793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28794 /* end confdefs.h.  */
28795 #include <stdio.h>
28796 int
28797 main ()
28798 {
28799 FILE *f = fopen ("conftest.out", "w");
28800  return ferror (f) || fclose (f) != 0;
28801 
28802   ;
28803   return 0;
28804 }
28805 _ACEOF
28806 ac_clean_files="$ac_clean_files conftest.out"
28807 # Check that the compiler produces executables we can run.  If not, either
28808 # the compiler is broken, or we cross compile.
28809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
28810 $as_echo_n "checking whether we are cross compiling... " >&6; }
28811 if test "$cross_compiling" != yes; then
28812   { { ac_try="$ac_link"
28813 case "(($ac_try" in
28814   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28815   *) ac_try_echo=$ac_try;;
28816 esac
28817 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28818 $as_echo "$ac_try_echo"; } >&5
28819   (eval "$ac_link") 2>&5
28820   ac_status=$?
28821   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28822   test $ac_status = 0; }
28823   if { ac_try='./conftest$ac_cv_exeext'
28824   { { case "(($ac_try" in
28825   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28826   *) ac_try_echo=$ac_try;;
28827 esac
28828 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28829 $as_echo "$ac_try_echo"; } >&5
28830   (eval "$ac_try") 2>&5
28831   ac_status=$?
28832   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28833   test $ac_status = 0; }; }; then
28834     cross_compiling=no
28835   else
28836     if test "$cross_compiling" = maybe; then
28837         cross_compiling=yes
28838     else
28839         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28840 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28841 as_fn_error $? "cannot run C compiled programs.
28842 If you meant to cross compile, use \`--host'.
28843 See \`config.log' for more details" "$LINENO" 5; }
28844     fi
28845   fi
28846 fi
28847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
28848 $as_echo "$cross_compiling" >&6; }
28849 
28850 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
28851 ac_clean_files=$ac_clean_files_save
28852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
28853 $as_echo_n "checking for suffix of object files... " >&6; }
28854 if ${ac_cv_objext+:} false; then :
28855   $as_echo_n "(cached) " >&6
28856 else
28857   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28858 /* end confdefs.h.  */
28859 
28860 int
28861 main ()
28862 {
28863 
28864   ;
28865   return 0;
28866 }
28867 _ACEOF
28868 rm -f conftest.o conftest.obj
28869 if { { ac_try="$ac_compile"
28870 case "(($ac_try" in
28871   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28872   *) ac_try_echo=$ac_try;;
28873 esac
28874 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28875 $as_echo "$ac_try_echo"; } >&5
28876   (eval "$ac_compile") 2>&5
28877   ac_status=$?
28878   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28879   test $ac_status = 0; }; then :
28880   for ac_file in conftest.o conftest.obj conftest.*; do
28881   test -f "$ac_file" || continue;
28882   case $ac_file in
28883     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
28884     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
28885        break;;
28886   esac
28887 done
28888 else
28889   $as_echo "$as_me: failed program was:" >&5
28890 sed 's/^/| /' conftest.$ac_ext >&5
28891 
28892 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28893 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28894 as_fn_error $? "cannot compute suffix of object files: cannot compile
28895 See \`config.log' for more details" "$LINENO" 5; }
28896 fi
28897 rm -f conftest.$ac_cv_objext conftest.$ac_ext
28898 fi
28899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
28900 $as_echo "$ac_cv_objext" >&6; }
28901 OBJEXT=$ac_cv_objext
28902 ac_objext=$OBJEXT
28903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
28904 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
28905 if ${ac_cv_c_compiler_gnu+:} false; then :
28906   $as_echo_n "(cached) " >&6
28907 else
28908   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28909 /* end confdefs.h.  */
28910 
28911 int
28912 main ()
28913 {
28914 #ifndef __GNUC__
28915        choke me
28916 #endif
28917 
28918   ;
28919   return 0;
28920 }
28921 _ACEOF
28922 if ac_fn_c_try_compile "$LINENO"; then :
28923   ac_compiler_gnu=yes
28924 else
28925   ac_compiler_gnu=no
28926 fi
28927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28928 ac_cv_c_compiler_gnu=$ac_compiler_gnu
28929 
28930 fi
28931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
28932 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
28933 if test $ac_compiler_gnu = yes; then
28934   GCC=yes
28935 else
28936   GCC=
28937 fi
28938 ac_test_CFLAGS=${CFLAGS+set}
28939 ac_save_CFLAGS=$CFLAGS
28940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
28941 $as_echo_n "checking whether $CC accepts -g... " >&6; }
28942 if ${ac_cv_prog_cc_g+:} false; then :
28943   $as_echo_n "(cached) " >&6
28944 else
28945   ac_save_c_werror_flag=$ac_c_werror_flag
28946    ac_c_werror_flag=yes
28947    ac_cv_prog_cc_g=no
28948    CFLAGS="-g"
28949    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28950 /* end confdefs.h.  */
28951 
28952 int
28953 main ()
28954 {
28955 
28956   ;
28957   return 0;
28958 }
28959 _ACEOF
28960 if ac_fn_c_try_compile "$LINENO"; then :
28961   ac_cv_prog_cc_g=yes
28962 else
28963   CFLAGS=""
28964       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28965 /* end confdefs.h.  */
28966 
28967 int
28968 main ()
28969 {
28970 
28971   ;
28972   return 0;
28973 }
28974 _ACEOF
28975 if ac_fn_c_try_compile "$LINENO"; then :
28976 
28977 else
28978   ac_c_werror_flag=$ac_save_c_werror_flag
28979          CFLAGS="-g"
28980          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28981 /* end confdefs.h.  */
28982 
28983 int
28984 main ()
28985 {
28986 
28987   ;
28988   return 0;
28989 }
28990 _ACEOF
28991 if ac_fn_c_try_compile "$LINENO"; then :
28992   ac_cv_prog_cc_g=yes
28993 fi
28994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28995 fi
28996 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28997 fi
28998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28999    ac_c_werror_flag=$ac_save_c_werror_flag
29000 fi
29001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
29002 $as_echo "$ac_cv_prog_cc_g" >&6; }
29003 if test "$ac_test_CFLAGS" = set; then
29004   CFLAGS=$ac_save_CFLAGS
29005 elif test $ac_cv_prog_cc_g = yes; then
29006   if test "$GCC" = yes; then
29007     CFLAGS="-g -O2"
29008   else
29009     CFLAGS="-g"
29010   fi
29011 else
29012   if test "$GCC" = yes; then
29013     CFLAGS="-O2"
29014   else
29015     CFLAGS=
29016   fi
29017 fi
29018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
29019 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
29020 if ${ac_cv_prog_cc_c89+:} false; then :
29021   $as_echo_n "(cached) " >&6
29022 else
29023   ac_cv_prog_cc_c89=no
29024 ac_save_CC=$CC
29025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29026 /* end confdefs.h.  */
29027 #include <stdarg.h>
29028 #include <stdio.h>
29029 struct stat;
29030 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
29031 struct buf { int x; };
29032 FILE * (*rcsopen) (struct buf *, struct stat *, int);
29033 static char *e (p, i)
29034      char **p;
29035      int i;
29036 {
29037   return p[i];
29038 }
29039 static char *f (char * (*g) (char **, int), char **p, ...)
29040 {
29041   char *s;
29042   va_list v;
29043   va_start (v,p);
29044   s = g (p, va_arg (v,int));
29045   va_end (v);
29046   return s;
29047 }
29048 
29049 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
29050    function prototypes and stuff, but not '\xHH' hex character constants.
29051    These don't provoke an error unfortunately, instead are silently treated
29052    as 'x'.  The following induces an error, until -std is added to get
29053    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
29054    array size at least.  It's necessary to write '\x00'==0 to get something
29055    that's true only with -std.  */
29056 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
29057 
29058 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
29059    inside strings and character constants.  */
29060 #define FOO(x) 'x'
29061 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
29062 
29063 int test (int i, double x);
29064 struct s1 {int (*f) (int a);};
29065 struct s2 {int (*f) (double a);};
29066 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
29067 int argc;
29068 char **argv;
29069 int
29070 main ()
29071 {
29072 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
29073   ;
29074   return 0;
29075 }
29076 _ACEOF
29077 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
29078         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
29079 do
29080   CC="$ac_save_CC $ac_arg"
29081   if ac_fn_c_try_compile "$LINENO"; then :
29082   ac_cv_prog_cc_c89=$ac_arg
29083 fi
29084 rm -f core conftest.err conftest.$ac_objext
29085   test "x$ac_cv_prog_cc_c89" != "xno" && break
29086 done
29087 rm -f conftest.$ac_ext
29088 CC=$ac_save_CC
29089 
29090 fi
29091 # AC_CACHE_VAL
29092 case "x$ac_cv_prog_cc_c89" in
29093   x)
29094     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
29095 $as_echo "none needed" >&6; } ;;
29096   xno)
29097     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
29098 $as_echo "unsupported" >&6; } ;;
29099   *)
29100     CC="$CC $ac_cv_prog_cc_c89"
29101     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
29102 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
29103 esac
29104 if test "x$ac_cv_prog_cc_c89" != xno; then :
29105 
29106 fi
29107 
29108 ac_ext=cpp
29109 ac_cpp='$CXXCPP $CPPFLAGS'
29110 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29111 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29112 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29113 
29114 
29115 
29116   COMPILER_NAME=C++
29117   SEARCH_LIST="$TOOLCHAIN_CXX_BINARY"
29118 
29119   if test "x$CXX" != x; then
29120     # User has supplied compiler name already, always let that override.
29121     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
29122 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
29123     if test "x`basename $CXX`" = "x$CXX"; then
29124       # A command without a complete path is provided, search $PATH.
29125 
29126       for ac_prog in $CXX
29127 do
29128   # Extract the first word of "$ac_prog", so it can be a program name with args.
29129 set dummy $ac_prog; ac_word=$2
29130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29131 $as_echo_n "checking for $ac_word... " >&6; }
29132 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29133   $as_echo_n "(cached) " >&6
29134 else
29135   case $POTENTIAL_CXX in
29136   [\\/]* | ?:[\\/]*)
29137   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29138   ;;
29139   *)
29140   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29141 for as_dir in $PATH
29142 do
29143   IFS=$as_save_IFS
29144   test -z "$as_dir" && as_dir=.
29145     for ac_exec_ext in '' $ac_executable_extensions; do
29146   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29147     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29148     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29149     break 2
29150   fi
29151 done
29152   done
29153 IFS=$as_save_IFS
29154 
29155   ;;
29156 esac
29157 fi
29158 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29159 if test -n "$POTENTIAL_CXX"; then
29160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29161 $as_echo "$POTENTIAL_CXX" >&6; }
29162 else
29163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29164 $as_echo "no" >&6; }
29165 fi
29166 
29167 
29168   test -n "$POTENTIAL_CXX" && break
29169 done
29170 
29171       if test "x$POTENTIAL_CXX" != x; then
29172         CXX=$POTENTIAL_CXX
29173       else
29174         as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29175       fi
29176     else
29177       # Otherwise it might already be a complete path
29178       if test ! -x "$CXX"; then
29179         as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29180       fi
29181     fi
29182   else
29183     # No user supplied value. Locate compiler ourselves.
29184 
29185     # If we are cross compiling, assume cross compilation tools follows the
29186     # cross compilation standard where they are prefixed with the autoconf
29187     # standard name for the target. For example the binary
29188     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29189     # If we are not cross compiling, then the default compiler name will be
29190     # used.
29191 
29192     CXX=
29193     # If TOOLS_DIR is set, check for all compiler names in there first
29194     # before checking the rest of the PATH.
29195     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29196     # step, this should not be necessary.
29197     if test -n "$TOOLS_DIR"; then
29198       PATH_save="$PATH"
29199       PATH="$TOOLS_DIR"
29200       for ac_prog in $SEARCH_LIST
29201 do
29202   # Extract the first word of "$ac_prog", so it can be a program name with args.
29203 set dummy $ac_prog; ac_word=$2
29204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29205 $as_echo_n "checking for $ac_word... " >&6; }
29206 if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then :
29207   $as_echo_n "(cached) " >&6
29208 else
29209   case $TOOLS_DIR_CXX in
29210   [\\/]* | ?:[\\/]*)
29211   ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path.
29212   ;;
29213   *)
29214   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29215 for as_dir in $PATH
29216 do
29217   IFS=$as_save_IFS
29218   test -z "$as_dir" && as_dir=.
29219     for ac_exec_ext in '' $ac_executable_extensions; do
29220   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29221     ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext"
29222     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29223     break 2
29224   fi
29225 done
29226   done
29227 IFS=$as_save_IFS
29228 
29229   ;;
29230 esac
29231 fi
29232 TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX
29233 if test -n "$TOOLS_DIR_CXX"; then
29234   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5
29235 $as_echo "$TOOLS_DIR_CXX" >&6; }
29236 else
29237   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29238 $as_echo "no" >&6; }
29239 fi
29240 
29241 
29242   test -n "$TOOLS_DIR_CXX" && break
29243 done
29244 
29245       CXX=$TOOLS_DIR_CXX
29246       PATH="$PATH_save"
29247     fi
29248 
29249     # AC_PATH_PROGS can't be run multiple times with the same variable,
29250     # so create a new name for this run.
29251     if test "x$CXX" = x; then
29252       for ac_prog in $SEARCH_LIST
29253 do
29254   # Extract the first word of "$ac_prog", so it can be a program name with args.
29255 set dummy $ac_prog; ac_word=$2
29256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29257 $as_echo_n "checking for $ac_word... " >&6; }
29258 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29259   $as_echo_n "(cached) " >&6
29260 else
29261   case $POTENTIAL_CXX in
29262   [\\/]* | ?:[\\/]*)
29263   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29264   ;;
29265   *)
29266   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29267 for as_dir in $PATH
29268 do
29269   IFS=$as_save_IFS
29270   test -z "$as_dir" && as_dir=.
29271     for ac_exec_ext in '' $ac_executable_extensions; do
29272   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29273     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29274     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29275     break 2
29276   fi
29277 done
29278   done
29279 IFS=$as_save_IFS
29280 
29281   ;;
29282 esac
29283 fi
29284 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29285 if test -n "$POTENTIAL_CXX"; then
29286   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29287 $as_echo "$POTENTIAL_CXX" >&6; }
29288 else
29289   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29290 $as_echo "no" >&6; }
29291 fi
29292 
29293 
29294   test -n "$POTENTIAL_CXX" && break
29295 done
29296 
29297       CXX=$POTENTIAL_CXX
29298     fi
29299 
29300     if test "x$CXX" = x; then
29301 
29302   # Print a helpful message on how to acquire the necessary build dependency.
29303   # devkit is the help tag: freetype, cups, pulse, alsa etc
29304   MISSING_DEPENDENCY=devkit
29305 
29306   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29307     cygwin_help $MISSING_DEPENDENCY
29308   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29309     msys_help $MISSING_DEPENDENCY
29310   else
29311     PKGHANDLER_COMMAND=
29312 
29313     case $PKGHANDLER in
29314       apt-get)
29315         apt_help     $MISSING_DEPENDENCY ;;
29316       yum)
29317         yum_help     $MISSING_DEPENDENCY ;;
29318       port)
29319         port_help    $MISSING_DEPENDENCY ;;
29320       pkgutil)
29321         pkgutil_help $MISSING_DEPENDENCY ;;
29322       pkgadd)
29323         pkgadd_help  $MISSING_DEPENDENCY ;;
29324     esac
29325 
29326     if test "x$PKGHANDLER_COMMAND" != x; then
29327       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29328     fi
29329   fi
29330 
29331       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29332     fi
29333   fi
29334 
29335   # Now we have a compiler binary in CXX. Make sure it's okay.
29336 
29337   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29338 
29339   # First separate the path from the arguments. This will split at the first
29340   # space.
29341   complete="$CXX"
29342   path="${complete%% *}"
29343   tmp="$complete EOL"
29344   arguments="${tmp#* }"
29345 
29346   # Input might be given as Windows format, start by converting to
29347   # unix format.
29348   new_path=`$CYGPATH -u "$path"`
29349 
29350   # Now try to locate executable using which
29351   new_path=`$WHICH "$new_path" 2> /dev/null`
29352   # bat and cmd files are not always considered executable in cygwin causing which
29353   # to not find them
29354   if test "x$new_path" = x \
29355       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29356       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29357     new_path=`$CYGPATH -u "$path"`
29358   fi
29359   if test "x$new_path" = x; then
29360     # Oops. Which didn't find the executable.
29361     # The splitting of arguments from the executable at a space might have been incorrect,
29362     # since paths with space are more likely in Windows. Give it another try with the whole
29363     # argument.
29364     path="$complete"
29365     arguments="EOL"
29366     new_path=`$CYGPATH -u "$path"`
29367     new_path=`$WHICH "$new_path" 2> /dev/null`
29368     # bat and cmd files are not always considered executable in cygwin causing which
29369     # to not find them
29370     if test "x$new_path" = x \
29371         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29372         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29373       new_path=`$CYGPATH -u "$path"`
29374     fi
29375     if test "x$new_path" = x; then
29376       # It's still not found. Now this is an unrecoverable error.
29377       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29378 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29379       has_space=`$ECHO "$complete" | $GREP " "`
29380       if test "x$has_space" != x; then
29381         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29382 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29383       fi
29384       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29385     fi
29386   fi
29387 
29388   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29389   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29390   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29391   # "foo.exe" is OK but "foo" is an error.
29392   #
29393   # This test is therefore slightly more accurate than "test -f" to check for file presence.
29394   # It is also a way to make sure we got the proper file name for the real test later on.
29395   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29396   if test "x$test_shortpath" = x; then
29397     # Short path failed, file does not exist as specified.
29398     # Try adding .exe or .cmd
29399     if test -f "${new_path}.exe"; then
29400       input_to_shortpath="${new_path}.exe"
29401     elif test -f "${new_path}.cmd"; then
29402       input_to_shortpath="${new_path}.cmd"
29403     else
29404       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
29405 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
29406       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29407 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29408       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29409     fi
29410   else
29411     input_to_shortpath="$new_path"
29412   fi
29413 
29414   # Call helper function which possibly converts this using DOS-style short mode.
29415   # If so, the updated path is stored in $new_path.
29416   new_path="$input_to_shortpath"
29417 
29418   input_path="$input_to_shortpath"
29419   # Check if we need to convert this using DOS-style short mode. If the path
29420   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29421   # take no chances and rewrite it.
29422   # Note: m4 eats our [], so we need to use [ and ] instead.
29423   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29424   if test "x$has_forbidden_chars" != x; then
29425     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29426     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29427     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29428     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29429       # Going to short mode and back again did indeed matter. Since short mode is
29430       # case insensitive, let's make it lowercase to improve readability.
29431       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29432       # Now convert it back to Unix-stile (cygpath)
29433       input_path=`$CYGPATH -u "$shortmode_path"`
29434       new_path="$input_path"
29435     fi
29436   fi
29437 
29438   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29439   if test "x$test_cygdrive_prefix" = x; then
29440     # As a simple fix, exclude /usr/bin since it's not a real path.
29441     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29442       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29443       # a path prefixed by /cygdrive for fixpath to work.
29444       new_path="$CYGWIN_ROOT_PATH$input_path"
29445     fi
29446   fi
29447 
29448   # remove trailing .exe if any
29449   new_path="${new_path/%.exe/}"
29450 
29451   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29452 
29453   # First separate the path from the arguments. This will split at the first
29454   # space.
29455   complete="$CXX"
29456   path="${complete%% *}"
29457   tmp="$complete EOL"
29458   arguments="${tmp#* }"
29459 
29460   # Input might be given as Windows format, start by converting to
29461   # unix format.
29462   new_path="$path"
29463 
29464   windows_path="$new_path"
29465   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29466     unix_path=`$CYGPATH -u "$windows_path"`
29467     new_path="$unix_path"
29468   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29469     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29470     new_path="$unix_path"
29471   fi
29472 
29473 
29474   # Now try to locate executable using which
29475   new_path=`$WHICH "$new_path" 2> /dev/null`
29476 
29477   if test "x$new_path" = x; then
29478     # Oops. Which didn't find the executable.
29479     # The splitting of arguments from the executable at a space might have been incorrect,
29480     # since paths with space are more likely in Windows. Give it another try with the whole
29481     # argument.
29482     path="$complete"
29483     arguments="EOL"
29484     new_path="$path"
29485 
29486   windows_path="$new_path"
29487   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29488     unix_path=`$CYGPATH -u "$windows_path"`
29489     new_path="$unix_path"
29490   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29491     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29492     new_path="$unix_path"
29493   fi
29494 
29495 
29496     new_path=`$WHICH "$new_path" 2> /dev/null`
29497 
29498     if test "x$new_path" = x; then
29499       # It's still not found. Now this is an unrecoverable error.
29500       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29501 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29502       has_space=`$ECHO "$complete" | $GREP " "`
29503       if test "x$has_space" != x; then
29504         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29505 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29506       fi
29507       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29508     fi
29509   fi
29510 
29511   # Now new_path has a complete unix path to the binary
29512   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29513     # Keep paths in /bin as-is, but remove trailing .exe if any
29514     new_path="${new_path/%.exe/}"
29515     # Do not save /bin paths to all_fixpath_prefixes!
29516   else
29517     # Not in mixed or Windows style, start by that.
29518     new_path=`cmd //c echo $new_path`
29519 
29520   input_path="$new_path"
29521   # Check if we need to convert this using DOS-style short mode. If the path
29522   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29523   # take no chances and rewrite it.
29524   # Note: m4 eats our [], so we need to use [ and ] instead.
29525   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29526   if test "x$has_forbidden_chars" != x; then
29527     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29528     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29529   fi
29530 
29531     # Output is in $new_path
29532 
29533   windows_path="$new_path"
29534   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29535     unix_path=`$CYGPATH -u "$windows_path"`
29536     new_path="$unix_path"
29537   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29538     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29539     new_path="$unix_path"
29540   fi
29541 
29542     # remove trailing .exe if any
29543     new_path="${new_path/%.exe/}"
29544 
29545     # Save the first 10 bytes of this path to the storage, so fixpath can work.
29546     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29547   fi
29548 
29549   else
29550     # We're on a posix platform. Hooray! :)
29551     # First separate the path from the arguments. This will split at the first
29552     # space.
29553     complete="$CXX"
29554     path="${complete%% *}"
29555     tmp="$complete EOL"
29556     arguments="${tmp#* }"
29557 
29558     # Cannot rely on the command "which" here since it doesn't always work.
29559     is_absolute_path=`$ECHO "$path" | $GREP ^/`
29560     if test -z "$is_absolute_path"; then
29561       # Path to executable is not absolute. Find it.
29562       IFS_save="$IFS"
29563       IFS=:
29564       for p in $PATH; do
29565         if test -f "$p/$path" && test -x "$p/$path"; then
29566           new_path="$p/$path"
29567           break
29568         fi
29569       done
29570       IFS="$IFS_save"
29571     else
29572       # This is an absolute path, we can use it without further modifications.
29573       new_path="$path"
29574     fi
29575 
29576     if test "x$new_path" = x; then
29577       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29578 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29579       has_space=`$ECHO "$complete" | $GREP " "`
29580       if test "x$has_space" != x; then
29581         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29582 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29583       fi
29584       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29585     fi
29586   fi
29587 
29588   # Now join together the path and the arguments once again
29589   if test "x$arguments" != xEOL; then
29590     new_complete="$new_path ${arguments% *}"
29591   else
29592     new_complete="$new_path"
29593   fi
29594 
29595   if test "x$complete" != "x$new_complete"; then
29596     CXX="$new_complete"
29597     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
29598 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
29599   fi
29600 
29601   TEST_COMPILER="$CXX"
29602   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29603   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29604   if test "x$OPENJDK_BUILD_OS" != xaix; then
29605     # FIXME: This test should not be needed anymore; we don't do that for any platform.
29606     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
29607 $as_echo_n "checking resolved symbolic links for CXX... " >&6; }
29608 
29609   if test "x$OPENJDK_BUILD_OS" != xwindows; then
29610     # Follow a chain of symbolic links. Use readlink
29611     # where it exists, else fall back to horribly
29612     # complicated shell code.
29613     if test "x$READLINK_TESTED" != yes; then
29614       # On MacOSX there is a readlink tool with a different
29615       # purpose than the GNU readlink tool. Check the found readlink.
29616       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29617       if test "x$ISGNU" = x; then
29618         # A readlink that we do not know how to use.
29619         # Are there other non-GNU readlinks out there?
29620         READLINK_TESTED=yes
29621         READLINK=
29622       fi
29623     fi
29624 
29625     if test "x$READLINK" != x; then
29626       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29627     else
29628       # Save the current directory for restoring afterwards
29629       STARTDIR=$PWD
29630       COUNTER=0
29631       sym_link_dir=`$DIRNAME $TEST_COMPILER`
29632       sym_link_file=`$BASENAME $TEST_COMPILER`
29633       cd $sym_link_dir
29634       # Use -P flag to resolve symlinks in directories.
29635       cd `$THEPWDCMD -P`
29636       sym_link_dir=`$THEPWDCMD -P`
29637       # Resolve file symlinks
29638       while test $COUNTER -lt 20; do
29639         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
29640         if test "x$ISLINK" == x; then
29641           # This is not a symbolic link! We are done!
29642           break
29643         fi
29644         # Again resolve directory symlinks since the target of the just found
29645         # link could be in a different directory
29646         cd `$DIRNAME $ISLINK`
29647         sym_link_dir=`$THEPWDCMD -P`
29648         sym_link_file=`$BASENAME $ISLINK`
29649         let COUNTER=COUNTER+1
29650       done
29651       cd $STARTDIR
29652       TEST_COMPILER=$sym_link_dir/$sym_link_file
29653     fi
29654   fi
29655 
29656     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
29657 $as_echo "$TEST_COMPILER" >&6; }
29658   fi
29659   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
29660 $as_echo_n "checking if CXX is disguised ccache... " >&6; }
29661 
29662   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
29663   if test "x$COMPILER_BASENAME" = "xccache"; then
29664     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
29665 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
29666     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
29667     # We want to control ccache invocation ourselves, so ignore this cc and try
29668     # searching again.
29669 
29670     # Remove the path to the fake ccache cc from the PATH
29671     RETRY_COMPILER_SAVED_PATH="$PATH"
29672     COMPILER_DIRNAME=`$DIRNAME $CXX`
29673     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
29674 
29675     # Try again looking for our compiler
29676     if test -n "$ac_tool_prefix"; then
29677   for ac_prog in $TOOLCHAIN_CXX_BINARY
29678   do
29679     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
29680 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
29681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29682 $as_echo_n "checking for $ac_word... " >&6; }
29683 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
29684   $as_echo_n "(cached) " >&6
29685 else
29686   if test -n "$PROPER_COMPILER_CXX"; then
29687   ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
29688 else
29689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29690 for as_dir in $PATH
29691 do
29692   IFS=$as_save_IFS
29693   test -z "$as_dir" && as_dir=.
29694     for ac_exec_ext in '' $ac_executable_extensions; do
29695   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29696     ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
29697     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29698     break 2
29699   fi
29700 done
29701   done
29702 IFS=$as_save_IFS
29703 
29704 fi
29705 fi
29706 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
29707 if test -n "$PROPER_COMPILER_CXX"; then
29708   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
29709 $as_echo "$PROPER_COMPILER_CXX" >&6; }
29710 else
29711   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29712 $as_echo "no" >&6; }
29713 fi
29714 
29715 
29716     test -n "$PROPER_COMPILER_CXX" && break
29717   done
29718 fi
29719 if test -z "$PROPER_COMPILER_CXX"; then
29720   ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
29721   for ac_prog in $TOOLCHAIN_CXX_BINARY
29722 do
29723   # Extract the first word of "$ac_prog", so it can be a program name with args.
29724 set dummy $ac_prog; ac_word=$2
29725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29726 $as_echo_n "checking for $ac_word... " >&6; }
29727 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
29728   $as_echo_n "(cached) " >&6
29729 else
29730   if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29731   ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
29732 else
29733 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29734 for as_dir in $PATH
29735 do
29736   IFS=$as_save_IFS
29737   test -z "$as_dir" && as_dir=.
29738     for ac_exec_ext in '' $ac_executable_extensions; do
29739   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29740     ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
29741     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29742     break 2
29743   fi
29744 done
29745   done
29746 IFS=$as_save_IFS
29747 
29748 fi
29749 fi
29750 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
29751 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29752   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
29753 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
29754 else
29755   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29756 $as_echo "no" >&6; }
29757 fi
29758 
29759 
29760   test -n "$ac_ct_PROPER_COMPILER_CXX" && break
29761 done
29762 
29763   if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
29764     PROPER_COMPILER_CXX=""
29765   else
29766     case $cross_compiling:$ac_tool_warned in
29767 yes:)
29768 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
29769 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
29770 ac_tool_warned=yes ;;
29771 esac
29772     PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
29773   fi
29774 fi
29775 
29776 
29777   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29778 
29779   # First separate the path from the arguments. This will split at the first
29780   # space.
29781   complete="$PROPER_COMPILER_CXX"
29782   path="${complete%% *}"
29783   tmp="$complete EOL"
29784   arguments="${tmp#* }"
29785 
29786   # Input might be given as Windows format, start by converting to
29787   # unix format.
29788   new_path=`$CYGPATH -u "$path"`
29789 
29790   # Now try to locate executable using which
29791   new_path=`$WHICH "$new_path" 2> /dev/null`
29792   # bat and cmd files are not always considered executable in cygwin causing which
29793   # to not find them
29794   if test "x$new_path" = x \
29795       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29796       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29797     new_path=`$CYGPATH -u "$path"`
29798   fi
29799   if test "x$new_path" = x; then
29800     # Oops. Which didn't find the executable.
29801     # The splitting of arguments from the executable at a space might have been incorrect,
29802     # since paths with space are more likely in Windows. Give it another try with the whole
29803     # argument.
29804     path="$complete"
29805     arguments="EOL"
29806     new_path=`$CYGPATH -u "$path"`
29807     new_path=`$WHICH "$new_path" 2> /dev/null`
29808     # bat and cmd files are not always considered executable in cygwin causing which
29809     # to not find them
29810     if test "x$new_path" = x \
29811         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29812         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29813       new_path=`$CYGPATH -u "$path"`
29814     fi
29815     if test "x$new_path" = x; then
29816       # It's still not found. Now this is an unrecoverable error.
29817       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29818 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29819       has_space=`$ECHO "$complete" | $GREP " "`
29820       if test "x$has_space" != x; then
29821         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29822 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29823       fi
29824       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29825     fi
29826   fi
29827 
29828   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29829   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29830   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29831   # "foo.exe" is OK but "foo" is an error.
29832   #
29833   # This test is therefore slightly more accurate than "test -f" to check for file presence.
29834   # It is also a way to make sure we got the proper file name for the real test later on.
29835   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29836   if test "x$test_shortpath" = x; then
29837     # Short path failed, file does not exist as specified.
29838     # Try adding .exe or .cmd
29839     if test -f "${new_path}.exe"; then
29840       input_to_shortpath="${new_path}.exe"
29841     elif test -f "${new_path}.cmd"; then
29842       input_to_shortpath="${new_path}.cmd"
29843     else
29844       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
29845 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
29846       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29847 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29848       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29849     fi
29850   else
29851     input_to_shortpath="$new_path"
29852   fi
29853 
29854   # Call helper function which possibly converts this using DOS-style short mode.
29855   # If so, the updated path is stored in $new_path.
29856   new_path="$input_to_shortpath"
29857 
29858   input_path="$input_to_shortpath"
29859   # Check if we need to convert this using DOS-style short mode. If the path
29860   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29861   # take no chances and rewrite it.
29862   # Note: m4 eats our [], so we need to use [ and ] instead.
29863   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29864   if test "x$has_forbidden_chars" != x; then
29865     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29866     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29867     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29868     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29869       # Going to short mode and back again did indeed matter. Since short mode is
29870       # case insensitive, let's make it lowercase to improve readability.
29871       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29872       # Now convert it back to Unix-stile (cygpath)
29873       input_path=`$CYGPATH -u "$shortmode_path"`
29874       new_path="$input_path"
29875     fi
29876   fi
29877 
29878   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29879   if test "x$test_cygdrive_prefix" = x; then
29880     # As a simple fix, exclude /usr/bin since it's not a real path.
29881     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29882       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29883       # a path prefixed by /cygdrive for fixpath to work.
29884       new_path="$CYGWIN_ROOT_PATH$input_path"
29885     fi
29886   fi
29887 
29888   # remove trailing .exe if any
29889   new_path="${new_path/%.exe/}"
29890 
29891   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29892 
29893   # First separate the path from the arguments. This will split at the first
29894   # space.
29895   complete="$PROPER_COMPILER_CXX"
29896   path="${complete%% *}"
29897   tmp="$complete EOL"
29898   arguments="${tmp#* }"
29899 
29900   # Input might be given as Windows format, start by converting to
29901   # unix format.
29902   new_path="$path"
29903 
29904   windows_path="$new_path"
29905   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29906     unix_path=`$CYGPATH -u "$windows_path"`
29907     new_path="$unix_path"
29908   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29909     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29910     new_path="$unix_path"
29911   fi
29912 
29913 
29914   # Now try to locate executable using which
29915   new_path=`$WHICH "$new_path" 2> /dev/null`
29916 
29917   if test "x$new_path" = x; then
29918     # Oops. Which didn't find the executable.
29919     # The splitting of arguments from the executable at a space might have been incorrect,
29920     # since paths with space are more likely in Windows. Give it another try with the whole
29921     # argument.
29922     path="$complete"
29923     arguments="EOL"
29924     new_path="$path"
29925 
29926   windows_path="$new_path"
29927   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29928     unix_path=`$CYGPATH -u "$windows_path"`
29929     new_path="$unix_path"
29930   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29931     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29932     new_path="$unix_path"
29933   fi
29934 
29935 
29936     new_path=`$WHICH "$new_path" 2> /dev/null`
29937 
29938     if test "x$new_path" = x; then
29939       # It's still not found. Now this is an unrecoverable error.
29940       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29941 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29942       has_space=`$ECHO "$complete" | $GREP " "`
29943       if test "x$has_space" != x; then
29944         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29945 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29946       fi
29947       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29948     fi
29949   fi
29950 
29951   # Now new_path has a complete unix path to the binary
29952   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29953     # Keep paths in /bin as-is, but remove trailing .exe if any
29954     new_path="${new_path/%.exe/}"
29955     # Do not save /bin paths to all_fixpath_prefixes!
29956   else
29957     # Not in mixed or Windows style, start by that.
29958     new_path=`cmd //c echo $new_path`
29959 
29960   input_path="$new_path"
29961   # Check if we need to convert this using DOS-style short mode. If the path
29962   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29963   # take no chances and rewrite it.
29964   # Note: m4 eats our [], so we need to use [ and ] instead.
29965   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29966   if test "x$has_forbidden_chars" != x; then
29967     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29968     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29969   fi
29970 
29971     # Output is in $new_path
29972 
29973   windows_path="$new_path"
29974   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29975     unix_path=`$CYGPATH -u "$windows_path"`
29976     new_path="$unix_path"
29977   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29978     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29979     new_path="$unix_path"
29980   fi
29981 
29982     # remove trailing .exe if any
29983     new_path="${new_path/%.exe/}"
29984 
29985     # Save the first 10 bytes of this path to the storage, so fixpath can work.
29986     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29987   fi
29988 
29989   else
29990     # We're on a posix platform. Hooray! :)
29991     # First separate the path from the arguments. This will split at the first
29992     # space.
29993     complete="$PROPER_COMPILER_CXX"
29994     path="${complete%% *}"
29995     tmp="$complete EOL"
29996     arguments="${tmp#* }"
29997 
29998     # Cannot rely on the command "which" here since it doesn't always work.
29999     is_absolute_path=`$ECHO "$path" | $GREP ^/`
30000     if test -z "$is_absolute_path"; then
30001       # Path to executable is not absolute. Find it.
30002       IFS_save="$IFS"
30003       IFS=:
30004       for p in $PATH; do
30005         if test -f "$p/$path" && test -x "$p/$path"; then
30006           new_path="$p/$path"
30007           break
30008         fi
30009       done
30010       IFS="$IFS_save"
30011     else
30012       # This is an absolute path, we can use it without further modifications.
30013       new_path="$path"
30014     fi
30015 
30016     if test "x$new_path" = x; then
30017       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30018 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30019       has_space=`$ECHO "$complete" | $GREP " "`
30020       if test "x$has_space" != x; then
30021         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30022 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30023       fi
30024       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30025     fi
30026   fi
30027 
30028   # Now join together the path and the arguments once again
30029   if test "x$arguments" != xEOL; then
30030     new_complete="$new_path ${arguments% *}"
30031   else
30032     new_complete="$new_path"
30033   fi
30034 
30035   if test "x$complete" != "x$new_complete"; then
30036     PROPER_COMPILER_CXX="$new_complete"
30037     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
30038 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
30039   fi
30040 
30041     PATH="$RETRY_COMPILER_SAVED_PATH"
30042 
30043     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
30044 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
30045 
30046   if test "x$OPENJDK_BUILD_OS" != xwindows; then
30047     # Follow a chain of symbolic links. Use readlink
30048     # where it exists, else fall back to horribly
30049     # complicated shell code.
30050     if test "x$READLINK_TESTED" != yes; then
30051       # On MacOSX there is a readlink tool with a different
30052       # purpose than the GNU readlink tool. Check the found readlink.
30053       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30054       if test "x$ISGNU" = x; then
30055         # A readlink that we do not know how to use.
30056         # Are there other non-GNU readlinks out there?
30057         READLINK_TESTED=yes
30058         READLINK=
30059       fi
30060     fi
30061 
30062     if test "x$READLINK" != x; then
30063       PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
30064     else
30065       # Save the current directory for restoring afterwards
30066       STARTDIR=$PWD
30067       COUNTER=0
30068       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
30069       sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
30070       cd $sym_link_dir
30071       # Use -P flag to resolve symlinks in directories.
30072       cd `$THEPWDCMD -P`
30073       sym_link_dir=`$THEPWDCMD -P`
30074       # Resolve file symlinks
30075       while test $COUNTER -lt 20; do
30076         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30077         if test "x$ISLINK" == x; then
30078           # This is not a symbolic link! We are done!
30079           break
30080         fi
30081         # Again resolve directory symlinks since the target of the just found
30082         # link could be in a different directory
30083         cd `$DIRNAME $ISLINK`
30084         sym_link_dir=`$THEPWDCMD -P`
30085         sym_link_file=`$BASENAME $ISLINK`
30086         let COUNTER=COUNTER+1
30087       done
30088       cd $STARTDIR
30089       PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
30090     fi
30091   fi
30092 
30093     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30094 $as_echo "$PROPER_COMPILER_CXX" >&6; }
30095     CXX="$PROPER_COMPILER_CXX"
30096   else
30097     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
30098 $as_echo "no, keeping CXX" >&6; }
30099   fi
30100 
30101 
30102   COMPILER=$CXX
30103   COMPILER_NAME=$COMPILER_NAME
30104 
30105   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
30106     # cc -V output typically looks like
30107     #     cc: Sun C 5.12 Linux_i386 2011/11/16
30108     COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
30109     # Check that this is likely to be the Solaris Studio cc.
30110     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30111     if test $? -ne 0; then
30112       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30113       { $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
30114 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30115       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30116 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30117       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30118 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30119       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30120     fi
30121     # Remove usage instructions (if present), and
30122     # collapse compiler output into a single line
30123     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30124         $SED -e 's/ *[Uu]sage:.*//'`
30125     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30126         $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
30127   elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
30128     # xlc -qversion output typically looks like
30129     #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
30130     #     Version: 11.01.0000.0015
30131     COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
30132     # Check that this is likely to be the IBM XL C compiler.
30133     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
30134     if test $? -ne 0; then
30135       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30136       { $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
30137 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30138       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30139 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30140       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30141 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30142       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30143     fi
30144     # Collapse compiler output into a single line
30145     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30146     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30147         $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
30148   elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
30149     # There is no specific version flag, but all output starts with a version string.
30150     # First line typically looks something like:
30151     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30152     COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30153     # Check that this is likely to be Microsoft CL.EXE.
30154     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
30155     if test $? -ne 0; then
30156       { $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
30157 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30158       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30159 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30160       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30161     fi
30162     # Collapse compiler output into a single line
30163     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30164     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30165         $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
30166   elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
30167     # gcc --version output typically looks like
30168     #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
30169     #     Copyright (C) 2013 Free Software Foundation, Inc.
30170     #     This is free software; see the source for copying conditions.  There is NO
30171     #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30172     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30173     # Check that this is likely to be GCC.
30174     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
30175     if test $? -ne 0; then
30176       { $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
30177 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30178       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
30179 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
30180       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30181     fi
30182     # Remove Copyright and legalese from version string, and
30183     # collapse into a single line
30184     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30185         $SED -e 's/ *Copyright .*//'`
30186     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30187         $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
30188   elif test  "x$TOOLCHAIN_TYPE" = xclang; then
30189     # clang --version output typically looks like
30190     #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
30191     #    clang version 3.3 (tags/RELEASE_33/final)
30192     # or
30193     #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
30194     #    Target: x86_64-pc-linux-gnu
30195     #    Thread model: posix
30196     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30197     # Check that this is likely to be clang
30198     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
30199     if test $? -ne 0; then
30200       { $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
30201 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30202       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30203 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30204       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30205     fi
30206     # Collapse compiler output into a single line
30207     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30208     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30209         $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
30210   else
30211       as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
30212   fi
30213   # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
30214   CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
30215   # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
30216   CXX_VERSION_STRING="$COMPILER_VERSION_STRING"
30217 
30218   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
30219 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
30220 
30221 
30222   # Now that we have resolved CXX ourself, let autoconf have its go at it
30223   ac_ext=cpp
30224 ac_cpp='$CXXCPP $CPPFLAGS'
30225 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30226 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30227 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30228 if test -z "$CXX"; then
30229   if test -n "$CCC"; then
30230     CXX=$CCC
30231   else
30232     if test -n "$ac_tool_prefix"; then
30233   for ac_prog in $CXX
30234   do
30235     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30236 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30238 $as_echo_n "checking for $ac_word... " >&6; }
30239 if ${ac_cv_prog_CXX+:} false; then :
30240   $as_echo_n "(cached) " >&6
30241 else
30242   if test -n "$CXX"; then
30243   ac_cv_prog_CXX="$CXX" # Let the user override the test.
30244 else
30245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30246 for as_dir in $PATH
30247 do
30248   IFS=$as_save_IFS
30249   test -z "$as_dir" && as_dir=.
30250     for ac_exec_ext in '' $ac_executable_extensions; do
30251   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30252     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
30253     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30254     break 2
30255   fi
30256 done
30257   done
30258 IFS=$as_save_IFS
30259 
30260 fi
30261 fi
30262 CXX=$ac_cv_prog_CXX
30263 if test -n "$CXX"; then
30264   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
30265 $as_echo "$CXX" >&6; }
30266 else
30267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30268 $as_echo "no" >&6; }
30269 fi
30270 
30271 
30272     test -n "$CXX" && break
30273   done
30274 fi
30275 if test -z "$CXX"; then
30276   ac_ct_CXX=$CXX
30277   for ac_prog in $CXX
30278 do
30279   # Extract the first word of "$ac_prog", so it can be a program name with args.
30280 set dummy $ac_prog; ac_word=$2
30281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30282 $as_echo_n "checking for $ac_word... " >&6; }
30283 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
30284   $as_echo_n "(cached) " >&6
30285 else
30286   if test -n "$ac_ct_CXX"; then
30287   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
30288 else
30289 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30290 for as_dir in $PATH
30291 do
30292   IFS=$as_save_IFS
30293   test -z "$as_dir" && as_dir=.
30294     for ac_exec_ext in '' $ac_executable_extensions; do
30295   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30296     ac_cv_prog_ac_ct_CXX="$ac_prog"
30297     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30298     break 2
30299   fi
30300 done
30301   done
30302 IFS=$as_save_IFS
30303 
30304 fi
30305 fi
30306 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
30307 if test -n "$ac_ct_CXX"; then
30308   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
30309 $as_echo "$ac_ct_CXX" >&6; }
30310 else
30311   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30312 $as_echo "no" >&6; }
30313 fi
30314 
30315 
30316   test -n "$ac_ct_CXX" && break
30317 done
30318 
30319   if test "x$ac_ct_CXX" = x; then
30320     CXX="g++"
30321   else
30322     case $cross_compiling:$ac_tool_warned in
30323 yes:)
30324 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30325 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30326 ac_tool_warned=yes ;;
30327 esac
30328     CXX=$ac_ct_CXX
30329   fi
30330 fi
30331 
30332   fi
30333 fi
30334 # Provide some information about the compiler.
30335 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
30336 set X $ac_compile
30337 ac_compiler=$2
30338 for ac_option in --version -v -V -qversion; do
30339   { { ac_try="$ac_compiler $ac_option >&5"
30340 case "(($ac_try" in
30341   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30342   *) ac_try_echo=$ac_try;;
30343 esac
30344 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30345 $as_echo "$ac_try_echo"; } >&5
30346   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30347   ac_status=$?
30348   if test -s conftest.err; then
30349     sed '10a\
30350 ... rest of stderr output deleted ...
30351          10q' conftest.err >conftest.er1
30352     cat conftest.er1 >&5
30353   fi
30354   rm -f conftest.er1 conftest.err
30355   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30356   test $ac_status = 0; }
30357 done
30358 
30359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
30360 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
30361 if ${ac_cv_cxx_compiler_gnu+:} false; then :
30362   $as_echo_n "(cached) " >&6
30363 else
30364   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30365 /* end confdefs.h.  */
30366 
30367 int
30368 main ()
30369 {
30370 #ifndef __GNUC__
30371        choke me
30372 #endif
30373 
30374   ;
30375   return 0;
30376 }
30377 _ACEOF
30378 if ac_fn_cxx_try_compile "$LINENO"; then :
30379   ac_compiler_gnu=yes
30380 else
30381   ac_compiler_gnu=no
30382 fi
30383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30384 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
30385 
30386 fi
30387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
30388 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
30389 if test $ac_compiler_gnu = yes; then
30390   GXX=yes
30391 else
30392   GXX=
30393 fi
30394 ac_test_CXXFLAGS=${CXXFLAGS+set}
30395 ac_save_CXXFLAGS=$CXXFLAGS
30396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
30397 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
30398 if ${ac_cv_prog_cxx_g+:} false; then :
30399   $as_echo_n "(cached) " >&6
30400 else
30401   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
30402    ac_cxx_werror_flag=yes
30403    ac_cv_prog_cxx_g=no
30404    CXXFLAGS="-g"
30405    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30406 /* end confdefs.h.  */
30407 
30408 int
30409 main ()
30410 {
30411 
30412   ;
30413   return 0;
30414 }
30415 _ACEOF
30416 if ac_fn_cxx_try_compile "$LINENO"; then :
30417   ac_cv_prog_cxx_g=yes
30418 else
30419   CXXFLAGS=""
30420       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30421 /* end confdefs.h.  */
30422 
30423 int
30424 main ()
30425 {
30426 
30427   ;
30428   return 0;
30429 }
30430 _ACEOF
30431 if ac_fn_cxx_try_compile "$LINENO"; then :
30432 
30433 else
30434   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30435          CXXFLAGS="-g"
30436          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30437 /* end confdefs.h.  */
30438 
30439 int
30440 main ()
30441 {
30442 
30443   ;
30444   return 0;
30445 }
30446 _ACEOF
30447 if ac_fn_cxx_try_compile "$LINENO"; then :
30448   ac_cv_prog_cxx_g=yes
30449 fi
30450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30451 fi
30452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30453 fi
30454 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30455    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30456 fi
30457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
30458 $as_echo "$ac_cv_prog_cxx_g" >&6; }
30459 if test "$ac_test_CXXFLAGS" = set; then
30460   CXXFLAGS=$ac_save_CXXFLAGS
30461 elif test $ac_cv_prog_cxx_g = yes; then
30462   if test "$GXX" = yes; then
30463     CXXFLAGS="-g -O2"
30464   else
30465     CXXFLAGS="-g"
30466   fi
30467 else
30468   if test "$GXX" = yes; then
30469     CXXFLAGS="-O2"
30470   else
30471     CXXFLAGS=
30472   fi
30473 fi
30474 ac_ext=cpp
30475 ac_cpp='$CXXCPP $CPPFLAGS'
30476 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30477 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30478 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30479 
30480 
30481   #
30482   # Setup the preprocessor (CPP and CXXCPP)
30483   #
30484   ac_ext=c
30485 ac_cpp='$CPP $CPPFLAGS'
30486 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30487 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30488 ac_compiler_gnu=$ac_cv_c_compiler_gnu
30489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
30490 $as_echo_n "checking how to run the C preprocessor... " >&6; }
30491 # On Suns, sometimes $CPP names a directory.
30492 if test -n "$CPP" && test -d "$CPP"; then
30493   CPP=
30494 fi
30495 if test -z "$CPP"; then
30496   if ${ac_cv_prog_CPP+:} false; then :
30497   $as_echo_n "(cached) " >&6
30498 else
30499       # Double quotes because CPP needs to be expanded
30500     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
30501     do
30502       ac_preproc_ok=false
30503 for ac_c_preproc_warn_flag in '' yes
30504 do
30505   # Use a header file that comes with gcc, so configuring glibc
30506   # with a fresh cross-compiler works.
30507   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30508   # <limits.h> exists even on freestanding compilers.
30509   # On the NeXT, cc -E runs the code through the compiler's parser,
30510   # not just through cpp. "Syntax error" is here to catch this case.
30511   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30512 /* end confdefs.h.  */
30513 #ifdef __STDC__
30514 # include <limits.h>
30515 #else
30516 # include <assert.h>
30517 #endif
30518                      Syntax error
30519 _ACEOF
30520 if ac_fn_c_try_cpp "$LINENO"; then :
30521 
30522 else
30523   # Broken: fails on valid input.
30524 continue
30525 fi
30526 rm -f conftest.err conftest.i conftest.$ac_ext
30527 
30528   # OK, works on sane cases.  Now check whether nonexistent headers
30529   # can be detected and how.
30530   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30531 /* end confdefs.h.  */
30532 #include <ac_nonexistent.h>
30533 _ACEOF
30534 if ac_fn_c_try_cpp "$LINENO"; then :
30535   # Broken: success on invalid input.
30536 continue
30537 else
30538   # Passes both tests.
30539 ac_preproc_ok=:
30540 break
30541 fi
30542 rm -f conftest.err conftest.i conftest.$ac_ext
30543 
30544 done
30545 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30546 rm -f conftest.i conftest.err conftest.$ac_ext
30547 if $ac_preproc_ok; then :
30548   break
30549 fi
30550 
30551     done
30552     ac_cv_prog_CPP=$CPP
30553 
30554 fi
30555   CPP=$ac_cv_prog_CPP
30556 else
30557   ac_cv_prog_CPP=$CPP
30558 fi
30559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
30560 $as_echo "$CPP" >&6; }
30561 ac_preproc_ok=false
30562 for ac_c_preproc_warn_flag in '' yes
30563 do
30564   # Use a header file that comes with gcc, so configuring glibc
30565   # with a fresh cross-compiler works.
30566   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30567   # <limits.h> exists even on freestanding compilers.
30568   # On the NeXT, cc -E runs the code through the compiler's parser,
30569   # not just through cpp. "Syntax error" is here to catch this case.
30570   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30571 /* end confdefs.h.  */
30572 #ifdef __STDC__
30573 # include <limits.h>
30574 #else
30575 # include <assert.h>
30576 #endif
30577                      Syntax error
30578 _ACEOF
30579 if ac_fn_c_try_cpp "$LINENO"; then :
30580 
30581 else
30582   # Broken: fails on valid input.
30583 continue
30584 fi
30585 rm -f conftest.err conftest.i conftest.$ac_ext
30586 
30587   # OK, works on sane cases.  Now check whether nonexistent headers
30588   # can be detected and how.
30589   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30590 /* end confdefs.h.  */
30591 #include <ac_nonexistent.h>
30592 _ACEOF
30593 if ac_fn_c_try_cpp "$LINENO"; then :
30594   # Broken: success on invalid input.
30595 continue
30596 else
30597   # Passes both tests.
30598 ac_preproc_ok=:
30599 break
30600 fi
30601 rm -f conftest.err conftest.i conftest.$ac_ext
30602 
30603 done
30604 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30605 rm -f conftest.i conftest.err conftest.$ac_ext
30606 if $ac_preproc_ok; then :
30607 
30608 else
30609   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30610 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30611 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
30612 See \`config.log' for more details" "$LINENO" 5; }
30613 fi
30614 
30615 ac_ext=cpp
30616 ac_cpp='$CXXCPP $CPPFLAGS'
30617 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30618 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30619 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30620 
30621 
30622   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30623 
30624   # First separate the path from the arguments. This will split at the first
30625   # space.
30626   complete="$CPP"
30627   path="${complete%% *}"
30628   tmp="$complete EOL"
30629   arguments="${tmp#* }"
30630 
30631   # Input might be given as Windows format, start by converting to
30632   # unix format.
30633   new_path=`$CYGPATH -u "$path"`
30634 
30635   # Now try to locate executable using which
30636   new_path=`$WHICH "$new_path" 2> /dev/null`
30637   # bat and cmd files are not always considered executable in cygwin causing which
30638   # to not find them
30639   if test "x$new_path" = x \
30640       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30641       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30642     new_path=`$CYGPATH -u "$path"`
30643   fi
30644   if test "x$new_path" = x; then
30645     # Oops. Which didn't find the executable.
30646     # The splitting of arguments from the executable at a space might have been incorrect,
30647     # since paths with space are more likely in Windows. Give it another try with the whole
30648     # argument.
30649     path="$complete"
30650     arguments="EOL"
30651     new_path=`$CYGPATH -u "$path"`
30652     new_path=`$WHICH "$new_path" 2> /dev/null`
30653     # bat and cmd files are not always considered executable in cygwin causing which
30654     # to not find them
30655     if test "x$new_path" = x \
30656         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30657         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30658       new_path=`$CYGPATH -u "$path"`
30659     fi
30660     if test "x$new_path" = x; then
30661       # It's still not found. Now this is an unrecoverable error.
30662       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30663 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30664       has_space=`$ECHO "$complete" | $GREP " "`
30665       if test "x$has_space" != x; then
30666         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30667 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30668       fi
30669       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30670     fi
30671   fi
30672 
30673   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30674   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30675   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30676   # "foo.exe" is OK but "foo" is an error.
30677   #
30678   # This test is therefore slightly more accurate than "test -f" to check for file presence.
30679   # It is also a way to make sure we got the proper file name for the real test later on.
30680   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30681   if test "x$test_shortpath" = x; then
30682     # Short path failed, file does not exist as specified.
30683     # Try adding .exe or .cmd
30684     if test -f "${new_path}.exe"; then
30685       input_to_shortpath="${new_path}.exe"
30686     elif test -f "${new_path}.cmd"; then
30687       input_to_shortpath="${new_path}.cmd"
30688     else
30689       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
30690 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
30691       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30692 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30693       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30694     fi
30695   else
30696     input_to_shortpath="$new_path"
30697   fi
30698 
30699   # Call helper function which possibly converts this using DOS-style short mode.
30700   # If so, the updated path is stored in $new_path.
30701   new_path="$input_to_shortpath"
30702 
30703   input_path="$input_to_shortpath"
30704   # Check if we need to convert this using DOS-style short mode. If the path
30705   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30706   # take no chances and rewrite it.
30707   # Note: m4 eats our [], so we need to use [ and ] instead.
30708   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30709   if test "x$has_forbidden_chars" != x; then
30710     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30711     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30712     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30713     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30714       # Going to short mode and back again did indeed matter. Since short mode is
30715       # case insensitive, let's make it lowercase to improve readability.
30716       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30717       # Now convert it back to Unix-stile (cygpath)
30718       input_path=`$CYGPATH -u "$shortmode_path"`
30719       new_path="$input_path"
30720     fi
30721   fi
30722 
30723   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30724   if test "x$test_cygdrive_prefix" = x; then
30725     # As a simple fix, exclude /usr/bin since it's not a real path.
30726     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30727       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30728       # a path prefixed by /cygdrive for fixpath to work.
30729       new_path="$CYGWIN_ROOT_PATH$input_path"
30730     fi
30731   fi
30732 
30733   # remove trailing .exe if any
30734   new_path="${new_path/%.exe/}"
30735 
30736   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30737 
30738   # First separate the path from the arguments. This will split at the first
30739   # space.
30740   complete="$CPP"
30741   path="${complete%% *}"
30742   tmp="$complete EOL"
30743   arguments="${tmp#* }"
30744 
30745   # Input might be given as Windows format, start by converting to
30746   # unix format.
30747   new_path="$path"
30748 
30749   windows_path="$new_path"
30750   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30751     unix_path=`$CYGPATH -u "$windows_path"`
30752     new_path="$unix_path"
30753   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30754     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30755     new_path="$unix_path"
30756   fi
30757 
30758 
30759   # Now try to locate executable using which
30760   new_path=`$WHICH "$new_path" 2> /dev/null`
30761 
30762   if test "x$new_path" = x; then
30763     # Oops. Which didn't find the executable.
30764     # The splitting of arguments from the executable at a space might have been incorrect,
30765     # since paths with space are more likely in Windows. Give it another try with the whole
30766     # argument.
30767     path="$complete"
30768     arguments="EOL"
30769     new_path="$path"
30770 
30771   windows_path="$new_path"
30772   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30773     unix_path=`$CYGPATH -u "$windows_path"`
30774     new_path="$unix_path"
30775   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30776     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30777     new_path="$unix_path"
30778   fi
30779 
30780 
30781     new_path=`$WHICH "$new_path" 2> /dev/null`
30782 
30783     if test "x$new_path" = x; then
30784       # It's still not found. Now this is an unrecoverable error.
30785       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30786 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30787       has_space=`$ECHO "$complete" | $GREP " "`
30788       if test "x$has_space" != x; then
30789         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30790 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30791       fi
30792       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30793     fi
30794   fi
30795 
30796   # Now new_path has a complete unix path to the binary
30797   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30798     # Keep paths in /bin as-is, but remove trailing .exe if any
30799     new_path="${new_path/%.exe/}"
30800     # Do not save /bin paths to all_fixpath_prefixes!
30801   else
30802     # Not in mixed or Windows style, start by that.
30803     new_path=`cmd //c echo $new_path`
30804 
30805   input_path="$new_path"
30806   # Check if we need to convert this using DOS-style short mode. If the path
30807   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30808   # take no chances and rewrite it.
30809   # Note: m4 eats our [], so we need to use [ and ] instead.
30810   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30811   if test "x$has_forbidden_chars" != x; then
30812     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30813     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30814   fi
30815 
30816     # Output is in $new_path
30817 
30818   windows_path="$new_path"
30819   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30820     unix_path=`$CYGPATH -u "$windows_path"`
30821     new_path="$unix_path"
30822   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30823     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30824     new_path="$unix_path"
30825   fi
30826 
30827     # remove trailing .exe if any
30828     new_path="${new_path/%.exe/}"
30829 
30830     # Save the first 10 bytes of this path to the storage, so fixpath can work.
30831     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30832   fi
30833 
30834   else
30835     # We're on a posix platform. Hooray! :)
30836     # First separate the path from the arguments. This will split at the first
30837     # space.
30838     complete="$CPP"
30839     path="${complete%% *}"
30840     tmp="$complete EOL"
30841     arguments="${tmp#* }"
30842 
30843     # Cannot rely on the command "which" here since it doesn't always work.
30844     is_absolute_path=`$ECHO "$path" | $GREP ^/`
30845     if test -z "$is_absolute_path"; then
30846       # Path to executable is not absolute. Find it.
30847       IFS_save="$IFS"
30848       IFS=:
30849       for p in $PATH; do
30850         if test -f "$p/$path" && test -x "$p/$path"; then
30851           new_path="$p/$path"
30852           break
30853         fi
30854       done
30855       IFS="$IFS_save"
30856     else
30857       # This is an absolute path, we can use it without further modifications.
30858       new_path="$path"
30859     fi
30860 
30861     if test "x$new_path" = x; then
30862       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30863 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30864       has_space=`$ECHO "$complete" | $GREP " "`
30865       if test "x$has_space" != x; then
30866         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30867 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30868       fi
30869       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30870     fi
30871   fi
30872 
30873   # Now join together the path and the arguments once again
30874   if test "x$arguments" != xEOL; then
30875     new_complete="$new_path ${arguments% *}"
30876   else
30877     new_complete="$new_path"
30878   fi
30879 
30880   if test "x$complete" != "x$new_complete"; then
30881     CPP="$new_complete"
30882     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
30883 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
30884   fi
30885 
30886   ac_ext=cpp
30887 ac_cpp='$CXXCPP $CPPFLAGS'
30888 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30889 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30890 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
30892 $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
30893 if test -z "$CXXCPP"; then
30894   if ${ac_cv_prog_CXXCPP+:} false; then :
30895   $as_echo_n "(cached) " >&6
30896 else
30897       # Double quotes because CXXCPP needs to be expanded
30898     for CXXCPP in "$CXX -E" "/lib/cpp"
30899     do
30900       ac_preproc_ok=false
30901 for ac_cxx_preproc_warn_flag in '' yes
30902 do
30903   # Use a header file that comes with gcc, so configuring glibc
30904   # with a fresh cross-compiler works.
30905   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30906   # <limits.h> exists even on freestanding compilers.
30907   # On the NeXT, cc -E runs the code through the compiler's parser,
30908   # not just through cpp. "Syntax error" is here to catch this case.
30909   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30910 /* end confdefs.h.  */
30911 #ifdef __STDC__
30912 # include <limits.h>
30913 #else
30914 # include <assert.h>
30915 #endif
30916                      Syntax error
30917 _ACEOF
30918 if ac_fn_cxx_try_cpp "$LINENO"; then :
30919 
30920 else
30921   # Broken: fails on valid input.
30922 continue
30923 fi
30924 rm -f conftest.err conftest.i conftest.$ac_ext
30925 
30926   # OK, works on sane cases.  Now check whether nonexistent headers
30927   # can be detected and how.
30928   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30929 /* end confdefs.h.  */
30930 #include <ac_nonexistent.h>
30931 _ACEOF
30932 if ac_fn_cxx_try_cpp "$LINENO"; then :
30933   # Broken: success on invalid input.
30934 continue
30935 else
30936   # Passes both tests.
30937 ac_preproc_ok=:
30938 break
30939 fi
30940 rm -f conftest.err conftest.i conftest.$ac_ext
30941 
30942 done
30943 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30944 rm -f conftest.i conftest.err conftest.$ac_ext
30945 if $ac_preproc_ok; then :
30946   break
30947 fi
30948 
30949     done
30950     ac_cv_prog_CXXCPP=$CXXCPP
30951 
30952 fi
30953   CXXCPP=$ac_cv_prog_CXXCPP
30954 else
30955   ac_cv_prog_CXXCPP=$CXXCPP
30956 fi
30957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
30958 $as_echo "$CXXCPP" >&6; }
30959 ac_preproc_ok=false
30960 for ac_cxx_preproc_warn_flag in '' yes
30961 do
30962   # Use a header file that comes with gcc, so configuring glibc
30963   # with a fresh cross-compiler works.
30964   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30965   # <limits.h> exists even on freestanding compilers.
30966   # On the NeXT, cc -E runs the code through the compiler's parser,
30967   # not just through cpp. "Syntax error" is here to catch this case.
30968   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30969 /* end confdefs.h.  */
30970 #ifdef __STDC__
30971 # include <limits.h>
30972 #else
30973 # include <assert.h>
30974 #endif
30975                      Syntax error
30976 _ACEOF
30977 if ac_fn_cxx_try_cpp "$LINENO"; then :
30978 
30979 else
30980   # Broken: fails on valid input.
30981 continue
30982 fi
30983 rm -f conftest.err conftest.i conftest.$ac_ext
30984 
30985   # OK, works on sane cases.  Now check whether nonexistent headers
30986   # can be detected and how.
30987   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30988 /* end confdefs.h.  */
30989 #include <ac_nonexistent.h>
30990 _ACEOF
30991 if ac_fn_cxx_try_cpp "$LINENO"; then :
30992   # Broken: success on invalid input.
30993 continue
30994 else
30995   # Passes both tests.
30996 ac_preproc_ok=:
30997 break
30998 fi
30999 rm -f conftest.err conftest.i conftest.$ac_ext
31000 
31001 done
31002 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
31003 rm -f conftest.i conftest.err conftest.$ac_ext
31004 if $ac_preproc_ok; then :
31005 
31006 else
31007   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
31008 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
31009 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
31010 See \`config.log' for more details" "$LINENO" 5; }
31011 fi
31012 
31013 ac_ext=cpp
31014 ac_cpp='$CXXCPP $CPPFLAGS'
31015 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
31016 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
31017 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
31018 
31019 
31020   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31021 
31022   # First separate the path from the arguments. This will split at the first
31023   # space.
31024   complete="$CXXCPP"
31025   path="${complete%% *}"
31026   tmp="$complete EOL"
31027   arguments="${tmp#* }"
31028 
31029   # Input might be given as Windows format, start by converting to
31030   # unix format.
31031   new_path=`$CYGPATH -u "$path"`
31032 
31033   # Now try to locate executable using which
31034   new_path=`$WHICH "$new_path" 2> /dev/null`
31035   # bat and cmd files are not always considered executable in cygwin causing which
31036   # to not find them
31037   if test "x$new_path" = x \
31038       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31039       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31040     new_path=`$CYGPATH -u "$path"`
31041   fi
31042   if test "x$new_path" = x; then
31043     # Oops. Which didn't find the executable.
31044     # The splitting of arguments from the executable at a space might have been incorrect,
31045     # since paths with space are more likely in Windows. Give it another try with the whole
31046     # argument.
31047     path="$complete"
31048     arguments="EOL"
31049     new_path=`$CYGPATH -u "$path"`
31050     new_path=`$WHICH "$new_path" 2> /dev/null`
31051     # bat and cmd files are not always considered executable in cygwin causing which
31052     # to not find them
31053     if test "x$new_path" = x \
31054         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31055         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31056       new_path=`$CYGPATH -u "$path"`
31057     fi
31058     if test "x$new_path" = x; then
31059       # It's still not found. Now this is an unrecoverable error.
31060       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31061 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31062       has_space=`$ECHO "$complete" | $GREP " "`
31063       if test "x$has_space" != x; then
31064         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31065 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31066       fi
31067       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31068     fi
31069   fi
31070 
31071   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31072   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31073   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31074   # "foo.exe" is OK but "foo" is an error.
31075   #
31076   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31077   # It is also a way to make sure we got the proper file name for the real test later on.
31078   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31079   if test "x$test_shortpath" = x; then
31080     # Short path failed, file does not exist as specified.
31081     # Try adding .exe or .cmd
31082     if test -f "${new_path}.exe"; then
31083       input_to_shortpath="${new_path}.exe"
31084     elif test -f "${new_path}.cmd"; then
31085       input_to_shortpath="${new_path}.cmd"
31086     else
31087       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
31088 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
31089       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31090 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31091       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31092     fi
31093   else
31094     input_to_shortpath="$new_path"
31095   fi
31096 
31097   # Call helper function which possibly converts this using DOS-style short mode.
31098   # If so, the updated path is stored in $new_path.
31099   new_path="$input_to_shortpath"
31100 
31101   input_path="$input_to_shortpath"
31102   # Check if we need to convert this using DOS-style short mode. If the path
31103   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31104   # take no chances and rewrite it.
31105   # Note: m4 eats our [], so we need to use [ and ] instead.
31106   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31107   if test "x$has_forbidden_chars" != x; then
31108     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31109     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31110     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31111     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31112       # Going to short mode and back again did indeed matter. Since short mode is
31113       # case insensitive, let's make it lowercase to improve readability.
31114       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31115       # Now convert it back to Unix-stile (cygpath)
31116       input_path=`$CYGPATH -u "$shortmode_path"`
31117       new_path="$input_path"
31118     fi
31119   fi
31120 
31121   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31122   if test "x$test_cygdrive_prefix" = x; then
31123     # As a simple fix, exclude /usr/bin since it's not a real path.
31124     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31125       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31126       # a path prefixed by /cygdrive for fixpath to work.
31127       new_path="$CYGWIN_ROOT_PATH$input_path"
31128     fi
31129   fi
31130 
31131   # remove trailing .exe if any
31132   new_path="${new_path/%.exe/}"
31133 
31134   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31135 
31136   # First separate the path from the arguments. This will split at the first
31137   # space.
31138   complete="$CXXCPP"
31139   path="${complete%% *}"
31140   tmp="$complete EOL"
31141   arguments="${tmp#* }"
31142 
31143   # Input might be given as Windows format, start by converting to
31144   # unix format.
31145   new_path="$path"
31146 
31147   windows_path="$new_path"
31148   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31149     unix_path=`$CYGPATH -u "$windows_path"`
31150     new_path="$unix_path"
31151   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31152     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31153     new_path="$unix_path"
31154   fi
31155 
31156 
31157   # Now try to locate executable using which
31158   new_path=`$WHICH "$new_path" 2> /dev/null`
31159 
31160   if test "x$new_path" = x; then
31161     # Oops. Which didn't find the executable.
31162     # The splitting of arguments from the executable at a space might have been incorrect,
31163     # since paths with space are more likely in Windows. Give it another try with the whole
31164     # argument.
31165     path="$complete"
31166     arguments="EOL"
31167     new_path="$path"
31168 
31169   windows_path="$new_path"
31170   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31171     unix_path=`$CYGPATH -u "$windows_path"`
31172     new_path="$unix_path"
31173   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31174     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31175     new_path="$unix_path"
31176   fi
31177 
31178 
31179     new_path=`$WHICH "$new_path" 2> /dev/null`
31180 
31181     if test "x$new_path" = x; then
31182       # It's still not found. Now this is an unrecoverable error.
31183       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31184 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31185       has_space=`$ECHO "$complete" | $GREP " "`
31186       if test "x$has_space" != x; then
31187         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31188 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31189       fi
31190       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31191     fi
31192   fi
31193 
31194   # Now new_path has a complete unix path to the binary
31195   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31196     # Keep paths in /bin as-is, but remove trailing .exe if any
31197     new_path="${new_path/%.exe/}"
31198     # Do not save /bin paths to all_fixpath_prefixes!
31199   else
31200     # Not in mixed or Windows style, start by that.
31201     new_path=`cmd //c echo $new_path`
31202 
31203   input_path="$new_path"
31204   # Check if we need to convert this using DOS-style short mode. If the path
31205   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31206   # take no chances and rewrite it.
31207   # Note: m4 eats our [], so we need to use [ and ] instead.
31208   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31209   if test "x$has_forbidden_chars" != x; then
31210     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31211     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31212   fi
31213 
31214     # Output is in $new_path
31215 
31216   windows_path="$new_path"
31217   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31218     unix_path=`$CYGPATH -u "$windows_path"`
31219     new_path="$unix_path"
31220   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31221     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31222     new_path="$unix_path"
31223   fi
31224 
31225     # remove trailing .exe if any
31226     new_path="${new_path/%.exe/}"
31227 
31228     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31229     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31230   fi
31231 
31232   else
31233     # We're on a posix platform. Hooray! :)
31234     # First separate the path from the arguments. This will split at the first
31235     # space.
31236     complete="$CXXCPP"
31237     path="${complete%% *}"
31238     tmp="$complete EOL"
31239     arguments="${tmp#* }"
31240 
31241     # Cannot rely on the command "which" here since it doesn't always work.
31242     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31243     if test -z "$is_absolute_path"; then
31244       # Path to executable is not absolute. Find it.
31245       IFS_save="$IFS"
31246       IFS=:
31247       for p in $PATH; do
31248         if test -f "$p/$path" && test -x "$p/$path"; then
31249           new_path="$p/$path"
31250           break
31251         fi
31252       done
31253       IFS="$IFS_save"
31254     else
31255       # This is an absolute path, we can use it without further modifications.
31256       new_path="$path"
31257     fi
31258 
31259     if test "x$new_path" = x; then
31260       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31261 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31262       has_space=`$ECHO "$complete" | $GREP " "`
31263       if test "x$has_space" != x; then
31264         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31265 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31266       fi
31267       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31268     fi
31269   fi
31270 
31271   # Now join together the path and the arguments once again
31272   if test "x$arguments" != xEOL; then
31273     new_complete="$new_path ${arguments% *}"
31274   else
31275     new_complete="$new_path"
31276   fi
31277 
31278   if test "x$complete" != "x$new_complete"; then
31279     CXXCPP="$new_complete"
31280     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
31281 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
31282   fi
31283 
31284 
31285   #
31286   # Setup the linker (LD)
31287   #
31288   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
31289     # In the Microsoft toolchain we have a separate LD command "link".
31290     # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is
31291     # a cygwin program for something completely different.
31292     # Extract the first word of "link", so it can be a program name with args.
31293 set dummy link; ac_word=$2
31294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31295 $as_echo_n "checking for $ac_word... " >&6; }
31296 if ${ac_cv_prog_LD+:} false; then :
31297   $as_echo_n "(cached) " >&6
31298 else
31299   if test -n "$LD"; then
31300   ac_cv_prog_LD="$LD" # Let the user override the test.
31301 else
31302   ac_prog_rejected=no
31303 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31304 for as_dir in $PATH
31305 do
31306   IFS=$as_save_IFS
31307   test -z "$as_dir" && as_dir=.
31308     for ac_exec_ext in '' $ac_executable_extensions; do
31309   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31310     if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
31311        ac_prog_rejected=yes
31312        continue
31313      fi
31314     ac_cv_prog_LD="link"
31315     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31316     break 2
31317   fi
31318 done
31319   done
31320 IFS=$as_save_IFS
31321 
31322 if test $ac_prog_rejected = yes; then
31323   # We found a bogon in the path, so make sure we never use it.
31324   set dummy $ac_cv_prog_LD
31325   shift
31326   if test $# != 0; then
31327     # We chose a different compiler from the bogus one.
31328     # However, it has the same basename, so the bogon will be chosen
31329     # first if we set LD to just the basename; use the full file name.
31330     shift
31331     ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@"
31332   fi
31333 fi
31334 fi
31335 fi
31336 LD=$ac_cv_prog_LD
31337 if test -n "$LD"; then
31338   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
31339 $as_echo "$LD" >&6; }
31340 else
31341   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31342 $as_echo "no" >&6; }
31343 fi
31344 
31345 
31346 
31347   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31348 
31349   # First separate the path from the arguments. This will split at the first
31350   # space.
31351   complete="$LD"
31352   path="${complete%% *}"
31353   tmp="$complete EOL"
31354   arguments="${tmp#* }"
31355 
31356   # Input might be given as Windows format, start by converting to
31357   # unix format.
31358   new_path=`$CYGPATH -u "$path"`
31359 
31360   # Now try to locate executable using which
31361   new_path=`$WHICH "$new_path" 2> /dev/null`
31362   # bat and cmd files are not always considered executable in cygwin causing which
31363   # to not find them
31364   if test "x$new_path" = x \
31365       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31366       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31367     new_path=`$CYGPATH -u "$path"`
31368   fi
31369   if test "x$new_path" = x; then
31370     # Oops. Which didn't find the executable.
31371     # The splitting of arguments from the executable at a space might have been incorrect,
31372     # since paths with space are more likely in Windows. Give it another try with the whole
31373     # argument.
31374     path="$complete"
31375     arguments="EOL"
31376     new_path=`$CYGPATH -u "$path"`
31377     new_path=`$WHICH "$new_path" 2> /dev/null`
31378     # bat and cmd files are not always considered executable in cygwin causing which
31379     # to not find them
31380     if test "x$new_path" = x \
31381         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31382         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31383       new_path=`$CYGPATH -u "$path"`
31384     fi
31385     if test "x$new_path" = x; then
31386       # It's still not found. Now this is an unrecoverable error.
31387       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31388 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31389       has_space=`$ECHO "$complete" | $GREP " "`
31390       if test "x$has_space" != x; then
31391         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31392 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31393       fi
31394       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31395     fi
31396   fi
31397 
31398   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31399   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31400   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31401   # "foo.exe" is OK but "foo" is an error.
31402   #
31403   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31404   # It is also a way to make sure we got the proper file name for the real test later on.
31405   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31406   if test "x$test_shortpath" = x; then
31407     # Short path failed, file does not exist as specified.
31408     # Try adding .exe or .cmd
31409     if test -f "${new_path}.exe"; then
31410       input_to_shortpath="${new_path}.exe"
31411     elif test -f "${new_path}.cmd"; then
31412       input_to_shortpath="${new_path}.cmd"
31413     else
31414       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5
31415 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;}
31416       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31417 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31418       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31419     fi
31420   else
31421     input_to_shortpath="$new_path"
31422   fi
31423 
31424   # Call helper function which possibly converts this using DOS-style short mode.
31425   # If so, the updated path is stored in $new_path.
31426   new_path="$input_to_shortpath"
31427 
31428   input_path="$input_to_shortpath"
31429   # Check if we need to convert this using DOS-style short mode. If the path
31430   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31431   # take no chances and rewrite it.
31432   # Note: m4 eats our [], so we need to use [ and ] instead.
31433   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31434   if test "x$has_forbidden_chars" != x; then
31435     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31436     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31437     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31438     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31439       # Going to short mode and back again did indeed matter. Since short mode is
31440       # case insensitive, let's make it lowercase to improve readability.
31441       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31442       # Now convert it back to Unix-stile (cygpath)
31443       input_path=`$CYGPATH -u "$shortmode_path"`
31444       new_path="$input_path"
31445     fi
31446   fi
31447 
31448   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31449   if test "x$test_cygdrive_prefix" = x; then
31450     # As a simple fix, exclude /usr/bin since it's not a real path.
31451     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31452       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31453       # a path prefixed by /cygdrive for fixpath to work.
31454       new_path="$CYGWIN_ROOT_PATH$input_path"
31455     fi
31456   fi
31457 
31458   # remove trailing .exe if any
31459   new_path="${new_path/%.exe/}"
31460 
31461   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31462 
31463   # First separate the path from the arguments. This will split at the first
31464   # space.
31465   complete="$LD"
31466   path="${complete%% *}"
31467   tmp="$complete EOL"
31468   arguments="${tmp#* }"
31469 
31470   # Input might be given as Windows format, start by converting to
31471   # unix format.
31472   new_path="$path"
31473 
31474   windows_path="$new_path"
31475   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31476     unix_path=`$CYGPATH -u "$windows_path"`
31477     new_path="$unix_path"
31478   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31479     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31480     new_path="$unix_path"
31481   fi
31482 
31483 
31484   # Now try to locate executable using which
31485   new_path=`$WHICH "$new_path" 2> /dev/null`
31486 
31487   if test "x$new_path" = x; then
31488     # Oops. Which didn't find the executable.
31489     # The splitting of arguments from the executable at a space might have been incorrect,
31490     # since paths with space are more likely in Windows. Give it another try with the whole
31491     # argument.
31492     path="$complete"
31493     arguments="EOL"
31494     new_path="$path"
31495 
31496   windows_path="$new_path"
31497   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31498     unix_path=`$CYGPATH -u "$windows_path"`
31499     new_path="$unix_path"
31500   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31501     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31502     new_path="$unix_path"
31503   fi
31504 
31505 
31506     new_path=`$WHICH "$new_path" 2> /dev/null`
31507 
31508     if test "x$new_path" = x; then
31509       # It's still not found. Now this is an unrecoverable error.
31510       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31511 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31512       has_space=`$ECHO "$complete" | $GREP " "`
31513       if test "x$has_space" != x; then
31514         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31515 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31516       fi
31517       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31518     fi
31519   fi
31520 
31521   # Now new_path has a complete unix path to the binary
31522   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31523     # Keep paths in /bin as-is, but remove trailing .exe if any
31524     new_path="${new_path/%.exe/}"
31525     # Do not save /bin paths to all_fixpath_prefixes!
31526   else
31527     # Not in mixed or Windows style, start by that.
31528     new_path=`cmd //c echo $new_path`
31529 
31530   input_path="$new_path"
31531   # Check if we need to convert this using DOS-style short mode. If the path
31532   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31533   # take no chances and rewrite it.
31534   # Note: m4 eats our [], so we need to use [ and ] instead.
31535   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31536   if test "x$has_forbidden_chars" != x; then
31537     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31538     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31539   fi
31540 
31541     # Output is in $new_path
31542 
31543   windows_path="$new_path"
31544   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31545     unix_path=`$CYGPATH -u "$windows_path"`
31546     new_path="$unix_path"
31547   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31548     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31549     new_path="$unix_path"
31550   fi
31551 
31552     # remove trailing .exe if any
31553     new_path="${new_path/%.exe/}"
31554 
31555     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31556     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31557   fi
31558 
31559   else
31560     # We're on a posix platform. Hooray! :)
31561     # First separate the path from the arguments. This will split at the first
31562     # space.
31563     complete="$LD"
31564     path="${complete%% *}"
31565     tmp="$complete EOL"
31566     arguments="${tmp#* }"
31567 
31568     # Cannot rely on the command "which" here since it doesn't always work.
31569     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31570     if test -z "$is_absolute_path"; then
31571       # Path to executable is not absolute. Find it.
31572       IFS_save="$IFS"
31573       IFS=:
31574       for p in $PATH; do
31575         if test -f "$p/$path" && test -x "$p/$path"; then
31576           new_path="$p/$path"
31577           break
31578         fi
31579       done
31580       IFS="$IFS_save"
31581     else
31582       # This is an absolute path, we can use it without further modifications.
31583       new_path="$path"
31584     fi
31585 
31586     if test "x$new_path" = x; then
31587       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31588 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31589       has_space=`$ECHO "$complete" | $GREP " "`
31590       if test "x$has_space" != x; then
31591         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31592 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31593       fi
31594       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31595     fi
31596   fi
31597 
31598   # Now join together the path and the arguments once again
31599   if test "x$arguments" != xEOL; then
31600     new_complete="$new_path ${arguments% *}"
31601   else
31602     new_complete="$new_path"
31603   fi
31604 
31605   if test "x$complete" != "x$new_complete"; then
31606     LD="$new_complete"
31607     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5
31608 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;}
31609   fi
31610 
31611     # Verify that we indeed succeeded with this trick.
31612     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
31613 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
31614     "$LD" --version > /dev/null
31615     if test $? -eq 0 ; then
31616       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31617 $as_echo "no" >&6; }
31618       as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
31619     else
31620       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31621 $as_echo "yes" >&6; }
31622     fi
31623     LDCXX="$LD"
31624   else
31625     # All other toolchains use the compiler to link.
31626     LD="$CC"
31627     LDCXX="$CXX"
31628   fi
31629 
31630   # FIXME: it should be CXXLD, according to standard (cf CXXCPP)
31631 
31632 
31633   #
31634   # Setup the assembler (AS)
31635   #
31636   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
31637     # FIXME: should this really be solaris, or solstudio?
31638 
31639 
31640   # Publish this variable in the help.
31641 
31642 
31643   if test "x$AS" = x; then
31644     # The variable is not set by user, try to locate tool using the code snippet
31645     for ac_prog in as
31646 do
31647   # Extract the first word of "$ac_prog", so it can be a program name with args.
31648 set dummy $ac_prog; ac_word=$2
31649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31650 $as_echo_n "checking for $ac_word... " >&6; }
31651 if ${ac_cv_path_AS+:} false; then :
31652   $as_echo_n "(cached) " >&6
31653 else
31654   case $AS in
31655   [\\/]* | ?:[\\/]*)
31656   ac_cv_path_AS="$AS" # Let the user override the test with a path.
31657   ;;
31658   *)
31659   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31660 for as_dir in $PATH
31661 do
31662   IFS=$as_save_IFS
31663   test -z "$as_dir" && as_dir=.
31664     for ac_exec_ext in '' $ac_executable_extensions; do
31665   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31666     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31667     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31668     break 2
31669   fi
31670 done
31671   done
31672 IFS=$as_save_IFS
31673 
31674   ;;
31675 esac
31676 fi
31677 AS=$ac_cv_path_AS
31678 if test -n "$AS"; then
31679   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31680 $as_echo "$AS" >&6; }
31681 else
31682   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31683 $as_echo "no" >&6; }
31684 fi
31685 
31686 
31687   test -n "$AS" && break
31688 done
31689 
31690   else
31691     # The variable is set, but is it from the command line or the environment?
31692 
31693     # Try to remove the string !AS! from our list.
31694     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
31695     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
31696       # If it failed, the variable was not from the command line. Ignore it,
31697       # but warn the user (except for BASH, which is always set by the calling BASH).
31698       if test "xAS" != xBASH; then
31699         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
31700 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
31701       fi
31702       # Try to locate tool using the code snippet
31703       for ac_prog in as
31704 do
31705   # Extract the first word of "$ac_prog", so it can be a program name with args.
31706 set dummy $ac_prog; ac_word=$2
31707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31708 $as_echo_n "checking for $ac_word... " >&6; }
31709 if ${ac_cv_path_AS+:} false; then :
31710   $as_echo_n "(cached) " >&6
31711 else
31712   case $AS in
31713   [\\/]* | ?:[\\/]*)
31714   ac_cv_path_AS="$AS" # Let the user override the test with a path.
31715   ;;
31716   *)
31717   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31718 for as_dir in $PATH
31719 do
31720   IFS=$as_save_IFS
31721   test -z "$as_dir" && as_dir=.
31722     for ac_exec_ext in '' $ac_executable_extensions; do
31723   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31724     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31725     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31726     break 2
31727   fi
31728 done
31729   done
31730 IFS=$as_save_IFS
31731 
31732   ;;
31733 esac
31734 fi
31735 AS=$ac_cv_path_AS
31736 if test -n "$AS"; then
31737   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31738 $as_echo "$AS" >&6; }
31739 else
31740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31741 $as_echo "no" >&6; }
31742 fi
31743 
31744 
31745   test -n "$AS" && break
31746 done
31747 
31748     else
31749       # If it succeeded, then it was overridden by the user. We will use it
31750       # for the tool.
31751 
31752       # First remove it from the list of overridden variables, so we can test
31753       # for unknown variables in the end.
31754       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
31755 
31756       # Check if the provided tool contains a complete path.
31757       tool_specified="$AS"
31758       tool_basename="${tool_specified##*/}"
31759       if test "x$tool_basename" = "x$tool_specified"; then
31760         # A command without a complete path is provided, search $PATH.
31761         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
31762 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
31763         # Extract the first word of "$tool_basename", so it can be a program name with args.
31764 set dummy $tool_basename; ac_word=$2
31765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31766 $as_echo_n "checking for $ac_word... " >&6; }
31767 if ${ac_cv_path_AS+:} false; then :
31768   $as_echo_n "(cached) " >&6
31769 else
31770   case $AS in
31771   [\\/]* | ?:[\\/]*)
31772   ac_cv_path_AS="$AS" # Let the user override the test with a path.
31773   ;;
31774   *)
31775   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31776 for as_dir in $PATH
31777 do
31778   IFS=$as_save_IFS
31779   test -z "$as_dir" && as_dir=.
31780     for ac_exec_ext in '' $ac_executable_extensions; do
31781   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31782     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31783     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31784     break 2
31785   fi
31786 done
31787   done
31788 IFS=$as_save_IFS
31789 
31790   ;;
31791 esac
31792 fi
31793 AS=$ac_cv_path_AS
31794 if test -n "$AS"; then
31795   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31796 $as_echo "$AS" >&6; }
31797 else
31798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31799 $as_echo "no" >&6; }
31800 fi
31801 
31802 
31803         if test "x$AS" = x; then
31804           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
31805         fi
31806       else
31807         # Otherwise we believe it is a complete path. Use it as it is.
31808         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
31809 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
31810         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
31811 $as_echo_n "checking for AS... " >&6; }
31812         if test ! -x "$tool_specified"; then
31813           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
31814 $as_echo "not found" >&6; }
31815           as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
31816         fi
31817         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
31818 $as_echo "$tool_specified" >&6; }
31819       fi
31820     fi
31821   fi
31822 
31823 
31824 
31825   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31826 
31827   # First separate the path from the arguments. This will split at the first
31828   # space.
31829   complete="$AS"
31830   path="${complete%% *}"
31831   tmp="$complete EOL"
31832   arguments="${tmp#* }"
31833 
31834   # Input might be given as Windows format, start by converting to
31835   # unix format.
31836   new_path=`$CYGPATH -u "$path"`
31837 
31838   # Now try to locate executable using which
31839   new_path=`$WHICH "$new_path" 2> /dev/null`
31840   # bat and cmd files are not always considered executable in cygwin causing which
31841   # to not find them
31842   if test "x$new_path" = x \
31843       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31844       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31845     new_path=`$CYGPATH -u "$path"`
31846   fi
31847   if test "x$new_path" = x; then
31848     # Oops. Which didn't find the executable.
31849     # The splitting of arguments from the executable at a space might have been incorrect,
31850     # since paths with space are more likely in Windows. Give it another try with the whole
31851     # argument.
31852     path="$complete"
31853     arguments="EOL"
31854     new_path=`$CYGPATH -u "$path"`
31855     new_path=`$WHICH "$new_path" 2> /dev/null`
31856     # bat and cmd files are not always considered executable in cygwin causing which
31857     # to not find them
31858     if test "x$new_path" = x \
31859         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31860         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31861       new_path=`$CYGPATH -u "$path"`
31862     fi
31863     if test "x$new_path" = x; then
31864       # It's still not found. Now this is an unrecoverable error.
31865       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31866 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31867       has_space=`$ECHO "$complete" | $GREP " "`
31868       if test "x$has_space" != x; then
31869         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31870 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31871       fi
31872       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31873     fi
31874   fi
31875 
31876   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31877   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31878   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31879   # "foo.exe" is OK but "foo" is an error.
31880   #
31881   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31882   # It is also a way to make sure we got the proper file name for the real test later on.
31883   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31884   if test "x$test_shortpath" = x; then
31885     # Short path failed, file does not exist as specified.
31886     # Try adding .exe or .cmd
31887     if test -f "${new_path}.exe"; then
31888       input_to_shortpath="${new_path}.exe"
31889     elif test -f "${new_path}.cmd"; then
31890       input_to_shortpath="${new_path}.cmd"
31891     else
31892       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
31893 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
31894       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31895 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31896       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31897     fi
31898   else
31899     input_to_shortpath="$new_path"
31900   fi
31901 
31902   # Call helper function which possibly converts this using DOS-style short mode.
31903   # If so, the updated path is stored in $new_path.
31904   new_path="$input_to_shortpath"
31905 
31906   input_path="$input_to_shortpath"
31907   # Check if we need to convert this using DOS-style short mode. If the path
31908   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31909   # take no chances and rewrite it.
31910   # Note: m4 eats our [], so we need to use [ and ] instead.
31911   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31912   if test "x$has_forbidden_chars" != x; then
31913     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31914     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31915     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31916     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31917       # Going to short mode and back again did indeed matter. Since short mode is
31918       # case insensitive, let's make it lowercase to improve readability.
31919       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31920       # Now convert it back to Unix-stile (cygpath)
31921       input_path=`$CYGPATH -u "$shortmode_path"`
31922       new_path="$input_path"
31923     fi
31924   fi
31925 
31926   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31927   if test "x$test_cygdrive_prefix" = x; then
31928     # As a simple fix, exclude /usr/bin since it's not a real path.
31929     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31930       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31931       # a path prefixed by /cygdrive for fixpath to work.
31932       new_path="$CYGWIN_ROOT_PATH$input_path"
31933     fi
31934   fi
31935 
31936   # remove trailing .exe if any
31937   new_path="${new_path/%.exe/}"
31938 
31939   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31940 
31941   # First separate the path from the arguments. This will split at the first
31942   # space.
31943   complete="$AS"
31944   path="${complete%% *}"
31945   tmp="$complete EOL"
31946   arguments="${tmp#* }"
31947 
31948   # Input might be given as Windows format, start by converting to
31949   # unix format.
31950   new_path="$path"
31951 
31952   windows_path="$new_path"
31953   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31954     unix_path=`$CYGPATH -u "$windows_path"`
31955     new_path="$unix_path"
31956   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31957     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31958     new_path="$unix_path"
31959   fi
31960 
31961 
31962   # Now try to locate executable using which
31963   new_path=`$WHICH "$new_path" 2> /dev/null`
31964 
31965   if test "x$new_path" = x; then
31966     # Oops. Which didn't find the executable.
31967     # The splitting of arguments from the executable at a space might have been incorrect,
31968     # since paths with space are more likely in Windows. Give it another try with the whole
31969     # argument.
31970     path="$complete"
31971     arguments="EOL"
31972     new_path="$path"
31973 
31974   windows_path="$new_path"
31975   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31976     unix_path=`$CYGPATH -u "$windows_path"`
31977     new_path="$unix_path"
31978   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31979     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31980     new_path="$unix_path"
31981   fi
31982 
31983 
31984     new_path=`$WHICH "$new_path" 2> /dev/null`
31985 
31986     if test "x$new_path" = x; then
31987       # It's still not found. Now this is an unrecoverable error.
31988       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31989 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31990       has_space=`$ECHO "$complete" | $GREP " "`
31991       if test "x$has_space" != x; then
31992         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31993 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31994       fi
31995       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31996     fi
31997   fi
31998 
31999   # Now new_path has a complete unix path to the binary
32000   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32001     # Keep paths in /bin as-is, but remove trailing .exe if any
32002     new_path="${new_path/%.exe/}"
32003     # Do not save /bin paths to all_fixpath_prefixes!
32004   else
32005     # Not in mixed or Windows style, start by that.
32006     new_path=`cmd //c echo $new_path`
32007 
32008   input_path="$new_path"
32009   # Check if we need to convert this using DOS-style short mode. If the path
32010   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32011   # take no chances and rewrite it.
32012   # Note: m4 eats our [], so we need to use [ and ] instead.
32013   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32014   if test "x$has_forbidden_chars" != x; then
32015     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32016     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32017   fi
32018 
32019     # Output is in $new_path
32020 
32021   windows_path="$new_path"
32022   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32023     unix_path=`$CYGPATH -u "$windows_path"`
32024     new_path="$unix_path"
32025   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32026     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32027     new_path="$unix_path"
32028   fi
32029 
32030     # remove trailing .exe if any
32031     new_path="${new_path/%.exe/}"
32032 
32033     # Save the first 10 bytes of this path to the storage, so fixpath can work.
32034     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32035   fi
32036 
32037   else
32038     # We're on a posix platform. Hooray! :)
32039     # First separate the path from the arguments. This will split at the first
32040     # space.
32041     complete="$AS"
32042     path="${complete%% *}"
32043     tmp="$complete EOL"
32044     arguments="${tmp#* }"
32045 
32046     # Cannot rely on the command "which" here since it doesn't always work.
32047     is_absolute_path=`$ECHO "$path" | $GREP ^/`
32048     if test -z "$is_absolute_path"; then
32049       # Path to executable is not absolute. Find it.
32050       IFS_save="$IFS"
32051       IFS=:
32052       for p in $PATH; do
32053         if test -f "$p/$path" && test -x "$p/$path"; then
32054           new_path="$p/$path"
32055           break
32056         fi
32057       done
32058       IFS="$IFS_save"
32059     else
32060       # This is an absolute path, we can use it without further modifications.
32061       new_path="$path"
32062     fi
32063 
32064     if test "x$new_path" = x; then
32065       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32066 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32067       has_space=`$ECHO "$complete" | $GREP " "`
32068       if test "x$has_space" != x; then
32069         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32070 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32071       fi
32072       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32073     fi
32074   fi
32075 
32076   # Now join together the path and the arguments once again
32077   if test "x$arguments" != xEOL; then
32078     new_complete="$new_path ${arguments% *}"
32079   else
32080     new_complete="$new_path"
32081   fi
32082 
32083   if test "x$complete" != "x$new_complete"; then
32084     AS="$new_complete"
32085     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
32086 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
32087   fi
32088 
32089   else
32090     # FIXME: is this correct for microsoft?
32091     AS="$CC -c"
32092   fi
32093 
32094 
32095   #
32096   # Setup the archiver (AR)
32097   #
32098   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
32099     # The corresponding ar tool is lib.exe (used to create static libraries)
32100     # Extract the first word of "lib", so it can be a program name with args.
32101 set dummy lib; ac_word=$2
32102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32103 $as_echo_n "checking for $ac_word... " >&6; }
32104 if ${ac_cv_prog_AR+:} false; then :
32105   $as_echo_n "(cached) " >&6
32106 else
32107   if test -n "$AR"; then
32108   ac_cv_prog_AR="$AR" # Let the user override the test.
32109 else
32110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32111 for as_dir in $PATH
32112 do
32113   IFS=$as_save_IFS
32114   test -z "$as_dir" && as_dir=.
32115     for ac_exec_ext in '' $ac_executable_extensions; do
32116   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32117     ac_cv_prog_AR="lib"
32118     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32119     break 2
32120   fi
32121 done
32122   done
32123 IFS=$as_save_IFS
32124 
32125 fi
32126 fi
32127 AR=$ac_cv_prog_AR
32128 if test -n "$AR"; then
32129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32130 $as_echo "$AR" >&6; }
32131 else
32132   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32133 $as_echo "no" >&6; }
32134 fi
32135 
32136 
32137   else
32138 
32139 
32140   # Publish this variable in the help.
32141 
32142 
32143   if test "x$AR" = x; then
32144     # The variable is not set by user, try to locate tool using the code snippet
32145     if test -n "$ac_tool_prefix"; then
32146   for ac_prog in ar
32147   do
32148     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32149 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32151 $as_echo_n "checking for $ac_word... " >&6; }
32152 if ${ac_cv_prog_AR+:} false; then :
32153   $as_echo_n "(cached) " >&6
32154 else
32155   if test -n "$AR"; then
32156   ac_cv_prog_AR="$AR" # Let the user override the test.
32157 else
32158 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32159 for as_dir in $PATH
32160 do
32161   IFS=$as_save_IFS
32162   test -z "$as_dir" && as_dir=.
32163     for ac_exec_ext in '' $ac_executable_extensions; do
32164   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32165     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32166     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32167     break 2
32168   fi
32169 done
32170   done
32171 IFS=$as_save_IFS
32172 
32173 fi
32174 fi
32175 AR=$ac_cv_prog_AR
32176 if test -n "$AR"; then
32177   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32178 $as_echo "$AR" >&6; }
32179 else
32180   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32181 $as_echo "no" >&6; }
32182 fi
32183 
32184 
32185     test -n "$AR" && break
32186   done
32187 fi
32188 if test -z "$AR"; then
32189   ac_ct_AR=$AR
32190   for ac_prog in ar
32191 do
32192   # Extract the first word of "$ac_prog", so it can be a program name with args.
32193 set dummy $ac_prog; 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_prog_ac_ct_AR+:} false; then :
32197   $as_echo_n "(cached) " >&6
32198 else
32199   if test -n "$ac_ct_AR"; then
32200   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32201 else
32202 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32203 for as_dir in $PATH
32204 do
32205   IFS=$as_save_IFS
32206   test -z "$as_dir" && as_dir=.
32207     for ac_exec_ext in '' $ac_executable_extensions; do
32208   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32209     ac_cv_prog_ac_ct_AR="$ac_prog"
32210     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32211     break 2
32212   fi
32213 done
32214   done
32215 IFS=$as_save_IFS
32216 
32217 fi
32218 fi
32219 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32220 if test -n "$ac_ct_AR"; then
32221   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32222 $as_echo "$ac_ct_AR" >&6; }
32223 else
32224   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32225 $as_echo "no" >&6; }
32226 fi
32227 
32228 
32229   test -n "$ac_ct_AR" && break
32230 done
32231 
32232   if test "x$ac_ct_AR" = x; then
32233     AR=""
32234   else
32235     case $cross_compiling:$ac_tool_warned in
32236 yes:)
32237 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32238 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32239 ac_tool_warned=yes ;;
32240 esac
32241     AR=$ac_ct_AR
32242   fi
32243 fi
32244 
32245   else
32246     # The variable is set, but is it from the command line or the environment?
32247 
32248     # Try to remove the string !AR! from our list.
32249     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32250     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32251       # If it failed, the variable was not from the command line. Ignore it,
32252       # but warn the user (except for BASH, which is always set by the calling BASH).
32253       if test "xAR" != xBASH; then
32254         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32255 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32256       fi
32257       # Try to locate tool using the code snippet
32258       if test -n "$ac_tool_prefix"; then
32259   for ac_prog in ar
32260   do
32261     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32262 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32264 $as_echo_n "checking for $ac_word... " >&6; }
32265 if ${ac_cv_prog_AR+:} false; then :
32266   $as_echo_n "(cached) " >&6
32267 else
32268   if test -n "$AR"; then
32269   ac_cv_prog_AR="$AR" # Let the user override the test.
32270 else
32271 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32272 for as_dir in $PATH
32273 do
32274   IFS=$as_save_IFS
32275   test -z "$as_dir" && as_dir=.
32276     for ac_exec_ext in '' $ac_executable_extensions; do
32277   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32278     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32279     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32280     break 2
32281   fi
32282 done
32283   done
32284 IFS=$as_save_IFS
32285 
32286 fi
32287 fi
32288 AR=$ac_cv_prog_AR
32289 if test -n "$AR"; then
32290   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32291 $as_echo "$AR" >&6; }
32292 else
32293   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32294 $as_echo "no" >&6; }
32295 fi
32296 
32297 
32298     test -n "$AR" && break
32299   done
32300 fi
32301 if test -z "$AR"; then
32302   ac_ct_AR=$AR
32303   for ac_prog in ar
32304 do
32305   # Extract the first word of "$ac_prog", so it can be a program name with args.
32306 set dummy $ac_prog; ac_word=$2
32307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32308 $as_echo_n "checking for $ac_word... " >&6; }
32309 if ${ac_cv_prog_ac_ct_AR+:} false; then :
32310   $as_echo_n "(cached) " >&6
32311 else
32312   if test -n "$ac_ct_AR"; then
32313   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32314 else
32315 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32316 for as_dir in $PATH
32317 do
32318   IFS=$as_save_IFS
32319   test -z "$as_dir" && as_dir=.
32320     for ac_exec_ext in '' $ac_executable_extensions; do
32321   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32322     ac_cv_prog_ac_ct_AR="$ac_prog"
32323     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32324     break 2
32325   fi
32326 done
32327   done
32328 IFS=$as_save_IFS
32329 
32330 fi
32331 fi
32332 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32333 if test -n "$ac_ct_AR"; then
32334   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32335 $as_echo "$ac_ct_AR" >&6; }
32336 else
32337   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32338 $as_echo "no" >&6; }
32339 fi
32340 
32341 
32342   test -n "$ac_ct_AR" && break
32343 done
32344 
32345   if test "x$ac_ct_AR" = x; then
32346     AR=""
32347   else
32348     case $cross_compiling:$ac_tool_warned in
32349 yes:)
32350 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32351 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32352 ac_tool_warned=yes ;;
32353 esac
32354     AR=$ac_ct_AR
32355   fi
32356 fi
32357 
32358     else
32359       # If it succeeded, then it was overridden by the user. We will use it
32360       # for the tool.
32361 
32362       # First remove it from the list of overridden variables, so we can test
32363       # for unknown variables in the end.
32364       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32365 
32366       # Check if the provided tool contains a complete path.
32367       tool_specified="$AR"
32368       tool_basename="${tool_specified##*/}"
32369       if test "x$tool_basename" = "x$tool_specified"; then
32370         # A command without a complete path is provided, search $PATH.
32371         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
32372 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
32373         # Extract the first word of "$tool_basename", so it can be a program name with args.
32374 set dummy $tool_basename; ac_word=$2
32375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32376 $as_echo_n "checking for $ac_word... " >&6; }
32377 if ${ac_cv_path_AR+:} false; then :
32378   $as_echo_n "(cached) " >&6
32379 else
32380   case $AR in
32381   [\\/]* | ?:[\\/]*)
32382   ac_cv_path_AR="$AR" # Let the user override the test with a path.
32383   ;;
32384   *)
32385   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32386 for as_dir in $PATH
32387 do
32388   IFS=$as_save_IFS
32389   test -z "$as_dir" && as_dir=.
32390     for ac_exec_ext in '' $ac_executable_extensions; do
32391   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32392     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
32393     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32394     break 2
32395   fi
32396 done
32397   done
32398 IFS=$as_save_IFS
32399 
32400   ;;
32401 esac
32402 fi
32403 AR=$ac_cv_path_AR
32404 if test -n "$AR"; then
32405   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32406 $as_echo "$AR" >&6; }
32407 else
32408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32409 $as_echo "no" >&6; }
32410 fi
32411 
32412 
32413         if test "x$AR" = x; then
32414           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32415         fi
32416       else
32417         # Otherwise we believe it is a complete path. Use it as it is.
32418         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
32419 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
32420         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
32421 $as_echo_n "checking for AR... " >&6; }
32422         if test ! -x "$tool_specified"; then
32423           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32424 $as_echo "not found" >&6; }
32425           as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
32426         fi
32427         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32428 $as_echo "$tool_specified" >&6; }
32429       fi
32430     fi
32431   fi
32432 
32433 
32434   fi
32435 
32436   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32437 
32438   # First separate the path from the arguments. This will split at the first
32439   # space.
32440   complete="$AR"
32441   path="${complete%% *}"
32442   tmp="$complete EOL"
32443   arguments="${tmp#* }"
32444 
32445   # Input might be given as Windows format, start by converting to
32446   # unix format.
32447   new_path=`$CYGPATH -u "$path"`
32448 
32449   # Now try to locate executable using which
32450   new_path=`$WHICH "$new_path" 2> /dev/null`
32451   # bat and cmd files are not always considered executable in cygwin causing which
32452   # to not find them
32453   if test "x$new_path" = x \
32454       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32455       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32456     new_path=`$CYGPATH -u "$path"`
32457   fi
32458   if test "x$new_path" = x; then
32459     # Oops. Which didn't find the executable.
32460     # The splitting of arguments from the executable at a space might have been incorrect,
32461     # since paths with space are more likely in Windows. Give it another try with the whole
32462     # argument.
32463     path="$complete"
32464     arguments="EOL"
32465     new_path=`$CYGPATH -u "$path"`
32466     new_path=`$WHICH "$new_path" 2> /dev/null`
32467     # bat and cmd files are not always considered executable in cygwin causing which
32468     # to not find them
32469     if test "x$new_path" = x \
32470         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32471         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32472       new_path=`$CYGPATH -u "$path"`
32473     fi
32474     if test "x$new_path" = x; then
32475       # It's still not found. Now this is an unrecoverable error.
32476       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32477 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32478       has_space=`$ECHO "$complete" | $GREP " "`
32479       if test "x$has_space" != x; then
32480         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32481 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32482       fi
32483       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32484     fi
32485   fi
32486 
32487   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32488   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32489   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32490   # "foo.exe" is OK but "foo" is an error.
32491   #
32492   # This test is therefore slightly more accurate than "test -f" to check for file presence.
32493   # It is also a way to make sure we got the proper file name for the real test later on.
32494   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32495   if test "x$test_shortpath" = x; then
32496     # Short path failed, file does not exist as specified.
32497     # Try adding .exe or .cmd
32498     if test -f "${new_path}.exe"; then
32499       input_to_shortpath="${new_path}.exe"
32500     elif test -f "${new_path}.cmd"; then
32501       input_to_shortpath="${new_path}.cmd"
32502     else
32503       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
32504 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
32505       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32506 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32507       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32508     fi
32509   else
32510     input_to_shortpath="$new_path"
32511   fi
32512 
32513   # Call helper function which possibly converts this using DOS-style short mode.
32514   # If so, the updated path is stored in $new_path.
32515   new_path="$input_to_shortpath"
32516 
32517   input_path="$input_to_shortpath"
32518   # Check if we need to convert this using DOS-style short mode. If the path
32519   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32520   # take no chances and rewrite it.
32521   # Note: m4 eats our [], so we need to use [ and ] instead.
32522   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32523   if test "x$has_forbidden_chars" != x; then
32524     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32525     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32526     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32527     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32528       # Going to short mode and back again did indeed matter. Since short mode is
32529       # case insensitive, let's make it lowercase to improve readability.
32530       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32531       # Now convert it back to Unix-stile (cygpath)
32532       input_path=`$CYGPATH -u "$shortmode_path"`
32533       new_path="$input_path"
32534     fi
32535   fi
32536 
32537   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32538   if test "x$test_cygdrive_prefix" = x; then
32539     # As a simple fix, exclude /usr/bin since it's not a real path.
32540     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32541       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32542       # a path prefixed by /cygdrive for fixpath to work.
32543       new_path="$CYGWIN_ROOT_PATH$input_path"
32544     fi
32545   fi
32546 
32547   # remove trailing .exe if any
32548   new_path="${new_path/%.exe/}"
32549 
32550   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32551 
32552   # First separate the path from the arguments. This will split at the first
32553   # space.
32554   complete="$AR"
32555   path="${complete%% *}"
32556   tmp="$complete EOL"
32557   arguments="${tmp#* }"
32558 
32559   # Input might be given as Windows format, start by converting to
32560   # unix format.
32561   new_path="$path"
32562 
32563   windows_path="$new_path"
32564   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32565     unix_path=`$CYGPATH -u "$windows_path"`
32566     new_path="$unix_path"
32567   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32568     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32569     new_path="$unix_path"
32570   fi
32571 
32572 
32573   # Now try to locate executable using which
32574   new_path=`$WHICH "$new_path" 2> /dev/null`
32575 
32576   if test "x$new_path" = x; then
32577     # Oops. Which didn't find the executable.
32578     # The splitting of arguments from the executable at a space might have been incorrect,
32579     # since paths with space are more likely in Windows. Give it another try with the whole
32580     # argument.
32581     path="$complete"
32582     arguments="EOL"
32583     new_path="$path"
32584 
32585   windows_path="$new_path"
32586   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32587     unix_path=`$CYGPATH -u "$windows_path"`
32588     new_path="$unix_path"
32589   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32590     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32591     new_path="$unix_path"
32592   fi
32593 
32594 
32595     new_path=`$WHICH "$new_path" 2> /dev/null`
32596 
32597     if test "x$new_path" = x; then
32598       # It's still not found. Now this is an unrecoverable error.
32599       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32600 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32601       has_space=`$ECHO "$complete" | $GREP " "`
32602       if test "x$has_space" != x; then
32603         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32604 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32605       fi
32606       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32607     fi
32608   fi
32609 
32610   # Now new_path has a complete unix path to the binary
32611   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32612     # Keep paths in /bin as-is, but remove trailing .exe if any
32613     new_path="${new_path/%.exe/}"
32614     # Do not save /bin paths to all_fixpath_prefixes!
32615   else
32616     # Not in mixed or Windows style, start by that.
32617     new_path=`cmd //c echo $new_path`
32618 
32619   input_path="$new_path"
32620   # Check if we need to convert this using DOS-style short mode. If the path
32621   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32622   # take no chances and rewrite it.
32623   # Note: m4 eats our [], so we need to use [ and ] instead.
32624   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32625   if test "x$has_forbidden_chars" != x; then
32626     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32627     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32628   fi
32629 
32630     # Output is in $new_path
32631 
32632   windows_path="$new_path"
32633   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32634     unix_path=`$CYGPATH -u "$windows_path"`
32635     new_path="$unix_path"
32636   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32637     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32638     new_path="$unix_path"
32639   fi
32640 
32641     # remove trailing .exe if any
32642     new_path="${new_path/%.exe/}"
32643 
32644     # Save the first 10 bytes of this path to the storage, so fixpath can work.
32645     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32646   fi
32647 
32648   else
32649     # We're on a posix platform. Hooray! :)
32650     # First separate the path from the arguments. This will split at the first
32651     # space.
32652     complete="$AR"
32653     path="${complete%% *}"
32654     tmp="$complete EOL"
32655     arguments="${tmp#* }"
32656 
32657     # Cannot rely on the command "which" here since it doesn't always work.
32658     is_absolute_path=`$ECHO "$path" | $GREP ^/`
32659     if test -z "$is_absolute_path"; then
32660       # Path to executable is not absolute. Find it.
32661       IFS_save="$IFS"
32662       IFS=:
32663       for p in $PATH; do
32664         if test -f "$p/$path" && test -x "$p/$path"; then
32665           new_path="$p/$path"
32666           break
32667         fi
32668       done
32669       IFS="$IFS_save"
32670     else
32671       # This is an absolute path, we can use it without further modifications.
32672       new_path="$path"
32673     fi
32674 
32675     if test "x$new_path" = x; then
32676       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32677 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32678       has_space=`$ECHO "$complete" | $GREP " "`
32679       if test "x$has_space" != x; then
32680         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32681 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32682       fi
32683       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32684     fi
32685   fi
32686 
32687   # Now join together the path and the arguments once again
32688   if test "x$arguments" != xEOL; then
32689     new_complete="$new_path ${arguments% *}"
32690   else
32691     new_complete="$new_path"
32692   fi
32693 
32694   if test "x$complete" != "x$new_complete"; then
32695     AR="$new_complete"
32696     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
32697 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
32698   fi
32699 
32700 
32701 
32702   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
32703     ac_ext=m
32704 ac_cpp='$OBJCPP $CPPFLAGS'
32705 ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32706 ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32707 ac_compiler_gnu=$ac_cv_objc_compiler_gnu
32708 if test -n "$ac_tool_prefix"; then
32709   for ac_prog in gcc objcc objc cc CC
32710   do
32711     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32712 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32714 $as_echo_n "checking for $ac_word... " >&6; }
32715 if ${ac_cv_prog_OBJC+:} false; then :
32716   $as_echo_n "(cached) " >&6
32717 else
32718   if test -n "$OBJC"; then
32719   ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
32720 else
32721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32722 for as_dir in $PATH
32723 do
32724   IFS=$as_save_IFS
32725   test -z "$as_dir" && as_dir=.
32726     for ac_exec_ext in '' $ac_executable_extensions; do
32727   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32728     ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
32729     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32730     break 2
32731   fi
32732 done
32733   done
32734 IFS=$as_save_IFS
32735 
32736 fi
32737 fi
32738 OBJC=$ac_cv_prog_OBJC
32739 if test -n "$OBJC"; then
32740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
32741 $as_echo "$OBJC" >&6; }
32742 else
32743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32744 $as_echo "no" >&6; }
32745 fi
32746 
32747 
32748     test -n "$OBJC" && break
32749   done
32750 fi
32751 if test -z "$OBJC"; then
32752   ac_ct_OBJC=$OBJC
32753   for ac_prog in gcc objcc objc cc CC
32754 do
32755   # Extract the first word of "$ac_prog", so it can be a program name with args.
32756 set dummy $ac_prog; ac_word=$2
32757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32758 $as_echo_n "checking for $ac_word... " >&6; }
32759 if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
32760   $as_echo_n "(cached) " >&6
32761 else
32762   if test -n "$ac_ct_OBJC"; then
32763   ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
32764 else
32765 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32766 for as_dir in $PATH
32767 do
32768   IFS=$as_save_IFS
32769   test -z "$as_dir" && as_dir=.
32770     for ac_exec_ext in '' $ac_executable_extensions; do
32771   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32772     ac_cv_prog_ac_ct_OBJC="$ac_prog"
32773     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32774     break 2
32775   fi
32776 done
32777   done
32778 IFS=$as_save_IFS
32779 
32780 fi
32781 fi
32782 ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
32783 if test -n "$ac_ct_OBJC"; then
32784   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
32785 $as_echo "$ac_ct_OBJC" >&6; }
32786 else
32787   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32788 $as_echo "no" >&6; }
32789 fi
32790 
32791 
32792   test -n "$ac_ct_OBJC" && break
32793 done
32794 
32795   if test "x$ac_ct_OBJC" = x; then
32796     OBJC="gcc"
32797   else
32798     case $cross_compiling:$ac_tool_warned in
32799 yes:)
32800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32801 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32802 ac_tool_warned=yes ;;
32803 esac
32804     OBJC=$ac_ct_OBJC
32805   fi
32806 fi
32807 
32808 # Provide some information about the compiler.
32809 $as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
32810 set X $ac_compile
32811 ac_compiler=$2
32812 for ac_option in --version -v -V -qversion; do
32813   { { ac_try="$ac_compiler $ac_option >&5"
32814 case "(($ac_try" in
32815   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32816   *) ac_try_echo=$ac_try;;
32817 esac
32818 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32819 $as_echo "$ac_try_echo"; } >&5
32820   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32821   ac_status=$?
32822   if test -s conftest.err; then
32823     sed '10a\
32824 ... rest of stderr output deleted ...
32825          10q' conftest.err >conftest.er1
32826     cat conftest.er1 >&5
32827   fi
32828   rm -f conftest.er1 conftest.err
32829   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32830   test $ac_status = 0; }
32831 done
32832 
32833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
32834 $as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
32835 if ${ac_cv_objc_compiler_gnu+:} false; then :
32836   $as_echo_n "(cached) " >&6
32837 else
32838   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32839 /* end confdefs.h.  */
32840 
32841 int
32842 main ()
32843 {
32844 #ifndef __GNUC__
32845        choke me
32846 #endif
32847 
32848   ;
32849   return 0;
32850 }
32851 _ACEOF
32852 if ac_fn_objc_try_compile "$LINENO"; then :
32853   ac_compiler_gnu=yes
32854 else
32855   ac_compiler_gnu=no
32856 fi
32857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32858 ac_cv_objc_compiler_gnu=$ac_compiler_gnu
32859 
32860 fi
32861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
32862 $as_echo "$ac_cv_objc_compiler_gnu" >&6; }
32863 if test $ac_compiler_gnu = yes; then
32864   GOBJC=yes
32865 else
32866   GOBJC=
32867 fi
32868 ac_test_OBJCFLAGS=${OBJCFLAGS+set}
32869 ac_save_OBJCFLAGS=$OBJCFLAGS
32870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
32871 $as_echo_n "checking whether $OBJC accepts -g... " >&6; }
32872 if ${ac_cv_prog_objc_g+:} false; then :
32873   $as_echo_n "(cached) " >&6
32874 else
32875   ac_save_objc_werror_flag=$ac_objc_werror_flag
32876    ac_objc_werror_flag=yes
32877    ac_cv_prog_objc_g=no
32878    OBJCFLAGS="-g"
32879    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32880 /* end confdefs.h.  */
32881 
32882 int
32883 main ()
32884 {
32885 
32886   ;
32887   return 0;
32888 }
32889 _ACEOF
32890 if ac_fn_objc_try_compile "$LINENO"; then :
32891   ac_cv_prog_objc_g=yes
32892 else
32893   OBJCFLAGS=""
32894       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32895 /* end confdefs.h.  */
32896 
32897 int
32898 main ()
32899 {
32900 
32901   ;
32902   return 0;
32903 }
32904 _ACEOF
32905 if ac_fn_objc_try_compile "$LINENO"; then :
32906 
32907 else
32908   ac_objc_werror_flag=$ac_save_objc_werror_flag
32909          OBJCFLAGS="-g"
32910          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32911 /* end confdefs.h.  */
32912 
32913 int
32914 main ()
32915 {
32916 
32917   ;
32918   return 0;
32919 }
32920 _ACEOF
32921 if ac_fn_objc_try_compile "$LINENO"; then :
32922   ac_cv_prog_objc_g=yes
32923 fi
32924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32925 fi
32926 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32927 fi
32928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32929    ac_objc_werror_flag=$ac_save_objc_werror_flag
32930 fi
32931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
32932 $as_echo "$ac_cv_prog_objc_g" >&6; }
32933 if test "$ac_test_OBJCFLAGS" = set; then
32934   OBJCFLAGS=$ac_save_OBJCFLAGS
32935 elif test $ac_cv_prog_objc_g = yes; then
32936   if test "$GOBJC" = yes; then
32937     OBJCFLAGS="-g -O2"
32938   else
32939     OBJCFLAGS="-g"
32940   fi
32941 else
32942   if test "$GOBJC" = yes; then
32943     OBJCFLAGS="-O2"
32944   else
32945     OBJCFLAGS=
32946   fi
32947 fi
32948 ac_ext=cpp
32949 ac_cpp='$CXXCPP $CPPFLAGS'
32950 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32951 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32952 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32953 
32954 
32955   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32956 
32957   # First separate the path from the arguments. This will split at the first
32958   # space.
32959   complete="$OBJC"
32960   path="${complete%% *}"
32961   tmp="$complete EOL"
32962   arguments="${tmp#* }"
32963 
32964   # Input might be given as Windows format, start by converting to
32965   # unix format.
32966   new_path=`$CYGPATH -u "$path"`
32967 
32968   # Now try to locate executable using which
32969   new_path=`$WHICH "$new_path" 2> /dev/null`
32970   # bat and cmd files are not always considered executable in cygwin causing which
32971   # to not find them
32972   if test "x$new_path" = x \
32973       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32974       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32975     new_path=`$CYGPATH -u "$path"`
32976   fi
32977   if test "x$new_path" = x; then
32978     # Oops. Which didn't find the executable.
32979     # The splitting of arguments from the executable at a space might have been incorrect,
32980     # since paths with space are more likely in Windows. Give it another try with the whole
32981     # argument.
32982     path="$complete"
32983     arguments="EOL"
32984     new_path=`$CYGPATH -u "$path"`
32985     new_path=`$WHICH "$new_path" 2> /dev/null`
32986     # bat and cmd files are not always considered executable in cygwin causing which
32987     # to not find them
32988     if test "x$new_path" = x \
32989         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32990         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32991       new_path=`$CYGPATH -u "$path"`
32992     fi
32993     if test "x$new_path" = x; then
32994       # It's still not found. Now this is an unrecoverable error.
32995       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32996 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32997       has_space=`$ECHO "$complete" | $GREP " "`
32998       if test "x$has_space" != x; then
32999         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33000 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33001       fi
33002       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33003     fi
33004   fi
33005 
33006   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33007   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33008   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33009   # "foo.exe" is OK but "foo" is an error.
33010   #
33011   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33012   # It is also a way to make sure we got the proper file name for the real test later on.
33013   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33014   if test "x$test_shortpath" = x; then
33015     # Short path failed, file does not exist as specified.
33016     # Try adding .exe or .cmd
33017     if test -f "${new_path}.exe"; then
33018       input_to_shortpath="${new_path}.exe"
33019     elif test -f "${new_path}.cmd"; then
33020       input_to_shortpath="${new_path}.cmd"
33021     else
33022       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
33023 $as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
33024       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33025 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33026       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33027     fi
33028   else
33029     input_to_shortpath="$new_path"
33030   fi
33031 
33032   # Call helper function which possibly converts this using DOS-style short mode.
33033   # If so, the updated path is stored in $new_path.
33034   new_path="$input_to_shortpath"
33035 
33036   input_path="$input_to_shortpath"
33037   # Check if we need to convert this using DOS-style short mode. If the path
33038   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33039   # take no chances and rewrite it.
33040   # Note: m4 eats our [], so we need to use [ and ] instead.
33041   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33042   if test "x$has_forbidden_chars" != x; then
33043     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33044     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33045     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33046     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33047       # Going to short mode and back again did indeed matter. Since short mode is
33048       # case insensitive, let's make it lowercase to improve readability.
33049       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33050       # Now convert it back to Unix-stile (cygpath)
33051       input_path=`$CYGPATH -u "$shortmode_path"`
33052       new_path="$input_path"
33053     fi
33054   fi
33055 
33056   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33057   if test "x$test_cygdrive_prefix" = x; then
33058     # As a simple fix, exclude /usr/bin since it's not a real path.
33059     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33060       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33061       # a path prefixed by /cygdrive for fixpath to work.
33062       new_path="$CYGWIN_ROOT_PATH$input_path"
33063     fi
33064   fi
33065 
33066   # remove trailing .exe if any
33067   new_path="${new_path/%.exe/}"
33068 
33069   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33070 
33071   # First separate the path from the arguments. This will split at the first
33072   # space.
33073   complete="$OBJC"
33074   path="${complete%% *}"
33075   tmp="$complete EOL"
33076   arguments="${tmp#* }"
33077 
33078   # Input might be given as Windows format, start by converting to
33079   # unix format.
33080   new_path="$path"
33081 
33082   windows_path="$new_path"
33083   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33084     unix_path=`$CYGPATH -u "$windows_path"`
33085     new_path="$unix_path"
33086   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33087     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33088     new_path="$unix_path"
33089   fi
33090 
33091 
33092   # Now try to locate executable using which
33093   new_path=`$WHICH "$new_path" 2> /dev/null`
33094 
33095   if test "x$new_path" = x; then
33096     # Oops. Which didn't find the executable.
33097     # The splitting of arguments from the executable at a space might have been incorrect,
33098     # since paths with space are more likely in Windows. Give it another try with the whole
33099     # argument.
33100     path="$complete"
33101     arguments="EOL"
33102     new_path="$path"
33103 
33104   windows_path="$new_path"
33105   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33106     unix_path=`$CYGPATH -u "$windows_path"`
33107     new_path="$unix_path"
33108   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33109     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33110     new_path="$unix_path"
33111   fi
33112 
33113 
33114     new_path=`$WHICH "$new_path" 2> /dev/null`
33115 
33116     if test "x$new_path" = x; then
33117       # It's still not found. Now this is an unrecoverable error.
33118       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33119 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33120       has_space=`$ECHO "$complete" | $GREP " "`
33121       if test "x$has_space" != x; then
33122         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33123 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33124       fi
33125       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33126     fi
33127   fi
33128 
33129   # Now new_path has a complete unix path to the binary
33130   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33131     # Keep paths in /bin as-is, but remove trailing .exe if any
33132     new_path="${new_path/%.exe/}"
33133     # Do not save /bin paths to all_fixpath_prefixes!
33134   else
33135     # Not in mixed or Windows style, start by that.
33136     new_path=`cmd //c echo $new_path`
33137 
33138   input_path="$new_path"
33139   # Check if we need to convert this using DOS-style short mode. If the path
33140   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33141   # take no chances and rewrite it.
33142   # Note: m4 eats our [], so we need to use [ and ] instead.
33143   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33144   if test "x$has_forbidden_chars" != x; then
33145     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33146     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33147   fi
33148 
33149     # Output is in $new_path
33150 
33151   windows_path="$new_path"
33152   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33153     unix_path=`$CYGPATH -u "$windows_path"`
33154     new_path="$unix_path"
33155   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33156     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33157     new_path="$unix_path"
33158   fi
33159 
33160     # remove trailing .exe if any
33161     new_path="${new_path/%.exe/}"
33162 
33163     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33164     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33165   fi
33166 
33167   else
33168     # We're on a posix platform. Hooray! :)
33169     # First separate the path from the arguments. This will split at the first
33170     # space.
33171     complete="$OBJC"
33172     path="${complete%% *}"
33173     tmp="$complete EOL"
33174     arguments="${tmp#* }"
33175 
33176     # Cannot rely on the command "which" here since it doesn't always work.
33177     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33178     if test -z "$is_absolute_path"; then
33179       # Path to executable is not absolute. Find it.
33180       IFS_save="$IFS"
33181       IFS=:
33182       for p in $PATH; do
33183         if test -f "$p/$path" && test -x "$p/$path"; then
33184           new_path="$p/$path"
33185           break
33186         fi
33187       done
33188       IFS="$IFS_save"
33189     else
33190       # This is an absolute path, we can use it without further modifications.
33191       new_path="$path"
33192     fi
33193 
33194     if test "x$new_path" = x; then
33195       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33196 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33197       has_space=`$ECHO "$complete" | $GREP " "`
33198       if test "x$has_space" != x; then
33199         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33200 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33201       fi
33202       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33203     fi
33204   fi
33205 
33206   # Now join together the path and the arguments once again
33207   if test "x$arguments" != xEOL; then
33208     new_complete="$new_path ${arguments% *}"
33209   else
33210     new_complete="$new_path"
33211   fi
33212 
33213   if test "x$complete" != "x$new_complete"; then
33214     OBJC="$new_complete"
33215     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
33216 $as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
33217   fi
33218 
33219 
33220 
33221   # Publish this variable in the help.
33222 
33223 
33224   if test "x$LIPO" = x; then
33225     # The variable is not set by user, try to locate tool using the code snippet
33226     for ac_prog in lipo
33227 do
33228   # Extract the first word of "$ac_prog", so it can be a program name with args.
33229 set dummy $ac_prog; ac_word=$2
33230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33231 $as_echo_n "checking for $ac_word... " >&6; }
33232 if ${ac_cv_path_LIPO+:} false; then :
33233   $as_echo_n "(cached) " >&6
33234 else
33235   case $LIPO in
33236   [\\/]* | ?:[\\/]*)
33237   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33238   ;;
33239   *)
33240   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33241 for as_dir in $PATH
33242 do
33243   IFS=$as_save_IFS
33244   test -z "$as_dir" && as_dir=.
33245     for ac_exec_ext in '' $ac_executable_extensions; do
33246   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33247     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33248     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33249     break 2
33250   fi
33251 done
33252   done
33253 IFS=$as_save_IFS
33254 
33255   ;;
33256 esac
33257 fi
33258 LIPO=$ac_cv_path_LIPO
33259 if test -n "$LIPO"; then
33260   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33261 $as_echo "$LIPO" >&6; }
33262 else
33263   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33264 $as_echo "no" >&6; }
33265 fi
33266 
33267 
33268   test -n "$LIPO" && break
33269 done
33270 
33271   else
33272     # The variable is set, but is it from the command line or the environment?
33273 
33274     # Try to remove the string !LIPO! from our list.
33275     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
33276     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
33277       # If it failed, the variable was not from the command line. Ignore it,
33278       # but warn the user (except for BASH, which is always set by the calling BASH).
33279       if test "xLIPO" != xBASH; then
33280         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
33281 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
33282       fi
33283       # Try to locate tool using the code snippet
33284       for ac_prog in lipo
33285 do
33286   # Extract the first word of "$ac_prog", so it can be a program name with args.
33287 set dummy $ac_prog; ac_word=$2
33288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33289 $as_echo_n "checking for $ac_word... " >&6; }
33290 if ${ac_cv_path_LIPO+:} false; then :
33291   $as_echo_n "(cached) " >&6
33292 else
33293   case $LIPO in
33294   [\\/]* | ?:[\\/]*)
33295   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33296   ;;
33297   *)
33298   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33299 for as_dir in $PATH
33300 do
33301   IFS=$as_save_IFS
33302   test -z "$as_dir" && as_dir=.
33303     for ac_exec_ext in '' $ac_executable_extensions; do
33304   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33305     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33306     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33307     break 2
33308   fi
33309 done
33310   done
33311 IFS=$as_save_IFS
33312 
33313   ;;
33314 esac
33315 fi
33316 LIPO=$ac_cv_path_LIPO
33317 if test -n "$LIPO"; then
33318   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33319 $as_echo "$LIPO" >&6; }
33320 else
33321   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33322 $as_echo "no" >&6; }
33323 fi
33324 
33325 
33326   test -n "$LIPO" && break
33327 done
33328 
33329     else
33330       # If it succeeded, then it was overridden by the user. We will use it
33331       # for the tool.
33332 
33333       # First remove it from the list of overridden variables, so we can test
33334       # for unknown variables in the end.
33335       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33336 
33337       # Check if the provided tool contains a complete path.
33338       tool_specified="$LIPO"
33339       tool_basename="${tool_specified##*/}"
33340       if test "x$tool_basename" = "x$tool_specified"; then
33341         # A command without a complete path is provided, search $PATH.
33342         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
33343 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
33344         # Extract the first word of "$tool_basename", so it can be a program name with args.
33345 set dummy $tool_basename; ac_word=$2
33346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33347 $as_echo_n "checking for $ac_word... " >&6; }
33348 if ${ac_cv_path_LIPO+:} false; then :
33349   $as_echo_n "(cached) " >&6
33350 else
33351   case $LIPO in
33352   [\\/]* | ?:[\\/]*)
33353   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33354   ;;
33355   *)
33356   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33357 for as_dir in $PATH
33358 do
33359   IFS=$as_save_IFS
33360   test -z "$as_dir" && as_dir=.
33361     for ac_exec_ext in '' $ac_executable_extensions; do
33362   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33363     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33364     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33365     break 2
33366   fi
33367 done
33368   done
33369 IFS=$as_save_IFS
33370 
33371   ;;
33372 esac
33373 fi
33374 LIPO=$ac_cv_path_LIPO
33375 if test -n "$LIPO"; then
33376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33377 $as_echo "$LIPO" >&6; }
33378 else
33379   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33380 $as_echo "no" >&6; }
33381 fi
33382 
33383 
33384         if test "x$LIPO" = x; then
33385           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33386         fi
33387       else
33388         # Otherwise we believe it is a complete path. Use it as it is.
33389         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
33390 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
33391         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
33392 $as_echo_n "checking for LIPO... " >&6; }
33393         if test ! -x "$tool_specified"; then
33394           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33395 $as_echo "not found" >&6; }
33396           as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
33397         fi
33398         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33399 $as_echo "$tool_specified" >&6; }
33400       fi
33401     fi
33402   fi
33403 
33404 
33405 
33406   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33407 
33408   # First separate the path from the arguments. This will split at the first
33409   # space.
33410   complete="$LIPO"
33411   path="${complete%% *}"
33412   tmp="$complete EOL"
33413   arguments="${tmp#* }"
33414 
33415   # Input might be given as Windows format, start by converting to
33416   # unix format.
33417   new_path=`$CYGPATH -u "$path"`
33418 
33419   # Now try to locate executable using which
33420   new_path=`$WHICH "$new_path" 2> /dev/null`
33421   # bat and cmd files are not always considered executable in cygwin causing which
33422   # to not find them
33423   if test "x$new_path" = x \
33424       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33425       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33426     new_path=`$CYGPATH -u "$path"`
33427   fi
33428   if test "x$new_path" = x; then
33429     # Oops. Which didn't find the executable.
33430     # The splitting of arguments from the executable at a space might have been incorrect,
33431     # since paths with space are more likely in Windows. Give it another try with the whole
33432     # argument.
33433     path="$complete"
33434     arguments="EOL"
33435     new_path=`$CYGPATH -u "$path"`
33436     new_path=`$WHICH "$new_path" 2> /dev/null`
33437     # bat and cmd files are not always considered executable in cygwin causing which
33438     # to not find them
33439     if test "x$new_path" = x \
33440         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33441         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33442       new_path=`$CYGPATH -u "$path"`
33443     fi
33444     if test "x$new_path" = x; then
33445       # It's still not found. Now this is an unrecoverable error.
33446       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33447 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33448       has_space=`$ECHO "$complete" | $GREP " "`
33449       if test "x$has_space" != x; then
33450         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33451 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33452       fi
33453       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33454     fi
33455   fi
33456 
33457   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33458   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33459   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33460   # "foo.exe" is OK but "foo" is an error.
33461   #
33462   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33463   # It is also a way to make sure we got the proper file name for the real test later on.
33464   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33465   if test "x$test_shortpath" = x; then
33466     # Short path failed, file does not exist as specified.
33467     # Try adding .exe or .cmd
33468     if test -f "${new_path}.exe"; then
33469       input_to_shortpath="${new_path}.exe"
33470     elif test -f "${new_path}.cmd"; then
33471       input_to_shortpath="${new_path}.cmd"
33472     else
33473       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
33474 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
33475       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33476 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33477       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33478     fi
33479   else
33480     input_to_shortpath="$new_path"
33481   fi
33482 
33483   # Call helper function which possibly converts this using DOS-style short mode.
33484   # If so, the updated path is stored in $new_path.
33485   new_path="$input_to_shortpath"
33486 
33487   input_path="$input_to_shortpath"
33488   # Check if we need to convert this using DOS-style short mode. If the path
33489   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33490   # take no chances and rewrite it.
33491   # Note: m4 eats our [], so we need to use [ and ] instead.
33492   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33493   if test "x$has_forbidden_chars" != x; then
33494     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33495     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33496     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33497     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33498       # Going to short mode and back again did indeed matter. Since short mode is
33499       # case insensitive, let's make it lowercase to improve readability.
33500       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33501       # Now convert it back to Unix-stile (cygpath)
33502       input_path=`$CYGPATH -u "$shortmode_path"`
33503       new_path="$input_path"
33504     fi
33505   fi
33506 
33507   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33508   if test "x$test_cygdrive_prefix" = x; then
33509     # As a simple fix, exclude /usr/bin since it's not a real path.
33510     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33511       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33512       # a path prefixed by /cygdrive for fixpath to work.
33513       new_path="$CYGWIN_ROOT_PATH$input_path"
33514     fi
33515   fi
33516 
33517   # remove trailing .exe if any
33518   new_path="${new_path/%.exe/}"
33519 
33520   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33521 
33522   # First separate the path from the arguments. This will split at the first
33523   # space.
33524   complete="$LIPO"
33525   path="${complete%% *}"
33526   tmp="$complete EOL"
33527   arguments="${tmp#* }"
33528 
33529   # Input might be given as Windows format, start by converting to
33530   # unix format.
33531   new_path="$path"
33532 
33533   windows_path="$new_path"
33534   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33535     unix_path=`$CYGPATH -u "$windows_path"`
33536     new_path="$unix_path"
33537   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33538     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33539     new_path="$unix_path"
33540   fi
33541 
33542 
33543   # Now try to locate executable using which
33544   new_path=`$WHICH "$new_path" 2> /dev/null`
33545 
33546   if test "x$new_path" = x; then
33547     # Oops. Which didn't find the executable.
33548     # The splitting of arguments from the executable at a space might have been incorrect,
33549     # since paths with space are more likely in Windows. Give it another try with the whole
33550     # argument.
33551     path="$complete"
33552     arguments="EOL"
33553     new_path="$path"
33554 
33555   windows_path="$new_path"
33556   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33557     unix_path=`$CYGPATH -u "$windows_path"`
33558     new_path="$unix_path"
33559   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33560     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33561     new_path="$unix_path"
33562   fi
33563 
33564 
33565     new_path=`$WHICH "$new_path" 2> /dev/null`
33566 
33567     if test "x$new_path" = x; then
33568       # It's still not found. Now this is an unrecoverable error.
33569       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33570 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33571       has_space=`$ECHO "$complete" | $GREP " "`
33572       if test "x$has_space" != x; then
33573         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33574 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33575       fi
33576       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33577     fi
33578   fi
33579 
33580   # Now new_path has a complete unix path to the binary
33581   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33582     # Keep paths in /bin as-is, but remove trailing .exe if any
33583     new_path="${new_path/%.exe/}"
33584     # Do not save /bin paths to all_fixpath_prefixes!
33585   else
33586     # Not in mixed or Windows style, start by that.
33587     new_path=`cmd //c echo $new_path`
33588 
33589   input_path="$new_path"
33590   # Check if we need to convert this using DOS-style short mode. If the path
33591   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33592   # take no chances and rewrite it.
33593   # Note: m4 eats our [], so we need to use [ and ] instead.
33594   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33595   if test "x$has_forbidden_chars" != x; then
33596     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33597     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33598   fi
33599 
33600     # Output is in $new_path
33601 
33602   windows_path="$new_path"
33603   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33604     unix_path=`$CYGPATH -u "$windows_path"`
33605     new_path="$unix_path"
33606   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33607     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33608     new_path="$unix_path"
33609   fi
33610 
33611     # remove trailing .exe if any
33612     new_path="${new_path/%.exe/}"
33613 
33614     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33615     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33616   fi
33617 
33618   else
33619     # We're on a posix platform. Hooray! :)
33620     # First separate the path from the arguments. This will split at the first
33621     # space.
33622     complete="$LIPO"
33623     path="${complete%% *}"
33624     tmp="$complete EOL"
33625     arguments="${tmp#* }"
33626 
33627     # Cannot rely on the command "which" here since it doesn't always work.
33628     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33629     if test -z "$is_absolute_path"; then
33630       # Path to executable is not absolute. Find it.
33631       IFS_save="$IFS"
33632       IFS=:
33633       for p in $PATH; do
33634         if test -f "$p/$path" && test -x "$p/$path"; then
33635           new_path="$p/$path"
33636           break
33637         fi
33638       done
33639       IFS="$IFS_save"
33640     else
33641       # This is an absolute path, we can use it without further modifications.
33642       new_path="$path"
33643     fi
33644 
33645     if test "x$new_path" = x; then
33646       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33647 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33648       has_space=`$ECHO "$complete" | $GREP " "`
33649       if test "x$has_space" != x; then
33650         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33651 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33652       fi
33653       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33654     fi
33655   fi
33656 
33657   # Now join together the path and the arguments once again
33658   if test "x$arguments" != xEOL; then
33659     new_complete="$new_path ${arguments% *}"
33660   else
33661     new_complete="$new_path"
33662   fi
33663 
33664   if test "x$complete" != "x$new_complete"; then
33665     LIPO="$new_complete"
33666     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
33667 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
33668   fi
33669 
33670   else
33671     OBJC=
33672   fi
33673 
33674   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
33675     # Extract the first word of "mt", so it can be a program name with args.
33676 set dummy mt; ac_word=$2
33677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33678 $as_echo_n "checking for $ac_word... " >&6; }
33679 if ${ac_cv_prog_MT+:} false; then :
33680   $as_echo_n "(cached) " >&6
33681 else
33682   if test -n "$MT"; then
33683   ac_cv_prog_MT="$MT" # Let the user override the test.
33684 else
33685   ac_prog_rejected=no
33686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33687 for as_dir in $PATH
33688 do
33689   IFS=$as_save_IFS
33690   test -z "$as_dir" && as_dir=.
33691     for ac_exec_ext in '' $ac_executable_extensions; do
33692   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33693     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
33694        ac_prog_rejected=yes
33695        continue
33696      fi
33697     ac_cv_prog_MT="mt"
33698     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33699     break 2
33700   fi
33701 done
33702   done
33703 IFS=$as_save_IFS
33704 
33705 if test $ac_prog_rejected = yes; then
33706   # We found a bogon in the path, so make sure we never use it.
33707   set dummy $ac_cv_prog_MT
33708   shift
33709   if test $# != 0; then
33710     # We chose a different compiler from the bogus one.
33711     # However, it has the same basename, so the bogon will be chosen
33712     # first if we set MT to just the basename; use the full file name.
33713     shift
33714     ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
33715   fi
33716 fi
33717 fi
33718 fi
33719 MT=$ac_cv_prog_MT
33720 if test -n "$MT"; then
33721   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
33722 $as_echo "$MT" >&6; }
33723 else
33724   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33725 $as_echo "no" >&6; }
33726 fi
33727 
33728 
33729 
33730   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33731 
33732   # First separate the path from the arguments. This will split at the first
33733   # space.
33734   complete="$MT"
33735   path="${complete%% *}"
33736   tmp="$complete EOL"
33737   arguments="${tmp#* }"
33738 
33739   # Input might be given as Windows format, start by converting to
33740   # unix format.
33741   new_path=`$CYGPATH -u "$path"`
33742 
33743   # Now try to locate executable using which
33744   new_path=`$WHICH "$new_path" 2> /dev/null`
33745   # bat and cmd files are not always considered executable in cygwin causing which
33746   # to not find them
33747   if test "x$new_path" = x \
33748       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33749       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33750     new_path=`$CYGPATH -u "$path"`
33751   fi
33752   if test "x$new_path" = x; then
33753     # Oops. Which didn't find the executable.
33754     # The splitting of arguments from the executable at a space might have been incorrect,
33755     # since paths with space are more likely in Windows. Give it another try with the whole
33756     # argument.
33757     path="$complete"
33758     arguments="EOL"
33759     new_path=`$CYGPATH -u "$path"`
33760     new_path=`$WHICH "$new_path" 2> /dev/null`
33761     # bat and cmd files are not always considered executable in cygwin causing which
33762     # to not find them
33763     if test "x$new_path" = x \
33764         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33765         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33766       new_path=`$CYGPATH -u "$path"`
33767     fi
33768     if test "x$new_path" = x; then
33769       # It's still not found. Now this is an unrecoverable error.
33770       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33771 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33772       has_space=`$ECHO "$complete" | $GREP " "`
33773       if test "x$has_space" != x; then
33774         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33775 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33776       fi
33777       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33778     fi
33779   fi
33780 
33781   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33782   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33783   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33784   # "foo.exe" is OK but "foo" is an error.
33785   #
33786   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33787   # It is also a way to make sure we got the proper file name for the real test later on.
33788   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33789   if test "x$test_shortpath" = x; then
33790     # Short path failed, file does not exist as specified.
33791     # Try adding .exe or .cmd
33792     if test -f "${new_path}.exe"; then
33793       input_to_shortpath="${new_path}.exe"
33794     elif test -f "${new_path}.cmd"; then
33795       input_to_shortpath="${new_path}.cmd"
33796     else
33797       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
33798 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
33799       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33800 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33801       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33802     fi
33803   else
33804     input_to_shortpath="$new_path"
33805   fi
33806 
33807   # Call helper function which possibly converts this using DOS-style short mode.
33808   # If so, the updated path is stored in $new_path.
33809   new_path="$input_to_shortpath"
33810 
33811   input_path="$input_to_shortpath"
33812   # Check if we need to convert this using DOS-style short mode. If the path
33813   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33814   # take no chances and rewrite it.
33815   # Note: m4 eats our [], so we need to use [ and ] instead.
33816   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33817   if test "x$has_forbidden_chars" != x; then
33818     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33819     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33820     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33821     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33822       # Going to short mode and back again did indeed matter. Since short mode is
33823       # case insensitive, let's make it lowercase to improve readability.
33824       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33825       # Now convert it back to Unix-stile (cygpath)
33826       input_path=`$CYGPATH -u "$shortmode_path"`
33827       new_path="$input_path"
33828     fi
33829   fi
33830 
33831   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33832   if test "x$test_cygdrive_prefix" = x; then
33833     # As a simple fix, exclude /usr/bin since it's not a real path.
33834     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33835       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33836       # a path prefixed by /cygdrive for fixpath to work.
33837       new_path="$CYGWIN_ROOT_PATH$input_path"
33838     fi
33839   fi
33840 
33841   # remove trailing .exe if any
33842   new_path="${new_path/%.exe/}"
33843 
33844   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33845 
33846   # First separate the path from the arguments. This will split at the first
33847   # space.
33848   complete="$MT"
33849   path="${complete%% *}"
33850   tmp="$complete EOL"
33851   arguments="${tmp#* }"
33852 
33853   # Input might be given as Windows format, start by converting to
33854   # unix format.
33855   new_path="$path"
33856 
33857   windows_path="$new_path"
33858   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33859     unix_path=`$CYGPATH -u "$windows_path"`
33860     new_path="$unix_path"
33861   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33862     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33863     new_path="$unix_path"
33864   fi
33865 
33866 
33867   # Now try to locate executable using which
33868   new_path=`$WHICH "$new_path" 2> /dev/null`
33869 
33870   if test "x$new_path" = x; then
33871     # Oops. Which didn't find the executable.
33872     # The splitting of arguments from the executable at a space might have been incorrect,
33873     # since paths with space are more likely in Windows. Give it another try with the whole
33874     # argument.
33875     path="$complete"
33876     arguments="EOL"
33877     new_path="$path"
33878 
33879   windows_path="$new_path"
33880   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33881     unix_path=`$CYGPATH -u "$windows_path"`
33882     new_path="$unix_path"
33883   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33884     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33885     new_path="$unix_path"
33886   fi
33887 
33888 
33889     new_path=`$WHICH "$new_path" 2> /dev/null`
33890 
33891     if test "x$new_path" = x; then
33892       # It's still not found. Now this is an unrecoverable error.
33893       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33894 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33895       has_space=`$ECHO "$complete" | $GREP " "`
33896       if test "x$has_space" != x; then
33897         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33898 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33899       fi
33900       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33901     fi
33902   fi
33903 
33904   # Now new_path has a complete unix path to the binary
33905   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33906     # Keep paths in /bin as-is, but remove trailing .exe if any
33907     new_path="${new_path/%.exe/}"
33908     # Do not save /bin paths to all_fixpath_prefixes!
33909   else
33910     # Not in mixed or Windows style, start by that.
33911     new_path=`cmd //c echo $new_path`
33912 
33913   input_path="$new_path"
33914   # Check if we need to convert this using DOS-style short mode. If the path
33915   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33916   # take no chances and rewrite it.
33917   # Note: m4 eats our [], so we need to use [ and ] instead.
33918   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33919   if test "x$has_forbidden_chars" != x; then
33920     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33921     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33922   fi
33923 
33924     # Output is in $new_path
33925 
33926   windows_path="$new_path"
33927   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33928     unix_path=`$CYGPATH -u "$windows_path"`
33929     new_path="$unix_path"
33930   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33931     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33932     new_path="$unix_path"
33933   fi
33934 
33935     # remove trailing .exe if any
33936     new_path="${new_path/%.exe/}"
33937 
33938     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33939     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33940   fi
33941 
33942   else
33943     # We're on a posix platform. Hooray! :)
33944     # First separate the path from the arguments. This will split at the first
33945     # space.
33946     complete="$MT"
33947     path="${complete%% *}"
33948     tmp="$complete EOL"
33949     arguments="${tmp#* }"
33950 
33951     # Cannot rely on the command "which" here since it doesn't always work.
33952     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33953     if test -z "$is_absolute_path"; then
33954       # Path to executable is not absolute. Find it.
33955       IFS_save="$IFS"
33956       IFS=:
33957       for p in $PATH; do
33958         if test -f "$p/$path" && test -x "$p/$path"; then
33959           new_path="$p/$path"
33960           break
33961         fi
33962       done
33963       IFS="$IFS_save"
33964     else
33965       # This is an absolute path, we can use it without further modifications.
33966       new_path="$path"
33967     fi
33968 
33969     if test "x$new_path" = x; then
33970       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33971 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33972       has_space=`$ECHO "$complete" | $GREP " "`
33973       if test "x$has_space" != x; then
33974         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33975 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33976       fi
33977       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33978     fi
33979   fi
33980 
33981   # Now join together the path and the arguments once again
33982   if test "x$arguments" != xEOL; then
33983     new_complete="$new_path ${arguments% *}"
33984   else
33985     new_complete="$new_path"
33986   fi
33987 
33988   if test "x$complete" != "x$new_complete"; then
33989     MT="$new_complete"
33990     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
33991 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
33992   fi
33993 
33994     # Setup the resource compiler (RC)
33995     # Extract the first word of "rc", so it can be a program name with args.
33996 set dummy rc; ac_word=$2
33997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33998 $as_echo_n "checking for $ac_word... " >&6; }
33999 if ${ac_cv_prog_RC+:} false; then :
34000   $as_echo_n "(cached) " >&6
34001 else
34002   if test -n "$RC"; then
34003   ac_cv_prog_RC="$RC" # Let the user override the test.
34004 else
34005   ac_prog_rejected=no
34006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34007 for as_dir in $PATH
34008 do
34009   IFS=$as_save_IFS
34010   test -z "$as_dir" && as_dir=.
34011     for ac_exec_ext in '' $ac_executable_extensions; do
34012   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34013     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
34014        ac_prog_rejected=yes
34015        continue
34016      fi
34017     ac_cv_prog_RC="rc"
34018     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34019     break 2
34020   fi
34021 done
34022   done
34023 IFS=$as_save_IFS
34024 
34025 if test $ac_prog_rejected = yes; then
34026   # We found a bogon in the path, so make sure we never use it.
34027   set dummy $ac_cv_prog_RC
34028   shift
34029   if test $# != 0; then
34030     # We chose a different compiler from the bogus one.
34031     # However, it has the same basename, so the bogon will be chosen
34032     # first if we set RC to just the basename; use the full file name.
34033     shift
34034     ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34035   fi
34036 fi
34037 fi
34038 fi
34039 RC=$ac_cv_prog_RC
34040 if test -n "$RC"; then
34041   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34042 $as_echo "$RC" >&6; }
34043 else
34044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34045 $as_echo "no" >&6; }
34046 fi
34047 
34048 
34049 
34050   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34051 
34052   # First separate the path from the arguments. This will split at the first
34053   # space.
34054   complete="$RC"
34055   path="${complete%% *}"
34056   tmp="$complete EOL"
34057   arguments="${tmp#* }"
34058 
34059   # Input might be given as Windows format, start by converting to
34060   # unix format.
34061   new_path=`$CYGPATH -u "$path"`
34062 
34063   # Now try to locate executable using which
34064   new_path=`$WHICH "$new_path" 2> /dev/null`
34065   # bat and cmd files are not always considered executable in cygwin causing which
34066   # to not find them
34067   if test "x$new_path" = x \
34068       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34069       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34070     new_path=`$CYGPATH -u "$path"`
34071   fi
34072   if test "x$new_path" = x; then
34073     # Oops. Which didn't find the executable.
34074     # The splitting of arguments from the executable at a space might have been incorrect,
34075     # since paths with space are more likely in Windows. Give it another try with the whole
34076     # argument.
34077     path="$complete"
34078     arguments="EOL"
34079     new_path=`$CYGPATH -u "$path"`
34080     new_path=`$WHICH "$new_path" 2> /dev/null`
34081     # bat and cmd files are not always considered executable in cygwin causing which
34082     # to not find them
34083     if test "x$new_path" = x \
34084         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34085         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34086       new_path=`$CYGPATH -u "$path"`
34087     fi
34088     if test "x$new_path" = x; then
34089       # It's still not found. Now this is an unrecoverable error.
34090       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34091 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34092       has_space=`$ECHO "$complete" | $GREP " "`
34093       if test "x$has_space" != x; then
34094         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34095 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34096       fi
34097       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34098     fi
34099   fi
34100 
34101   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34102   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34103   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34104   # "foo.exe" is OK but "foo" is an error.
34105   #
34106   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34107   # It is also a way to make sure we got the proper file name for the real test later on.
34108   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34109   if test "x$test_shortpath" = x; then
34110     # Short path failed, file does not exist as specified.
34111     # Try adding .exe or .cmd
34112     if test -f "${new_path}.exe"; then
34113       input_to_shortpath="${new_path}.exe"
34114     elif test -f "${new_path}.cmd"; then
34115       input_to_shortpath="${new_path}.cmd"
34116     else
34117       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34118 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34119       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34120 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34121       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34122     fi
34123   else
34124     input_to_shortpath="$new_path"
34125   fi
34126 
34127   # Call helper function which possibly converts this using DOS-style short mode.
34128   # If so, the updated path is stored in $new_path.
34129   new_path="$input_to_shortpath"
34130 
34131   input_path="$input_to_shortpath"
34132   # Check if we need to convert this using DOS-style short mode. If the path
34133   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34134   # take no chances and rewrite it.
34135   # Note: m4 eats our [], so we need to use [ and ] instead.
34136   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34137   if test "x$has_forbidden_chars" != x; then
34138     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34139     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34140     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34141     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34142       # Going to short mode and back again did indeed matter. Since short mode is
34143       # case insensitive, let's make it lowercase to improve readability.
34144       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34145       # Now convert it back to Unix-stile (cygpath)
34146       input_path=`$CYGPATH -u "$shortmode_path"`
34147       new_path="$input_path"
34148     fi
34149   fi
34150 
34151   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34152   if test "x$test_cygdrive_prefix" = x; then
34153     # As a simple fix, exclude /usr/bin since it's not a real path.
34154     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34155       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34156       # a path prefixed by /cygdrive for fixpath to work.
34157       new_path="$CYGWIN_ROOT_PATH$input_path"
34158     fi
34159   fi
34160 
34161   # remove trailing .exe if any
34162   new_path="${new_path/%.exe/}"
34163 
34164   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34165 
34166   # First separate the path from the arguments. This will split at the first
34167   # space.
34168   complete="$RC"
34169   path="${complete%% *}"
34170   tmp="$complete EOL"
34171   arguments="${tmp#* }"
34172 
34173   # Input might be given as Windows format, start by converting to
34174   # unix format.
34175   new_path="$path"
34176 
34177   windows_path="$new_path"
34178   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34179     unix_path=`$CYGPATH -u "$windows_path"`
34180     new_path="$unix_path"
34181   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34182     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34183     new_path="$unix_path"
34184   fi
34185 
34186 
34187   # Now try to locate executable using which
34188   new_path=`$WHICH "$new_path" 2> /dev/null`
34189 
34190   if test "x$new_path" = x; then
34191     # Oops. Which didn't find the executable.
34192     # The splitting of arguments from the executable at a space might have been incorrect,
34193     # since paths with space are more likely in Windows. Give it another try with the whole
34194     # argument.
34195     path="$complete"
34196     arguments="EOL"
34197     new_path="$path"
34198 
34199   windows_path="$new_path"
34200   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34201     unix_path=`$CYGPATH -u "$windows_path"`
34202     new_path="$unix_path"
34203   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34204     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34205     new_path="$unix_path"
34206   fi
34207 
34208 
34209     new_path=`$WHICH "$new_path" 2> /dev/null`
34210 
34211     if test "x$new_path" = x; then
34212       # It's still not found. Now this is an unrecoverable error.
34213       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34214 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34215       has_space=`$ECHO "$complete" | $GREP " "`
34216       if test "x$has_space" != x; then
34217         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34218 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34219       fi
34220       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34221     fi
34222   fi
34223 
34224   # Now new_path has a complete unix path to the binary
34225   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34226     # Keep paths in /bin as-is, but remove trailing .exe if any
34227     new_path="${new_path/%.exe/}"
34228     # Do not save /bin paths to all_fixpath_prefixes!
34229   else
34230     # Not in mixed or Windows style, start by that.
34231     new_path=`cmd //c echo $new_path`
34232 
34233   input_path="$new_path"
34234   # Check if we need to convert this using DOS-style short mode. If the path
34235   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34236   # take no chances and rewrite it.
34237   # Note: m4 eats our [], so we need to use [ and ] instead.
34238   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34239   if test "x$has_forbidden_chars" != x; then
34240     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34241     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34242   fi
34243 
34244     # Output is in $new_path
34245 
34246   windows_path="$new_path"
34247   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34248     unix_path=`$CYGPATH -u "$windows_path"`
34249     new_path="$unix_path"
34250   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34251     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34252     new_path="$unix_path"
34253   fi
34254 
34255     # remove trailing .exe if any
34256     new_path="${new_path/%.exe/}"
34257 
34258     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34259     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34260   fi
34261 
34262   else
34263     # We're on a posix platform. Hooray! :)
34264     # First separate the path from the arguments. This will split at the first
34265     # space.
34266     complete="$RC"
34267     path="${complete%% *}"
34268     tmp="$complete EOL"
34269     arguments="${tmp#* }"
34270 
34271     # Cannot rely on the command "which" here since it doesn't always work.
34272     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34273     if test -z "$is_absolute_path"; then
34274       # Path to executable is not absolute. Find it.
34275       IFS_save="$IFS"
34276       IFS=:
34277       for p in $PATH; do
34278         if test -f "$p/$path" && test -x "$p/$path"; then
34279           new_path="$p/$path"
34280           break
34281         fi
34282       done
34283       IFS="$IFS_save"
34284     else
34285       # This is an absolute path, we can use it without further modifications.
34286       new_path="$path"
34287     fi
34288 
34289     if test "x$new_path" = x; then
34290       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34291 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34292       has_space=`$ECHO "$complete" | $GREP " "`
34293       if test "x$has_space" != x; then
34294         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34295 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34296       fi
34297       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34298     fi
34299   fi
34300 
34301   # Now join together the path and the arguments once again
34302   if test "x$arguments" != xEOL; then
34303     new_complete="$new_path ${arguments% *}"
34304   else
34305     new_complete="$new_path"
34306   fi
34307 
34308   if test "x$complete" != "x$new_complete"; then
34309     RC="$new_complete"
34310     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34311 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34312   fi
34313 
34314     # Extract the first word of "dumpbin", so it can be a program name with args.
34315 set dummy dumpbin; ac_word=$2
34316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34317 $as_echo_n "checking for $ac_word... " >&6; }
34318 if ${ac_cv_prog_DUMPBIN+:} false; then :
34319   $as_echo_n "(cached) " >&6
34320 else
34321   if test -n "$DUMPBIN"; then
34322   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34323 else
34324 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34325 for as_dir in $PATH
34326 do
34327   IFS=$as_save_IFS
34328   test -z "$as_dir" && as_dir=.
34329     for ac_exec_ext in '' $ac_executable_extensions; do
34330   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34331     ac_cv_prog_DUMPBIN="dumpbin"
34332     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34333     break 2
34334   fi
34335 done
34336   done
34337 IFS=$as_save_IFS
34338 
34339 fi
34340 fi
34341 DUMPBIN=$ac_cv_prog_DUMPBIN
34342 if test -n "$DUMPBIN"; then
34343   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34344 $as_echo "$DUMPBIN" >&6; }
34345 else
34346   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34347 $as_echo "no" >&6; }
34348 fi
34349 
34350 
34351 
34352   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34353 
34354   # First separate the path from the arguments. This will split at the first
34355   # space.
34356   complete="$DUMPBIN"
34357   path="${complete%% *}"
34358   tmp="$complete EOL"
34359   arguments="${tmp#* }"
34360 
34361   # Input might be given as Windows format, start by converting to
34362   # unix format.
34363   new_path=`$CYGPATH -u "$path"`
34364 
34365   # Now try to locate executable using which
34366   new_path=`$WHICH "$new_path" 2> /dev/null`
34367   # bat and cmd files are not always considered executable in cygwin causing which
34368   # to not find them
34369   if test "x$new_path" = x \
34370       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34371       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34372     new_path=`$CYGPATH -u "$path"`
34373   fi
34374   if test "x$new_path" = x; then
34375     # Oops. Which didn't find the executable.
34376     # The splitting of arguments from the executable at a space might have been incorrect,
34377     # since paths with space are more likely in Windows. Give it another try with the whole
34378     # argument.
34379     path="$complete"
34380     arguments="EOL"
34381     new_path=`$CYGPATH -u "$path"`
34382     new_path=`$WHICH "$new_path" 2> /dev/null`
34383     # bat and cmd files are not always considered executable in cygwin causing which
34384     # to not find them
34385     if test "x$new_path" = x \
34386         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34387         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34388       new_path=`$CYGPATH -u "$path"`
34389     fi
34390     if test "x$new_path" = x; then
34391       # It's still not found. Now this is an unrecoverable error.
34392       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34393 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34394       has_space=`$ECHO "$complete" | $GREP " "`
34395       if test "x$has_space" != x; then
34396         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34397 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34398       fi
34399       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34400     fi
34401   fi
34402 
34403   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34404   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34405   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34406   # "foo.exe" is OK but "foo" is an error.
34407   #
34408   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34409   # It is also a way to make sure we got the proper file name for the real test later on.
34410   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34411   if test "x$test_shortpath" = x; then
34412     # Short path failed, file does not exist as specified.
34413     # Try adding .exe or .cmd
34414     if test -f "${new_path}.exe"; then
34415       input_to_shortpath="${new_path}.exe"
34416     elif test -f "${new_path}.cmd"; then
34417       input_to_shortpath="${new_path}.cmd"
34418     else
34419       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34420 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34421       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34422 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34423       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34424     fi
34425   else
34426     input_to_shortpath="$new_path"
34427   fi
34428 
34429   # Call helper function which possibly converts this using DOS-style short mode.
34430   # If so, the updated path is stored in $new_path.
34431   new_path="$input_to_shortpath"
34432 
34433   input_path="$input_to_shortpath"
34434   # Check if we need to convert this using DOS-style short mode. If the path
34435   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34436   # take no chances and rewrite it.
34437   # Note: m4 eats our [], so we need to use [ and ] instead.
34438   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34439   if test "x$has_forbidden_chars" != x; then
34440     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34441     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34442     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34443     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34444       # Going to short mode and back again did indeed matter. Since short mode is
34445       # case insensitive, let's make it lowercase to improve readability.
34446       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34447       # Now convert it back to Unix-stile (cygpath)
34448       input_path=`$CYGPATH -u "$shortmode_path"`
34449       new_path="$input_path"
34450     fi
34451   fi
34452 
34453   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34454   if test "x$test_cygdrive_prefix" = x; then
34455     # As a simple fix, exclude /usr/bin since it's not a real path.
34456     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34457       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34458       # a path prefixed by /cygdrive for fixpath to work.
34459       new_path="$CYGWIN_ROOT_PATH$input_path"
34460     fi
34461   fi
34462 
34463   # remove trailing .exe if any
34464   new_path="${new_path/%.exe/}"
34465 
34466   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34467 
34468   # First separate the path from the arguments. This will split at the first
34469   # space.
34470   complete="$DUMPBIN"
34471   path="${complete%% *}"
34472   tmp="$complete EOL"
34473   arguments="${tmp#* }"
34474 
34475   # Input might be given as Windows format, start by converting to
34476   # unix format.
34477   new_path="$path"
34478 
34479   windows_path="$new_path"
34480   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34481     unix_path=`$CYGPATH -u "$windows_path"`
34482     new_path="$unix_path"
34483   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34484     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34485     new_path="$unix_path"
34486   fi
34487 
34488 
34489   # Now try to locate executable using which
34490   new_path=`$WHICH "$new_path" 2> /dev/null`
34491 
34492   if test "x$new_path" = x; then
34493     # Oops. Which didn't find the executable.
34494     # The splitting of arguments from the executable at a space might have been incorrect,
34495     # since paths with space are more likely in Windows. Give it another try with the whole
34496     # argument.
34497     path="$complete"
34498     arguments="EOL"
34499     new_path="$path"
34500 
34501   windows_path="$new_path"
34502   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34503     unix_path=`$CYGPATH -u "$windows_path"`
34504     new_path="$unix_path"
34505   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34506     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34507     new_path="$unix_path"
34508   fi
34509 
34510 
34511     new_path=`$WHICH "$new_path" 2> /dev/null`
34512 
34513     if test "x$new_path" = x; then
34514       # It's still not found. Now this is an unrecoverable error.
34515       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34516 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34517       has_space=`$ECHO "$complete" | $GREP " "`
34518       if test "x$has_space" != x; then
34519         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34520 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34521       fi
34522       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34523     fi
34524   fi
34525 
34526   # Now new_path has a complete unix path to the binary
34527   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34528     # Keep paths in /bin as-is, but remove trailing .exe if any
34529     new_path="${new_path/%.exe/}"
34530     # Do not save /bin paths to all_fixpath_prefixes!
34531   else
34532     # Not in mixed or Windows style, start by that.
34533     new_path=`cmd //c echo $new_path`
34534 
34535   input_path="$new_path"
34536   # Check if we need to convert this using DOS-style short mode. If the path
34537   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34538   # take no chances and rewrite it.
34539   # Note: m4 eats our [], so we need to use [ and ] instead.
34540   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34541   if test "x$has_forbidden_chars" != x; then
34542     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34543     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34544   fi
34545 
34546     # Output is in $new_path
34547 
34548   windows_path="$new_path"
34549   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34550     unix_path=`$CYGPATH -u "$windows_path"`
34551     new_path="$unix_path"
34552   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34553     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34554     new_path="$unix_path"
34555   fi
34556 
34557     # remove trailing .exe if any
34558     new_path="${new_path/%.exe/}"
34559 
34560     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34561     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34562   fi
34563 
34564   else
34565     # We're on a posix platform. Hooray! :)
34566     # First separate the path from the arguments. This will split at the first
34567     # space.
34568     complete="$DUMPBIN"
34569     path="${complete%% *}"
34570     tmp="$complete EOL"
34571     arguments="${tmp#* }"
34572 
34573     # Cannot rely on the command "which" here since it doesn't always work.
34574     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34575     if test -z "$is_absolute_path"; then
34576       # Path to executable is not absolute. Find it.
34577       IFS_save="$IFS"
34578       IFS=:
34579       for p in $PATH; do
34580         if test -f "$p/$path" && test -x "$p/$path"; then
34581           new_path="$p/$path"
34582           break
34583         fi
34584       done
34585       IFS="$IFS_save"
34586     else
34587       # This is an absolute path, we can use it without further modifications.
34588       new_path="$path"
34589     fi
34590 
34591     if test "x$new_path" = x; then
34592       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34593 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34594       has_space=`$ECHO "$complete" | $GREP " "`
34595       if test "x$has_space" != x; then
34596         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34597 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34598       fi
34599       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34600     fi
34601   fi
34602 
34603   # Now join together the path and the arguments once again
34604   if test "x$arguments" != xEOL; then
34605     new_complete="$new_path ${arguments% *}"
34606   else
34607     new_complete="$new_path"
34608   fi
34609 
34610   if test "x$complete" != "x$new_complete"; then
34611     DUMPBIN="$new_complete"
34612     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
34613 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
34614   fi
34615 
34616   fi
34617 
34618   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
34619 
34620 
34621   # Publish this variable in the help.
34622 
34623 
34624   if test "x$STRIP" = x; then
34625     # The variable is not set by user, try to locate tool using the code snippet
34626     for ac_prog in strip
34627 do
34628   # Extract the first word of "$ac_prog", so it can be a program name with args.
34629 set dummy $ac_prog; ac_word=$2
34630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34631 $as_echo_n "checking for $ac_word... " >&6; }
34632 if ${ac_cv_path_STRIP+:} false; then :
34633   $as_echo_n "(cached) " >&6
34634 else
34635   case $STRIP in
34636   [\\/]* | ?:[\\/]*)
34637   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34638   ;;
34639   *)
34640   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34641 for as_dir in $PATH
34642 do
34643   IFS=$as_save_IFS
34644   test -z "$as_dir" && as_dir=.
34645     for ac_exec_ext in '' $ac_executable_extensions; do
34646   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34647     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34648     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34649     break 2
34650   fi
34651 done
34652   done
34653 IFS=$as_save_IFS
34654 
34655   ;;
34656 esac
34657 fi
34658 STRIP=$ac_cv_path_STRIP
34659 if test -n "$STRIP"; then
34660   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34661 $as_echo "$STRIP" >&6; }
34662 else
34663   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34664 $as_echo "no" >&6; }
34665 fi
34666 
34667 
34668   test -n "$STRIP" && break
34669 done
34670 
34671   else
34672     # The variable is set, but is it from the command line or the environment?
34673 
34674     # Try to remove the string !STRIP! from our list.
34675     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
34676     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
34677       # If it failed, the variable was not from the command line. Ignore it,
34678       # but warn the user (except for BASH, which is always set by the calling BASH).
34679       if test "xSTRIP" != xBASH; then
34680         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
34681 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
34682       fi
34683       # Try to locate tool using the code snippet
34684       for ac_prog in strip
34685 do
34686   # Extract the first word of "$ac_prog", so it can be a program name with args.
34687 set dummy $ac_prog; ac_word=$2
34688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34689 $as_echo_n "checking for $ac_word... " >&6; }
34690 if ${ac_cv_path_STRIP+:} false; then :
34691   $as_echo_n "(cached) " >&6
34692 else
34693   case $STRIP in
34694   [\\/]* | ?:[\\/]*)
34695   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34696   ;;
34697   *)
34698   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34699 for as_dir in $PATH
34700 do
34701   IFS=$as_save_IFS
34702   test -z "$as_dir" && as_dir=.
34703     for ac_exec_ext in '' $ac_executable_extensions; do
34704   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34705     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34706     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34707     break 2
34708   fi
34709 done
34710   done
34711 IFS=$as_save_IFS
34712 
34713   ;;
34714 esac
34715 fi
34716 STRIP=$ac_cv_path_STRIP
34717 if test -n "$STRIP"; then
34718   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34719 $as_echo "$STRIP" >&6; }
34720 else
34721   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34722 $as_echo "no" >&6; }
34723 fi
34724 
34725 
34726   test -n "$STRIP" && break
34727 done
34728 
34729     else
34730       # If it succeeded, then it was overridden by the user. We will use it
34731       # for the tool.
34732 
34733       # First remove it from the list of overridden variables, so we can test
34734       # for unknown variables in the end.
34735       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
34736 
34737       # Check if the provided tool contains a complete path.
34738       tool_specified="$STRIP"
34739       tool_basename="${tool_specified##*/}"
34740       if test "x$tool_basename" = "x$tool_specified"; then
34741         # A command without a complete path is provided, search $PATH.
34742         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
34743 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
34744         # Extract the first word of "$tool_basename", so it can be a program name with args.
34745 set dummy $tool_basename; ac_word=$2
34746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34747 $as_echo_n "checking for $ac_word... " >&6; }
34748 if ${ac_cv_path_STRIP+:} false; then :
34749   $as_echo_n "(cached) " >&6
34750 else
34751   case $STRIP in
34752   [\\/]* | ?:[\\/]*)
34753   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34754   ;;
34755   *)
34756   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34757 for as_dir in $PATH
34758 do
34759   IFS=$as_save_IFS
34760   test -z "$as_dir" && as_dir=.
34761     for ac_exec_ext in '' $ac_executable_extensions; do
34762   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34763     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34764     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34765     break 2
34766   fi
34767 done
34768   done
34769 IFS=$as_save_IFS
34770 
34771   ;;
34772 esac
34773 fi
34774 STRIP=$ac_cv_path_STRIP
34775 if test -n "$STRIP"; then
34776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34777 $as_echo "$STRIP" >&6; }
34778 else
34779   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34780 $as_echo "no" >&6; }
34781 fi
34782 
34783 
34784         if test "x$STRIP" = x; then
34785           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
34786         fi
34787       else
34788         # Otherwise we believe it is a complete path. Use it as it is.
34789         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
34790 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
34791         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
34792 $as_echo_n "checking for STRIP... " >&6; }
34793         if test ! -x "$tool_specified"; then
34794           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
34795 $as_echo "not found" >&6; }
34796           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
34797         fi
34798         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
34799 $as_echo "$tool_specified" >&6; }
34800       fi
34801     fi
34802   fi
34803 
34804 
34805 
34806   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34807 
34808   # First separate the path from the arguments. This will split at the first
34809   # space.
34810   complete="$STRIP"
34811   path="${complete%% *}"
34812   tmp="$complete EOL"
34813   arguments="${tmp#* }"
34814 
34815   # Input might be given as Windows format, start by converting to
34816   # unix format.
34817   new_path=`$CYGPATH -u "$path"`
34818 
34819   # Now try to locate executable using which
34820   new_path=`$WHICH "$new_path" 2> /dev/null`
34821   # bat and cmd files are not always considered executable in cygwin causing which
34822   # to not find them
34823   if test "x$new_path" = x \
34824       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34825       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34826     new_path=`$CYGPATH -u "$path"`
34827   fi
34828   if test "x$new_path" = x; then
34829     # Oops. Which didn't find the executable.
34830     # The splitting of arguments from the executable at a space might have been incorrect,
34831     # since paths with space are more likely in Windows. Give it another try with the whole
34832     # argument.
34833     path="$complete"
34834     arguments="EOL"
34835     new_path=`$CYGPATH -u "$path"`
34836     new_path=`$WHICH "$new_path" 2> /dev/null`
34837     # bat and cmd files are not always considered executable in cygwin causing which
34838     # to not find them
34839     if test "x$new_path" = x \
34840         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34841         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34842       new_path=`$CYGPATH -u "$path"`
34843     fi
34844     if test "x$new_path" = x; then
34845       # It's still not found. Now this is an unrecoverable error.
34846       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34847 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34848       has_space=`$ECHO "$complete" | $GREP " "`
34849       if test "x$has_space" != x; then
34850         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34851 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34852       fi
34853       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34854     fi
34855   fi
34856 
34857   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34858   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34859   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34860   # "foo.exe" is OK but "foo" is an error.
34861   #
34862   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34863   # It is also a way to make sure we got the proper file name for the real test later on.
34864   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34865   if test "x$test_shortpath" = x; then
34866     # Short path failed, file does not exist as specified.
34867     # Try adding .exe or .cmd
34868     if test -f "${new_path}.exe"; then
34869       input_to_shortpath="${new_path}.exe"
34870     elif test -f "${new_path}.cmd"; then
34871       input_to_shortpath="${new_path}.cmd"
34872     else
34873       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
34874 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
34875       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34876 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34877       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34878     fi
34879   else
34880     input_to_shortpath="$new_path"
34881   fi
34882 
34883   # Call helper function which possibly converts this using DOS-style short mode.
34884   # If so, the updated path is stored in $new_path.
34885   new_path="$input_to_shortpath"
34886 
34887   input_path="$input_to_shortpath"
34888   # Check if we need to convert this using DOS-style short mode. If the path
34889   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34890   # take no chances and rewrite it.
34891   # Note: m4 eats our [], so we need to use [ and ] instead.
34892   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34893   if test "x$has_forbidden_chars" != x; then
34894     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34895     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34896     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34897     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34898       # Going to short mode and back again did indeed matter. Since short mode is
34899       # case insensitive, let's make it lowercase to improve readability.
34900       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34901       # Now convert it back to Unix-stile (cygpath)
34902       input_path=`$CYGPATH -u "$shortmode_path"`
34903       new_path="$input_path"
34904     fi
34905   fi
34906 
34907   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34908   if test "x$test_cygdrive_prefix" = x; then
34909     # As a simple fix, exclude /usr/bin since it's not a real path.
34910     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34911       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34912       # a path prefixed by /cygdrive for fixpath to work.
34913       new_path="$CYGWIN_ROOT_PATH$input_path"
34914     fi
34915   fi
34916 
34917   # remove trailing .exe if any
34918   new_path="${new_path/%.exe/}"
34919 
34920   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34921 
34922   # First separate the path from the arguments. This will split at the first
34923   # space.
34924   complete="$STRIP"
34925   path="${complete%% *}"
34926   tmp="$complete EOL"
34927   arguments="${tmp#* }"
34928 
34929   # Input might be given as Windows format, start by converting to
34930   # unix format.
34931   new_path="$path"
34932 
34933   windows_path="$new_path"
34934   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34935     unix_path=`$CYGPATH -u "$windows_path"`
34936     new_path="$unix_path"
34937   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34938     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34939     new_path="$unix_path"
34940   fi
34941 
34942 
34943   # Now try to locate executable using which
34944   new_path=`$WHICH "$new_path" 2> /dev/null`
34945 
34946   if test "x$new_path" = x; then
34947     # Oops. Which didn't find the executable.
34948     # The splitting of arguments from the executable at a space might have been incorrect,
34949     # since paths with space are more likely in Windows. Give it another try with the whole
34950     # argument.
34951     path="$complete"
34952     arguments="EOL"
34953     new_path="$path"
34954 
34955   windows_path="$new_path"
34956   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34957     unix_path=`$CYGPATH -u "$windows_path"`
34958     new_path="$unix_path"
34959   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34960     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34961     new_path="$unix_path"
34962   fi
34963 
34964 
34965     new_path=`$WHICH "$new_path" 2> /dev/null`
34966 
34967     if test "x$new_path" = x; then
34968       # It's still not found. Now this is an unrecoverable error.
34969       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34970 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34971       has_space=`$ECHO "$complete" | $GREP " "`
34972       if test "x$has_space" != x; then
34973         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34974 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34975       fi
34976       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34977     fi
34978   fi
34979 
34980   # Now new_path has a complete unix path to the binary
34981   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34982     # Keep paths in /bin as-is, but remove trailing .exe if any
34983     new_path="${new_path/%.exe/}"
34984     # Do not save /bin paths to all_fixpath_prefixes!
34985   else
34986     # Not in mixed or Windows style, start by that.
34987     new_path=`cmd //c echo $new_path`
34988 
34989   input_path="$new_path"
34990   # Check if we need to convert this using DOS-style short mode. If the path
34991   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34992   # take no chances and rewrite it.
34993   # Note: m4 eats our [], so we need to use [ and ] instead.
34994   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34995   if test "x$has_forbidden_chars" != x; then
34996     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34997     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34998   fi
34999 
35000     # Output is in $new_path
35001 
35002   windows_path="$new_path"
35003   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35004     unix_path=`$CYGPATH -u "$windows_path"`
35005     new_path="$unix_path"
35006   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35007     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35008     new_path="$unix_path"
35009   fi
35010 
35011     # remove trailing .exe if any
35012     new_path="${new_path/%.exe/}"
35013 
35014     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35015     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35016   fi
35017 
35018   else
35019     # We're on a posix platform. Hooray! :)
35020     # First separate the path from the arguments. This will split at the first
35021     # space.
35022     complete="$STRIP"
35023     path="${complete%% *}"
35024     tmp="$complete EOL"
35025     arguments="${tmp#* }"
35026 
35027     # Cannot rely on the command "which" here since it doesn't always work.
35028     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35029     if test -z "$is_absolute_path"; then
35030       # Path to executable is not absolute. Find it.
35031       IFS_save="$IFS"
35032       IFS=:
35033       for p in $PATH; do
35034         if test -f "$p/$path" && test -x "$p/$path"; then
35035           new_path="$p/$path"
35036           break
35037         fi
35038       done
35039       IFS="$IFS_save"
35040     else
35041       # This is an absolute path, we can use it without further modifications.
35042       new_path="$path"
35043     fi
35044 
35045     if test "x$new_path" = x; then
35046       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35047 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35048       has_space=`$ECHO "$complete" | $GREP " "`
35049       if test "x$has_space" != x; then
35050         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35051 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35052       fi
35053       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35054     fi
35055   fi
35056 
35057   # Now join together the path and the arguments once again
35058   if test "x$arguments" != xEOL; then
35059     new_complete="$new_path ${arguments% *}"
35060   else
35061     new_complete="$new_path"
35062   fi
35063 
35064   if test "x$complete" != "x$new_complete"; then
35065     STRIP="$new_complete"
35066     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
35067 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
35068   fi
35069 
35070 
35071 
35072   # Publish this variable in the help.
35073 
35074 
35075   if test "x$NM" = x; then
35076     # The variable is not set by user, try to locate tool using the code snippet
35077     for ac_prog in nm
35078 do
35079   # Extract the first word of "$ac_prog", so it can be a program name with args.
35080 set dummy $ac_prog; ac_word=$2
35081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35082 $as_echo_n "checking for $ac_word... " >&6; }
35083 if ${ac_cv_path_NM+:} false; then :
35084   $as_echo_n "(cached) " >&6
35085 else
35086   case $NM in
35087   [\\/]* | ?:[\\/]*)
35088   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35089   ;;
35090   *)
35091   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35092 for as_dir in $PATH
35093 do
35094   IFS=$as_save_IFS
35095   test -z "$as_dir" && as_dir=.
35096     for ac_exec_ext in '' $ac_executable_extensions; do
35097   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35098     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35099     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35100     break 2
35101   fi
35102 done
35103   done
35104 IFS=$as_save_IFS
35105 
35106   ;;
35107 esac
35108 fi
35109 NM=$ac_cv_path_NM
35110 if test -n "$NM"; then
35111   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35112 $as_echo "$NM" >&6; }
35113 else
35114   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35115 $as_echo "no" >&6; }
35116 fi
35117 
35118 
35119   test -n "$NM" && break
35120 done
35121 
35122   else
35123     # The variable is set, but is it from the command line or the environment?
35124 
35125     # Try to remove the string !NM! from our list.
35126     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
35127     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35128       # If it failed, the variable was not from the command line. Ignore it,
35129       # but warn the user (except for BASH, which is always set by the calling BASH).
35130       if test "xNM" != xBASH; then
35131         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
35132 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
35133       fi
35134       # Try to locate tool using the code snippet
35135       for ac_prog in nm
35136 do
35137   # Extract the first word of "$ac_prog", so it can be a program name with args.
35138 set dummy $ac_prog; ac_word=$2
35139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35140 $as_echo_n "checking for $ac_word... " >&6; }
35141 if ${ac_cv_path_NM+:} false; then :
35142   $as_echo_n "(cached) " >&6
35143 else
35144   case $NM in
35145   [\\/]* | ?:[\\/]*)
35146   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35147   ;;
35148   *)
35149   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35150 for as_dir in $PATH
35151 do
35152   IFS=$as_save_IFS
35153   test -z "$as_dir" && as_dir=.
35154     for ac_exec_ext in '' $ac_executable_extensions; do
35155   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35156     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35157     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35158     break 2
35159   fi
35160 done
35161   done
35162 IFS=$as_save_IFS
35163 
35164   ;;
35165 esac
35166 fi
35167 NM=$ac_cv_path_NM
35168 if test -n "$NM"; then
35169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35170 $as_echo "$NM" >&6; }
35171 else
35172   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35173 $as_echo "no" >&6; }
35174 fi
35175 
35176 
35177   test -n "$NM" && break
35178 done
35179 
35180     else
35181       # If it succeeded, then it was overridden by the user. We will use it
35182       # for the tool.
35183 
35184       # First remove it from the list of overridden variables, so we can test
35185       # for unknown variables in the end.
35186       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35187 
35188       # Check if the provided tool contains a complete path.
35189       tool_specified="$NM"
35190       tool_basename="${tool_specified##*/}"
35191       if test "x$tool_basename" = "x$tool_specified"; then
35192         # A command without a complete path is provided, search $PATH.
35193         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
35194 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
35195         # Extract the first word of "$tool_basename", so it can be a program name with args.
35196 set dummy $tool_basename; ac_word=$2
35197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35198 $as_echo_n "checking for $ac_word... " >&6; }
35199 if ${ac_cv_path_NM+:} false; then :
35200   $as_echo_n "(cached) " >&6
35201 else
35202   case $NM in
35203   [\\/]* | ?:[\\/]*)
35204   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35205   ;;
35206   *)
35207   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35208 for as_dir in $PATH
35209 do
35210   IFS=$as_save_IFS
35211   test -z "$as_dir" && as_dir=.
35212     for ac_exec_ext in '' $ac_executable_extensions; do
35213   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35214     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35215     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35216     break 2
35217   fi
35218 done
35219   done
35220 IFS=$as_save_IFS
35221 
35222   ;;
35223 esac
35224 fi
35225 NM=$ac_cv_path_NM
35226 if test -n "$NM"; then
35227   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35228 $as_echo "$NM" >&6; }
35229 else
35230   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35231 $as_echo "no" >&6; }
35232 fi
35233 
35234 
35235         if test "x$NM" = x; then
35236           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35237         fi
35238       else
35239         # Otherwise we believe it is a complete path. Use it as it is.
35240         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
35241 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
35242         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
35243 $as_echo_n "checking for NM... " >&6; }
35244         if test ! -x "$tool_specified"; then
35245           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35246 $as_echo "not found" >&6; }
35247           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
35248         fi
35249         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35250 $as_echo "$tool_specified" >&6; }
35251       fi
35252     fi
35253   fi
35254 
35255 
35256 
35257   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35258 
35259   # First separate the path from the arguments. This will split at the first
35260   # space.
35261   complete="$NM"
35262   path="${complete%% *}"
35263   tmp="$complete EOL"
35264   arguments="${tmp#* }"
35265 
35266   # Input might be given as Windows format, start by converting to
35267   # unix format.
35268   new_path=`$CYGPATH -u "$path"`
35269 
35270   # Now try to locate executable using which
35271   new_path=`$WHICH "$new_path" 2> /dev/null`
35272   # bat and cmd files are not always considered executable in cygwin causing which
35273   # to not find them
35274   if test "x$new_path" = x \
35275       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35276       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35277     new_path=`$CYGPATH -u "$path"`
35278   fi
35279   if test "x$new_path" = x; then
35280     # Oops. Which didn't find the executable.
35281     # The splitting of arguments from the executable at a space might have been incorrect,
35282     # since paths with space are more likely in Windows. Give it another try with the whole
35283     # argument.
35284     path="$complete"
35285     arguments="EOL"
35286     new_path=`$CYGPATH -u "$path"`
35287     new_path=`$WHICH "$new_path" 2> /dev/null`
35288     # bat and cmd files are not always considered executable in cygwin causing which
35289     # to not find them
35290     if test "x$new_path" = x \
35291         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35292         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35293       new_path=`$CYGPATH -u "$path"`
35294     fi
35295     if test "x$new_path" = x; then
35296       # It's still not found. Now this is an unrecoverable error.
35297       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35298 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35299       has_space=`$ECHO "$complete" | $GREP " "`
35300       if test "x$has_space" != x; then
35301         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35302 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35303       fi
35304       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35305     fi
35306   fi
35307 
35308   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35309   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35310   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35311   # "foo.exe" is OK but "foo" is an error.
35312   #
35313   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35314   # It is also a way to make sure we got the proper file name for the real test later on.
35315   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35316   if test "x$test_shortpath" = x; then
35317     # Short path failed, file does not exist as specified.
35318     # Try adding .exe or .cmd
35319     if test -f "${new_path}.exe"; then
35320       input_to_shortpath="${new_path}.exe"
35321     elif test -f "${new_path}.cmd"; then
35322       input_to_shortpath="${new_path}.cmd"
35323     else
35324       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
35325 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
35326       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35327 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35328       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35329     fi
35330   else
35331     input_to_shortpath="$new_path"
35332   fi
35333 
35334   # Call helper function which possibly converts this using DOS-style short mode.
35335   # If so, the updated path is stored in $new_path.
35336   new_path="$input_to_shortpath"
35337 
35338   input_path="$input_to_shortpath"
35339   # Check if we need to convert this using DOS-style short mode. If the path
35340   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35341   # take no chances and rewrite it.
35342   # Note: m4 eats our [], so we need to use [ and ] instead.
35343   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35344   if test "x$has_forbidden_chars" != x; then
35345     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35346     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35347     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35348     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35349       # Going to short mode and back again did indeed matter. Since short mode is
35350       # case insensitive, let's make it lowercase to improve readability.
35351       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35352       # Now convert it back to Unix-stile (cygpath)
35353       input_path=`$CYGPATH -u "$shortmode_path"`
35354       new_path="$input_path"
35355     fi
35356   fi
35357 
35358   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35359   if test "x$test_cygdrive_prefix" = x; then
35360     # As a simple fix, exclude /usr/bin since it's not a real path.
35361     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35362       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35363       # a path prefixed by /cygdrive for fixpath to work.
35364       new_path="$CYGWIN_ROOT_PATH$input_path"
35365     fi
35366   fi
35367 
35368   # remove trailing .exe if any
35369   new_path="${new_path/%.exe/}"
35370 
35371   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35372 
35373   # First separate the path from the arguments. This will split at the first
35374   # space.
35375   complete="$NM"
35376   path="${complete%% *}"
35377   tmp="$complete EOL"
35378   arguments="${tmp#* }"
35379 
35380   # Input might be given as Windows format, start by converting to
35381   # unix format.
35382   new_path="$path"
35383 
35384   windows_path="$new_path"
35385   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35386     unix_path=`$CYGPATH -u "$windows_path"`
35387     new_path="$unix_path"
35388   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35389     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35390     new_path="$unix_path"
35391   fi
35392 
35393 
35394   # Now try to locate executable using which
35395   new_path=`$WHICH "$new_path" 2> /dev/null`
35396 
35397   if test "x$new_path" = x; then
35398     # Oops. Which didn't find the executable.
35399     # The splitting of arguments from the executable at a space might have been incorrect,
35400     # since paths with space are more likely in Windows. Give it another try with the whole
35401     # argument.
35402     path="$complete"
35403     arguments="EOL"
35404     new_path="$path"
35405 
35406   windows_path="$new_path"
35407   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35408     unix_path=`$CYGPATH -u "$windows_path"`
35409     new_path="$unix_path"
35410   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35411     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35412     new_path="$unix_path"
35413   fi
35414 
35415 
35416     new_path=`$WHICH "$new_path" 2> /dev/null`
35417 
35418     if test "x$new_path" = x; then
35419       # It's still not found. Now this is an unrecoverable error.
35420       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35421 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35422       has_space=`$ECHO "$complete" | $GREP " "`
35423       if test "x$has_space" != x; then
35424         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35425 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35426       fi
35427       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35428     fi
35429   fi
35430 
35431   # Now new_path has a complete unix path to the binary
35432   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35433     # Keep paths in /bin as-is, but remove trailing .exe if any
35434     new_path="${new_path/%.exe/}"
35435     # Do not save /bin paths to all_fixpath_prefixes!
35436   else
35437     # Not in mixed or Windows style, start by that.
35438     new_path=`cmd //c echo $new_path`
35439 
35440   input_path="$new_path"
35441   # Check if we need to convert this using DOS-style short mode. If the path
35442   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35443   # take no chances and rewrite it.
35444   # Note: m4 eats our [], so we need to use [ and ] instead.
35445   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35446   if test "x$has_forbidden_chars" != x; then
35447     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35448     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35449   fi
35450 
35451     # Output is in $new_path
35452 
35453   windows_path="$new_path"
35454   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35455     unix_path=`$CYGPATH -u "$windows_path"`
35456     new_path="$unix_path"
35457   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35458     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35459     new_path="$unix_path"
35460   fi
35461 
35462     # remove trailing .exe if any
35463     new_path="${new_path/%.exe/}"
35464 
35465     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35466     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35467   fi
35468 
35469   else
35470     # We're on a posix platform. Hooray! :)
35471     # First separate the path from the arguments. This will split at the first
35472     # space.
35473     complete="$NM"
35474     path="${complete%% *}"
35475     tmp="$complete EOL"
35476     arguments="${tmp#* }"
35477 
35478     # Cannot rely on the command "which" here since it doesn't always work.
35479     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35480     if test -z "$is_absolute_path"; then
35481       # Path to executable is not absolute. Find it.
35482       IFS_save="$IFS"
35483       IFS=:
35484       for p in $PATH; do
35485         if test -f "$p/$path" && test -x "$p/$path"; then
35486           new_path="$p/$path"
35487           break
35488         fi
35489       done
35490       IFS="$IFS_save"
35491     else
35492       # This is an absolute path, we can use it without further modifications.
35493       new_path="$path"
35494     fi
35495 
35496     if test "x$new_path" = x; then
35497       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35498 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35499       has_space=`$ECHO "$complete" | $GREP " "`
35500       if test "x$has_space" != x; then
35501         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35502 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35503       fi
35504       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35505     fi
35506   fi
35507 
35508   # Now join together the path and the arguments once again
35509   if test "x$arguments" != xEOL; then
35510     new_complete="$new_path ${arguments% *}"
35511   else
35512     new_complete="$new_path"
35513   fi
35514 
35515   if test "x$complete" != "x$new_complete"; then
35516     NM="$new_complete"
35517     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
35518 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
35519   fi
35520 
35521 
35522 
35523   # Publish this variable in the help.
35524 
35525 
35526   if test "x$GNM" = x; then
35527     # The variable is not set by user, try to locate tool using the code snippet
35528     for ac_prog in gnm
35529 do
35530   # Extract the first word of "$ac_prog", so it can be a program name with args.
35531 set dummy $ac_prog; ac_word=$2
35532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35533 $as_echo_n "checking for $ac_word... " >&6; }
35534 if ${ac_cv_path_GNM+:} false; then :
35535   $as_echo_n "(cached) " >&6
35536 else
35537   case $GNM in
35538   [\\/]* | ?:[\\/]*)
35539   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35540   ;;
35541   *)
35542   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35543 for as_dir in $PATH
35544 do
35545   IFS=$as_save_IFS
35546   test -z "$as_dir" && as_dir=.
35547     for ac_exec_ext in '' $ac_executable_extensions; do
35548   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35549     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35550     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35551     break 2
35552   fi
35553 done
35554   done
35555 IFS=$as_save_IFS
35556 
35557   ;;
35558 esac
35559 fi
35560 GNM=$ac_cv_path_GNM
35561 if test -n "$GNM"; then
35562   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35563 $as_echo "$GNM" >&6; }
35564 else
35565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35566 $as_echo "no" >&6; }
35567 fi
35568 
35569 
35570   test -n "$GNM" && break
35571 done
35572 
35573   else
35574     # The variable is set, but is it from the command line or the environment?
35575 
35576     # Try to remove the string !GNM! from our list.
35577     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
35578     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35579       # If it failed, the variable was not from the command line. Ignore it,
35580       # but warn the user (except for BASH, which is always set by the calling BASH).
35581       if test "xGNM" != xBASH; then
35582         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
35583 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
35584       fi
35585       # Try to locate tool using the code snippet
35586       for ac_prog in gnm
35587 do
35588   # Extract the first word of "$ac_prog", so it can be a program name with args.
35589 set dummy $ac_prog; ac_word=$2
35590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35591 $as_echo_n "checking for $ac_word... " >&6; }
35592 if ${ac_cv_path_GNM+:} false; then :
35593   $as_echo_n "(cached) " >&6
35594 else
35595   case $GNM in
35596   [\\/]* | ?:[\\/]*)
35597   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35598   ;;
35599   *)
35600   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35601 for as_dir in $PATH
35602 do
35603   IFS=$as_save_IFS
35604   test -z "$as_dir" && as_dir=.
35605     for ac_exec_ext in '' $ac_executable_extensions; do
35606   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35607     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35608     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35609     break 2
35610   fi
35611 done
35612   done
35613 IFS=$as_save_IFS
35614 
35615   ;;
35616 esac
35617 fi
35618 GNM=$ac_cv_path_GNM
35619 if test -n "$GNM"; then
35620   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35621 $as_echo "$GNM" >&6; }
35622 else
35623   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35624 $as_echo "no" >&6; }
35625 fi
35626 
35627 
35628   test -n "$GNM" && break
35629 done
35630 
35631     else
35632       # If it succeeded, then it was overridden by the user. We will use it
35633       # for the tool.
35634 
35635       # First remove it from the list of overridden variables, so we can test
35636       # for unknown variables in the end.
35637       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35638 
35639       # Check if the provided tool contains a complete path.
35640       tool_specified="$GNM"
35641       tool_basename="${tool_specified##*/}"
35642       if test "x$tool_basename" = "x$tool_specified"; then
35643         # A command without a complete path is provided, search $PATH.
35644         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
35645 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
35646         # Extract the first word of "$tool_basename", so it can be a program name with args.
35647 set dummy $tool_basename; ac_word=$2
35648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35649 $as_echo_n "checking for $ac_word... " >&6; }
35650 if ${ac_cv_path_GNM+:} false; then :
35651   $as_echo_n "(cached) " >&6
35652 else
35653   case $GNM in
35654   [\\/]* | ?:[\\/]*)
35655   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35656   ;;
35657   *)
35658   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35659 for as_dir in $PATH
35660 do
35661   IFS=$as_save_IFS
35662   test -z "$as_dir" && as_dir=.
35663     for ac_exec_ext in '' $ac_executable_extensions; do
35664   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35665     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35666     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35667     break 2
35668   fi
35669 done
35670   done
35671 IFS=$as_save_IFS
35672 
35673   ;;
35674 esac
35675 fi
35676 GNM=$ac_cv_path_GNM
35677 if test -n "$GNM"; then
35678   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35679 $as_echo "$GNM" >&6; }
35680 else
35681   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35682 $as_echo "no" >&6; }
35683 fi
35684 
35685 
35686         if test "x$GNM" = x; then
35687           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35688         fi
35689       else
35690         # Otherwise we believe it is a complete path. Use it as it is.
35691         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
35692 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
35693         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
35694 $as_echo_n "checking for GNM... " >&6; }
35695         if test ! -x "$tool_specified"; then
35696           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35697 $as_echo "not found" >&6; }
35698           as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
35699         fi
35700         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35701 $as_echo "$tool_specified" >&6; }
35702       fi
35703     fi
35704   fi
35705 
35706 
35707 
35708   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35709 
35710   # First separate the path from the arguments. This will split at the first
35711   # space.
35712   complete="$GNM"
35713   path="${complete%% *}"
35714   tmp="$complete EOL"
35715   arguments="${tmp#* }"
35716 
35717   # Input might be given as Windows format, start by converting to
35718   # unix format.
35719   new_path=`$CYGPATH -u "$path"`
35720 
35721   # Now try to locate executable using which
35722   new_path=`$WHICH "$new_path" 2> /dev/null`
35723   # bat and cmd files are not always considered executable in cygwin causing which
35724   # to not find them
35725   if test "x$new_path" = x \
35726       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35727       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35728     new_path=`$CYGPATH -u "$path"`
35729   fi
35730   if test "x$new_path" = x; then
35731     # Oops. Which didn't find the executable.
35732     # The splitting of arguments from the executable at a space might have been incorrect,
35733     # since paths with space are more likely in Windows. Give it another try with the whole
35734     # argument.
35735     path="$complete"
35736     arguments="EOL"
35737     new_path=`$CYGPATH -u "$path"`
35738     new_path=`$WHICH "$new_path" 2> /dev/null`
35739     # bat and cmd files are not always considered executable in cygwin causing which
35740     # to not find them
35741     if test "x$new_path" = x \
35742         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35743         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35744       new_path=`$CYGPATH -u "$path"`
35745     fi
35746     if test "x$new_path" = x; then
35747       # It's still not found. Now this is an unrecoverable error.
35748       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35749 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35750       has_space=`$ECHO "$complete" | $GREP " "`
35751       if test "x$has_space" != x; then
35752         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35753 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35754       fi
35755       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35756     fi
35757   fi
35758 
35759   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35760   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35761   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35762   # "foo.exe" is OK but "foo" is an error.
35763   #
35764   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35765   # It is also a way to make sure we got the proper file name for the real test later on.
35766   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35767   if test "x$test_shortpath" = x; then
35768     # Short path failed, file does not exist as specified.
35769     # Try adding .exe or .cmd
35770     if test -f "${new_path}.exe"; then
35771       input_to_shortpath="${new_path}.exe"
35772     elif test -f "${new_path}.cmd"; then
35773       input_to_shortpath="${new_path}.cmd"
35774     else
35775       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
35776 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
35777       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35778 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35779       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35780     fi
35781   else
35782     input_to_shortpath="$new_path"
35783   fi
35784 
35785   # Call helper function which possibly converts this using DOS-style short mode.
35786   # If so, the updated path is stored in $new_path.
35787   new_path="$input_to_shortpath"
35788 
35789   input_path="$input_to_shortpath"
35790   # Check if we need to convert this using DOS-style short mode. If the path
35791   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35792   # take no chances and rewrite it.
35793   # Note: m4 eats our [], so we need to use [ and ] instead.
35794   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35795   if test "x$has_forbidden_chars" != x; then
35796     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35797     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35798     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35799     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35800       # Going to short mode and back again did indeed matter. Since short mode is
35801       # case insensitive, let's make it lowercase to improve readability.
35802       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35803       # Now convert it back to Unix-stile (cygpath)
35804       input_path=`$CYGPATH -u "$shortmode_path"`
35805       new_path="$input_path"
35806     fi
35807   fi
35808 
35809   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35810   if test "x$test_cygdrive_prefix" = x; then
35811     # As a simple fix, exclude /usr/bin since it's not a real path.
35812     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35813       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35814       # a path prefixed by /cygdrive for fixpath to work.
35815       new_path="$CYGWIN_ROOT_PATH$input_path"
35816     fi
35817   fi
35818 
35819   # remove trailing .exe if any
35820   new_path="${new_path/%.exe/}"
35821 
35822   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35823 
35824   # First separate the path from the arguments. This will split at the first
35825   # space.
35826   complete="$GNM"
35827   path="${complete%% *}"
35828   tmp="$complete EOL"
35829   arguments="${tmp#* }"
35830 
35831   # Input might be given as Windows format, start by converting to
35832   # unix format.
35833   new_path="$path"
35834 
35835   windows_path="$new_path"
35836   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35837     unix_path=`$CYGPATH -u "$windows_path"`
35838     new_path="$unix_path"
35839   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35840     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35841     new_path="$unix_path"
35842   fi
35843 
35844 
35845   # Now try to locate executable using which
35846   new_path=`$WHICH "$new_path" 2> /dev/null`
35847 
35848   if test "x$new_path" = x; then
35849     # Oops. Which didn't find the executable.
35850     # The splitting of arguments from the executable at a space might have been incorrect,
35851     # since paths with space are more likely in Windows. Give it another try with the whole
35852     # argument.
35853     path="$complete"
35854     arguments="EOL"
35855     new_path="$path"
35856 
35857   windows_path="$new_path"
35858   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35859     unix_path=`$CYGPATH -u "$windows_path"`
35860     new_path="$unix_path"
35861   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35862     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35863     new_path="$unix_path"
35864   fi
35865 
35866 
35867     new_path=`$WHICH "$new_path" 2> /dev/null`
35868 
35869     if test "x$new_path" = x; then
35870       # It's still not found. Now this is an unrecoverable error.
35871       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35872 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35873       has_space=`$ECHO "$complete" | $GREP " "`
35874       if test "x$has_space" != x; then
35875         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35876 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35877       fi
35878       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35879     fi
35880   fi
35881 
35882   # Now new_path has a complete unix path to the binary
35883   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35884     # Keep paths in /bin as-is, but remove trailing .exe if any
35885     new_path="${new_path/%.exe/}"
35886     # Do not save /bin paths to all_fixpath_prefixes!
35887   else
35888     # Not in mixed or Windows style, start by that.
35889     new_path=`cmd //c echo $new_path`
35890 
35891   input_path="$new_path"
35892   # Check if we need to convert this using DOS-style short mode. If the path
35893   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35894   # take no chances and rewrite it.
35895   # Note: m4 eats our [], so we need to use [ and ] instead.
35896   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35897   if test "x$has_forbidden_chars" != x; then
35898     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35899     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35900   fi
35901 
35902     # Output is in $new_path
35903 
35904   windows_path="$new_path"
35905   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35906     unix_path=`$CYGPATH -u "$windows_path"`
35907     new_path="$unix_path"
35908   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35909     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35910     new_path="$unix_path"
35911   fi
35912 
35913     # remove trailing .exe if any
35914     new_path="${new_path/%.exe/}"
35915 
35916     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35917     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35918   fi
35919 
35920   else
35921     # We're on a posix platform. Hooray! :)
35922     # First separate the path from the arguments. This will split at the first
35923     # space.
35924     complete="$GNM"
35925     path="${complete%% *}"
35926     tmp="$complete EOL"
35927     arguments="${tmp#* }"
35928 
35929     # Cannot rely on the command "which" here since it doesn't always work.
35930     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35931     if test -z "$is_absolute_path"; then
35932       # Path to executable is not absolute. Find it.
35933       IFS_save="$IFS"
35934       IFS=:
35935       for p in $PATH; do
35936         if test -f "$p/$path" && test -x "$p/$path"; then
35937           new_path="$p/$path"
35938           break
35939         fi
35940       done
35941       IFS="$IFS_save"
35942     else
35943       # This is an absolute path, we can use it without further modifications.
35944       new_path="$path"
35945     fi
35946 
35947     if test "x$new_path" = x; then
35948       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35949 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35950       has_space=`$ECHO "$complete" | $GREP " "`
35951       if test "x$has_space" != x; then
35952         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35953 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35954       fi
35955       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35956     fi
35957   fi
35958 
35959   # Now join together the path and the arguments once again
35960   if test "x$arguments" != xEOL; then
35961     new_complete="$new_path ${arguments% *}"
35962   else
35963     new_complete="$new_path"
35964   fi
35965 
35966   if test "x$complete" != "x$new_complete"; then
35967     GNM="$new_complete"
35968     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
35969 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
35970   fi
35971 
35972 
35973 
35974 
35975   # Publish this variable in the help.
35976 
35977 
35978   if test "x$MCS" = x; then
35979     # The variable is not set by user, try to locate tool using the code snippet
35980     for ac_prog in mcs
35981 do
35982   # Extract the first word of "$ac_prog", so it can be a program name with args.
35983 set dummy $ac_prog; ac_word=$2
35984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35985 $as_echo_n "checking for $ac_word... " >&6; }
35986 if ${ac_cv_path_MCS+:} false; then :
35987   $as_echo_n "(cached) " >&6
35988 else
35989   case $MCS in
35990   [\\/]* | ?:[\\/]*)
35991   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
35992   ;;
35993   *)
35994   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35995 for as_dir in $PATH
35996 do
35997   IFS=$as_save_IFS
35998   test -z "$as_dir" && as_dir=.
35999     for ac_exec_ext in '' $ac_executable_extensions; do
36000   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36001     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36002     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36003     break 2
36004   fi
36005 done
36006   done
36007 IFS=$as_save_IFS
36008 
36009   ;;
36010 esac
36011 fi
36012 MCS=$ac_cv_path_MCS
36013 if test -n "$MCS"; then
36014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36015 $as_echo "$MCS" >&6; }
36016 else
36017   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36018 $as_echo "no" >&6; }
36019 fi
36020 
36021 
36022   test -n "$MCS" && break
36023 done
36024 
36025   else
36026     # The variable is set, but is it from the command line or the environment?
36027 
36028     # Try to remove the string !MCS! from our list.
36029     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
36030     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36031       # If it failed, the variable was not from the command line. Ignore it,
36032       # but warn the user (except for BASH, which is always set by the calling BASH).
36033       if test "xMCS" != xBASH; then
36034         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
36035 $as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
36036       fi
36037       # Try to locate tool using the code snippet
36038       for ac_prog in mcs
36039 do
36040   # Extract the first word of "$ac_prog", so it can be a program name with args.
36041 set dummy $ac_prog; ac_word=$2
36042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36043 $as_echo_n "checking for $ac_word... " >&6; }
36044 if ${ac_cv_path_MCS+:} false; then :
36045   $as_echo_n "(cached) " >&6
36046 else
36047   case $MCS in
36048   [\\/]* | ?:[\\/]*)
36049   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36050   ;;
36051   *)
36052   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36053 for as_dir in $PATH
36054 do
36055   IFS=$as_save_IFS
36056   test -z "$as_dir" && as_dir=.
36057     for ac_exec_ext in '' $ac_executable_extensions; do
36058   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36059     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36060     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36061     break 2
36062   fi
36063 done
36064   done
36065 IFS=$as_save_IFS
36066 
36067   ;;
36068 esac
36069 fi
36070 MCS=$ac_cv_path_MCS
36071 if test -n "$MCS"; then
36072   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36073 $as_echo "$MCS" >&6; }
36074 else
36075   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36076 $as_echo "no" >&6; }
36077 fi
36078 
36079 
36080   test -n "$MCS" && break
36081 done
36082 
36083     else
36084       # If it succeeded, then it was overridden by the user. We will use it
36085       # for the tool.
36086 
36087       # First remove it from the list of overridden variables, so we can test
36088       # for unknown variables in the end.
36089       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36090 
36091       # Check if the provided tool contains a complete path.
36092       tool_specified="$MCS"
36093       tool_basename="${tool_specified##*/}"
36094       if test "x$tool_basename" = "x$tool_specified"; then
36095         # A command without a complete path is provided, search $PATH.
36096         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
36097 $as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
36098         # Extract the first word of "$tool_basename", so it can be a program name with args.
36099 set dummy $tool_basename; ac_word=$2
36100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36101 $as_echo_n "checking for $ac_word... " >&6; }
36102 if ${ac_cv_path_MCS+:} false; then :
36103   $as_echo_n "(cached) " >&6
36104 else
36105   case $MCS in
36106   [\\/]* | ?:[\\/]*)
36107   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36108   ;;
36109   *)
36110   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36111 for as_dir in $PATH
36112 do
36113   IFS=$as_save_IFS
36114   test -z "$as_dir" && as_dir=.
36115     for ac_exec_ext in '' $ac_executable_extensions; do
36116   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36117     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36118     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36119     break 2
36120   fi
36121 done
36122   done
36123 IFS=$as_save_IFS
36124 
36125   ;;
36126 esac
36127 fi
36128 MCS=$ac_cv_path_MCS
36129 if test -n "$MCS"; then
36130   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36131 $as_echo "$MCS" >&6; }
36132 else
36133   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36134 $as_echo "no" >&6; }
36135 fi
36136 
36137 
36138         if test "x$MCS" = x; then
36139           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36140         fi
36141       else
36142         # Otherwise we believe it is a complete path. Use it as it is.
36143         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
36144 $as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
36145         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
36146 $as_echo_n "checking for MCS... " >&6; }
36147         if test ! -x "$tool_specified"; then
36148           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36149 $as_echo "not found" >&6; }
36150           as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
36151         fi
36152         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36153 $as_echo "$tool_specified" >&6; }
36154       fi
36155     fi
36156   fi
36157 
36158 
36159 
36160   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36161 
36162   # First separate the path from the arguments. This will split at the first
36163   # space.
36164   complete="$MCS"
36165   path="${complete%% *}"
36166   tmp="$complete EOL"
36167   arguments="${tmp#* }"
36168 
36169   # Input might be given as Windows format, start by converting to
36170   # unix format.
36171   new_path=`$CYGPATH -u "$path"`
36172 
36173   # Now try to locate executable using which
36174   new_path=`$WHICH "$new_path" 2> /dev/null`
36175   # bat and cmd files are not always considered executable in cygwin causing which
36176   # to not find them
36177   if test "x$new_path" = x \
36178       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36179       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36180     new_path=`$CYGPATH -u "$path"`
36181   fi
36182   if test "x$new_path" = x; then
36183     # Oops. Which didn't find the executable.
36184     # The splitting of arguments from the executable at a space might have been incorrect,
36185     # since paths with space are more likely in Windows. Give it another try with the whole
36186     # argument.
36187     path="$complete"
36188     arguments="EOL"
36189     new_path=`$CYGPATH -u "$path"`
36190     new_path=`$WHICH "$new_path" 2> /dev/null`
36191     # bat and cmd files are not always considered executable in cygwin causing which
36192     # to not find them
36193     if test "x$new_path" = x \
36194         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36195         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36196       new_path=`$CYGPATH -u "$path"`
36197     fi
36198     if test "x$new_path" = x; then
36199       # It's still not found. Now this is an unrecoverable error.
36200       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36201 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36202       has_space=`$ECHO "$complete" | $GREP " "`
36203       if test "x$has_space" != x; then
36204         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36205 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36206       fi
36207       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36208     fi
36209   fi
36210 
36211   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36212   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36213   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36214   # "foo.exe" is OK but "foo" is an error.
36215   #
36216   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36217   # It is also a way to make sure we got the proper file name for the real test later on.
36218   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36219   if test "x$test_shortpath" = x; then
36220     # Short path failed, file does not exist as specified.
36221     # Try adding .exe or .cmd
36222     if test -f "${new_path}.exe"; then
36223       input_to_shortpath="${new_path}.exe"
36224     elif test -f "${new_path}.cmd"; then
36225       input_to_shortpath="${new_path}.cmd"
36226     else
36227       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
36228 $as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
36229       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36230 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36231       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36232     fi
36233   else
36234     input_to_shortpath="$new_path"
36235   fi
36236 
36237   # Call helper function which possibly converts this using DOS-style short mode.
36238   # If so, the updated path is stored in $new_path.
36239   new_path="$input_to_shortpath"
36240 
36241   input_path="$input_to_shortpath"
36242   # Check if we need to convert this using DOS-style short mode. If the path
36243   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36244   # take no chances and rewrite it.
36245   # Note: m4 eats our [], so we need to use [ and ] instead.
36246   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36247   if test "x$has_forbidden_chars" != x; then
36248     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36249     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36250     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36251     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36252       # Going to short mode and back again did indeed matter. Since short mode is
36253       # case insensitive, let's make it lowercase to improve readability.
36254       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36255       # Now convert it back to Unix-stile (cygpath)
36256       input_path=`$CYGPATH -u "$shortmode_path"`
36257       new_path="$input_path"
36258     fi
36259   fi
36260 
36261   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36262   if test "x$test_cygdrive_prefix" = x; then
36263     # As a simple fix, exclude /usr/bin since it's not a real path.
36264     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36265       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36266       # a path prefixed by /cygdrive for fixpath to work.
36267       new_path="$CYGWIN_ROOT_PATH$input_path"
36268     fi
36269   fi
36270 
36271   # remove trailing .exe if any
36272   new_path="${new_path/%.exe/}"
36273 
36274   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36275 
36276   # First separate the path from the arguments. This will split at the first
36277   # space.
36278   complete="$MCS"
36279   path="${complete%% *}"
36280   tmp="$complete EOL"
36281   arguments="${tmp#* }"
36282 
36283   # Input might be given as Windows format, start by converting to
36284   # unix format.
36285   new_path="$path"
36286 
36287   windows_path="$new_path"
36288   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36289     unix_path=`$CYGPATH -u "$windows_path"`
36290     new_path="$unix_path"
36291   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36292     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36293     new_path="$unix_path"
36294   fi
36295 
36296 
36297   # Now try to locate executable using which
36298   new_path=`$WHICH "$new_path" 2> /dev/null`
36299 
36300   if test "x$new_path" = x; then
36301     # Oops. Which didn't find the executable.
36302     # The splitting of arguments from the executable at a space might have been incorrect,
36303     # since paths with space are more likely in Windows. Give it another try with the whole
36304     # argument.
36305     path="$complete"
36306     arguments="EOL"
36307     new_path="$path"
36308 
36309   windows_path="$new_path"
36310   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36311     unix_path=`$CYGPATH -u "$windows_path"`
36312     new_path="$unix_path"
36313   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36314     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36315     new_path="$unix_path"
36316   fi
36317 
36318 
36319     new_path=`$WHICH "$new_path" 2> /dev/null`
36320 
36321     if test "x$new_path" = x; then
36322       # It's still not found. Now this is an unrecoverable error.
36323       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36324 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36325       has_space=`$ECHO "$complete" | $GREP " "`
36326       if test "x$has_space" != x; then
36327         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36328 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36329       fi
36330       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36331     fi
36332   fi
36333 
36334   # Now new_path has a complete unix path to the binary
36335   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36336     # Keep paths in /bin as-is, but remove trailing .exe if any
36337     new_path="${new_path/%.exe/}"
36338     # Do not save /bin paths to all_fixpath_prefixes!
36339   else
36340     # Not in mixed or Windows style, start by that.
36341     new_path=`cmd //c echo $new_path`
36342 
36343   input_path="$new_path"
36344   # Check if we need to convert this using DOS-style short mode. If the path
36345   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36346   # take no chances and rewrite it.
36347   # Note: m4 eats our [], so we need to use [ and ] instead.
36348   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36349   if test "x$has_forbidden_chars" != x; then
36350     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36351     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36352   fi
36353 
36354     # Output is in $new_path
36355 
36356   windows_path="$new_path"
36357   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36358     unix_path=`$CYGPATH -u "$windows_path"`
36359     new_path="$unix_path"
36360   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36361     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36362     new_path="$unix_path"
36363   fi
36364 
36365     # remove trailing .exe if any
36366     new_path="${new_path/%.exe/}"
36367 
36368     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36369     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36370   fi
36371 
36372   else
36373     # We're on a posix platform. Hooray! :)
36374     # First separate the path from the arguments. This will split at the first
36375     # space.
36376     complete="$MCS"
36377     path="${complete%% *}"
36378     tmp="$complete EOL"
36379     arguments="${tmp#* }"
36380 
36381     # Cannot rely on the command "which" here since it doesn't always work.
36382     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36383     if test -z "$is_absolute_path"; then
36384       # Path to executable is not absolute. Find it.
36385       IFS_save="$IFS"
36386       IFS=:
36387       for p in $PATH; do
36388         if test -f "$p/$path" && test -x "$p/$path"; then
36389           new_path="$p/$path"
36390           break
36391         fi
36392       done
36393       IFS="$IFS_save"
36394     else
36395       # This is an absolute path, we can use it without further modifications.
36396       new_path="$path"
36397     fi
36398 
36399     if test "x$new_path" = x; then
36400       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36401 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36402       has_space=`$ECHO "$complete" | $GREP " "`
36403       if test "x$has_space" != x; then
36404         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36405 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36406       fi
36407       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36408     fi
36409   fi
36410 
36411   # Now join together the path and the arguments once again
36412   if test "x$arguments" != xEOL; then
36413     new_complete="$new_path ${arguments% *}"
36414   else
36415     new_complete="$new_path"
36416   fi
36417 
36418   if test "x$complete" != "x$new_complete"; then
36419     MCS="$new_complete"
36420     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
36421 $as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
36422   fi
36423 
36424   elif test "x$OPENJDK_TARGET_OS" != xwindows; then
36425     # FIXME: we should unify this with the solaris case above.
36426 
36427 
36428   # Publish this variable in the help.
36429 
36430 
36431   if test "x$STRIP" = x; then
36432     # The variable is not set by user, try to locate tool using the code snippet
36433     if test -n "$ac_tool_prefix"; then
36434   for ac_prog in strip
36435   do
36436     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36437 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36439 $as_echo_n "checking for $ac_word... " >&6; }
36440 if ${ac_cv_prog_STRIP+:} false; then :
36441   $as_echo_n "(cached) " >&6
36442 else
36443   if test -n "$STRIP"; then
36444   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36445 else
36446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36447 for as_dir in $PATH
36448 do
36449   IFS=$as_save_IFS
36450   test -z "$as_dir" && as_dir=.
36451     for ac_exec_ext in '' $ac_executable_extensions; do
36452   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36453     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36454     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36455     break 2
36456   fi
36457 done
36458   done
36459 IFS=$as_save_IFS
36460 
36461 fi
36462 fi
36463 STRIP=$ac_cv_prog_STRIP
36464 if test -n "$STRIP"; then
36465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36466 $as_echo "$STRIP" >&6; }
36467 else
36468   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36469 $as_echo "no" >&6; }
36470 fi
36471 
36472 
36473     test -n "$STRIP" && break
36474   done
36475 fi
36476 if test -z "$STRIP"; then
36477   ac_ct_STRIP=$STRIP
36478   for ac_prog in strip
36479 do
36480   # Extract the first word of "$ac_prog", so it can be a program name with args.
36481 set dummy $ac_prog; ac_word=$2
36482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36483 $as_echo_n "checking for $ac_word... " >&6; }
36484 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36485   $as_echo_n "(cached) " >&6
36486 else
36487   if test -n "$ac_ct_STRIP"; then
36488   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36489 else
36490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36491 for as_dir in $PATH
36492 do
36493   IFS=$as_save_IFS
36494   test -z "$as_dir" && as_dir=.
36495     for ac_exec_ext in '' $ac_executable_extensions; do
36496   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36497     ac_cv_prog_ac_ct_STRIP="$ac_prog"
36498     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36499     break 2
36500   fi
36501 done
36502   done
36503 IFS=$as_save_IFS
36504 
36505 fi
36506 fi
36507 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36508 if test -n "$ac_ct_STRIP"; then
36509   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36510 $as_echo "$ac_ct_STRIP" >&6; }
36511 else
36512   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36513 $as_echo "no" >&6; }
36514 fi
36515 
36516 
36517   test -n "$ac_ct_STRIP" && break
36518 done
36519 
36520   if test "x$ac_ct_STRIP" = x; then
36521     STRIP=""
36522   else
36523     case $cross_compiling:$ac_tool_warned in
36524 yes:)
36525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36526 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36527 ac_tool_warned=yes ;;
36528 esac
36529     STRIP=$ac_ct_STRIP
36530   fi
36531 fi
36532 
36533   else
36534     # The variable is set, but is it from the command line or the environment?
36535 
36536     # Try to remove the string !STRIP! from our list.
36537     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
36538     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36539       # If it failed, the variable was not from the command line. Ignore it,
36540       # but warn the user (except for BASH, which is always set by the calling BASH).
36541       if test "xSTRIP" != xBASH; then
36542         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
36543 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
36544       fi
36545       # Try to locate tool using the code snippet
36546       if test -n "$ac_tool_prefix"; then
36547   for ac_prog in strip
36548   do
36549     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36550 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36552 $as_echo_n "checking for $ac_word... " >&6; }
36553 if ${ac_cv_prog_STRIP+:} false; then :
36554   $as_echo_n "(cached) " >&6
36555 else
36556   if test -n "$STRIP"; then
36557   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36558 else
36559 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36560 for as_dir in $PATH
36561 do
36562   IFS=$as_save_IFS
36563   test -z "$as_dir" && as_dir=.
36564     for ac_exec_ext in '' $ac_executable_extensions; do
36565   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36566     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36567     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36568     break 2
36569   fi
36570 done
36571   done
36572 IFS=$as_save_IFS
36573 
36574 fi
36575 fi
36576 STRIP=$ac_cv_prog_STRIP
36577 if test -n "$STRIP"; then
36578   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36579 $as_echo "$STRIP" >&6; }
36580 else
36581   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36582 $as_echo "no" >&6; }
36583 fi
36584 
36585 
36586     test -n "$STRIP" && break
36587   done
36588 fi
36589 if test -z "$STRIP"; then
36590   ac_ct_STRIP=$STRIP
36591   for ac_prog in strip
36592 do
36593   # Extract the first word of "$ac_prog", so it can be a program name with args.
36594 set dummy $ac_prog; ac_word=$2
36595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36596 $as_echo_n "checking for $ac_word... " >&6; }
36597 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36598   $as_echo_n "(cached) " >&6
36599 else
36600   if test -n "$ac_ct_STRIP"; then
36601   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36602 else
36603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36604 for as_dir in $PATH
36605 do
36606   IFS=$as_save_IFS
36607   test -z "$as_dir" && as_dir=.
36608     for ac_exec_ext in '' $ac_executable_extensions; do
36609   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36610     ac_cv_prog_ac_ct_STRIP="$ac_prog"
36611     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36612     break 2
36613   fi
36614 done
36615   done
36616 IFS=$as_save_IFS
36617 
36618 fi
36619 fi
36620 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36621 if test -n "$ac_ct_STRIP"; then
36622   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36623 $as_echo "$ac_ct_STRIP" >&6; }
36624 else
36625   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36626 $as_echo "no" >&6; }
36627 fi
36628 
36629 
36630   test -n "$ac_ct_STRIP" && break
36631 done
36632 
36633   if test "x$ac_ct_STRIP" = x; then
36634     STRIP=""
36635   else
36636     case $cross_compiling:$ac_tool_warned in
36637 yes:)
36638 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36639 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36640 ac_tool_warned=yes ;;
36641 esac
36642     STRIP=$ac_ct_STRIP
36643   fi
36644 fi
36645 
36646     else
36647       # If it succeeded, then it was overridden by the user. We will use it
36648       # for the tool.
36649 
36650       # First remove it from the list of overridden variables, so we can test
36651       # for unknown variables in the end.
36652       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36653 
36654       # Check if the provided tool contains a complete path.
36655       tool_specified="$STRIP"
36656       tool_basename="${tool_specified##*/}"
36657       if test "x$tool_basename" = "x$tool_specified"; then
36658         # A command without a complete path is provided, search $PATH.
36659         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
36660 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
36661         # Extract the first word of "$tool_basename", so it can be a program name with args.
36662 set dummy $tool_basename; ac_word=$2
36663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36664 $as_echo_n "checking for $ac_word... " >&6; }
36665 if ${ac_cv_path_STRIP+:} false; then :
36666   $as_echo_n "(cached) " >&6
36667 else
36668   case $STRIP in
36669   [\\/]* | ?:[\\/]*)
36670   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
36671   ;;
36672   *)
36673   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36674 for as_dir in $PATH
36675 do
36676   IFS=$as_save_IFS
36677   test -z "$as_dir" && as_dir=.
36678     for ac_exec_ext in '' $ac_executable_extensions; do
36679   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36680     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
36681     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36682     break 2
36683   fi
36684 done
36685   done
36686 IFS=$as_save_IFS
36687 
36688   ;;
36689 esac
36690 fi
36691 STRIP=$ac_cv_path_STRIP
36692 if test -n "$STRIP"; then
36693   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36694 $as_echo "$STRIP" >&6; }
36695 else
36696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36697 $as_echo "no" >&6; }
36698 fi
36699 
36700 
36701         if test "x$STRIP" = x; then
36702           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36703         fi
36704       else
36705         # Otherwise we believe it is a complete path. Use it as it is.
36706         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
36707 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
36708         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
36709 $as_echo_n "checking for STRIP... " >&6; }
36710         if test ! -x "$tool_specified"; then
36711           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36712 $as_echo "not found" >&6; }
36713           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
36714         fi
36715         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36716 $as_echo "$tool_specified" >&6; }
36717       fi
36718     fi
36719   fi
36720 
36721 
36722 
36723   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36724 
36725   # First separate the path from the arguments. This will split at the first
36726   # space.
36727   complete="$STRIP"
36728   path="${complete%% *}"
36729   tmp="$complete EOL"
36730   arguments="${tmp#* }"
36731 
36732   # Input might be given as Windows format, start by converting to
36733   # unix format.
36734   new_path=`$CYGPATH -u "$path"`
36735 
36736   # Now try to locate executable using which
36737   new_path=`$WHICH "$new_path" 2> /dev/null`
36738   # bat and cmd files are not always considered executable in cygwin causing which
36739   # to not find them
36740   if test "x$new_path" = x \
36741       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36742       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36743     new_path=`$CYGPATH -u "$path"`
36744   fi
36745   if test "x$new_path" = x; then
36746     # Oops. Which didn't find the executable.
36747     # The splitting of arguments from the executable at a space might have been incorrect,
36748     # since paths with space are more likely in Windows. Give it another try with the whole
36749     # argument.
36750     path="$complete"
36751     arguments="EOL"
36752     new_path=`$CYGPATH -u "$path"`
36753     new_path=`$WHICH "$new_path" 2> /dev/null`
36754     # bat and cmd files are not always considered executable in cygwin causing which
36755     # to not find them
36756     if test "x$new_path" = x \
36757         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36758         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36759       new_path=`$CYGPATH -u "$path"`
36760     fi
36761     if test "x$new_path" = x; then
36762       # It's still not found. Now this is an unrecoverable error.
36763       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36764 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36765       has_space=`$ECHO "$complete" | $GREP " "`
36766       if test "x$has_space" != x; then
36767         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36768 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36769       fi
36770       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36771     fi
36772   fi
36773 
36774   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36775   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36776   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36777   # "foo.exe" is OK but "foo" is an error.
36778   #
36779   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36780   # It is also a way to make sure we got the proper file name for the real test later on.
36781   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36782   if test "x$test_shortpath" = x; then
36783     # Short path failed, file does not exist as specified.
36784     # Try adding .exe or .cmd
36785     if test -f "${new_path}.exe"; then
36786       input_to_shortpath="${new_path}.exe"
36787     elif test -f "${new_path}.cmd"; then
36788       input_to_shortpath="${new_path}.cmd"
36789     else
36790       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
36791 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
36792       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36793 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36794       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36795     fi
36796   else
36797     input_to_shortpath="$new_path"
36798   fi
36799 
36800   # Call helper function which possibly converts this using DOS-style short mode.
36801   # If so, the updated path is stored in $new_path.
36802   new_path="$input_to_shortpath"
36803 
36804   input_path="$input_to_shortpath"
36805   # Check if we need to convert this using DOS-style short mode. If the path
36806   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36807   # take no chances and rewrite it.
36808   # Note: m4 eats our [], so we need to use [ and ] instead.
36809   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36810   if test "x$has_forbidden_chars" != x; then
36811     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36812     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36813     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36814     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36815       # Going to short mode and back again did indeed matter. Since short mode is
36816       # case insensitive, let's make it lowercase to improve readability.
36817       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36818       # Now convert it back to Unix-stile (cygpath)
36819       input_path=`$CYGPATH -u "$shortmode_path"`
36820       new_path="$input_path"
36821     fi
36822   fi
36823 
36824   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36825   if test "x$test_cygdrive_prefix" = x; then
36826     # As a simple fix, exclude /usr/bin since it's not a real path.
36827     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36828       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36829       # a path prefixed by /cygdrive for fixpath to work.
36830       new_path="$CYGWIN_ROOT_PATH$input_path"
36831     fi
36832   fi
36833 
36834   # remove trailing .exe if any
36835   new_path="${new_path/%.exe/}"
36836 
36837   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36838 
36839   # First separate the path from the arguments. This will split at the first
36840   # space.
36841   complete="$STRIP"
36842   path="${complete%% *}"
36843   tmp="$complete EOL"
36844   arguments="${tmp#* }"
36845 
36846   # Input might be given as Windows format, start by converting to
36847   # unix format.
36848   new_path="$path"
36849 
36850   windows_path="$new_path"
36851   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36852     unix_path=`$CYGPATH -u "$windows_path"`
36853     new_path="$unix_path"
36854   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36855     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36856     new_path="$unix_path"
36857   fi
36858 
36859 
36860   # Now try to locate executable using which
36861   new_path=`$WHICH "$new_path" 2> /dev/null`
36862 
36863   if test "x$new_path" = x; then
36864     # Oops. Which didn't find the executable.
36865     # The splitting of arguments from the executable at a space might have been incorrect,
36866     # since paths with space are more likely in Windows. Give it another try with the whole
36867     # argument.
36868     path="$complete"
36869     arguments="EOL"
36870     new_path="$path"
36871 
36872   windows_path="$new_path"
36873   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36874     unix_path=`$CYGPATH -u "$windows_path"`
36875     new_path="$unix_path"
36876   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36877     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36878     new_path="$unix_path"
36879   fi
36880 
36881 
36882     new_path=`$WHICH "$new_path" 2> /dev/null`
36883 
36884     if test "x$new_path" = x; then
36885       # It's still not found. Now this is an unrecoverable error.
36886       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36887 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36888       has_space=`$ECHO "$complete" | $GREP " "`
36889       if test "x$has_space" != x; then
36890         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36891 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36892       fi
36893       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36894     fi
36895   fi
36896 
36897   # Now new_path has a complete unix path to the binary
36898   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36899     # Keep paths in /bin as-is, but remove trailing .exe if any
36900     new_path="${new_path/%.exe/}"
36901     # Do not save /bin paths to all_fixpath_prefixes!
36902   else
36903     # Not in mixed or Windows style, start by that.
36904     new_path=`cmd //c echo $new_path`
36905 
36906   input_path="$new_path"
36907   # Check if we need to convert this using DOS-style short mode. If the path
36908   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36909   # take no chances and rewrite it.
36910   # Note: m4 eats our [], so we need to use [ and ] instead.
36911   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36912   if test "x$has_forbidden_chars" != x; then
36913     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36914     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36915   fi
36916 
36917     # Output is in $new_path
36918 
36919   windows_path="$new_path"
36920   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36921     unix_path=`$CYGPATH -u "$windows_path"`
36922     new_path="$unix_path"
36923   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36924     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36925     new_path="$unix_path"
36926   fi
36927 
36928     # remove trailing .exe if any
36929     new_path="${new_path/%.exe/}"
36930 
36931     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36932     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36933   fi
36934 
36935   else
36936     # We're on a posix platform. Hooray! :)
36937     # First separate the path from the arguments. This will split at the first
36938     # space.
36939     complete="$STRIP"
36940     path="${complete%% *}"
36941     tmp="$complete EOL"
36942     arguments="${tmp#* }"
36943 
36944     # Cannot rely on the command "which" here since it doesn't always work.
36945     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36946     if test -z "$is_absolute_path"; then
36947       # Path to executable is not absolute. Find it.
36948       IFS_save="$IFS"
36949       IFS=:
36950       for p in $PATH; do
36951         if test -f "$p/$path" && test -x "$p/$path"; then
36952           new_path="$p/$path"
36953           break
36954         fi
36955       done
36956       IFS="$IFS_save"
36957     else
36958       # This is an absolute path, we can use it without further modifications.
36959       new_path="$path"
36960     fi
36961 
36962     if test "x$new_path" = x; then
36963       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36964 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36965       has_space=`$ECHO "$complete" | $GREP " "`
36966       if test "x$has_space" != x; then
36967         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36968 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36969       fi
36970       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36971     fi
36972   fi
36973 
36974   # Now join together the path and the arguments once again
36975   if test "x$arguments" != xEOL; then
36976     new_complete="$new_path ${arguments% *}"
36977   else
36978     new_complete="$new_path"
36979   fi
36980 
36981   if test "x$complete" != "x$new_complete"; then
36982     STRIP="$new_complete"
36983     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
36984 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
36985   fi
36986 
36987 
36988 
36989   # Publish this variable in the help.
36990 
36991 
36992   if test "x$NM" = x; then
36993     # The variable is not set by user, try to locate tool using the code snippet
36994     if test -n "$ac_tool_prefix"; then
36995   for ac_prog in nm
36996   do
36997     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36998 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37000 $as_echo_n "checking for $ac_word... " >&6; }
37001 if ${ac_cv_prog_NM+:} false; then :
37002   $as_echo_n "(cached) " >&6
37003 else
37004   if test -n "$NM"; then
37005   ac_cv_prog_NM="$NM" # Let the user override the test.
37006 else
37007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37008 for as_dir in $PATH
37009 do
37010   IFS=$as_save_IFS
37011   test -z "$as_dir" && as_dir=.
37012     for ac_exec_ext in '' $ac_executable_extensions; do
37013   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37014     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37015     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37016     break 2
37017   fi
37018 done
37019   done
37020 IFS=$as_save_IFS
37021 
37022 fi
37023 fi
37024 NM=$ac_cv_prog_NM
37025 if test -n "$NM"; then
37026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37027 $as_echo "$NM" >&6; }
37028 else
37029   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37030 $as_echo "no" >&6; }
37031 fi
37032 
37033 
37034     test -n "$NM" && break
37035   done
37036 fi
37037 if test -z "$NM"; then
37038   ac_ct_NM=$NM
37039   for ac_prog in nm
37040 do
37041   # Extract the first word of "$ac_prog", so it can be a program name with args.
37042 set dummy $ac_prog; ac_word=$2
37043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37044 $as_echo_n "checking for $ac_word... " >&6; }
37045 if ${ac_cv_prog_ac_ct_NM+:} false; then :
37046   $as_echo_n "(cached) " >&6
37047 else
37048   if test -n "$ac_ct_NM"; then
37049   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37050 else
37051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37052 for as_dir in $PATH
37053 do
37054   IFS=$as_save_IFS
37055   test -z "$as_dir" && as_dir=.
37056     for ac_exec_ext in '' $ac_executable_extensions; do
37057   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37058     ac_cv_prog_ac_ct_NM="$ac_prog"
37059     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37060     break 2
37061   fi
37062 done
37063   done
37064 IFS=$as_save_IFS
37065 
37066 fi
37067 fi
37068 ac_ct_NM=$ac_cv_prog_ac_ct_NM
37069 if test -n "$ac_ct_NM"; then
37070   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37071 $as_echo "$ac_ct_NM" >&6; }
37072 else
37073   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37074 $as_echo "no" >&6; }
37075 fi
37076 
37077 
37078   test -n "$ac_ct_NM" && break
37079 done
37080 
37081   if test "x$ac_ct_NM" = x; then
37082     NM=""
37083   else
37084     case $cross_compiling:$ac_tool_warned in
37085 yes:)
37086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37087 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37088 ac_tool_warned=yes ;;
37089 esac
37090     NM=$ac_ct_NM
37091   fi
37092 fi
37093 
37094   else
37095     # The variable is set, but is it from the command line or the environment?
37096 
37097     # Try to remove the string !NM! from our list.
37098     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
37099     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37100       # If it failed, the variable was not from the command line. Ignore it,
37101       # but warn the user (except for BASH, which is always set by the calling BASH).
37102       if test "xNM" != xBASH; then
37103         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
37104 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
37105       fi
37106       # Try to locate tool using the code snippet
37107       if test -n "$ac_tool_prefix"; then
37108   for ac_prog in nm
37109   do
37110     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37111 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37113 $as_echo_n "checking for $ac_word... " >&6; }
37114 if ${ac_cv_prog_NM+:} false; then :
37115   $as_echo_n "(cached) " >&6
37116 else
37117   if test -n "$NM"; then
37118   ac_cv_prog_NM="$NM" # Let the user override the test.
37119 else
37120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37121 for as_dir in $PATH
37122 do
37123   IFS=$as_save_IFS
37124   test -z "$as_dir" && as_dir=.
37125     for ac_exec_ext in '' $ac_executable_extensions; do
37126   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37127     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37128     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37129     break 2
37130   fi
37131 done
37132   done
37133 IFS=$as_save_IFS
37134 
37135 fi
37136 fi
37137 NM=$ac_cv_prog_NM
37138 if test -n "$NM"; then
37139   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37140 $as_echo "$NM" >&6; }
37141 else
37142   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37143 $as_echo "no" >&6; }
37144 fi
37145 
37146 
37147     test -n "$NM" && break
37148   done
37149 fi
37150 if test -z "$NM"; then
37151   ac_ct_NM=$NM
37152   for ac_prog in nm
37153 do
37154   # Extract the first word of "$ac_prog", so it can be a program name with args.
37155 set dummy $ac_prog; ac_word=$2
37156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37157 $as_echo_n "checking for $ac_word... " >&6; }
37158 if ${ac_cv_prog_ac_ct_NM+:} false; then :
37159   $as_echo_n "(cached) " >&6
37160 else
37161   if test -n "$ac_ct_NM"; then
37162   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37163 else
37164 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37165 for as_dir in $PATH
37166 do
37167   IFS=$as_save_IFS
37168   test -z "$as_dir" && as_dir=.
37169     for ac_exec_ext in '' $ac_executable_extensions; do
37170   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37171     ac_cv_prog_ac_ct_NM="$ac_prog"
37172     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37173     break 2
37174   fi
37175 done
37176   done
37177 IFS=$as_save_IFS
37178 
37179 fi
37180 fi
37181 ac_ct_NM=$ac_cv_prog_ac_ct_NM
37182 if test -n "$ac_ct_NM"; then
37183   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37184 $as_echo "$ac_ct_NM" >&6; }
37185 else
37186   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37187 $as_echo "no" >&6; }
37188 fi
37189 
37190 
37191   test -n "$ac_ct_NM" && break
37192 done
37193 
37194   if test "x$ac_ct_NM" = x; then
37195     NM=""
37196   else
37197     case $cross_compiling:$ac_tool_warned in
37198 yes:)
37199 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37200 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37201 ac_tool_warned=yes ;;
37202 esac
37203     NM=$ac_ct_NM
37204   fi
37205 fi
37206 
37207     else
37208       # If it succeeded, then it was overridden by the user. We will use it
37209       # for the tool.
37210 
37211       # First remove it from the list of overridden variables, so we can test
37212       # for unknown variables in the end.
37213       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37214 
37215       # Check if the provided tool contains a complete path.
37216       tool_specified="$NM"
37217       tool_basename="${tool_specified##*/}"
37218       if test "x$tool_basename" = "x$tool_specified"; then
37219         # A command without a complete path is provided, search $PATH.
37220         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
37221 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
37222         # Extract the first word of "$tool_basename", so it can be a program name with args.
37223 set dummy $tool_basename; ac_word=$2
37224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37225 $as_echo_n "checking for $ac_word... " >&6; }
37226 if ${ac_cv_path_NM+:} false; then :
37227   $as_echo_n "(cached) " >&6
37228 else
37229   case $NM in
37230   [\\/]* | ?:[\\/]*)
37231   ac_cv_path_NM="$NM" # Let the user override the test with a path.
37232   ;;
37233   *)
37234   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37235 for as_dir in $PATH
37236 do
37237   IFS=$as_save_IFS
37238   test -z "$as_dir" && as_dir=.
37239     for ac_exec_ext in '' $ac_executable_extensions; do
37240   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37241     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
37242     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37243     break 2
37244   fi
37245 done
37246   done
37247 IFS=$as_save_IFS
37248 
37249   ;;
37250 esac
37251 fi
37252 NM=$ac_cv_path_NM
37253 if test -n "$NM"; then
37254   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37255 $as_echo "$NM" >&6; }
37256 else
37257   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37258 $as_echo "no" >&6; }
37259 fi
37260 
37261 
37262         if test "x$NM" = x; then
37263           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37264         fi
37265       else
37266         # Otherwise we believe it is a complete path. Use it as it is.
37267         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
37268 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
37269         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
37270 $as_echo_n "checking for NM... " >&6; }
37271         if test ! -x "$tool_specified"; then
37272           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37273 $as_echo "not found" >&6; }
37274           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
37275         fi
37276         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37277 $as_echo "$tool_specified" >&6; }
37278       fi
37279     fi
37280   fi
37281 
37282 
37283 
37284   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37285 
37286   # First separate the path from the arguments. This will split at the first
37287   # space.
37288   complete="$NM"
37289   path="${complete%% *}"
37290   tmp="$complete EOL"
37291   arguments="${tmp#* }"
37292 
37293   # Input might be given as Windows format, start by converting to
37294   # unix format.
37295   new_path=`$CYGPATH -u "$path"`
37296 
37297   # Now try to locate executable using which
37298   new_path=`$WHICH "$new_path" 2> /dev/null`
37299   # bat and cmd files are not always considered executable in cygwin causing which
37300   # to not find them
37301   if test "x$new_path" = x \
37302       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37303       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37304     new_path=`$CYGPATH -u "$path"`
37305   fi
37306   if test "x$new_path" = x; then
37307     # Oops. Which didn't find the executable.
37308     # The splitting of arguments from the executable at a space might have been incorrect,
37309     # since paths with space are more likely in Windows. Give it another try with the whole
37310     # argument.
37311     path="$complete"
37312     arguments="EOL"
37313     new_path=`$CYGPATH -u "$path"`
37314     new_path=`$WHICH "$new_path" 2> /dev/null`
37315     # bat and cmd files are not always considered executable in cygwin causing which
37316     # to not find them
37317     if test "x$new_path" = x \
37318         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37319         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37320       new_path=`$CYGPATH -u "$path"`
37321     fi
37322     if test "x$new_path" = x; then
37323       # It's still not found. Now this is an unrecoverable error.
37324       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37325 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37326       has_space=`$ECHO "$complete" | $GREP " "`
37327       if test "x$has_space" != x; then
37328         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37329 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37330       fi
37331       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37332     fi
37333   fi
37334 
37335   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37336   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37337   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37338   # "foo.exe" is OK but "foo" is an error.
37339   #
37340   # This test is therefore slightly more accurate than "test -f" to check for file presence.
37341   # It is also a way to make sure we got the proper file name for the real test later on.
37342   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37343   if test "x$test_shortpath" = x; then
37344     # Short path failed, file does not exist as specified.
37345     # Try adding .exe or .cmd
37346     if test -f "${new_path}.exe"; then
37347       input_to_shortpath="${new_path}.exe"
37348     elif test -f "${new_path}.cmd"; then
37349       input_to_shortpath="${new_path}.cmd"
37350     else
37351       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
37352 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
37353       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37354 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37355       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37356     fi
37357   else
37358     input_to_shortpath="$new_path"
37359   fi
37360 
37361   # Call helper function which possibly converts this using DOS-style short mode.
37362   # If so, the updated path is stored in $new_path.
37363   new_path="$input_to_shortpath"
37364 
37365   input_path="$input_to_shortpath"
37366   # Check if we need to convert this using DOS-style short mode. If the path
37367   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37368   # take no chances and rewrite it.
37369   # Note: m4 eats our [], so we need to use [ and ] instead.
37370   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37371   if test "x$has_forbidden_chars" != x; then
37372     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37373     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37374     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37375     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37376       # Going to short mode and back again did indeed matter. Since short mode is
37377       # case insensitive, let's make it lowercase to improve readability.
37378       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37379       # Now convert it back to Unix-stile (cygpath)
37380       input_path=`$CYGPATH -u "$shortmode_path"`
37381       new_path="$input_path"
37382     fi
37383   fi
37384 
37385   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37386   if test "x$test_cygdrive_prefix" = x; then
37387     # As a simple fix, exclude /usr/bin since it's not a real path.
37388     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37389       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37390       # a path prefixed by /cygdrive for fixpath to work.
37391       new_path="$CYGWIN_ROOT_PATH$input_path"
37392     fi
37393   fi
37394 
37395   # remove trailing .exe if any
37396   new_path="${new_path/%.exe/}"
37397 
37398   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37399 
37400   # First separate the path from the arguments. This will split at the first
37401   # space.
37402   complete="$NM"
37403   path="${complete%% *}"
37404   tmp="$complete EOL"
37405   arguments="${tmp#* }"
37406 
37407   # Input might be given as Windows format, start by converting to
37408   # unix format.
37409   new_path="$path"
37410 
37411   windows_path="$new_path"
37412   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37413     unix_path=`$CYGPATH -u "$windows_path"`
37414     new_path="$unix_path"
37415   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37416     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37417     new_path="$unix_path"
37418   fi
37419 
37420 
37421   # Now try to locate executable using which
37422   new_path=`$WHICH "$new_path" 2> /dev/null`
37423 
37424   if test "x$new_path" = x; then
37425     # Oops. Which didn't find the executable.
37426     # The splitting of arguments from the executable at a space might have been incorrect,
37427     # since paths with space are more likely in Windows. Give it another try with the whole
37428     # argument.
37429     path="$complete"
37430     arguments="EOL"
37431     new_path="$path"
37432 
37433   windows_path="$new_path"
37434   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37435     unix_path=`$CYGPATH -u "$windows_path"`
37436     new_path="$unix_path"
37437   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37438     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37439     new_path="$unix_path"
37440   fi
37441 
37442 
37443     new_path=`$WHICH "$new_path" 2> /dev/null`
37444 
37445     if test "x$new_path" = x; then
37446       # It's still not found. Now this is an unrecoverable error.
37447       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37448 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37449       has_space=`$ECHO "$complete" | $GREP " "`
37450       if test "x$has_space" != x; then
37451         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37452 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37453       fi
37454       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37455     fi
37456   fi
37457 
37458   # Now new_path has a complete unix path to the binary
37459   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37460     # Keep paths in /bin as-is, but remove trailing .exe if any
37461     new_path="${new_path/%.exe/}"
37462     # Do not save /bin paths to all_fixpath_prefixes!
37463   else
37464     # Not in mixed or Windows style, start by that.
37465     new_path=`cmd //c echo $new_path`
37466 
37467   input_path="$new_path"
37468   # Check if we need to convert this using DOS-style short mode. If the path
37469   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37470   # take no chances and rewrite it.
37471   # Note: m4 eats our [], so we need to use [ and ] instead.
37472   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37473   if test "x$has_forbidden_chars" != x; then
37474     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37475     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37476   fi
37477 
37478     # Output is in $new_path
37479 
37480   windows_path="$new_path"
37481   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37482     unix_path=`$CYGPATH -u "$windows_path"`
37483     new_path="$unix_path"
37484   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37485     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37486     new_path="$unix_path"
37487   fi
37488 
37489     # remove trailing .exe if any
37490     new_path="${new_path/%.exe/}"
37491 
37492     # Save the first 10 bytes of this path to the storage, so fixpath can work.
37493     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37494   fi
37495 
37496   else
37497     # We're on a posix platform. Hooray! :)
37498     # First separate the path from the arguments. This will split at the first
37499     # space.
37500     complete="$NM"
37501     path="${complete%% *}"
37502     tmp="$complete EOL"
37503     arguments="${tmp#* }"
37504 
37505     # Cannot rely on the command "which" here since it doesn't always work.
37506     is_absolute_path=`$ECHO "$path" | $GREP ^/`
37507     if test -z "$is_absolute_path"; then
37508       # Path to executable is not absolute. Find it.
37509       IFS_save="$IFS"
37510       IFS=:
37511       for p in $PATH; do
37512         if test -f "$p/$path" && test -x "$p/$path"; then
37513           new_path="$p/$path"
37514           break
37515         fi
37516       done
37517       IFS="$IFS_save"
37518     else
37519       # This is an absolute path, we can use it without further modifications.
37520       new_path="$path"
37521     fi
37522 
37523     if test "x$new_path" = x; then
37524       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37525 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37526       has_space=`$ECHO "$complete" | $GREP " "`
37527       if test "x$has_space" != x; then
37528         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37529 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37530       fi
37531       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37532     fi
37533   fi
37534 
37535   # Now join together the path and the arguments once again
37536   if test "x$arguments" != xEOL; then
37537     new_complete="$new_path ${arguments% *}"
37538   else
37539     new_complete="$new_path"
37540   fi
37541 
37542   if test "x$complete" != "x$new_complete"; then
37543     NM="$new_complete"
37544     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
37545 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
37546   fi
37547 
37548     GNM="$NM"
37549 
37550   fi
37551 
37552   # objcopy is used for moving debug symbols to separate files when
37553   # full debug symbols are enabled.
37554   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
37555 
37556 
37557   # Publish this variable in the help.
37558 
37559 
37560   if test "x$OBJCOPY" = x; then
37561     # The variable is not set by user, try to locate tool using the code snippet
37562     if test -n "$ac_tool_prefix"; then
37563   for ac_prog in gobjcopy objcopy
37564   do
37565     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37566 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37568 $as_echo_n "checking for $ac_word... " >&6; }
37569 if ${ac_cv_prog_OBJCOPY+:} false; then :
37570   $as_echo_n "(cached) " >&6
37571 else
37572   if test -n "$OBJCOPY"; then
37573   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37574 else
37575 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37576 for as_dir in $PATH
37577 do
37578   IFS=$as_save_IFS
37579   test -z "$as_dir" && as_dir=.
37580     for ac_exec_ext in '' $ac_executable_extensions; do
37581   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37582     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37583     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37584     break 2
37585   fi
37586 done
37587   done
37588 IFS=$as_save_IFS
37589 
37590 fi
37591 fi
37592 OBJCOPY=$ac_cv_prog_OBJCOPY
37593 if test -n "$OBJCOPY"; then
37594   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37595 $as_echo "$OBJCOPY" >&6; }
37596 else
37597   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37598 $as_echo "no" >&6; }
37599 fi
37600 
37601 
37602     test -n "$OBJCOPY" && break
37603   done
37604 fi
37605 if test -z "$OBJCOPY"; then
37606   ac_ct_OBJCOPY=$OBJCOPY
37607   for ac_prog in gobjcopy objcopy
37608 do
37609   # Extract the first word of "$ac_prog", so it can be a program name with args.
37610 set dummy $ac_prog; ac_word=$2
37611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37612 $as_echo_n "checking for $ac_word... " >&6; }
37613 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37614   $as_echo_n "(cached) " >&6
37615 else
37616   if test -n "$ac_ct_OBJCOPY"; then
37617   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37618 else
37619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37620 for as_dir in $PATH
37621 do
37622   IFS=$as_save_IFS
37623   test -z "$as_dir" && as_dir=.
37624     for ac_exec_ext in '' $ac_executable_extensions; do
37625   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37626     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37627     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37628     break 2
37629   fi
37630 done
37631   done
37632 IFS=$as_save_IFS
37633 
37634 fi
37635 fi
37636 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37637 if test -n "$ac_ct_OBJCOPY"; then
37638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37639 $as_echo "$ac_ct_OBJCOPY" >&6; }
37640 else
37641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37642 $as_echo "no" >&6; }
37643 fi
37644 
37645 
37646   test -n "$ac_ct_OBJCOPY" && break
37647 done
37648 
37649   if test "x$ac_ct_OBJCOPY" = x; then
37650     OBJCOPY=""
37651   else
37652     case $cross_compiling:$ac_tool_warned in
37653 yes:)
37654 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37655 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37656 ac_tool_warned=yes ;;
37657 esac
37658     OBJCOPY=$ac_ct_OBJCOPY
37659   fi
37660 fi
37661 
37662   else
37663     # The variable is set, but is it from the command line or the environment?
37664 
37665     # Try to remove the string !OBJCOPY! from our list.
37666     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
37667     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37668       # If it failed, the variable was not from the command line. Ignore it,
37669       # but warn the user (except for BASH, which is always set by the calling BASH).
37670       if test "xOBJCOPY" != xBASH; then
37671         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
37672 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
37673       fi
37674       # Try to locate tool using the code snippet
37675       if test -n "$ac_tool_prefix"; then
37676   for ac_prog in gobjcopy objcopy
37677   do
37678     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37679 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37681 $as_echo_n "checking for $ac_word... " >&6; }
37682 if ${ac_cv_prog_OBJCOPY+:} false; then :
37683   $as_echo_n "(cached) " >&6
37684 else
37685   if test -n "$OBJCOPY"; then
37686   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37687 else
37688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37689 for as_dir in $PATH
37690 do
37691   IFS=$as_save_IFS
37692   test -z "$as_dir" && as_dir=.
37693     for ac_exec_ext in '' $ac_executable_extensions; do
37694   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37695     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37696     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37697     break 2
37698   fi
37699 done
37700   done
37701 IFS=$as_save_IFS
37702 
37703 fi
37704 fi
37705 OBJCOPY=$ac_cv_prog_OBJCOPY
37706 if test -n "$OBJCOPY"; then
37707   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37708 $as_echo "$OBJCOPY" >&6; }
37709 else
37710   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37711 $as_echo "no" >&6; }
37712 fi
37713 
37714 
37715     test -n "$OBJCOPY" && break
37716   done
37717 fi
37718 if test -z "$OBJCOPY"; then
37719   ac_ct_OBJCOPY=$OBJCOPY
37720   for ac_prog in gobjcopy objcopy
37721 do
37722   # Extract the first word of "$ac_prog", so it can be a program name with args.
37723 set dummy $ac_prog; ac_word=$2
37724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37725 $as_echo_n "checking for $ac_word... " >&6; }
37726 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37727   $as_echo_n "(cached) " >&6
37728 else
37729   if test -n "$ac_ct_OBJCOPY"; then
37730   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37731 else
37732 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37733 for as_dir in $PATH
37734 do
37735   IFS=$as_save_IFS
37736   test -z "$as_dir" && as_dir=.
37737     for ac_exec_ext in '' $ac_executable_extensions; do
37738   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37739     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37740     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37741     break 2
37742   fi
37743 done
37744   done
37745 IFS=$as_save_IFS
37746 
37747 fi
37748 fi
37749 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37750 if test -n "$ac_ct_OBJCOPY"; then
37751   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37752 $as_echo "$ac_ct_OBJCOPY" >&6; }
37753 else
37754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37755 $as_echo "no" >&6; }
37756 fi
37757 
37758 
37759   test -n "$ac_ct_OBJCOPY" && break
37760 done
37761 
37762   if test "x$ac_ct_OBJCOPY" = x; then
37763     OBJCOPY=""
37764   else
37765     case $cross_compiling:$ac_tool_warned in
37766 yes:)
37767 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37768 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37769 ac_tool_warned=yes ;;
37770 esac
37771     OBJCOPY=$ac_ct_OBJCOPY
37772   fi
37773 fi
37774 
37775     else
37776       # If it succeeded, then it was overridden by the user. We will use it
37777       # for the tool.
37778 
37779       # First remove it from the list of overridden variables, so we can test
37780       # for unknown variables in the end.
37781       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37782 
37783       # Check if the provided tool contains a complete path.
37784       tool_specified="$OBJCOPY"
37785       tool_basename="${tool_specified##*/}"
37786       if test "x$tool_basename" = "x$tool_specified"; then
37787         # A command without a complete path is provided, search $PATH.
37788         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
37789 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
37790         # Extract the first word of "$tool_basename", so it can be a program name with args.
37791 set dummy $tool_basename; ac_word=$2
37792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37793 $as_echo_n "checking for $ac_word... " >&6; }
37794 if ${ac_cv_path_OBJCOPY+:} false; then :
37795   $as_echo_n "(cached) " >&6
37796 else
37797   case $OBJCOPY in
37798   [\\/]* | ?:[\\/]*)
37799   ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
37800   ;;
37801   *)
37802   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37803 for as_dir in $PATH
37804 do
37805   IFS=$as_save_IFS
37806   test -z "$as_dir" && as_dir=.
37807     for ac_exec_ext in '' $ac_executable_extensions; do
37808   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37809     ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
37810     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37811     break 2
37812   fi
37813 done
37814   done
37815 IFS=$as_save_IFS
37816 
37817   ;;
37818 esac
37819 fi
37820 OBJCOPY=$ac_cv_path_OBJCOPY
37821 if test -n "$OBJCOPY"; then
37822   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37823 $as_echo "$OBJCOPY" >&6; }
37824 else
37825   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37826 $as_echo "no" >&6; }
37827 fi
37828 
37829 
37830         if test "x$OBJCOPY" = x; then
37831           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37832         fi
37833       else
37834         # Otherwise we believe it is a complete path. Use it as it is.
37835         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
37836 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
37837         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
37838 $as_echo_n "checking for OBJCOPY... " >&6; }
37839         if test ! -x "$tool_specified"; then
37840           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37841 $as_echo "not found" >&6; }
37842           as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
37843         fi
37844         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37845 $as_echo "$tool_specified" >&6; }
37846       fi
37847     fi
37848   fi
37849 
37850 
37851     # Only call fixup if objcopy was found.
37852     if test -n "$OBJCOPY"; then
37853 
37854   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37855 
37856   # First separate the path from the arguments. This will split at the first
37857   # space.
37858   complete="$OBJCOPY"
37859   path="${complete%% *}"
37860   tmp="$complete EOL"
37861   arguments="${tmp#* }"
37862 
37863   # Input might be given as Windows format, start by converting to
37864   # unix format.
37865   new_path=`$CYGPATH -u "$path"`
37866 
37867   # Now try to locate executable using which
37868   new_path=`$WHICH "$new_path" 2> /dev/null`
37869   # bat and cmd files are not always considered executable in cygwin causing which
37870   # to not find them
37871   if test "x$new_path" = x \
37872       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37873       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37874     new_path=`$CYGPATH -u "$path"`
37875   fi
37876   if test "x$new_path" = x; then
37877     # Oops. Which didn't find the executable.
37878     # The splitting of arguments from the executable at a space might have been incorrect,
37879     # since paths with space are more likely in Windows. Give it another try with the whole
37880     # argument.
37881     path="$complete"
37882     arguments="EOL"
37883     new_path=`$CYGPATH -u "$path"`
37884     new_path=`$WHICH "$new_path" 2> /dev/null`
37885     # bat and cmd files are not always considered executable in cygwin causing which
37886     # to not find them
37887     if test "x$new_path" = x \
37888         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37889         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37890       new_path=`$CYGPATH -u "$path"`
37891     fi
37892     if test "x$new_path" = x; then
37893       # It's still not found. Now this is an unrecoverable error.
37894       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37895 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37896       has_space=`$ECHO "$complete" | $GREP " "`
37897       if test "x$has_space" != x; then
37898         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37899 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37900       fi
37901       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37902     fi
37903   fi
37904 
37905   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37906   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37907   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37908   # "foo.exe" is OK but "foo" is an error.
37909   #
37910   # This test is therefore slightly more accurate than "test -f" to check for file presence.
37911   # It is also a way to make sure we got the proper file name for the real test later on.
37912   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37913   if test "x$test_shortpath" = x; then
37914     # Short path failed, file does not exist as specified.
37915     # Try adding .exe or .cmd
37916     if test -f "${new_path}.exe"; then
37917       input_to_shortpath="${new_path}.exe"
37918     elif test -f "${new_path}.cmd"; then
37919       input_to_shortpath="${new_path}.cmd"
37920     else
37921       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
37922 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
37923       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37924 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37925       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37926     fi
37927   else
37928     input_to_shortpath="$new_path"
37929   fi
37930 
37931   # Call helper function which possibly converts this using DOS-style short mode.
37932   # If so, the updated path is stored in $new_path.
37933   new_path="$input_to_shortpath"
37934 
37935   input_path="$input_to_shortpath"
37936   # Check if we need to convert this using DOS-style short mode. If the path
37937   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37938   # take no chances and rewrite it.
37939   # Note: m4 eats our [], so we need to use [ and ] instead.
37940   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37941   if test "x$has_forbidden_chars" != x; then
37942     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37943     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37944     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37945     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37946       # Going to short mode and back again did indeed matter. Since short mode is
37947       # case insensitive, let's make it lowercase to improve readability.
37948       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37949       # Now convert it back to Unix-stile (cygpath)
37950       input_path=`$CYGPATH -u "$shortmode_path"`
37951       new_path="$input_path"
37952     fi
37953   fi
37954 
37955   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37956   if test "x$test_cygdrive_prefix" = x; then
37957     # As a simple fix, exclude /usr/bin since it's not a real path.
37958     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37959       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37960       # a path prefixed by /cygdrive for fixpath to work.
37961       new_path="$CYGWIN_ROOT_PATH$input_path"
37962     fi
37963   fi
37964 
37965   # remove trailing .exe if any
37966   new_path="${new_path/%.exe/}"
37967 
37968   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37969 
37970   # First separate the path from the arguments. This will split at the first
37971   # space.
37972   complete="$OBJCOPY"
37973   path="${complete%% *}"
37974   tmp="$complete EOL"
37975   arguments="${tmp#* }"
37976 
37977   # Input might be given as Windows format, start by converting to
37978   # unix format.
37979   new_path="$path"
37980 
37981   windows_path="$new_path"
37982   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37983     unix_path=`$CYGPATH -u "$windows_path"`
37984     new_path="$unix_path"
37985   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37986     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37987     new_path="$unix_path"
37988   fi
37989 
37990 
37991   # Now try to locate executable using which
37992   new_path=`$WHICH "$new_path" 2> /dev/null`
37993 
37994   if test "x$new_path" = x; then
37995     # Oops. Which didn't find the executable.
37996     # The splitting of arguments from the executable at a space might have been incorrect,
37997     # since paths with space are more likely in Windows. Give it another try with the whole
37998     # argument.
37999     path="$complete"
38000     arguments="EOL"
38001     new_path="$path"
38002 
38003   windows_path="$new_path"
38004   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38005     unix_path=`$CYGPATH -u "$windows_path"`
38006     new_path="$unix_path"
38007   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38008     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38009     new_path="$unix_path"
38010   fi
38011 
38012 
38013     new_path=`$WHICH "$new_path" 2> /dev/null`
38014 
38015     if test "x$new_path" = x; then
38016       # It's still not found. Now this is an unrecoverable error.
38017       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38018 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38019       has_space=`$ECHO "$complete" | $GREP " "`
38020       if test "x$has_space" != x; then
38021         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38022 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38023       fi
38024       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38025     fi
38026   fi
38027 
38028   # Now new_path has a complete unix path to the binary
38029   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38030     # Keep paths in /bin as-is, but remove trailing .exe if any
38031     new_path="${new_path/%.exe/}"
38032     # Do not save /bin paths to all_fixpath_prefixes!
38033   else
38034     # Not in mixed or Windows style, start by that.
38035     new_path=`cmd //c echo $new_path`
38036 
38037   input_path="$new_path"
38038   # Check if we need to convert this using DOS-style short mode. If the path
38039   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38040   # take no chances and rewrite it.
38041   # Note: m4 eats our [], so we need to use [ and ] instead.
38042   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38043   if test "x$has_forbidden_chars" != x; then
38044     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38045     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38046   fi
38047 
38048     # Output is in $new_path
38049 
38050   windows_path="$new_path"
38051   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38052     unix_path=`$CYGPATH -u "$windows_path"`
38053     new_path="$unix_path"
38054   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38055     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38056     new_path="$unix_path"
38057   fi
38058 
38059     # remove trailing .exe if any
38060     new_path="${new_path/%.exe/}"
38061 
38062     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38063     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38064   fi
38065 
38066   else
38067     # We're on a posix platform. Hooray! :)
38068     # First separate the path from the arguments. This will split at the first
38069     # space.
38070     complete="$OBJCOPY"
38071     path="${complete%% *}"
38072     tmp="$complete EOL"
38073     arguments="${tmp#* }"
38074 
38075     # Cannot rely on the command "which" here since it doesn't always work.
38076     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38077     if test -z "$is_absolute_path"; then
38078       # Path to executable is not absolute. Find it.
38079       IFS_save="$IFS"
38080       IFS=:
38081       for p in $PATH; do
38082         if test -f "$p/$path" && test -x "$p/$path"; then
38083           new_path="$p/$path"
38084           break
38085         fi
38086       done
38087       IFS="$IFS_save"
38088     else
38089       # This is an absolute path, we can use it without further modifications.
38090       new_path="$path"
38091     fi
38092 
38093     if test "x$new_path" = x; then
38094       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38095 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38096       has_space=`$ECHO "$complete" | $GREP " "`
38097       if test "x$has_space" != x; then
38098         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38099 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38100       fi
38101       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38102     fi
38103   fi
38104 
38105   # Now join together the path and the arguments once again
38106   if test "x$arguments" != xEOL; then
38107     new_complete="$new_path ${arguments% *}"
38108   else
38109     new_complete="$new_path"
38110   fi
38111 
38112   if test "x$complete" != "x$new_complete"; then
38113     OBJCOPY="$new_complete"
38114     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
38115 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
38116   fi
38117 
38118     fi
38119   fi
38120 
38121 
38122 
38123   # Publish this variable in the help.
38124 
38125 
38126   if test "x$OBJDUMP" = x; then
38127     # The variable is not set by user, try to locate tool using the code snippet
38128     if test -n "$ac_tool_prefix"; then
38129   for ac_prog in gobjdump objdump
38130   do
38131     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38132 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38134 $as_echo_n "checking for $ac_word... " >&6; }
38135 if ${ac_cv_prog_OBJDUMP+:} false; then :
38136   $as_echo_n "(cached) " >&6
38137 else
38138   if test -n "$OBJDUMP"; then
38139   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38140 else
38141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38142 for as_dir in $PATH
38143 do
38144   IFS=$as_save_IFS
38145   test -z "$as_dir" && as_dir=.
38146     for ac_exec_ext in '' $ac_executable_extensions; do
38147   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38148     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38149     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38150     break 2
38151   fi
38152 done
38153   done
38154 IFS=$as_save_IFS
38155 
38156 fi
38157 fi
38158 OBJDUMP=$ac_cv_prog_OBJDUMP
38159 if test -n "$OBJDUMP"; then
38160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38161 $as_echo "$OBJDUMP" >&6; }
38162 else
38163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38164 $as_echo "no" >&6; }
38165 fi
38166 
38167 
38168     test -n "$OBJDUMP" && break
38169   done
38170 fi
38171 if test -z "$OBJDUMP"; then
38172   ac_ct_OBJDUMP=$OBJDUMP
38173   for ac_prog in gobjdump objdump
38174 do
38175   # Extract the first word of "$ac_prog", so it can be a program name with args.
38176 set dummy $ac_prog; ac_word=$2
38177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38178 $as_echo_n "checking for $ac_word... " >&6; }
38179 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38180   $as_echo_n "(cached) " >&6
38181 else
38182   if test -n "$ac_ct_OBJDUMP"; then
38183   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38184 else
38185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38186 for as_dir in $PATH
38187 do
38188   IFS=$as_save_IFS
38189   test -z "$as_dir" && as_dir=.
38190     for ac_exec_ext in '' $ac_executable_extensions; do
38191   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38192     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38193     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38194     break 2
38195   fi
38196 done
38197   done
38198 IFS=$as_save_IFS
38199 
38200 fi
38201 fi
38202 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38203 if test -n "$ac_ct_OBJDUMP"; then
38204   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38205 $as_echo "$ac_ct_OBJDUMP" >&6; }
38206 else
38207   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38208 $as_echo "no" >&6; }
38209 fi
38210 
38211 
38212   test -n "$ac_ct_OBJDUMP" && break
38213 done
38214 
38215   if test "x$ac_ct_OBJDUMP" = x; then
38216     OBJDUMP=""
38217   else
38218     case $cross_compiling:$ac_tool_warned in
38219 yes:)
38220 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38221 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38222 ac_tool_warned=yes ;;
38223 esac
38224     OBJDUMP=$ac_ct_OBJDUMP
38225   fi
38226 fi
38227 
38228   else
38229     # The variable is set, but is it from the command line or the environment?
38230 
38231     # Try to remove the string !OBJDUMP! from our list.
38232     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
38233     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38234       # If it failed, the variable was not from the command line. Ignore it,
38235       # but warn the user (except for BASH, which is always set by the calling BASH).
38236       if test "xOBJDUMP" != xBASH; then
38237         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
38238 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
38239       fi
38240       # Try to locate tool using the code snippet
38241       if test -n "$ac_tool_prefix"; then
38242   for ac_prog in gobjdump objdump
38243   do
38244     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38245 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38247 $as_echo_n "checking for $ac_word... " >&6; }
38248 if ${ac_cv_prog_OBJDUMP+:} false; then :
38249   $as_echo_n "(cached) " >&6
38250 else
38251   if test -n "$OBJDUMP"; then
38252   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38253 else
38254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38255 for as_dir in $PATH
38256 do
38257   IFS=$as_save_IFS
38258   test -z "$as_dir" && as_dir=.
38259     for ac_exec_ext in '' $ac_executable_extensions; do
38260   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38261     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38262     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38263     break 2
38264   fi
38265 done
38266   done
38267 IFS=$as_save_IFS
38268 
38269 fi
38270 fi
38271 OBJDUMP=$ac_cv_prog_OBJDUMP
38272 if test -n "$OBJDUMP"; then
38273   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38274 $as_echo "$OBJDUMP" >&6; }
38275 else
38276   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38277 $as_echo "no" >&6; }
38278 fi
38279 
38280 
38281     test -n "$OBJDUMP" && break
38282   done
38283 fi
38284 if test -z "$OBJDUMP"; then
38285   ac_ct_OBJDUMP=$OBJDUMP
38286   for ac_prog in gobjdump objdump
38287 do
38288   # Extract the first word of "$ac_prog", so it can be a program name with args.
38289 set dummy $ac_prog; ac_word=$2
38290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38291 $as_echo_n "checking for $ac_word... " >&6; }
38292 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38293   $as_echo_n "(cached) " >&6
38294 else
38295   if test -n "$ac_ct_OBJDUMP"; then
38296   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38297 else
38298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38299 for as_dir in $PATH
38300 do
38301   IFS=$as_save_IFS
38302   test -z "$as_dir" && as_dir=.
38303     for ac_exec_ext in '' $ac_executable_extensions; do
38304   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38305     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38306     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38307     break 2
38308   fi
38309 done
38310   done
38311 IFS=$as_save_IFS
38312 
38313 fi
38314 fi
38315 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38316 if test -n "$ac_ct_OBJDUMP"; then
38317   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38318 $as_echo "$ac_ct_OBJDUMP" >&6; }
38319 else
38320   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38321 $as_echo "no" >&6; }
38322 fi
38323 
38324 
38325   test -n "$ac_ct_OBJDUMP" && break
38326 done
38327 
38328   if test "x$ac_ct_OBJDUMP" = x; then
38329     OBJDUMP=""
38330   else
38331     case $cross_compiling:$ac_tool_warned in
38332 yes:)
38333 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38334 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38335 ac_tool_warned=yes ;;
38336 esac
38337     OBJDUMP=$ac_ct_OBJDUMP
38338   fi
38339 fi
38340 
38341     else
38342       # If it succeeded, then it was overridden by the user. We will use it
38343       # for the tool.
38344 
38345       # First remove it from the list of overridden variables, so we can test
38346       # for unknown variables in the end.
38347       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38348 
38349       # Check if the provided tool contains a complete path.
38350       tool_specified="$OBJDUMP"
38351       tool_basename="${tool_specified##*/}"
38352       if test "x$tool_basename" = "x$tool_specified"; then
38353         # A command without a complete path is provided, search $PATH.
38354         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
38355 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
38356         # Extract the first word of "$tool_basename", so it can be a program name with args.
38357 set dummy $tool_basename; ac_word=$2
38358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38359 $as_echo_n "checking for $ac_word... " >&6; }
38360 if ${ac_cv_path_OBJDUMP+:} false; then :
38361   $as_echo_n "(cached) " >&6
38362 else
38363   case $OBJDUMP in
38364   [\\/]* | ?:[\\/]*)
38365   ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
38366   ;;
38367   *)
38368   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38369 for as_dir in $PATH
38370 do
38371   IFS=$as_save_IFS
38372   test -z "$as_dir" && as_dir=.
38373     for ac_exec_ext in '' $ac_executable_extensions; do
38374   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38375     ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
38376     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38377     break 2
38378   fi
38379 done
38380   done
38381 IFS=$as_save_IFS
38382 
38383   ;;
38384 esac
38385 fi
38386 OBJDUMP=$ac_cv_path_OBJDUMP
38387 if test -n "$OBJDUMP"; then
38388   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38389 $as_echo "$OBJDUMP" >&6; }
38390 else
38391   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38392 $as_echo "no" >&6; }
38393 fi
38394 
38395 
38396         if test "x$OBJDUMP" = x; then
38397           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38398         fi
38399       else
38400         # Otherwise we believe it is a complete path. Use it as it is.
38401         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
38402 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
38403         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
38404 $as_echo_n "checking for OBJDUMP... " >&6; }
38405         if test ! -x "$tool_specified"; then
38406           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38407 $as_echo "not found" >&6; }
38408           as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
38409         fi
38410         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38411 $as_echo "$tool_specified" >&6; }
38412       fi
38413     fi
38414   fi
38415 
38416 
38417   if test "x$OBJDUMP" != x; then
38418     # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE
38419     # bails if argument is missing.
38420 
38421   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38422 
38423   # First separate the path from the arguments. This will split at the first
38424   # space.
38425   complete="$OBJDUMP"
38426   path="${complete%% *}"
38427   tmp="$complete EOL"
38428   arguments="${tmp#* }"
38429 
38430   # Input might be given as Windows format, start by converting to
38431   # unix format.
38432   new_path=`$CYGPATH -u "$path"`
38433 
38434   # Now try to locate executable using which
38435   new_path=`$WHICH "$new_path" 2> /dev/null`
38436   # bat and cmd files are not always considered executable in cygwin causing which
38437   # to not find them
38438   if test "x$new_path" = x \
38439       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38440       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38441     new_path=`$CYGPATH -u "$path"`
38442   fi
38443   if test "x$new_path" = x; then
38444     # Oops. Which didn't find the executable.
38445     # The splitting of arguments from the executable at a space might have been incorrect,
38446     # since paths with space are more likely in Windows. Give it another try with the whole
38447     # argument.
38448     path="$complete"
38449     arguments="EOL"
38450     new_path=`$CYGPATH -u "$path"`
38451     new_path=`$WHICH "$new_path" 2> /dev/null`
38452     # bat and cmd files are not always considered executable in cygwin causing which
38453     # to not find them
38454     if test "x$new_path" = x \
38455         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38456         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38457       new_path=`$CYGPATH -u "$path"`
38458     fi
38459     if test "x$new_path" = x; then
38460       # It's still not found. Now this is an unrecoverable error.
38461       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38462 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38463       has_space=`$ECHO "$complete" | $GREP " "`
38464       if test "x$has_space" != x; then
38465         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38466 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38467       fi
38468       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38469     fi
38470   fi
38471 
38472   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38473   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38474   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38475   # "foo.exe" is OK but "foo" is an error.
38476   #
38477   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38478   # It is also a way to make sure we got the proper file name for the real test later on.
38479   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38480   if test "x$test_shortpath" = x; then
38481     # Short path failed, file does not exist as specified.
38482     # Try adding .exe or .cmd
38483     if test -f "${new_path}.exe"; then
38484       input_to_shortpath="${new_path}.exe"
38485     elif test -f "${new_path}.cmd"; then
38486       input_to_shortpath="${new_path}.cmd"
38487     else
38488       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
38489 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
38490       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38491 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38492       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38493     fi
38494   else
38495     input_to_shortpath="$new_path"
38496   fi
38497 
38498   # Call helper function which possibly converts this using DOS-style short mode.
38499   # If so, the updated path is stored in $new_path.
38500   new_path="$input_to_shortpath"
38501 
38502   input_path="$input_to_shortpath"
38503   # Check if we need to convert this using DOS-style short mode. If the path
38504   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38505   # take no chances and rewrite it.
38506   # Note: m4 eats our [], so we need to use [ and ] instead.
38507   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38508   if test "x$has_forbidden_chars" != x; then
38509     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38510     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38511     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38512     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38513       # Going to short mode and back again did indeed matter. Since short mode is
38514       # case insensitive, let's make it lowercase to improve readability.
38515       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38516       # Now convert it back to Unix-stile (cygpath)
38517       input_path=`$CYGPATH -u "$shortmode_path"`
38518       new_path="$input_path"
38519     fi
38520   fi
38521 
38522   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38523   if test "x$test_cygdrive_prefix" = x; then
38524     # As a simple fix, exclude /usr/bin since it's not a real path.
38525     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38526       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38527       # a path prefixed by /cygdrive for fixpath to work.
38528       new_path="$CYGWIN_ROOT_PATH$input_path"
38529     fi
38530   fi
38531 
38532   # remove trailing .exe if any
38533   new_path="${new_path/%.exe/}"
38534 
38535   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38536 
38537   # First separate the path from the arguments. This will split at the first
38538   # space.
38539   complete="$OBJDUMP"
38540   path="${complete%% *}"
38541   tmp="$complete EOL"
38542   arguments="${tmp#* }"
38543 
38544   # Input might be given as Windows format, start by converting to
38545   # unix format.
38546   new_path="$path"
38547 
38548   windows_path="$new_path"
38549   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38550     unix_path=`$CYGPATH -u "$windows_path"`
38551     new_path="$unix_path"
38552   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38553     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38554     new_path="$unix_path"
38555   fi
38556 
38557 
38558   # Now try to locate executable using which
38559   new_path=`$WHICH "$new_path" 2> /dev/null`
38560 
38561   if test "x$new_path" = x; then
38562     # Oops. Which didn't find the executable.
38563     # The splitting of arguments from the executable at a space might have been incorrect,
38564     # since paths with space are more likely in Windows. Give it another try with the whole
38565     # argument.
38566     path="$complete"
38567     arguments="EOL"
38568     new_path="$path"
38569 
38570   windows_path="$new_path"
38571   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38572     unix_path=`$CYGPATH -u "$windows_path"`
38573     new_path="$unix_path"
38574   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38575     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38576     new_path="$unix_path"
38577   fi
38578 
38579 
38580     new_path=`$WHICH "$new_path" 2> /dev/null`
38581 
38582     if test "x$new_path" = x; then
38583       # It's still not found. Now this is an unrecoverable error.
38584       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38585 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38586       has_space=`$ECHO "$complete" | $GREP " "`
38587       if test "x$has_space" != x; then
38588         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38589 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38590       fi
38591       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38592     fi
38593   fi
38594 
38595   # Now new_path has a complete unix path to the binary
38596   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38597     # Keep paths in /bin as-is, but remove trailing .exe if any
38598     new_path="${new_path/%.exe/}"
38599     # Do not save /bin paths to all_fixpath_prefixes!
38600   else
38601     # Not in mixed or Windows style, start by that.
38602     new_path=`cmd //c echo $new_path`
38603 
38604   input_path="$new_path"
38605   # Check if we need to convert this using DOS-style short mode. If the path
38606   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38607   # take no chances and rewrite it.
38608   # Note: m4 eats our [], so we need to use [ and ] instead.
38609   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38610   if test "x$has_forbidden_chars" != x; then
38611     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38612     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38613   fi
38614 
38615     # Output is in $new_path
38616 
38617   windows_path="$new_path"
38618   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38619     unix_path=`$CYGPATH -u "$windows_path"`
38620     new_path="$unix_path"
38621   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38622     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38623     new_path="$unix_path"
38624   fi
38625 
38626     # remove trailing .exe if any
38627     new_path="${new_path/%.exe/}"
38628 
38629     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38630     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38631   fi
38632 
38633   else
38634     # We're on a posix platform. Hooray! :)
38635     # First separate the path from the arguments. This will split at the first
38636     # space.
38637     complete="$OBJDUMP"
38638     path="${complete%% *}"
38639     tmp="$complete EOL"
38640     arguments="${tmp#* }"
38641 
38642     # Cannot rely on the command "which" here since it doesn't always work.
38643     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38644     if test -z "$is_absolute_path"; then
38645       # Path to executable is not absolute. Find it.
38646       IFS_save="$IFS"
38647       IFS=:
38648       for p in $PATH; do
38649         if test -f "$p/$path" && test -x "$p/$path"; then
38650           new_path="$p/$path"
38651           break
38652         fi
38653       done
38654       IFS="$IFS_save"
38655     else
38656       # This is an absolute path, we can use it without further modifications.
38657       new_path="$path"
38658     fi
38659 
38660     if test "x$new_path" = x; then
38661       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38662 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38663       has_space=`$ECHO "$complete" | $GREP " "`
38664       if test "x$has_space" != x; then
38665         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38666 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38667       fi
38668       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38669     fi
38670   fi
38671 
38672   # Now join together the path and the arguments once again
38673   if test "x$arguments" != xEOL; then
38674     new_complete="$new_path ${arguments% *}"
38675   else
38676     new_complete="$new_path"
38677   fi
38678 
38679   if test "x$complete" != "x$new_complete"; then
38680     OBJDUMP="$new_complete"
38681     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
38682 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
38683   fi
38684 
38685   fi
38686 
38687 
38688   # Restore old path.
38689   PATH="$OLD_PATH"
38690 
38691   # Restore the flags to the user specified values.
38692   # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
38693   CFLAGS="$ORG_CFLAGS"
38694   CXXFLAGS="$ORG_CXXFLAGS"
38695   OBJCFLAGS="$ORG_OBJCFLAGS"
38696 
38697 
38698 # Finally do some processing after the detection phase
38699 
38700   if test "x$COMPILE_TYPE" = "xcross"; then
38701     # Now we need to find a C/C++ compiler that can build executables for the
38702     # build platform. We can't use the AC_PROG_CC macro, since it can only be
38703     # used once. Also, we need to do this without adding a tools dir to the
38704     # path, otherwise we might pick up cross-compilers which don't use standard
38705     # naming.
38706 
38707     # FIXME: we should list the discovered compilers as an exclude pattern!
38708     # If we do that, we can do this detection before POST_DETECTION, and still
38709     # find the build compilers in the tools dir, if needed.
38710 
38711 
38712   # Publish this variable in the help.
38713 
38714 
38715   if test "x$BUILD_CC" = x; then
38716     # The variable is not set by user, try to locate tool using the code snippet
38717     for ac_prog in cl cc gcc
38718 do
38719   # Extract the first word of "$ac_prog", so it can be a program name with args.
38720 set dummy $ac_prog; ac_word=$2
38721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38722 $as_echo_n "checking for $ac_word... " >&6; }
38723 if ${ac_cv_path_BUILD_CC+:} false; then :
38724   $as_echo_n "(cached) " >&6
38725 else
38726   case $BUILD_CC in
38727   [\\/]* | ?:[\\/]*)
38728   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38729   ;;
38730   *)
38731   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38732 for as_dir in $PATH
38733 do
38734   IFS=$as_save_IFS
38735   test -z "$as_dir" && as_dir=.
38736     for ac_exec_ext in '' $ac_executable_extensions; do
38737   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38738     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38739     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38740     break 2
38741   fi
38742 done
38743   done
38744 IFS=$as_save_IFS
38745 
38746   ;;
38747 esac
38748 fi
38749 BUILD_CC=$ac_cv_path_BUILD_CC
38750 if test -n "$BUILD_CC"; then
38751   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38752 $as_echo "$BUILD_CC" >&6; }
38753 else
38754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38755 $as_echo "no" >&6; }
38756 fi
38757 
38758 
38759   test -n "$BUILD_CC" && break
38760 done
38761 
38762   else
38763     # The variable is set, but is it from the command line or the environment?
38764 
38765     # Try to remove the string !BUILD_CC! from our list.
38766     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
38767     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38768       # If it failed, the variable was not from the command line. Ignore it,
38769       # but warn the user (except for BASH, which is always set by the calling BASH).
38770       if test "xBUILD_CC" != xBASH; then
38771         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
38772 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
38773       fi
38774       # Try to locate tool using the code snippet
38775       for ac_prog in cl cc gcc
38776 do
38777   # Extract the first word of "$ac_prog", so it can be a program name with args.
38778 set dummy $ac_prog; ac_word=$2
38779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38780 $as_echo_n "checking for $ac_word... " >&6; }
38781 if ${ac_cv_path_BUILD_CC+:} false; then :
38782   $as_echo_n "(cached) " >&6
38783 else
38784   case $BUILD_CC in
38785   [\\/]* | ?:[\\/]*)
38786   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38787   ;;
38788   *)
38789   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38790 for as_dir in $PATH
38791 do
38792   IFS=$as_save_IFS
38793   test -z "$as_dir" && as_dir=.
38794     for ac_exec_ext in '' $ac_executable_extensions; do
38795   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38796     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38797     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38798     break 2
38799   fi
38800 done
38801   done
38802 IFS=$as_save_IFS
38803 
38804   ;;
38805 esac
38806 fi
38807 BUILD_CC=$ac_cv_path_BUILD_CC
38808 if test -n "$BUILD_CC"; then
38809   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38810 $as_echo "$BUILD_CC" >&6; }
38811 else
38812   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38813 $as_echo "no" >&6; }
38814 fi
38815 
38816 
38817   test -n "$BUILD_CC" && break
38818 done
38819 
38820     else
38821       # If it succeeded, then it was overridden by the user. We will use it
38822       # for the tool.
38823 
38824       # First remove it from the list of overridden variables, so we can test
38825       # for unknown variables in the end.
38826       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38827 
38828       # Check if the provided tool contains a complete path.
38829       tool_specified="$BUILD_CC"
38830       tool_basename="${tool_specified##*/}"
38831       if test "x$tool_basename" = "x$tool_specified"; then
38832         # A command without a complete path is provided, search $PATH.
38833         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
38834 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
38835         # Extract the first word of "$tool_basename", so it can be a program name with args.
38836 set dummy $tool_basename; ac_word=$2
38837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38838 $as_echo_n "checking for $ac_word... " >&6; }
38839 if ${ac_cv_path_BUILD_CC+:} false; then :
38840   $as_echo_n "(cached) " >&6
38841 else
38842   case $BUILD_CC in
38843   [\\/]* | ?:[\\/]*)
38844   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38845   ;;
38846   *)
38847   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38848 for as_dir in $PATH
38849 do
38850   IFS=$as_save_IFS
38851   test -z "$as_dir" && as_dir=.
38852     for ac_exec_ext in '' $ac_executable_extensions; do
38853   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38854     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38855     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38856     break 2
38857   fi
38858 done
38859   done
38860 IFS=$as_save_IFS
38861 
38862   ;;
38863 esac
38864 fi
38865 BUILD_CC=$ac_cv_path_BUILD_CC
38866 if test -n "$BUILD_CC"; then
38867   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38868 $as_echo "$BUILD_CC" >&6; }
38869 else
38870   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38871 $as_echo "no" >&6; }
38872 fi
38873 
38874 
38875         if test "x$BUILD_CC" = x; then
38876           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38877         fi
38878       else
38879         # Otherwise we believe it is a complete path. Use it as it is.
38880         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
38881 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
38882         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
38883 $as_echo_n "checking for BUILD_CC... " >&6; }
38884         if test ! -x "$tool_specified"; then
38885           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38886 $as_echo "not found" >&6; }
38887           as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
38888         fi
38889         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38890 $as_echo "$tool_specified" >&6; }
38891       fi
38892     fi
38893   fi
38894 
38895 
38896 
38897   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38898 
38899   # First separate the path from the arguments. This will split at the first
38900   # space.
38901   complete="$BUILD_CC"
38902   path="${complete%% *}"
38903   tmp="$complete EOL"
38904   arguments="${tmp#* }"
38905 
38906   # Input might be given as Windows format, start by converting to
38907   # unix format.
38908   new_path=`$CYGPATH -u "$path"`
38909 
38910   # Now try to locate executable using which
38911   new_path=`$WHICH "$new_path" 2> /dev/null`
38912   # bat and cmd files are not always considered executable in cygwin causing which
38913   # to not find them
38914   if test "x$new_path" = x \
38915       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38916       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38917     new_path=`$CYGPATH -u "$path"`
38918   fi
38919   if test "x$new_path" = x; then
38920     # Oops. Which didn't find the executable.
38921     # The splitting of arguments from the executable at a space might have been incorrect,
38922     # since paths with space are more likely in Windows. Give it another try with the whole
38923     # argument.
38924     path="$complete"
38925     arguments="EOL"
38926     new_path=`$CYGPATH -u "$path"`
38927     new_path=`$WHICH "$new_path" 2> /dev/null`
38928     # bat and cmd files are not always considered executable in cygwin causing which
38929     # to not find them
38930     if test "x$new_path" = x \
38931         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38932         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38933       new_path=`$CYGPATH -u "$path"`
38934     fi
38935     if test "x$new_path" = x; then
38936       # It's still not found. Now this is an unrecoverable error.
38937       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
38938 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
38939       has_space=`$ECHO "$complete" | $GREP " "`
38940       if test "x$has_space" != x; then
38941         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38942 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38943       fi
38944       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38945     fi
38946   fi
38947 
38948   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38949   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38950   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38951   # "foo.exe" is OK but "foo" is an error.
38952   #
38953   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38954   # It is also a way to make sure we got the proper file name for the real test later on.
38955   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38956   if test "x$test_shortpath" = x; then
38957     # Short path failed, file does not exist as specified.
38958     # Try adding .exe or .cmd
38959     if test -f "${new_path}.exe"; then
38960       input_to_shortpath="${new_path}.exe"
38961     elif test -f "${new_path}.cmd"; then
38962       input_to_shortpath="${new_path}.cmd"
38963     else
38964       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
38965 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
38966       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38967 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38968       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38969     fi
38970   else
38971     input_to_shortpath="$new_path"
38972   fi
38973 
38974   # Call helper function which possibly converts this using DOS-style short mode.
38975   # If so, the updated path is stored in $new_path.
38976   new_path="$input_to_shortpath"
38977 
38978   input_path="$input_to_shortpath"
38979   # Check if we need to convert this using DOS-style short mode. If the path
38980   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38981   # take no chances and rewrite it.
38982   # Note: m4 eats our [], so we need to use [ and ] instead.
38983   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38984   if test "x$has_forbidden_chars" != x; then
38985     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38986     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38987     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38988     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38989       # Going to short mode and back again did indeed matter. Since short mode is
38990       # case insensitive, let's make it lowercase to improve readability.
38991       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38992       # Now convert it back to Unix-stile (cygpath)
38993       input_path=`$CYGPATH -u "$shortmode_path"`
38994       new_path="$input_path"
38995     fi
38996   fi
38997 
38998   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38999   if test "x$test_cygdrive_prefix" = x; then
39000     # As a simple fix, exclude /usr/bin since it's not a real path.
39001     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39002       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39003       # a path prefixed by /cygdrive for fixpath to work.
39004       new_path="$CYGWIN_ROOT_PATH$input_path"
39005     fi
39006   fi
39007 
39008   # remove trailing .exe if any
39009   new_path="${new_path/%.exe/}"
39010 
39011   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39012 
39013   # First separate the path from the arguments. This will split at the first
39014   # space.
39015   complete="$BUILD_CC"
39016   path="${complete%% *}"
39017   tmp="$complete EOL"
39018   arguments="${tmp#* }"
39019 
39020   # Input might be given as Windows format, start by converting to
39021   # unix format.
39022   new_path="$path"
39023 
39024   windows_path="$new_path"
39025   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39026     unix_path=`$CYGPATH -u "$windows_path"`
39027     new_path="$unix_path"
39028   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39029     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39030     new_path="$unix_path"
39031   fi
39032 
39033 
39034   # Now try to locate executable using which
39035   new_path=`$WHICH "$new_path" 2> /dev/null`
39036 
39037   if test "x$new_path" = x; then
39038     # Oops. Which didn't find the executable.
39039     # The splitting of arguments from the executable at a space might have been incorrect,
39040     # since paths with space are more likely in Windows. Give it another try with the whole
39041     # argument.
39042     path="$complete"
39043     arguments="EOL"
39044     new_path="$path"
39045 
39046   windows_path="$new_path"
39047   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39048     unix_path=`$CYGPATH -u "$windows_path"`
39049     new_path="$unix_path"
39050   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39051     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39052     new_path="$unix_path"
39053   fi
39054 
39055 
39056     new_path=`$WHICH "$new_path" 2> /dev/null`
39057 
39058     if test "x$new_path" = x; then
39059       # It's still not found. Now this is an unrecoverable error.
39060       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39061 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39062       has_space=`$ECHO "$complete" | $GREP " "`
39063       if test "x$has_space" != x; then
39064         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39065 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39066       fi
39067       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39068     fi
39069   fi
39070 
39071   # Now new_path has a complete unix path to the binary
39072   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39073     # Keep paths in /bin as-is, but remove trailing .exe if any
39074     new_path="${new_path/%.exe/}"
39075     # Do not save /bin paths to all_fixpath_prefixes!
39076   else
39077     # Not in mixed or Windows style, start by that.
39078     new_path=`cmd //c echo $new_path`
39079 
39080   input_path="$new_path"
39081   # Check if we need to convert this using DOS-style short mode. If the path
39082   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39083   # take no chances and rewrite it.
39084   # Note: m4 eats our [], so we need to use [ and ] instead.
39085   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39086   if test "x$has_forbidden_chars" != x; then
39087     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39088     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39089   fi
39090 
39091     # Output is in $new_path
39092 
39093   windows_path="$new_path"
39094   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39095     unix_path=`$CYGPATH -u "$windows_path"`
39096     new_path="$unix_path"
39097   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39098     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39099     new_path="$unix_path"
39100   fi
39101 
39102     # remove trailing .exe if any
39103     new_path="${new_path/%.exe/}"
39104 
39105     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39106     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39107   fi
39108 
39109   else
39110     # We're on a posix platform. Hooray! :)
39111     # First separate the path from the arguments. This will split at the first
39112     # space.
39113     complete="$BUILD_CC"
39114     path="${complete%% *}"
39115     tmp="$complete EOL"
39116     arguments="${tmp#* }"
39117 
39118     # Cannot rely on the command "which" here since it doesn't always work.
39119     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39120     if test -z "$is_absolute_path"; then
39121       # Path to executable is not absolute. Find it.
39122       IFS_save="$IFS"
39123       IFS=:
39124       for p in $PATH; do
39125         if test -f "$p/$path" && test -x "$p/$path"; then
39126           new_path="$p/$path"
39127           break
39128         fi
39129       done
39130       IFS="$IFS_save"
39131     else
39132       # This is an absolute path, we can use it without further modifications.
39133       new_path="$path"
39134     fi
39135 
39136     if test "x$new_path" = x; then
39137       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39138 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39139       has_space=`$ECHO "$complete" | $GREP " "`
39140       if test "x$has_space" != x; then
39141         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39142 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39143       fi
39144       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39145     fi
39146   fi
39147 
39148   # Now join together the path and the arguments once again
39149   if test "x$arguments" != xEOL; then
39150     new_complete="$new_path ${arguments% *}"
39151   else
39152     new_complete="$new_path"
39153   fi
39154 
39155   if test "x$complete" != "x$new_complete"; then
39156     BUILD_CC="$new_complete"
39157     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
39158 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
39159   fi
39160 
39161 
39162 
39163   # Publish this variable in the help.
39164 
39165 
39166   if test "x$BUILD_CXX" = x; then
39167     # The variable is not set by user, try to locate tool using the code snippet
39168     for ac_prog in cl CC g++
39169 do
39170   # Extract the first word of "$ac_prog", so it can be a program name with args.
39171 set dummy $ac_prog; ac_word=$2
39172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39173 $as_echo_n "checking for $ac_word... " >&6; }
39174 if ${ac_cv_path_BUILD_CXX+:} false; then :
39175   $as_echo_n "(cached) " >&6
39176 else
39177   case $BUILD_CXX in
39178   [\\/]* | ?:[\\/]*)
39179   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39180   ;;
39181   *)
39182   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39183 for as_dir in $PATH
39184 do
39185   IFS=$as_save_IFS
39186   test -z "$as_dir" && as_dir=.
39187     for ac_exec_ext in '' $ac_executable_extensions; do
39188   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39189     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39190     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39191     break 2
39192   fi
39193 done
39194   done
39195 IFS=$as_save_IFS
39196 
39197   ;;
39198 esac
39199 fi
39200 BUILD_CXX=$ac_cv_path_BUILD_CXX
39201 if test -n "$BUILD_CXX"; then
39202   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39203 $as_echo "$BUILD_CXX" >&6; }
39204 else
39205   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39206 $as_echo "no" >&6; }
39207 fi
39208 
39209 
39210   test -n "$BUILD_CXX" && break
39211 done
39212 
39213   else
39214     # The variable is set, but is it from the command line or the environment?
39215 
39216     # Try to remove the string !BUILD_CXX! from our list.
39217     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
39218     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39219       # If it failed, the variable was not from the command line. Ignore it,
39220       # but warn the user (except for BASH, which is always set by the calling BASH).
39221       if test "xBUILD_CXX" != xBASH; then
39222         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
39223 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
39224       fi
39225       # Try to locate tool using the code snippet
39226       for ac_prog in cl CC g++
39227 do
39228   # Extract the first word of "$ac_prog", so it can be a program name with args.
39229 set dummy $ac_prog; ac_word=$2
39230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39231 $as_echo_n "checking for $ac_word... " >&6; }
39232 if ${ac_cv_path_BUILD_CXX+:} false; then :
39233   $as_echo_n "(cached) " >&6
39234 else
39235   case $BUILD_CXX in
39236   [\\/]* | ?:[\\/]*)
39237   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39238   ;;
39239   *)
39240   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39241 for as_dir in $PATH
39242 do
39243   IFS=$as_save_IFS
39244   test -z "$as_dir" && as_dir=.
39245     for ac_exec_ext in '' $ac_executable_extensions; do
39246   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39247     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39248     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39249     break 2
39250   fi
39251 done
39252   done
39253 IFS=$as_save_IFS
39254 
39255   ;;
39256 esac
39257 fi
39258 BUILD_CXX=$ac_cv_path_BUILD_CXX
39259 if test -n "$BUILD_CXX"; then
39260   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39261 $as_echo "$BUILD_CXX" >&6; }
39262 else
39263   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39264 $as_echo "no" >&6; }
39265 fi
39266 
39267 
39268   test -n "$BUILD_CXX" && break
39269 done
39270 
39271     else
39272       # If it succeeded, then it was overridden by the user. We will use it
39273       # for the tool.
39274 
39275       # First remove it from the list of overridden variables, so we can test
39276       # for unknown variables in the end.
39277       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39278 
39279       # Check if the provided tool contains a complete path.
39280       tool_specified="$BUILD_CXX"
39281       tool_basename="${tool_specified##*/}"
39282       if test "x$tool_basename" = "x$tool_specified"; then
39283         # A command without a complete path is provided, search $PATH.
39284         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
39285 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
39286         # Extract the first word of "$tool_basename", so it can be a program name with args.
39287 set dummy $tool_basename; ac_word=$2
39288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39289 $as_echo_n "checking for $ac_word... " >&6; }
39290 if ${ac_cv_path_BUILD_CXX+:} false; then :
39291   $as_echo_n "(cached) " >&6
39292 else
39293   case $BUILD_CXX in
39294   [\\/]* | ?:[\\/]*)
39295   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39296   ;;
39297   *)
39298   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39299 for as_dir in $PATH
39300 do
39301   IFS=$as_save_IFS
39302   test -z "$as_dir" && as_dir=.
39303     for ac_exec_ext in '' $ac_executable_extensions; do
39304   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39305     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39306     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39307     break 2
39308   fi
39309 done
39310   done
39311 IFS=$as_save_IFS
39312 
39313   ;;
39314 esac
39315 fi
39316 BUILD_CXX=$ac_cv_path_BUILD_CXX
39317 if test -n "$BUILD_CXX"; then
39318   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39319 $as_echo "$BUILD_CXX" >&6; }
39320 else
39321   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39322 $as_echo "no" >&6; }
39323 fi
39324 
39325 
39326         if test "x$BUILD_CXX" = x; then
39327           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39328         fi
39329       else
39330         # Otherwise we believe it is a complete path. Use it as it is.
39331         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
39332 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
39333         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
39334 $as_echo_n "checking for BUILD_CXX... " >&6; }
39335         if test ! -x "$tool_specified"; then
39336           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39337 $as_echo "not found" >&6; }
39338           as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
39339         fi
39340         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39341 $as_echo "$tool_specified" >&6; }
39342       fi
39343     fi
39344   fi
39345 
39346 
39347 
39348   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39349 
39350   # First separate the path from the arguments. This will split at the first
39351   # space.
39352   complete="$BUILD_CXX"
39353   path="${complete%% *}"
39354   tmp="$complete EOL"
39355   arguments="${tmp#* }"
39356 
39357   # Input might be given as Windows format, start by converting to
39358   # unix format.
39359   new_path=`$CYGPATH -u "$path"`
39360 
39361   # Now try to locate executable using which
39362   new_path=`$WHICH "$new_path" 2> /dev/null`
39363   # bat and cmd files are not always considered executable in cygwin causing which
39364   # to not find them
39365   if test "x$new_path" = x \
39366       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39367       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39368     new_path=`$CYGPATH -u "$path"`
39369   fi
39370   if test "x$new_path" = x; then
39371     # Oops. Which didn't find the executable.
39372     # The splitting of arguments from the executable at a space might have been incorrect,
39373     # since paths with space are more likely in Windows. Give it another try with the whole
39374     # argument.
39375     path="$complete"
39376     arguments="EOL"
39377     new_path=`$CYGPATH -u "$path"`
39378     new_path=`$WHICH "$new_path" 2> /dev/null`
39379     # bat and cmd files are not always considered executable in cygwin causing which
39380     # to not find them
39381     if test "x$new_path" = x \
39382         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39383         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39384       new_path=`$CYGPATH -u "$path"`
39385     fi
39386     if test "x$new_path" = x; then
39387       # It's still not found. Now this is an unrecoverable error.
39388       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39389 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39390       has_space=`$ECHO "$complete" | $GREP " "`
39391       if test "x$has_space" != x; then
39392         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39393 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39394       fi
39395       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39396     fi
39397   fi
39398 
39399   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39400   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39401   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39402   # "foo.exe" is OK but "foo" is an error.
39403   #
39404   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39405   # It is also a way to make sure we got the proper file name for the real test later on.
39406   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39407   if test "x$test_shortpath" = x; then
39408     # Short path failed, file does not exist as specified.
39409     # Try adding .exe or .cmd
39410     if test -f "${new_path}.exe"; then
39411       input_to_shortpath="${new_path}.exe"
39412     elif test -f "${new_path}.cmd"; then
39413       input_to_shortpath="${new_path}.cmd"
39414     else
39415       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
39416 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
39417       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39418 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39419       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39420     fi
39421   else
39422     input_to_shortpath="$new_path"
39423   fi
39424 
39425   # Call helper function which possibly converts this using DOS-style short mode.
39426   # If so, the updated path is stored in $new_path.
39427   new_path="$input_to_shortpath"
39428 
39429   input_path="$input_to_shortpath"
39430   # Check if we need to convert this using DOS-style short mode. If the path
39431   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39432   # take no chances and rewrite it.
39433   # Note: m4 eats our [], so we need to use [ and ] instead.
39434   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39435   if test "x$has_forbidden_chars" != x; then
39436     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39437     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39438     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39439     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39440       # Going to short mode and back again did indeed matter. Since short mode is
39441       # case insensitive, let's make it lowercase to improve readability.
39442       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39443       # Now convert it back to Unix-stile (cygpath)
39444       input_path=`$CYGPATH -u "$shortmode_path"`
39445       new_path="$input_path"
39446     fi
39447   fi
39448 
39449   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39450   if test "x$test_cygdrive_prefix" = x; then
39451     # As a simple fix, exclude /usr/bin since it's not a real path.
39452     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39453       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39454       # a path prefixed by /cygdrive for fixpath to work.
39455       new_path="$CYGWIN_ROOT_PATH$input_path"
39456     fi
39457   fi
39458 
39459   # remove trailing .exe if any
39460   new_path="${new_path/%.exe/}"
39461 
39462   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39463 
39464   # First separate the path from the arguments. This will split at the first
39465   # space.
39466   complete="$BUILD_CXX"
39467   path="${complete%% *}"
39468   tmp="$complete EOL"
39469   arguments="${tmp#* }"
39470 
39471   # Input might be given as Windows format, start by converting to
39472   # unix format.
39473   new_path="$path"
39474 
39475   windows_path="$new_path"
39476   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39477     unix_path=`$CYGPATH -u "$windows_path"`
39478     new_path="$unix_path"
39479   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39480     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39481     new_path="$unix_path"
39482   fi
39483 
39484 
39485   # Now try to locate executable using which
39486   new_path=`$WHICH "$new_path" 2> /dev/null`
39487 
39488   if test "x$new_path" = x; then
39489     # Oops. Which didn't find the executable.
39490     # The splitting of arguments from the executable at a space might have been incorrect,
39491     # since paths with space are more likely in Windows. Give it another try with the whole
39492     # argument.
39493     path="$complete"
39494     arguments="EOL"
39495     new_path="$path"
39496 
39497   windows_path="$new_path"
39498   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39499     unix_path=`$CYGPATH -u "$windows_path"`
39500     new_path="$unix_path"
39501   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39502     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39503     new_path="$unix_path"
39504   fi
39505 
39506 
39507     new_path=`$WHICH "$new_path" 2> /dev/null`
39508 
39509     if test "x$new_path" = x; then
39510       # It's still not found. Now this is an unrecoverable error.
39511       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39512 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39513       has_space=`$ECHO "$complete" | $GREP " "`
39514       if test "x$has_space" != x; then
39515         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39516 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39517       fi
39518       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39519     fi
39520   fi
39521 
39522   # Now new_path has a complete unix path to the binary
39523   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39524     # Keep paths in /bin as-is, but remove trailing .exe if any
39525     new_path="${new_path/%.exe/}"
39526     # Do not save /bin paths to all_fixpath_prefixes!
39527   else
39528     # Not in mixed or Windows style, start by that.
39529     new_path=`cmd //c echo $new_path`
39530 
39531   input_path="$new_path"
39532   # Check if we need to convert this using DOS-style short mode. If the path
39533   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39534   # take no chances and rewrite it.
39535   # Note: m4 eats our [], so we need to use [ and ] instead.
39536   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39537   if test "x$has_forbidden_chars" != x; then
39538     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39539     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39540   fi
39541 
39542     # Output is in $new_path
39543 
39544   windows_path="$new_path"
39545   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39546     unix_path=`$CYGPATH -u "$windows_path"`
39547     new_path="$unix_path"
39548   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39549     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39550     new_path="$unix_path"
39551   fi
39552 
39553     # remove trailing .exe if any
39554     new_path="${new_path/%.exe/}"
39555 
39556     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39557     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39558   fi
39559 
39560   else
39561     # We're on a posix platform. Hooray! :)
39562     # First separate the path from the arguments. This will split at the first
39563     # space.
39564     complete="$BUILD_CXX"
39565     path="${complete%% *}"
39566     tmp="$complete EOL"
39567     arguments="${tmp#* }"
39568 
39569     # Cannot rely on the command "which" here since it doesn't always work.
39570     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39571     if test -z "$is_absolute_path"; then
39572       # Path to executable is not absolute. Find it.
39573       IFS_save="$IFS"
39574       IFS=:
39575       for p in $PATH; do
39576         if test -f "$p/$path" && test -x "$p/$path"; then
39577           new_path="$p/$path"
39578           break
39579         fi
39580       done
39581       IFS="$IFS_save"
39582     else
39583       # This is an absolute path, we can use it without further modifications.
39584       new_path="$path"
39585     fi
39586 
39587     if test "x$new_path" = x; then
39588       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39589 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39590       has_space=`$ECHO "$complete" | $GREP " "`
39591       if test "x$has_space" != x; then
39592         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39593 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39594       fi
39595       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39596     fi
39597   fi
39598 
39599   # Now join together the path and the arguments once again
39600   if test "x$arguments" != xEOL; then
39601     new_complete="$new_path ${arguments% *}"
39602   else
39603     new_complete="$new_path"
39604   fi
39605 
39606   if test "x$complete" != "x$new_complete"; then
39607     BUILD_CXX="$new_complete"
39608     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
39609 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
39610   fi
39611 
39612 
39613 
39614   # Publish this variable in the help.
39615 
39616 
39617   if test "x$BUILD_LD" = x; then
39618     # The variable is not set by user, try to locate tool using the code snippet
39619     for ac_prog in ld
39620 do
39621   # Extract the first word of "$ac_prog", so it can be a program name with args.
39622 set dummy $ac_prog; ac_word=$2
39623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39624 $as_echo_n "checking for $ac_word... " >&6; }
39625 if ${ac_cv_path_BUILD_LD+:} false; then :
39626   $as_echo_n "(cached) " >&6
39627 else
39628   case $BUILD_LD in
39629   [\\/]* | ?:[\\/]*)
39630   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39631   ;;
39632   *)
39633   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39634 for as_dir in $PATH
39635 do
39636   IFS=$as_save_IFS
39637   test -z "$as_dir" && as_dir=.
39638     for ac_exec_ext in '' $ac_executable_extensions; do
39639   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39640     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39641     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39642     break 2
39643   fi
39644 done
39645   done
39646 IFS=$as_save_IFS
39647 
39648   ;;
39649 esac
39650 fi
39651 BUILD_LD=$ac_cv_path_BUILD_LD
39652 if test -n "$BUILD_LD"; then
39653   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39654 $as_echo "$BUILD_LD" >&6; }
39655 else
39656   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39657 $as_echo "no" >&6; }
39658 fi
39659 
39660 
39661   test -n "$BUILD_LD" && break
39662 done
39663 
39664   else
39665     # The variable is set, but is it from the command line or the environment?
39666 
39667     # Try to remove the string !BUILD_LD! from our list.
39668     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
39669     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39670       # If it failed, the variable was not from the command line. Ignore it,
39671       # but warn the user (except for BASH, which is always set by the calling BASH).
39672       if test "xBUILD_LD" != xBASH; then
39673         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
39674 $as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
39675       fi
39676       # Try to locate tool using the code snippet
39677       for ac_prog in ld
39678 do
39679   # Extract the first word of "$ac_prog", so it can be a program name with args.
39680 set dummy $ac_prog; ac_word=$2
39681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39682 $as_echo_n "checking for $ac_word... " >&6; }
39683 if ${ac_cv_path_BUILD_LD+:} false; then :
39684   $as_echo_n "(cached) " >&6
39685 else
39686   case $BUILD_LD in
39687   [\\/]* | ?:[\\/]*)
39688   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39689   ;;
39690   *)
39691   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39692 for as_dir in $PATH
39693 do
39694   IFS=$as_save_IFS
39695   test -z "$as_dir" && as_dir=.
39696     for ac_exec_ext in '' $ac_executable_extensions; do
39697   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39698     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39699     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39700     break 2
39701   fi
39702 done
39703   done
39704 IFS=$as_save_IFS
39705 
39706   ;;
39707 esac
39708 fi
39709 BUILD_LD=$ac_cv_path_BUILD_LD
39710 if test -n "$BUILD_LD"; then
39711   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39712 $as_echo "$BUILD_LD" >&6; }
39713 else
39714   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39715 $as_echo "no" >&6; }
39716 fi
39717 
39718 
39719   test -n "$BUILD_LD" && break
39720 done
39721 
39722     else
39723       # If it succeeded, then it was overridden by the user. We will use it
39724       # for the tool.
39725 
39726       # First remove it from the list of overridden variables, so we can test
39727       # for unknown variables in the end.
39728       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39729 
39730       # Check if the provided tool contains a complete path.
39731       tool_specified="$BUILD_LD"
39732       tool_basename="${tool_specified##*/}"
39733       if test "x$tool_basename" = "x$tool_specified"; then
39734         # A command without a complete path is provided, search $PATH.
39735         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
39736 $as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
39737         # Extract the first word of "$tool_basename", so it can be a program name with args.
39738 set dummy $tool_basename; ac_word=$2
39739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39740 $as_echo_n "checking for $ac_word... " >&6; }
39741 if ${ac_cv_path_BUILD_LD+:} false; then :
39742   $as_echo_n "(cached) " >&6
39743 else
39744   case $BUILD_LD in
39745   [\\/]* | ?:[\\/]*)
39746   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39747   ;;
39748   *)
39749   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39750 for as_dir in $PATH
39751 do
39752   IFS=$as_save_IFS
39753   test -z "$as_dir" && as_dir=.
39754     for ac_exec_ext in '' $ac_executable_extensions; do
39755   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39756     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39757     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39758     break 2
39759   fi
39760 done
39761   done
39762 IFS=$as_save_IFS
39763 
39764   ;;
39765 esac
39766 fi
39767 BUILD_LD=$ac_cv_path_BUILD_LD
39768 if test -n "$BUILD_LD"; then
39769   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39770 $as_echo "$BUILD_LD" >&6; }
39771 else
39772   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39773 $as_echo "no" >&6; }
39774 fi
39775 
39776 
39777         if test "x$BUILD_LD" = x; then
39778           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39779         fi
39780       else
39781         # Otherwise we believe it is a complete path. Use it as it is.
39782         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
39783 $as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
39784         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
39785 $as_echo_n "checking for BUILD_LD... " >&6; }
39786         if test ! -x "$tool_specified"; then
39787           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39788 $as_echo "not found" >&6; }
39789           as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
39790         fi
39791         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39792 $as_echo "$tool_specified" >&6; }
39793       fi
39794     fi
39795   fi
39796 
39797 
39798 
39799   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39800 
39801   # First separate the path from the arguments. This will split at the first
39802   # space.
39803   complete="$BUILD_LD"
39804   path="${complete%% *}"
39805   tmp="$complete EOL"
39806   arguments="${tmp#* }"
39807 
39808   # Input might be given as Windows format, start by converting to
39809   # unix format.
39810   new_path=`$CYGPATH -u "$path"`
39811 
39812   # Now try to locate executable using which
39813   new_path=`$WHICH "$new_path" 2> /dev/null`
39814   # bat and cmd files are not always considered executable in cygwin causing which
39815   # to not find them
39816   if test "x$new_path" = x \
39817       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39818       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39819     new_path=`$CYGPATH -u "$path"`
39820   fi
39821   if test "x$new_path" = x; then
39822     # Oops. Which didn't find the executable.
39823     # The splitting of arguments from the executable at a space might have been incorrect,
39824     # since paths with space are more likely in Windows. Give it another try with the whole
39825     # argument.
39826     path="$complete"
39827     arguments="EOL"
39828     new_path=`$CYGPATH -u "$path"`
39829     new_path=`$WHICH "$new_path" 2> /dev/null`
39830     # bat and cmd files are not always considered executable in cygwin causing which
39831     # to not find them
39832     if test "x$new_path" = x \
39833         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39834         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39835       new_path=`$CYGPATH -u "$path"`
39836     fi
39837     if test "x$new_path" = x; then
39838       # It's still not found. Now this is an unrecoverable error.
39839       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39840 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39841       has_space=`$ECHO "$complete" | $GREP " "`
39842       if test "x$has_space" != x; then
39843         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39844 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39845       fi
39846       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39847     fi
39848   fi
39849 
39850   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39851   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39852   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39853   # "foo.exe" is OK but "foo" is an error.
39854   #
39855   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39856   # It is also a way to make sure we got the proper file name for the real test later on.
39857   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39858   if test "x$test_shortpath" = x; then
39859     # Short path failed, file does not exist as specified.
39860     # Try adding .exe or .cmd
39861     if test -f "${new_path}.exe"; then
39862       input_to_shortpath="${new_path}.exe"
39863     elif test -f "${new_path}.cmd"; then
39864       input_to_shortpath="${new_path}.cmd"
39865     else
39866       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
39867 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
39868       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39869 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39870       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39871     fi
39872   else
39873     input_to_shortpath="$new_path"
39874   fi
39875 
39876   # Call helper function which possibly converts this using DOS-style short mode.
39877   # If so, the updated path is stored in $new_path.
39878   new_path="$input_to_shortpath"
39879 
39880   input_path="$input_to_shortpath"
39881   # Check if we need to convert this using DOS-style short mode. If the path
39882   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39883   # take no chances and rewrite it.
39884   # Note: m4 eats our [], so we need to use [ and ] instead.
39885   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39886   if test "x$has_forbidden_chars" != x; then
39887     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39888     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39889     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39890     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39891       # Going to short mode and back again did indeed matter. Since short mode is
39892       # case insensitive, let's make it lowercase to improve readability.
39893       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39894       # Now convert it back to Unix-stile (cygpath)
39895       input_path=`$CYGPATH -u "$shortmode_path"`
39896       new_path="$input_path"
39897     fi
39898   fi
39899 
39900   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39901   if test "x$test_cygdrive_prefix" = x; then
39902     # As a simple fix, exclude /usr/bin since it's not a real path.
39903     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39904       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39905       # a path prefixed by /cygdrive for fixpath to work.
39906       new_path="$CYGWIN_ROOT_PATH$input_path"
39907     fi
39908   fi
39909 
39910   # remove trailing .exe if any
39911   new_path="${new_path/%.exe/}"
39912 
39913   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39914 
39915   # First separate the path from the arguments. This will split at the first
39916   # space.
39917   complete="$BUILD_LD"
39918   path="${complete%% *}"
39919   tmp="$complete EOL"
39920   arguments="${tmp#* }"
39921 
39922   # Input might be given as Windows format, start by converting to
39923   # unix format.
39924   new_path="$path"
39925 
39926   windows_path="$new_path"
39927   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39928     unix_path=`$CYGPATH -u "$windows_path"`
39929     new_path="$unix_path"
39930   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39931     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39932     new_path="$unix_path"
39933   fi
39934 
39935 
39936   # Now try to locate executable using which
39937   new_path=`$WHICH "$new_path" 2> /dev/null`
39938 
39939   if test "x$new_path" = x; then
39940     # Oops. Which didn't find the executable.
39941     # The splitting of arguments from the executable at a space might have been incorrect,
39942     # since paths with space are more likely in Windows. Give it another try with the whole
39943     # argument.
39944     path="$complete"
39945     arguments="EOL"
39946     new_path="$path"
39947 
39948   windows_path="$new_path"
39949   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39950     unix_path=`$CYGPATH -u "$windows_path"`
39951     new_path="$unix_path"
39952   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39953     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39954     new_path="$unix_path"
39955   fi
39956 
39957 
39958     new_path=`$WHICH "$new_path" 2> /dev/null`
39959 
39960     if test "x$new_path" = x; then
39961       # It's still not found. Now this is an unrecoverable error.
39962       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39963 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39964       has_space=`$ECHO "$complete" | $GREP " "`
39965       if test "x$has_space" != x; then
39966         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39967 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39968       fi
39969       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39970     fi
39971   fi
39972 
39973   # Now new_path has a complete unix path to the binary
39974   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39975     # Keep paths in /bin as-is, but remove trailing .exe if any
39976     new_path="${new_path/%.exe/}"
39977     # Do not save /bin paths to all_fixpath_prefixes!
39978   else
39979     # Not in mixed or Windows style, start by that.
39980     new_path=`cmd //c echo $new_path`
39981 
39982   input_path="$new_path"
39983   # Check if we need to convert this using DOS-style short mode. If the path
39984   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39985   # take no chances and rewrite it.
39986   # Note: m4 eats our [], so we need to use [ and ] instead.
39987   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39988   if test "x$has_forbidden_chars" != x; then
39989     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39990     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39991   fi
39992 
39993     # Output is in $new_path
39994 
39995   windows_path="$new_path"
39996   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39997     unix_path=`$CYGPATH -u "$windows_path"`
39998     new_path="$unix_path"
39999   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40000     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40001     new_path="$unix_path"
40002   fi
40003 
40004     # remove trailing .exe if any
40005     new_path="${new_path/%.exe/}"
40006 
40007     # Save the first 10 bytes of this path to the storage, so fixpath can work.
40008     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40009   fi
40010 
40011   else
40012     # We're on a posix platform. Hooray! :)
40013     # First separate the path from the arguments. This will split at the first
40014     # space.
40015     complete="$BUILD_LD"
40016     path="${complete%% *}"
40017     tmp="$complete EOL"
40018     arguments="${tmp#* }"
40019 
40020     # Cannot rely on the command "which" here since it doesn't always work.
40021     is_absolute_path=`$ECHO "$path" | $GREP ^/`
40022     if test -z "$is_absolute_path"; then
40023       # Path to executable is not absolute. Find it.
40024       IFS_save="$IFS"
40025       IFS=:
40026       for p in $PATH; do
40027         if test -f "$p/$path" && test -x "$p/$path"; then
40028           new_path="$p/$path"
40029           break
40030         fi
40031       done
40032       IFS="$IFS_save"
40033     else
40034       # This is an absolute path, we can use it without further modifications.
40035       new_path="$path"
40036     fi
40037 
40038     if test "x$new_path" = x; then
40039       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40040 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40041       has_space=`$ECHO "$complete" | $GREP " "`
40042       if test "x$has_space" != x; then
40043         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40044 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40045       fi
40046       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40047     fi
40048   fi
40049 
40050   # Now join together the path and the arguments once again
40051   if test "x$arguments" != xEOL; then
40052     new_complete="$new_path ${arguments% *}"
40053   else
40054     new_complete="$new_path"
40055   fi
40056 
40057   if test "x$complete" != "x$new_complete"; then
40058     BUILD_LD="$new_complete"
40059     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
40060 $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
40061   fi
40062 
40063   else
40064     # If we are not cross compiling, use the normal target compilers for
40065     # building the build platform executables.
40066     BUILD_CC="$CC"
40067     BUILD_CXX="$CXX"
40068     BUILD_LD="$LD"
40069   fi
40070 
40071 
40072 
40073 
40074 
40075 
40076   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40077     # For hotspot, we need these in Windows mixed path,
40078     # so rewrite them all. Need added .exe suffix.
40079     HOTSPOT_CXX="$CXX.exe"
40080     HOTSPOT_LD="$LD.exe"
40081     HOTSPOT_MT="$MT.exe"
40082     HOTSPOT_RC="$RC.exe"
40083 
40084   unix_path="$HOTSPOT_CXX"
40085   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40086     windows_path=`$CYGPATH -m "$unix_path"`
40087     HOTSPOT_CXX="$windows_path"
40088   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40089     windows_path=`cmd //c echo $unix_path`
40090     HOTSPOT_CXX="$windows_path"
40091   fi
40092 
40093 
40094   unix_path="$HOTSPOT_LD"
40095   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40096     windows_path=`$CYGPATH -m "$unix_path"`
40097     HOTSPOT_LD="$windows_path"
40098   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40099     windows_path=`cmd //c echo $unix_path`
40100     HOTSPOT_LD="$windows_path"
40101   fi
40102 
40103 
40104   unix_path="$HOTSPOT_MT"
40105   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40106     windows_path=`$CYGPATH -m "$unix_path"`
40107     HOTSPOT_MT="$windows_path"
40108   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40109     windows_path=`cmd //c echo $unix_path`
40110     HOTSPOT_MT="$windows_path"
40111   fi
40112 
40113 
40114   unix_path="$HOTSPOT_RC"
40115   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40116     windows_path=`$CYGPATH -m "$unix_path"`
40117     HOTSPOT_RC="$windows_path"
40118   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40119     windows_path=`cmd //c echo $unix_path`
40120     HOTSPOT_RC="$windows_path"
40121   fi
40122 
40123 
40124 
40125   else
40126     HOTSPOT_CXX="$CXX"
40127     HOTSPOT_LD="$LD"
40128   fi
40129 
40130 
40131 
40132   if test  "x$TOOLCHAIN_TYPE" = xclang; then
40133     USE_CLANG=true
40134   fi
40135 
40136 
40137   # LDEXE is the linker to use, when creating executables. Not really used.
40138   # FIXME: These should just be removed!
40139   LDEXE="$LD"
40140   LDEXECXX="$LDCXX"
40141 
40142 
40143 
40144 
40145   # The package path is used only on macosx?
40146   # FIXME: clean this up, and/or move it elsewhere.
40147   PACKAGE_PATH=/opt/local
40148 
40149 
40150   # Check for extra potential brokenness.
40151   if test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40152     # On Windows, double-check that we got the right compiler.
40153     CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'`
40154     COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"`
40155     if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
40156       if test "x$COMPILER_CPU_TEST" != "x80x86"; then
40157         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
40158       fi
40159     elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
40160       if test "x$COMPILER_CPU_TEST" != "xx64"; then
40161         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
40162       fi
40163     fi
40164   fi
40165 
40166   if test "x$TOOLCHAIN_TYPE" = xgcc; then
40167     # If this is a --hash-style=gnu system, use --hash-style=both, why?
40168     HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
40169     # This is later checked when setting flags.
40170   fi
40171 
40172   # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed
40173   # in executable.'
40174   USING_BROKEN_SUSE_LD=no
40175   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then
40176     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
40177 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
40178     echo "SUNWprivate_1.1 { local: *; };" > version-script.map
40179     echo "int main() { }" > main.c
40180     if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
40181       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40182 $as_echo "no" >&6; }
40183       USING_BROKEN_SUSE_LD=no
40184     else
40185       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40186 $as_echo "yes" >&6; }
40187       USING_BROKEN_SUSE_LD=yes
40188     fi
40189     rm -rf version-script.map main.c a.out
40190   fi
40191 
40192 
40193 
40194 # Setup the JTReg Regression Test Harness.
40195 
40196 
40197 # Check whether --with-jtreg was given.
40198 if test "${with_jtreg+set}" = set; then :
40199   withval=$with_jtreg;
40200 else
40201   with_jtreg=no
40202 fi
40203 
40204 
40205   if test "x$with_jtreg" = xno; then
40206     # jtreg disabled
40207     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40208 $as_echo_n "checking for jtreg... " >&6; }
40209     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40210 $as_echo "no" >&6; }
40211   else
40212     if test "x$with_jtreg" != xyes; then
40213       # with path specified.
40214       JT_HOME="$with_jtreg"
40215     fi
40216 
40217     if test "x$JT_HOME" != x; then
40218       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40219 $as_echo_n "checking for jtreg... " >&6; }
40220 
40221       # use JT_HOME enviroment var.
40222 
40223   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40224 
40225   # Input might be given as Windows format, start by converting to
40226   # unix format.
40227   path="$JT_HOME"
40228   new_path=`$CYGPATH -u "$path"`
40229 
40230   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40231   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40232   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40233   # "foo.exe" is OK but "foo" is an error.
40234   #
40235   # This test is therefore slightly more accurate than "test -f" to check for file precense.
40236   # It is also a way to make sure we got the proper file name for the real test later on.
40237   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40238   if test "x$test_shortpath" = x; then
40239     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40240 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40241     as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
40242   fi
40243 
40244   # Call helper function which possibly converts this using DOS-style short mode.
40245   # If so, the updated path is stored in $new_path.
40246 
40247   input_path="$new_path"
40248   # Check if we need to convert this using DOS-style short mode. If the path
40249   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40250   # take no chances and rewrite it.
40251   # Note: m4 eats our [], so we need to use [ and ] instead.
40252   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40253   if test "x$has_forbidden_chars" != x; then
40254     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40255     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40256     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40257     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40258       # Going to short mode and back again did indeed matter. Since short mode is
40259       # case insensitive, let's make it lowercase to improve readability.
40260       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40261       # Now convert it back to Unix-stile (cygpath)
40262       input_path=`$CYGPATH -u "$shortmode_path"`
40263       new_path="$input_path"
40264     fi
40265   fi
40266 
40267   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40268   if test "x$test_cygdrive_prefix" = x; then
40269     # As a simple fix, exclude /usr/bin since it's not a real path.
40270     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
40271       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40272       # a path prefixed by /cygdrive for fixpath to work.
40273       new_path="$CYGWIN_ROOT_PATH$input_path"
40274     fi
40275   fi
40276 
40277 
40278   if test "x$path" != "x$new_path"; then
40279     JT_HOME="$new_path"
40280     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40281 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40282   fi
40283 
40284   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40285 
40286   path="$JT_HOME"
40287   has_colon=`$ECHO $path | $GREP ^.:`
40288   new_path="$path"
40289   if test "x$has_colon" = x; then
40290     # Not in mixed or Windows style, start by that.
40291     new_path=`cmd //c echo $path`
40292   fi
40293 
40294 
40295   input_path="$new_path"
40296   # Check if we need to convert this using DOS-style short mode. If the path
40297   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40298   # take no chances and rewrite it.
40299   # Note: m4 eats our [], so we need to use [ and ] instead.
40300   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40301   if test "x$has_forbidden_chars" != x; then
40302     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40303     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40304   fi
40305 
40306 
40307   windows_path="$new_path"
40308   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40309     unix_path=`$CYGPATH -u "$windows_path"`
40310     new_path="$unix_path"
40311   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40312     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40313     new_path="$unix_path"
40314   fi
40315 
40316   if test "x$path" != "x$new_path"; then
40317     JT_HOME="$new_path"
40318     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40319 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40320   fi
40321 
40322   # Save the first 10 bytes of this path to the storage, so fixpath can work.
40323   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40324 
40325   else
40326     # We're on a posix platform. Hooray! :)
40327     path="$JT_HOME"
40328     has_space=`$ECHO "$path" | $GREP " "`
40329     if test "x$has_space" != x; then
40330       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40331 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40332       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
40333     fi
40334 
40335     # Use eval to expand a potential ~
40336     eval path="$path"
40337     if test ! -f "$path" && test ! -d "$path"; then
40338       as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
40339     fi
40340 
40341     JT_HOME="`cd "$path"; $THEPWDCMD -L`"
40342   fi
40343 
40344 
40345       # jtreg win32 script works for everybody
40346       JTREGEXE="$JT_HOME/win32/bin/jtreg"
40347 
40348       if test ! -f "$JTREGEXE"; then
40349         as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
40350       fi
40351 
40352       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40353 $as_echo "$JTREGEXE" >&6; }
40354     else
40355       # try to find jtreg on path
40356 
40357 
40358 
40359   # Publish this variable in the help.
40360 
40361 
40362   if test "x$JTREGEXE" = x; then
40363     # The variable is not set by user, try to locate tool using the code snippet
40364     for ac_prog in jtreg
40365 do
40366   # Extract the first word of "$ac_prog", so it can be a program name with args.
40367 set dummy $ac_prog; ac_word=$2
40368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40369 $as_echo_n "checking for $ac_word... " >&6; }
40370 if ${ac_cv_path_JTREGEXE+:} false; then :
40371   $as_echo_n "(cached) " >&6
40372 else
40373   case $JTREGEXE in
40374   [\\/]* | ?:[\\/]*)
40375   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40376   ;;
40377   *)
40378   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40379 for as_dir in $PATH
40380 do
40381   IFS=$as_save_IFS
40382   test -z "$as_dir" && as_dir=.
40383     for ac_exec_ext in '' $ac_executable_extensions; do
40384   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40385     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40386     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40387     break 2
40388   fi
40389 done
40390   done
40391 IFS=$as_save_IFS
40392 
40393   ;;
40394 esac
40395 fi
40396 JTREGEXE=$ac_cv_path_JTREGEXE
40397 if test -n "$JTREGEXE"; then
40398   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40399 $as_echo "$JTREGEXE" >&6; }
40400 else
40401   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40402 $as_echo "no" >&6; }
40403 fi
40404 
40405 
40406   test -n "$JTREGEXE" && break
40407 done
40408 
40409   else
40410     # The variable is set, but is it from the command line or the environment?
40411 
40412     # Try to remove the string !JTREGEXE! from our list.
40413     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
40414     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40415       # If it failed, the variable was not from the command line. Ignore it,
40416       # but warn the user (except for BASH, which is always set by the calling BASH).
40417       if test "xJTREGEXE" != xBASH; then
40418         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
40419 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
40420       fi
40421       # Try to locate tool using the code snippet
40422       for ac_prog in jtreg
40423 do
40424   # Extract the first word of "$ac_prog", so it can be a program name with args.
40425 set dummy $ac_prog; ac_word=$2
40426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40427 $as_echo_n "checking for $ac_word... " >&6; }
40428 if ${ac_cv_path_JTREGEXE+:} false; then :
40429   $as_echo_n "(cached) " >&6
40430 else
40431   case $JTREGEXE in
40432   [\\/]* | ?:[\\/]*)
40433   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40434   ;;
40435   *)
40436   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40437 for as_dir in $PATH
40438 do
40439   IFS=$as_save_IFS
40440   test -z "$as_dir" && as_dir=.
40441     for ac_exec_ext in '' $ac_executable_extensions; do
40442   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40443     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40444     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40445     break 2
40446   fi
40447 done
40448   done
40449 IFS=$as_save_IFS
40450 
40451   ;;
40452 esac
40453 fi
40454 JTREGEXE=$ac_cv_path_JTREGEXE
40455 if test -n "$JTREGEXE"; then
40456   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40457 $as_echo "$JTREGEXE" >&6; }
40458 else
40459   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40460 $as_echo "no" >&6; }
40461 fi
40462 
40463 
40464   test -n "$JTREGEXE" && break
40465 done
40466 
40467     else
40468       # If it succeeded, then it was overridden by the user. We will use it
40469       # for the tool.
40470 
40471       # First remove it from the list of overridden variables, so we can test
40472       # for unknown variables in the end.
40473       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40474 
40475       # Check if the provided tool contains a complete path.
40476       tool_specified="$JTREGEXE"
40477       tool_basename="${tool_specified##*/}"
40478       if test "x$tool_basename" = "x$tool_specified"; then
40479         # A command without a complete path is provided, search $PATH.
40480         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
40481 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
40482         # Extract the first word of "$tool_basename", so it can be a program name with args.
40483 set dummy $tool_basename; ac_word=$2
40484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40485 $as_echo_n "checking for $ac_word... " >&6; }
40486 if ${ac_cv_path_JTREGEXE+:} false; then :
40487   $as_echo_n "(cached) " >&6
40488 else
40489   case $JTREGEXE in
40490   [\\/]* | ?:[\\/]*)
40491   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40492   ;;
40493   *)
40494   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40495 for as_dir in $PATH
40496 do
40497   IFS=$as_save_IFS
40498   test -z "$as_dir" && as_dir=.
40499     for ac_exec_ext in '' $ac_executable_extensions; do
40500   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40501     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40502     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40503     break 2
40504   fi
40505 done
40506   done
40507 IFS=$as_save_IFS
40508 
40509   ;;
40510 esac
40511 fi
40512 JTREGEXE=$ac_cv_path_JTREGEXE
40513 if test -n "$JTREGEXE"; then
40514   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40515 $as_echo "$JTREGEXE" >&6; }
40516 else
40517   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40518 $as_echo "no" >&6; }
40519 fi
40520 
40521 
40522         if test "x$JTREGEXE" = x; then
40523           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40524         fi
40525       else
40526         # Otherwise we believe it is a complete path. Use it as it is.
40527         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
40528 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
40529         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
40530 $as_echo_n "checking for JTREGEXE... " >&6; }
40531         if test ! -x "$tool_specified"; then
40532           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40533 $as_echo "not found" >&6; }
40534           as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
40535         fi
40536         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40537 $as_echo "$tool_specified" >&6; }
40538       fi
40539     fi
40540   fi
40541 
40542 
40543 
40544   if test "x$JTREGEXE" = x; then
40545     as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
40546   fi
40547 
40548 
40549       JT_HOME="`$DIRNAME $JTREGEXE`"
40550     fi
40551   fi
40552 
40553 
40554 
40555 
40556 
40557 
40558   # Option used to tell the compiler whether to create 32- or 64-bit executables
40559   if test "x$TOOLCHAIN_TYPE" = xxlc; then
40560     COMPILER_TARGET_BITS_FLAG="-q"
40561   else
40562     COMPILER_TARGET_BITS_FLAG="-m"
40563   fi
40564 
40565 
40566   # FIXME: figure out if we should select AR flags depending on OS or toolchain.
40567   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
40568     ARFLAGS="-r"
40569   elif test "x$OPENJDK_TARGET_OS" = xaix; then
40570     ARFLAGS="-X64"
40571   elif test "x$OPENJDK_TARGET_OS" = xwindows; then
40572     # lib.exe is used as AR to create static libraries.
40573     ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
40574   else
40575     ARFLAGS=""
40576   fi
40577 
40578 
40579   ## Setup strip.
40580   # FIXME: should this really be per platform, or should it be per toolchain type?
40581   # strip is not provided by clang or solstudio; so guessing platform makes most sense.
40582   # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD.
40583   if test "x$OPENJDK_TARGET_OS" = xlinux; then
40584     STRIPFLAGS="-g"
40585   elif test "x$OPENJDK_TARGET_OS" = xsolaris; then
40586     STRIPFLAGS="-x"
40587   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
40588     STRIPFLAGS="-S"
40589   elif test "x$OPENJDK_TARGET_OS" = xaix; then
40590     STRIPFLAGS="-X32_64"
40591   fi
40592 
40593   if test "x$OPENJDK_TARGET_OS" != xwindows; then
40594     POST_STRIP_CMD="$STRIP $STRIPFLAGS"
40595   fi
40596 
40597 
40598   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40599     # FIXME: break out into MCSFLAGS
40600     POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
40601   fi
40602 
40603 
40604   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40605     CC_OUT_OPTION=-Fo
40606     EXE_OUT_OPTION=-out:
40607     LD_OUT_OPTION=-out:
40608     AR_OUT_OPTION=-out:
40609   else
40610     # The option used to specify the target .o,.a or .so file.
40611     # When compiling, how to specify the to be created object file.
40612     CC_OUT_OPTION='-o$(SPACE)'
40613     # When linking, how to specify the to be created executable.
40614     EXE_OUT_OPTION='-o$(SPACE)'
40615     # When linking, how to specify the to be created dynamically linkable library.
40616     LD_OUT_OPTION='-o$(SPACE)'
40617     # When archiving, how to specify the to be create static archive for object files.
40618     AR_OUT_OPTION='rcs$(SPACE)'
40619   fi
40620 
40621 
40622 
40623 
40624 
40625   # On Windows, we need to set RC flags.
40626   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40627     RC_FLAGS="-nologo -l 0x409 -r"
40628     if test "x$VARIANT" = xOPT; then
40629       RC_FLAGS="$RC_FLAGS -d NDEBUG"
40630     fi
40631 
40632     # The version variables used to create RC_FLAGS may be overridden
40633     # in a custom configure script, or possibly the command line.
40634     # Let those variables be expanded at make time in spec.gmk.
40635     # The \$ are escaped to the shell, and the $(...) variables
40636     # are evaluated by make.
40637     RC_FLAGS="$RC_FLAGS \
40638         -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40639         -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40640         -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40641         -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40642         -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40643         -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40644         -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40645   fi
40646 
40647 
40648   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40649     # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40650     CCXXFLAGS="$CCXXFLAGS -nologo"
40651   fi
40652 
40653 
40654 # FIXME: Currently we must test this after toolchain but before flags. Fix!
40655 
40656 # Now we can test some aspects on the target using configure macros.
40657 
40658 
40659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40660 $as_echo_n "checking for ANSI C header files... " >&6; }
40661 if ${ac_cv_header_stdc+:} false; then :
40662   $as_echo_n "(cached) " >&6
40663 else
40664   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40665 /* end confdefs.h.  */
40666 #include <stdlib.h>
40667 #include <stdarg.h>
40668 #include <string.h>
40669 #include <float.h>
40670 
40671 int
40672 main ()
40673 {
40674 
40675   ;
40676   return 0;
40677 }
40678 _ACEOF
40679 if ac_fn_cxx_try_compile "$LINENO"; then :
40680   ac_cv_header_stdc=yes
40681 else
40682   ac_cv_header_stdc=no
40683 fi
40684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40685 
40686 if test $ac_cv_header_stdc = yes; then
40687   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
40688   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40689 /* end confdefs.h.  */
40690 #include <string.h>
40691 
40692 _ACEOF
40693 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40694   $EGREP "memchr" >/dev/null 2>&1; then :
40695 
40696 else
40697   ac_cv_header_stdc=no
40698 fi
40699 rm -f conftest*
40700 
40701 fi
40702 
40703 if test $ac_cv_header_stdc = yes; then
40704   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
40705   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40706 /* end confdefs.h.  */
40707 #include <stdlib.h>
40708 
40709 _ACEOF
40710 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40711   $EGREP "free" >/dev/null 2>&1; then :
40712 
40713 else
40714   ac_cv_header_stdc=no
40715 fi
40716 rm -f conftest*
40717 
40718 fi
40719 
40720 if test $ac_cv_header_stdc = yes; then
40721   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
40722   if test "$cross_compiling" = yes; then :
40723   :
40724 else
40725   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40726 /* end confdefs.h.  */
40727 #include <ctype.h>
40728 #include <stdlib.h>
40729 #if ((' ' & 0x0FF) == 0x020)
40730 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
40731 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
40732 #else
40733 # define ISLOWER(c) \
40734                    (('a' <= (c) && (c) <= 'i') \
40735                      || ('j' <= (c) && (c) <= 'r') \
40736                      || ('s' <= (c) && (c) <= 'z'))
40737 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
40738 #endif
40739 
40740 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
40741 int
40742 main ()
40743 {
40744   int i;
40745   for (i = 0; i < 256; i++)
40746     if (XOR (islower (i), ISLOWER (i))
40747         || toupper (i) != TOUPPER (i))
40748       return 2;
40749   return 0;
40750 }
40751 _ACEOF
40752 if ac_fn_cxx_try_run "$LINENO"; then :
40753 
40754 else
40755   ac_cv_header_stdc=no
40756 fi
40757 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40758   conftest.$ac_objext conftest.beam conftest.$ac_ext
40759 fi
40760 
40761 fi
40762 fi
40763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
40764 $as_echo "$ac_cv_header_stdc" >&6; }
40765 if test $ac_cv_header_stdc = yes; then
40766 
40767 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
40768 
40769 fi
40770 
40771 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
40772 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
40773                   inttypes.h stdint.h unistd.h
40774 do :
40775   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
40776 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
40777 "
40778 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
40779   cat >>confdefs.h <<_ACEOF
40780 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
40781 _ACEOF
40782 
40783 fi
40784 
40785 done
40786 
40787 
40788 
40789   ###############################################################################
40790   #
40791   # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
40792   # (The JVM can use 32 or 64 bit Java pointers but that decision
40793   # is made at runtime.)
40794   #
40795 
40796   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
40797     # Always specify -m flag on Solaris
40798     # And -q on AIX because otherwise the compiler produces 32-bit objects by default
40799 
40800   # When we add flags to the "official" CFLAGS etc, we need to
40801   # keep track of these additions in ADDED_CFLAGS etc. These
40802   # will later be checked to make sure only controlled additions
40803   # have been made to CFLAGS etc.
40804   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40805   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40806   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40807 
40808   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40809   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40810   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40811 
40812   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40813   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40814   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40815 
40816   elif test "x$COMPILE_TYPE" = xreduced; then
40817     if test "x$OPENJDK_TARGET_OS" != xwindows; then
40818       # Specify -m if running reduced on other Posix platforms
40819 
40820   # When we add flags to the "official" CFLAGS etc, we need to
40821   # keep track of these additions in ADDED_CFLAGS etc. These
40822   # will later be checked to make sure only controlled additions
40823   # have been made to CFLAGS etc.
40824   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40825   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40826   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40827 
40828   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40829   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40830   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40831 
40832   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40833   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40834   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40835 
40836     fi
40837   fi
40838 
40839   # Make compilation sanity check
40840   for ac_header in stdio.h
40841 do :
40842   ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
40843 if test "x$ac_cv_header_stdio_h" = xyes; then :
40844   cat >>confdefs.h <<_ACEOF
40845 #define HAVE_STDIO_H 1
40846 _ACEOF
40847 
40848 else
40849 
40850     { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
40851 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
40852     if test "x$COMPILE_TYPE" = xreduced; then
40853       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
40854 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
40855     elif test "x$COMPILE_TYPE" = xcross; then
40856       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
40857 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
40858     fi
40859     as_fn_error $? "Cannot continue." "$LINENO" 5
40860 
40861 fi
40862 
40863 done
40864 
40865 
40866   # The cast to long int works around a bug in the HP C Compiler
40867 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40868 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40869 # This bug is HP SR number 8606223364.
40870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40871 $as_echo_n "checking size of int *... " >&6; }
40872 if ${ac_cv_sizeof_int_p+:} false; then :
40873   $as_echo_n "(cached) " >&6
40874 else
40875   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40876 
40877 else
40878   if test "$ac_cv_type_int_p" = yes; then
40879      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40880 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40881 as_fn_error 77 "cannot compute sizeof (int *)
40882 See \`config.log' for more details" "$LINENO" 5; }
40883    else
40884      ac_cv_sizeof_int_p=0
40885    fi
40886 fi
40887 
40888 fi
40889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40890 $as_echo "$ac_cv_sizeof_int_p" >&6; }
40891 
40892 
40893 
40894 cat >>confdefs.h <<_ACEOF
40895 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
40896 _ACEOF
40897 
40898 
40899 
40900   # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
40901   if test "x$ac_cv_sizeof_int_p" = x; then
40902     # The test failed, lets stick to the assumed value.
40903     { $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
40904 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
40905   else
40906     TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40907 
40908     if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40909       # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
40910       # Let's try to implicitely set the compilers target architecture and retry the test
40911       { $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
40912 $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;}
40913       { $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
40914 $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;}
40915 
40916   # When we add flags to the "official" CFLAGS etc, we need to
40917   # keep track of these additions in ADDED_CFLAGS etc. These
40918   # will later be checked to make sure only controlled additions
40919   # have been made to CFLAGS etc.
40920   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40921   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40922   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40923 
40924   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40925   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40926   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40927 
40928   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40929   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40930   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40931 
40932 
40933       # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
40934       unset ac_cv_sizeof_int_p
40935       # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
40936       cat >>confdefs.h <<_ACEOF
40937 #undef SIZEOF_INT_P
40938 _ACEOF
40939 
40940       # The cast to long int works around a bug in the HP C Compiler
40941 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40942 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40943 # This bug is HP SR number 8606223364.
40944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40945 $as_echo_n "checking size of int *... " >&6; }
40946 if ${ac_cv_sizeof_int_p+:} false; then :
40947   $as_echo_n "(cached) " >&6
40948 else
40949   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40950 
40951 else
40952   if test "$ac_cv_type_int_p" = yes; then
40953      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40954 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40955 as_fn_error 77 "cannot compute sizeof (int *)
40956 See \`config.log' for more details" "$LINENO" 5; }
40957    else
40958      ac_cv_sizeof_int_p=0
40959    fi
40960 fi
40961 
40962 fi
40963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40964 $as_echo "$ac_cv_sizeof_int_p" >&6; }
40965 
40966 
40967 
40968 cat >>confdefs.h <<_ACEOF
40969 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
40970 _ACEOF
40971 
40972 
40973 
40974       TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40975 
40976       if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40977         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
40978       fi
40979     fi
40980   fi
40981 
40982   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
40983 $as_echo_n "checking for target address size... " >&6; }
40984   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
40985 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
40986 
40987 
40988   ###############################################################################
40989   #
40990   # Is the target little of big endian?
40991   #
40992    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
40993 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
40994 if ${ac_cv_c_bigendian+:} false; then :
40995   $as_echo_n "(cached) " >&6
40996 else
40997   ac_cv_c_bigendian=unknown
40998     # See if we're dealing with a universal compiler.
40999     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41000 /* end confdefs.h.  */
41001 #ifndef __APPLE_CC__
41002                not a universal capable compiler
41003              #endif
41004              typedef int dummy;
41005 
41006 _ACEOF
41007 if ac_fn_cxx_try_compile "$LINENO"; then :
41008 
41009         # Check for potential -arch flags.  It is not universal unless
41010         # there are at least two -arch flags with different values.
41011         ac_arch=
41012         ac_prev=
41013         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
41014          if test -n "$ac_prev"; then
41015            case $ac_word in
41016              i?86 | x86_64 | ppc | ppc64)
41017                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
41018                  ac_arch=$ac_word
41019                else
41020                  ac_cv_c_bigendian=universal
41021                  break
41022                fi
41023                ;;
41024            esac
41025            ac_prev=
41026          elif test "x$ac_word" = "x-arch"; then
41027            ac_prev=arch
41028          fi
41029        done
41030 fi
41031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41032     if test $ac_cv_c_bigendian = unknown; then
41033       # See if sys/param.h defines the BYTE_ORDER macro.
41034       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41035 /* end confdefs.h.  */
41036 #include <sys/types.h>
41037              #include <sys/param.h>
41038 
41039 int
41040 main ()
41041 {
41042 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
41043                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
41044                      && LITTLE_ENDIAN)
41045               bogus endian macros
41046              #endif
41047 
41048   ;
41049   return 0;
41050 }
41051 _ACEOF
41052 if ac_fn_cxx_try_compile "$LINENO"; then :
41053   # It does; now see whether it defined to BIG_ENDIAN or not.
41054          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41055 /* end confdefs.h.  */
41056 #include <sys/types.h>
41057                 #include <sys/param.h>
41058 
41059 int
41060 main ()
41061 {
41062 #if BYTE_ORDER != BIG_ENDIAN
41063                  not big endian
41064                 #endif
41065 
41066   ;
41067   return 0;
41068 }
41069 _ACEOF
41070 if ac_fn_cxx_try_compile "$LINENO"; then :
41071   ac_cv_c_bigendian=yes
41072 else
41073   ac_cv_c_bigendian=no
41074 fi
41075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41076 fi
41077 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41078     fi
41079     if test $ac_cv_c_bigendian = unknown; then
41080       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
41081       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41082 /* end confdefs.h.  */
41083 #include <limits.h>
41084 
41085 int
41086 main ()
41087 {
41088 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
41089               bogus endian macros
41090              #endif
41091 
41092   ;
41093   return 0;
41094 }
41095 _ACEOF
41096 if ac_fn_cxx_try_compile "$LINENO"; then :
41097   # It does; now see whether it defined to _BIG_ENDIAN or not.
41098          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41099 /* end confdefs.h.  */
41100 #include <limits.h>
41101 
41102 int
41103 main ()
41104 {
41105 #ifndef _BIG_ENDIAN
41106                  not big endian
41107                 #endif
41108 
41109   ;
41110   return 0;
41111 }
41112 _ACEOF
41113 if ac_fn_cxx_try_compile "$LINENO"; then :
41114   ac_cv_c_bigendian=yes
41115 else
41116   ac_cv_c_bigendian=no
41117 fi
41118 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41119 fi
41120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41121     fi
41122     if test $ac_cv_c_bigendian = unknown; then
41123       # Compile a test program.
41124       if test "$cross_compiling" = yes; then :
41125   # Try to guess by grepping values from an object file.
41126          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41127 /* end confdefs.h.  */
41128 short int ascii_mm[] =
41129                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
41130                 short int ascii_ii[] =
41131                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
41132                 int use_ascii (int i) {
41133                   return ascii_mm[i] + ascii_ii[i];
41134                 }
41135                 short int ebcdic_ii[] =
41136                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
41137                 short int ebcdic_mm[] =
41138                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
41139                 int use_ebcdic (int i) {
41140                   return ebcdic_mm[i] + ebcdic_ii[i];
41141                 }
41142                 extern int foo;
41143 
41144 int
41145 main ()
41146 {
41147 return use_ascii (foo) == use_ebcdic (foo);
41148   ;
41149   return 0;
41150 }
41151 _ACEOF
41152 if ac_fn_cxx_try_compile "$LINENO"; then :
41153   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
41154               ac_cv_c_bigendian=yes
41155             fi
41156             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
41157               if test "$ac_cv_c_bigendian" = unknown; then
41158                 ac_cv_c_bigendian=no
41159               else
41160                 # finding both strings is unlikely to happen, but who knows?
41161                 ac_cv_c_bigendian=unknown
41162               fi
41163             fi
41164 fi
41165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41166 else
41167   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41168 /* end confdefs.h.  */
41169 $ac_includes_default
41170 int
41171 main ()
41172 {
41173 
41174              /* Are we little or big endian?  From Harbison&Steele.  */
41175              union
41176              {
41177                long int l;
41178                char c[sizeof (long int)];
41179              } u;
41180              u.l = 1;
41181              return u.c[sizeof (long int) - 1] == 1;
41182 
41183   ;
41184   return 0;
41185 }
41186 _ACEOF
41187 if ac_fn_cxx_try_run "$LINENO"; then :
41188   ac_cv_c_bigendian=no
41189 else
41190   ac_cv_c_bigendian=yes
41191 fi
41192 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41193   conftest.$ac_objext conftest.beam conftest.$ac_ext
41194 fi
41195 
41196     fi
41197 fi
41198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
41199 $as_echo "$ac_cv_c_bigendian" >&6; }
41200  case $ac_cv_c_bigendian in #(
41201    yes)
41202      ENDIAN="big";; #(
41203    no)
41204      ENDIAN="little" ;; #(
41205    universal)
41206      ENDIAN="universal_endianness"
41207      ;; #(
41208    *)
41209      ENDIAN="unknown" ;;
41210  esac
41211 
41212 
41213   if test "x$ENDIAN" = xuniversal_endianness; then
41214     as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
41215   fi
41216   if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
41217     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
41218   fi
41219 
41220 
41221 # Configure flags for the tools
41222 
41223   ###############################################################################
41224   #
41225   # How to compile shared libraries.
41226   #
41227 
41228   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41229     PICFLAG="-fPIC"
41230     C_FLAG_REORDER=''
41231     CXX_FLAG_REORDER=''
41232 
41233     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41234       # Linking is different on MacOSX
41235       SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41236       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41237       SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41238       SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41239       SET_SHARED_LIBRARY_MAPFILE=''
41240     else
41241       # Default works for linux, might work on other platforms as well.
41242       SHARED_LIBRARY_FLAGS='-shared'
41243       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41244       SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41245       SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41246       SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41247     fi
41248   elif test "x$TOOLCHAIN_TYPE" = xclang; then
41249     PICFLAG=''
41250     C_FLAG_REORDER=''
41251     CXX_FLAG_REORDER=''
41252 
41253     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41254       # Linking is different on MacOSX
41255       SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41256       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41257       SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41258       SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41259       SET_SHARED_LIBRARY_MAPFILE=''
41260     else
41261       # Default works for linux, might work on other platforms as well.
41262       SHARED_LIBRARY_FLAGS='-shared'
41263       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41264       SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41265       SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41266       SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41267     fi
41268   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41269     PICFLAG="-KPIC"
41270     C_FLAG_REORDER='-xF'
41271     CXX_FLAG_REORDER='-xF'
41272     SHARED_LIBRARY_FLAGS="-G"
41273     SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1'
41274     SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41275     SET_SHARED_LIBRARY_NAME=''
41276     SET_SHARED_LIBRARY_MAPFILE='-M$1'
41277   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41278     PICFLAG="-qpic=large"
41279     C_FLAG_REORDER=''
41280     CXX_FLAG_REORDER=''
41281     SHARED_LIBRARY_FLAGS="-qmkshrobj"
41282     SET_EXECUTABLE_ORIGIN=""
41283     SET_SHARED_LIBRARY_ORIGIN=''
41284     SET_SHARED_LIBRARY_NAME=''
41285     SET_SHARED_LIBRARY_MAPFILE=''
41286   elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41287     PICFLAG=""
41288     C_FLAG_REORDER=''
41289     CXX_FLAG_REORDER=''
41290     SHARED_LIBRARY_FLAGS="-LD"
41291     SET_EXECUTABLE_ORIGIN=''
41292     SET_SHARED_LIBRARY_ORIGIN=''
41293     SET_SHARED_LIBRARY_NAME=''
41294     SET_SHARED_LIBRARY_MAPFILE=''
41295   fi
41296 
41297 
41298 
41299 
41300 
41301 
41302 
41303 
41304 
41305   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41306     CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
41307     CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
41308     CFLAGS_JDKLIB_EXTRA='-xstrconst'
41309   fi
41310   # The (cross) compiler is now configured, we can now test capabilities
41311   # of the target platform.
41312 
41313 
41314 
41315   ###############################################################################
41316   #
41317   # Setup the opt flags for different compilers
41318   # and different operating systems.
41319   #
41320 
41321   # FIXME: this was indirectly the old default, but just inherited.
41322   # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41323   #   C_FLAG_DEPS="-MMD -MF"
41324   # fi
41325 
41326   # Generate make dependency files
41327   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41328     C_FLAG_DEPS="-MMD -MF"
41329   elif test "x$TOOLCHAIN_TYPE" = xclang; then
41330     C_FLAG_DEPS="-MMD -MF"
41331   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41332     C_FLAG_DEPS="-xMMD -xMF"
41333   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41334     C_FLAG_DEPS="-qmakedep=gcc -MF"
41335   fi
41336   CXX_FLAG_DEPS="$C_FLAG_DEPS"
41337 
41338 
41339 
41340   # Debug symbols
41341   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41342     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
41343       CFLAGS_DEBUG_SYMBOLS="-g1"
41344       CXXFLAGS_DEBUG_SYMBOLS="-g1"
41345     else
41346       CFLAGS_DEBUG_SYMBOLS="-g"
41347       CXXFLAGS_DEBUG_SYMBOLS="-g"
41348     fi
41349   elif test "x$TOOLCHAIN_TYPE" = xclang; then
41350     CFLAGS_DEBUG_SYMBOLS="-g"
41351     CXXFLAGS_DEBUG_SYMBOLS="-g"
41352   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41353     CFLAGS_DEBUG_SYMBOLS="-g -xs"
41354     CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
41355   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41356     CFLAGS_DEBUG_SYMBOLS="-g"
41357     CXXFLAGS_DEBUG_SYMBOLS="-g"
41358   fi
41359 
41360 
41361 
41362   # Optimization levels
41363   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41364     CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xalias_level=basic -xbuiltin=%all -xdepend -xrestrict -xlibmil"
41365 
41366     if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
41367       # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global?
41368       C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr"
41369       C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
41370       C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
41371       C_O_FLAG_NONE="-xregs=no%frameptr"
41372       CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
41373       CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
41374       CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
41375       CXX_O_FLAG_NONE="-xregs=no%frameptr"
41376       if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41377         C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
41378         CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
41379       fi
41380     elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41381       C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41382       C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41383       C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41384       C_O_FLAG_NONE=""
41385       CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41386       CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41387       CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41388       CXX_O_FLAG_NONE=""
41389     fi
41390   else
41391     # The remaining toolchains share opt flags between CC and CXX;
41392     # setup for C and duplicate afterwards.
41393     if test "x$TOOLCHAIN_TYPE" = xgcc; then
41394       if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41395         # On MacOSX we optimize for size, something
41396         # we should do for all platforms?
41397         C_O_FLAG_HIGHEST="-Os"
41398         C_O_FLAG_HI="-Os"
41399         C_O_FLAG_NORM="-Os"
41400         C_O_FLAG_NONE=""
41401       else
41402         C_O_FLAG_HIGHEST="-O3"
41403         C_O_FLAG_HI="-O3"
41404         C_O_FLAG_NORM="-O2"
41405         C_O_FLAG_NONE="-O0"
41406       fi
41407     elif test "x$TOOLCHAIN_TYPE" = xclang; then
41408       if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41409         # On MacOSX we optimize for size, something
41410         # we should do for all platforms?
41411         C_O_FLAG_HIGHEST="-Os"
41412         C_O_FLAG_HI="-Os"
41413         C_O_FLAG_NORM="-Os"
41414         C_O_FLAG_NONE=""
41415       else
41416         C_O_FLAG_HIGHEST="-O3"
41417         C_O_FLAG_HI="-O3"
41418         C_O_FLAG_NORM="-O2"
41419         C_O_FLAG_NONE="-O0"
41420       fi
41421     elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41422       C_O_FLAG_HIGHEST="-O3"
41423       C_O_FLAG_HI="-O3 -qstrict"
41424       C_O_FLAG_NORM="-O2"
41425       C_O_FLAG_NONE=""
41426     elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41427       C_O_FLAG_HIGHEST="-O2"
41428       C_O_FLAG_HI="-O1"
41429       C_O_FLAG_NORM="-O1"
41430       C_O_FLAG_NONE="-Od"
41431     fi
41432     CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
41433     CXX_O_FLAG_HI="$C_O_FLAG_HI"
41434     CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41435     CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41436   fi
41437 
41438 
41439 
41440 
41441 
41442 
41443 
41444 
41445 
41446 
41447 
41448   # Special extras...
41449   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41450     if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41451       CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41452       CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41453     fi
41454   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41455     LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
41456     CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41457     CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41458   fi
41459 
41460   if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
41461     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
41462 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
41463   fi
41464 
41465   if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
41466     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
41467 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
41468   fi
41469 
41470   if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
41471     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
41472 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
41473   fi
41474 
41475 
41476 # Check whether --with-extra-cflags was given.
41477 if test "${with_extra_cflags+set}" = set; then :
41478   withval=$with_extra_cflags;
41479 fi
41480 
41481 
41482 
41483 # Check whether --with-extra-cxxflags was given.
41484 if test "${with_extra_cxxflags+set}" = set; then :
41485   withval=$with_extra_cxxflags;
41486 fi
41487 
41488 
41489 
41490 # Check whether --with-extra-ldflags was given.
41491 if test "${with_extra_ldflags+set}" = set; then :
41492   withval=$with_extra_ldflags;
41493 fi
41494 
41495 
41496   CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41497   CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41498   LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41499 
41500   # Hotspot needs these set in their legacy form
41501   LEGACY_EXTRA_CFLAGS=$with_extra_cflags
41502   LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags
41503   LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags
41504 
41505 
41506 
41507 
41508 
41509   ###############################################################################
41510   #
41511   # Now setup the CFLAGS and LDFLAGS for the JDK build.
41512   # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41513   #
41514 
41515   # Setup compiler/platform specific flags to CFLAGS_JDK,
41516   # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41517   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41518     # these options are used for both C and C++ compiles
41519     CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41520         -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41521     case $OPENJDK_TARGET_CPU_ARCH in
41522       arm )
41523         # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
41524         CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41525         ;;
41526       ppc )
41527         # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing
41528         ;;
41529       * )
41530         CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer"
41531         CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41532         ;;
41533     esac
41534   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41535     CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
41536     if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
41537       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
41538       CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
41539     fi
41540 
41541     CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
41542     CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
41543   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41544     CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41545     CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41546   elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41547     CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
41548     -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
41549     -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
41550     -DWIN32 -DIAL"
41551     if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
41552       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64"
41553     else
41554       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86"
41555     fi
41556   fi
41557 
41558   ###############################################################################
41559 
41560   # Adjust flags according to debug level.
41561   case $DEBUG_LEVEL in
41562     fastdebug )
41563       CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41564       CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41565       C_O_FLAG_HI="$C_O_FLAG_NORM"
41566       C_O_FLAG_NORM="$C_O_FLAG_NORM"
41567       CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
41568       CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM"
41569       JAVAC_FLAGS="$JAVAC_FLAGS -g"
41570       ;;
41571     slowdebug )
41572       CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41573       CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41574       C_O_FLAG_HI="$C_O_FLAG_NONE"
41575       C_O_FLAG_NORM="$C_O_FLAG_NONE"
41576       CXX_O_FLAG_HI="$CXX_O_FLAG_NONE"
41577       CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE"
41578       JAVAC_FLAGS="$JAVAC_FLAGS -g"
41579       ;;
41580   esac
41581 
41582   # Setup LP64
41583   CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41584 
41585   # Set some common defines. These works for all compilers, but assume
41586   # -D is universally accepted.
41587 
41588   # Setup endianness
41589   if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41590     # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41591     #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41592     #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41593     #   Note: -Dmacro         is the same as    #define macro 1
41594     #         -Dmacro=        is the same as    #define macro
41595     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41596       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41597     else
41598       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41599     fi
41600   else
41601     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41602   fi
41603 
41604   # Setup target OS define. Use OS target name but in upper case.
41605   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41606   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41607 
41608   # Setup target CPU
41609   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41610 
41611   # Setup debug/release defines
41612   if test "x$DEBUG_LEVEL" = xrelease; then
41613     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41614     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41615       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41616     fi
41617   else
41618     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41619   fi
41620 
41621   # Setup release name
41622   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
41623 
41624 
41625   # Set some additional per-OS defines.
41626   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41627     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
41628   elif test "x$OPENJDK_TARGET_OS" = xaix; then
41629     # FIXME: PPC64 should not be here.
41630     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DPPC64"
41631   elif test "x$OPENJDK_TARGET_OS" = xbsd; then
41632     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
41633   fi
41634 
41635   # Additional macosx handling
41636   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41637     if test "x$TOOLCHAIN_TYPE" = xgcc; then
41638       # FIXME: This needs to be exported in spec.gmk due to closed legacy code.
41639       # FIXME: clean this up, and/or move it elsewhere.
41640 
41641       # Setting these parameters makes it an error to link to macosx APIs that are
41642       # newer than the given OS version and makes the linked binaries compatible
41643       # even if built on a newer version of the OS.
41644       # The expected format is X.Y.Z
41645       MACOSX_VERSION_MIN=10.7.0
41646 
41647 
41648       # The macro takes the version with no dots, ex: 1070
41649       # Let the flags variables get resolved in make for easier override on make
41650       # command line.
41651       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41652       LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41653     fi
41654   fi
41655 
41656   # Setup some hard coded includes
41657   CCXXFLAGS_JDK="$CCXXFLAGS_JDK \
41658       -I${JDK_OUTPUTDIR}/include \
41659       -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \
41660       -I${JDK_TOPDIR}/src/share/javavm/export \
41661       -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_EXPORT_DIR/javavm/export \
41662       -I${JDK_TOPDIR}/src/share/native/common \
41663       -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common"
41664 
41665   # The shared libraries are compiled using the picflag.
41666   CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
41667   CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
41668 
41669   # Executable flags
41670   CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK"
41671   CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK"
41672 
41673 
41674 
41675 
41676 
41677 
41678   # Setup LDFLAGS et al.
41679   #
41680   # Now this is odd. The JDK native libraries have to link against libjvm.so
41681   # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
41682   # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
41683   # is identical for client and server? Yes. Which is picked at runtime (client or server)?
41684   # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
41685   # libraries will link to whatever is in memory. Yuck.
41686   #
41687   # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
41688   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41689     LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
41690     if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41691       LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
41692     fi
41693     # TODO: make -debug optional "--disable-full-debug-symbols"
41694     LDFLAGS_JDK="$LDFLAGS_JDK -debug"
41695     LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib"
41696     LDFLAGS_JDKLIB_SUFFIX=""
41697     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
41698       LDFLAGS_STACK_SIZE=1048576
41699     else
41700       LDFLAGS_STACK_SIZE=327680
41701     fi
41702     LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE"
41703   else
41704     if test "x$TOOLCHAIN_TYPE" = xgcc; then
41705       # If this is a --hash-style=gnu system, use --hash-style=both, why?
41706       # We have previously set HAS_GNU_HASH if this is the case
41707       if test -n "$HAS_GNU_HASH"; then
41708         LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both "
41709       fi
41710       if test "x$OPENJDK_TARGET_OS" = xlinux; then
41711         # And since we now know that the linker is gnu, then add -z defs, to forbid
41712         # undefined symbols in object files.
41713         LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
41714         if test "x$DEBUG_LEVEL" = "xrelease"; then
41715           # When building release libraries, tell the linker optimize them.
41716           # Should this be supplied to the OSS linker as well?
41717           LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
41718         fi
41719       fi
41720     fi
41721 
41722     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41723       LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
41724       LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
41725     fi
41726 
41727     LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \
41728         -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
41729 
41730     # On some platforms (mac) the linker warns about non existing -L dirs.
41731     # Add server first if available. Linking aginst client does not always produce the same results.
41732     # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
41733     # Default to server for other variants.
41734     if test "x$JVM_VARIANT_SERVER" = xtrue; then
41735       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41736     elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
41737       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
41738     elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
41739       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
41740     else
41741       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41742     fi
41743 
41744     LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
41745     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41746       LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
41747     fi
41748 
41749     LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
41750     if test "x$OPENJDK_TARGET_OS" = xlinux; then
41751       LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
41752     fi
41753   fi
41754 
41755 
41756 
41757 
41758 
41759 
41760 
41761 
41762   # Some Zero and Shark settings.
41763   # ZERO_ARCHFLAG tells the compiler which mode to build for
41764   case "${OPENJDK_TARGET_CPU}" in
41765     s390)
41766       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
41767       ;;
41768     *)
41769       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41770   esac
41771 
41772   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
41773 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
41774   supports=yes
41775 
41776   saved_cflags="$CFLAGS"
41777   CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
41778   ac_ext=c
41779 ac_cpp='$CPP $CPPFLAGS'
41780 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41781 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41782 ac_compiler_gnu=$ac_cv_c_compiler_gnu
41783 
41784   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41785 /* end confdefs.h.  */
41786 int i;
41787 _ACEOF
41788 if ac_fn_c_try_compile "$LINENO"; then :
41789 
41790 else
41791   supports=no
41792 fi
41793 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41794   ac_ext=cpp
41795 ac_cpp='$CXXCPP $CPPFLAGS'
41796 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41797 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41798 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41799 
41800   CFLAGS="$saved_cflags"
41801 
41802   saved_cxxflags="$CXXFLAGS"
41803   CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
41804   ac_ext=cpp
41805 ac_cpp='$CXXCPP $CPPFLAGS'
41806 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41807 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41808 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41809 
41810   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41811 /* end confdefs.h.  */
41812 int i;
41813 _ACEOF
41814 if ac_fn_cxx_try_compile "$LINENO"; then :
41815 
41816 else
41817   supports=no
41818 fi
41819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41820   ac_ext=cpp
41821 ac_cpp='$CXXCPP $CPPFLAGS'
41822 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41823 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41824 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41825 
41826   CXXFLAGS="$saved_cxxflags"
41827 
41828   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41829 $as_echo "$supports" >&6; }
41830   if test "x$supports" = "xyes" ; then
41831     :
41832   else
41833     ZERO_ARCHFLAG=""
41834   fi
41835 
41836 
41837 
41838   # Check that the compiler supports -mX (or -qX on AIX) flags
41839   # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
41840 
41841   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
41842 $as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
41843   supports=yes
41844 
41845   saved_cflags="$CFLAGS"
41846   CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41847   ac_ext=c
41848 ac_cpp='$CPP $CPPFLAGS'
41849 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41850 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41851 ac_compiler_gnu=$ac_cv_c_compiler_gnu
41852 
41853   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41854 /* end confdefs.h.  */
41855 int i;
41856 _ACEOF
41857 if ac_fn_c_try_compile "$LINENO"; then :
41858 
41859 else
41860   supports=no
41861 fi
41862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41863   ac_ext=cpp
41864 ac_cpp='$CXXCPP $CPPFLAGS'
41865 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41866 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41867 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41868 
41869   CFLAGS="$saved_cflags"
41870 
41871   saved_cxxflags="$CXXFLAGS"
41872   CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41873   ac_ext=cpp
41874 ac_cpp='$CXXCPP $CPPFLAGS'
41875 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41876 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41877 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41878 
41879   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41880 /* end confdefs.h.  */
41881 int i;
41882 _ACEOF
41883 if ac_fn_cxx_try_compile "$LINENO"; then :
41884 
41885 else
41886   supports=no
41887 fi
41888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41889   ac_ext=cpp
41890 ac_cpp='$CXXCPP $CPPFLAGS'
41891 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41892 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41893 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41894 
41895   CXXFLAGS="$saved_cxxflags"
41896 
41897   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41898 $as_echo "$supports" >&6; }
41899   if test "x$supports" = "xyes" ; then
41900     COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
41901   else
41902     COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
41903   fi
41904 
41905 
41906 
41907 
41908 # Setup debug symbols (need objcopy from the toolchain for that)
41909 
41910   #
41911   # ENABLE_DEBUG_SYMBOLS
41912   # This must be done after the toolchain is setup, since we're looking at objcopy.
41913   #
41914   # Check whether --enable-debug-symbols was given.
41915 if test "${enable_debug_symbols+set}" = set; then :
41916   enableval=$enable_debug_symbols;
41917 fi
41918 
41919 
41920   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
41921 $as_echo_n "checking if we should generate debug symbols... " >&6; }
41922 
41923   if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
41924     # explicit enabling of enable-debug-symbols and can't find objcopy
41925     #   this is an error
41926     as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
41927   fi
41928 
41929   if test "x$enable_debug_symbols" = "xyes"; then
41930     ENABLE_DEBUG_SYMBOLS=true
41931   elif test "x$enable_debug_symbols" = "xno"; then
41932     ENABLE_DEBUG_SYMBOLS=false
41933   else
41934     # Default is on if objcopy is found
41935     if test "x$OBJCOPY" != x; then
41936       ENABLE_DEBUG_SYMBOLS=true
41937     # MacOS X and Windows don't use objcopy but default is on for those OSes
41938     elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
41939       ENABLE_DEBUG_SYMBOLS=true
41940     else
41941       ENABLE_DEBUG_SYMBOLS=false
41942     fi
41943   fi
41944 
41945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
41946 $as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
41947 
41948   #
41949   # ZIP_DEBUGINFO_FILES
41950   #
41951   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
41952 $as_echo_n "checking if we should zip debug-info files... " >&6; }
41953   # Check whether --enable-zip-debug-info was given.
41954 if test "${enable_zip_debug_info+set}" = set; then :
41955   enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
41956 else
41957   enable_zip_debug_info="yes"
41958 fi
41959 
41960   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
41961 $as_echo "${enable_zip_debug_info}" >&6; }
41962 
41963   if test "x${enable_zip_debug_info}" = "xno"; then
41964     ZIP_DEBUGINFO_FILES=false
41965   else
41966     ZIP_DEBUGINFO_FILES=true
41967   fi
41968 
41969 
41970 
41971 
41972 
41973 ###############################################################################
41974 #
41975 # Check dependencies for external and internal libraries.
41976 #
41977 ###############################################################################
41978 
41979 # After we have toolchain, we can compile fixpath. It's needed by the lib checks.
41980 
41981   # When using cygwin or msys, we need a wrapper binary that renames
41982   # /cygdrive/c/ arguments into c:/ arguments and peeks into
41983   # @files and rewrites these too! This wrapper binary is
41984   # called fixpath.
41985   FIXPATH=
41986   if test "x$OPENJDK_BUILD_OS" = xwindows; then
41987     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
41988 $as_echo_n "checking if fixpath can be created... " >&6; }
41989     FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
41990     FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
41991     if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
41992       FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
41993       FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
41994       # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
41995       FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
41996     elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
41997       FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
41998       FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
41999 
42000       # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
42001       # @ was chosen as separator to minimize risk of other tools messing around with it
42002       all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
42003       fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
42004 
42005       FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
42006     fi
42007     rm -f $OUTPUT_ROOT/fixpath*
42008     cd $OUTPUT_ROOT
42009     $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
42010     cd $CURDIR
42011 
42012     if test ! -x $OUTPUT_ROOT/fixpath.exe; then
42013       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42014 $as_echo "no" >&6; }
42015       cat $OUTPUT_ROOT/fixpath1.log
42016       as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
42017     fi
42018     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42019 $as_echo "yes" >&6; }
42020     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
42021 $as_echo_n "checking if fixpath.exe works... " >&6; }
42022     cd $OUTPUT_ROOT
42023     $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
42024     cd $CURDIR
42025     if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
42026       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42027 $as_echo "no" >&6; }
42028       cat $OUTPUT_ROOT/fixpath2.log
42029       as_fn_error $? "fixpath did not work!" "$LINENO" 5
42030     fi
42031     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42032 $as_echo "yes" >&6; }
42033     rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
42034   fi
42035 
42036 
42037 
42038 
42039 
42040 
42041   ###############################################################################
42042   #
42043   # OS specific settings that we never will need to probe.
42044   #
42045   if test "x$OPENJDK_TARGET_OS" = xlinux; then
42046     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
42047 $as_echo_n "checking what is not needed on Linux?... " >&6; }
42048     PULSE_NOT_NEEDED=yes
42049     { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
42050 $as_echo "pulse" >&6; }
42051   fi
42052 
42053   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42054     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
42055 $as_echo_n "checking what is not needed on Solaris?... " >&6; }
42056     ALSA_NOT_NEEDED=yes
42057     PULSE_NOT_NEEDED=yes
42058     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42059 $as_echo "alsa pulse" >&6; }
42060   fi
42061 
42062   if test "x$OPENJDK_TARGET_OS" = xaix; then
42063     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
42064 $as_echo_n "checking what is not needed on AIX?... " >&6; }
42065     ALSA_NOT_NEEDED=yes
42066     PULSE_NOT_NEEDED=yes
42067     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42068 $as_echo "alsa pulse" >&6; }
42069   fi
42070 
42071 
42072   if test "x$OPENJDK_TARGET_OS" = xwindows; then
42073     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
42074 $as_echo_n "checking what is not needed on Windows?... " >&6; }
42075     CUPS_NOT_NEEDED=yes
42076     ALSA_NOT_NEEDED=yes
42077     PULSE_NOT_NEEDED=yes
42078     X11_NOT_NEEDED=yes
42079     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
42080 $as_echo "alsa cups pulse x11" >&6; }
42081   fi
42082 
42083   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42084     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
42085 $as_echo_n "checking what is not needed on MacOSX?... " >&6; }
42086     ALSA_NOT_NEEDED=yes
42087     PULSE_NOT_NEEDED=yes
42088     X11_NOT_NEEDED=yes
42089     # If the java runtime framework is disabled, then we need X11.
42090     # This will be adjusted below.
42091     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
42092 $as_echo "alsa pulse x11" >&6; }
42093   fi
42094 
42095   if test "x$OPENJDK_TARGET_OS" = xbsd; then
42096     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
42097 $as_echo_n "checking what is not needed on bsd?... " >&6; }
42098     ALSA_NOT_NEEDED=yes
42099     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
42100 $as_echo "alsa" >&6; }
42101   fi
42102 
42103   if test "x$OPENJDK" = "xfalse"; then
42104     FREETYPE_NOT_NEEDED=yes
42105   fi
42106 
42107   if test "x$SUPPORT_HEADFUL" = xno; then
42108     X11_NOT_NEEDED=yes
42109   fi
42110 
42111   ###############################################################################
42112   #
42113   # Check for MacOSX support for OpenJDK.
42114   #
42115 
42116 
42117   # Check whether --enable-macosx-runtime-support was given.
42118 if test "${enable_macosx_runtime_support+set}" = set; then :
42119   enableval=$enable_macosx_runtime_support;
42120 fi
42121 
42122   if test "x$enable_macosx_runtime_support" != x; then
42123     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&5
42124 $as_echo "$as_me: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&2;}
42125   fi
42126 
42127 
42128   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42129 $as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42130   if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42131     { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42132 $as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42133   else
42134     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42135 $as_echo "no" >&6; }
42136   fi
42137 
42138 
42139 
42140   ###############################################################################
42141   #
42142   # Check for X Windows
42143   #
42144 
42145   # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42146   # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42147   # --x-libraries for the sysroot, if that seems to be correct.
42148   if test "x$SYS_ROOT" != "x/"; then
42149     if test "x$x_includes" = xNONE; then
42150       if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then
42151         x_includes="$SYS_ROOT/usr/X11R6/include"
42152       elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then
42153         x_includes="$SYS_ROOT/usr/include"
42154       fi
42155     fi
42156     if test "x$x_libraries" = xNONE; then
42157       if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then
42158         x_libraries="$SYS_ROOT/usr/X11R6/lib"
42159       elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42160         x_libraries="$SYS_ROOT/usr/lib64"
42161       elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then
42162         x_libraries="$SYS_ROOT/usr/lib"
42163       fi
42164     fi
42165   fi
42166 
42167   # Now let autoconf do it's magic
42168   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42169 $as_echo_n "checking for X... " >&6; }
42170 
42171 
42172 # Check whether --with-x was given.
42173 if test "${with_x+set}" = set; then :
42174   withval=$with_x;
42175 fi
42176 
42177 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42178 if test "x$with_x" = xno; then
42179   # The user explicitly disabled X.
42180   have_x=disabled
42181 else
42182   case $x_includes,$x_libraries in #(
42183     *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
42184     *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
42185   $as_echo_n "(cached) " >&6
42186 else
42187   # One or both of the vars are not set, and there is no cached value.
42188 ac_x_includes=no ac_x_libraries=no
42189 rm -f -r conftest.dir
42190 if mkdir conftest.dir; then
42191   cd conftest.dir
42192   cat >Imakefile <<'_ACEOF'
42193 incroot:
42194         @echo incroot='${INCROOT}'
42195 usrlibdir:
42196         @echo usrlibdir='${USRLIBDIR}'
42197 libdir:
42198         @echo libdir='${LIBDIR}'
42199 _ACEOF
42200   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
42201     # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
42202     for ac_var in incroot usrlibdir libdir; do
42203       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
42204     done
42205     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
42206     for ac_extension in a so sl dylib la dll; do
42207       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
42208          test -f "$ac_im_libdir/libX11.$ac_extension"; then
42209         ac_im_usrlibdir=$ac_im_libdir; break
42210       fi
42211     done
42212     # Screen out bogus values from the imake configuration.  They are
42213     # bogus both because they are the default anyway, and because
42214     # using them would break gcc on systems where it needs fixed includes.
42215     case $ac_im_incroot in
42216         /usr/include) ac_x_includes= ;;
42217         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
42218     esac
42219     case $ac_im_usrlibdir in
42220         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
42221         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
42222     esac
42223   fi
42224   cd ..
42225   rm -f -r conftest.dir
42226 fi
42227 
42228 # Standard set of common directories for X headers.
42229 # Check X11 before X11Rn because it is often a symlink to the current release.
42230 ac_x_header_dirs='
42231 /usr/X11/include
42232 /usr/X11R7/include
42233 /usr/X11R6/include
42234 /usr/X11R5/include
42235 /usr/X11R4/include
42236 
42237 /usr/include/X11
42238 /usr/include/X11R7
42239 /usr/include/X11R6
42240 /usr/include/X11R5
42241 /usr/include/X11R4
42242 
42243 /usr/local/X11/include
42244 /usr/local/X11R7/include
42245 /usr/local/X11R6/include
42246 /usr/local/X11R5/include
42247 /usr/local/X11R4/include
42248 
42249 /usr/local/include/X11
42250 /usr/local/include/X11R7
42251 /usr/local/include/X11R6
42252 /usr/local/include/X11R5
42253 /usr/local/include/X11R4
42254 
42255 /usr/X386/include
42256 /usr/x386/include
42257 /usr/XFree86/include/X11
42258 
42259 /usr/include
42260 /usr/local/include
42261 /usr/unsupported/include
42262 /usr/athena/include
42263 /usr/local/x11r5/include
42264 /usr/lpp/Xamples/include
42265 
42266 /usr/openwin/include
42267 /usr/openwin/share/include'
42268 
42269 if test "$ac_x_includes" = no; then
42270   # Guess where to find include files, by looking for Xlib.h.
42271   # First, try using that file with no special directory specified.
42272   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42273 /* end confdefs.h.  */
42274 #include <X11/Xlib.h>
42275 _ACEOF
42276 if ac_fn_cxx_try_cpp "$LINENO"; then :
42277   # We can compile using X headers with no special include directory.
42278 ac_x_includes=
42279 else
42280   for ac_dir in $ac_x_header_dirs; do
42281   if test -r "$ac_dir/X11/Xlib.h"; then
42282     ac_x_includes=$ac_dir
42283     break
42284   fi
42285 done
42286 fi
42287 rm -f conftest.err conftest.i conftest.$ac_ext
42288 fi # $ac_x_includes = no
42289 
42290 if test "$ac_x_libraries" = no; then
42291   # Check for the libraries.
42292   # See if we find them without any special options.
42293   # Don't add to $LIBS permanently.
42294   ac_save_LIBS=$LIBS
42295   LIBS="-lX11 $LIBS"
42296   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42297 /* end confdefs.h.  */
42298 #include <X11/Xlib.h>
42299 int
42300 main ()
42301 {
42302 XrmInitialize ()
42303   ;
42304   return 0;
42305 }
42306 _ACEOF
42307 if ac_fn_cxx_try_link "$LINENO"; then :
42308   LIBS=$ac_save_LIBS
42309 # We can link X programs with no special library path.
42310 ac_x_libraries=
42311 else
42312   LIBS=$ac_save_LIBS
42313 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
42314 do
42315   # Don't even attempt the hair of trying to link an X program!
42316   for ac_extension in a so sl dylib la dll; do
42317     if test -r "$ac_dir/libX11.$ac_extension"; then
42318       ac_x_libraries=$ac_dir
42319       break 2
42320     fi
42321   done
42322 done
42323 fi
42324 rm -f core conftest.err conftest.$ac_objext \
42325     conftest$ac_exeext conftest.$ac_ext
42326 fi # $ac_x_libraries = no
42327 
42328 case $ac_x_includes,$ac_x_libraries in #(
42329   no,* | *,no | *\'*)
42330     # Didn't find X, or a directory has "'" in its name.
42331     ac_cv_have_x="have_x=no";; #(
42332   *)
42333     # Record where we found X for the cache.
42334     ac_cv_have_x="have_x=yes\
42335         ac_x_includes='$ac_x_includes'\
42336         ac_x_libraries='$ac_x_libraries'"
42337 esac
42338 fi
42339 ;; #(
42340     *) have_x=yes;;
42341   esac
42342   eval "$ac_cv_have_x"
42343 fi # $with_x != no
42344 
42345 if test "$have_x" != yes; then
42346   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
42347 $as_echo "$have_x" >&6; }
42348   no_x=yes
42349 else
42350   # If each of the values was on the command line, it overrides each guess.
42351   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
42352   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
42353   # Update the cache value to reflect the command line values.
42354   ac_cv_have_x="have_x=yes\
42355         ac_x_includes='$x_includes'\
42356         ac_x_libraries='$x_libraries'"
42357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
42358 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
42359 fi
42360 
42361   if test "$no_x" = yes; then
42362   # Not all programs may use this symbol, but it does not hurt to define it.
42363 
42364 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
42365 
42366   X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
42367 else
42368   if test -n "$x_includes"; then
42369     X_CFLAGS="$X_CFLAGS -I$x_includes"
42370   fi
42371 
42372   # It would also be nice to do this for all -L options, not just this one.
42373   if test -n "$x_libraries"; then
42374     X_LIBS="$X_LIBS -L$x_libraries"
42375     # For Solaris; some versions of Sun CC require a space after -R and
42376     # others require no space.  Words are not sufficient . . . .
42377     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
42378 $as_echo_n "checking whether -R must be followed by a space... " >&6; }
42379     ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
42380     ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
42381     ac_cxx_werror_flag=yes
42382     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42383 /* end confdefs.h.  */
42384 
42385 int
42386 main ()
42387 {
42388 
42389   ;
42390   return 0;
42391 }
42392 _ACEOF
42393 if ac_fn_cxx_try_link "$LINENO"; then :
42394   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42395 $as_echo "no" >&6; }
42396        X_LIBS="$X_LIBS -R$x_libraries"
42397 else
42398   LIBS="$ac_xsave_LIBS -R $x_libraries"
42399        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42400 /* end confdefs.h.  */
42401 
42402 int
42403 main ()
42404 {
42405 
42406   ;
42407   return 0;
42408 }
42409 _ACEOF
42410 if ac_fn_cxx_try_link "$LINENO"; then :
42411   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42412 $as_echo "yes" >&6; }
42413           X_LIBS="$X_LIBS -R $x_libraries"
42414 else
42415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
42416 $as_echo "neither works" >&6; }
42417 fi
42418 rm -f core conftest.err conftest.$ac_objext \
42419     conftest$ac_exeext conftest.$ac_ext
42420 fi
42421 rm -f core conftest.err conftest.$ac_objext \
42422     conftest$ac_exeext conftest.$ac_ext
42423     ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
42424     LIBS=$ac_xsave_LIBS
42425   fi
42426 
42427   # Check for system-dependent libraries X programs must link with.
42428   # Do this before checking for the system-independent R6 libraries
42429   # (-lICE), since we may need -lsocket or whatever for X linking.
42430 
42431   if test "$ISC" = yes; then
42432     X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
42433   else
42434     # Martyn Johnson says this is needed for Ultrix, if the X
42435     # libraries were built with DECnet support.  And Karl Berry says
42436     # the Alpha needs dnet_stub (dnet does not exist).
42437     ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
42438     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42439 /* end confdefs.h.  */
42440 
42441 /* Override any GCC internal prototype to avoid an error.
42442    Use char because int might match the return type of a GCC
42443    builtin and then its argument prototype would still apply.  */
42444 #ifdef __cplusplus
42445 extern "C"
42446 #endif
42447 char XOpenDisplay ();
42448 int
42449 main ()
42450 {
42451 return XOpenDisplay ();
42452   ;
42453   return 0;
42454 }
42455 _ACEOF
42456 if ac_fn_cxx_try_link "$LINENO"; then :
42457 
42458 else
42459   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
42460 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
42461 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
42462   $as_echo_n "(cached) " >&6
42463 else
42464   ac_check_lib_save_LIBS=$LIBS
42465 LIBS="-ldnet  $LIBS"
42466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42467 /* end confdefs.h.  */
42468 
42469 /* Override any GCC internal prototype to avoid an error.
42470    Use char because int might match the return type of a GCC
42471    builtin and then its argument prototype would still apply.  */
42472 #ifdef __cplusplus
42473 extern "C"
42474 #endif
42475 char dnet_ntoa ();
42476 int
42477 main ()
42478 {
42479 return dnet_ntoa ();
42480   ;
42481   return 0;
42482 }
42483 _ACEOF
42484 if ac_fn_cxx_try_link "$LINENO"; then :
42485   ac_cv_lib_dnet_dnet_ntoa=yes
42486 else
42487   ac_cv_lib_dnet_dnet_ntoa=no
42488 fi
42489 rm -f core conftest.err conftest.$ac_objext \
42490     conftest$ac_exeext conftest.$ac_ext
42491 LIBS=$ac_check_lib_save_LIBS
42492 fi
42493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
42494 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
42495 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
42496   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
42497 fi
42498 
42499     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
42500       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
42501 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
42502 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
42503   $as_echo_n "(cached) " >&6
42504 else
42505   ac_check_lib_save_LIBS=$LIBS
42506 LIBS="-ldnet_stub  $LIBS"
42507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42508 /* end confdefs.h.  */
42509 
42510 /* Override any GCC internal prototype to avoid an error.
42511    Use char because int might match the return type of a GCC
42512    builtin and then its argument prototype would still apply.  */
42513 #ifdef __cplusplus
42514 extern "C"
42515 #endif
42516 char dnet_ntoa ();
42517 int
42518 main ()
42519 {
42520 return dnet_ntoa ();
42521   ;
42522   return 0;
42523 }
42524 _ACEOF
42525 if ac_fn_cxx_try_link "$LINENO"; then :
42526   ac_cv_lib_dnet_stub_dnet_ntoa=yes
42527 else
42528   ac_cv_lib_dnet_stub_dnet_ntoa=no
42529 fi
42530 rm -f core conftest.err conftest.$ac_objext \
42531     conftest$ac_exeext conftest.$ac_ext
42532 LIBS=$ac_check_lib_save_LIBS
42533 fi
42534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
42535 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
42536 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
42537   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
42538 fi
42539 
42540     fi
42541 fi
42542 rm -f core conftest.err conftest.$ac_objext \
42543     conftest$ac_exeext conftest.$ac_ext
42544     LIBS="$ac_xsave_LIBS"
42545 
42546     # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
42547     # to get the SysV transport functions.
42548     # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
42549     # needs -lnsl.
42550     # The nsl library prevents programs from opening the X display
42551     # on Irix 5.2, according to T.E. Dickey.
42552     # The functions gethostbyname, getservbyname, and inet_addr are
42553     # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
42554     ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
42555 if test "x$ac_cv_func_gethostbyname" = xyes; then :
42556 
42557 fi
42558 
42559     if test $ac_cv_func_gethostbyname = no; then
42560       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
42561 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
42562 if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
42563   $as_echo_n "(cached) " >&6
42564 else
42565   ac_check_lib_save_LIBS=$LIBS
42566 LIBS="-lnsl  $LIBS"
42567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42568 /* end confdefs.h.  */
42569 
42570 /* Override any GCC internal prototype to avoid an error.
42571    Use char because int might match the return type of a GCC
42572    builtin and then its argument prototype would still apply.  */
42573 #ifdef __cplusplus
42574 extern "C"
42575 #endif
42576 char gethostbyname ();
42577 int
42578 main ()
42579 {
42580 return gethostbyname ();
42581   ;
42582   return 0;
42583 }
42584 _ACEOF
42585 if ac_fn_cxx_try_link "$LINENO"; then :
42586   ac_cv_lib_nsl_gethostbyname=yes
42587 else
42588   ac_cv_lib_nsl_gethostbyname=no
42589 fi
42590 rm -f core conftest.err conftest.$ac_objext \
42591     conftest$ac_exeext conftest.$ac_ext
42592 LIBS=$ac_check_lib_save_LIBS
42593 fi
42594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
42595 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
42596 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
42597   X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
42598 fi
42599 
42600       if test $ac_cv_lib_nsl_gethostbyname = no; then
42601         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
42602 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
42603 if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
42604   $as_echo_n "(cached) " >&6
42605 else
42606   ac_check_lib_save_LIBS=$LIBS
42607 LIBS="-lbsd  $LIBS"
42608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42609 /* end confdefs.h.  */
42610 
42611 /* Override any GCC internal prototype to avoid an error.
42612    Use char because int might match the return type of a GCC
42613    builtin and then its argument prototype would still apply.  */
42614 #ifdef __cplusplus
42615 extern "C"
42616 #endif
42617 char gethostbyname ();
42618 int
42619 main ()
42620 {
42621 return gethostbyname ();
42622   ;
42623   return 0;
42624 }
42625 _ACEOF
42626 if ac_fn_cxx_try_link "$LINENO"; then :
42627   ac_cv_lib_bsd_gethostbyname=yes
42628 else
42629   ac_cv_lib_bsd_gethostbyname=no
42630 fi
42631 rm -f core conftest.err conftest.$ac_objext \
42632     conftest$ac_exeext conftest.$ac_ext
42633 LIBS=$ac_check_lib_save_LIBS
42634 fi
42635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
42636 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
42637 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
42638   X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
42639 fi
42640 
42641       fi
42642     fi
42643 
42644     # lieder@skyler.mavd.honeywell.com says without -lsocket,
42645     # socket/setsockopt and other routines are undefined under SCO ODT
42646     # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
42647     # on later versions), says Simon Leinen: it contains gethostby*
42648     # variants that don't use the name server (or something).  -lsocket
42649     # must be given before -lnsl if both are needed.  We assume that
42650     # if connect needs -lnsl, so does gethostbyname.
42651     ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
42652 if test "x$ac_cv_func_connect" = xyes; then :
42653 
42654 fi
42655 
42656     if test $ac_cv_func_connect = no; then
42657       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
42658 $as_echo_n "checking for connect in -lsocket... " >&6; }
42659 if ${ac_cv_lib_socket_connect+:} false; then :
42660   $as_echo_n "(cached) " >&6
42661 else
42662   ac_check_lib_save_LIBS=$LIBS
42663 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
42664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42665 /* end confdefs.h.  */
42666 
42667 /* Override any GCC internal prototype to avoid an error.
42668    Use char because int might match the return type of a GCC
42669    builtin and then its argument prototype would still apply.  */
42670 #ifdef __cplusplus
42671 extern "C"
42672 #endif
42673 char connect ();
42674 int
42675 main ()
42676 {
42677 return connect ();
42678   ;
42679   return 0;
42680 }
42681 _ACEOF
42682 if ac_fn_cxx_try_link "$LINENO"; then :
42683   ac_cv_lib_socket_connect=yes
42684 else
42685   ac_cv_lib_socket_connect=no
42686 fi
42687 rm -f core conftest.err conftest.$ac_objext \
42688     conftest$ac_exeext conftest.$ac_ext
42689 LIBS=$ac_check_lib_save_LIBS
42690 fi
42691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
42692 $as_echo "$ac_cv_lib_socket_connect" >&6; }
42693 if test "x$ac_cv_lib_socket_connect" = xyes; then :
42694   X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
42695 fi
42696 
42697     fi
42698 
42699     # Guillermo Gomez says -lposix is necessary on A/UX.
42700     ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
42701 if test "x$ac_cv_func_remove" = xyes; then :
42702 
42703 fi
42704 
42705     if test $ac_cv_func_remove = no; then
42706       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
42707 $as_echo_n "checking for remove in -lposix... " >&6; }
42708 if ${ac_cv_lib_posix_remove+:} false; then :
42709   $as_echo_n "(cached) " >&6
42710 else
42711   ac_check_lib_save_LIBS=$LIBS
42712 LIBS="-lposix  $LIBS"
42713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42714 /* end confdefs.h.  */
42715 
42716 /* Override any GCC internal prototype to avoid an error.
42717    Use char because int might match the return type of a GCC
42718    builtin and then its argument prototype would still apply.  */
42719 #ifdef __cplusplus
42720 extern "C"
42721 #endif
42722 char remove ();
42723 int
42724 main ()
42725 {
42726 return remove ();
42727   ;
42728   return 0;
42729 }
42730 _ACEOF
42731 if ac_fn_cxx_try_link "$LINENO"; then :
42732   ac_cv_lib_posix_remove=yes
42733 else
42734   ac_cv_lib_posix_remove=no
42735 fi
42736 rm -f core conftest.err conftest.$ac_objext \
42737     conftest$ac_exeext conftest.$ac_ext
42738 LIBS=$ac_check_lib_save_LIBS
42739 fi
42740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
42741 $as_echo "$ac_cv_lib_posix_remove" >&6; }
42742 if test "x$ac_cv_lib_posix_remove" = xyes; then :
42743   X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
42744 fi
42745 
42746     fi
42747 
42748     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
42749     ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
42750 if test "x$ac_cv_func_shmat" = xyes; then :
42751 
42752 fi
42753 
42754     if test $ac_cv_func_shmat = no; then
42755       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
42756 $as_echo_n "checking for shmat in -lipc... " >&6; }
42757 if ${ac_cv_lib_ipc_shmat+:} false; then :
42758   $as_echo_n "(cached) " >&6
42759 else
42760   ac_check_lib_save_LIBS=$LIBS
42761 LIBS="-lipc  $LIBS"
42762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42763 /* end confdefs.h.  */
42764 
42765 /* Override any GCC internal prototype to avoid an error.
42766    Use char because int might match the return type of a GCC
42767    builtin and then its argument prototype would still apply.  */
42768 #ifdef __cplusplus
42769 extern "C"
42770 #endif
42771 char shmat ();
42772 int
42773 main ()
42774 {
42775 return shmat ();
42776   ;
42777   return 0;
42778 }
42779 _ACEOF
42780 if ac_fn_cxx_try_link "$LINENO"; then :
42781   ac_cv_lib_ipc_shmat=yes
42782 else
42783   ac_cv_lib_ipc_shmat=no
42784 fi
42785 rm -f core conftest.err conftest.$ac_objext \
42786     conftest$ac_exeext conftest.$ac_ext
42787 LIBS=$ac_check_lib_save_LIBS
42788 fi
42789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
42790 $as_echo "$ac_cv_lib_ipc_shmat" >&6; }
42791 if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
42792   X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
42793 fi
42794 
42795     fi
42796   fi
42797 
42798   # Check for libraries that X11R6 Xt/Xaw programs need.
42799   ac_save_LDFLAGS=$LDFLAGS
42800   test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
42801   # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
42802   # check for ICE first), but we must link in the order -lSM -lICE or
42803   # we get undefined symbols.  So assume we have SM if we have ICE.
42804   # These have to be linked with before -lX11, unlike the other
42805   # libraries we check for below, so use a different variable.
42806   # John Interrante, Karl Berry
42807   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
42808 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
42809 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
42810   $as_echo_n "(cached) " >&6
42811 else
42812   ac_check_lib_save_LIBS=$LIBS
42813 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
42814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42815 /* end confdefs.h.  */
42816 
42817 /* Override any GCC internal prototype to avoid an error.
42818    Use char because int might match the return type of a GCC
42819    builtin and then its argument prototype would still apply.  */
42820 #ifdef __cplusplus
42821 extern "C"
42822 #endif
42823 char IceConnectionNumber ();
42824 int
42825 main ()
42826 {
42827 return IceConnectionNumber ();
42828   ;
42829   return 0;
42830 }
42831 _ACEOF
42832 if ac_fn_cxx_try_link "$LINENO"; then :
42833   ac_cv_lib_ICE_IceConnectionNumber=yes
42834 else
42835   ac_cv_lib_ICE_IceConnectionNumber=no
42836 fi
42837 rm -f core conftest.err conftest.$ac_objext \
42838     conftest$ac_exeext conftest.$ac_ext
42839 LIBS=$ac_check_lib_save_LIBS
42840 fi
42841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
42842 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
42843 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
42844   X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
42845 fi
42846 
42847   LDFLAGS=$ac_save_LDFLAGS
42848 
42849 fi
42850 
42851 
42852   # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
42853   # this doesn't make sense so we remove it.
42854   if test "x$COMPILE_TYPE" = xcross; then
42855     X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
42856   fi
42857 
42858   if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then
42859 
42860   # Print a helpful message on how to acquire the necessary build dependency.
42861   # x11 is the help tag: freetype, cups, pulse, alsa etc
42862   MISSING_DEPENDENCY=x11
42863 
42864   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42865     cygwin_help $MISSING_DEPENDENCY
42866   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42867     msys_help $MISSING_DEPENDENCY
42868   else
42869     PKGHANDLER_COMMAND=
42870 
42871     case $PKGHANDLER in
42872       apt-get)
42873         apt_help     $MISSING_DEPENDENCY ;;
42874       yum)
42875         yum_help     $MISSING_DEPENDENCY ;;
42876       port)
42877         port_help    $MISSING_DEPENDENCY ;;
42878       pkgutil)
42879         pkgutil_help $MISSING_DEPENDENCY ;;
42880       pkgadd)
42881         pkgadd_help  $MISSING_DEPENDENCY ;;
42882     esac
42883 
42884     if test "x$PKGHANDLER_COMMAND" != x; then
42885       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42886     fi
42887   fi
42888 
42889     as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
42890   fi
42891 
42892   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42893     OPENWIN_HOME="/usr/openwin"
42894   fi
42895 
42896 
42897 
42898   #
42899   # Weird Sol10 something check...TODO change to try compile
42900   #
42901   if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
42902     if test "`uname -r`" = "5.10"; then
42903       if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
42904         X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
42905       fi
42906     fi
42907   fi
42908 
42909   ac_ext=c
42910 ac_cpp='$CPP $CPPFLAGS'
42911 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42912 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42913 ac_compiler_gnu=$ac_cv_c_compiler_gnu
42914 
42915   OLD_CFLAGS="$CFLAGS"
42916   CFLAGS="$CFLAGS $X_CFLAGS"
42917 
42918   # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
42919   for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
42920 do :
42921   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
42922 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
42923         # include <X11/Xlib.h>
42924         # include <X11/Xutil.h>
42925 
42926 
42927 "
42928 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
42929   cat >>confdefs.h <<_ACEOF
42930 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
42931 _ACEOF
42932  X11_A_OK=yes
42933 else
42934   X11_A_OK=no; break
42935 fi
42936 
42937 done
42938 
42939 
42940   CFLAGS="$OLD_CFLAGS"
42941   ac_ext=cpp
42942 ac_cpp='$CXXCPP $CPPFLAGS'
42943 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42944 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42945 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42946 
42947 
42948   if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then
42949 
42950   # Print a helpful message on how to acquire the necessary build dependency.
42951   # x11 is the help tag: freetype, cups, pulse, alsa etc
42952   MISSING_DEPENDENCY=x11
42953 
42954   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42955     cygwin_help $MISSING_DEPENDENCY
42956   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42957     msys_help $MISSING_DEPENDENCY
42958   else
42959     PKGHANDLER_COMMAND=
42960 
42961     case $PKGHANDLER in
42962       apt-get)
42963         apt_help     $MISSING_DEPENDENCY ;;
42964       yum)
42965         yum_help     $MISSING_DEPENDENCY ;;
42966       port)
42967         port_help    $MISSING_DEPENDENCY ;;
42968       pkgutil)
42969         pkgutil_help $MISSING_DEPENDENCY ;;
42970       pkgadd)
42971         pkgadd_help  $MISSING_DEPENDENCY ;;
42972     esac
42973 
42974     if test "x$PKGHANDLER_COMMAND" != x; then
42975       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42976     fi
42977   fi
42978 
42979     as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
42980   fi
42981 
42982 
42983 
42984 
42985 
42986 
42987   ###############################################################################
42988   #
42989   # The common unix printing system cups is used to print from java.
42990   #
42991 
42992 # Check whether --with-cups was given.
42993 if test "${with_cups+set}" = set; then :
42994   withval=$with_cups;
42995 fi
42996 
42997 
42998 # Check whether --with-cups-include was given.
42999 if test "${with_cups_include+set}" = set; then :
43000   withval=$with_cups_include;
43001 fi
43002 
43003 
43004   if test "x$CUPS_NOT_NEEDED" = xyes; then
43005     if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
43006       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
43007 $as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
43008     fi
43009     CUPS_CFLAGS=
43010   else
43011     CUPS_FOUND=no
43012 
43013     if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
43014       as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
43015     fi
43016 
43017     if test "x${with_cups}" != x; then
43018       CUPS_CFLAGS="-I${with_cups}/include"
43019       CUPS_FOUND=yes
43020     fi
43021     if test "x${with_cups_include}" != x; then
43022       CUPS_CFLAGS="-I${with_cups_include}"
43023       CUPS_FOUND=yes
43024     fi
43025     if test "x$CUPS_FOUND" = xno; then
43026 
43027 
43028   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43029     # Source the builddeps file again, to make sure it uses the latest variables!
43030     . $builddepsfile
43031     # Look for a target and build machine specific resource!
43032     eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43033     if test "x$resource" = x; then
43034       # Ok, lets instead look for a target specific resource
43035       eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
43036     fi
43037     if test "x$resource" = x; then
43038       # Ok, lets instead look for a build specific resource
43039       eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
43040     fi
43041     if test "x$resource" = x; then
43042       # Ok, lets instead look for a generic resource
43043       # (The cups comes from M4 and not the shell, thus no need for eval here.)
43044       resource=${builddep_cups}
43045     fi
43046     if test "x$resource" != x; then
43047       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
43048 $as_echo "$as_me: Using builddeps $resource for cups" >&6;}
43049       # If the resource in the builddeps.conf file is an existing directory,
43050       # for example /java/linux/cups
43051       if test -d ${resource}; then
43052         depdir=${resource}
43053       else
43054 
43055   # cups is for example mymodule
43056   # $resource is for example libs/general/libmymod_1_2_3.zip
43057   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43058   # $with_builddeps_dir is for example /localhome/builddeps
43059   # depdir is the name of the variable into which we store the depdir, eg MYMOD
43060   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43061   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43062   filename=`basename $resource`
43063   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43064   filebase=${filename%%.*}
43065   extension=${filename#*.}
43066   installdir=$with_builddeps_dir/$filebase
43067   if test ! -f $installdir/$filename.unpacked; then
43068     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
43069 $as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43070     if test ! -d $installdir; then
43071       mkdir -p $installdir
43072     fi
43073     if test ! -d $installdir; then
43074       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43075     fi
43076     tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
43077     touch $tmpfile
43078     if test ! -f $tmpfile; then
43079       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43080     fi
43081 
43082   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43083   # $tmpfile is the local file name for the downloaded file.
43084   VALID_TOOL=no
43085   if test "x$BDEPS_FTP" = xwget; then
43086     VALID_TOOL=yes
43087     wget -O $tmpfile $with_builddeps_server/$resource
43088   fi
43089   if test "x$BDEPS_FTP" = xlftp; then
43090     VALID_TOOL=yes
43091     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43092   fi
43093   if test "x$BDEPS_FTP" = xftp; then
43094     VALID_TOOL=yes
43095     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43096     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43097     FTPUSERPWD=${FTPSERVER%%@*}
43098     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43099       FTPUSER=${userpwd%%:*}
43100       FTPPWD=${userpwd#*@}
43101       FTPSERVER=${FTPSERVER#*@}
43102     else
43103       FTPUSER=ftp
43104       FTPPWD=ftp
43105     fi
43106     # the "pass" command does not work on some
43107     # ftp clients (read ftp.exe) but if it works,
43108     # passive mode is better!
43109     ( \
43110         echo "user $FTPUSER $FTPPWD"        ; \
43111         echo "pass"                         ; \
43112         echo "bin"                          ; \
43113         echo "get $FTPPATH $tmpfile"              ; \
43114     ) | ftp -in $FTPSERVER
43115   fi
43116   if test "x$VALID_TOOL" != xyes; then
43117     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43118   fi
43119 
43120     mv $tmpfile $installdir/$filename
43121     if test ! -s $installdir/$filename; then
43122       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43123     fi
43124     case "$extension" in
43125       zip)  echo "Unzipping $installdir/$filename..."
43126         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43127         ;;
43128       tar.gz) echo "Untaring $installdir/$filename..."
43129         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43130         ;;
43131       tgz) echo "Untaring $installdir/$filename..."
43132         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43133         ;;
43134       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43135         ;;
43136     esac
43137   fi
43138   if test -f $installdir/$filename.unpacked; then
43139     depdir=$installdir
43140   fi
43141 
43142       fi
43143       # Source the builddeps file again, because in the previous command, the depdir
43144       # was updated to point at the current build dependency install directory.
43145       . $builddepsfile
43146       # Now extract variables from the builddeps.conf files.
43147       theroot=${builddep_cups_ROOT}
43148       thecflags=${builddep_cups_CFLAGS}
43149       thelibs=${builddep_cups_LIBS}
43150       if test "x$depdir" = x; then
43151         as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
43152       fi
43153       CUPS=$depdir
43154       if test "x$theroot" != x; then
43155         CUPS="$theroot"
43156       fi
43157       if test "x$thecflags" != x; then
43158         CUPS_CFLAGS="$thecflags"
43159       fi
43160       if test "x$thelibs" != x; then
43161         CUPS_LIBS="$thelibs"
43162       fi
43163       CUPS_FOUND=yes
43164 
43165     fi
43166 
43167   fi
43168 
43169     fi
43170     if test "x$CUPS_FOUND" = xno; then
43171       # Are the cups headers installed in the default /usr/include location?
43172       for ac_header in cups/cups.h cups/ppd.h
43173 do :
43174   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43175 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
43176 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43177   cat >>confdefs.h <<_ACEOF
43178 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43179 _ACEOF
43180 
43181             CUPS_FOUND=yes
43182             CUPS_CFLAGS=
43183             DEFAULT_CUPS=yes
43184 
43185 
43186 fi
43187 
43188 done
43189 
43190     fi
43191     if test "x$CUPS_FOUND" = xno; then
43192       # Getting nervous now? Lets poke around for standard Solaris third-party
43193       # package installation locations.
43194       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43195 $as_echo_n "checking for cups headers... " >&6; }
43196       if test -s /opt/sfw/cups/include/cups/cups.h; then
43197         # An SFW package seems to be installed!
43198         CUPS_FOUND=yes
43199         CUPS_CFLAGS="-I/opt/sfw/cups/include"
43200       elif test -s /opt/csw/include/cups/cups.h; then
43201         # A CSW package seems to be installed!
43202         CUPS_FOUND=yes
43203         CUPS_CFLAGS="-I/opt/csw/include"
43204       fi
43205       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43206 $as_echo "$CUPS_FOUND" >&6; }
43207     fi
43208     if test "x$CUPS_FOUND" = xno; then
43209 
43210   # Print a helpful message on how to acquire the necessary build dependency.
43211   # cups is the help tag: freetype, cups, pulse, alsa etc
43212   MISSING_DEPENDENCY=cups
43213 
43214   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43215     cygwin_help $MISSING_DEPENDENCY
43216   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43217     msys_help $MISSING_DEPENDENCY
43218   else
43219     PKGHANDLER_COMMAND=
43220 
43221     case $PKGHANDLER in
43222       apt-get)
43223         apt_help     $MISSING_DEPENDENCY ;;
43224       yum)
43225         yum_help     $MISSING_DEPENDENCY ;;
43226       port)
43227         port_help    $MISSING_DEPENDENCY ;;
43228       pkgutil)
43229         pkgutil_help $MISSING_DEPENDENCY ;;
43230       pkgadd)
43231         pkgadd_help  $MISSING_DEPENDENCY ;;
43232     esac
43233 
43234     if test "x$PKGHANDLER_COMMAND" != x; then
43235       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43236     fi
43237   fi
43238 
43239       as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
43240     fi
43241   fi
43242 
43243 
43244 
43245 
43246 
43247 
43248   ###############################################################################
43249   #
43250   # The ubiquitous freetype library is used to render fonts.
43251   #
43252 
43253 # Check whether --with-freetype was given.
43254 if test "${with_freetype+set}" = set; then :
43255   withval=$with_freetype;
43256 fi
43257 
43258 
43259 # Check whether --with-freetype-include was given.
43260 if test "${with_freetype_include+set}" = set; then :
43261   withval=$with_freetype_include;
43262 fi
43263 
43264 
43265 # Check whether --with-freetype-lib was given.
43266 if test "${with_freetype_lib+set}" = set; then :
43267   withval=$with_freetype_lib;
43268 fi
43269 
43270   # Check whether --enable-freetype-bundling was given.
43271 if test "${enable_freetype_bundling+set}" = set; then :
43272   enableval=$enable_freetype_bundling;
43273 fi
43274 
43275 
43276   FREETYPE_CFLAGS=
43277   FREETYPE_LIBS=
43278   FREETYPE_BUNDLE_LIB_PATH=
43279 
43280   if test "x$FREETYPE_NOT_NEEDED" = xyes; then
43281     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43282       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
43283 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
43284     fi
43285     if test "x$enable_freetype_bundling" != x; then
43286       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
43287 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
43288     fi
43289   else
43290     # freetype is needed to build; go get it!
43291 
43292     BUNDLE_FREETYPE="$enable_freetype_bundling"
43293 
43294     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43295       # User has specified settings
43296 
43297       if test "x$BUNDLE_FREETYPE" = x; then
43298         # If not specified, default is to bundle freetype
43299         BUNDLE_FREETYPE=yes
43300       fi
43301 
43302       if test "x$with_freetype" != x; then
43303         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
43304         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
43305       fi
43306 
43307       # Allow --with-freetype-lib and --with-freetype-include to override
43308       if test "x$with_freetype_include" != x; then
43309         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
43310       fi
43311       if test "x$with_freetype_lib" != x; then
43312         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
43313       fi
43314 
43315       if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
43316         # Okay, we got it. Check that it works.
43317 
43318   POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43319   POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43320   METHOD="--with-freetype"
43321 
43322   # First check if the files exists.
43323   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43324     # We found an arbitrary include file. That's a good sign.
43325     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43326 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43327     FOUND_FREETYPE=yes
43328 
43329     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43330     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43331       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43332 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43333       FOUND_FREETYPE=no
43334     else
43335       if test "x$OPENJDK_TARGET_OS" = xwindows; then
43336         # On Windows, we will need both .lib and .dll file.
43337         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43338           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43339 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43340           FOUND_FREETYPE=no
43341         fi
43342       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
43343         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43344         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43345       fi
43346     fi
43347   fi
43348 
43349   if test "x$FOUND_FREETYPE" = xyes; then
43350 
43351   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43352 
43353   # Input might be given as Windows format, start by converting to
43354   # unix format.
43355   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43356   new_path=`$CYGPATH -u "$path"`
43357 
43358   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43359   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43360   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43361   # "foo.exe" is OK but "foo" is an error.
43362   #
43363   # This test is therefore slightly more accurate than "test -f" to check for file precense.
43364   # It is also a way to make sure we got the proper file name for the real test later on.
43365   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43366   if test "x$test_shortpath" = x; then
43367     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43368 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43369     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43370   fi
43371 
43372   # Call helper function which possibly converts this using DOS-style short mode.
43373   # If so, the updated path is stored in $new_path.
43374 
43375   input_path="$new_path"
43376   # Check if we need to convert this using DOS-style short mode. If the path
43377   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43378   # take no chances and rewrite it.
43379   # Note: m4 eats our [], so we need to use [ and ] instead.
43380   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43381   if test "x$has_forbidden_chars" != x; then
43382     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43383     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43384     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43385     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43386       # Going to short mode and back again did indeed matter. Since short mode is
43387       # case insensitive, let's make it lowercase to improve readability.
43388       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43389       # Now convert it back to Unix-stile (cygpath)
43390       input_path=`$CYGPATH -u "$shortmode_path"`
43391       new_path="$input_path"
43392     fi
43393   fi
43394 
43395   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43396   if test "x$test_cygdrive_prefix" = x; then
43397     # As a simple fix, exclude /usr/bin since it's not a real path.
43398     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43399       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43400       # a path prefixed by /cygdrive for fixpath to work.
43401       new_path="$CYGWIN_ROOT_PATH$input_path"
43402     fi
43403   fi
43404 
43405 
43406   if test "x$path" != "x$new_path"; then
43407     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43408     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43409 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43410   fi
43411 
43412   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43413 
43414   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43415   has_colon=`$ECHO $path | $GREP ^.:`
43416   new_path="$path"
43417   if test "x$has_colon" = x; then
43418     # Not in mixed or Windows style, start by that.
43419     new_path=`cmd //c echo $path`
43420   fi
43421 
43422 
43423   input_path="$new_path"
43424   # Check if we need to convert this using DOS-style short mode. If the path
43425   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43426   # take no chances and rewrite it.
43427   # Note: m4 eats our [], so we need to use [ and ] instead.
43428   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43429   if test "x$has_forbidden_chars" != x; then
43430     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43431     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43432   fi
43433 
43434 
43435   windows_path="$new_path"
43436   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43437     unix_path=`$CYGPATH -u "$windows_path"`
43438     new_path="$unix_path"
43439   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43440     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43441     new_path="$unix_path"
43442   fi
43443 
43444   if test "x$path" != "x$new_path"; then
43445     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43446     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43447 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43448   fi
43449 
43450   # Save the first 10 bytes of this path to the storage, so fixpath can work.
43451   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43452 
43453   else
43454     # We're on a posix platform. Hooray! :)
43455     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43456     has_space=`$ECHO "$path" | $GREP " "`
43457     if test "x$has_space" != x; then
43458       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43459 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43460       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43461     fi
43462 
43463     # Use eval to expand a potential ~
43464     eval path="$path"
43465     if test ! -f "$path" && test ! -d "$path"; then
43466       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43467     fi
43468 
43469     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43470   fi
43471 
43472 
43473   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43474 
43475   # Input might be given as Windows format, start by converting to
43476   # unix format.
43477   path="$POTENTIAL_FREETYPE_LIB_PATH"
43478   new_path=`$CYGPATH -u "$path"`
43479 
43480   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43481   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43482   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43483   # "foo.exe" is OK but "foo" is an error.
43484   #
43485   # This test is therefore slightly more accurate than "test -f" to check for file precense.
43486   # It is also a way to make sure we got the proper file name for the real test later on.
43487   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43488   if test "x$test_shortpath" = x; then
43489     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43490 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43491     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
43492   fi
43493 
43494   # Call helper function which possibly converts this using DOS-style short mode.
43495   # If so, the updated path is stored in $new_path.
43496 
43497   input_path="$new_path"
43498   # Check if we need to convert this using DOS-style short mode. If the path
43499   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43500   # take no chances and rewrite it.
43501   # Note: m4 eats our [], so we need to use [ and ] instead.
43502   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43503   if test "x$has_forbidden_chars" != x; then
43504     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43505     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43506     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43507     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43508       # Going to short mode and back again did indeed matter. Since short mode is
43509       # case insensitive, let's make it lowercase to improve readability.
43510       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43511       # Now convert it back to Unix-stile (cygpath)
43512       input_path=`$CYGPATH -u "$shortmode_path"`
43513       new_path="$input_path"
43514     fi
43515   fi
43516 
43517   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43518   if test "x$test_cygdrive_prefix" = x; then
43519     # As a simple fix, exclude /usr/bin since it's not a real path.
43520     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43521       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43522       # a path prefixed by /cygdrive for fixpath to work.
43523       new_path="$CYGWIN_ROOT_PATH$input_path"
43524     fi
43525   fi
43526 
43527 
43528   if test "x$path" != "x$new_path"; then
43529     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43530     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43531 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43532   fi
43533 
43534   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43535 
43536   path="$POTENTIAL_FREETYPE_LIB_PATH"
43537   has_colon=`$ECHO $path | $GREP ^.:`
43538   new_path="$path"
43539   if test "x$has_colon" = x; then
43540     # Not in mixed or Windows style, start by that.
43541     new_path=`cmd //c echo $path`
43542   fi
43543 
43544 
43545   input_path="$new_path"
43546   # Check if we need to convert this using DOS-style short mode. If the path
43547   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43548   # take no chances and rewrite it.
43549   # Note: m4 eats our [], so we need to use [ and ] instead.
43550   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43551   if test "x$has_forbidden_chars" != x; then
43552     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43553     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43554   fi
43555 
43556 
43557   windows_path="$new_path"
43558   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43559     unix_path=`$CYGPATH -u "$windows_path"`
43560     new_path="$unix_path"
43561   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43562     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43563     new_path="$unix_path"
43564   fi
43565 
43566   if test "x$path" != "x$new_path"; then
43567     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43568     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43569 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43570   fi
43571 
43572   # Save the first 10 bytes of this path to the storage, so fixpath can work.
43573   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43574 
43575   else
43576     # We're on a posix platform. Hooray! :)
43577     path="$POTENTIAL_FREETYPE_LIB_PATH"
43578     has_space=`$ECHO "$path" | $GREP " "`
43579     if test "x$has_space" != x; then
43580       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43581 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43582       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43583     fi
43584 
43585     # Use eval to expand a potential ~
43586     eval path="$path"
43587     if test ! -f "$path" && test ! -d "$path"; then
43588       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43589     fi
43590 
43591     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
43592   fi
43593 
43594 
43595     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43596     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
43597 $as_echo_n "checking for freetype includes... " >&6; }
43598     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
43599 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
43600     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43601     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
43602 $as_echo_n "checking for freetype libraries... " >&6; }
43603     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
43604 $as_echo "$FREETYPE_LIB_PATH" >&6; }
43605   fi
43606 
43607         if test "x$FOUND_FREETYPE" != xyes; then
43608           as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
43609         fi
43610       else
43611         # User specified only one of lib or include. This is an error.
43612         if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
43613           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
43614 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
43615           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43616         else
43617           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
43618 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
43619           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43620         fi
43621       fi
43622     else
43623       # User did not specify settings, but we need freetype. Try to locate it.
43624 
43625       if test "x$BUNDLE_FREETYPE" = x; then
43626         # If not specified, default is to bundle freetype only on windows
43627         if test "x$OPENJDK_TARGET_OS" = xwindows; then
43628           BUNDLE_FREETYPE=yes
43629         else
43630           BUNDLE_FREETYPE=no
43631         fi
43632       fi
43633 
43634       if test "x$FOUND_FREETYPE" != xyes; then
43635         # Check builddeps
43636 
43637 
43638   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43639     # Source the builddeps file again, to make sure it uses the latest variables!
43640     . $builddepsfile
43641     # Look for a target and build machine specific resource!
43642     eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43643     if test "x$resource" = x; then
43644       # Ok, lets instead look for a target specific resource
43645       eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
43646     fi
43647     if test "x$resource" = x; then
43648       # Ok, lets instead look for a build specific resource
43649       eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
43650     fi
43651     if test "x$resource" = x; then
43652       # Ok, lets instead look for a generic resource
43653       # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
43654       resource=${builddep_freetype2}
43655     fi
43656     if test "x$resource" != x; then
43657       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
43658 $as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
43659       # If the resource in the builddeps.conf file is an existing directory,
43660       # for example /java/linux/cups
43661       if test -d ${resource}; then
43662         depdir=${resource}
43663       else
43664 
43665   # freetype2 is for example mymodule
43666   # $resource is for example libs/general/libmymod_1_2_3.zip
43667   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43668   # $with_builddeps_dir is for example /localhome/builddeps
43669   # depdir is the name of the variable into which we store the depdir, eg MYMOD
43670   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43671   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43672   filename=`basename $resource`
43673   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43674   filebase=${filename%%.*}
43675   extension=${filename#*.}
43676   installdir=$with_builddeps_dir/$filebase
43677   if test ! -f $installdir/$filename.unpacked; then
43678     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
43679 $as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43680     if test ! -d $installdir; then
43681       mkdir -p $installdir
43682     fi
43683     if test ! -d $installdir; then
43684       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43685     fi
43686     tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
43687     touch $tmpfile
43688     if test ! -f $tmpfile; then
43689       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43690     fi
43691 
43692   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43693   # $tmpfile is the local file name for the downloaded file.
43694   VALID_TOOL=no
43695   if test "x$BDEPS_FTP" = xwget; then
43696     VALID_TOOL=yes
43697     wget -O $tmpfile $with_builddeps_server/$resource
43698   fi
43699   if test "x$BDEPS_FTP" = xlftp; then
43700     VALID_TOOL=yes
43701     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43702   fi
43703   if test "x$BDEPS_FTP" = xftp; then
43704     VALID_TOOL=yes
43705     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43706     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43707     FTPUSERPWD=${FTPSERVER%%@*}
43708     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43709       FTPUSER=${userpwd%%:*}
43710       FTPPWD=${userpwd#*@}
43711       FTPSERVER=${FTPSERVER#*@}
43712     else
43713       FTPUSER=ftp
43714       FTPPWD=ftp
43715     fi
43716     # the "pass" command does not work on some
43717     # ftp clients (read ftp.exe) but if it works,
43718     # passive mode is better!
43719     ( \
43720         echo "user $FTPUSER $FTPPWD"        ; \
43721         echo "pass"                         ; \
43722         echo "bin"                          ; \
43723         echo "get $FTPPATH $tmpfile"              ; \
43724     ) | ftp -in $FTPSERVER
43725   fi
43726   if test "x$VALID_TOOL" != xyes; then
43727     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43728   fi
43729 
43730     mv $tmpfile $installdir/$filename
43731     if test ! -s $installdir/$filename; then
43732       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43733     fi
43734     case "$extension" in
43735       zip)  echo "Unzipping $installdir/$filename..."
43736         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43737         ;;
43738       tar.gz) echo "Untaring $installdir/$filename..."
43739         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43740         ;;
43741       tgz) echo "Untaring $installdir/$filename..."
43742         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43743         ;;
43744       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43745         ;;
43746     esac
43747   fi
43748   if test -f $installdir/$filename.unpacked; then
43749     depdir=$installdir
43750   fi
43751 
43752       fi
43753       # Source the builddeps file again, because in the previous command, the depdir
43754       # was updated to point at the current build dependency install directory.
43755       . $builddepsfile
43756       # Now extract variables from the builddeps.conf files.
43757       theroot=${builddep_freetype2_ROOT}
43758       thecflags=${builddep_freetype2_CFLAGS}
43759       thelibs=${builddep_freetype2_LIBS}
43760       if test "x$depdir" = x; then
43761         as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
43762       fi
43763       FREETYPE=$depdir
43764       if test "x$theroot" != x; then
43765         FREETYPE="$theroot"
43766       fi
43767       if test "x$thecflags" != x; then
43768         FREETYPE_CFLAGS="$thecflags"
43769       fi
43770       if test "x$thelibs" != x; then
43771         FREETYPE_LIBS="$thelibs"
43772       fi
43773       FOUND_FREETYPE=yes
43774       else FOUND_FREETYPE=no
43775 
43776     fi
43777     else FOUND_FREETYPE=no
43778 
43779   fi
43780 
43781         # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43782         if test "x$FOUND_FREETYPE" = xyes; then
43783           if test "x$BUNDLE_FREETYPE" = xyes; then
43784             { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43785 $as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43786             FOUND_FREETYPE=no
43787           else
43788             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43789 $as_echo_n "checking for freetype... " >&6; }
43790             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43791 $as_echo "yes (using builddeps)" >&6; }
43792           fi
43793         fi
43794       fi
43795 
43796       if test "x$FOUND_FREETYPE" != xyes; then
43797         # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43798         if test "x$PKG_CONFIG" != x; then
43799 
43800 pkg_failed=no
43801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43802 $as_echo_n "checking for FREETYPE... " >&6; }
43803 
43804 if test -n "$FREETYPE_CFLAGS"; then
43805     pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43806  elif test -n "$PKG_CONFIG"; then
43807     if test -n "$PKG_CONFIG" && \
43808     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43809   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43810   ac_status=$?
43811   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43812   test $ac_status = 0; }; then
43813   pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43814 else
43815   pkg_failed=yes
43816 fi
43817  else
43818     pkg_failed=untried
43819 fi
43820 if test -n "$FREETYPE_LIBS"; then
43821     pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
43822  elif test -n "$PKG_CONFIG"; then
43823     if test -n "$PKG_CONFIG" && \
43824     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43825   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43826   ac_status=$?
43827   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43828   test $ac_status = 0; }; then
43829   pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
43830 else
43831   pkg_failed=yes
43832 fi
43833  else
43834     pkg_failed=untried
43835 fi
43836 
43837 
43838 
43839 if test $pkg_failed = yes; then
43840 
43841 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
43842         _pkg_short_errors_supported=yes
43843 else
43844         _pkg_short_errors_supported=no
43845 fi
43846         if test $_pkg_short_errors_supported = yes; then
43847                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
43848         else
43849                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
43850         fi
43851         # Put the nasty error message in config.log where it belongs
43852         echo "$FREETYPE_PKG_ERRORS" >&5
43853 
43854         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43855 $as_echo "no" >&6; }
43856                 FOUND_FREETYPE=no
43857 elif test $pkg_failed = untried; then
43858         FOUND_FREETYPE=no
43859 else
43860         FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
43861         FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
43862         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43863 $as_echo "yes" >&6; }
43864         FOUND_FREETYPE=yes
43865 fi
43866           if test "x$FOUND_FREETYPE" = xyes; then
43867             # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
43868             FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
43869             # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
43870             if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
43871               FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
43872             fi
43873             # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43874             if test "x$BUNDLE_FREETYPE" = xyes; then
43875               { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
43876 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
43877               FOUND_FREETYPE=no
43878             else
43879               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43880 $as_echo_n "checking for freetype... " >&6; }
43881               { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
43882 $as_echo "yes (using pkg-config)" >&6; }
43883             fi
43884           fi
43885         fi
43886       fi
43887 
43888       if test "x$FOUND_FREETYPE" != xyes; then
43889         # Check in well-known locations
43890         if test "x$OPENJDK_TARGET_OS" = xwindows; then
43891           FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
43892 
43893   windows_path="$FREETYPE_BASE_DIR"
43894   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43895     unix_path=`$CYGPATH -u "$windows_path"`
43896     FREETYPE_BASE_DIR="$unix_path"
43897   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43898     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43899     FREETYPE_BASE_DIR="$unix_path"
43900   fi
43901 
43902 
43903   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
43904   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
43905   METHOD="well-known location"
43906 
43907   # First check if the files exists.
43908   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43909     # We found an arbitrary include file. That's a good sign.
43910     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43911 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43912     FOUND_FREETYPE=yes
43913 
43914     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43915     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43916       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43917 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43918       FOUND_FREETYPE=no
43919     else
43920       if test "x$OPENJDK_TARGET_OS" = xwindows; then
43921         # On Windows, we will need both .lib and .dll file.
43922         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43923           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43924 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43925           FOUND_FREETYPE=no
43926         fi
43927       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
43928         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43929         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43930       fi
43931     fi
43932   fi
43933 
43934   if test "x$FOUND_FREETYPE" = xyes; then
43935 
43936   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43937 
43938   # Input might be given as Windows format, start by converting to
43939   # unix format.
43940   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43941   new_path=`$CYGPATH -u "$path"`
43942 
43943   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43944   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43945   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43946   # "foo.exe" is OK but "foo" is an error.
43947   #
43948   # This test is therefore slightly more accurate than "test -f" to check for file precense.
43949   # It is also a way to make sure we got the proper file name for the real test later on.
43950   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43951   if test "x$test_shortpath" = x; then
43952     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43953 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43954     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43955   fi
43956 
43957   # Call helper function which possibly converts this using DOS-style short mode.
43958   # If so, the updated path is stored in $new_path.
43959 
43960   input_path="$new_path"
43961   # Check if we need to convert this using DOS-style short mode. If the path
43962   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43963   # take no chances and rewrite it.
43964   # Note: m4 eats our [], so we need to use [ and ] instead.
43965   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43966   if test "x$has_forbidden_chars" != x; then
43967     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43968     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43969     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43970     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43971       # Going to short mode and back again did indeed matter. Since short mode is
43972       # case insensitive, let's make it lowercase to improve readability.
43973       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43974       # Now convert it back to Unix-stile (cygpath)
43975       input_path=`$CYGPATH -u "$shortmode_path"`
43976       new_path="$input_path"
43977     fi
43978   fi
43979 
43980   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43981   if test "x$test_cygdrive_prefix" = x; then
43982     # As a simple fix, exclude /usr/bin since it's not a real path.
43983     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43984       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43985       # a path prefixed by /cygdrive for fixpath to work.
43986       new_path="$CYGWIN_ROOT_PATH$input_path"
43987     fi
43988   fi
43989 
43990 
43991   if test "x$path" != "x$new_path"; then
43992     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43993     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43994 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43995   fi
43996 
43997   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43998 
43999   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44000   has_colon=`$ECHO $path | $GREP ^.:`
44001   new_path="$path"
44002   if test "x$has_colon" = x; then
44003     # Not in mixed or Windows style, start by that.
44004     new_path=`cmd //c echo $path`
44005   fi
44006 
44007 
44008   input_path="$new_path"
44009   # Check if we need to convert this using DOS-style short mode. If the path
44010   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44011   # take no chances and rewrite it.
44012   # Note: m4 eats our [], so we need to use [ and ] instead.
44013   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44014   if test "x$has_forbidden_chars" != x; then
44015     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44016     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44017   fi
44018 
44019 
44020   windows_path="$new_path"
44021   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44022     unix_path=`$CYGPATH -u "$windows_path"`
44023     new_path="$unix_path"
44024   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44025     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44026     new_path="$unix_path"
44027   fi
44028 
44029   if test "x$path" != "x$new_path"; then
44030     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44031     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44032 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44033   fi
44034 
44035   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44036   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44037 
44038   else
44039     # We're on a posix platform. Hooray! :)
44040     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44041     has_space=`$ECHO "$path" | $GREP " "`
44042     if test "x$has_space" != x; then
44043       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44044 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44045       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44046     fi
44047 
44048     # Use eval to expand a potential ~
44049     eval path="$path"
44050     if test ! -f "$path" && test ! -d "$path"; then
44051       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44052     fi
44053 
44054     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44055   fi
44056 
44057 
44058   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44059 
44060   # Input might be given as Windows format, start by converting to
44061   # unix format.
44062   path="$POTENTIAL_FREETYPE_LIB_PATH"
44063   new_path=`$CYGPATH -u "$path"`
44064 
44065   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44066   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44067   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44068   # "foo.exe" is OK but "foo" is an error.
44069   #
44070   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44071   # It is also a way to make sure we got the proper file name for the real test later on.
44072   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44073   if test "x$test_shortpath" = x; then
44074     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44075 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44076     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44077   fi
44078 
44079   # Call helper function which possibly converts this using DOS-style short mode.
44080   # If so, the updated path is stored in $new_path.
44081 
44082   input_path="$new_path"
44083   # Check if we need to convert this using DOS-style short mode. If the path
44084   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44085   # take no chances and rewrite it.
44086   # Note: m4 eats our [], so we need to use [ and ] instead.
44087   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44088   if test "x$has_forbidden_chars" != x; then
44089     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44090     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44091     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44092     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44093       # Going to short mode and back again did indeed matter. Since short mode is
44094       # case insensitive, let's make it lowercase to improve readability.
44095       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44096       # Now convert it back to Unix-stile (cygpath)
44097       input_path=`$CYGPATH -u "$shortmode_path"`
44098       new_path="$input_path"
44099     fi
44100   fi
44101 
44102   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44103   if test "x$test_cygdrive_prefix" = x; then
44104     # As a simple fix, exclude /usr/bin since it's not a real path.
44105     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44106       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44107       # a path prefixed by /cygdrive for fixpath to work.
44108       new_path="$CYGWIN_ROOT_PATH$input_path"
44109     fi
44110   fi
44111 
44112 
44113   if test "x$path" != "x$new_path"; then
44114     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44115     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44116 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44117   fi
44118 
44119   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44120 
44121   path="$POTENTIAL_FREETYPE_LIB_PATH"
44122   has_colon=`$ECHO $path | $GREP ^.:`
44123   new_path="$path"
44124   if test "x$has_colon" = x; then
44125     # Not in mixed or Windows style, start by that.
44126     new_path=`cmd //c echo $path`
44127   fi
44128 
44129 
44130   input_path="$new_path"
44131   # Check if we need to convert this using DOS-style short mode. If the path
44132   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44133   # take no chances and rewrite it.
44134   # Note: m4 eats our [], so we need to use [ and ] instead.
44135   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44136   if test "x$has_forbidden_chars" != x; then
44137     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44138     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44139   fi
44140 
44141 
44142   windows_path="$new_path"
44143   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44144     unix_path=`$CYGPATH -u "$windows_path"`
44145     new_path="$unix_path"
44146   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44147     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44148     new_path="$unix_path"
44149   fi
44150 
44151   if test "x$path" != "x$new_path"; then
44152     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44153     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44154 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44155   fi
44156 
44157   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44158   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44159 
44160   else
44161     # We're on a posix platform. Hooray! :)
44162     path="$POTENTIAL_FREETYPE_LIB_PATH"
44163     has_space=`$ECHO "$path" | $GREP " "`
44164     if test "x$has_space" != x; then
44165       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44166 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44167       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44168     fi
44169 
44170     # Use eval to expand a potential ~
44171     eval path="$path"
44172     if test ! -f "$path" && test ! -d "$path"; then
44173       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44174     fi
44175 
44176     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44177   fi
44178 
44179 
44180     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44181     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44182 $as_echo_n "checking for freetype includes... " >&6; }
44183     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44184 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44185     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44186     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44187 $as_echo_n "checking for freetype libraries... " >&6; }
44188     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44189 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44190   fi
44191 
44192           if test "x$FOUND_FREETYPE" != xyes; then
44193             FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
44194 
44195   windows_path="$FREETYPE_BASE_DIR"
44196   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44197     unix_path=`$CYGPATH -u "$windows_path"`
44198     FREETYPE_BASE_DIR="$unix_path"
44199   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44200     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44201     FREETYPE_BASE_DIR="$unix_path"
44202   fi
44203 
44204 
44205   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44206   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44207   METHOD="well-known location"
44208 
44209   # First check if the files exists.
44210   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44211     # We found an arbitrary include file. That's a good sign.
44212     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44213 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44214     FOUND_FREETYPE=yes
44215 
44216     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44217     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44218       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44219 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44220       FOUND_FREETYPE=no
44221     else
44222       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44223         # On Windows, we will need both .lib and .dll file.
44224         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44225           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44226 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44227           FOUND_FREETYPE=no
44228         fi
44229       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44230         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44231         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44232       fi
44233     fi
44234   fi
44235 
44236   if test "x$FOUND_FREETYPE" = xyes; then
44237 
44238   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44239 
44240   # Input might be given as Windows format, start by converting to
44241   # unix format.
44242   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44243   new_path=`$CYGPATH -u "$path"`
44244 
44245   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44246   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44247   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44248   # "foo.exe" is OK but "foo" is an error.
44249   #
44250   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44251   # It is also a way to make sure we got the proper file name for the real test later on.
44252   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44253   if test "x$test_shortpath" = x; then
44254     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44255 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44256     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44257   fi
44258 
44259   # Call helper function which possibly converts this using DOS-style short mode.
44260   # If so, the updated path is stored in $new_path.
44261 
44262   input_path="$new_path"
44263   # Check if we need to convert this using DOS-style short mode. If the path
44264   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44265   # take no chances and rewrite it.
44266   # Note: m4 eats our [], so we need to use [ and ] instead.
44267   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44268   if test "x$has_forbidden_chars" != x; then
44269     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44270     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44271     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44272     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44273       # Going to short mode and back again did indeed matter. Since short mode is
44274       # case insensitive, let's make it lowercase to improve readability.
44275       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44276       # Now convert it back to Unix-stile (cygpath)
44277       input_path=`$CYGPATH -u "$shortmode_path"`
44278       new_path="$input_path"
44279     fi
44280   fi
44281 
44282   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44283   if test "x$test_cygdrive_prefix" = x; then
44284     # As a simple fix, exclude /usr/bin since it's not a real path.
44285     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44286       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44287       # a path prefixed by /cygdrive for fixpath to work.
44288       new_path="$CYGWIN_ROOT_PATH$input_path"
44289     fi
44290   fi
44291 
44292 
44293   if test "x$path" != "x$new_path"; then
44294     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44295     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44296 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44297   fi
44298 
44299   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44300 
44301   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44302   has_colon=`$ECHO $path | $GREP ^.:`
44303   new_path="$path"
44304   if test "x$has_colon" = x; then
44305     # Not in mixed or Windows style, start by that.
44306     new_path=`cmd //c echo $path`
44307   fi
44308 
44309 
44310   input_path="$new_path"
44311   # Check if we need to convert this using DOS-style short mode. If the path
44312   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44313   # take no chances and rewrite it.
44314   # Note: m4 eats our [], so we need to use [ and ] instead.
44315   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44316   if test "x$has_forbidden_chars" != x; then
44317     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44318     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44319   fi
44320 
44321 
44322   windows_path="$new_path"
44323   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44324     unix_path=`$CYGPATH -u "$windows_path"`
44325     new_path="$unix_path"
44326   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44327     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44328     new_path="$unix_path"
44329   fi
44330 
44331   if test "x$path" != "x$new_path"; then
44332     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44333     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44334 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44335   fi
44336 
44337   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44338   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44339 
44340   else
44341     # We're on a posix platform. Hooray! :)
44342     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44343     has_space=`$ECHO "$path" | $GREP " "`
44344     if test "x$has_space" != x; then
44345       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44346 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44347       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44348     fi
44349 
44350     # Use eval to expand a potential ~
44351     eval path="$path"
44352     if test ! -f "$path" && test ! -d "$path"; then
44353       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44354     fi
44355 
44356     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44357   fi
44358 
44359 
44360   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44361 
44362   # Input might be given as Windows format, start by converting to
44363   # unix format.
44364   path="$POTENTIAL_FREETYPE_LIB_PATH"
44365   new_path=`$CYGPATH -u "$path"`
44366 
44367   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44368   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44369   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44370   # "foo.exe" is OK but "foo" is an error.
44371   #
44372   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44373   # It is also a way to make sure we got the proper file name for the real test later on.
44374   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44375   if test "x$test_shortpath" = x; then
44376     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44377 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44378     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44379   fi
44380 
44381   # Call helper function which possibly converts this using DOS-style short mode.
44382   # If so, the updated path is stored in $new_path.
44383 
44384   input_path="$new_path"
44385   # Check if we need to convert this using DOS-style short mode. If the path
44386   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44387   # take no chances and rewrite it.
44388   # Note: m4 eats our [], so we need to use [ and ] instead.
44389   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44390   if test "x$has_forbidden_chars" != x; then
44391     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44392     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44393     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44394     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44395       # Going to short mode and back again did indeed matter. Since short mode is
44396       # case insensitive, let's make it lowercase to improve readability.
44397       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44398       # Now convert it back to Unix-stile (cygpath)
44399       input_path=`$CYGPATH -u "$shortmode_path"`
44400       new_path="$input_path"
44401     fi
44402   fi
44403 
44404   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44405   if test "x$test_cygdrive_prefix" = x; then
44406     # As a simple fix, exclude /usr/bin since it's not a real path.
44407     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44408       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44409       # a path prefixed by /cygdrive for fixpath to work.
44410       new_path="$CYGWIN_ROOT_PATH$input_path"
44411     fi
44412   fi
44413 
44414 
44415   if test "x$path" != "x$new_path"; then
44416     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44417     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44418 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44419   fi
44420 
44421   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44422 
44423   path="$POTENTIAL_FREETYPE_LIB_PATH"
44424   has_colon=`$ECHO $path | $GREP ^.:`
44425   new_path="$path"
44426   if test "x$has_colon" = x; then
44427     # Not in mixed or Windows style, start by that.
44428     new_path=`cmd //c echo $path`
44429   fi
44430 
44431 
44432   input_path="$new_path"
44433   # Check if we need to convert this using DOS-style short mode. If the path
44434   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44435   # take no chances and rewrite it.
44436   # Note: m4 eats our [], so we need to use [ and ] instead.
44437   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44438   if test "x$has_forbidden_chars" != x; then
44439     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44440     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44441   fi
44442 
44443 
44444   windows_path="$new_path"
44445   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44446     unix_path=`$CYGPATH -u "$windows_path"`
44447     new_path="$unix_path"
44448   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44449     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44450     new_path="$unix_path"
44451   fi
44452 
44453   if test "x$path" != "x$new_path"; then
44454     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44455     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44456 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44457   fi
44458 
44459   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44460   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44461 
44462   else
44463     # We're on a posix platform. Hooray! :)
44464     path="$POTENTIAL_FREETYPE_LIB_PATH"
44465     has_space=`$ECHO "$path" | $GREP " "`
44466     if test "x$has_space" != x; then
44467       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44468 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44469       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44470     fi
44471 
44472     # Use eval to expand a potential ~
44473     eval path="$path"
44474     if test ! -f "$path" && test ! -d "$path"; then
44475       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44476     fi
44477 
44478     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44479   fi
44480 
44481 
44482     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44483     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44484 $as_echo_n "checking for freetype includes... " >&6; }
44485     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44486 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44487     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44488     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44489 $as_echo_n "checking for freetype libraries... " >&6; }
44490     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44491 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44492   fi
44493 
44494           fi
44495         else
44496           if test "x$SYS_ROOT" = "x/"; then
44497             FREETYPE_ROOT=
44498           else
44499             FREETYPE_ROOT="$SYS_ROOT"
44500           fi
44501           FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
44502 
44503   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44504   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44505   METHOD="well-known location"
44506 
44507   # First check if the files exists.
44508   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44509     # We found an arbitrary include file. That's a good sign.
44510     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44511 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44512     FOUND_FREETYPE=yes
44513 
44514     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44515     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44516       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44517 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44518       FOUND_FREETYPE=no
44519     else
44520       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44521         # On Windows, we will need both .lib and .dll file.
44522         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44523           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44524 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44525           FOUND_FREETYPE=no
44526         fi
44527       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44528         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44529         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44530       fi
44531     fi
44532   fi
44533 
44534   if test "x$FOUND_FREETYPE" = xyes; then
44535 
44536   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44537 
44538   # Input might be given as Windows format, start by converting to
44539   # unix format.
44540   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44541   new_path=`$CYGPATH -u "$path"`
44542 
44543   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44544   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44545   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44546   # "foo.exe" is OK but "foo" is an error.
44547   #
44548   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44549   # It is also a way to make sure we got the proper file name for the real test later on.
44550   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44551   if test "x$test_shortpath" = x; then
44552     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44553 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44554     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44555   fi
44556 
44557   # Call helper function which possibly converts this using DOS-style short mode.
44558   # If so, the updated path is stored in $new_path.
44559 
44560   input_path="$new_path"
44561   # Check if we need to convert this using DOS-style short mode. If the path
44562   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44563   # take no chances and rewrite it.
44564   # Note: m4 eats our [], so we need to use [ and ] instead.
44565   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44566   if test "x$has_forbidden_chars" != x; then
44567     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44568     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44569     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44570     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44571       # Going to short mode and back again did indeed matter. Since short mode is
44572       # case insensitive, let's make it lowercase to improve readability.
44573       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44574       # Now convert it back to Unix-stile (cygpath)
44575       input_path=`$CYGPATH -u "$shortmode_path"`
44576       new_path="$input_path"
44577     fi
44578   fi
44579 
44580   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44581   if test "x$test_cygdrive_prefix" = x; then
44582     # As a simple fix, exclude /usr/bin since it's not a real path.
44583     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44584       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44585       # a path prefixed by /cygdrive for fixpath to work.
44586       new_path="$CYGWIN_ROOT_PATH$input_path"
44587     fi
44588   fi
44589 
44590 
44591   if test "x$path" != "x$new_path"; then
44592     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44593     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44594 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44595   fi
44596 
44597   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44598 
44599   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44600   has_colon=`$ECHO $path | $GREP ^.:`
44601   new_path="$path"
44602   if test "x$has_colon" = x; then
44603     # Not in mixed or Windows style, start by that.
44604     new_path=`cmd //c echo $path`
44605   fi
44606 
44607 
44608   input_path="$new_path"
44609   # Check if we need to convert this using DOS-style short mode. If the path
44610   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44611   # take no chances and rewrite it.
44612   # Note: m4 eats our [], so we need to use [ and ] instead.
44613   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44614   if test "x$has_forbidden_chars" != x; then
44615     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44616     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44617   fi
44618 
44619 
44620   windows_path="$new_path"
44621   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44622     unix_path=`$CYGPATH -u "$windows_path"`
44623     new_path="$unix_path"
44624   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44625     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44626     new_path="$unix_path"
44627   fi
44628 
44629   if test "x$path" != "x$new_path"; then
44630     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44631     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44632 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44633   fi
44634 
44635   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44636   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44637 
44638   else
44639     # We're on a posix platform. Hooray! :)
44640     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44641     has_space=`$ECHO "$path" | $GREP " "`
44642     if test "x$has_space" != x; then
44643       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44644 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44645       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44646     fi
44647 
44648     # Use eval to expand a potential ~
44649     eval path="$path"
44650     if test ! -f "$path" && test ! -d "$path"; then
44651       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44652     fi
44653 
44654     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44655   fi
44656 
44657 
44658   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44659 
44660   # Input might be given as Windows format, start by converting to
44661   # unix format.
44662   path="$POTENTIAL_FREETYPE_LIB_PATH"
44663   new_path=`$CYGPATH -u "$path"`
44664 
44665   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44666   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44667   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44668   # "foo.exe" is OK but "foo" is an error.
44669   #
44670   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44671   # It is also a way to make sure we got the proper file name for the real test later on.
44672   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44673   if test "x$test_shortpath" = x; then
44674     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44675 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44676     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44677   fi
44678 
44679   # Call helper function which possibly converts this using DOS-style short mode.
44680   # If so, the updated path is stored in $new_path.
44681 
44682   input_path="$new_path"
44683   # Check if we need to convert this using DOS-style short mode. If the path
44684   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44685   # take no chances and rewrite it.
44686   # Note: m4 eats our [], so we need to use [ and ] instead.
44687   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44688   if test "x$has_forbidden_chars" != x; then
44689     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44690     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44691     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44692     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44693       # Going to short mode and back again did indeed matter. Since short mode is
44694       # case insensitive, let's make it lowercase to improve readability.
44695       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44696       # Now convert it back to Unix-stile (cygpath)
44697       input_path=`$CYGPATH -u "$shortmode_path"`
44698       new_path="$input_path"
44699     fi
44700   fi
44701 
44702   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44703   if test "x$test_cygdrive_prefix" = x; then
44704     # As a simple fix, exclude /usr/bin since it's not a real path.
44705     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44706       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44707       # a path prefixed by /cygdrive for fixpath to work.
44708       new_path="$CYGWIN_ROOT_PATH$input_path"
44709     fi
44710   fi
44711 
44712 
44713   if test "x$path" != "x$new_path"; then
44714     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44715     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44716 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44717   fi
44718 
44719   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44720 
44721   path="$POTENTIAL_FREETYPE_LIB_PATH"
44722   has_colon=`$ECHO $path | $GREP ^.:`
44723   new_path="$path"
44724   if test "x$has_colon" = x; then
44725     # Not in mixed or Windows style, start by that.
44726     new_path=`cmd //c echo $path`
44727   fi
44728 
44729 
44730   input_path="$new_path"
44731   # Check if we need to convert this using DOS-style short mode. If the path
44732   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44733   # take no chances and rewrite it.
44734   # Note: m4 eats our [], so we need to use [ and ] instead.
44735   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44736   if test "x$has_forbidden_chars" != x; then
44737     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44738     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44739   fi
44740 
44741 
44742   windows_path="$new_path"
44743   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44744     unix_path=`$CYGPATH -u "$windows_path"`
44745     new_path="$unix_path"
44746   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44747     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44748     new_path="$unix_path"
44749   fi
44750 
44751   if test "x$path" != "x$new_path"; then
44752     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44753     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44754 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44755   fi
44756 
44757   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44758   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44759 
44760   else
44761     # We're on a posix platform. Hooray! :)
44762     path="$POTENTIAL_FREETYPE_LIB_PATH"
44763     has_space=`$ECHO "$path" | $GREP " "`
44764     if test "x$has_space" != x; then
44765       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44766 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44767       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44768     fi
44769 
44770     # Use eval to expand a potential ~
44771     eval path="$path"
44772     if test ! -f "$path" && test ! -d "$path"; then
44773       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44774     fi
44775 
44776     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44777   fi
44778 
44779 
44780     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44781     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44782 $as_echo_n "checking for freetype includes... " >&6; }
44783     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44784 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44785     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44786     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44787 $as_echo_n "checking for freetype libraries... " >&6; }
44788     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44789 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44790   fi
44791 
44792 
44793           if test "x$FOUND_FREETYPE" != xyes; then
44794             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr/X11"
44795 
44796   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44797   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44798   METHOD="well-known location"
44799 
44800   # First check if the files exists.
44801   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44802     # We found an arbitrary include file. That's a good sign.
44803     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44804 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44805     FOUND_FREETYPE=yes
44806 
44807     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44808     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44809       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44810 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44811       FOUND_FREETYPE=no
44812     else
44813       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44814         # On Windows, we will need both .lib and .dll file.
44815         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44816           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44817 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44818           FOUND_FREETYPE=no
44819         fi
44820       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44821         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44822         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44823       fi
44824     fi
44825   fi
44826 
44827   if test "x$FOUND_FREETYPE" = xyes; then
44828 
44829   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44830 
44831   # Input might be given as Windows format, start by converting to
44832   # unix format.
44833   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44834   new_path=`$CYGPATH -u "$path"`
44835 
44836   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44837   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44838   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44839   # "foo.exe" is OK but "foo" is an error.
44840   #
44841   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44842   # It is also a way to make sure we got the proper file name for the real test later on.
44843   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44844   if test "x$test_shortpath" = x; then
44845     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44846 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44847     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44848   fi
44849 
44850   # Call helper function which possibly converts this using DOS-style short mode.
44851   # If so, the updated path is stored in $new_path.
44852 
44853   input_path="$new_path"
44854   # Check if we need to convert this using DOS-style short mode. If the path
44855   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44856   # take no chances and rewrite it.
44857   # Note: m4 eats our [], so we need to use [ and ] instead.
44858   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44859   if test "x$has_forbidden_chars" != x; then
44860     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44861     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44862     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44863     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44864       # Going to short mode and back again did indeed matter. Since short mode is
44865       # case insensitive, let's make it lowercase to improve readability.
44866       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44867       # Now convert it back to Unix-stile (cygpath)
44868       input_path=`$CYGPATH -u "$shortmode_path"`
44869       new_path="$input_path"
44870     fi
44871   fi
44872 
44873   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44874   if test "x$test_cygdrive_prefix" = x; then
44875     # As a simple fix, exclude /usr/bin since it's not a real path.
44876     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44877       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44878       # a path prefixed by /cygdrive for fixpath to work.
44879       new_path="$CYGWIN_ROOT_PATH$input_path"
44880     fi
44881   fi
44882 
44883 
44884   if test "x$path" != "x$new_path"; then
44885     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44886     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44887 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44888   fi
44889 
44890   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44891 
44892   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44893   has_colon=`$ECHO $path | $GREP ^.:`
44894   new_path="$path"
44895   if test "x$has_colon" = x; then
44896     # Not in mixed or Windows style, start by that.
44897     new_path=`cmd //c echo $path`
44898   fi
44899 
44900 
44901   input_path="$new_path"
44902   # Check if we need to convert this using DOS-style short mode. If the path
44903   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44904   # take no chances and rewrite it.
44905   # Note: m4 eats our [], so we need to use [ and ] instead.
44906   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44907   if test "x$has_forbidden_chars" != x; then
44908     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44909     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44910   fi
44911 
44912 
44913   windows_path="$new_path"
44914   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44915     unix_path=`$CYGPATH -u "$windows_path"`
44916     new_path="$unix_path"
44917   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44918     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44919     new_path="$unix_path"
44920   fi
44921 
44922   if test "x$path" != "x$new_path"; then
44923     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44924     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44925 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44926   fi
44927 
44928   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44929   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44930 
44931   else
44932     # We're on a posix platform. Hooray! :)
44933     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44934     has_space=`$ECHO "$path" | $GREP " "`
44935     if test "x$has_space" != x; then
44936       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44937 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44938       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44939     fi
44940 
44941     # Use eval to expand a potential ~
44942     eval path="$path"
44943     if test ! -f "$path" && test ! -d "$path"; then
44944       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44945     fi
44946 
44947     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44948   fi
44949 
44950 
44951   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44952 
44953   # Input might be given as Windows format, start by converting to
44954   # unix format.
44955   path="$POTENTIAL_FREETYPE_LIB_PATH"
44956   new_path=`$CYGPATH -u "$path"`
44957 
44958   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44959   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44960   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44961   # "foo.exe" is OK but "foo" is an error.
44962   #
44963   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44964   # It is also a way to make sure we got the proper file name for the real test later on.
44965   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44966   if test "x$test_shortpath" = x; then
44967     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44968 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44969     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44970   fi
44971 
44972   # Call helper function which possibly converts this using DOS-style short mode.
44973   # If so, the updated path is stored in $new_path.
44974 
44975   input_path="$new_path"
44976   # Check if we need to convert this using DOS-style short mode. If the path
44977   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44978   # take no chances and rewrite it.
44979   # Note: m4 eats our [], so we need to use [ and ] instead.
44980   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44981   if test "x$has_forbidden_chars" != x; then
44982     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44983     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44984     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44985     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44986       # Going to short mode and back again did indeed matter. Since short mode is
44987       # case insensitive, let's make it lowercase to improve readability.
44988       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44989       # Now convert it back to Unix-stile (cygpath)
44990       input_path=`$CYGPATH -u "$shortmode_path"`
44991       new_path="$input_path"
44992     fi
44993   fi
44994 
44995   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44996   if test "x$test_cygdrive_prefix" = x; then
44997     # As a simple fix, exclude /usr/bin since it's not a real path.
44998     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44999       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45000       # a path prefixed by /cygdrive for fixpath to work.
45001       new_path="$CYGWIN_ROOT_PATH$input_path"
45002     fi
45003   fi
45004 
45005 
45006   if test "x$path" != "x$new_path"; then
45007     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45008     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45009 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45010   fi
45011 
45012   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45013 
45014   path="$POTENTIAL_FREETYPE_LIB_PATH"
45015   has_colon=`$ECHO $path | $GREP ^.:`
45016   new_path="$path"
45017   if test "x$has_colon" = x; then
45018     # Not in mixed or Windows style, start by that.
45019     new_path=`cmd //c echo $path`
45020   fi
45021 
45022 
45023   input_path="$new_path"
45024   # Check if we need to convert this using DOS-style short mode. If the path
45025   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45026   # take no chances and rewrite it.
45027   # Note: m4 eats our [], so we need to use [ and ] instead.
45028   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45029   if test "x$has_forbidden_chars" != x; then
45030     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45031     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45032   fi
45033 
45034 
45035   windows_path="$new_path"
45036   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45037     unix_path=`$CYGPATH -u "$windows_path"`
45038     new_path="$unix_path"
45039   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45040     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45041     new_path="$unix_path"
45042   fi
45043 
45044   if test "x$path" != "x$new_path"; then
45045     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45046     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45047 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45048   fi
45049 
45050   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45051   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45052 
45053   else
45054     # We're on a posix platform. Hooray! :)
45055     path="$POTENTIAL_FREETYPE_LIB_PATH"
45056     has_space=`$ECHO "$path" | $GREP " "`
45057     if test "x$has_space" != x; then
45058       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45059 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45060       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45061     fi
45062 
45063     # Use eval to expand a potential ~
45064     eval path="$path"
45065     if test ! -f "$path" && test ! -d "$path"; then
45066       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45067     fi
45068 
45069     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45070   fi
45071 
45072 
45073     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45074     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45075 $as_echo_n "checking for freetype includes... " >&6; }
45076     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45077 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45078     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45079     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45080 $as_echo_n "checking for freetype libraries... " >&6; }
45081     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45082 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45083   fi
45084 
45085           fi
45086 
45087           if test "x$FOUND_FREETYPE" != xyes; then
45088             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
45089             if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45090 
45091   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45092   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45093   METHOD="well-known location"
45094 
45095   # First check if the files exists.
45096   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45097     # We found an arbitrary include file. That's a good sign.
45098     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45099 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45100     FOUND_FREETYPE=yes
45101 
45102     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45103     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45104       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45105 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45106       FOUND_FREETYPE=no
45107     else
45108       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45109         # On Windows, we will need both .lib and .dll file.
45110         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45111           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45112 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45113           FOUND_FREETYPE=no
45114         fi
45115       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45116         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45117         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45118       fi
45119     fi
45120   fi
45121 
45122   if test "x$FOUND_FREETYPE" = xyes; then
45123 
45124   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45125 
45126   # Input might be given as Windows format, start by converting to
45127   # unix format.
45128   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45129   new_path=`$CYGPATH -u "$path"`
45130 
45131   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45132   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45133   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45134   # "foo.exe" is OK but "foo" is an error.
45135   #
45136   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45137   # It is also a way to make sure we got the proper file name for the real test later on.
45138   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45139   if test "x$test_shortpath" = x; then
45140     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45141 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45142     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45143   fi
45144 
45145   # Call helper function which possibly converts this using DOS-style short mode.
45146   # If so, the updated path is stored in $new_path.
45147 
45148   input_path="$new_path"
45149   # Check if we need to convert this using DOS-style short mode. If the path
45150   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45151   # take no chances and rewrite it.
45152   # Note: m4 eats our [], so we need to use [ and ] instead.
45153   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45154   if test "x$has_forbidden_chars" != x; then
45155     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45156     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45157     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45158     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45159       # Going to short mode and back again did indeed matter. Since short mode is
45160       # case insensitive, let's make it lowercase to improve readability.
45161       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45162       # Now convert it back to Unix-stile (cygpath)
45163       input_path=`$CYGPATH -u "$shortmode_path"`
45164       new_path="$input_path"
45165     fi
45166   fi
45167 
45168   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45169   if test "x$test_cygdrive_prefix" = x; then
45170     # As a simple fix, exclude /usr/bin since it's not a real path.
45171     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45172       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45173       # a path prefixed by /cygdrive for fixpath to work.
45174       new_path="$CYGWIN_ROOT_PATH$input_path"
45175     fi
45176   fi
45177 
45178 
45179   if test "x$path" != "x$new_path"; then
45180     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45181     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45182 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45183   fi
45184 
45185   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45186 
45187   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45188   has_colon=`$ECHO $path | $GREP ^.:`
45189   new_path="$path"
45190   if test "x$has_colon" = x; then
45191     # Not in mixed or Windows style, start by that.
45192     new_path=`cmd //c echo $path`
45193   fi
45194 
45195 
45196   input_path="$new_path"
45197   # Check if we need to convert this using DOS-style short mode. If the path
45198   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45199   # take no chances and rewrite it.
45200   # Note: m4 eats our [], so we need to use [ and ] instead.
45201   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45202   if test "x$has_forbidden_chars" != x; then
45203     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45204     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45205   fi
45206 
45207 
45208   windows_path="$new_path"
45209   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45210     unix_path=`$CYGPATH -u "$windows_path"`
45211     new_path="$unix_path"
45212   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45213     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45214     new_path="$unix_path"
45215   fi
45216 
45217   if test "x$path" != "x$new_path"; then
45218     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45219     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45220 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45221   fi
45222 
45223   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45224   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45225 
45226   else
45227     # We're on a posix platform. Hooray! :)
45228     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45229     has_space=`$ECHO "$path" | $GREP " "`
45230     if test "x$has_space" != x; then
45231       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45232 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45233       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45234     fi
45235 
45236     # Use eval to expand a potential ~
45237     eval path="$path"
45238     if test ! -f "$path" && test ! -d "$path"; then
45239       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45240     fi
45241 
45242     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45243   fi
45244 
45245 
45246   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45247 
45248   # Input might be given as Windows format, start by converting to
45249   # unix format.
45250   path="$POTENTIAL_FREETYPE_LIB_PATH"
45251   new_path=`$CYGPATH -u "$path"`
45252 
45253   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45254   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45255   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45256   # "foo.exe" is OK but "foo" is an error.
45257   #
45258   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45259   # It is also a way to make sure we got the proper file name for the real test later on.
45260   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45261   if test "x$test_shortpath" = x; then
45262     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45263 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45264     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45265   fi
45266 
45267   # Call helper function which possibly converts this using DOS-style short mode.
45268   # If so, the updated path is stored in $new_path.
45269 
45270   input_path="$new_path"
45271   # Check if we need to convert this using DOS-style short mode. If the path
45272   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45273   # take no chances and rewrite it.
45274   # Note: m4 eats our [], so we need to use [ and ] instead.
45275   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45276   if test "x$has_forbidden_chars" != x; then
45277     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45278     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45279     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45280     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45281       # Going to short mode and back again did indeed matter. Since short mode is
45282       # case insensitive, let's make it lowercase to improve readability.
45283       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45284       # Now convert it back to Unix-stile (cygpath)
45285       input_path=`$CYGPATH -u "$shortmode_path"`
45286       new_path="$input_path"
45287     fi
45288   fi
45289 
45290   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45291   if test "x$test_cygdrive_prefix" = x; then
45292     # As a simple fix, exclude /usr/bin since it's not a real path.
45293     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45294       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45295       # a path prefixed by /cygdrive for fixpath to work.
45296       new_path="$CYGWIN_ROOT_PATH$input_path"
45297     fi
45298   fi
45299 
45300 
45301   if test "x$path" != "x$new_path"; then
45302     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45303     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45304 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45305   fi
45306 
45307   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45308 
45309   path="$POTENTIAL_FREETYPE_LIB_PATH"
45310   has_colon=`$ECHO $path | $GREP ^.:`
45311   new_path="$path"
45312   if test "x$has_colon" = x; then
45313     # Not in mixed or Windows style, start by that.
45314     new_path=`cmd //c echo $path`
45315   fi
45316 
45317 
45318   input_path="$new_path"
45319   # Check if we need to convert this using DOS-style short mode. If the path
45320   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45321   # take no chances and rewrite it.
45322   # Note: m4 eats our [], so we need to use [ and ] instead.
45323   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45324   if test "x$has_forbidden_chars" != x; then
45325     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45326     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45327   fi
45328 
45329 
45330   windows_path="$new_path"
45331   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45332     unix_path=`$CYGPATH -u "$windows_path"`
45333     new_path="$unix_path"
45334   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45335     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45336     new_path="$unix_path"
45337   fi
45338 
45339   if test "x$path" != "x$new_path"; then
45340     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45341     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45342 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45343   fi
45344 
45345   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45346   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45347 
45348   else
45349     # We're on a posix platform. Hooray! :)
45350     path="$POTENTIAL_FREETYPE_LIB_PATH"
45351     has_space=`$ECHO "$path" | $GREP " "`
45352     if test "x$has_space" != x; then
45353       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45354 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45355       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45356     fi
45357 
45358     # Use eval to expand a potential ~
45359     eval path="$path"
45360     if test ! -f "$path" && test ! -d "$path"; then
45361       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45362     fi
45363 
45364     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45365   fi
45366 
45367 
45368     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45369     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45370 $as_echo_n "checking for freetype includes... " >&6; }
45371     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45372 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45373     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45374     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45375 $as_echo_n "checking for freetype libraries... " >&6; }
45376     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45377 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45378   fi
45379 
45380             else
45381 
45382   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45383   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
45384   METHOD="well-known location"
45385 
45386   # First check if the files exists.
45387   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45388     # We found an arbitrary include file. That's a good sign.
45389     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45390 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45391     FOUND_FREETYPE=yes
45392 
45393     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45394     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45395       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45396 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45397       FOUND_FREETYPE=no
45398     else
45399       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45400         # On Windows, we will need both .lib and .dll file.
45401         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45402           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45403 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45404           FOUND_FREETYPE=no
45405         fi
45406       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45407         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45408         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45409       fi
45410     fi
45411   fi
45412 
45413   if test "x$FOUND_FREETYPE" = xyes; then
45414 
45415   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45416 
45417   # Input might be given as Windows format, start by converting to
45418   # unix format.
45419   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45420   new_path=`$CYGPATH -u "$path"`
45421 
45422   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45423   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45424   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45425   # "foo.exe" is OK but "foo" is an error.
45426   #
45427   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45428   # It is also a way to make sure we got the proper file name for the real test later on.
45429   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45430   if test "x$test_shortpath" = x; then
45431     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45432 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45433     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45434   fi
45435 
45436   # Call helper function which possibly converts this using DOS-style short mode.
45437   # If so, the updated path is stored in $new_path.
45438 
45439   input_path="$new_path"
45440   # Check if we need to convert this using DOS-style short mode. If the path
45441   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45442   # take no chances and rewrite it.
45443   # Note: m4 eats our [], so we need to use [ and ] instead.
45444   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45445   if test "x$has_forbidden_chars" != x; then
45446     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45447     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45448     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45449     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45450       # Going to short mode and back again did indeed matter. Since short mode is
45451       # case insensitive, let's make it lowercase to improve readability.
45452       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45453       # Now convert it back to Unix-stile (cygpath)
45454       input_path=`$CYGPATH -u "$shortmode_path"`
45455       new_path="$input_path"
45456     fi
45457   fi
45458 
45459   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45460   if test "x$test_cygdrive_prefix" = x; then
45461     # As a simple fix, exclude /usr/bin since it's not a real path.
45462     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45463       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45464       # a path prefixed by /cygdrive for fixpath to work.
45465       new_path="$CYGWIN_ROOT_PATH$input_path"
45466     fi
45467   fi
45468 
45469 
45470   if test "x$path" != "x$new_path"; then
45471     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45472     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45473 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45474   fi
45475 
45476   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45477 
45478   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45479   has_colon=`$ECHO $path | $GREP ^.:`
45480   new_path="$path"
45481   if test "x$has_colon" = x; then
45482     # Not in mixed or Windows style, start by that.
45483     new_path=`cmd //c echo $path`
45484   fi
45485 
45486 
45487   input_path="$new_path"
45488   # Check if we need to convert this using DOS-style short mode. If the path
45489   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45490   # take no chances and rewrite it.
45491   # Note: m4 eats our [], so we need to use [ and ] instead.
45492   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45493   if test "x$has_forbidden_chars" != x; then
45494     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45495     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45496   fi
45497 
45498 
45499   windows_path="$new_path"
45500   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45501     unix_path=`$CYGPATH -u "$windows_path"`
45502     new_path="$unix_path"
45503   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45504     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45505     new_path="$unix_path"
45506   fi
45507 
45508   if test "x$path" != "x$new_path"; then
45509     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45510     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45511 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45512   fi
45513 
45514   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45515   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45516 
45517   else
45518     # We're on a posix platform. Hooray! :)
45519     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45520     has_space=`$ECHO "$path" | $GREP " "`
45521     if test "x$has_space" != x; then
45522       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45523 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45524       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45525     fi
45526 
45527     # Use eval to expand a potential ~
45528     eval path="$path"
45529     if test ! -f "$path" && test ! -d "$path"; then
45530       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45531     fi
45532 
45533     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45534   fi
45535 
45536 
45537   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45538 
45539   # Input might be given as Windows format, start by converting to
45540   # unix format.
45541   path="$POTENTIAL_FREETYPE_LIB_PATH"
45542   new_path=`$CYGPATH -u "$path"`
45543 
45544   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45545   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45546   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45547   # "foo.exe" is OK but "foo" is an error.
45548   #
45549   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45550   # It is also a way to make sure we got the proper file name for the real test later on.
45551   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45552   if test "x$test_shortpath" = x; then
45553     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45554 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45555     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45556   fi
45557 
45558   # Call helper function which possibly converts this using DOS-style short mode.
45559   # If so, the updated path is stored in $new_path.
45560 
45561   input_path="$new_path"
45562   # Check if we need to convert this using DOS-style short mode. If the path
45563   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45564   # take no chances and rewrite it.
45565   # Note: m4 eats our [], so we need to use [ and ] instead.
45566   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45567   if test "x$has_forbidden_chars" != x; then
45568     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45569     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45570     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45571     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45572       # Going to short mode and back again did indeed matter. Since short mode is
45573       # case insensitive, let's make it lowercase to improve readability.
45574       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45575       # Now convert it back to Unix-stile (cygpath)
45576       input_path=`$CYGPATH -u "$shortmode_path"`
45577       new_path="$input_path"
45578     fi
45579   fi
45580 
45581   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45582   if test "x$test_cygdrive_prefix" = x; then
45583     # As a simple fix, exclude /usr/bin since it's not a real path.
45584     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45585       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45586       # a path prefixed by /cygdrive for fixpath to work.
45587       new_path="$CYGWIN_ROOT_PATH$input_path"
45588     fi
45589   fi
45590 
45591 
45592   if test "x$path" != "x$new_path"; then
45593     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45594     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45595 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45596   fi
45597 
45598   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45599 
45600   path="$POTENTIAL_FREETYPE_LIB_PATH"
45601   has_colon=`$ECHO $path | $GREP ^.:`
45602   new_path="$path"
45603   if test "x$has_colon" = x; then
45604     # Not in mixed or Windows style, start by that.
45605     new_path=`cmd //c echo $path`
45606   fi
45607 
45608 
45609   input_path="$new_path"
45610   # Check if we need to convert this using DOS-style short mode. If the path
45611   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45612   # take no chances and rewrite it.
45613   # Note: m4 eats our [], so we need to use [ and ] instead.
45614   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45615   if test "x$has_forbidden_chars" != x; then
45616     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45617     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45618   fi
45619 
45620 
45621   windows_path="$new_path"
45622   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45623     unix_path=`$CYGPATH -u "$windows_path"`
45624     new_path="$unix_path"
45625   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45626     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45627     new_path="$unix_path"
45628   fi
45629 
45630   if test "x$path" != "x$new_path"; then
45631     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45632     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45633 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45634   fi
45635 
45636   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45637   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45638 
45639   else
45640     # We're on a posix platform. Hooray! :)
45641     path="$POTENTIAL_FREETYPE_LIB_PATH"
45642     has_space=`$ECHO "$path" | $GREP " "`
45643     if test "x$has_space" != x; then
45644       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45645 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45646       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45647     fi
45648 
45649     # Use eval to expand a potential ~
45650     eval path="$path"
45651     if test ! -f "$path" && test ! -d "$path"; then
45652       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45653     fi
45654 
45655     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45656   fi
45657 
45658 
45659     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45660     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45661 $as_echo_n "checking for freetype includes... " >&6; }
45662     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45663 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45664     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45665     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45666 $as_echo_n "checking for freetype libraries... " >&6; }
45667     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45668 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45669   fi
45670 
45671               if test "x$FOUND_FREETYPE" != xyes; then
45672 
45673   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45674   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
45675   METHOD="well-known location"
45676 
45677   # First check if the files exists.
45678   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45679     # We found an arbitrary include file. That's a good sign.
45680     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45681 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45682     FOUND_FREETYPE=yes
45683 
45684     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45685     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45686       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45687 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45688       FOUND_FREETYPE=no
45689     else
45690       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45691         # On Windows, we will need both .lib and .dll file.
45692         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45693           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45694 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45695           FOUND_FREETYPE=no
45696         fi
45697       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45698         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45699         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45700       fi
45701     fi
45702   fi
45703 
45704   if test "x$FOUND_FREETYPE" = xyes; then
45705 
45706   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45707 
45708   # Input might be given as Windows format, start by converting to
45709   # unix format.
45710   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45711   new_path=`$CYGPATH -u "$path"`
45712 
45713   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45714   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45715   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45716   # "foo.exe" is OK but "foo" is an error.
45717   #
45718   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45719   # It is also a way to make sure we got the proper file name for the real test later on.
45720   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45721   if test "x$test_shortpath" = x; then
45722     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45723 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45724     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45725   fi
45726 
45727   # Call helper function which possibly converts this using DOS-style short mode.
45728   # If so, the updated path is stored in $new_path.
45729 
45730   input_path="$new_path"
45731   # Check if we need to convert this using DOS-style short mode. If the path
45732   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45733   # take no chances and rewrite it.
45734   # Note: m4 eats our [], so we need to use [ and ] instead.
45735   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45736   if test "x$has_forbidden_chars" != x; then
45737     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45738     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45739     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45740     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45741       # Going to short mode and back again did indeed matter. Since short mode is
45742       # case insensitive, let's make it lowercase to improve readability.
45743       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45744       # Now convert it back to Unix-stile (cygpath)
45745       input_path=`$CYGPATH -u "$shortmode_path"`
45746       new_path="$input_path"
45747     fi
45748   fi
45749 
45750   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45751   if test "x$test_cygdrive_prefix" = x; then
45752     # As a simple fix, exclude /usr/bin since it's not a real path.
45753     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45754       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45755       # a path prefixed by /cygdrive for fixpath to work.
45756       new_path="$CYGWIN_ROOT_PATH$input_path"
45757     fi
45758   fi
45759 
45760 
45761   if test "x$path" != "x$new_path"; then
45762     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45763     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45764 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45765   fi
45766 
45767   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45768 
45769   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45770   has_colon=`$ECHO $path | $GREP ^.:`
45771   new_path="$path"
45772   if test "x$has_colon" = x; then
45773     # Not in mixed or Windows style, start by that.
45774     new_path=`cmd //c echo $path`
45775   fi
45776 
45777 
45778   input_path="$new_path"
45779   # Check if we need to convert this using DOS-style short mode. If the path
45780   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45781   # take no chances and rewrite it.
45782   # Note: m4 eats our [], so we need to use [ and ] instead.
45783   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45784   if test "x$has_forbidden_chars" != x; then
45785     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45786     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45787   fi
45788 
45789 
45790   windows_path="$new_path"
45791   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45792     unix_path=`$CYGPATH -u "$windows_path"`
45793     new_path="$unix_path"
45794   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45795     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45796     new_path="$unix_path"
45797   fi
45798 
45799   if test "x$path" != "x$new_path"; then
45800     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45801     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45802 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45803   fi
45804 
45805   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45806   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45807 
45808   else
45809     # We're on a posix platform. Hooray! :)
45810     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45811     has_space=`$ECHO "$path" | $GREP " "`
45812     if test "x$has_space" != x; then
45813       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45814 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45815       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45816     fi
45817 
45818     # Use eval to expand a potential ~
45819     eval path="$path"
45820     if test ! -f "$path" && test ! -d "$path"; then
45821       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45822     fi
45823 
45824     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45825   fi
45826 
45827 
45828   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45829 
45830   # Input might be given as Windows format, start by converting to
45831   # unix format.
45832   path="$POTENTIAL_FREETYPE_LIB_PATH"
45833   new_path=`$CYGPATH -u "$path"`
45834 
45835   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45836   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45837   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45838   # "foo.exe" is OK but "foo" is an error.
45839   #
45840   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45841   # It is also a way to make sure we got the proper file name for the real test later on.
45842   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45843   if test "x$test_shortpath" = x; then
45844     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45845 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45846     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45847   fi
45848 
45849   # Call helper function which possibly converts this using DOS-style short mode.
45850   # If so, the updated path is stored in $new_path.
45851 
45852   input_path="$new_path"
45853   # Check if we need to convert this using DOS-style short mode. If the path
45854   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45855   # take no chances and rewrite it.
45856   # Note: m4 eats our [], so we need to use [ and ] instead.
45857   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45858   if test "x$has_forbidden_chars" != x; then
45859     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45860     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45861     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45862     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45863       # Going to short mode and back again did indeed matter. Since short mode is
45864       # case insensitive, let's make it lowercase to improve readability.
45865       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45866       # Now convert it back to Unix-stile (cygpath)
45867       input_path=`$CYGPATH -u "$shortmode_path"`
45868       new_path="$input_path"
45869     fi
45870   fi
45871 
45872   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45873   if test "x$test_cygdrive_prefix" = x; then
45874     # As a simple fix, exclude /usr/bin since it's not a real path.
45875     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45876       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45877       # a path prefixed by /cygdrive for fixpath to work.
45878       new_path="$CYGWIN_ROOT_PATH$input_path"
45879     fi
45880   fi
45881 
45882 
45883   if test "x$path" != "x$new_path"; then
45884     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45885     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45886 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45887   fi
45888 
45889   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45890 
45891   path="$POTENTIAL_FREETYPE_LIB_PATH"
45892   has_colon=`$ECHO $path | $GREP ^.:`
45893   new_path="$path"
45894   if test "x$has_colon" = x; then
45895     # Not in mixed or Windows style, start by that.
45896     new_path=`cmd //c echo $path`
45897   fi
45898 
45899 
45900   input_path="$new_path"
45901   # Check if we need to convert this using DOS-style short mode. If the path
45902   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45903   # take no chances and rewrite it.
45904   # Note: m4 eats our [], so we need to use [ and ] instead.
45905   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45906   if test "x$has_forbidden_chars" != x; then
45907     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45908     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45909   fi
45910 
45911 
45912   windows_path="$new_path"
45913   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45914     unix_path=`$CYGPATH -u "$windows_path"`
45915     new_path="$unix_path"
45916   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45917     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45918     new_path="$unix_path"
45919   fi
45920 
45921   if test "x$path" != "x$new_path"; then
45922     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45923     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45924 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45925   fi
45926 
45927   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45928   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45929 
45930   else
45931     # We're on a posix platform. Hooray! :)
45932     path="$POTENTIAL_FREETYPE_LIB_PATH"
45933     has_space=`$ECHO "$path" | $GREP " "`
45934     if test "x$has_space" != x; then
45935       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45936 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45937       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45938     fi
45939 
45940     # Use eval to expand a potential ~
45941     eval path="$path"
45942     if test ! -f "$path" && test ! -d "$path"; then
45943       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45944     fi
45945 
45946     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45947   fi
45948 
45949 
45950     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45951     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45952 $as_echo_n "checking for freetype includes... " >&6; }
45953     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45954 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45955     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45956     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45957 $as_echo_n "checking for freetype libraries... " >&6; }
45958     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45959 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45960   fi
45961 
45962               fi
45963             fi
45964           fi
45965         fi
45966       fi # end check in well-known locations
45967 
45968       if test "x$FOUND_FREETYPE" != xyes; then
45969 
45970   # Print a helpful message on how to acquire the necessary build dependency.
45971   # freetype is the help tag: freetype, cups, pulse, alsa etc
45972   MISSING_DEPENDENCY=freetype
45973 
45974   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45975     cygwin_help $MISSING_DEPENDENCY
45976   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45977     msys_help $MISSING_DEPENDENCY
45978   else
45979     PKGHANDLER_COMMAND=
45980 
45981     case $PKGHANDLER in
45982       apt-get)
45983         apt_help     $MISSING_DEPENDENCY ;;
45984       yum)
45985         yum_help     $MISSING_DEPENDENCY ;;
45986       port)
45987         port_help    $MISSING_DEPENDENCY ;;
45988       pkgutil)
45989         pkgutil_help $MISSING_DEPENDENCY ;;
45990       pkgadd)
45991         pkgadd_help  $MISSING_DEPENDENCY ;;
45992     esac
45993 
45994     if test "x$PKGHANDLER_COMMAND" != x; then
45995       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
45996     fi
45997   fi
45998 
45999         as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
46000       fi
46001     fi # end user specified settings
46002 
46003     # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
46004     if test "x$FREETYPE_CFLAGS" = x; then
46005 
46006   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46007 
46008   # Input might be given as Windows format, start by converting to
46009   # unix format.
46010   path="$FREETYPE_INCLUDE_PATH"
46011   new_path=`$CYGPATH -u "$path"`
46012 
46013   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46014   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46015   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46016   # "foo.exe" is OK but "foo" is an error.
46017   #
46018   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46019   # It is also a way to make sure we got the proper file name for the real test later on.
46020   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46021   if test "x$test_shortpath" = x; then
46022     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46023 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46024     as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
46025   fi
46026 
46027   # Call helper function which possibly converts this using DOS-style short mode.
46028   # If so, the updated path is stored in $new_path.
46029 
46030   input_path="$new_path"
46031   # Check if we need to convert this using DOS-style short mode. If the path
46032   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46033   # take no chances and rewrite it.
46034   # Note: m4 eats our [], so we need to use [ and ] instead.
46035   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46036   if test "x$has_forbidden_chars" != x; then
46037     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46038     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46039     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46040     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46041       # Going to short mode and back again did indeed matter. Since short mode is
46042       # case insensitive, let's make it lowercase to improve readability.
46043       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46044       # Now convert it back to Unix-stile (cygpath)
46045       input_path=`$CYGPATH -u "$shortmode_path"`
46046       new_path="$input_path"
46047     fi
46048   fi
46049 
46050   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46051   if test "x$test_cygdrive_prefix" = x; then
46052     # As a simple fix, exclude /usr/bin since it's not a real path.
46053     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46054       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46055       # a path prefixed by /cygdrive for fixpath to work.
46056       new_path="$CYGWIN_ROOT_PATH$input_path"
46057     fi
46058   fi
46059 
46060 
46061   if test "x$path" != "x$new_path"; then
46062     FREETYPE_INCLUDE_PATH="$new_path"
46063     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46064 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46065   fi
46066 
46067   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46068 
46069   path="$FREETYPE_INCLUDE_PATH"
46070   has_colon=`$ECHO $path | $GREP ^.:`
46071   new_path="$path"
46072   if test "x$has_colon" = x; then
46073     # Not in mixed or Windows style, start by that.
46074     new_path=`cmd //c echo $path`
46075   fi
46076 
46077 
46078   input_path="$new_path"
46079   # Check if we need to convert this using DOS-style short mode. If the path
46080   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46081   # take no chances and rewrite it.
46082   # Note: m4 eats our [], so we need to use [ and ] instead.
46083   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46084   if test "x$has_forbidden_chars" != x; then
46085     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46086     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46087   fi
46088 
46089 
46090   windows_path="$new_path"
46091   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46092     unix_path=`$CYGPATH -u "$windows_path"`
46093     new_path="$unix_path"
46094   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46095     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46096     new_path="$unix_path"
46097   fi
46098 
46099   if test "x$path" != "x$new_path"; then
46100     FREETYPE_INCLUDE_PATH="$new_path"
46101     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46102 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46103   fi
46104 
46105   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46106   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46107 
46108   else
46109     # We're on a posix platform. Hooray! :)
46110     path="$FREETYPE_INCLUDE_PATH"
46111     has_space=`$ECHO "$path" | $GREP " "`
46112     if test "x$has_space" != x; then
46113       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46114 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46115       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46116     fi
46117 
46118     # Use eval to expand a potential ~
46119     eval path="$path"
46120     if test ! -f "$path" && test ! -d "$path"; then
46121       as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46122     fi
46123 
46124     FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46125   fi
46126 
46127       if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
46128         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
46129       else
46130         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
46131       fi
46132     fi
46133 
46134     if test "x$FREETYPE_LIBS" = x; then
46135 
46136   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46137 
46138   # Input might be given as Windows format, start by converting to
46139   # unix format.
46140   path="$FREETYPE_LIB_PATH"
46141   new_path=`$CYGPATH -u "$path"`
46142 
46143   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46144   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46145   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46146   # "foo.exe" is OK but "foo" is an error.
46147   #
46148   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46149   # It is also a way to make sure we got the proper file name for the real test later on.
46150   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46151   if test "x$test_shortpath" = x; then
46152     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46153 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46154     as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
46155   fi
46156 
46157   # Call helper function which possibly converts this using DOS-style short mode.
46158   # If so, the updated path is stored in $new_path.
46159 
46160   input_path="$new_path"
46161   # Check if we need to convert this using DOS-style short mode. If the path
46162   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46163   # take no chances and rewrite it.
46164   # Note: m4 eats our [], so we need to use [ and ] instead.
46165   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46166   if test "x$has_forbidden_chars" != x; then
46167     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46168     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46169     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46170     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46171       # Going to short mode and back again did indeed matter. Since short mode is
46172       # case insensitive, let's make it lowercase to improve readability.
46173       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46174       # Now convert it back to Unix-stile (cygpath)
46175       input_path=`$CYGPATH -u "$shortmode_path"`
46176       new_path="$input_path"
46177     fi
46178   fi
46179 
46180   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46181   if test "x$test_cygdrive_prefix" = x; then
46182     # As a simple fix, exclude /usr/bin since it's not a real path.
46183     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46184       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46185       # a path prefixed by /cygdrive for fixpath to work.
46186       new_path="$CYGWIN_ROOT_PATH$input_path"
46187     fi
46188   fi
46189 
46190 
46191   if test "x$path" != "x$new_path"; then
46192     FREETYPE_LIB_PATH="$new_path"
46193     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46194 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46195   fi
46196 
46197   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46198 
46199   path="$FREETYPE_LIB_PATH"
46200   has_colon=`$ECHO $path | $GREP ^.:`
46201   new_path="$path"
46202   if test "x$has_colon" = x; then
46203     # Not in mixed or Windows style, start by that.
46204     new_path=`cmd //c echo $path`
46205   fi
46206 
46207 
46208   input_path="$new_path"
46209   # Check if we need to convert this using DOS-style short mode. If the path
46210   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46211   # take no chances and rewrite it.
46212   # Note: m4 eats our [], so we need to use [ and ] instead.
46213   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46214   if test "x$has_forbidden_chars" != x; then
46215     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46216     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46217   fi
46218 
46219 
46220   windows_path="$new_path"
46221   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46222     unix_path=`$CYGPATH -u "$windows_path"`
46223     new_path="$unix_path"
46224   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46225     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46226     new_path="$unix_path"
46227   fi
46228 
46229   if test "x$path" != "x$new_path"; then
46230     FREETYPE_LIB_PATH="$new_path"
46231     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46232 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46233   fi
46234 
46235   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46236   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46237 
46238   else
46239     # We're on a posix platform. Hooray! :)
46240     path="$FREETYPE_LIB_PATH"
46241     has_space=`$ECHO "$path" | $GREP " "`
46242     if test "x$has_space" != x; then
46243       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46244 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46245       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46246     fi
46247 
46248     # Use eval to expand a potential ~
46249     eval path="$path"
46250     if test ! -f "$path" && test ! -d "$path"; then
46251       as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46252     fi
46253 
46254     FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46255   fi
46256 
46257       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46258         FREETYPE_LIBS="$FREETYPE_LIB_PATH/freetype.lib"
46259       else
46260         FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -lfreetype"
46261       fi
46262     fi
46263 
46264     # Try to compile it
46265     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
46266 $as_echo_n "checking if we can compile and link with freetype... " >&6; }
46267     ac_ext=cpp
46268 ac_cpp='$CXXCPP $CPPFLAGS'
46269 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46270 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46271 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46272 
46273     PREV_CXXCFLAGS="$CXXFLAGS"
46274     PREV_LIBS="$LIBS"
46275     PREV_CXX="$CXX"
46276     CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
46277     LIBS="$LIBS $FREETYPE_LIBS"
46278     CXX="$FIXPATH $CXX"
46279     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46280 /* end confdefs.h.  */
46281 
46282           #include<ft2build.h>
46283           #include FT_FREETYPE_H
46284           int main () {
46285             FT_Init_FreeType(NULL);
46286             return 0;
46287           }
46288 
46289 _ACEOF
46290 if ac_fn_cxx_try_link "$LINENO"; then :
46291 
46292           { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46293 $as_echo "yes" >&6; }
46294 
46295 else
46296 
46297           { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46298 $as_echo "no" >&6; }
46299           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
46300 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
46301           { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
46302 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
46303 
46304 
46305   # Print a helpful message on how to acquire the necessary build dependency.
46306   # freetype is the help tag: freetype, cups, pulse, alsa etc
46307   MISSING_DEPENDENCY=freetype
46308 
46309   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46310     cygwin_help $MISSING_DEPENDENCY
46311   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46312     msys_help $MISSING_DEPENDENCY
46313   else
46314     PKGHANDLER_COMMAND=
46315 
46316     case $PKGHANDLER in
46317       apt-get)
46318         apt_help     $MISSING_DEPENDENCY ;;
46319       yum)
46320         yum_help     $MISSING_DEPENDENCY ;;
46321       port)
46322         port_help    $MISSING_DEPENDENCY ;;
46323       pkgutil)
46324         pkgutil_help $MISSING_DEPENDENCY ;;
46325       pkgadd)
46326         pkgadd_help  $MISSING_DEPENDENCY ;;
46327     esac
46328 
46329     if test "x$PKGHANDLER_COMMAND" != x; then
46330       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46331     fi
46332   fi
46333 
46334 
46335           as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
46336 
46337 
46338 fi
46339 rm -f core conftest.err conftest.$ac_objext \
46340     conftest$ac_exeext conftest.$ac_ext
46341     CXXCFLAGS="$PREV_CXXFLAGS"
46342     LIBS="$PREV_LIBS"
46343     CXX="$PREV_CXX"
46344     ac_ext=cpp
46345 ac_cpp='$CXXCPP $CPPFLAGS'
46346 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46347 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46348 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46349 
46350 
46351     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
46352 $as_echo_n "checking if we should bundle freetype... " >&6; }
46353     if test "x$BUNDLE_FREETYPE" = xyes; then
46354       FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
46355     fi
46356     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
46357 $as_echo "$BUNDLE_FREETYPE" >&6; }
46358 
46359   fi # end freetype needed
46360 
46361 
46362 
46363 
46364 
46365 
46366 
46367   ###############################################################################
46368   #
46369   # Check for alsa headers and libraries. Used on Linux/GNU systems.
46370   #
46371 
46372 # Check whether --with-alsa was given.
46373 if test "${with_alsa+set}" = set; then :
46374   withval=$with_alsa;
46375 fi
46376 
46377 
46378 # Check whether --with-alsa-include was given.
46379 if test "${with_alsa_include+set}" = set; then :
46380   withval=$with_alsa_include;
46381 fi
46382 
46383 
46384 # Check whether --with-alsa-lib was given.
46385 if test "${with_alsa_lib+set}" = set; then :
46386   withval=$with_alsa_lib;
46387 fi
46388 
46389 
46390   if test "x$ALSA_NOT_NEEDED" = xyes; then
46391     if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
46392       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
46393 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
46394     fi
46395     ALSA_CFLAGS=
46396     ALSA_LIBS=
46397   else
46398     ALSA_FOUND=no
46399 
46400     if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
46401       as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
46402     fi
46403 
46404     if test "x${with_alsa}" != x; then
46405       ALSA_LIBS="-L${with_alsa}/lib -lasound"
46406       ALSA_CFLAGS="-I${with_alsa}/include"
46407       ALSA_FOUND=yes
46408     fi
46409     if test "x${with_alsa_include}" != x; then
46410       ALSA_CFLAGS="-I${with_alsa_include}"
46411       ALSA_FOUND=yes
46412     fi
46413     if test "x${with_alsa_lib}" != x; then
46414       ALSA_LIBS="-L${with_alsa_lib} -lasound"
46415       ALSA_FOUND=yes
46416     fi
46417     if test "x$ALSA_FOUND" = xno; then
46418 
46419 
46420   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
46421     # Source the builddeps file again, to make sure it uses the latest variables!
46422     . $builddepsfile
46423     # Look for a target and build machine specific resource!
46424     eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
46425     if test "x$resource" = x; then
46426       # Ok, lets instead look for a target specific resource
46427       eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
46428     fi
46429     if test "x$resource" = x; then
46430       # Ok, lets instead look for a build specific resource
46431       eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
46432     fi
46433     if test "x$resource" = x; then
46434       # Ok, lets instead look for a generic resource
46435       # (The alsa comes from M4 and not the shell, thus no need for eval here.)
46436       resource=${builddep_alsa}
46437     fi
46438     if test "x$resource" != x; then
46439       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
46440 $as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
46441       # If the resource in the builddeps.conf file is an existing directory,
46442       # for example /java/linux/cups
46443       if test -d ${resource}; then
46444         depdir=${resource}
46445       else
46446 
46447   # alsa is for example mymodule
46448   # $resource is for example libs/general/libmymod_1_2_3.zip
46449   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
46450   # $with_builddeps_dir is for example /localhome/builddeps
46451   # depdir is the name of the variable into which we store the depdir, eg MYMOD
46452   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
46453   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
46454   filename=`basename $resource`
46455   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
46456   filebase=${filename%%.*}
46457   extension=${filename#*.}
46458   installdir=$with_builddeps_dir/$filebase
46459   if test ! -f $installdir/$filename.unpacked; then
46460     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
46461 $as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
46462     if test ! -d $installdir; then
46463       mkdir -p $installdir
46464     fi
46465     if test ! -d $installdir; then
46466       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
46467     fi
46468     tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
46469     touch $tmpfile
46470     if test ! -f $tmpfile; then
46471       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
46472     fi
46473 
46474   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
46475   # $tmpfile is the local file name for the downloaded file.
46476   VALID_TOOL=no
46477   if test "x$BDEPS_FTP" = xwget; then
46478     VALID_TOOL=yes
46479     wget -O $tmpfile $with_builddeps_server/$resource
46480   fi
46481   if test "x$BDEPS_FTP" = xlftp; then
46482     VALID_TOOL=yes
46483     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
46484   fi
46485   if test "x$BDEPS_FTP" = xftp; then
46486     VALID_TOOL=yes
46487     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
46488     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
46489     FTPUSERPWD=${FTPSERVER%%@*}
46490     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
46491       FTPUSER=${userpwd%%:*}
46492       FTPPWD=${userpwd#*@}
46493       FTPSERVER=${FTPSERVER#*@}
46494     else
46495       FTPUSER=ftp
46496       FTPPWD=ftp
46497     fi
46498     # the "pass" command does not work on some
46499     # ftp clients (read ftp.exe) but if it works,
46500     # passive mode is better!
46501     ( \
46502         echo "user $FTPUSER $FTPPWD"        ; \
46503         echo "pass"                         ; \
46504         echo "bin"                          ; \
46505         echo "get $FTPPATH $tmpfile"              ; \
46506     ) | ftp -in $FTPSERVER
46507   fi
46508   if test "x$VALID_TOOL" != xyes; then
46509     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
46510   fi
46511 
46512     mv $tmpfile $installdir/$filename
46513     if test ! -s $installdir/$filename; then
46514       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
46515     fi
46516     case "$extension" in
46517       zip)  echo "Unzipping $installdir/$filename..."
46518         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
46519         ;;
46520       tar.gz) echo "Untaring $installdir/$filename..."
46521         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46522         ;;
46523       tgz) echo "Untaring $installdir/$filename..."
46524         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46525         ;;
46526       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
46527         ;;
46528     esac
46529   fi
46530   if test -f $installdir/$filename.unpacked; then
46531     depdir=$installdir
46532   fi
46533 
46534       fi
46535       # Source the builddeps file again, because in the previous command, the depdir
46536       # was updated to point at the current build dependency install directory.
46537       . $builddepsfile
46538       # Now extract variables from the builddeps.conf files.
46539       theroot=${builddep_alsa_ROOT}
46540       thecflags=${builddep_alsa_CFLAGS}
46541       thelibs=${builddep_alsa_LIBS}
46542       if test "x$depdir" = x; then
46543         as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
46544       fi
46545       ALSA=$depdir
46546       if test "x$theroot" != x; then
46547         ALSA="$theroot"
46548       fi
46549       if test "x$thecflags" != x; then
46550         ALSA_CFLAGS="$thecflags"
46551       fi
46552       if test "x$thelibs" != x; then
46553         ALSA_LIBS="$thelibs"
46554       fi
46555       ALSA_FOUND=yes
46556       else ALSA_FOUND=no
46557 
46558     fi
46559     else ALSA_FOUND=no
46560 
46561   fi
46562 
46563     fi
46564     if test "x$ALSA_FOUND" = xno; then
46565 
46566 pkg_failed=no
46567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46568 $as_echo_n "checking for ALSA... " >&6; }
46569 
46570 if test -n "$ALSA_CFLAGS"; then
46571     pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46572  elif test -n "$PKG_CONFIG"; then
46573     if test -n "$PKG_CONFIG" && \
46574     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46575   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46576   ac_status=$?
46577   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46578   test $ac_status = 0; }; then
46579   pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46580 else
46581   pkg_failed=yes
46582 fi
46583  else
46584     pkg_failed=untried
46585 fi
46586 if test -n "$ALSA_LIBS"; then
46587     pkg_cv_ALSA_LIBS="$ALSA_LIBS"
46588  elif test -n "$PKG_CONFIG"; then
46589     if test -n "$PKG_CONFIG" && \
46590     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46591   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46592   ac_status=$?
46593   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46594   test $ac_status = 0; }; then
46595   pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
46596 else
46597   pkg_failed=yes
46598 fi
46599  else
46600     pkg_failed=untried
46601 fi
46602 
46603 
46604 
46605 if test $pkg_failed = yes; then
46606 
46607 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
46608         _pkg_short_errors_supported=yes
46609 else
46610         _pkg_short_errors_supported=no
46611 fi
46612         if test $_pkg_short_errors_supported = yes; then
46613                 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
46614         else
46615                 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
46616         fi
46617         # Put the nasty error message in config.log where it belongs
46618         echo "$ALSA_PKG_ERRORS" >&5
46619 
46620         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46621 $as_echo "no" >&6; }
46622                 ALSA_FOUND=no
46623 elif test $pkg_failed = untried; then
46624         ALSA_FOUND=no
46625 else
46626         ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
46627         ALSA_LIBS=$pkg_cv_ALSA_LIBS
46628         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46629 $as_echo "yes" >&6; }
46630         ALSA_FOUND=yes
46631 fi
46632     fi
46633     if test "x$ALSA_FOUND" = xno; then
46634       for ac_header in alsa/asoundlib.h
46635 do :
46636   ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
46637 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
46638   cat >>confdefs.h <<_ACEOF
46639 #define HAVE_ALSA_ASOUNDLIB_H 1
46640 _ACEOF
46641 
46642             ALSA_FOUND=yes
46643             ALSA_CFLAGS=-Iignoreme
46644             ALSA_LIBS=-lasound
46645             DEFAULT_ALSA=yes
46646 
46647 else
46648   ALSA_FOUND=no
46649 fi
46650 
46651 done
46652 
46653     fi
46654     if test "x$ALSA_FOUND" = xno; then
46655 
46656   # Print a helpful message on how to acquire the necessary build dependency.
46657   # alsa is the help tag: freetype, cups, pulse, alsa etc
46658   MISSING_DEPENDENCY=alsa
46659 
46660   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46661     cygwin_help $MISSING_DEPENDENCY
46662   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46663     msys_help $MISSING_DEPENDENCY
46664   else
46665     PKGHANDLER_COMMAND=
46666 
46667     case $PKGHANDLER in
46668       apt-get)
46669         apt_help     $MISSING_DEPENDENCY ;;
46670       yum)
46671         yum_help     $MISSING_DEPENDENCY ;;
46672       port)
46673         port_help    $MISSING_DEPENDENCY ;;
46674       pkgutil)
46675         pkgutil_help $MISSING_DEPENDENCY ;;
46676       pkgadd)
46677         pkgadd_help  $MISSING_DEPENDENCY ;;
46678     esac
46679 
46680     if test "x$PKGHANDLER_COMMAND" != x; then
46681       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46682     fi
46683   fi
46684 
46685       as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
46686     fi
46687   fi
46688 
46689 
46690 
46691 
46692 
46693 
46694   ###############################################################################
46695   #
46696   # Check for the jpeg library
46697   #
46698 
46699   USE_EXTERNAL_LIBJPEG=true
46700   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5
46701 $as_echo_n "checking for main in -ljpeg... " >&6; }
46702 if ${ac_cv_lib_jpeg_main+:} false; then :
46703   $as_echo_n "(cached) " >&6
46704 else
46705   ac_check_lib_save_LIBS=$LIBS
46706 LIBS="-ljpeg  $LIBS"
46707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46708 /* end confdefs.h.  */
46709 
46710 
46711 int
46712 main ()
46713 {
46714 return main ();
46715   ;
46716   return 0;
46717 }
46718 _ACEOF
46719 if ac_fn_cxx_try_link "$LINENO"; then :
46720   ac_cv_lib_jpeg_main=yes
46721 else
46722   ac_cv_lib_jpeg_main=no
46723 fi
46724 rm -f core conftest.err conftest.$ac_objext \
46725     conftest$ac_exeext conftest.$ac_ext
46726 LIBS=$ac_check_lib_save_LIBS
46727 fi
46728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5
46729 $as_echo "$ac_cv_lib_jpeg_main" >&6; }
46730 if test "x$ac_cv_lib_jpeg_main" = xyes; then :
46731   cat >>confdefs.h <<_ACEOF
46732 #define HAVE_LIBJPEG 1
46733 _ACEOF
46734 
46735   LIBS="-ljpeg $LIBS"
46736 
46737 else
46738    USE_EXTERNAL_LIBJPEG=false
46739       { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5
46740 $as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;}
46741 
46742 fi
46743 
46744 
46745 
46746   ###############################################################################
46747   #
46748   # Check for the gif library
46749   #
46750 
46751 
46752 # Check whether --with-giflib was given.
46753 if test "${with_giflib+set}" = set; then :
46754   withval=$with_giflib;
46755 fi
46756 
46757 
46758 
46759   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
46760 $as_echo_n "checking for which giflib to use... " >&6; }
46761 
46762   # default is bundled
46763   DEFAULT_GIFLIB=bundled
46764 
46765   #
46766   # if user didn't specify, use DEFAULT_GIFLIB
46767   #
46768   if test "x${with_giflib}" = "x"; then
46769     with_giflib=${DEFAULT_GIFLIB}
46770   fi
46771 
46772   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
46773 $as_echo "${with_giflib}" >&6; }
46774 
46775   if test "x${with_giflib}" = "xbundled"; then
46776     USE_EXTERNAL_LIBGIF=false
46777   elif test "x${with_giflib}" = "xsystem"; then
46778     ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
46779 if test "x$ac_cv_header_gif_lib_h" = xyes; then :
46780 
46781 else
46782    as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
46783 fi
46784 
46785 
46786     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
46787 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
46788 if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
46789   $as_echo_n "(cached) " >&6
46790 else
46791   ac_check_lib_save_LIBS=$LIBS
46792 LIBS="-lgif  $LIBS"
46793 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46794 /* end confdefs.h.  */
46795 
46796 /* Override any GCC internal prototype to avoid an error.
46797    Use char because int might match the return type of a GCC
46798    builtin and then its argument prototype would still apply.  */
46799 #ifdef __cplusplus
46800 extern "C"
46801 #endif
46802 char DGifGetCode ();
46803 int
46804 main ()
46805 {
46806 return DGifGetCode ();
46807   ;
46808   return 0;
46809 }
46810 _ACEOF
46811 if ac_fn_cxx_try_link "$LINENO"; then :
46812   ac_cv_lib_gif_DGifGetCode=yes
46813 else
46814   ac_cv_lib_gif_DGifGetCode=no
46815 fi
46816 rm -f core conftest.err conftest.$ac_objext \
46817     conftest$ac_exeext conftest.$ac_ext
46818 LIBS=$ac_check_lib_save_LIBS
46819 fi
46820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
46821 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
46822 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
46823   cat >>confdefs.h <<_ACEOF
46824 #define HAVE_LIBGIF 1
46825 _ACEOF
46826 
46827   LIBS="-lgif $LIBS"
46828 
46829 else
46830    as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
46831 fi
46832 
46833 
46834     USE_EXTERNAL_LIBGIF=true
46835   else
46836     as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
46837   fi
46838 
46839 
46840   ###############################################################################
46841   #
46842   # Check for the zlib library
46843   #
46844 
46845 
46846 # Check whether --with-zlib was given.
46847 if test "${with_zlib+set}" = set; then :
46848   withval=$with_zlib;
46849 fi
46850 
46851 
46852   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
46853 $as_echo_n "checking for compress in -lz... " >&6; }
46854 if ${ac_cv_lib_z_compress+:} false; then :
46855   $as_echo_n "(cached) " >&6
46856 else
46857   ac_check_lib_save_LIBS=$LIBS
46858 LIBS="-lz  $LIBS"
46859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46860 /* end confdefs.h.  */
46861 
46862 /* Override any GCC internal prototype to avoid an error.
46863    Use char because int might match the return type of a GCC
46864    builtin and then its argument prototype would still apply.  */
46865 #ifdef __cplusplus
46866 extern "C"
46867 #endif
46868 char compress ();
46869 int
46870 main ()
46871 {
46872 return compress ();
46873   ;
46874   return 0;
46875 }
46876 _ACEOF
46877 if ac_fn_cxx_try_link "$LINENO"; then :
46878   ac_cv_lib_z_compress=yes
46879 else
46880   ac_cv_lib_z_compress=no
46881 fi
46882 rm -f core conftest.err conftest.$ac_objext \
46883     conftest$ac_exeext conftest.$ac_ext
46884 LIBS=$ac_check_lib_save_LIBS
46885 fi
46886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
46887 $as_echo "$ac_cv_lib_z_compress" >&6; }
46888 if test "x$ac_cv_lib_z_compress" = xyes; then :
46889    ZLIB_FOUND=yes
46890 else
46891    ZLIB_FOUND=no
46892 fi
46893 
46894 
46895   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
46896 $as_echo_n "checking for which zlib to use... " >&6; }
46897 
46898   DEFAULT_ZLIB=bundled
46899   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
46900     #
46901     # On macosx default is system...on others default is
46902     #
46903     DEFAULT_ZLIB=system
46904   fi
46905 
46906   if test "x${ZLIB_FOUND}" != "xyes"; then
46907     #
46908     # If we don't find any system...set default to bundled
46909     #
46910     DEFAULT_ZLIB=bundled
46911   fi
46912 
46913   #
46914   # If user didn't specify, use DEFAULT_ZLIB
46915   #
46916   if test "x${with_zlib}" = "x"; then
46917     with_zlib=${DEFAULT_ZLIB}
46918   fi
46919 
46920   if test "x${with_zlib}" = "xbundled"; then
46921     USE_EXTERNAL_LIBZ=false
46922     { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
46923 $as_echo "bundled" >&6; }
46924   elif test "x${with_zlib}" = "xsystem"; then
46925     if test "x${ZLIB_FOUND}" = "xyes"; then
46926       USE_EXTERNAL_LIBZ=true
46927       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
46928 $as_echo "system" >&6; }
46929     else
46930       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
46931 $as_echo "system not found" >&6; }
46932       as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
46933     fi
46934   else
46935     as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
46936   fi
46937 
46938 
46939 
46940   ###############################################################################
46941   LIBZIP_CAN_USE_MMAP=true
46942 
46943 
46944 
46945   ###############################################################################
46946   #
46947   # Check if altzone exists in time.h
46948   #
46949 
46950   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46951 /* end confdefs.h.  */
46952 #include <time.h>
46953 int
46954 main ()
46955 {
46956 return (int)altzone;
46957   ;
46958   return 0;
46959 }
46960 _ACEOF
46961 if ac_fn_cxx_try_link "$LINENO"; then :
46962   has_altzone=yes
46963 else
46964   has_altzone=no
46965 fi
46966 rm -f core conftest.err conftest.$ac_objext \
46967     conftest$ac_exeext conftest.$ac_ext
46968   if test "x$has_altzone" = xyes; then
46969 
46970 $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
46971 
46972   fi
46973 
46974   ###############################################################################
46975   #
46976   # Check the maths library
46977   #
46978 
46979   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
46980 $as_echo_n "checking for cos in -lm... " >&6; }
46981 if ${ac_cv_lib_m_cos+:} false; then :
46982   $as_echo_n "(cached) " >&6
46983 else
46984   ac_check_lib_save_LIBS=$LIBS
46985 LIBS="-lm  $LIBS"
46986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46987 /* end confdefs.h.  */
46988 
46989 /* Override any GCC internal prototype to avoid an error.
46990    Use char because int might match the return type of a GCC
46991    builtin and then its argument prototype would still apply.  */
46992 #ifdef __cplusplus
46993 extern "C"
46994 #endif
46995 char cos ();
46996 int
46997 main ()
46998 {
46999 return cos ();
47000   ;
47001   return 0;
47002 }
47003 _ACEOF
47004 if ac_fn_cxx_try_link "$LINENO"; then :
47005   ac_cv_lib_m_cos=yes
47006 else
47007   ac_cv_lib_m_cos=no
47008 fi
47009 rm -f core conftest.err conftest.$ac_objext \
47010     conftest$ac_exeext conftest.$ac_ext
47011 LIBS=$ac_check_lib_save_LIBS
47012 fi
47013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
47014 $as_echo "$ac_cv_lib_m_cos" >&6; }
47015 if test "x$ac_cv_lib_m_cos" = xyes; then :
47016   cat >>confdefs.h <<_ACEOF
47017 #define HAVE_LIBM 1
47018 _ACEOF
47019 
47020   LIBS="-lm $LIBS"
47021 
47022 else
47023 
47024         { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
47025 $as_echo "$as_me: Maths library was not found" >&6;}
47026 
47027 
47028 fi
47029 
47030 
47031 
47032   ###############################################################################
47033   #
47034   # Check for libdl.so
47035 
47036   save_LIBS="$LIBS"
47037   LIBS=""
47038   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
47039 $as_echo_n "checking for dlopen in -ldl... " >&6; }
47040 if ${ac_cv_lib_dl_dlopen+:} false; then :
47041   $as_echo_n "(cached) " >&6
47042 else
47043   ac_check_lib_save_LIBS=$LIBS
47044 LIBS="-ldl  $LIBS"
47045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47046 /* end confdefs.h.  */
47047 
47048 /* Override any GCC internal prototype to avoid an error.
47049    Use char because int might match the return type of a GCC
47050    builtin and then its argument prototype would still apply.  */
47051 #ifdef __cplusplus
47052 extern "C"
47053 #endif
47054 char dlopen ();
47055 int
47056 main ()
47057 {
47058 return dlopen ();
47059   ;
47060   return 0;
47061 }
47062 _ACEOF
47063 if ac_fn_cxx_try_link "$LINENO"; then :
47064   ac_cv_lib_dl_dlopen=yes
47065 else
47066   ac_cv_lib_dl_dlopen=no
47067 fi
47068 rm -f core conftest.err conftest.$ac_objext \
47069     conftest$ac_exeext conftest.$ac_ext
47070 LIBS=$ac_check_lib_save_LIBS
47071 fi
47072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
47073 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
47074 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
47075   cat >>confdefs.h <<_ACEOF
47076 #define HAVE_LIBDL 1
47077 _ACEOF
47078 
47079   LIBS="-ldl $LIBS"
47080 
47081 fi
47082 
47083   LIBDL="$LIBS"
47084 
47085   LIBS="$save_LIBS"
47086 
47087 
47088   ###############################################################################
47089   #
47090   # statically link libstdc++ before C++ ABI is stablized on Linux unless
47091   # dynamic build is configured on command line.
47092   #
47093 
47094 # Check whether --with-stdc++lib was given.
47095 if test "${with_stdc__lib+set}" = set; then :
47096   withval=$with_stdc__lib;
47097         if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
47098                 && test "x$with_stdc__lib" != xdefault; then
47099           as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
47100         fi
47101 
47102 else
47103   with_stdc__lib=default
47104 
47105 fi
47106 
47107 
47108   if test "x$OPENJDK_TARGET_OS" = xlinux; then
47109     # Test if -lstdc++ works.
47110     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
47111 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
47112     ac_ext=cpp
47113 ac_cpp='$CXXCPP $CPPFLAGS'
47114 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47115 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47116 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47117 
47118     OLD_CXXFLAGS="$CXXFLAGS"
47119     CXXFLAGS="$CXXFLAGS -lstdc++"
47120     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47121 /* end confdefs.h.  */
47122 
47123 int
47124 main ()
47125 {
47126 return 0;
47127   ;
47128   return 0;
47129 }
47130 _ACEOF
47131 if ac_fn_cxx_try_link "$LINENO"; then :
47132   has_dynamic_libstdcxx=yes
47133 else
47134   has_dynamic_libstdcxx=no
47135 fi
47136 rm -f core conftest.err conftest.$ac_objext \
47137     conftest$ac_exeext conftest.$ac_ext
47138     CXXFLAGS="$OLD_CXXFLAGS"
47139     ac_ext=cpp
47140 ac_cpp='$CXXCPP $CPPFLAGS'
47141 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47142 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47143 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47144 
47145     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
47146 $as_echo "$has_dynamic_libstdcxx" >&6; }
47147 
47148     # Test if stdc++ can be linked statically.
47149     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
47150 $as_echo_n "checking if static link of stdc++ is possible... " >&6; }
47151     STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
47152     ac_ext=cpp
47153 ac_cpp='$CXXCPP $CPPFLAGS'
47154 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47155 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47156 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47157 
47158     OLD_LIBS="$LIBS"
47159     OLD_CXX="$CXX"
47160     LIBS="$STATIC_STDCXX_FLAGS"
47161     CXX="$CC"
47162     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47163 /* end confdefs.h.  */
47164 
47165 int
47166 main ()
47167 {
47168 return 0;
47169   ;
47170   return 0;
47171 }
47172 _ACEOF
47173 if ac_fn_cxx_try_link "$LINENO"; then :
47174   has_static_libstdcxx=yes
47175 else
47176   has_static_libstdcxx=no
47177 fi
47178 rm -f core conftest.err conftest.$ac_objext \
47179     conftest$ac_exeext conftest.$ac_ext
47180     LIBS="$OLD_LIBS"
47181     CXX="$OLD_CXX"
47182     ac_ext=cpp
47183 ac_cpp='$CXXCPP $CPPFLAGS'
47184 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47185 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47186 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47187 
47188     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
47189 $as_echo "$has_static_libstdcxx" >&6; }
47190 
47191     if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
47192       as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
47193     fi
47194 
47195     if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
47196       as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
47197     fi
47198 
47199     if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
47200       as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
47201     fi
47202 
47203     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
47204 $as_echo_n "checking how to link with libstdc++... " >&6; }
47205     # If dynamic was requested, it's available since it would fail above otherwise.
47206     # If dynamic wasn't requested, go with static unless it isn't available.
47207     if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47208       LIBCXX="$LIBCXX -lstdc++"
47209       LDCXX="$CXX"
47210       STATIC_CXX_SETTING="STATIC_CXX=false"
47211       { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
47212 $as_echo "dynamic" >&6; }
47213     else
47214       LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
47215       LDCXX="$CC"
47216       STATIC_CXX_SETTING="STATIC_CXX=true"
47217       { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
47218 $as_echo "static" >&6; }
47219     fi
47220   fi
47221 
47222 
47223   if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47224     # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
47225 
47226 pkg_failed=no
47227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
47228 $as_echo_n "checking for LIBFFI... " >&6; }
47229 
47230 if test -n "$LIBFFI_CFLAGS"; then
47231     pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
47232  elif test -n "$PKG_CONFIG"; then
47233     if test -n "$PKG_CONFIG" && \
47234     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47235   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47236   ac_status=$?
47237   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47238   test $ac_status = 0; }; then
47239   pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
47240 else
47241   pkg_failed=yes
47242 fi
47243  else
47244     pkg_failed=untried
47245 fi
47246 if test -n "$LIBFFI_LIBS"; then
47247     pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
47248  elif test -n "$PKG_CONFIG"; then
47249     if test -n "$PKG_CONFIG" && \
47250     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47251   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47252   ac_status=$?
47253   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47254   test $ac_status = 0; }; then
47255   pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
47256 else
47257   pkg_failed=yes
47258 fi
47259  else
47260     pkg_failed=untried
47261 fi
47262 
47263 
47264 
47265 if test $pkg_failed = yes; then
47266 
47267 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47268         _pkg_short_errors_supported=yes
47269 else
47270         _pkg_short_errors_supported=no
47271 fi
47272         if test $_pkg_short_errors_supported = yes; then
47273                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
47274         else
47275                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
47276         fi
47277         # Put the nasty error message in config.log where it belongs
47278         echo "$LIBFFI_PKG_ERRORS" >&5
47279 
47280         as_fn_error $? "Package requirements (libffi) were not met:
47281 
47282 $LIBFFI_PKG_ERRORS
47283 
47284 Consider adjusting the PKG_CONFIG_PATH environment variable if you
47285 installed software in a non-standard prefix.
47286 
47287 Alternatively, you may set the environment variables LIBFFI_CFLAGS
47288 and LIBFFI_LIBS to avoid the need to call pkg-config.
47289 See the pkg-config man page for more details.
47290 " "$LINENO" 5
47291 elif test $pkg_failed = untried; then
47292         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47293 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
47294 as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
47295 is in your PATH or set the PKG_CONFIG environment variable to the full
47296 path to pkg-config.
47297 
47298 Alternatively, you may set the environment variables LIBFFI_CFLAGS
47299 and LIBFFI_LIBS to avoid the need to call pkg-config.
47300 See the pkg-config man page for more details.
47301 
47302 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
47303 See \`config.log' for more details" "$LINENO" 5; }
47304 else
47305         LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
47306         LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
47307         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47308 $as_echo "yes" >&6; }
47309         :
47310 fi
47311 
47312   fi
47313 
47314   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47315     # Extract the first word of "llvm-config", so it can be a program name with args.
47316 set dummy llvm-config; ac_word=$2
47317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47318 $as_echo_n "checking for $ac_word... " >&6; }
47319 if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
47320   $as_echo_n "(cached) " >&6
47321 else
47322   if test -n "$LLVM_CONFIG"; then
47323   ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
47324 else
47325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47326 for as_dir in $PATH
47327 do
47328   IFS=$as_save_IFS
47329   test -z "$as_dir" && as_dir=.
47330     for ac_exec_ext in '' $ac_executable_extensions; do
47331   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47332     ac_cv_prog_LLVM_CONFIG="llvm-config"
47333     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47334     break 2
47335   fi
47336 done
47337   done
47338 IFS=$as_save_IFS
47339 
47340 fi
47341 fi
47342 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
47343 if test -n "$LLVM_CONFIG"; then
47344   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
47345 $as_echo "$LLVM_CONFIG" >&6; }
47346 else
47347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47348 $as_echo "no" >&6; }
47349 fi
47350 
47351 
47352 
47353     if test "x$LLVM_CONFIG" != xllvm-config; then
47354       as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
47355     fi
47356 
47357     llvm_components="jit mcjit engine nativecodegen native"
47358     unset LLVM_CFLAGS
47359     for flag in $("$LLVM_CONFIG" --cxxflags); do
47360       if echo "${flag}" | grep -q '^-[ID]'; then
47361         if test "${flag}" != "-D_DEBUG" ; then
47362           if test "${LLVM_CFLAGS}" != "" ; then
47363             LLVM_CFLAGS="${LLVM_CFLAGS} "
47364           fi
47365           LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
47366         fi
47367       fi
47368     done
47369     llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
47370     LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
47371 
47372     unset LLVM_LDFLAGS
47373     for flag in $("${LLVM_CONFIG}" --ldflags); do
47374       if echo "${flag}" | grep -q '^-L'; then
47375         if test "${LLVM_LDFLAGS}" != ""; then
47376           LLVM_LDFLAGS="${LLVM_LDFLAGS} "
47377         fi
47378         LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
47379       fi
47380     done
47381 
47382     unset LLVM_LIBS
47383     for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47384       if echo "${flag}" | grep -q '^-l'; then
47385         if test "${LLVM_LIBS}" != ""; then
47386           LLVM_LIBS="${LLVM_LIBS} "
47387         fi
47388         LLVM_LIBS="${LLVM_LIBS}${flag}"
47389       fi
47390     done
47391 
47392 
47393 
47394 
47395   fi
47396 
47397   # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47398   if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47399     LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47400   fi
47401 
47402   # TODO better (platform agnostic) test
47403   if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47404     LIBCXX="-lstdc++"
47405   fi
47406 
47407 
47408 
47409 
47410   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47411 
47412 
47413 # Check whether --with-msvcr-dll was given.
47414 if test "${with_msvcr_dll+set}" = set; then :
47415   withval=$with_msvcr_dll;
47416 fi
47417 
47418 
47419   if test "x$with_msvcr_dll" != x; then
47420     # If given explicitely by user, do not probe. If not present, fail directly.
47421 
47422   POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
47423   METHOD="--with-msvcr-dll"
47424   if test -e "$POSSIBLE_MSVCR_DLL"; then
47425     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47426 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47427 
47428     # Need to check if the found msvcr is correct architecture
47429     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47430 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47431     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47432     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47433       CORRECT_MSVCR_ARCH=386
47434     else
47435       CORRECT_MSVCR_ARCH=x86-64
47436     fi
47437     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47438       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47439 $as_echo "ok" >&6; }
47440       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47441       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47442 $as_echo_n "checking for msvcr100.dll... " >&6; }
47443       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47444 $as_echo "$MSVCR_DLL" >&6; }
47445     else
47446       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47447 $as_echo "incorrect, ignoring" >&6; }
47448       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47449 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47450     fi
47451   fi
47452 
47453     if test "x$MSVCR_DLL" = x; then
47454       as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
47455     fi
47456   fi
47457 
47458   if test "x$MSVCR_DLL" = x; then
47459     # Probe: Using well-known location from Visual Studio 10.0
47460     if test "x$VCINSTALLDIR" != x; then
47461       CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
47462 
47463   windows_path="$CYGWIN_VC_INSTALL_DIR"
47464   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47465     unix_path=`$CYGPATH -u "$windows_path"`
47466     CYGWIN_VC_INSTALL_DIR="$unix_path"
47467   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47468     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47469     CYGWIN_VC_INSTALL_DIR="$unix_path"
47470   fi
47471 
47472       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47473         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
47474       else
47475         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
47476       fi
47477 
47478   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47479   METHOD="well-known location in VCINSTALLDIR"
47480   if test -e "$POSSIBLE_MSVCR_DLL"; then
47481     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47482 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47483 
47484     # Need to check if the found msvcr is correct architecture
47485     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47486 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47487     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47488     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47489       CORRECT_MSVCR_ARCH=386
47490     else
47491       CORRECT_MSVCR_ARCH=x86-64
47492     fi
47493     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47494       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47495 $as_echo "ok" >&6; }
47496       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47497       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47498 $as_echo_n "checking for msvcr100.dll... " >&6; }
47499       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47500 $as_echo "$MSVCR_DLL" >&6; }
47501     else
47502       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47503 $as_echo "incorrect, ignoring" >&6; }
47504       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47505 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47506     fi
47507   fi
47508 
47509     fi
47510   fi
47511 
47512   if test "x$MSVCR_DLL" = x; then
47513     # Probe: Check in the Boot JDK directory.
47514     POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
47515 
47516   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47517   METHOD="well-known location in Boot JDK"
47518   if test -e "$POSSIBLE_MSVCR_DLL"; then
47519     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47520 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47521 
47522     # Need to check if the found msvcr is correct architecture
47523     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47524 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47525     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47526     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47527       CORRECT_MSVCR_ARCH=386
47528     else
47529       CORRECT_MSVCR_ARCH=x86-64
47530     fi
47531     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47532       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47533 $as_echo "ok" >&6; }
47534       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47535       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47536 $as_echo_n "checking for msvcr100.dll... " >&6; }
47537       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47538 $as_echo "$MSVCR_DLL" >&6; }
47539     else
47540       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47541 $as_echo "incorrect, ignoring" >&6; }
47542       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47543 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47544     fi
47545   fi
47546 
47547   fi
47548 
47549   if test "x$MSVCR_DLL" = x; then
47550     # Probe: Look in the Windows system32 directory
47551     CYGWIN_SYSTEMROOT="$SYSTEMROOT"
47552 
47553   windows_path="$CYGWIN_SYSTEMROOT"
47554   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47555     unix_path=`$CYGPATH -u "$windows_path"`
47556     CYGWIN_SYSTEMROOT="$unix_path"
47557   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47558     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47559     CYGWIN_SYSTEMROOT="$unix_path"
47560   fi
47561 
47562     POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
47563 
47564   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47565   METHOD="well-known location in SYSTEMROOT"
47566   if test -e "$POSSIBLE_MSVCR_DLL"; then
47567     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47568 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47569 
47570     # Need to check if the found msvcr is correct architecture
47571     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47572 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47573     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47574     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47575       CORRECT_MSVCR_ARCH=386
47576     else
47577       CORRECT_MSVCR_ARCH=x86-64
47578     fi
47579     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47580       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47581 $as_echo "ok" >&6; }
47582       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47583       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47584 $as_echo_n "checking for msvcr100.dll... " >&6; }
47585       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47586 $as_echo "$MSVCR_DLL" >&6; }
47587     else
47588       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47589 $as_echo "incorrect, ignoring" >&6; }
47590       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47591 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47592     fi
47593   fi
47594 
47595   fi
47596 
47597   if test "x$MSVCR_DLL" = x; then
47598     # Probe: If Visual Studio Express is installed, there is usually one with the debugger
47599     if test "x$VS100COMNTOOLS" != x; then
47600       CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
47601 
47602   windows_path="$CYGWIN_VS_TOOLS_DIR"
47603   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47604     unix_path=`$CYGPATH -u "$windows_path"`
47605     CYGWIN_VS_TOOLS_DIR="$unix_path"
47606   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47607     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47608     CYGWIN_VS_TOOLS_DIR="$unix_path"
47609   fi
47610 
47611       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47612         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
47613       else
47614         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
47615       fi
47616 
47617   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47618   METHOD="search of VS100COMNTOOLS"
47619   if test -e "$POSSIBLE_MSVCR_DLL"; then
47620     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47621 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47622 
47623     # Need to check if the found msvcr is correct architecture
47624     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47625 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47626     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47627     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47628       CORRECT_MSVCR_ARCH=386
47629     else
47630       CORRECT_MSVCR_ARCH=x86-64
47631     fi
47632     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47633       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47634 $as_echo "ok" >&6; }
47635       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47636       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47637 $as_echo_n "checking for msvcr100.dll... " >&6; }
47638       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47639 $as_echo "$MSVCR_DLL" >&6; }
47640     else
47641       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47642 $as_echo "incorrect, ignoring" >&6; }
47643       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47644 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47645     fi
47646   fi
47647 
47648     fi
47649   fi
47650 
47651   if test "x$MSVCR_DLL" = x; then
47652     # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
47653     # (This was the original behaviour; kept since it might turn up something)
47654     if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
47655       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47656         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
47657       else
47658         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
47659         if test "x$POSSIBLE_MSVCR_DLL" = x; then
47660           # We're grasping at straws now...
47661           POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
47662         fi
47663       fi
47664 
47665 
47666   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47667   METHOD="search of VCINSTALLDIR"
47668   if test -e "$POSSIBLE_MSVCR_DLL"; then
47669     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47670 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47671 
47672     # Need to check if the found msvcr is correct architecture
47673     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47674 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47675     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47676     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47677       CORRECT_MSVCR_ARCH=386
47678     else
47679       CORRECT_MSVCR_ARCH=x86-64
47680     fi
47681     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47682       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47683 $as_echo "ok" >&6; }
47684       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47685       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47686 $as_echo_n "checking for msvcr100.dll... " >&6; }
47687       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47688 $as_echo "$MSVCR_DLL" >&6; }
47689     else
47690       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47691 $as_echo "incorrect, ignoring" >&6; }
47692       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47693 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47694     fi
47695   fi
47696 
47697     fi
47698   fi
47699 
47700   if test "x$MSVCR_DLL" = x; then
47701     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47702 $as_echo_n "checking for msvcr100.dll... " >&6; }
47703     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47704 $as_echo "no" >&6; }
47705     as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
47706   fi
47707 
47708 
47709   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47710 
47711   # Input might be given as Windows format, start by converting to
47712   # unix format.
47713   path="$MSVCR_DLL"
47714   new_path=`$CYGPATH -u "$path"`
47715 
47716   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47717   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47718   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47719   # "foo.exe" is OK but "foo" is an error.
47720   #
47721   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47722   # It is also a way to make sure we got the proper file name for the real test later on.
47723   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47724   if test "x$test_shortpath" = x; then
47725     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47726 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47727     as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
47728   fi
47729 
47730   # Call helper function which possibly converts this using DOS-style short mode.
47731   # If so, the updated path is stored in $new_path.
47732 
47733   input_path="$new_path"
47734   # Check if we need to convert this using DOS-style short mode. If the path
47735   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47736   # take no chances and rewrite it.
47737   # Note: m4 eats our [], so we need to use [ and ] instead.
47738   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47739   if test "x$has_forbidden_chars" != x; then
47740     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47741     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47742     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47743     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47744       # Going to short mode and back again did indeed matter. Since short mode is
47745       # case insensitive, let's make it lowercase to improve readability.
47746       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47747       # Now convert it back to Unix-stile (cygpath)
47748       input_path=`$CYGPATH -u "$shortmode_path"`
47749       new_path="$input_path"
47750     fi
47751   fi
47752 
47753   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47754   if test "x$test_cygdrive_prefix" = x; then
47755     # As a simple fix, exclude /usr/bin since it's not a real path.
47756     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47757       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47758       # a path prefixed by /cygdrive for fixpath to work.
47759       new_path="$CYGWIN_ROOT_PATH$input_path"
47760     fi
47761   fi
47762 
47763 
47764   if test "x$path" != "x$new_path"; then
47765     MSVCR_DLL="$new_path"
47766     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47767 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47768   fi
47769 
47770   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47771 
47772   path="$MSVCR_DLL"
47773   has_colon=`$ECHO $path | $GREP ^.:`
47774   new_path="$path"
47775   if test "x$has_colon" = x; then
47776     # Not in mixed or Windows style, start by that.
47777     new_path=`cmd //c echo $path`
47778   fi
47779 
47780 
47781   input_path="$new_path"
47782   # Check if we need to convert this using DOS-style short mode. If the path
47783   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47784   # take no chances and rewrite it.
47785   # Note: m4 eats our [], so we need to use [ and ] instead.
47786   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47787   if test "x$has_forbidden_chars" != x; then
47788     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47789     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47790   fi
47791 
47792 
47793   windows_path="$new_path"
47794   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47795     unix_path=`$CYGPATH -u "$windows_path"`
47796     new_path="$unix_path"
47797   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47798     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47799     new_path="$unix_path"
47800   fi
47801 
47802   if test "x$path" != "x$new_path"; then
47803     MSVCR_DLL="$new_path"
47804     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47805 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47806   fi
47807 
47808   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47809   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47810 
47811   else
47812     # We're on a posix platform. Hooray! :)
47813     path="$MSVCR_DLL"
47814     has_space=`$ECHO "$path" | $GREP " "`
47815     if test "x$has_space" != x; then
47816       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47817 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47818       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47819     fi
47820 
47821     # Use eval to expand a potential ~
47822     eval path="$path"
47823     if test ! -f "$path" && test ! -d "$path"; then
47824       as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
47825     fi
47826 
47827     MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
47828   fi
47829 
47830 
47831 
47832 
47833 # Check whether --with-dxsdk was given.
47834 if test "${with_dxsdk+set}" = set; then :
47835   withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
47836 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
47837 fi
47838 
47839 
47840 
47841 
47842 # Check whether --with-dxsdk-lib was given.
47843 if test "${with_dxsdk_lib+set}" = set; then :
47844   withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
47845 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
47846 fi
47847 
47848 
47849 
47850 
47851 # Check whether --with-dxsdk-include was given.
47852 if test "${with_dxsdk_include+set}" = set; then :
47853   withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
47854 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
47855 fi
47856 
47857 
47858   fi
47859 
47860 
47861 
47862 ###############################################################################
47863 #
47864 # We need to do some final tweaking, when everything else is done.
47865 #
47866 ###############################################################################
47867 
47868 
47869   HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
47870 
47871 
47872   # The name of the Service Agent jar.
47873   SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
47874   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47875     SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
47876   fi
47877 
47878 
47879 
47880     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
47881 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
47882 
47883     if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then
47884       ENABLE_INTREE_EC=yes
47885       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47886 $as_echo "yes" >&6; }
47887     else
47888       ENABLE_INTREE_EC=no
47889       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47890 $as_echo "no" >&6; }
47891     fi
47892 
47893 
47894 
47895 
47896 ###############################################################################
47897 #
47898 # Configure parts of the build that only affect the build performance,
47899 # not the result.
47900 #
47901 ###############################################################################
47902 
47903 
47904   # How many cores do we have on this build system?
47905 
47906 # Check whether --with-num-cores was given.
47907 if test "${with_num_cores+set}" = set; then :
47908   withval=$with_num_cores;
47909 fi
47910 
47911   if test "x$with_num_cores" = x; then
47912     # The number of cores were not specified, try to probe them.
47913 
47914   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
47915 $as_echo_n "checking for number of cores... " >&6; }
47916   NUM_CORES=1
47917   FOUND_CORES=no
47918 
47919   if test -f /proc/cpuinfo; then
47920     # Looks like a Linux (or cygwin) system
47921     NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
47922     FOUND_CORES=yes
47923   elif test -x /usr/sbin/psrinfo; then
47924     # Looks like a Solaris system
47925     NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
47926     FOUND_CORES=yes
47927   elif test -x /usr/sbin/system_profiler; then
47928     # Looks like a MacOSX system
47929     NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
47930     FOUND_CORES=yes
47931   elif test "x$OPENJDK_BUILD_OS" = xaix ; then
47932     NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
47933     FOUND_CORES=yes
47934   elif test -n "$NUMBER_OF_PROCESSORS"; then
47935     # On windows, look in the env
47936     NUM_CORES=$NUMBER_OF_PROCESSORS
47937     FOUND_CORES=yes
47938   fi
47939 
47940   if test "x$FOUND_CORES" = xyes; then
47941     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
47942 $as_echo "$NUM_CORES" >&6; }
47943   else
47944     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
47945 $as_echo "could not detect number of cores, defaulting to 1" >&6; }
47946     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
47947 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
47948   fi
47949 
47950   else
47951     NUM_CORES=$with_num_cores
47952   fi
47953 
47954 
47955 
47956   # How much memory do we have on this build system?
47957 
47958 # Check whether --with-memory-size was given.
47959 if test "${with_memory_size+set}" = set; then :
47960   withval=$with_memory_size;
47961 fi
47962 
47963   if test "x$with_memory_size" = x; then
47964     # The memory size was not specified, try to probe it.
47965 
47966   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
47967 $as_echo_n "checking for memory size... " >&6; }
47968   # Default to 1024 MB
47969   MEMORY_SIZE=1024
47970   FOUND_MEM=no
47971 
47972   if test -f /proc/meminfo; then
47973     # Looks like a Linux (or cygwin) system
47974     MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
47975     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
47976     FOUND_MEM=yes
47977   elif test -x /usr/sbin/prtconf; then
47978     # Looks like a Solaris or AIX system
47979     MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
47980     FOUND_MEM=yes
47981   elif test -x /usr/sbin/system_profiler; then
47982     # Looks like a MacOSX system
47983     MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
47984     MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
47985     FOUND_MEM=yes
47986   elif test "x$OPENJDK_BUILD_OS" = xwindows; then
47987     # Windows, but without cygwin
47988     MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
47989     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
47990     FOUND_MEM=yes
47991   fi
47992 
47993   if test "x$FOUND_MEM" = xyes; then
47994     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
47995 $as_echo "$MEMORY_SIZE MB" >&6; }
47996   else
47997     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5
47998 $as_echo "could not detect memory size, defaulting to 1024 MB" >&6; }
47999     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
48000 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
48001   fi
48002 
48003   else
48004     MEMORY_SIZE=$with_memory_size
48005   fi
48006 
48007 
48008 
48009   # Provide a decent default number of parallel jobs for make depending on
48010   # number of cores, amount of memory and machine architecture.
48011 
48012 # Check whether --with-jobs was given.
48013 if test "${with_jobs+set}" = set; then :
48014   withval=$with_jobs;
48015 fi
48016 
48017   if test "x$with_jobs" = x; then
48018     # Number of jobs was not specified, calculate.
48019     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
48020 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
48021     # Approximate memory in GB, rounding up a bit.
48022     memory_gb=`expr $MEMORY_SIZE / 1100`
48023     # Pick the lowest of memory in gb and number of cores.
48024     if test "$memory_gb" -lt "$NUM_CORES"; then
48025       JOBS="$memory_gb"
48026     else
48027       JOBS="$NUM_CORES"
48028       # On bigger machines, leave some room for other processes to run
48029       if test "$JOBS" -gt "4"; then
48030         JOBS=`expr $JOBS '*' 90 / 100`
48031       fi
48032     fi
48033     # Cap number of jobs to 16
48034     if test "$JOBS" -gt "16"; then
48035       JOBS=16
48036     fi
48037     if test "$JOBS" -eq "0"; then
48038       JOBS=1
48039     fi
48040     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
48041 $as_echo "$JOBS" >&6; }
48042   else
48043     JOBS=$with_jobs
48044   fi
48045 
48046 
48047 
48048 # Setup smart javac (after cores and memory have been setup)
48049 
48050 
48051 # Check whether --with-sjavac-server-java was given.
48052 if test "${with_sjavac_server_java+set}" = set; then :
48053   withval=$with_sjavac_server_java;
48054 fi
48055 
48056 
48057   if test "x$with_sjavac_server_java" != x; then
48058     SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
48059     FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
48060     if test "x$FOUND_VERSION" = x; then
48061       as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
48062     fi
48063   else
48064     SJAVAC_SERVER_JAVA=""
48065     # Hotspot specific options.
48066 
48067   $ECHO "Check if jvm arg is ok: -verbosegc" >&5
48068   $ECHO "Command: $JAVA -verbosegc -version" >&5
48069   OUTPUT=`$JAVA -verbosegc -version 2>&1`
48070   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48071   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48072   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48073     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc"
48074     JVM_ARG_OK=true
48075   else
48076     $ECHO "Arg failed:" >&5
48077     $ECHO "$OUTPUT" >&5
48078     JVM_ARG_OK=false
48079   fi
48080 
48081     # JRockit specific options.
48082 
48083   $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5
48084   $ECHO "Command: $JAVA -Xverbose:gc -version" >&5
48085   OUTPUT=`$JAVA -Xverbose:gc -version 2>&1`
48086   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48087   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48088   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48089     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc"
48090     JVM_ARG_OK=true
48091   else
48092     $ECHO "Arg failed:" >&5
48093     $ECHO "$OUTPUT" >&5
48094     JVM_ARG_OK=false
48095   fi
48096 
48097     SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA"
48098   fi
48099 
48100 
48101   if test "$MEMORY_SIZE" -gt "2500"; then
48102 
48103   $ECHO "Check if jvm arg is ok: -d64" >&5
48104   $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
48105   OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
48106   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48107   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48108   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48109     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64"
48110     JVM_ARG_OK=true
48111   else
48112     $ECHO "Arg failed:" >&5
48113     $ECHO "$OUTPUT" >&5
48114     JVM_ARG_OK=false
48115   fi
48116 
48117     if test "$JVM_ARG_OK" = true; then
48118       JVM_64BIT=true
48119       JVM_ARG_OK=false
48120     fi
48121   fi
48122 
48123   if test "$JVM_64BIT" = true; then
48124     if test "$MEMORY_SIZE" -gt "17000"; then
48125 
48126   $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5
48127   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5
48128   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1`
48129   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48130   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48131   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48132     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G"
48133     JVM_ARG_OK=true
48134   else
48135     $ECHO "Arg failed:" >&5
48136     $ECHO "$OUTPUT" >&5
48137     JVM_ARG_OK=false
48138   fi
48139 
48140     fi
48141     if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then
48142 
48143   $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5
48144   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5
48145   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1`
48146   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48147   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48148   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48149     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G"
48150     JVM_ARG_OK=true
48151   else
48152     $ECHO "Arg failed:" >&5
48153     $ECHO "$OUTPUT" >&5
48154     JVM_ARG_OK=false
48155   fi
48156 
48157     fi
48158     if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then
48159 
48160   $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5
48161   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5
48162   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1`
48163   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48164   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48165   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48166     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G"
48167     JVM_ARG_OK=true
48168   else
48169     $ECHO "Arg failed:" >&5
48170     $ECHO "$OUTPUT" >&5
48171     JVM_ARG_OK=false
48172   fi
48173 
48174     fi
48175     if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then
48176 
48177   $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5
48178   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5
48179   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1`
48180   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48181   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48182   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48183     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M"
48184     JVM_ARG_OK=true
48185   else
48186     $ECHO "Arg failed:" >&5
48187     $ECHO "$OUTPUT" >&5
48188     JVM_ARG_OK=false
48189   fi
48190 
48191     fi
48192   fi
48193   if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then
48194 
48195   $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5
48196   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5
48197   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1`
48198   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48199   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48200   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48201     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M"
48202     JVM_ARG_OK=true
48203   else
48204     $ECHO "Arg failed:" >&5
48205     $ECHO "$OUTPUT" >&5
48206     JVM_ARG_OK=false
48207   fi
48208 
48209   fi
48210   if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then
48211 
48212   $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5
48213   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5
48214   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1`
48215   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48216   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48217   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48218     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M"
48219     JVM_ARG_OK=true
48220   else
48221     $ECHO "Arg failed:" >&5
48222     $ECHO "$OUTPUT" >&5
48223     JVM_ARG_OK=false
48224   fi
48225 
48226   fi
48227   if test "$JVM_ARG_OK" = false; then
48228 
48229   $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5
48230   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5
48231   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1`
48232   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48233   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48234   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48235     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M"
48236     JVM_ARG_OK=true
48237   else
48238     $ECHO "Arg failed:" >&5
48239     $ECHO "$OUTPUT" >&5
48240     JVM_ARG_OK=false
48241   fi
48242 
48243   fi
48244 
48245   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
48246 $as_echo_n "checking whether to use sjavac... " >&6; }
48247   # Check whether --enable-sjavac was given.
48248 if test "${enable_sjavac+set}" = set; then :
48249   enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
48250 else
48251   ENABLE_SJAVAC='no'
48252 fi
48253 
48254   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
48255 $as_echo "$ENABLE_SJAVAC" >&6; }
48256 
48257 
48258   if test "x$ENABLE_SJAVAC" = xyes; then
48259     SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
48260   else
48261     SJAVAC_SERVER_DIR=
48262   fi
48263 
48264 
48265 
48266 # Can the C/C++ compiler use precompiled headers?
48267 
48268 
48269   ###############################################################################
48270   #
48271   # Can the C/C++ compiler use precompiled headers?
48272   #
48273   # Check whether --enable-precompiled-headers was given.
48274 if test "${enable_precompiled_headers+set}" = set; then :
48275   enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
48276 else
48277   ENABLE_PRECOMPH=yes
48278 fi
48279 
48280 
48281   USE_PRECOMPILED_HEADER=1
48282   if test "x$ENABLE_PRECOMPH" = xno; then
48283     USE_PRECOMPILED_HEADER=0
48284   fi
48285 
48286   if test "x$ENABLE_PRECOMPH" = xyes; then
48287     # Check that the compiler actually supports precomp headers.
48288     if test "x$TOOLCHAIN_TYPE" = xgcc; then
48289       { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
48290 $as_echo_n "checking that precompiled headers work... " >&6; }
48291       echo "int alfa();" > conftest.h
48292       $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
48293       if test ! -f conftest.hpp.gch; then
48294         USE_PRECOMPILED_HEADER=0
48295         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48296 $as_echo "no" >&6; }
48297       else
48298         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48299 $as_echo "yes" >&6; }
48300       fi
48301       rm -f conftest.h conftest.hpp.gch
48302     fi
48303   fi
48304 
48305 
48306 
48307 
48308 # Setup use of ccache, if available
48309 
48310   # Check whether --enable-ccache was given.
48311 if test "${enable_ccache+set}" = set; then :
48312   enableval=$enable_ccache;
48313 fi
48314 
48315 
48316   CCACHE=
48317   { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48318 $as_echo_n "checking is ccache enabled... " >&6; }
48319   ENABLE_CCACHE=$enable_ccache
48320   if test "x$enable_ccache" = xyes; then
48321     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48322 $as_echo "yes" >&6; }
48323     OLD_PATH="$PATH"
48324     if test "x$TOOLS_DIR" != x; then
48325       PATH=$TOOLS_DIR:$PATH
48326     fi
48327 
48328 
48329 
48330   # Publish this variable in the help.
48331 
48332 
48333   if test "x$CCACHE" = x; then
48334     # The variable is not set by user, try to locate tool using the code snippet
48335     for ac_prog in ccache
48336 do
48337   # Extract the first word of "$ac_prog", so it can be a program name with args.
48338 set dummy $ac_prog; ac_word=$2
48339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48340 $as_echo_n "checking for $ac_word... " >&6; }
48341 if ${ac_cv_path_CCACHE+:} false; then :
48342   $as_echo_n "(cached) " >&6
48343 else
48344   case $CCACHE in
48345   [\\/]* | ?:[\\/]*)
48346   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48347   ;;
48348   *)
48349   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48350 for as_dir in $PATH
48351 do
48352   IFS=$as_save_IFS
48353   test -z "$as_dir" && as_dir=.
48354     for ac_exec_ext in '' $ac_executable_extensions; do
48355   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48356     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48357     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48358     break 2
48359   fi
48360 done
48361   done
48362 IFS=$as_save_IFS
48363 
48364   ;;
48365 esac
48366 fi
48367 CCACHE=$ac_cv_path_CCACHE
48368 if test -n "$CCACHE"; then
48369   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48370 $as_echo "$CCACHE" >&6; }
48371 else
48372   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48373 $as_echo "no" >&6; }
48374 fi
48375 
48376 
48377   test -n "$CCACHE" && break
48378 done
48379 
48380   else
48381     # The variable is set, but is it from the command line or the environment?
48382 
48383     # Try to remove the string !CCACHE! from our list.
48384     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
48385     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
48386       # If it failed, the variable was not from the command line. Ignore it,
48387       # but warn the user (except for BASH, which is always set by the calling BASH).
48388       if test "xCCACHE" != xBASH; then
48389         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
48390 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
48391       fi
48392       # Try to locate tool using the code snippet
48393       for ac_prog in ccache
48394 do
48395   # Extract the first word of "$ac_prog", so it can be a program name with args.
48396 set dummy $ac_prog; ac_word=$2
48397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48398 $as_echo_n "checking for $ac_word... " >&6; }
48399 if ${ac_cv_path_CCACHE+:} false; then :
48400   $as_echo_n "(cached) " >&6
48401 else
48402   case $CCACHE in
48403   [\\/]* | ?:[\\/]*)
48404   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48405   ;;
48406   *)
48407   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48408 for as_dir in $PATH
48409 do
48410   IFS=$as_save_IFS
48411   test -z "$as_dir" && as_dir=.
48412     for ac_exec_ext in '' $ac_executable_extensions; do
48413   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48414     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48415     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48416     break 2
48417   fi
48418 done
48419   done
48420 IFS=$as_save_IFS
48421 
48422   ;;
48423 esac
48424 fi
48425 CCACHE=$ac_cv_path_CCACHE
48426 if test -n "$CCACHE"; then
48427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48428 $as_echo "$CCACHE" >&6; }
48429 else
48430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48431 $as_echo "no" >&6; }
48432 fi
48433 
48434 
48435   test -n "$CCACHE" && break
48436 done
48437 
48438     else
48439       # If it succeeded, then it was overridden by the user. We will use it
48440       # for the tool.
48441 
48442       # First remove it from the list of overridden variables, so we can test
48443       # for unknown variables in the end.
48444       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
48445 
48446       # Check if the provided tool contains a complete path.
48447       tool_specified="$CCACHE"
48448       tool_basename="${tool_specified##*/}"
48449       if test "x$tool_basename" = "x$tool_specified"; then
48450         # A command without a complete path is provided, search $PATH.
48451         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
48452 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
48453         # Extract the first word of "$tool_basename", so it can be a program name with args.
48454 set dummy $tool_basename; ac_word=$2
48455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48456 $as_echo_n "checking for $ac_word... " >&6; }
48457 if ${ac_cv_path_CCACHE+:} false; then :
48458   $as_echo_n "(cached) " >&6
48459 else
48460   case $CCACHE in
48461   [\\/]* | ?:[\\/]*)
48462   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48463   ;;
48464   *)
48465   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48466 for as_dir in $PATH
48467 do
48468   IFS=$as_save_IFS
48469   test -z "$as_dir" && as_dir=.
48470     for ac_exec_ext in '' $ac_executable_extensions; do
48471   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48472     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48473     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48474     break 2
48475   fi
48476 done
48477   done
48478 IFS=$as_save_IFS
48479 
48480   ;;
48481 esac
48482 fi
48483 CCACHE=$ac_cv_path_CCACHE
48484 if test -n "$CCACHE"; then
48485   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48486 $as_echo "$CCACHE" >&6; }
48487 else
48488   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48489 $as_echo "no" >&6; }
48490 fi
48491 
48492 
48493         if test "x$CCACHE" = x; then
48494           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
48495         fi
48496       else
48497         # Otherwise we believe it is a complete path. Use it as it is.
48498         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
48499 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
48500         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
48501 $as_echo_n "checking for CCACHE... " >&6; }
48502         if test ! -x "$tool_specified"; then
48503           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
48504 $as_echo "not found" >&6; }
48505           as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
48506         fi
48507         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
48508 $as_echo "$tool_specified" >&6; }
48509       fi
48510     fi
48511   fi
48512 
48513 
48514 
48515   if test "x$CCACHE" = x; then
48516     as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
48517   fi
48518 
48519 
48520     CCACHE_STATUS="enabled"
48521     PATH="$OLD_PATH"
48522   elif test "x$enable_ccache" = xno; then
48523     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
48524 $as_echo "no, explicitly disabled" >&6; }
48525   elif test "x$enable_ccache" = x; then
48526     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48527 $as_echo "no" >&6; }
48528   else
48529     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
48530 $as_echo "unknown" >&6; }
48531     as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
48532   fi
48533 
48534 
48535 
48536 # Check whether --with-ccache-dir was given.
48537 if test "${with_ccache_dir+set}" = set; then :
48538   withval=$with_ccache_dir;
48539 fi
48540 
48541 
48542   if test "x$with_ccache_dir" != x; then
48543     # When using a non home ccache directory, assume the use is to share ccache files
48544     # with other users. Thus change the umask.
48545     SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
48546     if test "x$CCACHE" = x; then
48547       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
48548 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
48549     fi
48550   fi
48551 
48552   if test "x$CCACHE" != x; then
48553 
48554   if test "x$CCACHE" != x; then
48555     # Only use ccache if it is 3.1.4 or later, which supports
48556     # precompiled headers.
48557     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
48558 $as_echo_n "checking if ccache supports precompiled headers... " >&6; }
48559     HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
48560     if test "x$HAS_GOOD_CCACHE" = x; then
48561       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
48562 $as_echo "no, disabling ccache" >&6; }
48563       CCACHE=
48564       CCACHE_STATUS="disabled"
48565     else
48566       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48567 $as_echo "yes" >&6; }
48568       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
48569 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
48570       PUSHED_FLAGS="$CXXFLAGS"
48571       CXXFLAGS="-fpch-preprocess $CXXFLAGS"
48572       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48573 /* end confdefs.h.  */
48574 
48575 int
48576 main ()
48577 {
48578 
48579   ;
48580   return 0;
48581 }
48582 _ACEOF
48583 if ac_fn_cxx_try_compile "$LINENO"; then :
48584   CC_KNOWS_CCACHE_TRICK=yes
48585 else
48586   CC_KNOWS_CCACHE_TRICK=no
48587 fi
48588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
48589       CXXFLAGS="$PUSHED_FLAGS"
48590       if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
48591         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48592 $as_echo "yes" >&6; }
48593       else
48594         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
48595 $as_echo "no, disabling ccaching of precompiled headers" >&6; }
48596         CCACHE=
48597         CCACHE_STATUS="disabled"
48598       fi
48599     fi
48600   fi
48601 
48602   if test "x$CCACHE" != x; then
48603     CCACHE_SLOPPINESS=time_macros
48604     CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
48605     CCACHE_FLAGS=-fpch-preprocess
48606 
48607     if test "x$SET_CCACHE_DIR" != x; then
48608       mkdir -p $CCACHE_DIR > /dev/null 2>&1
48609       chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
48610     fi
48611   fi
48612 
48613   fi
48614 
48615 
48616 ###############################################################################
48617 #
48618 # And now the finish...
48619 #
48620 ###############################################################################
48621 
48622 # Check for some common pitfalls
48623 
48624   if test x"$OPENJDK_BUILD_OS" = xwindows; then
48625     file_to_test="$SRC_ROOT/LICENSE"
48626     if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
48627       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
48628     fi
48629   fi
48630 
48631 
48632   # Did user specify any unknown variables?
48633 
48634   if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
48635     # Replace the separating ! with spaces before presenting for end user.
48636     unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
48637     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
48638 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
48639   fi
48640 
48641 
48642   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
48643 $as_echo_n "checking if build directory is on local disk... " >&6; }
48644 
48645   # df -l lists only local disks; if the given directory is not found then
48646   # a non-zero exit code is given
48647   if test "x$DF" = x; then
48648     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48649       # msys does not have df; use Windows "net use" instead.
48650       IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
48651       if test "x$IS_NETWORK_DISK" = x; then
48652         OUTPUT_DIR_IS_LOCAL="yes"
48653       else
48654         OUTPUT_DIR_IS_LOCAL="no"
48655       fi
48656     else
48657       # No df here, say it's local
48658       OUTPUT_DIR_IS_LOCAL="yes"
48659     fi
48660   else
48661     if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
48662       OUTPUT_DIR_IS_LOCAL="yes"
48663     else
48664       OUTPUT_DIR_IS_LOCAL="no"
48665     fi
48666   fi
48667 
48668   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
48669 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
48670 
48671 
48672 
48673   # Check if the user has any old-style ALT_ variables set.
48674   FOUND_ALT_VARIABLES=`env | grep ^ALT_`
48675 
48676   # Before generating output files, test if they exist. If they do, this is a reconfigure.
48677   # Since we can't properly handle the dependencies for this, warn the user about the situation
48678   if test -e $OUTPUT_ROOT/spec.gmk; then
48679     IS_RECONFIGURE=yes
48680   else
48681     IS_RECONFIGURE=no
48682   fi
48683 
48684 
48685 # At the end, call the custom hook. (Dummy macro if no custom sources available)
48686 
48687 
48688 # We're messing a bit with internal autoconf variables to put the config.status
48689 # in the output directory instead of the current directory.
48690 CONFIG_STATUS="$OUTPUT_ROOT/config.status"
48691 
48692 # Create the actual output files. Now the main work of configure is done.
48693 cat >confcache <<\_ACEOF
48694 # This file is a shell script that caches the results of configure
48695 # tests run on this system so they can be shared between configure
48696 # scripts and configure runs, see configure's option --config-cache.
48697 # It is not useful on other systems.  If it contains results you don't
48698 # want to keep, you may remove or edit it.
48699 #
48700 # config.status only pays attention to the cache file if you give it
48701 # the --recheck option to rerun configure.
48702 #
48703 # `ac_cv_env_foo' variables (set or unset) will be overridden when
48704 # loading this file, other *unset* `ac_cv_foo' will be assigned the
48705 # following values.
48706 
48707 _ACEOF
48708 
48709 # The following way of writing the cache mishandles newlines in values,
48710 # but we know of no workaround that is simple, portable, and efficient.
48711 # So, we kill variables containing newlines.
48712 # Ultrix sh set writes to stderr and can't be redirected directly,
48713 # and sets the high bit in the cache file unless we assign to the vars.
48714 (
48715   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
48716     eval ac_val=\$$ac_var
48717     case $ac_val in #(
48718     *${as_nl}*)
48719       case $ac_var in #(
48720       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
48721 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
48722       esac
48723       case $ac_var in #(
48724       _ | IFS | as_nl) ;; #(
48725       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
48726       *) { eval $ac_var=; unset $ac_var;} ;;
48727       esac ;;
48728     esac
48729   done
48730 
48731   (set) 2>&1 |
48732     case $as_nl`(ac_space=' '; set) 2>&1` in #(
48733     *${as_nl}ac_space=\ *)
48734       # `set' does not quote correctly, so add quotes: double-quote
48735       # substitution turns \\\\ into \\, and sed turns \\ into \.
48736       sed -n \
48737         "s/'/'\\\\''/g;
48738           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
48739       ;; #(
48740     *)
48741       # `set' quotes correctly as required by POSIX, so do not add quotes.
48742       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
48743       ;;
48744     esac |
48745     sort
48746 ) |
48747   sed '
48748      /^ac_cv_env_/b end
48749      t clear
48750      :clear
48751      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
48752      t end
48753      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
48754      :end' >>confcache
48755 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
48756   if test -w "$cache_file"; then
48757     if test "x$cache_file" != "x/dev/null"; then
48758       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
48759 $as_echo "$as_me: updating cache $cache_file" >&6;}
48760       if test ! -f "$cache_file" || test -h "$cache_file"; then
48761         cat confcache >"$cache_file"
48762       else
48763         case $cache_file in #(
48764         */* | ?:*)
48765           mv -f confcache "$cache_file"$$ &&
48766           mv -f "$cache_file"$$ "$cache_file" ;; #(
48767         *)
48768           mv -f confcache "$cache_file" ;;
48769         esac
48770       fi
48771     fi
48772   else
48773     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
48774 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
48775   fi
48776 fi
48777 rm -f confcache
48778 
48779 test "x$prefix" = xNONE && prefix=$ac_default_prefix
48780 # Let make expand exec_prefix.
48781 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
48782 
48783 DEFS=-DHAVE_CONFIG_H
48784 
48785 ac_libobjs=
48786 ac_ltlibobjs=
48787 U=
48788 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
48789   # 1. Remove the extension, and $U if already installed.
48790   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
48791   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
48792   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
48793   #    will be set to the directory where LIBOBJS objects are built.
48794   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
48795   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
48796 done
48797 LIBOBJS=$ac_libobjs
48798 
48799 LTLIBOBJS=$ac_ltlibobjs
48800 
48801 
48802 
48803 : "${CONFIG_STATUS=./config.status}"
48804 ac_write_fail=0
48805 ac_clean_files_save=$ac_clean_files
48806 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
48807 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
48808 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
48809 as_write_fail=0
48810 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
48811 #! $SHELL
48812 # Generated by $as_me.
48813 # Run this file to recreate the current configuration.
48814 # Compiler output produced by configure, useful for debugging
48815 # configure, is in config.log if it exists.
48816 
48817 debug=false
48818 ac_cs_recheck=false
48819 ac_cs_silent=false
48820 
48821 SHELL=\${CONFIG_SHELL-$SHELL}
48822 export SHELL
48823 _ASEOF
48824 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
48825 ## -------------------- ##
48826 ## M4sh Initialization. ##
48827 ## -------------------- ##
48828 
48829 # Be more Bourne compatible
48830 DUALCASE=1; export DUALCASE # for MKS sh
48831 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
48832   emulate sh
48833   NULLCMD=:
48834   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
48835   # is contrary to our usage.  Disable this feature.
48836   alias -g '${1+"$@"}'='"$@"'
48837   setopt NO_GLOB_SUBST
48838 else
48839   case `(set -o) 2>/dev/null` in #(
48840   *posix*) :
48841     set -o posix ;; #(
48842   *) :
48843      ;;
48844 esac
48845 fi
48846 
48847 
48848 as_nl='
48849 '
48850 export as_nl
48851 # Printing a long string crashes Solaris 7 /usr/bin/printf.
48852 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
48853 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
48854 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
48855 # Prefer a ksh shell builtin over an external printf program on Solaris,
48856 # but without wasting forks for bash or zsh.
48857 if test -z "$BASH_VERSION$ZSH_VERSION" \
48858     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
48859   as_echo='print -r --'
48860   as_echo_n='print -rn --'
48861 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48862   as_echo='printf %s\n'
48863   as_echo_n='printf %s'
48864 else
48865   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
48866     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
48867     as_echo_n='/usr/ucb/echo -n'
48868   else
48869     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
48870     as_echo_n_body='eval
48871       arg=$1;
48872       case $arg in #(
48873       *"$as_nl"*)
48874         expr "X$arg" : "X\\(.*\\)$as_nl";
48875         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
48876       esac;
48877       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
48878     '
48879     export as_echo_n_body
48880     as_echo_n='sh -c $as_echo_n_body as_echo'
48881   fi
48882   export as_echo_body
48883   as_echo='sh -c $as_echo_body as_echo'
48884 fi
48885 
48886 # The user is always right.
48887 if test "${PATH_SEPARATOR+set}" != set; then
48888   PATH_SEPARATOR=:
48889   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
48890     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
48891       PATH_SEPARATOR=';'
48892   }
48893 fi
48894 
48895 
48896 # IFS
48897 # We need space, tab and new line, in precisely that order.  Quoting is
48898 # there to prevent editors from complaining about space-tab.
48899 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
48900 # splitting by setting IFS to empty value.)
48901 IFS=" ""        $as_nl"
48902 
48903 # Find who we are.  Look in the path if we contain no directory separator.
48904 as_myself=
48905 case $0 in #((
48906   *[\\/]* ) as_myself=$0 ;;
48907   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48908 for as_dir in $PATH
48909 do
48910   IFS=$as_save_IFS
48911   test -z "$as_dir" && as_dir=.
48912     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
48913   done
48914 IFS=$as_save_IFS
48915 
48916      ;;
48917 esac
48918 # We did not find ourselves, most probably we were run as `sh COMMAND'
48919 # in which case we are not to be found in the path.
48920 if test "x$as_myself" = x; then
48921   as_myself=$0
48922 fi
48923 if test ! -f "$as_myself"; then
48924   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
48925   exit 1
48926 fi
48927 
48928 # Unset variables that we do not need and which cause bugs (e.g. in
48929 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
48930 # suppresses any "Segmentation fault" message there.  '((' could
48931 # trigger a bug in pdksh 5.2.14.
48932 for as_var in BASH_ENV ENV MAIL MAILPATH
48933 do eval test x\${$as_var+set} = xset \
48934   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
48935 done
48936 PS1='$ '
48937 PS2='> '
48938 PS4='+ '
48939 
48940 # NLS nuisances.
48941 LC_ALL=C
48942 export LC_ALL
48943 LANGUAGE=C
48944 export LANGUAGE
48945 
48946 # CDPATH.
48947 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
48948 
48949 
48950 # as_fn_error STATUS ERROR [LINENO LOG_FD]
48951 # ----------------------------------------
48952 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
48953 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
48954 # script with STATUS, using 1 if that was 0.
48955 as_fn_error ()
48956 {
48957   as_status=$1; test $as_status -eq 0 && as_status=1
48958   if test "$4"; then
48959     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
48960     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
48961   fi
48962   $as_echo "$as_me: error: $2" >&2
48963   as_fn_exit $as_status
48964 } # as_fn_error
48965 
48966 
48967 # as_fn_set_status STATUS
48968 # -----------------------
48969 # Set $? to STATUS, without forking.
48970 as_fn_set_status ()
48971 {
48972   return $1
48973 } # as_fn_set_status
48974 
48975 # as_fn_exit STATUS
48976 # -----------------
48977 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
48978 as_fn_exit ()
48979 {
48980   set +e
48981   as_fn_set_status $1
48982   exit $1
48983 } # as_fn_exit
48984 
48985 # as_fn_unset VAR
48986 # ---------------
48987 # Portably unset VAR.
48988 as_fn_unset ()
48989 {
48990   { eval $1=; unset $1;}
48991 }
48992 as_unset=as_fn_unset
48993 # as_fn_append VAR VALUE
48994 # ----------------------
48995 # Append the text in VALUE to the end of the definition contained in VAR. Take
48996 # advantage of any shell optimizations that allow amortized linear growth over
48997 # repeated appends, instead of the typical quadratic growth present in naive
48998 # implementations.
48999 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
49000   eval 'as_fn_append ()
49001   {
49002     eval $1+=\$2
49003   }'
49004 else
49005   as_fn_append ()
49006   {
49007     eval $1=\$$1\$2
49008   }
49009 fi # as_fn_append
49010 
49011 # as_fn_arith ARG...
49012 # ------------------
49013 # Perform arithmetic evaluation on the ARGs, and store the result in the
49014 # global $as_val. Take advantage of shells that can avoid forks. The arguments
49015 # must be portable across $(()) and expr.
49016 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
49017   eval 'as_fn_arith ()
49018   {
49019     as_val=$(( $* ))
49020   }'
49021 else
49022   as_fn_arith ()
49023   {
49024     as_val=`expr "$@" || test $? -eq 1`
49025   }
49026 fi # as_fn_arith
49027 
49028 
49029 if expr a : '\(a\)' >/dev/null 2>&1 &&
49030    test "X`expr 00001 : '.*\(...\)'`" = X001; then
49031   as_expr=expr
49032 else
49033   as_expr=false
49034 fi
49035 
49036 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
49037   as_basename=basename
49038 else
49039   as_basename=false
49040 fi
49041 
49042 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
49043   as_dirname=dirname
49044 else
49045   as_dirname=false
49046 fi
49047 
49048 as_me=`$as_basename -- "$0" ||
49049 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
49050          X"$0" : 'X\(//\)$' \| \
49051          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
49052 $as_echo X/"$0" |
49053     sed '/^.*\/\([^/][^/]*\)\/*$/{
49054             s//\1/
49055             q
49056           }
49057           /^X\/\(\/\/\)$/{
49058             s//\1/
49059             q
49060           }
49061           /^X\/\(\/\).*/{
49062             s//\1/
49063             q
49064           }
49065           s/.*/./; q'`
49066 
49067 # Avoid depending upon Character Ranges.
49068 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
49069 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
49070 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
49071 as_cr_digits='0123456789'
49072 as_cr_alnum=$as_cr_Letters$as_cr_digits
49073 
49074 ECHO_C= ECHO_N= ECHO_T=
49075 case `echo -n x` in #(((((
49076 -n*)
49077   case `echo 'xy\c'` in
49078   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
49079   xy)  ECHO_C='\c';;
49080   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
49081        ECHO_T=' ';;
49082   esac;;
49083 *)
49084   ECHO_N='-n';;
49085 esac
49086 
49087 rm -f conf$$ conf$$.exe conf$$.file
49088 if test -d conf$$.dir; then
49089   rm -f conf$$.dir/conf$$.file
49090 else
49091   rm -f conf$$.dir
49092   mkdir conf$$.dir 2>/dev/null
49093 fi
49094 if (echo >conf$$.file) 2>/dev/null; then
49095   if ln -s conf$$.file conf$$ 2>/dev/null; then
49096     as_ln_s='ln -s'
49097     # ... but there are two gotchas:
49098     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
49099     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
49100     # In both cases, we have to default to `cp -pR'.
49101     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
49102       as_ln_s='cp -pR'
49103   elif ln conf$$.file conf$$ 2>/dev/null; then
49104     as_ln_s=ln
49105   else
49106     as_ln_s='cp -pR'
49107   fi
49108 else
49109   as_ln_s='cp -pR'
49110 fi
49111 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
49112 rmdir conf$$.dir 2>/dev/null
49113 
49114 
49115 # as_fn_mkdir_p
49116 # -------------
49117 # Create "$as_dir" as a directory, including parents if necessary.
49118 as_fn_mkdir_p ()
49119 {
49120 
49121   case $as_dir in #(
49122   -*) as_dir=./$as_dir;;
49123   esac
49124   test -d "$as_dir" || eval $as_mkdir_p || {
49125     as_dirs=
49126     while :; do
49127       case $as_dir in #(
49128       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
49129       *) as_qdir=$as_dir;;
49130       esac
49131       as_dirs="'$as_qdir' $as_dirs"
49132       as_dir=`$as_dirname -- "$as_dir" ||
49133 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49134          X"$as_dir" : 'X\(//\)[^/]' \| \
49135          X"$as_dir" : 'X\(//\)$' \| \
49136          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
49137 $as_echo X"$as_dir" |
49138     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49139             s//\1/
49140             q
49141           }
49142           /^X\(\/\/\)[^/].*/{
49143             s//\1/
49144             q
49145           }
49146           /^X\(\/\/\)$/{
49147             s//\1/
49148             q
49149           }
49150           /^X\(\/\).*/{
49151             s//\1/
49152             q
49153           }
49154           s/.*/./; q'`
49155       test -d "$as_dir" && break
49156     done
49157     test -z "$as_dirs" || eval "mkdir $as_dirs"
49158   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
49159 
49160 
49161 } # as_fn_mkdir_p
49162 if mkdir -p . 2>/dev/null; then
49163   as_mkdir_p='mkdir -p "$as_dir"'
49164 else
49165   test -d ./-p && rmdir ./-p
49166   as_mkdir_p=false
49167 fi
49168 
49169 
49170 # as_fn_executable_p FILE
49171 # -----------------------
49172 # Test if FILE is an executable regular file.
49173 as_fn_executable_p ()
49174 {
49175   test -f "$1" && test -x "$1"
49176 } # as_fn_executable_p
49177 as_test_x='test -x'
49178 as_executable_p=as_fn_executable_p
49179 
49180 # Sed expression to map a string onto a valid CPP name.
49181 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
49182 
49183 # Sed expression to map a string onto a valid variable name.
49184 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
49185 
49186 
49187 exec 6>&1
49188 ## ----------------------------------- ##
49189 ## Main body of $CONFIG_STATUS script. ##
49190 ## ----------------------------------- ##
49191 _ASEOF
49192 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
49193 
49194 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49195 # Save the log message, to keep $0 and so on meaningful, and to
49196 # report actual input values of CONFIG_FILES etc. instead of their
49197 # values after options handling.
49198 ac_log="
49199 This file was extended by OpenJDK $as_me jdk8, which was
49200 generated by GNU Autoconf 2.69.  Invocation command line was
49201 
49202   CONFIG_FILES    = $CONFIG_FILES
49203   CONFIG_HEADERS  = $CONFIG_HEADERS
49204   CONFIG_LINKS    = $CONFIG_LINKS
49205   CONFIG_COMMANDS = $CONFIG_COMMANDS
49206   $ $0 $@
49207 
49208 on `(hostname || uname -n) 2>/dev/null | sed 1q`
49209 "
49210 
49211 _ACEOF
49212 
49213 case $ac_config_files in *"
49214 "*) set x $ac_config_files; shift; ac_config_files=$*;;
49215 esac
49216 
49217 case $ac_config_headers in *"
49218 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
49219 esac
49220 
49221 
49222 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49223 # Files that config.status was made for.
49224 config_files="$ac_config_files"
49225 config_headers="$ac_config_headers"
49226 
49227 _ACEOF
49228 
49229 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49230 ac_cs_usage="\
49231 \`$as_me' instantiates files and other configuration actions
49232 from templates according to the current configuration.  Unless the files
49233 and actions are specified as TAGs, all are instantiated by default.
49234 
49235 Usage: $0 [OPTION]... [TAG]...
49236 
49237   -h, --help       print this help, then exit
49238   -V, --version    print version number and configuration settings, then exit
49239       --config     print configuration, then exit
49240   -q, --quiet, --silent
49241                    do not print progress messages
49242   -d, --debug      don't remove temporary files
49243       --recheck    update $as_me by reconfiguring in the same conditions
49244       --file=FILE[:TEMPLATE]
49245                    instantiate the configuration file FILE
49246       --header=FILE[:TEMPLATE]
49247                    instantiate the configuration header FILE
49248 
49249 Configuration files:
49250 $config_files
49251 
49252 Configuration headers:
49253 $config_headers
49254 
49255 Report bugs to <build-dev@openjdk.java.net>.
49256 OpenJDK home page: <http://openjdk.java.net>."
49257 
49258 _ACEOF
49259 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49260 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
49261 ac_cs_version="\\
49262 OpenJDK config.status jdk8
49263 configured by $0, generated by GNU Autoconf 2.69,
49264   with options \\"\$ac_cs_config\\"
49265 
49266 Copyright (C) 2012 Free Software Foundation, Inc.
49267 This config.status script is free software; the Free Software Foundation
49268 gives unlimited permission to copy, distribute and modify it."
49269 
49270 ac_pwd='$ac_pwd'
49271 srcdir='$srcdir'
49272 AWK='$AWK'
49273 test -n "\$AWK" || AWK=awk
49274 _ACEOF
49275 
49276 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49277 # The default lists apply if the user does not specify any file.
49278 ac_need_defaults=:
49279 while test $# != 0
49280 do
49281   case $1 in
49282   --*=?*)
49283     ac_option=`expr "X$1" : 'X\([^=]*\)='`
49284     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
49285     ac_shift=:
49286     ;;
49287   --*=)
49288     ac_option=`expr "X$1" : 'X\([^=]*\)='`
49289     ac_optarg=
49290     ac_shift=:
49291     ;;
49292   *)
49293     ac_option=$1
49294     ac_optarg=$2
49295     ac_shift=shift
49296     ;;
49297   esac
49298 
49299   case $ac_option in
49300   # Handling of the options.
49301   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
49302     ac_cs_recheck=: ;;
49303   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
49304     $as_echo "$ac_cs_version"; exit ;;
49305   --config | --confi | --conf | --con | --co | --c )
49306     $as_echo "$ac_cs_config"; exit ;;
49307   --debug | --debu | --deb | --de | --d | -d )
49308     debug=: ;;
49309   --file | --fil | --fi | --f )
49310     $ac_shift
49311     case $ac_optarg in
49312     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49313     '') as_fn_error $? "missing file argument" ;;
49314     esac
49315     as_fn_append CONFIG_FILES " '$ac_optarg'"
49316     ac_need_defaults=false;;
49317   --header | --heade | --head | --hea )
49318     $ac_shift
49319     case $ac_optarg in
49320     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49321     esac
49322     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
49323     ac_need_defaults=false;;
49324   --he | --h)
49325     # Conflict between --help and --header
49326     as_fn_error $? "ambiguous option: \`$1'
49327 Try \`$0 --help' for more information.";;
49328   --help | --hel | -h )
49329     $as_echo "$ac_cs_usage"; exit ;;
49330   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
49331   | -silent | --silent | --silen | --sile | --sil | --si | --s)
49332     ac_cs_silent=: ;;
49333 
49334   # This is an error.
49335   -*) as_fn_error $? "unrecognized option: \`$1'
49336 Try \`$0 --help' for more information." ;;
49337 
49338   *) as_fn_append ac_config_targets " $1"
49339      ac_need_defaults=false ;;
49340 
49341   esac
49342   shift
49343 done
49344 
49345 ac_configure_extra_args=
49346 
49347 if $ac_cs_silent; then
49348   exec 6>/dev/null
49349   ac_configure_extra_args="$ac_configure_extra_args --silent"
49350 fi
49351 
49352 _ACEOF
49353 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49354 if \$ac_cs_recheck; then
49355   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
49356   shift
49357   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
49358   CONFIG_SHELL='$SHELL'
49359   export CONFIG_SHELL
49360   exec "\$@"
49361 fi
49362 
49363 _ACEOF
49364 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49365 exec 5>>config.log
49366 {
49367   echo
49368   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
49369 ## Running $as_me. ##
49370 _ASBOX
49371   $as_echo "$ac_log"
49372 } >&5
49373 
49374 _ACEOF
49375 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49376 _ACEOF
49377 
49378 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49379 
49380 # Handling of arguments.
49381 for ac_config_target in $ac_config_targets
49382 do
49383   case $ac_config_target in
49384     "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;;
49385     "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
49386     "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
49387     "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
49388     "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
49389     "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;;
49390     "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
49391 
49392   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
49393   esac
49394 done
49395 
49396 
49397 # If the user did not use the arguments to specify the items to instantiate,
49398 # then the envvar interface is used.  Set only those that are not.
49399 # We use the long form for the default assignment because of an extremely
49400 # bizarre bug on SunOS 4.1.3.
49401 if $ac_need_defaults; then
49402   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
49403   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
49404 fi
49405 
49406 # Have a temporary directory for convenience.  Make it in the build tree
49407 # simply because there is no reason against having it here, and in addition,
49408 # creating and moving files from /tmp can sometimes cause problems.
49409 # Hook for its removal unless debugging.
49410 # Note that there is a small window in which the directory will not be cleaned:
49411 # after its creation but before its name has been assigned to `$tmp'.
49412 $debug ||
49413 {
49414   tmp= ac_tmp=
49415   trap 'exit_status=$?
49416   : "${ac_tmp:=$tmp}"
49417   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
49418 ' 0
49419   trap 'as_fn_exit 1' 1 2 13 15
49420 }
49421 # Create a (secure) tmp directory for tmp files.
49422 
49423 {
49424   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
49425   test -d "$tmp"
49426 }  ||
49427 {
49428   tmp=./conf$$-$RANDOM
49429   (umask 077 && mkdir "$tmp")
49430 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
49431 ac_tmp=$tmp
49432 
49433 # Set up the scripts for CONFIG_FILES section.
49434 # No need to generate them if there are no CONFIG_FILES.
49435 # This happens for instance with `./config.status config.h'.
49436 if test -n "$CONFIG_FILES"; then
49437 
49438 
49439 ac_cr=`echo X | tr X '\015'`
49440 # On cygwin, bash can eat \r inside `` if the user requested igncr.
49441 # But we know of no other shell where ac_cr would be empty at this
49442 # point, so we can use a bashism as a fallback.
49443 if test "x$ac_cr" = x; then
49444   eval ac_cr=\$\'\\r\'
49445 fi
49446 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
49447 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
49448   ac_cs_awk_cr='\\r'
49449 else
49450   ac_cs_awk_cr=$ac_cr
49451 fi
49452 
49453 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
49454 _ACEOF
49455 
49456 
49457 {
49458   echo "cat >conf$$subs.awk <<_ACEOF" &&
49459   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
49460   echo "_ACEOF"
49461 } >conf$$subs.sh ||
49462   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49463 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
49464 ac_delim='%!_!# '
49465 for ac_last_try in false false false false false :; do
49466   . ./conf$$subs.sh ||
49467     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49468 
49469   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
49470   if test $ac_delim_n = $ac_delim_num; then
49471     break
49472   elif $ac_last_try; then
49473     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49474   else
49475     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49476   fi
49477 done
49478 rm -f conf$$subs.sh
49479 
49480 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49481 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
49482 _ACEOF
49483 sed -n '
49484 h
49485 s/^/S["/; s/!.*/"]=/
49486 p
49487 g
49488 s/^[^!]*!//
49489 :repl
49490 t repl
49491 s/'"$ac_delim"'$//
49492 t delim
49493 :nl
49494 h
49495 s/\(.\{148\}\)..*/\1/
49496 t more1
49497 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
49498 p
49499 n
49500 b repl
49501 :more1
49502 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49503 p
49504 g
49505 s/.\{148\}//
49506 t nl
49507 :delim
49508 h
49509 s/\(.\{148\}\)..*/\1/
49510 t more2
49511 s/["\\]/\\&/g; s/^/"/; s/$/"/
49512 p
49513 b
49514 :more2
49515 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49516 p
49517 g
49518 s/.\{148\}//
49519 t delim
49520 ' <conf$$subs.awk | sed '
49521 /^[^""]/{
49522   N
49523   s/\n//
49524 }
49525 ' >>$CONFIG_STATUS || ac_write_fail=1
49526 rm -f conf$$subs.awk
49527 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49528 _ACAWK
49529 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
49530   for (key in S) S_is_set[key] = 1
49531   FS = ""
49532 
49533 }
49534 {
49535   line = $ 0
49536   nfields = split(line, field, "@")
49537   substed = 0
49538   len = length(field[1])
49539   for (i = 2; i < nfields; i++) {
49540     key = field[i]
49541     keylen = length(key)
49542     if (S_is_set[key]) {
49543       value = S[key]
49544       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
49545       len += length(value) + length(field[++i])
49546       substed = 1
49547     } else
49548       len += 1 + keylen
49549   }
49550 
49551   print line
49552 }
49553 
49554 _ACAWK
49555 _ACEOF
49556 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49557 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
49558   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
49559 else
49560   cat
49561 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
49562   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
49563 _ACEOF
49564 
49565 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
49566 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
49567 # trailing colons and then remove the whole line if VPATH becomes empty
49568 # (actually we leave an empty line to preserve line numbers).
49569 if test "x$srcdir" = x.; then
49570   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
49571 h
49572 s///
49573 s/^/:/
49574 s/[      ]*$/:/
49575 s/:\$(srcdir):/:/g
49576 s/:\${srcdir}:/:/g
49577 s/:@srcdir@:/:/g
49578 s/^:*//
49579 s/:*$//
49580 x
49581 s/\(=[   ]*\).*/\1/
49582 G
49583 s/\n//
49584 s/^[^=]*=[       ]*$//
49585 }'
49586 fi
49587 
49588 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49589 fi # test -n "$CONFIG_FILES"
49590 
49591 # Set up the scripts for CONFIG_HEADERS section.
49592 # No need to generate them if there are no CONFIG_HEADERS.
49593 # This happens for instance with `./config.status Makefile'.
49594 if test -n "$CONFIG_HEADERS"; then
49595 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
49596 BEGIN {
49597 _ACEOF
49598 
49599 # Transform confdefs.h into an awk script `defines.awk', embedded as
49600 # here-document in config.status, that substitutes the proper values into
49601 # config.h.in to produce config.h.
49602 
49603 # Create a delimiter string that does not exist in confdefs.h, to ease
49604 # handling of long lines.
49605 ac_delim='%!_!# '
49606 for ac_last_try in false false :; do
49607   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
49608   if test -z "$ac_tt"; then
49609     break
49610   elif $ac_last_try; then
49611     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
49612   else
49613     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49614   fi
49615 done
49616 
49617 # For the awk script, D is an array of macro values keyed by name,
49618 # likewise P contains macro parameters if any.  Preserve backslash
49619 # newline sequences.
49620 
49621 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
49622 sed -n '
49623 s/.\{148\}/&'"$ac_delim"'/g
49624 t rset
49625 :rset
49626 s/^[     ]*#[    ]*define[       ][      ]*/ /
49627 t def
49628 d
49629 :def
49630 s/\\$//
49631 t bsnl
49632 s/["\\]/\\&/g
49633 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
49634 D["\1"]=" \3"/p
49635 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
49636 d
49637 :bsnl
49638 s/["\\]/\\&/g
49639 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
49640 D["\1"]=" \3\\\\\\n"\\/p
49641 t cont
49642 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
49643 t cont
49644 d
49645 :cont
49646 n
49647 s/.\{148\}/&'"$ac_delim"'/g
49648 t clear
49649 :clear
49650 s/\\$//
49651 t bsnlc
49652 s/["\\]/\\&/g; s/^/"/; s/$/"/p
49653 d
49654 :bsnlc
49655 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
49656 b cont
49657 ' <confdefs.h | sed '
49658 s/'"$ac_delim"'/"\\\
49659 "/g' >>$CONFIG_STATUS || ac_write_fail=1
49660 
49661 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49662   for (key in D) D_is_set[key] = 1
49663   FS = ""
49664 }
49665 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
49666   line = \$ 0
49667   split(line, arg, " ")
49668   if (arg[1] == "#") {
49669     defundef = arg[2]
49670     mac1 = arg[3]
49671   } else {
49672     defundef = substr(arg[1], 2)
49673     mac1 = arg[2]
49674   }
49675   split(mac1, mac2, "(") #)
49676   macro = mac2[1]
49677   prefix = substr(line, 1, index(line, defundef) - 1)
49678   if (D_is_set[macro]) {
49679     # Preserve the white space surrounding the "#".
49680     print prefix "define", macro P[macro] D[macro]
49681     next
49682   } else {
49683     # Replace #undef with comments.  This is necessary, for example,
49684     # in the case of _POSIX_SOURCE, which is predefined and required
49685     # on some systems where configure will not decide to define it.
49686     if (defundef == "undef") {
49687       print "/*", prefix defundef, macro, "*/"
49688       next
49689     }
49690   }
49691 }
49692 { print }
49693 _ACAWK
49694 _ACEOF
49695 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49696   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
49697 fi # test -n "$CONFIG_HEADERS"
49698 
49699 
49700 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
49701 shift
49702 for ac_tag
49703 do
49704   case $ac_tag in
49705   :[FHLC]) ac_mode=$ac_tag; continue;;
49706   esac
49707   case $ac_mode$ac_tag in
49708   :[FHL]*:*);;
49709   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
49710   :[FH]-) ac_tag=-:-;;
49711   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
49712   esac
49713   ac_save_IFS=$IFS
49714   IFS=:
49715   set x $ac_tag
49716   IFS=$ac_save_IFS
49717   shift
49718   ac_file=$1
49719   shift
49720 
49721   case $ac_mode in
49722   :L) ac_source=$1;;
49723   :[FH])
49724     ac_file_inputs=
49725     for ac_f
49726     do
49727       case $ac_f in
49728       -) ac_f="$ac_tmp/stdin";;
49729       *) # Look for the file first in the build tree, then in the source tree
49730          # (if the path is not absolute).  The absolute path cannot be DOS-style,
49731          # because $ac_f cannot contain `:'.
49732          test -f "$ac_f" ||
49733            case $ac_f in
49734            [\\/$]*) false;;
49735            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
49736            esac ||
49737            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
49738       esac
49739       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
49740       as_fn_append ac_file_inputs " '$ac_f'"
49741     done
49742 
49743     # Let's still pretend it is `configure' which instantiates (i.e., don't
49744     # use $as_me), people would be surprised to read:
49745     #    /* config.h.  Generated by config.status.  */
49746     configure_input='Generated from '`
49747           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
49748         `' by configure.'
49749     if test x"$ac_file" != x-; then
49750       configure_input="$ac_file.  $configure_input"
49751       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
49752 $as_echo "$as_me: creating $ac_file" >&6;}
49753     fi
49754     # Neutralize special characters interpreted by sed in replacement strings.
49755     case $configure_input in #(
49756     *\&* | *\|* | *\\* )
49757        ac_sed_conf_input=`$as_echo "$configure_input" |
49758        sed 's/[\\\\&|]/\\\\&/g'`;; #(
49759     *) ac_sed_conf_input=$configure_input;;
49760     esac
49761 
49762     case $ac_tag in
49763     *:-:* | *:-) cat >"$ac_tmp/stdin" \
49764       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
49765     esac
49766     ;;
49767   esac
49768 
49769   ac_dir=`$as_dirname -- "$ac_file" ||
49770 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49771          X"$ac_file" : 'X\(//\)[^/]' \| \
49772          X"$ac_file" : 'X\(//\)$' \| \
49773          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
49774 $as_echo X"$ac_file" |
49775     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49776             s//\1/
49777             q
49778           }
49779           /^X\(\/\/\)[^/].*/{
49780             s//\1/
49781             q
49782           }
49783           /^X\(\/\/\)$/{
49784             s//\1/
49785             q
49786           }
49787           /^X\(\/\).*/{
49788             s//\1/
49789             q
49790           }
49791           s/.*/./; q'`
49792   as_dir="$ac_dir"; as_fn_mkdir_p
49793   ac_builddir=.
49794 
49795 case "$ac_dir" in
49796 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
49797 *)
49798   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
49799   # A ".." for each directory in $ac_dir_suffix.
49800   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
49801   case $ac_top_builddir_sub in
49802   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
49803   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
49804   esac ;;
49805 esac
49806 ac_abs_top_builddir=$ac_pwd
49807 ac_abs_builddir=$ac_pwd$ac_dir_suffix
49808 # for backward compatibility:
49809 ac_top_builddir=$ac_top_build_prefix
49810 
49811 case $srcdir in
49812   .)  # We are building in place.
49813     ac_srcdir=.
49814     ac_top_srcdir=$ac_top_builddir_sub
49815     ac_abs_top_srcdir=$ac_pwd ;;
49816   [\\/]* | ?:[\\/]* )  # Absolute name.
49817     ac_srcdir=$srcdir$ac_dir_suffix;
49818     ac_top_srcdir=$srcdir
49819     ac_abs_top_srcdir=$srcdir ;;
49820   *) # Relative name.
49821     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
49822     ac_top_srcdir=$ac_top_build_prefix$srcdir
49823     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
49824 esac
49825 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
49826 
49827 
49828   case $ac_mode in
49829   :F)
49830   #
49831   # CONFIG_FILE
49832   #
49833 
49834 _ACEOF
49835 
49836 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49837 # If the template does not know about datarootdir, expand it.
49838 # FIXME: This hack should be removed a few years after 2.60.
49839 ac_datarootdir_hack=; ac_datarootdir_seen=
49840 ac_sed_dataroot='
49841 /datarootdir/ {
49842   p
49843   q
49844 }
49845 /@datadir@/p
49846 /@docdir@/p
49847 /@infodir@/p
49848 /@localedir@/p
49849 /@mandir@/p'
49850 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
49851 *datarootdir*) ac_datarootdir_seen=yes;;
49852 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
49853   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
49854 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
49855 _ACEOF
49856 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49857   ac_datarootdir_hack='
49858   s&@datadir@&$datadir&g
49859   s&@docdir@&$docdir&g
49860   s&@infodir@&$infodir&g
49861   s&@localedir@&$localedir&g
49862   s&@mandir@&$mandir&g
49863   s&\\\${datarootdir}&$datarootdir&g' ;;
49864 esac
49865 _ACEOF
49866 
49867 # Neutralize VPATH when `$srcdir' = `.'.
49868 # Shell code in configure.ac might set extrasub.
49869 # FIXME: do we really want to maintain this feature?
49870 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49871 ac_sed_extra="$ac_vpsub
49872 $extrasub
49873 _ACEOF
49874 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49875 :t
49876 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
49877 s|@configure_input@|$ac_sed_conf_input|;t t
49878 s&@top_builddir@&$ac_top_builddir_sub&;t t
49879 s&@top_build_prefix@&$ac_top_build_prefix&;t t
49880 s&@srcdir@&$ac_srcdir&;t t
49881 s&@abs_srcdir@&$ac_abs_srcdir&;t t
49882 s&@top_srcdir@&$ac_top_srcdir&;t t
49883 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
49884 s&@builddir@&$ac_builddir&;t t
49885 s&@abs_builddir@&$ac_abs_builddir&;t t
49886 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
49887 $ac_datarootdir_hack
49888 "
49889 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
49890   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49891 
49892 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
49893   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
49894   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
49895       "$ac_tmp/out"`; test -z "$ac_out"; } &&
49896   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49897 which seems to be undefined.  Please make sure it is defined" >&5
49898 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49899 which seems to be undefined.  Please make sure it is defined" >&2;}
49900 
49901   rm -f "$ac_tmp/stdin"
49902   case $ac_file in
49903   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
49904   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
49905   esac \
49906   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49907  ;;
49908   :H)
49909   #
49910   # CONFIG_HEADER
49911   #
49912   if test x"$ac_file" != x-; then
49913     {
49914       $as_echo "/* $configure_input  */" \
49915       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
49916     } >"$ac_tmp/config.h" \
49917       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49918     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
49919       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
49920 $as_echo "$as_me: $ac_file is unchanged" >&6;}
49921     else
49922       rm -f "$ac_file"
49923       mv "$ac_tmp/config.h" "$ac_file" \
49924         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49925     fi
49926   else
49927     $as_echo "/* $configure_input  */" \
49928       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
49929       || as_fn_error $? "could not create -" "$LINENO" 5
49930   fi
49931  ;;
49932 
49933 
49934   esac
49935 
49936 done # for ac_tag
49937 
49938 
49939 as_fn_exit 0
49940 _ACEOF
49941 ac_clean_files=$ac_clean_files_save
49942 
49943 test $ac_write_fail = 0 ||
49944   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
49945 
49946 
49947 # configure is writing to config.log, and then calls config.status.
49948 # config.status does its own redirection, appending to config.log.
49949 # Unfortunately, on DOS this fails, as config.log is still kept open
49950 # by configure, so config.status won't be able to write to it; its
49951 # output is simply discarded.  So we exec the FD to /dev/null,
49952 # effectively closing config.log, so it can be properly (re)opened and
49953 # appended to by config.status.  When coming back to configure, we
49954 # need to make the FD available again.
49955 if test "$no_create" != yes; then
49956   ac_cs_success=:
49957   ac_config_status_args=
49958   test "$silent" = yes &&
49959     ac_config_status_args="$ac_config_status_args --quiet"
49960   exec 5>/dev/null
49961   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
49962   exec 5>>config.log
49963   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
49964   # would make configure fail if this is the last instruction.
49965   $ac_cs_success || as_fn_exit 1
49966 fi
49967 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
49968   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
49969 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
49970 fi
49971 
49972 
49973 # Try to move the config.log file to the output directory.
49974 if test -e ./config.log; then
49975   $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
49976 fi
49977 
49978 # Make the compare script executable
49979 $CHMOD +x $OUTPUT_ROOT/compare.sh
49980 
49981 # Finally output some useful information to the user
49982 
49983   # Finally output some useful information to the user
49984 
49985   printf "\n"
49986   printf "====================================================\n"
49987   if test "x$no_create" != "xyes"; then
49988     if test "x$IS_RECONFIGURE" != "xyes"; then
49989       printf "A new configuration has been successfully created in\n %s\n" "$OUTPUT_ROOT"
49990     else
49991       printf "The existing configuration has been successfully updated in\n %s\n" "$OUTPUT_ROOT"
49992     fi
49993   else
49994     if test "x$IS_RECONFIGURE" != "xyes"; then
49995       printf "A configuration has been successfully checked but not created\n"
49996     else
49997       printf "The existing configuration has been successfully checked in\n %s\n" "$OUTPUT_ROOT"
49998     fi
49999   fi
50000   if test "x$CONFIGURE_COMMAND_LINE" != x; then
50001     printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
50002   else
50003     printf "using default settings.\n"
50004   fi
50005 
50006   printf "\n"
50007   printf "Configuration summary:\n"
50008   printf "* Debug level:    $DEBUG_LEVEL\n"
50009   printf "* JDK variant:    $JDK_VARIANT\n"
50010   printf "* JVM variants:   $with_jvm_variants\n"
50011   printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
50012 
50013   printf "\n"
50014   printf "Tools summary:\n"
50015   if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
50016     printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
50017   fi
50018   printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
50019   printf "* Toolchain:      $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)\n"
50020   printf "* C Compiler:     Version $CC_VERSION_NUMBER (at $CC)\n"
50021   printf "* C++ Compiler:   Version $CXX_VERSION_NUMBER (at $CXX)\n"
50022 
50023   printf "\n"
50024   printf "Build performance summary:\n"
50025   printf "* Cores to use:   $JOBS\n"
50026   printf "* Memory limit:   $MEMORY_SIZE MB\n"
50027   if test "x$CCACHE_STATUS" != "x"; then
50028     printf "* ccache status:  $CCACHE_STATUS\n"
50029   fi
50030   printf "\n"
50031 
50032   if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
50033     printf "NOTE: You have requested to build more than one version of the JVM, which\n"
50034     printf "will result in longer build times.\n"
50035     printf "\n"
50036   fi
50037 
50038   if test "x$FOUND_ALT_VARIABLES" != "x"; then
50039     printf "WARNING: You have old-style ALT_ environment variables set.\n"
50040     printf "These are not respected, and will be ignored. It is recommended\n"
50041     printf "that you clean your environment. The following variables are set:\n"
50042     printf "$FOUND_ALT_VARIABLES\n"
50043     printf "\n"
50044   fi
50045 
50046   if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
50047     printf "WARNING: Your build output directory is not on a local disk.\n"
50048     printf "This will severely degrade build performance!\n"
50049     printf "It is recommended that you create an output directory on a local disk,\n"
50050     printf "and run the configure script again from that directory.\n"
50051     printf "\n"
50052   fi
50053 
50054   if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
50055     printf "WARNING: The result of this configuration has overridden an older\n"
50056     printf "configuration. You *should* run 'make clean' to make sure you get a\n"
50057     printf "proper build. Failure to do so might result in strange build problems.\n"
50058     printf "\n"
50059   fi
50060 
50061   if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
50062     printf "WARNING: The result of this configuration was not saved.\n"
50063     printf "You should run without '--no-create | -n' to create the configuration.\n"
50064     printf "\n"
50065   fi
50066