generated-configure.sh revision 1009:f16ec21040c5
1#!/bin/bash
2#
3# ##########################################################
4# ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ###
5# ##########################################################
6#
7#! /bin/sh
8# Guess values for system-dependent variables and create Makefiles.
9# Generated by GNU Autoconf 2.69 for OpenJDK jdk9.
10#
11# Report bugs to <build-dev@openjdk.java.net>.
12#
13#
14# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
15#
16#
17# This configure script is free software; the Free Software Foundation
18# gives unlimited permission to copy, distribute and modify it.
19## -------------------- ##
20## M4sh Initialization. ##
21## -------------------- ##
22
23# Be more Bourne compatible
24DUALCASE=1; export DUALCASE # for MKS sh
25if 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
32else
33  case `(set -o) 2>/dev/null` in #(
34  *posix*) :
35    set -o posix ;; #(
36  *) :
37     ;;
38esac
39fi
40
41
42as_nl='
43'
44export as_nl
45# Printing a long string crashes Solaris 7 /usr/bin/printf.
46as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
47as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
48as_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.
51if 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 --'
55elif (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'
58else
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'
78fi
79
80# The user is always right.
81if 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  }
87fi
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.)
95IFS=" ""	$as_nl"
96
97# Find who we are.  Look in the path if we contain no directory separator.
98as_myself=
99case $0 in #((
100  *[\\/]* ) as_myself=$0 ;;
101  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
102for as_dir in $PATH
103do
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
108IFS=$as_save_IFS
109
110     ;;
111esac
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.
114if test "x$as_myself" = x; then
115  as_myself=$0
116fi
117if test ! -f "$as_myself"; then
118  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
119  exit 1
120fi
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.
126for as_var in BASH_ENV ENV MAIL MAILPATH
127do eval test x\${$as_var+set} = xset \
128  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
129done
130PS1='$ '
131PS2='> '
132PS4='+ '
133
134# NLS nuisances.
135LC_ALL=C
136export LC_ALL
137LANGUAGE=C
138export 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.
151BASH_ENV=/dev/null
152ENV=/dev/null
153(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
154case $- in # ((((
155  *v*x* | *x*v* ) as_opts=-vx ;;
156  *v* ) as_opts=-v ;;
157  *x* ) as_opts=-x ;;
158  * ) as_opts= ;;
159esac
160exec $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
164as_fn_exit 255
165  fi
166  # We don't want this to propagate to other subprocesses.
167          { _as_can_reexec=; unset _as_can_reexec;}
168if 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
176else
177  case \`(set -o) 2>/dev/null\` in #(
178  *posix*) :
179    set -o posix ;; #(
180  *) :
181     ;;
182esac
183fi
184"
185  as_required="as_fn_return () { (exit \$1); }
186as_fn_success () { as_fn_return 0; }
187as_fn_failure () { as_fn_return 1; }
188as_fn_ret_success () { return 0; }
189as_fn_ret_failure () { return 1; }
190
191exitcode=0
192as_fn_success || { exitcode=1; echo as_fn_success failed.; }
193as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
194as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
195as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
196if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
197
198else
199  exitcode=1; echo positional parameters were not saved.
200fi
201test x\$exitcode = x0 || exit 1
202test -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
207test \$(( 1 + 1 )) = 2 || exit 1"
208  if (eval "$as_required") 2>/dev/null; then :
209  as_have_required=yes
210else
211  as_have_required=no
212fi
213  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
214
215else
216  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
217as_found=false
218for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
219do
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
233fi
234fi
235	   done;;
236       esac
237  as_found=false
238done
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
242fi; }
243IFS=$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.
252BASH_ENV=/dev/null
253ENV=/dev/null
254(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
255case $- in # ((((
256  *v*x* | *x*v* ) as_opts=-vx ;;
257  *v* ) as_opts=-v ;;
258  *x* ) as_opts=-x ;;
259  * ) as_opts= ;;
260esac
261exec $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
265exit 255
266fi
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
282fi
283fi
284fi
285SHELL=${CONFIG_SHELL-/bin/sh}
286export SHELL
287# Unset more variables known to interfere with behavior of common tools.
288CLICOLOR_FORCE= GREP_OPTIONS=
289unset CLICOLOR_FORCE GREP_OPTIONS
290
291## --------------------- ##
292## M4sh Shell Functions. ##
293## --------------------- ##
294# as_fn_unset VAR
295# ---------------
296# Portably unset VAR.
297as_fn_unset ()
298{
299  { eval $1=; unset $1;}
300}
301as_unset=as_fn_unset
302
303# as_fn_set_status STATUS
304# -----------------------
305# Set $? to STATUS, without forking.
306as_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.
314as_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.
324as_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.
372as_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.
382if (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  }'
387else
388  as_fn_append ()
389  {
390    eval $1=\$$1\$2
391  }
392fi # 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.
399if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
400  eval 'as_fn_arith ()
401  {
402    as_val=$(( $* ))
403  }'
404else
405  as_fn_arith ()
406  {
407    as_val=`expr "$@" || test $? -eq 1`
408  }
409fi # 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.
417as_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
428if expr a : '\(a\)' >/dev/null 2>&1 &&
429   test "X`expr 00001 : '.*\(...\)'`" = X001; then
430  as_expr=expr
431else
432  as_expr=false
433fi
434
435if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
436  as_basename=basename
437else
438  as_basename=false
439fi
440
441if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
442  as_dirname=dirname
443else
444  as_dirname=false
445fi
446
447as_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.
467as_cr_letters='abcdefghijklmnopqrstuvwxyz'
468as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
469as_cr_Letters=$as_cr_letters$as_cr_LETTERS
470as_cr_digits='0123456789'
471as_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
509ECHO_C= ECHO_N= ECHO_T=
510case `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';;
520esac
521
522rm -f conf$$ conf$$.exe conf$$.file
523if test -d conf$$.dir; then
524  rm -f conf$$.dir/conf$$.file
525else
526  rm -f conf$$.dir
527  mkdir conf$$.dir 2>/dev/null
528fi
529if (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
543else
544  as_ln_s='cp -pR'
545fi
546rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
547rmdir conf$$.dir 2>/dev/null
548
549if mkdir -p . 2>/dev/null; then
550  as_mkdir_p='mkdir -p "$as_dir"'
551else
552  test -d ./-p && rmdir ./-p
553  as_mkdir_p=false
554fi
555
556as_test_x='test -x'
557as_executable_p=as_fn_executable_p
558
559# Sed expression to map a string onto a valid CPP name.
560as_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.
563as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
564
565
566test -n "$DJDIR" || exec 7<&0 </dev/null
567exec 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.
572ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
573
574#
575# Initializations.
576#
577ac_default_prefix=/usr/local
578ac_clean_files=
579ac_config_libobj_dir=.
580LIBOBJS=
581cross_compiling=no
582subdirs=
583MFLAGS=
584MAKEFLAGS=
585
586# Identity of this package.
587PACKAGE_NAME='OpenJDK'
588PACKAGE_TARNAME='openjdk'
589PACKAGE_VERSION='jdk9'
590PACKAGE_STRING='OpenJDK jdk9'
591PACKAGE_BUGREPORT='build-dev@openjdk.java.net'
592PACKAGE_URL='http://openjdk.java.net'
593
594# Factoring default headers for most tests.
595ac_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
630ac_subst_vars='LTLIBOBJS
631LIBOBJS
632CCACHE
633USE_PRECOMPILED_HEADER
634SJAVAC_SERVER_DIR
635ENABLE_SJAVAC
636SJAVAC_SERVER_JAVA
637JOBS
638MEMORY_SIZE
639NUM_CORES
640ENABLE_INTREE_EC
641SALIB_NAME
642HOTSPOT_MAKE_ARGS
643MSVCR_DLL
644LIBCXX
645LLVM_LIBS
646LLVM_LDFLAGS
647LLVM_CFLAGS
648LLVM_CONFIG
649LIBFFI_LIBS
650LIBFFI_CFLAGS
651STATIC_CXX_SETTING
652LIBDL
653LIBM
654LIBZIP_CAN_USE_MMAP
655USE_EXTERNAL_LIBZ
656USE_EXTERNAL_LIBPNG
657PNG_LIBS
658PNG_CFLAGS
659USE_EXTERNAL_LIBGIF
660USE_EXTERNAL_LIBJPEG
661ALSA_LIBS
662ALSA_CFLAGS
663FREETYPE_BUNDLE_LIB_PATH
664FREETYPE_LIBS
665FREETYPE_CFLAGS
666CUPS_CFLAGS
667X_EXTRA_LIBS
668X_LIBS
669X_PRE_LIBS
670X_CFLAGS
671XMKMF
672FIXPATH
673ZIP_DEBUGINFO_FILES
674ENABLE_DEBUG_SYMBOLS
675CFLAGS_WARNINGS_ARE_ERRORS
676COMPILER_SUPPORTS_TARGET_BITS_FLAG
677ZERO_ARCHFLAG
678LDFLAGS_CXX_JDK
679LDFLAGS_JDKEXE_SUFFIX
680LDFLAGS_JDKLIB_SUFFIX
681LDFLAGS_JDKEXE
682LDFLAGS_JDKLIB
683CXXFLAGS_JDKEXE
684CXXFLAGS_JDKLIB
685CFLAGS_JDKEXE
686CFLAGS_JDKLIB
687MACOSX_VERSION_MIN
688LEGACY_EXTRA_LDFLAGS
689LEGACY_EXTRA_CXXFLAGS
690LEGACY_EXTRA_CFLAGS
691CXX_O_FLAG_NONE
692CXX_O_FLAG_NORM
693CXX_O_FLAG_HI
694CXX_O_FLAG_HIGHEST
695C_O_FLAG_NONE
696C_O_FLAG_NORM
697C_O_FLAG_HI
698C_O_FLAG_HIGHEST
699CXXFLAGS_DEBUG_SYMBOLS
700CFLAGS_DEBUG_SYMBOLS
701CXX_FLAG_DEPS
702C_FLAG_DEPS
703SET_SHARED_LIBRARY_MAPFILE
704SET_SHARED_LIBRARY_NAME
705SET_SHARED_LIBRARY_ORIGIN
706SET_EXECUTABLE_ORIGIN
707SHARED_LIBRARY_FLAGS
708CXX_FLAG_REORDER
709C_FLAG_REORDER
710SYSROOT_LDFLAGS
711SYSROOT_CFLAGS
712RC_FLAGS
713AR_OUT_OPTION
714LD_OUT_OPTION
715EXE_OUT_OPTION
716CC_OUT_OPTION
717POST_MCS_CMD
718POST_STRIP_CMD
719ARFLAGS
720COMPILER_TARGET_BITS_FLAG
721JT_HOME
722JTREGEXE
723USING_BROKEN_SUSE_LD
724PACKAGE_PATH
725LDEXECXX
726LDEXE
727USE_CLANG
728HOTSPOT_LD
729HOTSPOT_CXX
730HOTSPOT_RC
731HOTSPOT_MT
732BUILD_LD
733BUILD_CXX
734BUILD_CC
735ac_ct_OBJDUMP
736OBJDUMP
737ac_ct_OBJCOPY
738OBJCOPY
739ac_ct_NM
740ac_ct_STRIP
741MCS
742GNM
743NM
744STRIP
745DUMPBIN
746RC
747MT
748LIPO
749ac_ct_OBJC
750OBJCFLAGS
751OBJC
752ac_ct_AR
753AR
754AS
755LDCXX
756LD
757CXXCPP
758CPP
759ac_ct_CXX
760CXXFLAGS
761CXX
762ac_ct_PROPER_COMPILER_CXX
763PROPER_COMPILER_CXX
764TOOLCHAIN_PATH_CXX
765POTENTIAL_CXX
766OBJEXT
767EXEEXT
768ac_ct_CC
769CPPFLAGS
770LDFLAGS
771CFLAGS
772CC
773ac_ct_PROPER_COMPILER_CC
774PROPER_COMPILER_CC
775TOOLCHAIN_PATH_CC
776POTENTIAL_CC
777VS_LIB
778VS_INCLUDE
779VS_PATH
780CYGWIN_LINK
781EXE_SUFFIX
782OBJ_SUFFIX
783STATIC_LIBRARY
784SHARED_LIBRARY
785STATIC_LIBRARY_SUFFIX
786SHARED_LIBRARY_SUFFIX
787LIBRARY_PREFIX
788TOOLCHAIN_TYPE
789BUILD_HOTSPOT
790HOTSPOT_DIST
791BUILD_OUTPUT
792OVERRIDE_SRC_ROOT
793ADD_SRC_ROOT
794JDK_TOPDIR
795NASHORN_TOPDIR
796HOTSPOT_TOPDIR
797JAXWS_TOPDIR
798JAXP_TOPDIR
799CORBA_TOPDIR
800LANGTOOLS_TOPDIR
801JAVA_FLAGS_SMALL
802JAVA_FLAGS_BIG
803JAVA_FLAGS
804JAVAC_FLAGS
805BOOT_JDK_SOURCETARGET
806JARSIGNER
807NATIVE2ASCII
808JAR
809JAVAH
810JAVAC
811JAVA
812BOOT_JDK
813BOOT_TOOLSJAR
814BOOT_RTJAR
815JAVA_CHECK
816JAVAC_CHECK
817COOKED_BUILD_NUMBER
818JDK_VERSION
819COPYRIGHT_YEAR
820MACOSX_BUNDLE_ID_BASE
821MACOSX_BUNDLE_NAME_BASE
822COMPANY_NAME
823JDK_RC_PLATFORM_NAME
824PRODUCT_SUFFIX
825PRODUCT_NAME
826LAUNCHER_NAME
827MILESTONE
828JDK_BUILD_NUMBER
829JDK_UPDATE_VERSION
830JDK_MICRO_VERSION
831JDK_MINOR_VERSION
832JDK_MAJOR_VERSION
833USER_RELEASE_SUFFIX
834COMPRESS_JARS
835RMICONNECTOR_IIOP
836UNLIMITED_CRYPTO
837CACERTS_FILE
838TEST_IN_BUILD
839BUILD_HEADLESS
840SUPPORT_HEADFUL
841SUPPORT_HEADLESS
842BDEPS_FTP
843BDEPS_UNZIP
844OS_VERSION_MICRO
845OS_VERSION_MINOR
846OS_VERSION_MAJOR
847PKG_CONFIG
848CODESIGN
849XATTR
850DSYMUTIL
851IS_GNU_TIME
852TIME
853STAT
854HG
855READELF
856OTOOL
857LDD
858ZIP
859UNZIP
860FIND_DELETE
861MAKE
862CHECK_TOOLSDIR_MAKE
863CHECK_TOOLSDIR_GMAKE
864CHECK_MAKE
865CHECK_GMAKE
866PKGHANDLER
867OUTPUT_ROOT
868CONF_NAME
869SPEC
870BUILD_VARIANT_RELEASE
871DEBUG_CLASSFILES
872FASTDEBUG
873VARIANT
874DEBUG_LEVEL
875MACOSX_UNIVERSAL
876INCLUDE_SA
877JVM_VARIANT_CORE
878JVM_VARIANT_ZEROSHARK
879JVM_VARIANT_ZERO
880JVM_VARIANT_KERNEL
881JVM_VARIANT_MINIMAL1
882JVM_VARIANT_CLIENT
883JVM_VARIANT_SERVER
884JVM_VARIANTS
885JVM_INTERPRETER
886JDK_VARIANT
887SET_OPENJDK
888BUILD_LOG_WRAPPER
889BUILD_LOG_PREVIOUS
890BUILD_LOG
891TOPDIR
892PATH_SEP
893ZERO_ARCHDEF
894DEFINE_CROSS_COMPILE_ARCH
895LP64
896OPENJDK_TARGET_OS_EXPORT_DIR
897OPENJDK_TARGET_OS_API_DIR
898OPENJDK_TARGET_CPU_JLI_CFLAGS
899OPENJDK_TARGET_CPU_OSARCH
900OPENJDK_TARGET_CPU_ISADIR
901OPENJDK_TARGET_CPU_LIBDIR
902OPENJDK_TARGET_CPU_LEGACY_LIB
903OPENJDK_TARGET_CPU_LEGACY
904REQUIRED_OS_VERSION
905REQUIRED_OS_NAME
906COMPILE_TYPE
907OPENJDK_TARGET_CPU_ENDIAN
908OPENJDK_TARGET_CPU_BITS
909OPENJDK_TARGET_CPU_ARCH
910OPENJDK_TARGET_CPU
911OPENJDK_TARGET_OS_API
912OPENJDK_TARGET_OS
913OPENJDK_BUILD_CPU_ENDIAN
914OPENJDK_BUILD_CPU_BITS
915OPENJDK_BUILD_CPU_ARCH
916OPENJDK_BUILD_CPU
917OPENJDK_BUILD_OS_API
918OPENJDK_BUILD_OS
919OPENJDK_BUILD_AUTOCONF_NAME
920OPENJDK_TARGET_AUTOCONF_NAME
921target_os
922target_vendor
923target_cpu
924target
925host_os
926host_vendor
927host_cpu
928host
929build_os
930build_vendor
931build_cpu
932build
933SETFILE
934DF
935READLINK
936CYGPATH
937SED
938FGREP
939EGREP
940GREP
941AWK
942XARGS
943WHICH
944WC
945UNIQ
946UNAME
947TR
948TOUCH
949TEE
950TAR
951TAIL
952SORT
953SH
954RM
955PRINTF
956NAWK
957MV
958MKTEMP
959MKDIR
960LS
961LN
962HEAD
963FIND
964FILE
965EXPR
966ECHO
967DIRNAME
968DIFF
969DATE
970CUT
971CPIO
972CP
973COMM
974CMP
975CHMOD
976CAT
977BASH
978BASENAME
979DATE_WHEN_CONFIGURED
980CONFIGURE_COMMAND_LINE
981target_alias
982host_alias
983build_alias
984LIBS
985ECHO_T
986ECHO_N
987ECHO_C
988DEFS
989mandir
990localedir
991libdir
992psdir
993pdfdir
994dvidir
995htmldir
996infodir
997docdir
998oldincludedir
999includedir
1000localstatedir
1001sharedstatedir
1002sysconfdir
1003datadir
1004datarootdir
1005libexecdir
1006sbindir
1007bindir
1008program_transform_name
1009prefix
1010exec_prefix
1011PACKAGE_URL
1012PACKAGE_BUGREPORT
1013PACKAGE_STRING
1014PACKAGE_VERSION
1015PACKAGE_TARNAME
1016PACKAGE_NAME
1017PATH_SEPARATOR
1018SHELL'
1019ac_subst_files=''
1020ac_user_opts='
1021enable_option_checking
1022with_target_bits
1023enable_openjdk_only
1024with_custom_make_dir
1025with_jdk_variant
1026with_jvm_interpreter
1027with_jvm_variants
1028enable_debug
1029with_debug_level
1030with_devkit
1031with_sys_root
1032with_sysroot
1033with_tools_dir
1034with_toolchain_path
1035with_extra_path
1036with_conf_name
1037with_builddeps_conf
1038with_builddeps_server
1039with_builddeps_dir
1040with_builddeps_group
1041enable_headful
1042enable_hotspot_test_in_build
1043with_cacerts_file
1044enable_unlimited_crypto
1045enable_rmiconnector_iiop
1046with_milestone
1047with_update_version
1048with_user_release_suffix
1049with_build_number
1050with_boot_jdk
1051with_boot_jdk_jvmargs
1052with_add_source_root
1053with_override_source_root
1054with_adds_and_overrides
1055with_override_langtools
1056with_override_corba
1057with_override_jaxp
1058with_override_jaxws
1059with_override_hotspot
1060with_override_nashorn
1061with_override_jdk
1062with_import_hotspot
1063with_toolchain_type
1064with_jtreg
1065with_extra_cflags
1066with_extra_cxxflags
1067with_extra_ldflags
1068enable_debug_symbols
1069enable_zip_debug_info
1070enable_macosx_runtime_support
1071with_x
1072with_cups
1073with_cups_include
1074with_freetype
1075with_freetype_include
1076with_freetype_lib
1077enable_freetype_bundling
1078with_alsa
1079with_alsa_include
1080with_alsa_lib
1081with_giflib
1082with_libpng
1083with_zlib
1084with_stdc__lib
1085with_msvcr_dll
1086with_dxsdk
1087with_dxsdk_lib
1088with_dxsdk_include
1089with_num_cores
1090with_memory_size
1091with_jobs
1092with_sjavac_server_java
1093enable_sjavac
1094enable_precompiled_headers
1095enable_ccache
1096with_ccache_dir
1097'
1098      ac_precious_vars='build_alias
1099host_alias
1100target_alias
1101BASENAME
1102BASH
1103CAT
1104CHMOD
1105CMP
1106COMM
1107CP
1108CPIO
1109CUT
1110DATE
1111DIFF
1112DIRNAME
1113ECHO
1114EXPR
1115FILE
1116FIND
1117HEAD
1118LN
1119LS
1120MKDIR
1121MKTEMP
1122MV
1123NAWK
1124PRINTF
1125RM
1126SH
1127SORT
1128TAIL
1129TAR
1130TEE
1131TOUCH
1132TR
1133UNAME
1134UNIQ
1135WC
1136WHICH
1137XARGS
1138AWK
1139GREP
1140EGREP
1141FGREP
1142SED
1143CYGPATH
1144READLINK
1145DF
1146SETFILE
1147UNZIP
1148ZIP
1149LDD
1150OTOOL
1151READELF
1152HG
1153STAT
1154TIME
1155DSYMUTIL
1156XATTR
1157CODESIGN
1158PKG_CONFIG
1159JAVA
1160JAVAC
1161JAVAH
1162JAR
1163NATIVE2ASCII
1164JARSIGNER
1165CC
1166CFLAGS
1167LDFLAGS
1168LIBS
1169CPPFLAGS
1170CXX
1171CXXFLAGS
1172CCC
1173CPP
1174CXXCPP
1175AS
1176AR
1177OBJC
1178OBJCFLAGS
1179LIPO
1180STRIP
1181NM
1182GNM
1183MCS
1184OBJCOPY
1185OBJDUMP
1186BUILD_CC
1187BUILD_CXX
1188BUILD_LD
1189JTREGEXE
1190XMKMF
1191FREETYPE_CFLAGS
1192FREETYPE_LIBS
1193ALSA_CFLAGS
1194ALSA_LIBS
1195PNG_CFLAGS
1196PNG_LIBS
1197LIBFFI_CFLAGS
1198LIBFFI_LIBS
1199CCACHE'
1200
1201
1202# Initialize some variables set by options.
1203ac_init_help=
1204ac_init_version=false
1205ac_unrecognized_opts=
1206ac_unrecognized_sep=
1207# The variables have the same names as the options, with
1208# dashes changed to underlines.
1209cache_file=/dev/null
1210exec_prefix=NONE
1211no_create=
1212no_recursion=
1213prefix=NONE
1214program_prefix=NONE
1215program_suffix=NONE
1216program_transform_name=s,x,x,
1217silent=
1218site=
1219srcdir=
1220verbose=
1221x_includes=NONE
1222x_libraries=NONE
1223
1224# Installation directory options.
1225# These are left unexpanded so users can "make install exec_prefix=/foo"
1226# and all the variables that are supposed to be based on exec_prefix
1227# by default will actually change.
1228# Use braces instead of parens because sh, perl, etc. also accept them.
1229# (The list follows the same order as the GNU Coding Standards.)
1230bindir='${exec_prefix}/bin'
1231sbindir='${exec_prefix}/sbin'
1232libexecdir='${exec_prefix}/libexec'
1233datarootdir='${prefix}/share'
1234datadir='${datarootdir}'
1235sysconfdir='${prefix}/etc'
1236sharedstatedir='${prefix}/com'
1237localstatedir='${prefix}/var'
1238includedir='${prefix}/include'
1239oldincludedir='/usr/include'
1240docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1241infodir='${datarootdir}/info'
1242htmldir='${docdir}'
1243dvidir='${docdir}'
1244pdfdir='${docdir}'
1245psdir='${docdir}'
1246libdir='${exec_prefix}/lib'
1247localedir='${datarootdir}/locale'
1248mandir='${datarootdir}/man'
1249
1250ac_prev=
1251ac_dashdash=
1252for ac_option
1253do
1254  # If the previous option needs an argument, assign it.
1255  if test -n "$ac_prev"; then
1256    eval $ac_prev=\$ac_option
1257    ac_prev=
1258    continue
1259  fi
1260
1261  case $ac_option in
1262  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1263  *=)   ac_optarg= ;;
1264  *)    ac_optarg=yes ;;
1265  esac
1266
1267  # Accept the important Cygnus configure options, so we can diagnose typos.
1268
1269  case $ac_dashdash$ac_option in
1270  --)
1271    ac_dashdash=yes ;;
1272
1273  -bindir | --bindir | --bindi | --bind | --bin | --bi)
1274    ac_prev=bindir ;;
1275  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1276    bindir=$ac_optarg ;;
1277
1278  -build | --build | --buil | --bui | --bu)
1279    ac_prev=build_alias ;;
1280  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1281    build_alias=$ac_optarg ;;
1282
1283  -cache-file | --cache-file | --cache-fil | --cache-fi \
1284  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1285    ac_prev=cache_file ;;
1286  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1287  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1288    cache_file=$ac_optarg ;;
1289
1290  --config-cache | -C)
1291    cache_file=config.cache ;;
1292
1293  -datadir | --datadir | --datadi | --datad)
1294    ac_prev=datadir ;;
1295  -datadir=* | --datadir=* | --datadi=* | --datad=*)
1296    datadir=$ac_optarg ;;
1297
1298  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1299  | --dataroo | --dataro | --datar)
1300    ac_prev=datarootdir ;;
1301  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1302  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1303    datarootdir=$ac_optarg ;;
1304
1305  -disable-* | --disable-*)
1306    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1307    # Reject names that are not valid shell variable names.
1308    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1309      as_fn_error $? "invalid feature name: $ac_useropt"
1310    ac_useropt_orig=$ac_useropt
1311    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1312    case $ac_user_opts in
1313      *"
1314"enable_$ac_useropt"
1315"*) ;;
1316      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1317	 ac_unrecognized_sep=', ';;
1318    esac
1319    eval enable_$ac_useropt=no ;;
1320
1321  -docdir | --docdir | --docdi | --doc | --do)
1322    ac_prev=docdir ;;
1323  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1324    docdir=$ac_optarg ;;
1325
1326  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1327    ac_prev=dvidir ;;
1328  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1329    dvidir=$ac_optarg ;;
1330
1331  -enable-* | --enable-*)
1332    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1333    # Reject names that are not valid shell variable names.
1334    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1335      as_fn_error $? "invalid feature name: $ac_useropt"
1336    ac_useropt_orig=$ac_useropt
1337    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1338    case $ac_user_opts in
1339      *"
1340"enable_$ac_useropt"
1341"*) ;;
1342      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1343	 ac_unrecognized_sep=', ';;
1344    esac
1345    eval enable_$ac_useropt=\$ac_optarg ;;
1346
1347  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1348  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1349  | --exec | --exe | --ex)
1350    ac_prev=exec_prefix ;;
1351  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1352  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1353  | --exec=* | --exe=* | --ex=*)
1354    exec_prefix=$ac_optarg ;;
1355
1356  -gas | --gas | --ga | --g)
1357    # Obsolete; use --with-gas.
1358    with_gas=yes ;;
1359
1360  -help | --help | --hel | --he | -h)
1361    ac_init_help=long ;;
1362  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1363    ac_init_help=recursive ;;
1364  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1365    ac_init_help=short ;;
1366
1367  -host | --host | --hos | --ho)
1368    ac_prev=host_alias ;;
1369  -host=* | --host=* | --hos=* | --ho=*)
1370    host_alias=$ac_optarg ;;
1371
1372  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1373    ac_prev=htmldir ;;
1374  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1375  | --ht=*)
1376    htmldir=$ac_optarg ;;
1377
1378  -includedir | --includedir | --includedi | --included | --include \
1379  | --includ | --inclu | --incl | --inc)
1380    ac_prev=includedir ;;
1381  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1382  | --includ=* | --inclu=* | --incl=* | --inc=*)
1383    includedir=$ac_optarg ;;
1384
1385  -infodir | --infodir | --infodi | --infod | --info | --inf)
1386    ac_prev=infodir ;;
1387  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1388    infodir=$ac_optarg ;;
1389
1390  -libdir | --libdir | --libdi | --libd)
1391    ac_prev=libdir ;;
1392  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1393    libdir=$ac_optarg ;;
1394
1395  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1396  | --libexe | --libex | --libe)
1397    ac_prev=libexecdir ;;
1398  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1399  | --libexe=* | --libex=* | --libe=*)
1400    libexecdir=$ac_optarg ;;
1401
1402  -localedir | --localedir | --localedi | --localed | --locale)
1403    ac_prev=localedir ;;
1404  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1405    localedir=$ac_optarg ;;
1406
1407  -localstatedir | --localstatedir | --localstatedi | --localstated \
1408  | --localstate | --localstat | --localsta | --localst | --locals)
1409    ac_prev=localstatedir ;;
1410  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1411  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1412    localstatedir=$ac_optarg ;;
1413
1414  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1415    ac_prev=mandir ;;
1416  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1417    mandir=$ac_optarg ;;
1418
1419  -nfp | --nfp | --nf)
1420    # Obsolete; use --without-fp.
1421    with_fp=no ;;
1422
1423  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1424  | --no-cr | --no-c | -n)
1425    no_create=yes ;;
1426
1427  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1428  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1429    no_recursion=yes ;;
1430
1431  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1432  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1433  | --oldin | --oldi | --old | --ol | --o)
1434    ac_prev=oldincludedir ;;
1435  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1436  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1437  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1438    oldincludedir=$ac_optarg ;;
1439
1440  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1441    ac_prev=prefix ;;
1442  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1443    prefix=$ac_optarg ;;
1444
1445  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1446  | --program-pre | --program-pr | --program-p)
1447    ac_prev=program_prefix ;;
1448  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1449  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1450    program_prefix=$ac_optarg ;;
1451
1452  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1453  | --program-suf | --program-su | --program-s)
1454    ac_prev=program_suffix ;;
1455  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1456  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1457    program_suffix=$ac_optarg ;;
1458
1459  -program-transform-name | --program-transform-name \
1460  | --program-transform-nam | --program-transform-na \
1461  | --program-transform-n | --program-transform- \
1462  | --program-transform | --program-transfor \
1463  | --program-transfo | --program-transf \
1464  | --program-trans | --program-tran \
1465  | --progr-tra | --program-tr | --program-t)
1466    ac_prev=program_transform_name ;;
1467  -program-transform-name=* | --program-transform-name=* \
1468  | --program-transform-nam=* | --program-transform-na=* \
1469  | --program-transform-n=* | --program-transform-=* \
1470  | --program-transform=* | --program-transfor=* \
1471  | --program-transfo=* | --program-transf=* \
1472  | --program-trans=* | --program-tran=* \
1473  | --progr-tra=* | --program-tr=* | --program-t=*)
1474    program_transform_name=$ac_optarg ;;
1475
1476  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1477    ac_prev=pdfdir ;;
1478  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1479    pdfdir=$ac_optarg ;;
1480
1481  -psdir | --psdir | --psdi | --psd | --ps)
1482    ac_prev=psdir ;;
1483  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1484    psdir=$ac_optarg ;;
1485
1486  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1487  | -silent | --silent | --silen | --sile | --sil)
1488    silent=yes ;;
1489
1490  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1491    ac_prev=sbindir ;;
1492  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1493  | --sbi=* | --sb=*)
1494    sbindir=$ac_optarg ;;
1495
1496  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1497  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1498  | --sharedst | --shareds | --shared | --share | --shar \
1499  | --sha | --sh)
1500    ac_prev=sharedstatedir ;;
1501  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1502  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1503  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1504  | --sha=* | --sh=*)
1505    sharedstatedir=$ac_optarg ;;
1506
1507  -site | --site | --sit)
1508    ac_prev=site ;;
1509  -site=* | --site=* | --sit=*)
1510    site=$ac_optarg ;;
1511
1512  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1513    ac_prev=srcdir ;;
1514  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1515    srcdir=$ac_optarg ;;
1516
1517  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1518  | --syscon | --sysco | --sysc | --sys | --sy)
1519    ac_prev=sysconfdir ;;
1520  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1521  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1522    sysconfdir=$ac_optarg ;;
1523
1524  -target | --target | --targe | --targ | --tar | --ta | --t)
1525    ac_prev=target_alias ;;
1526  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1527    target_alias=$ac_optarg ;;
1528
1529  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1530    verbose=yes ;;
1531
1532  -version | --version | --versio | --versi | --vers | -V)
1533    ac_init_version=: ;;
1534
1535  -with-* | --with-*)
1536    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1537    # Reject names that are not valid shell variable names.
1538    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1539      as_fn_error $? "invalid package name: $ac_useropt"
1540    ac_useropt_orig=$ac_useropt
1541    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1542    case $ac_user_opts in
1543      *"
1544"with_$ac_useropt"
1545"*) ;;
1546      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1547	 ac_unrecognized_sep=', ';;
1548    esac
1549    eval with_$ac_useropt=\$ac_optarg ;;
1550
1551  -without-* | --without-*)
1552    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1553    # Reject names that are not valid shell variable names.
1554    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1555      as_fn_error $? "invalid package name: $ac_useropt"
1556    ac_useropt_orig=$ac_useropt
1557    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1558    case $ac_user_opts in
1559      *"
1560"with_$ac_useropt"
1561"*) ;;
1562      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1563	 ac_unrecognized_sep=', ';;
1564    esac
1565    eval with_$ac_useropt=no ;;
1566
1567  --x)
1568    # Obsolete; use --with-x.
1569    with_x=yes ;;
1570
1571  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1572  | --x-incl | --x-inc | --x-in | --x-i)
1573    ac_prev=x_includes ;;
1574  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1575  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1576    x_includes=$ac_optarg ;;
1577
1578  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1579  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1580    ac_prev=x_libraries ;;
1581  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1582  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1583    x_libraries=$ac_optarg ;;
1584
1585  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1586Try \`$0 --help' for more information"
1587    ;;
1588
1589  *=*)
1590    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1591    # Reject names that are not valid shell variable names.
1592    case $ac_envvar in #(
1593      '' | [0-9]* | *[!_$as_cr_alnum]* )
1594      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1595    esac
1596    eval $ac_envvar=\$ac_optarg
1597    export $ac_envvar ;;
1598
1599  *)
1600    # FIXME: should be removed in autoconf 3.0.
1601    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1602    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1603      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1604    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1605    ;;
1606
1607  esac
1608done
1609
1610if test -n "$ac_prev"; then
1611  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1612  as_fn_error $? "missing argument to $ac_option"
1613fi
1614
1615if test -n "$ac_unrecognized_opts"; then
1616  case $enable_option_checking in
1617    no) ;;
1618    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1619    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1620  esac
1621fi
1622
1623# Check all directory arguments for consistency.
1624for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1625		datadir sysconfdir sharedstatedir localstatedir includedir \
1626		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1627		libdir localedir mandir
1628do
1629  eval ac_val=\$$ac_var
1630  # Remove trailing slashes.
1631  case $ac_val in
1632    */ )
1633      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1634      eval $ac_var=\$ac_val;;
1635  esac
1636  # Be sure to have absolute directory names.
1637  case $ac_val in
1638    [\\/$]* | ?:[\\/]* )  continue;;
1639    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1640  esac
1641  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1642done
1643
1644# There might be people who depend on the old broken behavior: `$host'
1645# used to hold the argument of --host etc.
1646# FIXME: To remove some day.
1647build=$build_alias
1648host=$host_alias
1649target=$target_alias
1650
1651# FIXME: To remove some day.
1652if test "x$host_alias" != x; then
1653  if test "x$build_alias" = x; then
1654    cross_compiling=maybe
1655  elif test "x$build_alias" != "x$host_alias"; then
1656    cross_compiling=yes
1657  fi
1658fi
1659
1660ac_tool_prefix=
1661test -n "$host_alias" && ac_tool_prefix=$host_alias-
1662
1663test "$silent" = yes && exec 6>/dev/null
1664
1665
1666ac_pwd=`pwd` && test -n "$ac_pwd" &&
1667ac_ls_di=`ls -di .` &&
1668ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1669  as_fn_error $? "working directory cannot be determined"
1670test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1671  as_fn_error $? "pwd does not report name of working directory"
1672
1673
1674# Find the source files, if location was not specified.
1675if test -z "$srcdir"; then
1676  ac_srcdir_defaulted=yes
1677  # Try the directory containing this script, then the parent directory.
1678  ac_confdir=`$as_dirname -- "$as_myself" ||
1679$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1680	 X"$as_myself" : 'X\(//\)[^/]' \| \
1681	 X"$as_myself" : 'X\(//\)$' \| \
1682	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1683$as_echo X"$as_myself" |
1684    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1685	    s//\1/
1686	    q
1687	  }
1688	  /^X\(\/\/\)[^/].*/{
1689	    s//\1/
1690	    q
1691	  }
1692	  /^X\(\/\/\)$/{
1693	    s//\1/
1694	    q
1695	  }
1696	  /^X\(\/\).*/{
1697	    s//\1/
1698	    q
1699	  }
1700	  s/.*/./; q'`
1701  srcdir=$ac_confdir
1702  if test ! -r "$srcdir/$ac_unique_file"; then
1703    srcdir=..
1704  fi
1705else
1706  ac_srcdir_defaulted=no
1707fi
1708if test ! -r "$srcdir/$ac_unique_file"; then
1709  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1710  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1711fi
1712ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1713ac_abs_confdir=`(
1714	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1715	pwd)`
1716# When building in place, set srcdir=.
1717if test "$ac_abs_confdir" = "$ac_pwd"; then
1718  srcdir=.
1719fi
1720# Remove unnecessary trailing slashes from srcdir.
1721# Double slashes in file names in object file debugging info
1722# mess up M-x gdb in Emacs.
1723case $srcdir in
1724*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1725esac
1726for ac_var in $ac_precious_vars; do
1727  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1728  eval ac_env_${ac_var}_value=\$${ac_var}
1729  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1730  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1731done
1732
1733#
1734# Report the --help message.
1735#
1736if test "$ac_init_help" = "long"; then
1737  # Omit some internal or obsolete options to make the list less imposing.
1738  # This message is too long to be a string in the A/UX 3.1 sh.
1739  cat <<_ACEOF
1740\`configure' configures OpenJDK jdk9 to adapt to many kinds of systems.
1741
1742Usage: $0 [OPTION]... [VAR=VALUE]...
1743
1744To assign environment variables (e.g., CC, CFLAGS...), specify them as
1745VAR=VALUE.  See below for descriptions of some of the useful variables.
1746
1747Defaults for the options are specified in brackets.
1748
1749Configuration:
1750  -h, --help              display this help and exit
1751      --help=short        display options specific to this package
1752      --help=recursive    display the short help of all the included packages
1753  -V, --version           display version information and exit
1754  -q, --quiet, --silent   do not print \`checking ...' messages
1755      --cache-file=FILE   cache test results in FILE [disabled]
1756  -C, --config-cache      alias for \`--cache-file=config.cache'
1757  -n, --no-create         do not create output files
1758      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1759
1760Installation directories:
1761  --prefix=PREFIX         install architecture-independent files in PREFIX
1762                          [$ac_default_prefix]
1763  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1764                          [PREFIX]
1765
1766By default, \`make install' will install all the files in
1767\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1768an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1769for instance \`--prefix=\$HOME'.
1770
1771For better control, use the options below.
1772
1773Fine tuning of the installation directories:
1774  --bindir=DIR            user executables [EPREFIX/bin]
1775  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1776  --libexecdir=DIR        program executables [EPREFIX/libexec]
1777  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1778  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1779  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1780  --libdir=DIR            object code libraries [EPREFIX/lib]
1781  --includedir=DIR        C header files [PREFIX/include]
1782  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1783  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1784  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1785  --infodir=DIR           info documentation [DATAROOTDIR/info]
1786  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1787  --mandir=DIR            man documentation [DATAROOTDIR/man]
1788  --docdir=DIR            documentation root [DATAROOTDIR/doc/openjdk]
1789  --htmldir=DIR           html documentation [DOCDIR]
1790  --dvidir=DIR            dvi documentation [DOCDIR]
1791  --pdfdir=DIR            pdf documentation [DOCDIR]
1792  --psdir=DIR             ps documentation [DOCDIR]
1793_ACEOF
1794
1795  cat <<\_ACEOF
1796
1797X features:
1798  --x-includes=DIR    X include files are in DIR
1799  --x-libraries=DIR   X library files are in DIR
1800
1801System types:
1802  --build=BUILD     configure for building on BUILD [guessed]
1803  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1804  --target=TARGET   configure for building compilers for TARGET [HOST]
1805_ACEOF
1806fi
1807
1808if test -n "$ac_init_help"; then
1809  case $ac_init_help in
1810     short | recursive ) echo "Configuration of OpenJDK jdk9:";;
1811   esac
1812  cat <<\_ACEOF
1813
1814Optional Features:
1815  --disable-option-checking  ignore unrecognized --enable/--with options
1816  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1817  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1818  --enable-openjdk-only   suppress building custom source even if present
1819                          [disabled]
1820  --enable-debug          set the debug level to fastdebug (shorthand for
1821                          --with-debug-level=fastdebug) [disabled]
1822  --disable-headful       disable building headful support (graphical UI
1823                          support) [enabled]
1824  --enable-hotspot-test-in-build
1825                          run the Queens test after Hotspot build [disabled]
1826  --enable-unlimited-crypto
1827                          Enable unlimited crypto policy [disabled]
1828  --enable-rmiconnector-iiop
1829                          enable the JMX RMIConnector iiop transport
1830                          [disabled]
1831  --disable-debug-symbols disable generation of debug symbols [enabled]
1832  --disable-zip-debug-info
1833                          disable zipping of debug-info files [enabled]
1834  --enable-macosx-runtime-support
1835                          Deprecated. Option is kept for backwards
1836                          compatibility and is ignored
1837  --disable-freetype-bundling
1838                          disable bundling of the freetype library with the
1839                          build result [enabled on Windows or when using
1840                          --with-freetype, disabled otherwise]
1841  --enable-sjavac         use sjavac to do fast incremental compiles
1842                          [disabled]
1843  --disable-precompiled-headers
1844                          disable using precompiled headers when compiling C++
1845                          [enabled]
1846  --enable-ccache         enable using ccache to speed up recompilations
1847                          [disabled]
1848
1849Optional Packages:
1850  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1851  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1852  --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1853                          support it), e.g. --with-target-bits=32 [guessed]
1854  --with-custom-make-dir  Deprecated. Option is kept for backwards
1855                          compatibility and is ignored
1856  --with-jdk-variant      JDK variant to build (normal) [normal]
1857  --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1858  --with-jvm-variants     JVM variants (separated by commas) to build (server,
1859                          client, minimal1, kernel, zero, zeroshark, core)
1860                          [server]
1861  --with-debug-level      set the debug level (release, fastdebug, slowdebug,
1862                          optimized (HotSpot build only)) [release]
1863  --with-devkit           use this devkit for compilers, tools and resources
1864  --with-sys-root         alias for --with-sysroot for backwards compatability
1865  --with-sysroot          use this directory as sysroot)
1866  --with-tools-dir        alias for --with-toolchain-path for backwards
1867                          compatibility
1868  --with-toolchain-path   prepend these directories when searching for
1869                          toolchain binaries (compilers etc)
1870  --with-extra-path       prepend these directories to the default path
1871  --with-conf-name        use this as the name of the configuration [generated
1872                          from important configuration options]
1873  --with-builddeps-conf   use this configuration file for the builddeps
1874  --with-builddeps-server download and use build dependencies from this server
1875                          url
1876  --with-builddeps-dir    store downloaded build dependencies here
1877                          [/localhome/builddeps]
1878  --with-builddeps-group  chgrp the downloaded build dependencies to this
1879                          group
1880  --with-cacerts-file     specify alternative cacerts file
1881  --with-milestone        Set milestone value for build [internal]
1882  --with-update-version   Set update version value for build [b00]
1883  --with-user-release-suffix
1884                          Add a custom string to the version string if build
1885                          number is not set.[username_builddateb00]
1886  --with-build-number     Set build number value for build [b00]
1887  --with-boot-jdk         path to Boot JDK (used to bootstrap build) [probed]
1888  --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java
1889                          invocations of boot JDK, overriding the default
1890                          values, e.g --with-boot-jdk-jvmargs="-Xmx8G
1891                          -enableassertions"
1892  --with-add-source-root  for each and every source directory, look in this
1893                          additional source root for the same directory; if it
1894                          exists and have files in it, include it in the build
1895  --with-override-source-root
1896                          for each and every source directory, look in this
1897                          override source root for the same directory; if it
1898                          exists, use that directory instead and ignore the
1899                          directory in the original source root
1900  --with-adds-and-overrides
1901                          use the subdirs 'adds' and 'overrides' in the
1902                          specified directory as add-source-root and
1903                          override-source-root
1904  --with-override-langtools
1905                          use this langtools dir for the build
1906  --with-override-corba   use this corba dir for the build
1907  --with-override-jaxp    use this jaxp dir for the build
1908  --with-override-jaxws   use this jaxws dir for the build
1909  --with-override-hotspot use this hotspot dir for the build
1910  --with-override-nashorn use this nashorn dir for the build
1911  --with-override-jdk     use this jdk dir for the build
1912  --with-import-hotspot   import hotspot binaries from this jdk image or
1913                          hotspot build dist dir instead of building from
1914                          source
1915  --with-toolchain-type   the toolchain type (or family) to use, use '--help'
1916                          to show possible values [platform dependent]
1917  --with-jtreg            Regression Test Harness [probed]
1918  --with-extra-cflags     extra flags to be used when compiling jdk c-files
1919  --with-extra-cxxflags   extra flags to be used when compiling jdk c++-files
1920  --with-extra-ldflags    extra flags to be used when linking jdk
1921  --with-x                use the X Window System
1922  --with-cups             specify prefix directory for the cups package
1923                          (expecting the headers under PATH/include)
1924  --with-cups-include     specify directory for the cups include files
1925  --with-freetype         specify prefix directory for the freetype package
1926                          (expecting the libraries under PATH/lib and the
1927                          headers under PATH/include)
1928  --with-freetype-include specify directory for the freetype include files
1929  --with-freetype-lib     specify directory for the freetype library
1930  --with-alsa             specify prefix directory for the alsa package
1931                          (expecting the libraries under PATH/lib and the
1932                          headers under PATH/include)
1933  --with-alsa-include     specify directory for the alsa include files
1934  --with-alsa-lib         specify directory for the alsa library
1935  --with-giflib           use giflib from build system or OpenJDK source
1936                          (system, bundled) [bundled]
1937  --with-libpng           use libpng from build system or OpenJDK source
1938                          (system, bundled) [bundled]
1939  --with-zlib             use zlib from build system or OpenJDK source
1940                          (system, bundled) [bundled]
1941  --with-stdc++lib=<static>,<dynamic>,<default>
1942                          force linking of the C++ runtime on Linux to either
1943                          static or dynamic, default is static with dynamic as
1944                          fallback
1945  --with-msvcr-dll        copy this msvcr100.dll into the built JDK (Windows
1946                          only) [probed]
1947  --with-dxsdk            Deprecated. Option is kept for backwards
1948                          compatibility and is ignored
1949  --with-dxsdk-lib        Deprecated. Option is kept for backwards
1950                          compatibility and is ignored
1951  --with-dxsdk-include    Deprecated. Option is kept for backwards
1952                          compatibility and is ignored
1953  --with-num-cores        number of cores in the build system, e.g.
1954                          --with-num-cores=8 [probed]
1955  --with-memory-size      memory (in MB) available in the build system, e.g.
1956                          --with-memory-size=1024 [probed]
1957  --with-jobs             number of parallel jobs to let make run [calculated
1958                          based on cores and memory]
1959  --with-sjavac-server-java
1960                          use this java binary for running the sjavac
1961                          background server [Boot JDK java]
1962  --with-ccache-dir       where to store ccache files [~/.ccache]
1963
1964Some influential environment variables:
1965  BASENAME    Override default value for BASENAME
1966  BASH        Override default value for BASH
1967  CAT         Override default value for CAT
1968  CHMOD       Override default value for CHMOD
1969  CMP         Override default value for CMP
1970  COMM        Override default value for COMM
1971  CP          Override default value for CP
1972  CPIO        Override default value for CPIO
1973  CUT         Override default value for CUT
1974  DATE        Override default value for DATE
1975  DIFF        Override default value for DIFF
1976  DIRNAME     Override default value for DIRNAME
1977  ECHO        Override default value for ECHO
1978  EXPR        Override default value for EXPR
1979  FILE        Override default value for FILE
1980  FIND        Override default value for FIND
1981  HEAD        Override default value for HEAD
1982  LN          Override default value for LN
1983  LS          Override default value for LS
1984  MKDIR       Override default value for MKDIR
1985  MKTEMP      Override default value for MKTEMP
1986  MV          Override default value for MV
1987  NAWK        Override default value for NAWK
1988  PRINTF      Override default value for PRINTF
1989  RM          Override default value for RM
1990  SH          Override default value for SH
1991  SORT        Override default value for SORT
1992  TAIL        Override default value for TAIL
1993  TAR         Override default value for TAR
1994  TEE         Override default value for TEE
1995  TOUCH       Override default value for TOUCH
1996  TR          Override default value for TR
1997  UNAME       Override default value for UNAME
1998  UNIQ        Override default value for UNIQ
1999  WC          Override default value for WC
2000  WHICH       Override default value for WHICH
2001  XARGS       Override default value for XARGS
2002  AWK         Override default value for AWK
2003  GREP        Override default value for GREP
2004  EGREP       Override default value for EGREP
2005  FGREP       Override default value for FGREP
2006  SED         Override default value for SED
2007  CYGPATH     Override default value for CYGPATH
2008  READLINK    Override default value for READLINK
2009  DF          Override default value for DF
2010  SETFILE     Override default value for SETFILE
2011  UNZIP       Override default value for UNZIP
2012  ZIP         Override default value for ZIP
2013  LDD         Override default value for LDD
2014  OTOOL       Override default value for OTOOL
2015  READELF     Override default value for READELF
2016  HG          Override default value for HG
2017  STAT        Override default value for STAT
2018  TIME        Override default value for TIME
2019  DSYMUTIL    Override default value for DSYMUTIL
2020  XATTR       Override default value for XATTR
2021  CODESIGN    Override default value for CODESIGN
2022  PKG_CONFIG  path to pkg-config utility
2023  JAVA        Override default value for JAVA
2024  JAVAC       Override default value for JAVAC
2025  JAVAH       Override default value for JAVAH
2026  JAR         Override default value for JAR
2027  NATIVE2ASCII
2028              Override default value for NATIVE2ASCII
2029  JARSIGNER   Override default value for JARSIGNER
2030  CC          C compiler command
2031  CFLAGS      C compiler flags
2032  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2033              nonstandard directory <lib dir>
2034  LIBS        libraries to pass to the linker, e.g. -l<library>
2035  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2036              you have headers in a nonstandard directory <include dir>
2037  CXX         C++ compiler command
2038  CXXFLAGS    C++ compiler flags
2039  CPP         C preprocessor
2040  CXXCPP      C++ preprocessor
2041  AS          Override default value for AS
2042  AR          Override default value for AR
2043  OBJC        Objective C compiler command
2044  OBJCFLAGS   Objective C compiler flags
2045  LIPO        Override default value for LIPO
2046  STRIP       Override default value for STRIP
2047  NM          Override default value for NM
2048  GNM         Override default value for GNM
2049  MCS         Override default value for MCS
2050  OBJCOPY     Override default value for OBJCOPY
2051  OBJDUMP     Override default value for OBJDUMP
2052  BUILD_CC    Override default value for BUILD_CC
2053  BUILD_CXX   Override default value for BUILD_CXX
2054  BUILD_LD    Override default value for BUILD_LD
2055  JTREGEXE    Override default value for JTREGEXE
2056  XMKMF       Path to xmkmf, Makefile generator for X Window System
2057  FREETYPE_CFLAGS
2058              C compiler flags for FREETYPE, overriding pkg-config
2059  FREETYPE_LIBS
2060              linker flags for FREETYPE, overriding pkg-config
2061  ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
2062  ALSA_LIBS   linker flags for ALSA, overriding pkg-config
2063  PNG_CFLAGS  C compiler flags for PNG, overriding pkg-config
2064  PNG_LIBS    linker flags for PNG, overriding pkg-config
2065  LIBFFI_CFLAGS
2066              C compiler flags for LIBFFI, overriding pkg-config
2067  LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config
2068  CCACHE      Override default value for CCACHE
2069
2070Use these variables to override the choices made by `configure' or to help
2071it to find libraries and programs with nonstandard names/locations.
2072
2073Report bugs to <build-dev@openjdk.java.net>.
2074OpenJDK home page: <http://openjdk.java.net>.
2075_ACEOF
2076ac_status=$?
2077fi
2078
2079if test "$ac_init_help" = "recursive"; then
2080  # If there are subdirs, report their specific --help.
2081  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2082    test -d "$ac_dir" ||
2083      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2084      continue
2085    ac_builddir=.
2086
2087case "$ac_dir" in
2088.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2089*)
2090  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2091  # A ".." for each directory in $ac_dir_suffix.
2092  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2093  case $ac_top_builddir_sub in
2094  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2095  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2096  esac ;;
2097esac
2098ac_abs_top_builddir=$ac_pwd
2099ac_abs_builddir=$ac_pwd$ac_dir_suffix
2100# for backward compatibility:
2101ac_top_builddir=$ac_top_build_prefix
2102
2103case $srcdir in
2104  .)  # We are building in place.
2105    ac_srcdir=.
2106    ac_top_srcdir=$ac_top_builddir_sub
2107    ac_abs_top_srcdir=$ac_pwd ;;
2108  [\\/]* | ?:[\\/]* )  # Absolute name.
2109    ac_srcdir=$srcdir$ac_dir_suffix;
2110    ac_top_srcdir=$srcdir
2111    ac_abs_top_srcdir=$srcdir ;;
2112  *) # Relative name.
2113    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2114    ac_top_srcdir=$ac_top_build_prefix$srcdir
2115    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2116esac
2117ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2118
2119    cd "$ac_dir" || { ac_status=$?; continue; }
2120    # Check for guested configure.
2121    if test -f "$ac_srcdir/configure.gnu"; then
2122      echo &&
2123      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2124    elif test -f "$ac_srcdir/configure"; then
2125      echo &&
2126      $SHELL "$ac_srcdir/configure" --help=recursive
2127    else
2128      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2129    fi || ac_status=$?
2130    cd "$ac_pwd" || { ac_status=$?; break; }
2131  done
2132fi
2133
2134test -n "$ac_init_help" && exit $ac_status
2135if $ac_init_version; then
2136  cat <<\_ACEOF
2137OpenJDK configure jdk9
2138generated by GNU Autoconf 2.69
2139
2140Copyright (C) 2012 Free Software Foundation, Inc.
2141This configure script is free software; the Free Software Foundation
2142gives unlimited permission to copy, distribute and modify it.
2143_ACEOF
2144  exit
2145fi
2146
2147## ------------------------ ##
2148## Autoconf initialization. ##
2149## ------------------------ ##
2150
2151# ac_fn_c_try_compile LINENO
2152# --------------------------
2153# Try to compile conftest.$ac_ext, and return whether this succeeded.
2154ac_fn_c_try_compile ()
2155{
2156  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2157  rm -f conftest.$ac_objext
2158  if { { ac_try="$ac_compile"
2159case "(($ac_try" in
2160  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2161  *) ac_try_echo=$ac_try;;
2162esac
2163eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2164$as_echo "$ac_try_echo"; } >&5
2165  (eval "$ac_compile") 2>conftest.err
2166  ac_status=$?
2167  if test -s conftest.err; then
2168    grep -v '^ *+' conftest.err >conftest.er1
2169    cat conftest.er1 >&5
2170    mv -f conftest.er1 conftest.err
2171  fi
2172  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2173  test $ac_status = 0; } && {
2174	 test -z "$ac_c_werror_flag" ||
2175	 test ! -s conftest.err
2176       } && test -s conftest.$ac_objext; then :
2177  ac_retval=0
2178else
2179  $as_echo "$as_me: failed program was:" >&5
2180sed 's/^/| /' conftest.$ac_ext >&5
2181
2182	ac_retval=1
2183fi
2184  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2185  as_fn_set_status $ac_retval
2186
2187} # ac_fn_c_try_compile
2188
2189# ac_fn_cxx_try_compile LINENO
2190# ----------------------------
2191# Try to compile conftest.$ac_ext, and return whether this succeeded.
2192ac_fn_cxx_try_compile ()
2193{
2194  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2195  rm -f conftest.$ac_objext
2196  if { { ac_try="$ac_compile"
2197case "(($ac_try" in
2198  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2199  *) ac_try_echo=$ac_try;;
2200esac
2201eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2202$as_echo "$ac_try_echo"; } >&5
2203  (eval "$ac_compile") 2>conftest.err
2204  ac_status=$?
2205  if test -s conftest.err; then
2206    grep -v '^ *+' conftest.err >conftest.er1
2207    cat conftest.er1 >&5
2208    mv -f conftest.er1 conftest.err
2209  fi
2210  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2211  test $ac_status = 0; } && {
2212	 test -z "$ac_cxx_werror_flag" ||
2213	 test ! -s conftest.err
2214       } && test -s conftest.$ac_objext; then :
2215  ac_retval=0
2216else
2217  $as_echo "$as_me: failed program was:" >&5
2218sed 's/^/| /' conftest.$ac_ext >&5
2219
2220	ac_retval=1
2221fi
2222  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2223  as_fn_set_status $ac_retval
2224
2225} # ac_fn_cxx_try_compile
2226
2227# ac_fn_c_try_cpp LINENO
2228# ----------------------
2229# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2230ac_fn_c_try_cpp ()
2231{
2232  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2233  if { { ac_try="$ac_cpp conftest.$ac_ext"
2234case "(($ac_try" in
2235  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2236  *) ac_try_echo=$ac_try;;
2237esac
2238eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2239$as_echo "$ac_try_echo"; } >&5
2240  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2241  ac_status=$?
2242  if test -s conftest.err; then
2243    grep -v '^ *+' conftest.err >conftest.er1
2244    cat conftest.er1 >&5
2245    mv -f conftest.er1 conftest.err
2246  fi
2247  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2248  test $ac_status = 0; } > conftest.i && {
2249	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2250	 test ! -s conftest.err
2251       }; then :
2252  ac_retval=0
2253else
2254  $as_echo "$as_me: failed program was:" >&5
2255sed 's/^/| /' conftest.$ac_ext >&5
2256
2257    ac_retval=1
2258fi
2259  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2260  as_fn_set_status $ac_retval
2261
2262} # ac_fn_c_try_cpp
2263
2264# ac_fn_cxx_try_cpp LINENO
2265# ------------------------
2266# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2267ac_fn_cxx_try_cpp ()
2268{
2269  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2270  if { { ac_try="$ac_cpp conftest.$ac_ext"
2271case "(($ac_try" in
2272  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2273  *) ac_try_echo=$ac_try;;
2274esac
2275eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2276$as_echo "$ac_try_echo"; } >&5
2277  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2278  ac_status=$?
2279  if test -s conftest.err; then
2280    grep -v '^ *+' conftest.err >conftest.er1
2281    cat conftest.er1 >&5
2282    mv -f conftest.er1 conftest.err
2283  fi
2284  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2285  test $ac_status = 0; } > conftest.i && {
2286	 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2287	 test ! -s conftest.err
2288       }; then :
2289  ac_retval=0
2290else
2291  $as_echo "$as_me: failed program was:" >&5
2292sed 's/^/| /' conftest.$ac_ext >&5
2293
2294    ac_retval=1
2295fi
2296  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2297  as_fn_set_status $ac_retval
2298
2299} # ac_fn_cxx_try_cpp
2300
2301# ac_fn_objc_try_compile LINENO
2302# -----------------------------
2303# Try to compile conftest.$ac_ext, and return whether this succeeded.
2304ac_fn_objc_try_compile ()
2305{
2306  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2307  rm -f conftest.$ac_objext
2308  if { { ac_try="$ac_compile"
2309case "(($ac_try" in
2310  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2311  *) ac_try_echo=$ac_try;;
2312esac
2313eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2314$as_echo "$ac_try_echo"; } >&5
2315  (eval "$ac_compile") 2>conftest.err
2316  ac_status=$?
2317  if test -s conftest.err; then
2318    grep -v '^ *+' conftest.err >conftest.er1
2319    cat conftest.er1 >&5
2320    mv -f conftest.er1 conftest.err
2321  fi
2322  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2323  test $ac_status = 0; } && {
2324	 test -z "$ac_objc_werror_flag" ||
2325	 test ! -s conftest.err
2326       } && test -s conftest.$ac_objext; then :
2327  ac_retval=0
2328else
2329  $as_echo "$as_me: failed program was:" >&5
2330sed 's/^/| /' conftest.$ac_ext >&5
2331
2332	ac_retval=1
2333fi
2334  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2335  as_fn_set_status $ac_retval
2336
2337} # ac_fn_objc_try_compile
2338
2339# ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
2340# ---------------------------------------------------------
2341# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2342# the include files in INCLUDES and setting the cache variable VAR
2343# accordingly.
2344ac_fn_cxx_check_header_mongrel ()
2345{
2346  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2347  if eval \${$3+:} false; then :
2348  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2349$as_echo_n "checking for $2... " >&6; }
2350if eval \${$3+:} false; then :
2351  $as_echo_n "(cached) " >&6
2352fi
2353eval ac_res=\$$3
2354	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2355$as_echo "$ac_res" >&6; }
2356else
2357  # Is the header compilable?
2358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2359$as_echo_n "checking $2 usability... " >&6; }
2360cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2361/* end confdefs.h.  */
2362$4
2363#include <$2>
2364_ACEOF
2365if ac_fn_cxx_try_compile "$LINENO"; then :
2366  ac_header_compiler=yes
2367else
2368  ac_header_compiler=no
2369fi
2370rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2371{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2372$as_echo "$ac_header_compiler" >&6; }
2373
2374# Is the header present?
2375{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2376$as_echo_n "checking $2 presence... " >&6; }
2377cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2378/* end confdefs.h.  */
2379#include <$2>
2380_ACEOF
2381if ac_fn_cxx_try_cpp "$LINENO"; then :
2382  ac_header_preproc=yes
2383else
2384  ac_header_preproc=no
2385fi
2386rm -f conftest.err conftest.i conftest.$ac_ext
2387{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2388$as_echo "$ac_header_preproc" >&6; }
2389
2390# So?  What about this header?
2391case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
2392  yes:no: )
2393    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2394$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2395    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2396$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2397    ;;
2398  no:yes:* )
2399    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2400$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2401    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2402$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2403    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2404$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2405    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2406$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2407    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2408$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2409( $as_echo "## ----------------------------------------- ##
2410## Report this to build-dev@openjdk.java.net ##
2411## ----------------------------------------- ##"
2412     ) | sed "s/^/$as_me: WARNING:     /" >&2
2413    ;;
2414esac
2415  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2416$as_echo_n "checking for $2... " >&6; }
2417if eval \${$3+:} false; then :
2418  $as_echo_n "(cached) " >&6
2419else
2420  eval "$3=\$ac_header_compiler"
2421fi
2422eval ac_res=\$$3
2423	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2424$as_echo "$ac_res" >&6; }
2425fi
2426  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2427
2428} # ac_fn_cxx_check_header_mongrel
2429
2430# ac_fn_cxx_try_run LINENO
2431# ------------------------
2432# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2433# that executables *can* be run.
2434ac_fn_cxx_try_run ()
2435{
2436  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2437  if { { ac_try="$ac_link"
2438case "(($ac_try" in
2439  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2440  *) ac_try_echo=$ac_try;;
2441esac
2442eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2443$as_echo "$ac_try_echo"; } >&5
2444  (eval "$ac_link") 2>&5
2445  ac_status=$?
2446  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2447  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2448  { { case "(($ac_try" in
2449  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2450  *) ac_try_echo=$ac_try;;
2451esac
2452eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2453$as_echo "$ac_try_echo"; } >&5
2454  (eval "$ac_try") 2>&5
2455  ac_status=$?
2456  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2457  test $ac_status = 0; }; }; then :
2458  ac_retval=0
2459else
2460  $as_echo "$as_me: program exited with status $ac_status" >&5
2461       $as_echo "$as_me: failed program was:" >&5
2462sed 's/^/| /' conftest.$ac_ext >&5
2463
2464       ac_retval=$ac_status
2465fi
2466  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2467  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2468  as_fn_set_status $ac_retval
2469
2470} # ac_fn_cxx_try_run
2471
2472# ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
2473# ---------------------------------------------------------
2474# Tests whether HEADER exists and can be compiled using the include files in
2475# INCLUDES, setting the cache variable VAR accordingly.
2476ac_fn_cxx_check_header_compile ()
2477{
2478  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2479  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2480$as_echo_n "checking for $2... " >&6; }
2481if eval \${$3+:} false; then :
2482  $as_echo_n "(cached) " >&6
2483else
2484  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2485/* end confdefs.h.  */
2486$4
2487#include <$2>
2488_ACEOF
2489if ac_fn_cxx_try_compile "$LINENO"; then :
2490  eval "$3=yes"
2491else
2492  eval "$3=no"
2493fi
2494rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2495fi
2496eval ac_res=\$$3
2497	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2498$as_echo "$ac_res" >&6; }
2499  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2500
2501} # ac_fn_cxx_check_header_compile
2502
2503# ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES
2504# ----------------------------------------------
2505# Tries to find the compile-time value of EXPR in a program that includes
2506# INCLUDES, setting VAR accordingly. Returns whether the value could be
2507# computed
2508ac_fn_cxx_compute_int ()
2509{
2510  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2511  if test "$cross_compiling" = yes; then
2512    # Depending upon the size, compute the lo and hi bounds.
2513cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2514/* end confdefs.h.  */
2515$4
2516int
2517main ()
2518{
2519static int test_array [1 - 2 * !(($2) >= 0)];
2520test_array [0] = 0;
2521return test_array [0];
2522
2523  ;
2524  return 0;
2525}
2526_ACEOF
2527if ac_fn_cxx_try_compile "$LINENO"; then :
2528  ac_lo=0 ac_mid=0
2529  while :; do
2530    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2531/* end confdefs.h.  */
2532$4
2533int
2534main ()
2535{
2536static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2537test_array [0] = 0;
2538return test_array [0];
2539
2540  ;
2541  return 0;
2542}
2543_ACEOF
2544if ac_fn_cxx_try_compile "$LINENO"; then :
2545  ac_hi=$ac_mid; break
2546else
2547  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2548			if test $ac_lo -le $ac_mid; then
2549			  ac_lo= ac_hi=
2550			  break
2551			fi
2552			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2553fi
2554rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2555  done
2556else
2557  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2558/* end confdefs.h.  */
2559$4
2560int
2561main ()
2562{
2563static int test_array [1 - 2 * !(($2) < 0)];
2564test_array [0] = 0;
2565return test_array [0];
2566
2567  ;
2568  return 0;
2569}
2570_ACEOF
2571if ac_fn_cxx_try_compile "$LINENO"; then :
2572  ac_hi=-1 ac_mid=-1
2573  while :; do
2574    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2575/* end confdefs.h.  */
2576$4
2577int
2578main ()
2579{
2580static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2581test_array [0] = 0;
2582return test_array [0];
2583
2584  ;
2585  return 0;
2586}
2587_ACEOF
2588if ac_fn_cxx_try_compile "$LINENO"; then :
2589  ac_lo=$ac_mid; break
2590else
2591  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2592			if test $ac_mid -le $ac_hi; then
2593			  ac_lo= ac_hi=
2594			  break
2595			fi
2596			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2597fi
2598rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2599  done
2600else
2601  ac_lo= ac_hi=
2602fi
2603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2604fi
2605rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2606# Binary search between lo and hi bounds.
2607while test "x$ac_lo" != "x$ac_hi"; do
2608  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2609  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2610/* end confdefs.h.  */
2611$4
2612int
2613main ()
2614{
2615static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2616test_array [0] = 0;
2617return test_array [0];
2618
2619  ;
2620  return 0;
2621}
2622_ACEOF
2623if ac_fn_cxx_try_compile "$LINENO"; then :
2624  ac_hi=$ac_mid
2625else
2626  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2627fi
2628rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2629done
2630case $ac_lo in #((
2631?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2632'') ac_retval=1 ;;
2633esac
2634  else
2635    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2636/* end confdefs.h.  */
2637$4
2638static long int longval () { return $2; }
2639static unsigned long int ulongval () { return $2; }
2640#include <stdio.h>
2641#include <stdlib.h>
2642int
2643main ()
2644{
2645
2646  FILE *f = fopen ("conftest.val", "w");
2647  if (! f)
2648    return 1;
2649  if (($2) < 0)
2650    {
2651      long int i = longval ();
2652      if (i != ($2))
2653	return 1;
2654      fprintf (f, "%ld", i);
2655    }
2656  else
2657    {
2658      unsigned long int i = ulongval ();
2659      if (i != ($2))
2660	return 1;
2661      fprintf (f, "%lu", i);
2662    }
2663  /* Do not output a trailing newline, as this causes \r\n confusion
2664     on some platforms.  */
2665  return ferror (f) || fclose (f) != 0;
2666
2667  ;
2668  return 0;
2669}
2670_ACEOF
2671if ac_fn_cxx_try_run "$LINENO"; then :
2672  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2673else
2674  ac_retval=1
2675fi
2676rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2677  conftest.$ac_objext conftest.beam conftest.$ac_ext
2678rm -f conftest.val
2679
2680  fi
2681  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2682  as_fn_set_status $ac_retval
2683
2684} # ac_fn_cxx_compute_int
2685
2686# ac_fn_cxx_try_link LINENO
2687# -------------------------
2688# Try to link conftest.$ac_ext, and return whether this succeeded.
2689ac_fn_cxx_try_link ()
2690{
2691  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2692  rm -f conftest.$ac_objext conftest$ac_exeext
2693  if { { ac_try="$ac_link"
2694case "(($ac_try" in
2695  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2696  *) ac_try_echo=$ac_try;;
2697esac
2698eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2699$as_echo "$ac_try_echo"; } >&5
2700  (eval "$ac_link") 2>conftest.err
2701  ac_status=$?
2702  if test -s conftest.err; then
2703    grep -v '^ *+' conftest.err >conftest.er1
2704    cat conftest.er1 >&5
2705    mv -f conftest.er1 conftest.err
2706  fi
2707  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2708  test $ac_status = 0; } && {
2709	 test -z "$ac_cxx_werror_flag" ||
2710	 test ! -s conftest.err
2711       } && test -s conftest$ac_exeext && {
2712	 test "$cross_compiling" = yes ||
2713	 test -x conftest$ac_exeext
2714       }; then :
2715  ac_retval=0
2716else
2717  $as_echo "$as_me: failed program was:" >&5
2718sed 's/^/| /' conftest.$ac_ext >&5
2719
2720	ac_retval=1
2721fi
2722  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2723  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2724  # interfere with the next link command; also delete a directory that is
2725  # left behind by Apple's compiler.  We do this before executing the actions.
2726  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2727  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2728  as_fn_set_status $ac_retval
2729
2730} # ac_fn_cxx_try_link
2731
2732# ac_fn_cxx_check_func LINENO FUNC VAR
2733# ------------------------------------
2734# Tests whether FUNC exists, setting the cache variable VAR accordingly
2735ac_fn_cxx_check_func ()
2736{
2737  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2738  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2739$as_echo_n "checking for $2... " >&6; }
2740if eval \${$3+:} false; then :
2741  $as_echo_n "(cached) " >&6
2742else
2743  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2744/* end confdefs.h.  */
2745/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2746   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2747#define $2 innocuous_$2
2748
2749/* System header to define __stub macros and hopefully few prototypes,
2750    which can conflict with char $2 (); below.
2751    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2752    <limits.h> exists even on freestanding compilers.  */
2753
2754#ifdef __STDC__
2755# include <limits.h>
2756#else
2757# include <assert.h>
2758#endif
2759
2760#undef $2
2761
2762/* Override any GCC internal prototype to avoid an error.
2763   Use char because int might match the return type of a GCC
2764   builtin and then its argument prototype would still apply.  */
2765#ifdef __cplusplus
2766extern "C"
2767#endif
2768char $2 ();
2769/* The GNU C library defines this for functions which it implements
2770    to always fail with ENOSYS.  Some functions are actually named
2771    something starting with __ and the normal name is an alias.  */
2772#if defined __stub_$2 || defined __stub___$2
2773choke me
2774#endif
2775
2776int
2777main ()
2778{
2779return $2 ();
2780  ;
2781  return 0;
2782}
2783_ACEOF
2784if ac_fn_cxx_try_link "$LINENO"; then :
2785  eval "$3=yes"
2786else
2787  eval "$3=no"
2788fi
2789rm -f core conftest.err conftest.$ac_objext \
2790    conftest$ac_exeext conftest.$ac_ext
2791fi
2792eval ac_res=\$$3
2793	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2794$as_echo "$ac_res" >&6; }
2795  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2796
2797} # ac_fn_cxx_check_func
2798
2799# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2800# -------------------------------------------------------
2801# Tests whether HEADER exists and can be compiled using the include files in
2802# INCLUDES, setting the cache variable VAR accordingly.
2803ac_fn_c_check_header_compile ()
2804{
2805  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2806  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2807$as_echo_n "checking for $2... " >&6; }
2808if eval \${$3+:} false; then :
2809  $as_echo_n "(cached) " >&6
2810else
2811  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2812/* end confdefs.h.  */
2813$4
2814#include <$2>
2815_ACEOF
2816if ac_fn_c_try_compile "$LINENO"; then :
2817  eval "$3=yes"
2818else
2819  eval "$3=no"
2820fi
2821rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2822fi
2823eval ac_res=\$$3
2824	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2825$as_echo "$ac_res" >&6; }
2826  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2827
2828} # ac_fn_c_check_header_compile
2829cat >config.log <<_ACEOF
2830This file contains any messages produced by compilers while
2831running configure, to aid debugging if configure makes a mistake.
2832
2833It was created by OpenJDK $as_me jdk9, which was
2834generated by GNU Autoconf 2.69.  Invocation command line was
2835
2836  $ $0 $@
2837
2838_ACEOF
2839exec 5>>config.log
2840{
2841cat <<_ASUNAME
2842## --------- ##
2843## Platform. ##
2844## --------- ##
2845
2846hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2847uname -m = `(uname -m) 2>/dev/null || echo unknown`
2848uname -r = `(uname -r) 2>/dev/null || echo unknown`
2849uname -s = `(uname -s) 2>/dev/null || echo unknown`
2850uname -v = `(uname -v) 2>/dev/null || echo unknown`
2851
2852/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2853/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2854
2855/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2856/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2857/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2858/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2859/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2860/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2861/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2862
2863_ASUNAME
2864
2865as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2866for as_dir in $PATH
2867do
2868  IFS=$as_save_IFS
2869  test -z "$as_dir" && as_dir=.
2870    $as_echo "PATH: $as_dir"
2871  done
2872IFS=$as_save_IFS
2873
2874} >&5
2875
2876cat >&5 <<_ACEOF
2877
2878
2879## ----------- ##
2880## Core tests. ##
2881## ----------- ##
2882
2883_ACEOF
2884
2885
2886# Keep a trace of the command line.
2887# Strip out --no-create and --no-recursion so they do not pile up.
2888# Strip out --silent because we don't want to record it for future runs.
2889# Also quote any args containing shell meta-characters.
2890# Make two passes to allow for proper duplicate-argument suppression.
2891ac_configure_args=
2892ac_configure_args0=
2893ac_configure_args1=
2894ac_must_keep_next=false
2895for ac_pass in 1 2
2896do
2897  for ac_arg
2898  do
2899    case $ac_arg in
2900    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2901    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2902    | -silent | --silent | --silen | --sile | --sil)
2903      continue ;;
2904    *\'*)
2905      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2906    esac
2907    case $ac_pass in
2908    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2909    2)
2910      as_fn_append ac_configure_args1 " '$ac_arg'"
2911      if test $ac_must_keep_next = true; then
2912	ac_must_keep_next=false # Got value, back to normal.
2913      else
2914	case $ac_arg in
2915	  *=* | --config-cache | -C | -disable-* | --disable-* \
2916	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2917	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2918	  | -with-* | --with-* | -without-* | --without-* | --x)
2919	    case "$ac_configure_args0 " in
2920	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2921	    esac
2922	    ;;
2923	  -* ) ac_must_keep_next=true ;;
2924	esac
2925      fi
2926      as_fn_append ac_configure_args " '$ac_arg'"
2927      ;;
2928    esac
2929  done
2930done
2931{ ac_configure_args0=; unset ac_configure_args0;}
2932{ ac_configure_args1=; unset ac_configure_args1;}
2933
2934# When interrupted or exit'd, cleanup temporary files, and complete
2935# config.log.  We remove comments because anyway the quotes in there
2936# would cause problems or look ugly.
2937# WARNING: Use '\'' to represent an apostrophe within the trap.
2938# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2939trap 'exit_status=$?
2940  # Save into config.log some information that might help in debugging.
2941  {
2942    echo
2943
2944    $as_echo "## ---------------- ##
2945## Cache variables. ##
2946## ---------------- ##"
2947    echo
2948    # The following way of writing the cache mishandles newlines in values,
2949(
2950  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2951    eval ac_val=\$$ac_var
2952    case $ac_val in #(
2953    *${as_nl}*)
2954      case $ac_var in #(
2955      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2956$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2957      esac
2958      case $ac_var in #(
2959      _ | IFS | as_nl) ;; #(
2960      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2961      *) { eval $ac_var=; unset $ac_var;} ;;
2962      esac ;;
2963    esac
2964  done
2965  (set) 2>&1 |
2966    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2967    *${as_nl}ac_space=\ *)
2968      sed -n \
2969	"s/'\''/'\''\\\\'\'''\''/g;
2970	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2971      ;; #(
2972    *)
2973      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2974      ;;
2975    esac |
2976    sort
2977)
2978    echo
2979
2980    $as_echo "## ----------------- ##
2981## Output variables. ##
2982## ----------------- ##"
2983    echo
2984    for ac_var in $ac_subst_vars
2985    do
2986      eval ac_val=\$$ac_var
2987      case $ac_val in
2988      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2989      esac
2990      $as_echo "$ac_var='\''$ac_val'\''"
2991    done | sort
2992    echo
2993
2994    if test -n "$ac_subst_files"; then
2995      $as_echo "## ------------------- ##
2996## File substitutions. ##
2997## ------------------- ##"
2998      echo
2999      for ac_var in $ac_subst_files
3000      do
3001	eval ac_val=\$$ac_var
3002	case $ac_val in
3003	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3004	esac
3005	$as_echo "$ac_var='\''$ac_val'\''"
3006      done | sort
3007      echo
3008    fi
3009
3010    if test -s confdefs.h; then
3011      $as_echo "## ----------- ##
3012## confdefs.h. ##
3013## ----------- ##"
3014      echo
3015      cat confdefs.h
3016      echo
3017    fi
3018    test "$ac_signal" != 0 &&
3019      $as_echo "$as_me: caught signal $ac_signal"
3020    $as_echo "$as_me: exit $exit_status"
3021  } >&5
3022  rm -f core *.core core.conftest.* &&
3023    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3024    exit $exit_status
3025' 0
3026for ac_signal in 1 2 13 15; do
3027  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3028done
3029ac_signal=0
3030
3031# confdefs.h avoids OS command line length limits that DEFS can exceed.
3032rm -f -r conftest* confdefs.h
3033
3034$as_echo "/* confdefs.h */" > confdefs.h
3035
3036# Predefined preprocessor variables.
3037
3038cat >>confdefs.h <<_ACEOF
3039#define PACKAGE_NAME "$PACKAGE_NAME"
3040_ACEOF
3041
3042cat >>confdefs.h <<_ACEOF
3043#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3044_ACEOF
3045
3046cat >>confdefs.h <<_ACEOF
3047#define PACKAGE_VERSION "$PACKAGE_VERSION"
3048_ACEOF
3049
3050cat >>confdefs.h <<_ACEOF
3051#define PACKAGE_STRING "$PACKAGE_STRING"
3052_ACEOF
3053
3054cat >>confdefs.h <<_ACEOF
3055#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3056_ACEOF
3057
3058cat >>confdefs.h <<_ACEOF
3059#define PACKAGE_URL "$PACKAGE_URL"
3060_ACEOF
3061
3062
3063# Let the site file select an alternate cache file if it wants to.
3064# Prefer an explicitly selected file to automatically selected ones.
3065ac_site_file1=NONE
3066ac_site_file2=NONE
3067if test -n "$CONFIG_SITE"; then
3068  # We do not want a PATH search for config.site.
3069  case $CONFIG_SITE in #((
3070    -*)  ac_site_file1=./$CONFIG_SITE;;
3071    */*) ac_site_file1=$CONFIG_SITE;;
3072    *)   ac_site_file1=./$CONFIG_SITE;;
3073  esac
3074elif test "x$prefix" != xNONE; then
3075  ac_site_file1=$prefix/share/config.site
3076  ac_site_file2=$prefix/etc/config.site
3077else
3078  ac_site_file1=$ac_default_prefix/share/config.site
3079  ac_site_file2=$ac_default_prefix/etc/config.site
3080fi
3081for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3082do
3083  test "x$ac_site_file" = xNONE && continue
3084  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3085    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3086$as_echo "$as_me: loading site script $ac_site_file" >&6;}
3087    sed 's/^/| /' "$ac_site_file" >&5
3088    . "$ac_site_file" \
3089      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3090$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3091as_fn_error $? "failed to load site script $ac_site_file
3092See \`config.log' for more details" "$LINENO" 5; }
3093  fi
3094done
3095
3096if test -r "$cache_file"; then
3097  # Some versions of bash will fail to source /dev/null (special files
3098  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3099  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3100    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3101$as_echo "$as_me: loading cache $cache_file" >&6;}
3102    case $cache_file in
3103      [\\/]* | ?:[\\/]* ) . "$cache_file";;
3104      *)                      . "./$cache_file";;
3105    esac
3106  fi
3107else
3108  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3109$as_echo "$as_me: creating cache $cache_file" >&6;}
3110  >$cache_file
3111fi
3112
3113# Check that the precious variables saved in the cache have kept the same
3114# value.
3115ac_cache_corrupted=false
3116for ac_var in $ac_precious_vars; do
3117  eval ac_old_set=\$ac_cv_env_${ac_var}_set
3118  eval ac_new_set=\$ac_env_${ac_var}_set
3119  eval ac_old_val=\$ac_cv_env_${ac_var}_value
3120  eval ac_new_val=\$ac_env_${ac_var}_value
3121  case $ac_old_set,$ac_new_set in
3122    set,)
3123      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3124$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3125      ac_cache_corrupted=: ;;
3126    ,set)
3127      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3128$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3129      ac_cache_corrupted=: ;;
3130    ,);;
3131    *)
3132      if test "x$ac_old_val" != "x$ac_new_val"; then
3133	# differences in whitespace do not lead to failure.
3134	ac_old_val_w=`echo x $ac_old_val`
3135	ac_new_val_w=`echo x $ac_new_val`
3136	if test "$ac_old_val_w" != "$ac_new_val_w"; then
3137	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3138$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3139	  ac_cache_corrupted=:
3140	else
3141	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3142$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3143	  eval $ac_var=\$ac_old_val
3144	fi
3145	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
3146$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
3147	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
3148$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
3149      fi;;
3150  esac
3151  # Pass precious variables to config.status.
3152  if test "$ac_new_set" = set; then
3153    case $ac_new_val in
3154    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3155    *) ac_arg=$ac_var=$ac_new_val ;;
3156    esac
3157    case " $ac_configure_args " in
3158      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
3159      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3160    esac
3161  fi
3162done
3163if $ac_cache_corrupted; then
3164  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3165$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3166  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3167$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3168  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3169fi
3170## -------------------- ##
3171## Main body of script. ##
3172## -------------------- ##
3173
3174ac_ext=c
3175ac_cpp='$CPP $CPPFLAGS'
3176ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3177ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3178ac_compiler_gnu=$ac_cv_c_compiler_gnu
3179
3180
3181
3182ac_aux_dir=
3183for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do
3184  if test -f "$ac_dir/install-sh"; then
3185    ac_aux_dir=$ac_dir
3186    ac_install_sh="$ac_aux_dir/install-sh -c"
3187    break
3188  elif test -f "$ac_dir/install.sh"; then
3189    ac_aux_dir=$ac_dir
3190    ac_install_sh="$ac_aux_dir/install.sh -c"
3191    break
3192  elif test -f "$ac_dir/shtool"; then
3193    ac_aux_dir=$ac_dir
3194    ac_install_sh="$ac_aux_dir/shtool install -c"
3195    break
3196  fi
3197done
3198if test -z "$ac_aux_dir"; then
3199  as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/common/autoconf/build-aux \"$srcdir\"/$TOPDIR/common/autoconf/build-aux" "$LINENO" 5
3200fi
3201
3202# These three variables are undocumented and unsupported,
3203# and are intended to be withdrawn in a future Autoconf release.
3204# They can cause serious problems if a builder's source tree is in a directory
3205# whose full name contains unusual characters.
3206ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3207ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3208ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3209
3210
3211# pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
3212
3213#
3214# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
3215# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3216#
3217# This code is free software; you can redistribute it and/or modify it
3218# under the terms of the GNU General Public License version 2 only, as
3219# published by the Free Software Foundation.  Oracle designates this
3220# particular file as subject to the "Classpath" exception as provided
3221# by Oracle in the LICENSE file that accompanied this code.
3222#
3223# This code is distributed in the hope that it will be useful, but WITHOUT
3224# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3225# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3226# version 2 for more details (a copy is included in the LICENSE file that
3227# accompanied this code).
3228#
3229# You should have received a copy of the GNU General Public License version
3230# 2 along with this work; if not, write to the Free Software Foundation,
3231# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3232#
3233# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3234# or visit www.oracle.com if you need additional information or have any
3235# questions.
3236#
3237
3238#
3239# Copyright �� 2004 Scott James Remnant <scott@netsplit.com>.
3240#
3241# This program is free software; you can redistribute it and/or modify
3242# it under the terms of the GNU General Public License as published by
3243# the Free Software Foundation; either version 2 of the License, or
3244# (at your option) any later version.
3245#
3246# This program is distributed in the hope that it will be useful, but
3247# WITHOUT ANY WARRANTY; without even the implied warranty of
3248# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
3249# General Public License for more details.
3250#
3251# You should have received a copy of the GNU General Public License
3252# along with this program; if not, write to the Free Software
3253# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
3254#
3255# As a special exception to the GNU General Public License, if you
3256# distribute this file as part of a program that contains a
3257# configuration script generated by Autoconf, you may include it under
3258# the same distribution terms that you use for the rest of that program.
3259
3260# PKG_PROG_PKG_CONFIG([MIN-VERSION])
3261# ----------------------------------
3262# PKG_PROG_PKG_CONFIG
3263
3264# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
3265#
3266# Check to see whether a particular set of modules exists.  Similar
3267# to PKG_CHECK_MODULES(), but does not set variables or print errors.
3268#
3269#
3270# Similar to PKG_CHECK_MODULES, make sure that the first instance of
3271# this or PKG_CHECK_MODULES is called, or make sure to call
3272# PKG_CHECK_EXISTS manually
3273# --------------------------------------------------------------
3274
3275
3276
3277# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
3278# ---------------------------------------------
3279# _PKG_CONFIG
3280
3281# _PKG_SHORT_ERRORS_SUPPORTED
3282# -----------------------------
3283# _PKG_SHORT_ERRORS_SUPPORTED
3284
3285
3286# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
3287# [ACTION-IF-NOT-FOUND])
3288#
3289#
3290# Note that if there is a possibility the first call to
3291# PKG_CHECK_MODULES might not happen, you should be sure to include an
3292# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
3293#
3294#
3295# --------------------------------------------------------------
3296# PKG_CHECK_MODULES
3297
3298
3299# Include these first...
3300#
3301# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3302# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3303#
3304# This code is free software; you can redistribute it and/or modify it
3305# under the terms of the GNU General Public License version 2 only, as
3306# published by the Free Software Foundation.  Oracle designates this
3307# particular file as subject to the "Classpath" exception as provided
3308# by Oracle in the LICENSE file that accompanied this code.
3309#
3310# This code is distributed in the hope that it will be useful, but WITHOUT
3311# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3312# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3313# version 2 for more details (a copy is included in the LICENSE file that
3314# accompanied this code).
3315#
3316# You should have received a copy of the GNU General Public License version
3317# 2 along with this work; if not, write to the Free Software Foundation,
3318# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3319#
3320# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3321# or visit www.oracle.com if you need additional information or have any
3322# questions.
3323#
3324
3325# Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3326# If so, then append $1 to $2 \
3327# Also set JVM_ARG_OK to true/false depending on outcome.
3328
3329
3330# Appends a string to a path variable, only adding the : when needed.
3331
3332
3333# Prepends a string to a path variable, only adding the : when needed.
3334
3335
3336# This will make sure the given variable points to a full and proper
3337# path. This means:
3338# 1) There will be no spaces in the path. On posix platforms,
3339#    spaces in the path will result in an error. On Windows,
3340#    the path will be rewritten using short-style to be space-free.
3341# 2) The path will be absolute, and it will be in unix-style (on
3342#     cygwin).
3343# $1: The name of the variable to fix
3344
3345
3346# This will make sure the given variable points to a executable
3347# with a full and proper path. This means:
3348# 1) There will be no spaces in the path. On posix platforms,
3349#    spaces in the path will result in an error. On Windows,
3350#    the path will be rewritten using short-style to be space-free.
3351# 2) The path will be absolute, and it will be in unix-style (on
3352#     cygwin).
3353# Any arguments given to the executable is preserved.
3354# If the input variable does not have a directory specification, then
3355# it need to be in the PATH.
3356# $1: The name of the variable to fix
3357
3358
3359
3360
3361# Register a --with argument but mark it as deprecated
3362# $1: The name of the with argument to deprecate, not including --with-
3363
3364
3365# Register a --enable argument but mark it as deprecated
3366# $1: The name of the with argument to deprecate, not including --enable-
3367# $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -)
3368
3369
3370
3371
3372# Test that variable $1 denoting a program is not empty. If empty, exit with an error.
3373# $1: variable to check
3374
3375
3376# Check that there are no unprocessed overridden variables left.
3377# If so, they are an incorrect argument and we will exit with an error.
3378
3379
3380# Setup a tool for the given variable. If correctly specified by the user,
3381# use that value, otherwise search for the tool using the supplied code snippet.
3382# $1: variable to set
3383# $2: code snippet to call to look for the tool
3384
3385
3386# Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool
3387# $1: variable to set
3388# $2: executable name (or list of names) to look for
3389
3390
3391# Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool
3392# $1: variable to set
3393# $2: executable name (or list of names) to look for
3394
3395
3396# Like BASIC_PATH_PROGS but fails if no tool was found.
3397# $1: variable to set
3398# $2: executable name (or list of names) to look for
3399
3400
3401# Like BASIC_SETUP_TOOL but fails if no tool was found.
3402# $1: variable to set
3403# $2: autoconf macro to call to look for the special tool
3404
3405
3406# Setup the most fundamental tools that relies on not much else to set up,
3407# but is used by much of the early bootstrap code.
3408
3409
3410# Setup basic configuration paths, and platform-specific stuff related to PATHs.
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420#%%% Simple tools %%%
3421
3422# Check if we have found a usable version of make
3423# $1: the path to a potential make binary (or empty)
3424# $2: the description on how we found this
3425
3426
3427# Goes looking for a usable version of GNU make.
3428
3429
3430
3431
3432
3433
3434# Check if build directory is on local disk. If not possible to determine,
3435# we prefer to claim it's local.
3436# Argument 1: directory to test
3437# Argument 2: what to do if it is on local disk
3438# Argument 3: what to do otherwise (remote disk or failure)
3439
3440
3441# Check that source files have basic read permissions set. This might
3442# not be the case in cygwin in certain conditions.
3443
3444
3445
3446
3447#
3448# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3449# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3450#
3451# This code is free software; you can redistribute it and/or modify it
3452# under the terms of the GNU General Public License version 2 only, as
3453# published by the Free Software Foundation.  Oracle designates this
3454# particular file as subject to the "Classpath" exception as provided
3455# by Oracle in the LICENSE file that accompanied this code.
3456#
3457# This code is distributed in the hope that it will be useful, but WITHOUT
3458# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3459# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3460# version 2 for more details (a copy is included in the LICENSE file that
3461# accompanied this code).
3462#
3463# You should have received a copy of the GNU General Public License version
3464# 2 along with this work; if not, write to the Free Software Foundation,
3465# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3466#
3467# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3468# or visit www.oracle.com if you need additional information or have any
3469# questions.
3470#
3471
3472
3473
3474
3475
3476# Helper function which possibly converts a path using DOS-style short mode.
3477# If so, the updated path is stored in $new_path.
3478# $1: The path to check
3479
3480
3481# Helper function which possibly converts a path using DOS-style short mode.
3482# If so, the updated path is stored in $new_path.
3483# $1: The path to check
3484
3485
3486# FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted
3487# and could probably be heavily simplified. However, all changes in this
3488# area tend to need lot of testing in different scenarios, and in lack of
3489# proper unit testing, cleaning this up has not been deemed worth the effort
3490# at the moment.
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500# Setup basic configuration paths, and platform-specific stuff related to PATHs.
3501
3502
3503
3504
3505#
3506# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3507# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3508#
3509# This code is free software; you can redistribute it and/or modify it
3510# under the terms of the GNU General Public License version 2 only, as
3511# published by the Free Software Foundation.  Oracle designates this
3512# particular file as subject to the "Classpath" exception as provided
3513# by Oracle in the LICENSE file that accompanied this code.
3514#
3515# This code is distributed in the hope that it will be useful, but WITHOUT
3516# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3517# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3518# version 2 for more details (a copy is included in the LICENSE file that
3519# accompanied this code).
3520#
3521# You should have received a copy of the GNU General Public License version
3522# 2 along with this work; if not, write to the Free Software Foundation,
3523# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3524#
3525# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3526# or visit www.oracle.com if you need additional information or have any
3527# questions.
3528#
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540# ... then the rest
3541#
3542# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3543# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3544#
3545# This code is free software; you can redistribute it and/or modify it
3546# under the terms of the GNU General Public License version 2 only, as
3547# published by the Free Software Foundation.  Oracle designates this
3548# particular file as subject to the "Classpath" exception as provided
3549# by Oracle in the LICENSE file that accompanied this code.
3550#
3551# This code is distributed in the hope that it will be useful, but WITHOUT
3552# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3553# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3554# version 2 for more details (a copy is included in the LICENSE file that
3555# accompanied this code).
3556#
3557# You should have received a copy of the GNU General Public License version
3558# 2 along with this work; if not, write to the Free Software Foundation,
3559# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3560#
3561# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3562# or visit www.oracle.com if you need additional information or have any
3563# questions.
3564#
3565
3566########################################################################
3567# This file handles detection of the Boot JDK. The Boot JDK detection
3568# process has been developed as a response to solve a complex real-world
3569# problem. Initially, it was simple, but it has grown as platform after
3570# platform, idiosyncracy after idiosyncracy has been supported.
3571#
3572# The basic idea is this:
3573# 1) You need an acceptable *) JDK to use as a Boot JDK
3574# 2) There are several ways to locate a JDK, that are mostly platform
3575#    dependent **)
3576# 3) You can have multiple JDKs installed
3577# 4) If possible, configure should try to dig out an acceptable JDK
3578#    automatically, without having to resort to command-line options
3579#
3580# *)  acceptable means e.g. JDK7 for building JDK8, a complete JDK (with
3581#     javac) and not a JRE, etc.
3582#
3583# **) On Windows we typically use a well-known path.
3584#     On MacOSX we typically use the tool java_home.
3585#     On Linux we typically find javac in the $PATH, and then follow a
3586#     chain of symlinks that often ends up in a real JDK.
3587#
3588# This leads to the code where we check in different ways to locate a
3589# JDK, and if one is found, check if it is acceptable. If not, we print
3590# our reasons for rejecting it (useful when debugging non-working
3591# configure situations) and continue checking the next one.
3592########################################################################
3593
3594# Execute the check given as argument, and verify the result
3595# If the Boot JDK was previously found, do nothing
3596# $1 A command line (typically autoconf macro) to execute
3597
3598
3599# Test: Is bootjdk explicitely set by command line arguments?
3600
3601
3602# Test: Is bootjdk available from builddeps?
3603
3604
3605# Test: Is $JAVA_HOME set?
3606
3607
3608# Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
3609
3610
3611# Test: Is there a /usr/libexec/java_home? (Typically on MacOSX)
3612# $1: Argument to the java_home binary (optional)
3613
3614
3615# Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
3616
3617
3618# Look for a jdk in the given path. If there are multiple, try to select the newest.
3619# If found, set BOOT_JDK and BOOT_JDK_FOUND.
3620# $1 = Path to directory containing jdk installations.
3621# $2 = String to append to the found JDK directory to get the proper JDK home
3622
3623
3624# Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given
3625# environmental variable as base for where to look.
3626# $1 Name of an environmal variable, assumed to point to the Program Files directory.
3627
3628
3629# Test: Is there a JDK installed in default, well-known locations?
3630
3631
3632# Check that a command-line tool in the Boot JDK is correct
3633# $1 = name of variable to assign
3634# $2 = name of binary
3635
3636
3637###############################################################################
3638#
3639# We need a Boot JDK to bootstrap the build.
3640#
3641
3642
3643
3644
3645
3646#
3647# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3648# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3649#
3650# This code is free software; you can redistribute it and/or modify it
3651# under the terms of the GNU General Public License version 2 only, as
3652# published by the Free Software Foundation.  Oracle designates this
3653# particular file as subject to the "Classpath" exception as provided
3654# by Oracle in the LICENSE file that accompanied this code.
3655#
3656# This code is distributed in the hope that it will be useful, but WITHOUT
3657# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3658# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3659# version 2 for more details (a copy is included in the LICENSE file that
3660# accompanied this code).
3661#
3662# You should have received a copy of the GNU General Public License version
3663# 2 along with this work; if not, write to the Free Software Foundation,
3664# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3665#
3666# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3667# or visit www.oracle.com if you need additional information or have any
3668# questions.
3669#
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690#
3691# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3692# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3693#
3694# This code is free software; you can redistribute it and/or modify it
3695# under the terms of the GNU General Public License version 2 only, as
3696# published by the Free Software Foundation.  Oracle designates this
3697# particular file as subject to the "Classpath" exception as provided
3698# by Oracle in the LICENSE file that accompanied this code.
3699#
3700# This code is distributed in the hope that it will be useful, but WITHOUT
3701# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3702# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3703# version 2 for more details (a copy is included in the LICENSE file that
3704# accompanied this code).
3705#
3706# You should have received a copy of the GNU General Public License version
3707# 2 along with this work; if not, write to the Free Software Foundation,
3708# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3709#
3710# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3711# or visit www.oracle.com if you need additional information or have any
3712# questions.
3713#
3714
3715
3716
3717
3718
3719# Documentation on common flags used for solstudio in HIGHEST.
3720#
3721# WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
3722#          done with care, there are some assumptions below that need to
3723#          be understood about the use of pointers, and IEEE behavior.
3724#
3725# -fns: Use non-standard floating point mode (not IEEE 754)
3726# -fsimple: Do some simplification of floating point arithmetic (not IEEE 754)
3727# -fsingle: Use single precision floating point with 'float'
3728# -xalias_level=basic: Assume memory references via basic pointer types do not alias
3729#   (Source with excessing pointer casting and data access with mixed
3730#    pointer types are not recommended)
3731# -xbuiltin=%all: Use intrinsic or inline versions for math/std functions
3732#   (If you expect perfect errno behavior, do not use this)
3733# -xdepend: Loop data dependency optimizations (need -xO3 or higher)
3734# -xrestrict: Pointer parameters to functions do not overlap
3735#   (Similar to -xalias_level=basic usage, but less obvious sometimes.
3736#    If you pass in multiple pointers to the same data, do not use this)
3737# -xlibmil: Inline some library routines
3738#   (If you expect perfect errno behavior, do not use this)
3739# -xlibmopt: Use optimized math routines (CURRENTLY DISABLED)
3740#   (If you expect perfect errno behavior, do not use this)
3741#  Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
3742
3743    # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore.
3744    # Bug?
3745    #if test "x$OPENJDK_TARGET_CPU" = xsparc; then
3746    #  CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s"
3747    #  CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s"
3748    #fi
3749
3750
3751
3752
3753
3754
3755# FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
3756#                                   [RUN-IF-FALSE])
3757# ------------------------------------------------------------
3758# Check that the c and c++ compilers support an argument
3759
3760
3761
3762
3763#
3764# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3765# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3766#
3767# This code is free software; you can redistribute it and/or modify it
3768# under the terms of the GNU General Public License version 2 only, as
3769# published by the Free Software Foundation.  Oracle designates this
3770# particular file as subject to the "Classpath" exception as provided
3771# by Oracle in the LICENSE file that accompanied this code.
3772#
3773# This code is distributed in the hope that it will be useful, but WITHOUT
3774# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3775# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3776# version 2 for more details (a copy is included in the LICENSE file that
3777# accompanied this code).
3778#
3779# You should have received a copy of the GNU General Public License version
3780# 2 along with this work; if not, write to the Free Software Foundation,
3781# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3782#
3783# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3784# or visit www.oracle.com if you need additional information or have any
3785# questions.
3786#
3787
3788
3789
3790
3791
3792cygwin_help() {
3793  case $1 in
3794    unzip)
3795      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )"
3796      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3797      ;;
3798    zip)
3799      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )"
3800      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3801      ;;
3802    make)
3803      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )"
3804      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3805      ;;
3806    freetype)
3807      if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
3808        HELP_MSG="To install freetype, run:
3809wget \"http://gnuwin32.sourceforge.net/downlinks/freetype.php\" -O /tmp/freetype-setup.exe
3810chmod +x /tmp/freetype-setup.exe
3811/tmp/freetype-setup.exe
3812Follow GUI prompts, and install to default directory \"C:\Program Files (x86)\GnuWin32\".
3813After installation, locate lib/libfreetype.dll.a and make a copy with the name freetype.dll."
3814      else
3815        HELP_MSG="You need to build a 64-bit version of freetype.
3816This is not readily available.
3817You can find source code and build instructions on
3818http://www.freetype.org/
3819If you put the resulting build in \"C:\Program Files\GnuWin32\", it will be found automatically."
3820      fi
3821      ;;
3822  esac
3823}
3824
3825msys_help() {
3826  PKGHANDLER_COMMAND=""
3827}
3828
3829apt_help() {
3830  case $1 in
3831    devkit)
3832      PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;;
3833    openjdk)
3834      PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;;
3835    alsa)
3836      PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;;
3837    cups)
3838      PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;;
3839    freetype)
3840      PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;;
3841    pulse)
3842      PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;;
3843    x11)
3844      PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
3845    ccache)
3846      PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
3847  esac
3848}
3849
3850yum_help() {
3851  case $1 in
3852    devkit)
3853      PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;;
3854    openjdk)
3855      PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;;
3856    alsa)
3857      PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;;
3858    cups)
3859      PKGHANDLER_COMMAND="sudo yum install cups-devel" ;;
3860    freetype)
3861      PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;;
3862    pulse)
3863      PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;;
3864    x11)
3865      PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
3866    ccache)
3867      PKGHANDLER_COMMAND="sudo yum install ccache" ;;
3868  esac
3869}
3870
3871port_help() {
3872  PKGHANDLER_COMMAND=""
3873}
3874
3875pkgutil_help() {
3876  PKGHANDLER_COMMAND=""
3877}
3878
3879pkgadd_help() {
3880  PKGHANDLER_COMMAND=""
3881}
3882
3883# This function will check if we're called from the "configure" wrapper while
3884# printing --help. If so, we will print out additional information that can
3885# only be extracted within the autoconf script, and then exit. This must be
3886# called at the very beginning in configure.ac.
3887
3888
3889
3890
3891#
3892# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3893# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3894#
3895# This code is free software; you can redistribute it and/or modify it
3896# under the terms of the GNU General Public License version 2 only, as
3897# published by the Free Software Foundation.  Oracle designates this
3898# particular file as subject to the "Classpath" exception as provided
3899# by Oracle in the LICENSE file that accompanied this code.
3900#
3901# This code is distributed in the hope that it will be useful, but WITHOUT
3902# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3903# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3904# version 2 for more details (a copy is included in the LICENSE file that
3905# accompanied this code).
3906#
3907# You should have received a copy of the GNU General Public License version
3908# 2 along with this work; if not, write to the Free Software Foundation,
3909# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3910#
3911# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3912# or visit www.oracle.com if you need additional information or have any
3913# questions.
3914#
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925###############################################################################
3926#
3927# Should we build only OpenJDK even if closed sources are present?
3928#
3929
3930
3931
3932
3933###############################################################################
3934#
3935# Setup version numbers
3936#
3937
3938
3939
3940
3941
3942
3943#
3944# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3945# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3946#
3947# This code is free software; you can redistribute it and/or modify it
3948# under the terms of the GNU General Public License version 2 only, as
3949# published by the Free Software Foundation.  Oracle designates this
3950# particular file as subject to the "Classpath" exception as provided
3951# by Oracle in the LICENSE file that accompanied this code.
3952#
3953# This code is distributed in the hope that it will be useful, but WITHOUT
3954# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3955# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3956# version 2 for more details (a copy is included in the LICENSE file that
3957# accompanied this code).
3958#
3959# You should have received a copy of the GNU General Public License version
3960# 2 along with this work; if not, write to the Free Software Foundation,
3961# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3962#
3963# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3964# or visit www.oracle.com if you need additional information or have any
3965# questions.
3966#
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986#
3987# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3988# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3989#
3990# This code is free software; you can redistribute it and/or modify it
3991# under the terms of the GNU General Public License version 2 only, as
3992# published by the Free Software Foundation.  Oracle designates this
3993# particular file as subject to the "Classpath" exception as provided
3994# by Oracle in the LICENSE file that accompanied this code.
3995#
3996# This code is distributed in the hope that it will be useful, but WITHOUT
3997# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3998# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3999# version 2 for more details (a copy is included in the LICENSE file that
4000# accompanied this code).
4001#
4002# You should have received a copy of the GNU General Public License version
4003# 2 along with this work; if not, write to the Free Software Foundation,
4004# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4005#
4006# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4007# or visit www.oracle.com if you need additional information or have any
4008# questions.
4009#
4010
4011# Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
4012# Converts autoconf style CPU name to OpenJDK style, into
4013# VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN.
4014
4015
4016# Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
4017# Converts autoconf style OS name to OpenJDK style, into
4018# VAR_OS and VAR_OS_API.
4019
4020
4021# Expects $host_os $host_cpu $build_os and $build_cpu
4022# and $with_target_bits to have been setup!
4023#
4024# Translate the standard triplet(quadruplet) definition
4025# of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU,
4026# OPENJDK_BUILD_OS, etc.
4027
4028
4029# Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour
4030# accordingly. Must be done after setting up build and target system, but before
4031# doing anything else with these values.
4032
4033
4034# Setup the legacy variables, for controlling the old makefiles.
4035#
4036
4037
4038
4039
4040#%%% Build and target systems %%%
4041
4042
4043
4044
4045# Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS.
4046# Add -mX to various FLAGS variables.
4047
4048
4049
4050
4051
4052
4053#
4054# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4055# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4056#
4057# This code is free software; you can redistribute it and/or modify it
4058# under the terms of the GNU General Public License version 2 only, as
4059# published by the Free Software Foundation.  Oracle designates this
4060# particular file as subject to the "Classpath" exception as provided
4061# by Oracle in the LICENSE file that accompanied this code.
4062#
4063# This code is distributed in the hope that it will be useful, but WITHOUT
4064# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4065# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4066# version 2 for more details (a copy is included in the LICENSE file that
4067# accompanied this code).
4068#
4069# You should have received a copy of the GNU General Public License version
4070# 2 along with this work; if not, write to the Free Software Foundation,
4071# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4072#
4073# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4074# or visit www.oracle.com if you need additional information or have any
4075# questions.
4076#
4077
4078
4079
4080
4081
4082
4083
4084
4085#
4086# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
4087# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4088#
4089# This code is free software; you can redistribute it and/or modify it
4090# under the terms of the GNU General Public License version 2 only, as
4091# published by the Free Software Foundation.  Oracle designates this
4092# particular file as subject to the "Classpath" exception as provided
4093# by Oracle in the LICENSE file that accompanied this code.
4094#
4095# This code is distributed in the hope that it will be useful, but WITHOUT
4096# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4097# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4098# version 2 for more details (a copy is included in the LICENSE file that
4099# accompanied this code).
4100#
4101# You should have received a copy of the GNU General Public License version
4102# 2 along with this work; if not, write to the Free Software Foundation,
4103# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4104#
4105# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4106# or visit www.oracle.com if you need additional information or have any
4107# questions.
4108#
4109
4110########################################################################
4111# This file is responsible for detecting, verifying and setting up the
4112# toolchain, i.e. the compiler, linker and related utilities. It will setup
4113# proper paths to the binaries, but it will not setup any flags.
4114#
4115# The binaries used is determined by the toolchain type, which is the family of
4116# compilers and related tools that are used.
4117########################################################################
4118
4119
4120# All valid toolchains, regardless of platform (used by help.m4)
4121VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft"
4122
4123# These toolchains are valid on different platforms
4124VALID_TOOLCHAINS_linux="gcc clang"
4125VALID_TOOLCHAINS_solaris="solstudio"
4126VALID_TOOLCHAINS_macosx="gcc clang"
4127VALID_TOOLCHAINS_aix="xlc"
4128VALID_TOOLCHAINS_windows="microsoft"
4129
4130# Toolchain descriptions
4131TOOLCHAIN_DESCRIPTION_clang="clang/LLVM"
4132TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection"
4133TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio"
4134TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio"
4135TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
4136
4137# Setup a number of variables describing how native output files are
4138# named on this platform/toolchain.
4139
4140
4141# Determine which toolchain type to use, and make sure it is valid for this
4142# platform. Setup various information about the selected toolchain.
4143
4144
4145# Before we start detecting the toolchain executables, we might need some
4146# special setup, e.g. additional paths etc.
4147
4148
4149# Restore path, etc
4150
4151
4152# Check if a compiler is of the toolchain type we expect, and save the version
4153# information from it. If the compiler does not match the expected type,
4154# this function will abort using AC_MSG_ERROR. If it matches, the version will
4155# be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and
4156# the full version string in CC_VERSION_STRING/CXX_VERSION_STRING.
4157#
4158# $1 = compiler to test (CC or CXX)
4159# $2 = human readable name of compiler (C or C++)
4160
4161
4162# Try to locate the given C or C++ compiler in the path, or otherwise.
4163#
4164# $1 = compiler to test (CC or CXX)
4165# $2 = human readable name of compiler (C or C++)
4166# $3 = list of compiler names to search for
4167
4168
4169# Detect the core components of the toolchain, i.e. the compilers (CC and CXX),
4170# preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the
4171# archiver (AR). Verify that the compilers are correct according to the
4172# toolchain type.
4173
4174
4175# Setup additional tools that is considered a part of the toolchain, but not the
4176# core part. Many of these are highly platform-specific and do not exist,
4177# and/or are not needed on all platforms.
4178
4179
4180# Setup the build tools (i.e, the compiler and linker used to build programs
4181# that should be run on the build platform, not the target platform, as a build
4182# helper). Since the non-cross-compile case uses the normal, target compilers
4183# for this, we can only do this after these have been setup.
4184
4185
4186# Setup legacy variables that are still needed as alternative ways to refer to
4187# parts of the toolchain.
4188
4189
4190# Do some additional checks on the detected tools.
4191
4192
4193# Setup the JTReg Regression Test Harness.
4194
4195
4196#
4197# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4198# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4199#
4200# This code is free software; you can redistribute it and/or modify it
4201# under the terms of the GNU General Public License version 2 only, as
4202# published by the Free Software Foundation.  Oracle designates this
4203# particular file as subject to the "Classpath" exception as provided
4204# by Oracle in the LICENSE file that accompanied this code.
4205#
4206# This code is distributed in the hope that it will be useful, but WITHOUT
4207# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4208# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4209# version 2 for more details (a copy is included in the LICENSE file that
4210# accompanied this code).
4211#
4212# You should have received a copy of the GNU General Public License version
4213# 2 along with this work; if not, write to the Free Software Foundation,
4214# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4215#
4216# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4217# or visit www.oracle.com if you need additional information or have any
4218# questions.
4219#
4220
4221
4222
4223
4224
4225
4226
4227# Check if the VS env variables were setup prior to running configure.
4228# If not, then find vcvarsall.bat and run it automatically, and integrate
4229# the set env variables into the spec file.
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240# This line needs to be here, verbatim, after all includes and the dummy hook
4241# definitions. It is replaced with custom functionality when building
4242# custom sources.
4243#CUSTOM_AUTOCONF_INCLUDE
4244
4245# Do not change or remove the following line, it is needed for consistency checks:
4246DATE_WHEN_GENERATED=1396297437
4247
4248###############################################################################
4249#
4250# Initialization / Boot-strapping
4251#
4252# The bootstrapping process needs to solve the "chicken or the egg" problem,
4253# thus it jumps back and forth, each time gaining something needed later on.
4254#
4255###############################################################################
4256
4257# If we are requested to print additional help, do that and then exit.
4258# This must be the very first call.
4259
4260  if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4261    $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4262    $PRINTF "Which are valid to use depends on the build platform.\n"
4263    for toolchain in $VALID_TOOLCHAINS_all; do
4264      # Use indirect variable referencing
4265      toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4266      TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
4267      $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
4268    done
4269
4270    # And now exit directly
4271    exit 0
4272  fi
4273
4274
4275# Basic initialization that must happen first of all in the normal process.
4276
4277  # Save the original command line. This is passed to us by the wrapper configure script.
4278
4279  DATE_WHEN_CONFIGURED=`LANG=C date`
4280
4281  { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5
4282$as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;}
4283  { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5
4284$as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;}
4285
4286
4287  # Start with tools that do not need have cross compilation support
4288  # and can be expected to be found in the default PATH. These tools are
4289  # used by configure. Nor are these tools expected to be found in the
4290  # devkit from the builddeps server either, since they are
4291  # needed to download the devkit.
4292
4293  # First are all the simple required tools.
4294
4295
4296
4297  # Publish this variable in the help.
4298
4299
4300  if test "x$BASENAME" = x; then
4301    # The variable is not set by user, try to locate tool using the code snippet
4302    for ac_prog in basename
4303do
4304  # Extract the first word of "$ac_prog", so it can be a program name with args.
4305set dummy $ac_prog; ac_word=$2
4306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4307$as_echo_n "checking for $ac_word... " >&6; }
4308if ${ac_cv_path_BASENAME+:} false; then :
4309  $as_echo_n "(cached) " >&6
4310else
4311  case $BASENAME in
4312  [\\/]* | ?:[\\/]*)
4313  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4314  ;;
4315  *)
4316  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4317for as_dir in $PATH
4318do
4319  IFS=$as_save_IFS
4320  test -z "$as_dir" && as_dir=.
4321    for ac_exec_ext in '' $ac_executable_extensions; do
4322  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4323    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4324    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4325    break 2
4326  fi
4327done
4328  done
4329IFS=$as_save_IFS
4330
4331  ;;
4332esac
4333fi
4334BASENAME=$ac_cv_path_BASENAME
4335if test -n "$BASENAME"; then
4336  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4337$as_echo "$BASENAME" >&6; }
4338else
4339  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4340$as_echo "no" >&6; }
4341fi
4342
4343
4344  test -n "$BASENAME" && break
4345done
4346
4347  else
4348    # The variable is set, but is it from the command line or the environment?
4349
4350    # Try to remove the string !BASENAME! from our list.
4351    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/}
4352    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4353      # If it failed, the variable was not from the command line. Ignore it,
4354      # but warn the user (except for BASH, which is always set by the calling BASH).
4355      if test "xBASENAME" != xBASH; then
4356        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5
4357$as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;}
4358      fi
4359      # Try to locate tool using the code snippet
4360      for ac_prog in basename
4361do
4362  # Extract the first word of "$ac_prog", so it can be a program name with args.
4363set dummy $ac_prog; ac_word=$2
4364{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4365$as_echo_n "checking for $ac_word... " >&6; }
4366if ${ac_cv_path_BASENAME+:} false; then :
4367  $as_echo_n "(cached) " >&6
4368else
4369  case $BASENAME in
4370  [\\/]* | ?:[\\/]*)
4371  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4372  ;;
4373  *)
4374  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4375for as_dir in $PATH
4376do
4377  IFS=$as_save_IFS
4378  test -z "$as_dir" && as_dir=.
4379    for ac_exec_ext in '' $ac_executable_extensions; do
4380  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4381    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4382    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4383    break 2
4384  fi
4385done
4386  done
4387IFS=$as_save_IFS
4388
4389  ;;
4390esac
4391fi
4392BASENAME=$ac_cv_path_BASENAME
4393if test -n "$BASENAME"; then
4394  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4395$as_echo "$BASENAME" >&6; }
4396else
4397  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4398$as_echo "no" >&6; }
4399fi
4400
4401
4402  test -n "$BASENAME" && break
4403done
4404
4405    else
4406      # If it succeeded, then it was overridden by the user. We will use it
4407      # for the tool.
4408
4409      # First remove it from the list of overridden variables, so we can test
4410      # for unknown variables in the end.
4411      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4412
4413      # Check if the provided tool contains a complete path.
4414      tool_specified="$BASENAME"
4415      tool_basename="${tool_specified##*/}"
4416      if test "x$tool_basename" = "x$tool_specified"; then
4417        # A command without a complete path is provided, search $PATH.
4418        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5
4419$as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;}
4420        # Extract the first word of "$tool_basename", so it can be a program name with args.
4421set dummy $tool_basename; ac_word=$2
4422{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4423$as_echo_n "checking for $ac_word... " >&6; }
4424if ${ac_cv_path_BASENAME+:} false; then :
4425  $as_echo_n "(cached) " >&6
4426else
4427  case $BASENAME in
4428  [\\/]* | ?:[\\/]*)
4429  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4430  ;;
4431  *)
4432  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4433for as_dir in $PATH
4434do
4435  IFS=$as_save_IFS
4436  test -z "$as_dir" && as_dir=.
4437    for ac_exec_ext in '' $ac_executable_extensions; do
4438  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4439    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4440    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4441    break 2
4442  fi
4443done
4444  done
4445IFS=$as_save_IFS
4446
4447  ;;
4448esac
4449fi
4450BASENAME=$ac_cv_path_BASENAME
4451if test -n "$BASENAME"; then
4452  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4453$as_echo "$BASENAME" >&6; }
4454else
4455  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4456$as_echo "no" >&6; }
4457fi
4458
4459
4460        if test "x$BASENAME" = x; then
4461          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4462        fi
4463      else
4464        # Otherwise we believe it is a complete path. Use it as it is.
4465        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5
4466$as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;}
4467        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5
4468$as_echo_n "checking for BASENAME... " >&6; }
4469        if test ! -x "$tool_specified"; then
4470          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4471$as_echo "not found" >&6; }
4472          as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5
4473        fi
4474        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4475$as_echo "$tool_specified" >&6; }
4476      fi
4477    fi
4478  fi
4479
4480
4481
4482  if test "x$BASENAME" = x; then
4483    as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5
4484  fi
4485
4486
4487
4488
4489
4490  # Publish this variable in the help.
4491
4492
4493  if test "x$BASH" = x; then
4494    # The variable is not set by user, try to locate tool using the code snippet
4495    for ac_prog in bash
4496do
4497  # Extract the first word of "$ac_prog", so it can be a program name with args.
4498set dummy $ac_prog; ac_word=$2
4499{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4500$as_echo_n "checking for $ac_word... " >&6; }
4501if ${ac_cv_path_BASH+:} false; then :
4502  $as_echo_n "(cached) " >&6
4503else
4504  case $BASH in
4505  [\\/]* | ?:[\\/]*)
4506  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4507  ;;
4508  *)
4509  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4510for as_dir in $PATH
4511do
4512  IFS=$as_save_IFS
4513  test -z "$as_dir" && as_dir=.
4514    for ac_exec_ext in '' $ac_executable_extensions; do
4515  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4516    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4517    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4518    break 2
4519  fi
4520done
4521  done
4522IFS=$as_save_IFS
4523
4524  ;;
4525esac
4526fi
4527BASH=$ac_cv_path_BASH
4528if test -n "$BASH"; then
4529  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4530$as_echo "$BASH" >&6; }
4531else
4532  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4533$as_echo "no" >&6; }
4534fi
4535
4536
4537  test -n "$BASH" && break
4538done
4539
4540  else
4541    # The variable is set, but is it from the command line or the environment?
4542
4543    # Try to remove the string !BASH! from our list.
4544    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/}
4545    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4546      # If it failed, the variable was not from the command line. Ignore it,
4547      # but warn the user (except for BASH, which is always set by the calling BASH).
4548      if test "xBASH" != xBASH; then
4549        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5
4550$as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;}
4551      fi
4552      # Try to locate tool using the code snippet
4553      for ac_prog in bash
4554do
4555  # Extract the first word of "$ac_prog", so it can be a program name with args.
4556set dummy $ac_prog; ac_word=$2
4557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4558$as_echo_n "checking for $ac_word... " >&6; }
4559if ${ac_cv_path_BASH+:} false; then :
4560  $as_echo_n "(cached) " >&6
4561else
4562  case $BASH in
4563  [\\/]* | ?:[\\/]*)
4564  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4565  ;;
4566  *)
4567  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4568for as_dir in $PATH
4569do
4570  IFS=$as_save_IFS
4571  test -z "$as_dir" && as_dir=.
4572    for ac_exec_ext in '' $ac_executable_extensions; do
4573  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4574    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4575    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4576    break 2
4577  fi
4578done
4579  done
4580IFS=$as_save_IFS
4581
4582  ;;
4583esac
4584fi
4585BASH=$ac_cv_path_BASH
4586if test -n "$BASH"; then
4587  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4588$as_echo "$BASH" >&6; }
4589else
4590  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4591$as_echo "no" >&6; }
4592fi
4593
4594
4595  test -n "$BASH" && break
4596done
4597
4598    else
4599      # If it succeeded, then it was overridden by the user. We will use it
4600      # for the tool.
4601
4602      # First remove it from the list of overridden variables, so we can test
4603      # for unknown variables in the end.
4604      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4605
4606      # Check if the provided tool contains a complete path.
4607      tool_specified="$BASH"
4608      tool_basename="${tool_specified##*/}"
4609      if test "x$tool_basename" = "x$tool_specified"; then
4610        # A command without a complete path is provided, search $PATH.
4611        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5
4612$as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;}
4613        # Extract the first word of "$tool_basename", so it can be a program name with args.
4614set dummy $tool_basename; ac_word=$2
4615{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4616$as_echo_n "checking for $ac_word... " >&6; }
4617if ${ac_cv_path_BASH+:} false; then :
4618  $as_echo_n "(cached) " >&6
4619else
4620  case $BASH in
4621  [\\/]* | ?:[\\/]*)
4622  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4623  ;;
4624  *)
4625  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4626for as_dir in $PATH
4627do
4628  IFS=$as_save_IFS
4629  test -z "$as_dir" && as_dir=.
4630    for ac_exec_ext in '' $ac_executable_extensions; do
4631  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4632    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4633    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4634    break 2
4635  fi
4636done
4637  done
4638IFS=$as_save_IFS
4639
4640  ;;
4641esac
4642fi
4643BASH=$ac_cv_path_BASH
4644if test -n "$BASH"; then
4645  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4646$as_echo "$BASH" >&6; }
4647else
4648  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4649$as_echo "no" >&6; }
4650fi
4651
4652
4653        if test "x$BASH" = x; then
4654          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4655        fi
4656      else
4657        # Otherwise we believe it is a complete path. Use it as it is.
4658        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5
4659$as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;}
4660        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5
4661$as_echo_n "checking for BASH... " >&6; }
4662        if test ! -x "$tool_specified"; then
4663          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4664$as_echo "not found" >&6; }
4665          as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5
4666        fi
4667        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4668$as_echo "$tool_specified" >&6; }
4669      fi
4670    fi
4671  fi
4672
4673
4674
4675  if test "x$BASH" = x; then
4676    as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5
4677  fi
4678
4679
4680
4681
4682
4683  # Publish this variable in the help.
4684
4685
4686  if test "x$CAT" = x; then
4687    # The variable is not set by user, try to locate tool using the code snippet
4688    for ac_prog in cat
4689do
4690  # Extract the first word of "$ac_prog", so it can be a program name with args.
4691set dummy $ac_prog; ac_word=$2
4692{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4693$as_echo_n "checking for $ac_word... " >&6; }
4694if ${ac_cv_path_CAT+:} false; then :
4695  $as_echo_n "(cached) " >&6
4696else
4697  case $CAT in
4698  [\\/]* | ?:[\\/]*)
4699  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4700  ;;
4701  *)
4702  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4703for as_dir in $PATH
4704do
4705  IFS=$as_save_IFS
4706  test -z "$as_dir" && as_dir=.
4707    for ac_exec_ext in '' $ac_executable_extensions; do
4708  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4709    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4710    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4711    break 2
4712  fi
4713done
4714  done
4715IFS=$as_save_IFS
4716
4717  ;;
4718esac
4719fi
4720CAT=$ac_cv_path_CAT
4721if test -n "$CAT"; then
4722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4723$as_echo "$CAT" >&6; }
4724else
4725  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4726$as_echo "no" >&6; }
4727fi
4728
4729
4730  test -n "$CAT" && break
4731done
4732
4733  else
4734    # The variable is set, but is it from the command line or the environment?
4735
4736    # Try to remove the string !CAT! from our list.
4737    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/}
4738    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4739      # If it failed, the variable was not from the command line. Ignore it,
4740      # but warn the user (except for BASH, which is always set by the calling BASH).
4741      if test "xCAT" != xBASH; then
4742        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5
4743$as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;}
4744      fi
4745      # Try to locate tool using the code snippet
4746      for ac_prog in cat
4747do
4748  # Extract the first word of "$ac_prog", so it can be a program name with args.
4749set dummy $ac_prog; ac_word=$2
4750{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4751$as_echo_n "checking for $ac_word... " >&6; }
4752if ${ac_cv_path_CAT+:} false; then :
4753  $as_echo_n "(cached) " >&6
4754else
4755  case $CAT in
4756  [\\/]* | ?:[\\/]*)
4757  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4758  ;;
4759  *)
4760  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4761for as_dir in $PATH
4762do
4763  IFS=$as_save_IFS
4764  test -z "$as_dir" && as_dir=.
4765    for ac_exec_ext in '' $ac_executable_extensions; do
4766  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4767    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4768    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4769    break 2
4770  fi
4771done
4772  done
4773IFS=$as_save_IFS
4774
4775  ;;
4776esac
4777fi
4778CAT=$ac_cv_path_CAT
4779if test -n "$CAT"; then
4780  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4781$as_echo "$CAT" >&6; }
4782else
4783  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4784$as_echo "no" >&6; }
4785fi
4786
4787
4788  test -n "$CAT" && break
4789done
4790
4791    else
4792      # If it succeeded, then it was overridden by the user. We will use it
4793      # for the tool.
4794
4795      # First remove it from the list of overridden variables, so we can test
4796      # for unknown variables in the end.
4797      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4798
4799      # Check if the provided tool contains a complete path.
4800      tool_specified="$CAT"
4801      tool_basename="${tool_specified##*/}"
4802      if test "x$tool_basename" = "x$tool_specified"; then
4803        # A command without a complete path is provided, search $PATH.
4804        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5
4805$as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;}
4806        # Extract the first word of "$tool_basename", so it can be a program name with args.
4807set dummy $tool_basename; ac_word=$2
4808{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4809$as_echo_n "checking for $ac_word... " >&6; }
4810if ${ac_cv_path_CAT+:} false; then :
4811  $as_echo_n "(cached) " >&6
4812else
4813  case $CAT in
4814  [\\/]* | ?:[\\/]*)
4815  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4816  ;;
4817  *)
4818  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4819for as_dir in $PATH
4820do
4821  IFS=$as_save_IFS
4822  test -z "$as_dir" && as_dir=.
4823    for ac_exec_ext in '' $ac_executable_extensions; do
4824  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4825    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4826    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4827    break 2
4828  fi
4829done
4830  done
4831IFS=$as_save_IFS
4832
4833  ;;
4834esac
4835fi
4836CAT=$ac_cv_path_CAT
4837if test -n "$CAT"; then
4838  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4839$as_echo "$CAT" >&6; }
4840else
4841  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4842$as_echo "no" >&6; }
4843fi
4844
4845
4846        if test "x$CAT" = x; then
4847          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4848        fi
4849      else
4850        # Otherwise we believe it is a complete path. Use it as it is.
4851        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5
4852$as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;}
4853        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5
4854$as_echo_n "checking for CAT... " >&6; }
4855        if test ! -x "$tool_specified"; then
4856          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4857$as_echo "not found" >&6; }
4858          as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5
4859        fi
4860        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4861$as_echo "$tool_specified" >&6; }
4862      fi
4863    fi
4864  fi
4865
4866
4867
4868  if test "x$CAT" = x; then
4869    as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5
4870  fi
4871
4872
4873
4874
4875
4876  # Publish this variable in the help.
4877
4878
4879  if test "x$CHMOD" = x; then
4880    # The variable is not set by user, try to locate tool using the code snippet
4881    for ac_prog in chmod
4882do
4883  # Extract the first word of "$ac_prog", so it can be a program name with args.
4884set dummy $ac_prog; ac_word=$2
4885{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4886$as_echo_n "checking for $ac_word... " >&6; }
4887if ${ac_cv_path_CHMOD+:} false; then :
4888  $as_echo_n "(cached) " >&6
4889else
4890  case $CHMOD in
4891  [\\/]* | ?:[\\/]*)
4892  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4893  ;;
4894  *)
4895  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4896for as_dir in $PATH
4897do
4898  IFS=$as_save_IFS
4899  test -z "$as_dir" && as_dir=.
4900    for ac_exec_ext in '' $ac_executable_extensions; do
4901  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4902    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4903    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4904    break 2
4905  fi
4906done
4907  done
4908IFS=$as_save_IFS
4909
4910  ;;
4911esac
4912fi
4913CHMOD=$ac_cv_path_CHMOD
4914if test -n "$CHMOD"; then
4915  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4916$as_echo "$CHMOD" >&6; }
4917else
4918  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4919$as_echo "no" >&6; }
4920fi
4921
4922
4923  test -n "$CHMOD" && break
4924done
4925
4926  else
4927    # The variable is set, but is it from the command line or the environment?
4928
4929    # Try to remove the string !CHMOD! from our list.
4930    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/}
4931    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4932      # If it failed, the variable was not from the command line. Ignore it,
4933      # but warn the user (except for BASH, which is always set by the calling BASH).
4934      if test "xCHMOD" != xBASH; then
4935        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5
4936$as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;}
4937      fi
4938      # Try to locate tool using the code snippet
4939      for ac_prog in chmod
4940do
4941  # Extract the first word of "$ac_prog", so it can be a program name with args.
4942set dummy $ac_prog; ac_word=$2
4943{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4944$as_echo_n "checking for $ac_word... " >&6; }
4945if ${ac_cv_path_CHMOD+:} false; then :
4946  $as_echo_n "(cached) " >&6
4947else
4948  case $CHMOD in
4949  [\\/]* | ?:[\\/]*)
4950  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4951  ;;
4952  *)
4953  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4954for as_dir in $PATH
4955do
4956  IFS=$as_save_IFS
4957  test -z "$as_dir" && as_dir=.
4958    for ac_exec_ext in '' $ac_executable_extensions; do
4959  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4960    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4961    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4962    break 2
4963  fi
4964done
4965  done
4966IFS=$as_save_IFS
4967
4968  ;;
4969esac
4970fi
4971CHMOD=$ac_cv_path_CHMOD
4972if test -n "$CHMOD"; then
4973  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4974$as_echo "$CHMOD" >&6; }
4975else
4976  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4977$as_echo "no" >&6; }
4978fi
4979
4980
4981  test -n "$CHMOD" && break
4982done
4983
4984    else
4985      # If it succeeded, then it was overridden by the user. We will use it
4986      # for the tool.
4987
4988      # First remove it from the list of overridden variables, so we can test
4989      # for unknown variables in the end.
4990      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4991
4992      # Check if the provided tool contains a complete path.
4993      tool_specified="$CHMOD"
4994      tool_basename="${tool_specified##*/}"
4995      if test "x$tool_basename" = "x$tool_specified"; then
4996        # A command without a complete path is provided, search $PATH.
4997        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5
4998$as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;}
4999        # Extract the first word of "$tool_basename", so it can be a program name with args.
5000set dummy $tool_basename; ac_word=$2
5001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5002$as_echo_n "checking for $ac_word... " >&6; }
5003if ${ac_cv_path_CHMOD+:} false; then :
5004  $as_echo_n "(cached) " >&6
5005else
5006  case $CHMOD in
5007  [\\/]* | ?:[\\/]*)
5008  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
5009  ;;
5010  *)
5011  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5012for as_dir in $PATH
5013do
5014  IFS=$as_save_IFS
5015  test -z "$as_dir" && as_dir=.
5016    for ac_exec_ext in '' $ac_executable_extensions; do
5017  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5018    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
5019    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5020    break 2
5021  fi
5022done
5023  done
5024IFS=$as_save_IFS
5025
5026  ;;
5027esac
5028fi
5029CHMOD=$ac_cv_path_CHMOD
5030if test -n "$CHMOD"; then
5031  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5032$as_echo "$CHMOD" >&6; }
5033else
5034  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5035$as_echo "no" >&6; }
5036fi
5037
5038
5039        if test "x$CHMOD" = x; then
5040          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5041        fi
5042      else
5043        # Otherwise we believe it is a complete path. Use it as it is.
5044        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5
5045$as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;}
5046        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5
5047$as_echo_n "checking for CHMOD... " >&6; }
5048        if test ! -x "$tool_specified"; then
5049          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5050$as_echo "not found" >&6; }
5051          as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5
5052        fi
5053        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5054$as_echo "$tool_specified" >&6; }
5055      fi
5056    fi
5057  fi
5058
5059
5060
5061  if test "x$CHMOD" = x; then
5062    as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5
5063  fi
5064
5065
5066
5067
5068
5069  # Publish this variable in the help.
5070
5071
5072  if test "x$CMP" = x; then
5073    # The variable is not set by user, try to locate tool using the code snippet
5074    for ac_prog in cmp
5075do
5076  # Extract the first word of "$ac_prog", so it can be a program name with args.
5077set dummy $ac_prog; ac_word=$2
5078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5079$as_echo_n "checking for $ac_word... " >&6; }
5080if ${ac_cv_path_CMP+:} false; then :
5081  $as_echo_n "(cached) " >&6
5082else
5083  case $CMP in
5084  [\\/]* | ?:[\\/]*)
5085  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5086  ;;
5087  *)
5088  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5089for as_dir in $PATH
5090do
5091  IFS=$as_save_IFS
5092  test -z "$as_dir" && as_dir=.
5093    for ac_exec_ext in '' $ac_executable_extensions; do
5094  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5095    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5096    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5097    break 2
5098  fi
5099done
5100  done
5101IFS=$as_save_IFS
5102
5103  ;;
5104esac
5105fi
5106CMP=$ac_cv_path_CMP
5107if test -n "$CMP"; then
5108  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5109$as_echo "$CMP" >&6; }
5110else
5111  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5112$as_echo "no" >&6; }
5113fi
5114
5115
5116  test -n "$CMP" && break
5117done
5118
5119  else
5120    # The variable is set, but is it from the command line or the environment?
5121
5122    # Try to remove the string !CMP! from our list.
5123    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/}
5124    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5125      # If it failed, the variable was not from the command line. Ignore it,
5126      # but warn the user (except for BASH, which is always set by the calling BASH).
5127      if test "xCMP" != xBASH; then
5128        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5
5129$as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;}
5130      fi
5131      # Try to locate tool using the code snippet
5132      for ac_prog in cmp
5133do
5134  # Extract the first word of "$ac_prog", so it can be a program name with args.
5135set dummy $ac_prog; ac_word=$2
5136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5137$as_echo_n "checking for $ac_word... " >&6; }
5138if ${ac_cv_path_CMP+:} false; then :
5139  $as_echo_n "(cached) " >&6
5140else
5141  case $CMP in
5142  [\\/]* | ?:[\\/]*)
5143  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5144  ;;
5145  *)
5146  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5147for as_dir in $PATH
5148do
5149  IFS=$as_save_IFS
5150  test -z "$as_dir" && as_dir=.
5151    for ac_exec_ext in '' $ac_executable_extensions; do
5152  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5153    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5154    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5155    break 2
5156  fi
5157done
5158  done
5159IFS=$as_save_IFS
5160
5161  ;;
5162esac
5163fi
5164CMP=$ac_cv_path_CMP
5165if test -n "$CMP"; then
5166  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5167$as_echo "$CMP" >&6; }
5168else
5169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5170$as_echo "no" >&6; }
5171fi
5172
5173
5174  test -n "$CMP" && break
5175done
5176
5177    else
5178      # If it succeeded, then it was overridden by the user. We will use it
5179      # for the tool.
5180
5181      # First remove it from the list of overridden variables, so we can test
5182      # for unknown variables in the end.
5183      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5184
5185      # Check if the provided tool contains a complete path.
5186      tool_specified="$CMP"
5187      tool_basename="${tool_specified##*/}"
5188      if test "x$tool_basename" = "x$tool_specified"; then
5189        # A command without a complete path is provided, search $PATH.
5190        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5
5191$as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;}
5192        # Extract the first word of "$tool_basename", so it can be a program name with args.
5193set dummy $tool_basename; ac_word=$2
5194{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5195$as_echo_n "checking for $ac_word... " >&6; }
5196if ${ac_cv_path_CMP+:} false; then :
5197  $as_echo_n "(cached) " >&6
5198else
5199  case $CMP in
5200  [\\/]* | ?:[\\/]*)
5201  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5202  ;;
5203  *)
5204  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5205for as_dir in $PATH
5206do
5207  IFS=$as_save_IFS
5208  test -z "$as_dir" && as_dir=.
5209    for ac_exec_ext in '' $ac_executable_extensions; do
5210  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5211    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5212    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5213    break 2
5214  fi
5215done
5216  done
5217IFS=$as_save_IFS
5218
5219  ;;
5220esac
5221fi
5222CMP=$ac_cv_path_CMP
5223if test -n "$CMP"; then
5224  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5225$as_echo "$CMP" >&6; }
5226else
5227  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5228$as_echo "no" >&6; }
5229fi
5230
5231
5232        if test "x$CMP" = x; then
5233          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5234        fi
5235      else
5236        # Otherwise we believe it is a complete path. Use it as it is.
5237        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5
5238$as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;}
5239        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5
5240$as_echo_n "checking for CMP... " >&6; }
5241        if test ! -x "$tool_specified"; then
5242          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5243$as_echo "not found" >&6; }
5244          as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5
5245        fi
5246        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5247$as_echo "$tool_specified" >&6; }
5248      fi
5249    fi
5250  fi
5251
5252
5253
5254  if test "x$CMP" = x; then
5255    as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5
5256  fi
5257
5258
5259
5260
5261
5262  # Publish this variable in the help.
5263
5264
5265  if test "x$COMM" = x; then
5266    # The variable is not set by user, try to locate tool using the code snippet
5267    for ac_prog in comm
5268do
5269  # Extract the first word of "$ac_prog", so it can be a program name with args.
5270set dummy $ac_prog; ac_word=$2
5271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5272$as_echo_n "checking for $ac_word... " >&6; }
5273if ${ac_cv_path_COMM+:} false; then :
5274  $as_echo_n "(cached) " >&6
5275else
5276  case $COMM in
5277  [\\/]* | ?:[\\/]*)
5278  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5279  ;;
5280  *)
5281  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5282for as_dir in $PATH
5283do
5284  IFS=$as_save_IFS
5285  test -z "$as_dir" && as_dir=.
5286    for ac_exec_ext in '' $ac_executable_extensions; do
5287  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5288    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5289    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5290    break 2
5291  fi
5292done
5293  done
5294IFS=$as_save_IFS
5295
5296  ;;
5297esac
5298fi
5299COMM=$ac_cv_path_COMM
5300if test -n "$COMM"; then
5301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5302$as_echo "$COMM" >&6; }
5303else
5304  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5305$as_echo "no" >&6; }
5306fi
5307
5308
5309  test -n "$COMM" && break
5310done
5311
5312  else
5313    # The variable is set, but is it from the command line or the environment?
5314
5315    # Try to remove the string !COMM! from our list.
5316    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
5317    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5318      # If it failed, the variable was not from the command line. Ignore it,
5319      # but warn the user (except for BASH, which is always set by the calling BASH).
5320      if test "xCOMM" != xBASH; then
5321        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
5322$as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
5323      fi
5324      # Try to locate tool using the code snippet
5325      for ac_prog in comm
5326do
5327  # Extract the first word of "$ac_prog", so it can be a program name with args.
5328set dummy $ac_prog; ac_word=$2
5329{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5330$as_echo_n "checking for $ac_word... " >&6; }
5331if ${ac_cv_path_COMM+:} false; then :
5332  $as_echo_n "(cached) " >&6
5333else
5334  case $COMM in
5335  [\\/]* | ?:[\\/]*)
5336  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5337  ;;
5338  *)
5339  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5340for as_dir in $PATH
5341do
5342  IFS=$as_save_IFS
5343  test -z "$as_dir" && as_dir=.
5344    for ac_exec_ext in '' $ac_executable_extensions; do
5345  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5346    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5347    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5348    break 2
5349  fi
5350done
5351  done
5352IFS=$as_save_IFS
5353
5354  ;;
5355esac
5356fi
5357COMM=$ac_cv_path_COMM
5358if test -n "$COMM"; then
5359  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5360$as_echo "$COMM" >&6; }
5361else
5362  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5363$as_echo "no" >&6; }
5364fi
5365
5366
5367  test -n "$COMM" && break
5368done
5369
5370    else
5371      # If it succeeded, then it was overridden by the user. We will use it
5372      # for the tool.
5373
5374      # First remove it from the list of overridden variables, so we can test
5375      # for unknown variables in the end.
5376      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5377
5378      # Check if the provided tool contains a complete path.
5379      tool_specified="$COMM"
5380      tool_basename="${tool_specified##*/}"
5381      if test "x$tool_basename" = "x$tool_specified"; then
5382        # A command without a complete path is provided, search $PATH.
5383        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
5384$as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
5385        # Extract the first word of "$tool_basename", so it can be a program name with args.
5386set dummy $tool_basename; ac_word=$2
5387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5388$as_echo_n "checking for $ac_word... " >&6; }
5389if ${ac_cv_path_COMM+:} false; then :
5390  $as_echo_n "(cached) " >&6
5391else
5392  case $COMM in
5393  [\\/]* | ?:[\\/]*)
5394  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5395  ;;
5396  *)
5397  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5398for as_dir in $PATH
5399do
5400  IFS=$as_save_IFS
5401  test -z "$as_dir" && as_dir=.
5402    for ac_exec_ext in '' $ac_executable_extensions; do
5403  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5404    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5405    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5406    break 2
5407  fi
5408done
5409  done
5410IFS=$as_save_IFS
5411
5412  ;;
5413esac
5414fi
5415COMM=$ac_cv_path_COMM
5416if test -n "$COMM"; then
5417  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5418$as_echo "$COMM" >&6; }
5419else
5420  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5421$as_echo "no" >&6; }
5422fi
5423
5424
5425        if test "x$COMM" = x; then
5426          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5427        fi
5428      else
5429        # Otherwise we believe it is a complete path. Use it as it is.
5430        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
5431$as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
5432        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
5433$as_echo_n "checking for COMM... " >&6; }
5434        if test ! -x "$tool_specified"; then
5435          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5436$as_echo "not found" >&6; }
5437          as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
5438        fi
5439        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5440$as_echo "$tool_specified" >&6; }
5441      fi
5442    fi
5443  fi
5444
5445
5446
5447  if test "x$COMM" = x; then
5448    as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
5449  fi
5450
5451
5452
5453
5454
5455  # Publish this variable in the help.
5456
5457
5458  if test "x$CP" = x; then
5459    # The variable is not set by user, try to locate tool using the code snippet
5460    for ac_prog in cp
5461do
5462  # Extract the first word of "$ac_prog", so it can be a program name with args.
5463set dummy $ac_prog; ac_word=$2
5464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5465$as_echo_n "checking for $ac_word... " >&6; }
5466if ${ac_cv_path_CP+:} false; then :
5467  $as_echo_n "(cached) " >&6
5468else
5469  case $CP in
5470  [\\/]* | ?:[\\/]*)
5471  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5472  ;;
5473  *)
5474  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5475for as_dir in $PATH
5476do
5477  IFS=$as_save_IFS
5478  test -z "$as_dir" && as_dir=.
5479    for ac_exec_ext in '' $ac_executable_extensions; do
5480  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5481    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5482    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5483    break 2
5484  fi
5485done
5486  done
5487IFS=$as_save_IFS
5488
5489  ;;
5490esac
5491fi
5492CP=$ac_cv_path_CP
5493if test -n "$CP"; then
5494  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5495$as_echo "$CP" >&6; }
5496else
5497  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5498$as_echo "no" >&6; }
5499fi
5500
5501
5502  test -n "$CP" && break
5503done
5504
5505  else
5506    # The variable is set, but is it from the command line or the environment?
5507
5508    # Try to remove the string !CP! from our list.
5509    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/}
5510    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5511      # If it failed, the variable was not from the command line. Ignore it,
5512      # but warn the user (except for BASH, which is always set by the calling BASH).
5513      if test "xCP" != xBASH; then
5514        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5
5515$as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;}
5516      fi
5517      # Try to locate tool using the code snippet
5518      for ac_prog in cp
5519do
5520  # Extract the first word of "$ac_prog", so it can be a program name with args.
5521set dummy $ac_prog; ac_word=$2
5522{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5523$as_echo_n "checking for $ac_word... " >&6; }
5524if ${ac_cv_path_CP+:} false; then :
5525  $as_echo_n "(cached) " >&6
5526else
5527  case $CP in
5528  [\\/]* | ?:[\\/]*)
5529  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5530  ;;
5531  *)
5532  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5533for as_dir in $PATH
5534do
5535  IFS=$as_save_IFS
5536  test -z "$as_dir" && as_dir=.
5537    for ac_exec_ext in '' $ac_executable_extensions; do
5538  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5539    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5540    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5541    break 2
5542  fi
5543done
5544  done
5545IFS=$as_save_IFS
5546
5547  ;;
5548esac
5549fi
5550CP=$ac_cv_path_CP
5551if test -n "$CP"; then
5552  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5553$as_echo "$CP" >&6; }
5554else
5555  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5556$as_echo "no" >&6; }
5557fi
5558
5559
5560  test -n "$CP" && break
5561done
5562
5563    else
5564      # If it succeeded, then it was overridden by the user. We will use it
5565      # for the tool.
5566
5567      # First remove it from the list of overridden variables, so we can test
5568      # for unknown variables in the end.
5569      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5570
5571      # Check if the provided tool contains a complete path.
5572      tool_specified="$CP"
5573      tool_basename="${tool_specified##*/}"
5574      if test "x$tool_basename" = "x$tool_specified"; then
5575        # A command without a complete path is provided, search $PATH.
5576        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5
5577$as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;}
5578        # Extract the first word of "$tool_basename", so it can be a program name with args.
5579set dummy $tool_basename; ac_word=$2
5580{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5581$as_echo_n "checking for $ac_word... " >&6; }
5582if ${ac_cv_path_CP+:} false; then :
5583  $as_echo_n "(cached) " >&6
5584else
5585  case $CP in
5586  [\\/]* | ?:[\\/]*)
5587  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5588  ;;
5589  *)
5590  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5591for as_dir in $PATH
5592do
5593  IFS=$as_save_IFS
5594  test -z "$as_dir" && as_dir=.
5595    for ac_exec_ext in '' $ac_executable_extensions; do
5596  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5597    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5598    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5599    break 2
5600  fi
5601done
5602  done
5603IFS=$as_save_IFS
5604
5605  ;;
5606esac
5607fi
5608CP=$ac_cv_path_CP
5609if test -n "$CP"; then
5610  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5611$as_echo "$CP" >&6; }
5612else
5613  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5614$as_echo "no" >&6; }
5615fi
5616
5617
5618        if test "x$CP" = x; then
5619          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5620        fi
5621      else
5622        # Otherwise we believe it is a complete path. Use it as it is.
5623        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5
5624$as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;}
5625        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5
5626$as_echo_n "checking for CP... " >&6; }
5627        if test ! -x "$tool_specified"; then
5628          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5629$as_echo "not found" >&6; }
5630          as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5
5631        fi
5632        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5633$as_echo "$tool_specified" >&6; }
5634      fi
5635    fi
5636  fi
5637
5638
5639
5640  if test "x$CP" = x; then
5641    as_fn_error $? "Could not find required tool for CP" "$LINENO" 5
5642  fi
5643
5644
5645
5646
5647
5648  # Publish this variable in the help.
5649
5650
5651  if test "x$CPIO" = x; then
5652    # The variable is not set by user, try to locate tool using the code snippet
5653    for ac_prog in cpio
5654do
5655  # Extract the first word of "$ac_prog", so it can be a program name with args.
5656set dummy $ac_prog; ac_word=$2
5657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5658$as_echo_n "checking for $ac_word... " >&6; }
5659if ${ac_cv_path_CPIO+:} false; then :
5660  $as_echo_n "(cached) " >&6
5661else
5662  case $CPIO in
5663  [\\/]* | ?:[\\/]*)
5664  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5665  ;;
5666  *)
5667  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5668for as_dir in $PATH
5669do
5670  IFS=$as_save_IFS
5671  test -z "$as_dir" && as_dir=.
5672    for ac_exec_ext in '' $ac_executable_extensions; do
5673  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5674    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5675    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5676    break 2
5677  fi
5678done
5679  done
5680IFS=$as_save_IFS
5681
5682  ;;
5683esac
5684fi
5685CPIO=$ac_cv_path_CPIO
5686if test -n "$CPIO"; then
5687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5688$as_echo "$CPIO" >&6; }
5689else
5690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5691$as_echo "no" >&6; }
5692fi
5693
5694
5695  test -n "$CPIO" && break
5696done
5697
5698  else
5699    # The variable is set, but is it from the command line or the environment?
5700
5701    # Try to remove the string !CPIO! from our list.
5702    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/}
5703    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5704      # If it failed, the variable was not from the command line. Ignore it,
5705      # but warn the user (except for BASH, which is always set by the calling BASH).
5706      if test "xCPIO" != xBASH; then
5707        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5
5708$as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;}
5709      fi
5710      # Try to locate tool using the code snippet
5711      for ac_prog in cpio
5712do
5713  # Extract the first word of "$ac_prog", so it can be a program name with args.
5714set dummy $ac_prog; ac_word=$2
5715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5716$as_echo_n "checking for $ac_word... " >&6; }
5717if ${ac_cv_path_CPIO+:} false; then :
5718  $as_echo_n "(cached) " >&6
5719else
5720  case $CPIO in
5721  [\\/]* | ?:[\\/]*)
5722  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5723  ;;
5724  *)
5725  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5726for as_dir in $PATH
5727do
5728  IFS=$as_save_IFS
5729  test -z "$as_dir" && as_dir=.
5730    for ac_exec_ext in '' $ac_executable_extensions; do
5731  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5732    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5733    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5734    break 2
5735  fi
5736done
5737  done
5738IFS=$as_save_IFS
5739
5740  ;;
5741esac
5742fi
5743CPIO=$ac_cv_path_CPIO
5744if test -n "$CPIO"; then
5745  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5746$as_echo "$CPIO" >&6; }
5747else
5748  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5749$as_echo "no" >&6; }
5750fi
5751
5752
5753  test -n "$CPIO" && break
5754done
5755
5756    else
5757      # If it succeeded, then it was overridden by the user. We will use it
5758      # for the tool.
5759
5760      # First remove it from the list of overridden variables, so we can test
5761      # for unknown variables in the end.
5762      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5763
5764      # Check if the provided tool contains a complete path.
5765      tool_specified="$CPIO"
5766      tool_basename="${tool_specified##*/}"
5767      if test "x$tool_basename" = "x$tool_specified"; then
5768        # A command without a complete path is provided, search $PATH.
5769        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5
5770$as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;}
5771        # Extract the first word of "$tool_basename", so it can be a program name with args.
5772set dummy $tool_basename; ac_word=$2
5773{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5774$as_echo_n "checking for $ac_word... " >&6; }
5775if ${ac_cv_path_CPIO+:} false; then :
5776  $as_echo_n "(cached) " >&6
5777else
5778  case $CPIO in
5779  [\\/]* | ?:[\\/]*)
5780  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5781  ;;
5782  *)
5783  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5784for as_dir in $PATH
5785do
5786  IFS=$as_save_IFS
5787  test -z "$as_dir" && as_dir=.
5788    for ac_exec_ext in '' $ac_executable_extensions; do
5789  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5790    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5791    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5792    break 2
5793  fi
5794done
5795  done
5796IFS=$as_save_IFS
5797
5798  ;;
5799esac
5800fi
5801CPIO=$ac_cv_path_CPIO
5802if test -n "$CPIO"; then
5803  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5804$as_echo "$CPIO" >&6; }
5805else
5806  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5807$as_echo "no" >&6; }
5808fi
5809
5810
5811        if test "x$CPIO" = x; then
5812          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5813        fi
5814      else
5815        # Otherwise we believe it is a complete path. Use it as it is.
5816        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5
5817$as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;}
5818        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5
5819$as_echo_n "checking for CPIO... " >&6; }
5820        if test ! -x "$tool_specified"; then
5821          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5822$as_echo "not found" >&6; }
5823          as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5
5824        fi
5825        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5826$as_echo "$tool_specified" >&6; }
5827      fi
5828    fi
5829  fi
5830
5831
5832
5833  if test "x$CPIO" = x; then
5834    as_fn_error $? "Could not find required tool for CPIO" "$LINENO" 5
5835  fi
5836
5837
5838
5839
5840
5841  # Publish this variable in the help.
5842
5843
5844  if test "x$CUT" = x; then
5845    # The variable is not set by user, try to locate tool using the code snippet
5846    for ac_prog in cut
5847do
5848  # Extract the first word of "$ac_prog", so it can be a program name with args.
5849set dummy $ac_prog; ac_word=$2
5850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5851$as_echo_n "checking for $ac_word... " >&6; }
5852if ${ac_cv_path_CUT+:} false; then :
5853  $as_echo_n "(cached) " >&6
5854else
5855  case $CUT in
5856  [\\/]* | ?:[\\/]*)
5857  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5858  ;;
5859  *)
5860  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5861for as_dir in $PATH
5862do
5863  IFS=$as_save_IFS
5864  test -z "$as_dir" && as_dir=.
5865    for ac_exec_ext in '' $ac_executable_extensions; do
5866  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5867    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5868    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5869    break 2
5870  fi
5871done
5872  done
5873IFS=$as_save_IFS
5874
5875  ;;
5876esac
5877fi
5878CUT=$ac_cv_path_CUT
5879if test -n "$CUT"; then
5880  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5881$as_echo "$CUT" >&6; }
5882else
5883  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5884$as_echo "no" >&6; }
5885fi
5886
5887
5888  test -n "$CUT" && break
5889done
5890
5891  else
5892    # The variable is set, but is it from the command line or the environment?
5893
5894    # Try to remove the string !CUT! from our list.
5895    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/}
5896    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5897      # If it failed, the variable was not from the command line. Ignore it,
5898      # but warn the user (except for BASH, which is always set by the calling BASH).
5899      if test "xCUT" != xBASH; then
5900        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5
5901$as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;}
5902      fi
5903      # Try to locate tool using the code snippet
5904      for ac_prog in cut
5905do
5906  # Extract the first word of "$ac_prog", so it can be a program name with args.
5907set dummy $ac_prog; ac_word=$2
5908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5909$as_echo_n "checking for $ac_word... " >&6; }
5910if ${ac_cv_path_CUT+:} false; then :
5911  $as_echo_n "(cached) " >&6
5912else
5913  case $CUT in
5914  [\\/]* | ?:[\\/]*)
5915  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5916  ;;
5917  *)
5918  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5919for as_dir in $PATH
5920do
5921  IFS=$as_save_IFS
5922  test -z "$as_dir" && as_dir=.
5923    for ac_exec_ext in '' $ac_executable_extensions; do
5924  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5925    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5926    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5927    break 2
5928  fi
5929done
5930  done
5931IFS=$as_save_IFS
5932
5933  ;;
5934esac
5935fi
5936CUT=$ac_cv_path_CUT
5937if test -n "$CUT"; then
5938  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5939$as_echo "$CUT" >&6; }
5940else
5941  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5942$as_echo "no" >&6; }
5943fi
5944
5945
5946  test -n "$CUT" && break
5947done
5948
5949    else
5950      # If it succeeded, then it was overridden by the user. We will use it
5951      # for the tool.
5952
5953      # First remove it from the list of overridden variables, so we can test
5954      # for unknown variables in the end.
5955      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5956
5957      # Check if the provided tool contains a complete path.
5958      tool_specified="$CUT"
5959      tool_basename="${tool_specified##*/}"
5960      if test "x$tool_basename" = "x$tool_specified"; then
5961        # A command without a complete path is provided, search $PATH.
5962        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5
5963$as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;}
5964        # Extract the first word of "$tool_basename", so it can be a program name with args.
5965set dummy $tool_basename; ac_word=$2
5966{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5967$as_echo_n "checking for $ac_word... " >&6; }
5968if ${ac_cv_path_CUT+:} false; then :
5969  $as_echo_n "(cached) " >&6
5970else
5971  case $CUT in
5972  [\\/]* | ?:[\\/]*)
5973  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5974  ;;
5975  *)
5976  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5977for as_dir in $PATH
5978do
5979  IFS=$as_save_IFS
5980  test -z "$as_dir" && as_dir=.
5981    for ac_exec_ext in '' $ac_executable_extensions; do
5982  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5983    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5984    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5985    break 2
5986  fi
5987done
5988  done
5989IFS=$as_save_IFS
5990
5991  ;;
5992esac
5993fi
5994CUT=$ac_cv_path_CUT
5995if test -n "$CUT"; then
5996  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5997$as_echo "$CUT" >&6; }
5998else
5999  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6000$as_echo "no" >&6; }
6001fi
6002
6003
6004        if test "x$CUT" = x; then
6005          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6006        fi
6007      else
6008        # Otherwise we believe it is a complete path. Use it as it is.
6009        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5
6010$as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;}
6011        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5
6012$as_echo_n "checking for CUT... " >&6; }
6013        if test ! -x "$tool_specified"; then
6014          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6015$as_echo "not found" >&6; }
6016          as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5
6017        fi
6018        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6019$as_echo "$tool_specified" >&6; }
6020      fi
6021    fi
6022  fi
6023
6024
6025
6026  if test "x$CUT" = x; then
6027    as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5
6028  fi
6029
6030
6031
6032
6033
6034  # Publish this variable in the help.
6035
6036
6037  if test "x$DATE" = x; then
6038    # The variable is not set by user, try to locate tool using the code snippet
6039    for ac_prog in date
6040do
6041  # Extract the first word of "$ac_prog", so it can be a program name with args.
6042set dummy $ac_prog; ac_word=$2
6043{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6044$as_echo_n "checking for $ac_word... " >&6; }
6045if ${ac_cv_path_DATE+:} false; then :
6046  $as_echo_n "(cached) " >&6
6047else
6048  case $DATE in
6049  [\\/]* | ?:[\\/]*)
6050  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6051  ;;
6052  *)
6053  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6054for as_dir in $PATH
6055do
6056  IFS=$as_save_IFS
6057  test -z "$as_dir" && as_dir=.
6058    for ac_exec_ext in '' $ac_executable_extensions; do
6059  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6060    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6061    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6062    break 2
6063  fi
6064done
6065  done
6066IFS=$as_save_IFS
6067
6068  ;;
6069esac
6070fi
6071DATE=$ac_cv_path_DATE
6072if test -n "$DATE"; then
6073  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6074$as_echo "$DATE" >&6; }
6075else
6076  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6077$as_echo "no" >&6; }
6078fi
6079
6080
6081  test -n "$DATE" && break
6082done
6083
6084  else
6085    # The variable is set, but is it from the command line or the environment?
6086
6087    # Try to remove the string !DATE! from our list.
6088    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/}
6089    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6090      # If it failed, the variable was not from the command line. Ignore it,
6091      # but warn the user (except for BASH, which is always set by the calling BASH).
6092      if test "xDATE" != xBASH; then
6093        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5
6094$as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;}
6095      fi
6096      # Try to locate tool using the code snippet
6097      for ac_prog in date
6098do
6099  # Extract the first word of "$ac_prog", so it can be a program name with args.
6100set dummy $ac_prog; ac_word=$2
6101{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6102$as_echo_n "checking for $ac_word... " >&6; }
6103if ${ac_cv_path_DATE+:} false; then :
6104  $as_echo_n "(cached) " >&6
6105else
6106  case $DATE in
6107  [\\/]* | ?:[\\/]*)
6108  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6109  ;;
6110  *)
6111  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6112for as_dir in $PATH
6113do
6114  IFS=$as_save_IFS
6115  test -z "$as_dir" && as_dir=.
6116    for ac_exec_ext in '' $ac_executable_extensions; do
6117  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6118    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6119    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6120    break 2
6121  fi
6122done
6123  done
6124IFS=$as_save_IFS
6125
6126  ;;
6127esac
6128fi
6129DATE=$ac_cv_path_DATE
6130if test -n "$DATE"; then
6131  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6132$as_echo "$DATE" >&6; }
6133else
6134  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6135$as_echo "no" >&6; }
6136fi
6137
6138
6139  test -n "$DATE" && break
6140done
6141
6142    else
6143      # If it succeeded, then it was overridden by the user. We will use it
6144      # for the tool.
6145
6146      # First remove it from the list of overridden variables, so we can test
6147      # for unknown variables in the end.
6148      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6149
6150      # Check if the provided tool contains a complete path.
6151      tool_specified="$DATE"
6152      tool_basename="${tool_specified##*/}"
6153      if test "x$tool_basename" = "x$tool_specified"; then
6154        # A command without a complete path is provided, search $PATH.
6155        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5
6156$as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;}
6157        # Extract the first word of "$tool_basename", so it can be a program name with args.
6158set dummy $tool_basename; ac_word=$2
6159{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6160$as_echo_n "checking for $ac_word... " >&6; }
6161if ${ac_cv_path_DATE+:} false; then :
6162  $as_echo_n "(cached) " >&6
6163else
6164  case $DATE in
6165  [\\/]* | ?:[\\/]*)
6166  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6167  ;;
6168  *)
6169  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6170for as_dir in $PATH
6171do
6172  IFS=$as_save_IFS
6173  test -z "$as_dir" && as_dir=.
6174    for ac_exec_ext in '' $ac_executable_extensions; do
6175  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6176    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6177    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6178    break 2
6179  fi
6180done
6181  done
6182IFS=$as_save_IFS
6183
6184  ;;
6185esac
6186fi
6187DATE=$ac_cv_path_DATE
6188if test -n "$DATE"; then
6189  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6190$as_echo "$DATE" >&6; }
6191else
6192  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6193$as_echo "no" >&6; }
6194fi
6195
6196
6197        if test "x$DATE" = x; then
6198          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6199        fi
6200      else
6201        # Otherwise we believe it is a complete path. Use it as it is.
6202        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5
6203$as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;}
6204        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5
6205$as_echo_n "checking for DATE... " >&6; }
6206        if test ! -x "$tool_specified"; then
6207          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6208$as_echo "not found" >&6; }
6209          as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5
6210        fi
6211        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6212$as_echo "$tool_specified" >&6; }
6213      fi
6214    fi
6215  fi
6216
6217
6218
6219  if test "x$DATE" = x; then
6220    as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5
6221  fi
6222
6223
6224
6225
6226
6227  # Publish this variable in the help.
6228
6229
6230  if test "x$DIFF" = x; then
6231    # The variable is not set by user, try to locate tool using the code snippet
6232    for ac_prog in gdiff diff
6233do
6234  # Extract the first word of "$ac_prog", so it can be a program name with args.
6235set dummy $ac_prog; ac_word=$2
6236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6237$as_echo_n "checking for $ac_word... " >&6; }
6238if ${ac_cv_path_DIFF+:} false; then :
6239  $as_echo_n "(cached) " >&6
6240else
6241  case $DIFF in
6242  [\\/]* | ?:[\\/]*)
6243  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6244  ;;
6245  *)
6246  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6247for as_dir in $PATH
6248do
6249  IFS=$as_save_IFS
6250  test -z "$as_dir" && as_dir=.
6251    for ac_exec_ext in '' $ac_executable_extensions; do
6252  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6253    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6254    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6255    break 2
6256  fi
6257done
6258  done
6259IFS=$as_save_IFS
6260
6261  ;;
6262esac
6263fi
6264DIFF=$ac_cv_path_DIFF
6265if test -n "$DIFF"; then
6266  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6267$as_echo "$DIFF" >&6; }
6268else
6269  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6270$as_echo "no" >&6; }
6271fi
6272
6273
6274  test -n "$DIFF" && break
6275done
6276
6277  else
6278    # The variable is set, but is it from the command line or the environment?
6279
6280    # Try to remove the string !DIFF! from our list.
6281    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/}
6282    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6283      # If it failed, the variable was not from the command line. Ignore it,
6284      # but warn the user (except for BASH, which is always set by the calling BASH).
6285      if test "xDIFF" != xBASH; then
6286        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5
6287$as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;}
6288      fi
6289      # Try to locate tool using the code snippet
6290      for ac_prog in gdiff diff
6291do
6292  # Extract the first word of "$ac_prog", so it can be a program name with args.
6293set dummy $ac_prog; ac_word=$2
6294{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6295$as_echo_n "checking for $ac_word... " >&6; }
6296if ${ac_cv_path_DIFF+:} false; then :
6297  $as_echo_n "(cached) " >&6
6298else
6299  case $DIFF in
6300  [\\/]* | ?:[\\/]*)
6301  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6302  ;;
6303  *)
6304  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6305for as_dir in $PATH
6306do
6307  IFS=$as_save_IFS
6308  test -z "$as_dir" && as_dir=.
6309    for ac_exec_ext in '' $ac_executable_extensions; do
6310  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6311    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6312    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6313    break 2
6314  fi
6315done
6316  done
6317IFS=$as_save_IFS
6318
6319  ;;
6320esac
6321fi
6322DIFF=$ac_cv_path_DIFF
6323if test -n "$DIFF"; then
6324  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6325$as_echo "$DIFF" >&6; }
6326else
6327  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6328$as_echo "no" >&6; }
6329fi
6330
6331
6332  test -n "$DIFF" && break
6333done
6334
6335    else
6336      # If it succeeded, then it was overridden by the user. We will use it
6337      # for the tool.
6338
6339      # First remove it from the list of overridden variables, so we can test
6340      # for unknown variables in the end.
6341      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6342
6343      # Check if the provided tool contains a complete path.
6344      tool_specified="$DIFF"
6345      tool_basename="${tool_specified##*/}"
6346      if test "x$tool_basename" = "x$tool_specified"; then
6347        # A command without a complete path is provided, search $PATH.
6348        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5
6349$as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;}
6350        # Extract the first word of "$tool_basename", so it can be a program name with args.
6351set dummy $tool_basename; ac_word=$2
6352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6353$as_echo_n "checking for $ac_word... " >&6; }
6354if ${ac_cv_path_DIFF+:} false; then :
6355  $as_echo_n "(cached) " >&6
6356else
6357  case $DIFF in
6358  [\\/]* | ?:[\\/]*)
6359  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6360  ;;
6361  *)
6362  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6363for as_dir in $PATH
6364do
6365  IFS=$as_save_IFS
6366  test -z "$as_dir" && as_dir=.
6367    for ac_exec_ext in '' $ac_executable_extensions; do
6368  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6369    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6370    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6371    break 2
6372  fi
6373done
6374  done
6375IFS=$as_save_IFS
6376
6377  ;;
6378esac
6379fi
6380DIFF=$ac_cv_path_DIFF
6381if test -n "$DIFF"; then
6382  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6383$as_echo "$DIFF" >&6; }
6384else
6385  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6386$as_echo "no" >&6; }
6387fi
6388
6389
6390        if test "x$DIFF" = x; then
6391          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6392        fi
6393      else
6394        # Otherwise we believe it is a complete path. Use it as it is.
6395        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5
6396$as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;}
6397        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5
6398$as_echo_n "checking for DIFF... " >&6; }
6399        if test ! -x "$tool_specified"; then
6400          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6401$as_echo "not found" >&6; }
6402          as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5
6403        fi
6404        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6405$as_echo "$tool_specified" >&6; }
6406      fi
6407    fi
6408  fi
6409
6410
6411
6412  if test "x$DIFF" = x; then
6413    as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5
6414  fi
6415
6416
6417
6418
6419
6420  # Publish this variable in the help.
6421
6422
6423  if test "x$DIRNAME" = x; then
6424    # The variable is not set by user, try to locate tool using the code snippet
6425    for ac_prog in dirname
6426do
6427  # Extract the first word of "$ac_prog", so it can be a program name with args.
6428set dummy $ac_prog; ac_word=$2
6429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6430$as_echo_n "checking for $ac_word... " >&6; }
6431if ${ac_cv_path_DIRNAME+:} false; then :
6432  $as_echo_n "(cached) " >&6
6433else
6434  case $DIRNAME in
6435  [\\/]* | ?:[\\/]*)
6436  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6437  ;;
6438  *)
6439  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6440for as_dir in $PATH
6441do
6442  IFS=$as_save_IFS
6443  test -z "$as_dir" && as_dir=.
6444    for ac_exec_ext in '' $ac_executable_extensions; do
6445  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6446    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6447    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6448    break 2
6449  fi
6450done
6451  done
6452IFS=$as_save_IFS
6453
6454  ;;
6455esac
6456fi
6457DIRNAME=$ac_cv_path_DIRNAME
6458if test -n "$DIRNAME"; then
6459  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6460$as_echo "$DIRNAME" >&6; }
6461else
6462  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6463$as_echo "no" >&6; }
6464fi
6465
6466
6467  test -n "$DIRNAME" && break
6468done
6469
6470  else
6471    # The variable is set, but is it from the command line or the environment?
6472
6473    # Try to remove the string !DIRNAME! from our list.
6474    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/}
6475    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6476      # If it failed, the variable was not from the command line. Ignore it,
6477      # but warn the user (except for BASH, which is always set by the calling BASH).
6478      if test "xDIRNAME" != xBASH; then
6479        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5
6480$as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;}
6481      fi
6482      # Try to locate tool using the code snippet
6483      for ac_prog in dirname
6484do
6485  # Extract the first word of "$ac_prog", so it can be a program name with args.
6486set dummy $ac_prog; ac_word=$2
6487{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6488$as_echo_n "checking for $ac_word... " >&6; }
6489if ${ac_cv_path_DIRNAME+:} false; then :
6490  $as_echo_n "(cached) " >&6
6491else
6492  case $DIRNAME in
6493  [\\/]* | ?:[\\/]*)
6494  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6495  ;;
6496  *)
6497  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6498for as_dir in $PATH
6499do
6500  IFS=$as_save_IFS
6501  test -z "$as_dir" && as_dir=.
6502    for ac_exec_ext in '' $ac_executable_extensions; do
6503  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6504    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6505    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6506    break 2
6507  fi
6508done
6509  done
6510IFS=$as_save_IFS
6511
6512  ;;
6513esac
6514fi
6515DIRNAME=$ac_cv_path_DIRNAME
6516if test -n "$DIRNAME"; then
6517  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6518$as_echo "$DIRNAME" >&6; }
6519else
6520  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6521$as_echo "no" >&6; }
6522fi
6523
6524
6525  test -n "$DIRNAME" && break
6526done
6527
6528    else
6529      # If it succeeded, then it was overridden by the user. We will use it
6530      # for the tool.
6531
6532      # First remove it from the list of overridden variables, so we can test
6533      # for unknown variables in the end.
6534      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6535
6536      # Check if the provided tool contains a complete path.
6537      tool_specified="$DIRNAME"
6538      tool_basename="${tool_specified##*/}"
6539      if test "x$tool_basename" = "x$tool_specified"; then
6540        # A command without a complete path is provided, search $PATH.
6541        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5
6542$as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;}
6543        # Extract the first word of "$tool_basename", so it can be a program name with args.
6544set dummy $tool_basename; ac_word=$2
6545{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6546$as_echo_n "checking for $ac_word... " >&6; }
6547if ${ac_cv_path_DIRNAME+:} false; then :
6548  $as_echo_n "(cached) " >&6
6549else
6550  case $DIRNAME in
6551  [\\/]* | ?:[\\/]*)
6552  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6553  ;;
6554  *)
6555  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6556for as_dir in $PATH
6557do
6558  IFS=$as_save_IFS
6559  test -z "$as_dir" && as_dir=.
6560    for ac_exec_ext in '' $ac_executable_extensions; do
6561  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6562    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6563    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6564    break 2
6565  fi
6566done
6567  done
6568IFS=$as_save_IFS
6569
6570  ;;
6571esac
6572fi
6573DIRNAME=$ac_cv_path_DIRNAME
6574if test -n "$DIRNAME"; then
6575  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6576$as_echo "$DIRNAME" >&6; }
6577else
6578  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6579$as_echo "no" >&6; }
6580fi
6581
6582
6583        if test "x$DIRNAME" = x; then
6584          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6585        fi
6586      else
6587        # Otherwise we believe it is a complete path. Use it as it is.
6588        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5
6589$as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;}
6590        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5
6591$as_echo_n "checking for DIRNAME... " >&6; }
6592        if test ! -x "$tool_specified"; then
6593          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6594$as_echo "not found" >&6; }
6595          as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
6596        fi
6597        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6598$as_echo "$tool_specified" >&6; }
6599      fi
6600    fi
6601  fi
6602
6603
6604
6605  if test "x$DIRNAME" = x; then
6606    as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5
6607  fi
6608
6609
6610
6611
6612
6613  # Publish this variable in the help.
6614
6615
6616  if test "x$ECHO" = x; then
6617    # The variable is not set by user, try to locate tool using the code snippet
6618    for ac_prog in echo
6619do
6620  # Extract the first word of "$ac_prog", so it can be a program name with args.
6621set dummy $ac_prog; ac_word=$2
6622{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6623$as_echo_n "checking for $ac_word... " >&6; }
6624if ${ac_cv_path_ECHO+:} false; then :
6625  $as_echo_n "(cached) " >&6
6626else
6627  case $ECHO in
6628  [\\/]* | ?:[\\/]*)
6629  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6630  ;;
6631  *)
6632  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6633for as_dir in $PATH
6634do
6635  IFS=$as_save_IFS
6636  test -z "$as_dir" && as_dir=.
6637    for ac_exec_ext in '' $ac_executable_extensions; do
6638  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6639    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6640    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6641    break 2
6642  fi
6643done
6644  done
6645IFS=$as_save_IFS
6646
6647  ;;
6648esac
6649fi
6650ECHO=$ac_cv_path_ECHO
6651if test -n "$ECHO"; then
6652  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6653$as_echo "$ECHO" >&6; }
6654else
6655  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6656$as_echo "no" >&6; }
6657fi
6658
6659
6660  test -n "$ECHO" && break
6661done
6662
6663  else
6664    # The variable is set, but is it from the command line or the environment?
6665
6666    # Try to remove the string !ECHO! from our list.
6667    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/}
6668    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6669      # If it failed, the variable was not from the command line. Ignore it,
6670      # but warn the user (except for BASH, which is always set by the calling BASH).
6671      if test "xECHO" != xBASH; then
6672        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5
6673$as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;}
6674      fi
6675      # Try to locate tool using the code snippet
6676      for ac_prog in echo
6677do
6678  # Extract the first word of "$ac_prog", so it can be a program name with args.
6679set dummy $ac_prog; ac_word=$2
6680{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6681$as_echo_n "checking for $ac_word... " >&6; }
6682if ${ac_cv_path_ECHO+:} false; then :
6683  $as_echo_n "(cached) " >&6
6684else
6685  case $ECHO in
6686  [\\/]* | ?:[\\/]*)
6687  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6688  ;;
6689  *)
6690  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6691for as_dir in $PATH
6692do
6693  IFS=$as_save_IFS
6694  test -z "$as_dir" && as_dir=.
6695    for ac_exec_ext in '' $ac_executable_extensions; do
6696  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6697    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6698    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6699    break 2
6700  fi
6701done
6702  done
6703IFS=$as_save_IFS
6704
6705  ;;
6706esac
6707fi
6708ECHO=$ac_cv_path_ECHO
6709if test -n "$ECHO"; then
6710  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6711$as_echo "$ECHO" >&6; }
6712else
6713  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6714$as_echo "no" >&6; }
6715fi
6716
6717
6718  test -n "$ECHO" && break
6719done
6720
6721    else
6722      # If it succeeded, then it was overridden by the user. We will use it
6723      # for the tool.
6724
6725      # First remove it from the list of overridden variables, so we can test
6726      # for unknown variables in the end.
6727      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6728
6729      # Check if the provided tool contains a complete path.
6730      tool_specified="$ECHO"
6731      tool_basename="${tool_specified##*/}"
6732      if test "x$tool_basename" = "x$tool_specified"; then
6733        # A command without a complete path is provided, search $PATH.
6734        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5
6735$as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;}
6736        # Extract the first word of "$tool_basename", so it can be a program name with args.
6737set dummy $tool_basename; ac_word=$2
6738{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6739$as_echo_n "checking for $ac_word... " >&6; }
6740if ${ac_cv_path_ECHO+:} false; then :
6741  $as_echo_n "(cached) " >&6
6742else
6743  case $ECHO in
6744  [\\/]* | ?:[\\/]*)
6745  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6746  ;;
6747  *)
6748  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6749for as_dir in $PATH
6750do
6751  IFS=$as_save_IFS
6752  test -z "$as_dir" && as_dir=.
6753    for ac_exec_ext in '' $ac_executable_extensions; do
6754  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6755    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6756    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6757    break 2
6758  fi
6759done
6760  done
6761IFS=$as_save_IFS
6762
6763  ;;
6764esac
6765fi
6766ECHO=$ac_cv_path_ECHO
6767if test -n "$ECHO"; then
6768  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6769$as_echo "$ECHO" >&6; }
6770else
6771  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6772$as_echo "no" >&6; }
6773fi
6774
6775
6776        if test "x$ECHO" = x; then
6777          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6778        fi
6779      else
6780        # Otherwise we believe it is a complete path. Use it as it is.
6781        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5
6782$as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;}
6783        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5
6784$as_echo_n "checking for ECHO... " >&6; }
6785        if test ! -x "$tool_specified"; then
6786          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6787$as_echo "not found" >&6; }
6788          as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5
6789        fi
6790        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6791$as_echo "$tool_specified" >&6; }
6792      fi
6793    fi
6794  fi
6795
6796
6797
6798  if test "x$ECHO" = x; then
6799    as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5
6800  fi
6801
6802
6803
6804
6805
6806  # Publish this variable in the help.
6807
6808
6809  if test "x$EXPR" = x; then
6810    # The variable is not set by user, try to locate tool using the code snippet
6811    for ac_prog in expr
6812do
6813  # Extract the first word of "$ac_prog", so it can be a program name with args.
6814set dummy $ac_prog; ac_word=$2
6815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6816$as_echo_n "checking for $ac_word... " >&6; }
6817if ${ac_cv_path_EXPR+:} false; then :
6818  $as_echo_n "(cached) " >&6
6819else
6820  case $EXPR in
6821  [\\/]* | ?:[\\/]*)
6822  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6823  ;;
6824  *)
6825  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6826for as_dir in $PATH
6827do
6828  IFS=$as_save_IFS
6829  test -z "$as_dir" && as_dir=.
6830    for ac_exec_ext in '' $ac_executable_extensions; do
6831  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6832    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6833    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6834    break 2
6835  fi
6836done
6837  done
6838IFS=$as_save_IFS
6839
6840  ;;
6841esac
6842fi
6843EXPR=$ac_cv_path_EXPR
6844if test -n "$EXPR"; then
6845  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6846$as_echo "$EXPR" >&6; }
6847else
6848  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6849$as_echo "no" >&6; }
6850fi
6851
6852
6853  test -n "$EXPR" && break
6854done
6855
6856  else
6857    # The variable is set, but is it from the command line or the environment?
6858
6859    # Try to remove the string !EXPR! from our list.
6860    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/}
6861    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6862      # If it failed, the variable was not from the command line. Ignore it,
6863      # but warn the user (except for BASH, which is always set by the calling BASH).
6864      if test "xEXPR" != xBASH; then
6865        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5
6866$as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;}
6867      fi
6868      # Try to locate tool using the code snippet
6869      for ac_prog in expr
6870do
6871  # Extract the first word of "$ac_prog", so it can be a program name with args.
6872set dummy $ac_prog; ac_word=$2
6873{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6874$as_echo_n "checking for $ac_word... " >&6; }
6875if ${ac_cv_path_EXPR+:} false; then :
6876  $as_echo_n "(cached) " >&6
6877else
6878  case $EXPR in
6879  [\\/]* | ?:[\\/]*)
6880  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6881  ;;
6882  *)
6883  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6884for as_dir in $PATH
6885do
6886  IFS=$as_save_IFS
6887  test -z "$as_dir" && as_dir=.
6888    for ac_exec_ext in '' $ac_executable_extensions; do
6889  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6890    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6891    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6892    break 2
6893  fi
6894done
6895  done
6896IFS=$as_save_IFS
6897
6898  ;;
6899esac
6900fi
6901EXPR=$ac_cv_path_EXPR
6902if test -n "$EXPR"; then
6903  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6904$as_echo "$EXPR" >&6; }
6905else
6906  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6907$as_echo "no" >&6; }
6908fi
6909
6910
6911  test -n "$EXPR" && break
6912done
6913
6914    else
6915      # If it succeeded, then it was overridden by the user. We will use it
6916      # for the tool.
6917
6918      # First remove it from the list of overridden variables, so we can test
6919      # for unknown variables in the end.
6920      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6921
6922      # Check if the provided tool contains a complete path.
6923      tool_specified="$EXPR"
6924      tool_basename="${tool_specified##*/}"
6925      if test "x$tool_basename" = "x$tool_specified"; then
6926        # A command without a complete path is provided, search $PATH.
6927        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5
6928$as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;}
6929        # Extract the first word of "$tool_basename", so it can be a program name with args.
6930set dummy $tool_basename; ac_word=$2
6931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6932$as_echo_n "checking for $ac_word... " >&6; }
6933if ${ac_cv_path_EXPR+:} false; then :
6934  $as_echo_n "(cached) " >&6
6935else
6936  case $EXPR in
6937  [\\/]* | ?:[\\/]*)
6938  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6939  ;;
6940  *)
6941  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6942for as_dir in $PATH
6943do
6944  IFS=$as_save_IFS
6945  test -z "$as_dir" && as_dir=.
6946    for ac_exec_ext in '' $ac_executable_extensions; do
6947  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6948    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6949    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6950    break 2
6951  fi
6952done
6953  done
6954IFS=$as_save_IFS
6955
6956  ;;
6957esac
6958fi
6959EXPR=$ac_cv_path_EXPR
6960if test -n "$EXPR"; then
6961  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6962$as_echo "$EXPR" >&6; }
6963else
6964  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6965$as_echo "no" >&6; }
6966fi
6967
6968
6969        if test "x$EXPR" = x; then
6970          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6971        fi
6972      else
6973        # Otherwise we believe it is a complete path. Use it as it is.
6974        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5
6975$as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;}
6976        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5
6977$as_echo_n "checking for EXPR... " >&6; }
6978        if test ! -x "$tool_specified"; then
6979          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6980$as_echo "not found" >&6; }
6981          as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5
6982        fi
6983        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6984$as_echo "$tool_specified" >&6; }
6985      fi
6986    fi
6987  fi
6988
6989
6990
6991  if test "x$EXPR" = x; then
6992    as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5
6993  fi
6994
6995
6996
6997
6998
6999  # Publish this variable in the help.
7000
7001
7002  if test "x$FILE" = x; then
7003    # The variable is not set by user, try to locate tool using the code snippet
7004    for ac_prog in file
7005do
7006  # Extract the first word of "$ac_prog", so it can be a program name with args.
7007set dummy $ac_prog; ac_word=$2
7008{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7009$as_echo_n "checking for $ac_word... " >&6; }
7010if ${ac_cv_path_FILE+:} false; then :
7011  $as_echo_n "(cached) " >&6
7012else
7013  case $FILE in
7014  [\\/]* | ?:[\\/]*)
7015  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7016  ;;
7017  *)
7018  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7019for as_dir in $PATH
7020do
7021  IFS=$as_save_IFS
7022  test -z "$as_dir" && as_dir=.
7023    for ac_exec_ext in '' $ac_executable_extensions; do
7024  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7025    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7026    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7027    break 2
7028  fi
7029done
7030  done
7031IFS=$as_save_IFS
7032
7033  ;;
7034esac
7035fi
7036FILE=$ac_cv_path_FILE
7037if test -n "$FILE"; then
7038  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7039$as_echo "$FILE" >&6; }
7040else
7041  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7042$as_echo "no" >&6; }
7043fi
7044
7045
7046  test -n "$FILE" && break
7047done
7048
7049  else
7050    # The variable is set, but is it from the command line or the environment?
7051
7052    # Try to remove the string !FILE! from our list.
7053    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/}
7054    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7055      # If it failed, the variable was not from the command line. Ignore it,
7056      # but warn the user (except for BASH, which is always set by the calling BASH).
7057      if test "xFILE" != xBASH; then
7058        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5
7059$as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;}
7060      fi
7061      # Try to locate tool using the code snippet
7062      for ac_prog in file
7063do
7064  # Extract the first word of "$ac_prog", so it can be a program name with args.
7065set dummy $ac_prog; ac_word=$2
7066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7067$as_echo_n "checking for $ac_word... " >&6; }
7068if ${ac_cv_path_FILE+:} false; then :
7069  $as_echo_n "(cached) " >&6
7070else
7071  case $FILE in
7072  [\\/]* | ?:[\\/]*)
7073  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7074  ;;
7075  *)
7076  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7077for as_dir in $PATH
7078do
7079  IFS=$as_save_IFS
7080  test -z "$as_dir" && as_dir=.
7081    for ac_exec_ext in '' $ac_executable_extensions; do
7082  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7083    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7084    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7085    break 2
7086  fi
7087done
7088  done
7089IFS=$as_save_IFS
7090
7091  ;;
7092esac
7093fi
7094FILE=$ac_cv_path_FILE
7095if test -n "$FILE"; then
7096  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7097$as_echo "$FILE" >&6; }
7098else
7099  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7100$as_echo "no" >&6; }
7101fi
7102
7103
7104  test -n "$FILE" && break
7105done
7106
7107    else
7108      # If it succeeded, then it was overridden by the user. We will use it
7109      # for the tool.
7110
7111      # First remove it from the list of overridden variables, so we can test
7112      # for unknown variables in the end.
7113      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7114
7115      # Check if the provided tool contains a complete path.
7116      tool_specified="$FILE"
7117      tool_basename="${tool_specified##*/}"
7118      if test "x$tool_basename" = "x$tool_specified"; then
7119        # A command without a complete path is provided, search $PATH.
7120        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5
7121$as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;}
7122        # Extract the first word of "$tool_basename", so it can be a program name with args.
7123set dummy $tool_basename; ac_word=$2
7124{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7125$as_echo_n "checking for $ac_word... " >&6; }
7126if ${ac_cv_path_FILE+:} false; then :
7127  $as_echo_n "(cached) " >&6
7128else
7129  case $FILE in
7130  [\\/]* | ?:[\\/]*)
7131  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7132  ;;
7133  *)
7134  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7135for as_dir in $PATH
7136do
7137  IFS=$as_save_IFS
7138  test -z "$as_dir" && as_dir=.
7139    for ac_exec_ext in '' $ac_executable_extensions; do
7140  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7141    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7142    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7143    break 2
7144  fi
7145done
7146  done
7147IFS=$as_save_IFS
7148
7149  ;;
7150esac
7151fi
7152FILE=$ac_cv_path_FILE
7153if test -n "$FILE"; then
7154  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7155$as_echo "$FILE" >&6; }
7156else
7157  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7158$as_echo "no" >&6; }
7159fi
7160
7161
7162        if test "x$FILE" = x; then
7163          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7164        fi
7165      else
7166        # Otherwise we believe it is a complete path. Use it as it is.
7167        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5
7168$as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;}
7169        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5
7170$as_echo_n "checking for FILE... " >&6; }
7171        if test ! -x "$tool_specified"; then
7172          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7173$as_echo "not found" >&6; }
7174          as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5
7175        fi
7176        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7177$as_echo "$tool_specified" >&6; }
7178      fi
7179    fi
7180  fi
7181
7182
7183
7184  if test "x$FILE" = x; then
7185    as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5
7186  fi
7187
7188
7189
7190
7191
7192  # Publish this variable in the help.
7193
7194
7195  if test "x$FIND" = x; then
7196    # The variable is not set by user, try to locate tool using the code snippet
7197    for ac_prog in find
7198do
7199  # Extract the first word of "$ac_prog", so it can be a program name with args.
7200set dummy $ac_prog; ac_word=$2
7201{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7202$as_echo_n "checking for $ac_word... " >&6; }
7203if ${ac_cv_path_FIND+:} false; then :
7204  $as_echo_n "(cached) " >&6
7205else
7206  case $FIND in
7207  [\\/]* | ?:[\\/]*)
7208  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7209  ;;
7210  *)
7211  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7212for as_dir in $PATH
7213do
7214  IFS=$as_save_IFS
7215  test -z "$as_dir" && as_dir=.
7216    for ac_exec_ext in '' $ac_executable_extensions; do
7217  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7218    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7219    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7220    break 2
7221  fi
7222done
7223  done
7224IFS=$as_save_IFS
7225
7226  ;;
7227esac
7228fi
7229FIND=$ac_cv_path_FIND
7230if test -n "$FIND"; then
7231  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7232$as_echo "$FIND" >&6; }
7233else
7234  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7235$as_echo "no" >&6; }
7236fi
7237
7238
7239  test -n "$FIND" && break
7240done
7241
7242  else
7243    # The variable is set, but is it from the command line or the environment?
7244
7245    # Try to remove the string !FIND! from our list.
7246    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/}
7247    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7248      # If it failed, the variable was not from the command line. Ignore it,
7249      # but warn the user (except for BASH, which is always set by the calling BASH).
7250      if test "xFIND" != xBASH; then
7251        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5
7252$as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;}
7253      fi
7254      # Try to locate tool using the code snippet
7255      for ac_prog in find
7256do
7257  # Extract the first word of "$ac_prog", so it can be a program name with args.
7258set dummy $ac_prog; ac_word=$2
7259{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7260$as_echo_n "checking for $ac_word... " >&6; }
7261if ${ac_cv_path_FIND+:} false; then :
7262  $as_echo_n "(cached) " >&6
7263else
7264  case $FIND in
7265  [\\/]* | ?:[\\/]*)
7266  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7267  ;;
7268  *)
7269  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7270for as_dir in $PATH
7271do
7272  IFS=$as_save_IFS
7273  test -z "$as_dir" && as_dir=.
7274    for ac_exec_ext in '' $ac_executable_extensions; do
7275  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7276    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7277    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7278    break 2
7279  fi
7280done
7281  done
7282IFS=$as_save_IFS
7283
7284  ;;
7285esac
7286fi
7287FIND=$ac_cv_path_FIND
7288if test -n "$FIND"; then
7289  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7290$as_echo "$FIND" >&6; }
7291else
7292  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7293$as_echo "no" >&6; }
7294fi
7295
7296
7297  test -n "$FIND" && break
7298done
7299
7300    else
7301      # If it succeeded, then it was overridden by the user. We will use it
7302      # for the tool.
7303
7304      # First remove it from the list of overridden variables, so we can test
7305      # for unknown variables in the end.
7306      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7307
7308      # Check if the provided tool contains a complete path.
7309      tool_specified="$FIND"
7310      tool_basename="${tool_specified##*/}"
7311      if test "x$tool_basename" = "x$tool_specified"; then
7312        # A command without a complete path is provided, search $PATH.
7313        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5
7314$as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;}
7315        # Extract the first word of "$tool_basename", so it can be a program name with args.
7316set dummy $tool_basename; ac_word=$2
7317{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7318$as_echo_n "checking for $ac_word... " >&6; }
7319if ${ac_cv_path_FIND+:} false; then :
7320  $as_echo_n "(cached) " >&6
7321else
7322  case $FIND in
7323  [\\/]* | ?:[\\/]*)
7324  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7325  ;;
7326  *)
7327  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7328for as_dir in $PATH
7329do
7330  IFS=$as_save_IFS
7331  test -z "$as_dir" && as_dir=.
7332    for ac_exec_ext in '' $ac_executable_extensions; do
7333  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7334    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7335    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7336    break 2
7337  fi
7338done
7339  done
7340IFS=$as_save_IFS
7341
7342  ;;
7343esac
7344fi
7345FIND=$ac_cv_path_FIND
7346if test -n "$FIND"; then
7347  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7348$as_echo "$FIND" >&6; }
7349else
7350  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7351$as_echo "no" >&6; }
7352fi
7353
7354
7355        if test "x$FIND" = x; then
7356          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7357        fi
7358      else
7359        # Otherwise we believe it is a complete path. Use it as it is.
7360        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5
7361$as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;}
7362        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5
7363$as_echo_n "checking for FIND... " >&6; }
7364        if test ! -x "$tool_specified"; then
7365          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7366$as_echo "not found" >&6; }
7367          as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5
7368        fi
7369        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7370$as_echo "$tool_specified" >&6; }
7371      fi
7372    fi
7373  fi
7374
7375
7376
7377  if test "x$FIND" = x; then
7378    as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5
7379  fi
7380
7381
7382
7383
7384
7385  # Publish this variable in the help.
7386
7387
7388  if test "x$HEAD" = x; then
7389    # The variable is not set by user, try to locate tool using the code snippet
7390    for ac_prog in head
7391do
7392  # Extract the first word of "$ac_prog", so it can be a program name with args.
7393set dummy $ac_prog; ac_word=$2
7394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7395$as_echo_n "checking for $ac_word... " >&6; }
7396if ${ac_cv_path_HEAD+:} false; then :
7397  $as_echo_n "(cached) " >&6
7398else
7399  case $HEAD in
7400  [\\/]* | ?:[\\/]*)
7401  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7402  ;;
7403  *)
7404  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7405for as_dir in $PATH
7406do
7407  IFS=$as_save_IFS
7408  test -z "$as_dir" && as_dir=.
7409    for ac_exec_ext in '' $ac_executable_extensions; do
7410  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7411    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7412    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7413    break 2
7414  fi
7415done
7416  done
7417IFS=$as_save_IFS
7418
7419  ;;
7420esac
7421fi
7422HEAD=$ac_cv_path_HEAD
7423if test -n "$HEAD"; then
7424  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7425$as_echo "$HEAD" >&6; }
7426else
7427  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7428$as_echo "no" >&6; }
7429fi
7430
7431
7432  test -n "$HEAD" && break
7433done
7434
7435  else
7436    # The variable is set, but is it from the command line or the environment?
7437
7438    # Try to remove the string !HEAD! from our list.
7439    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/}
7440    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7441      # If it failed, the variable was not from the command line. Ignore it,
7442      # but warn the user (except for BASH, which is always set by the calling BASH).
7443      if test "xHEAD" != xBASH; then
7444        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5
7445$as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;}
7446      fi
7447      # Try to locate tool using the code snippet
7448      for ac_prog in head
7449do
7450  # Extract the first word of "$ac_prog", so it can be a program name with args.
7451set dummy $ac_prog; ac_word=$2
7452{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7453$as_echo_n "checking for $ac_word... " >&6; }
7454if ${ac_cv_path_HEAD+:} false; then :
7455  $as_echo_n "(cached) " >&6
7456else
7457  case $HEAD in
7458  [\\/]* | ?:[\\/]*)
7459  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7460  ;;
7461  *)
7462  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7463for as_dir in $PATH
7464do
7465  IFS=$as_save_IFS
7466  test -z "$as_dir" && as_dir=.
7467    for ac_exec_ext in '' $ac_executable_extensions; do
7468  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7469    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7470    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7471    break 2
7472  fi
7473done
7474  done
7475IFS=$as_save_IFS
7476
7477  ;;
7478esac
7479fi
7480HEAD=$ac_cv_path_HEAD
7481if test -n "$HEAD"; then
7482  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7483$as_echo "$HEAD" >&6; }
7484else
7485  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7486$as_echo "no" >&6; }
7487fi
7488
7489
7490  test -n "$HEAD" && break
7491done
7492
7493    else
7494      # If it succeeded, then it was overridden by the user. We will use it
7495      # for the tool.
7496
7497      # First remove it from the list of overridden variables, so we can test
7498      # for unknown variables in the end.
7499      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7500
7501      # Check if the provided tool contains a complete path.
7502      tool_specified="$HEAD"
7503      tool_basename="${tool_specified##*/}"
7504      if test "x$tool_basename" = "x$tool_specified"; then
7505        # A command without a complete path is provided, search $PATH.
7506        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5
7507$as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;}
7508        # Extract the first word of "$tool_basename", so it can be a program name with args.
7509set dummy $tool_basename; ac_word=$2
7510{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7511$as_echo_n "checking for $ac_word... " >&6; }
7512if ${ac_cv_path_HEAD+:} false; then :
7513  $as_echo_n "(cached) " >&6
7514else
7515  case $HEAD in
7516  [\\/]* | ?:[\\/]*)
7517  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7518  ;;
7519  *)
7520  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7521for as_dir in $PATH
7522do
7523  IFS=$as_save_IFS
7524  test -z "$as_dir" && as_dir=.
7525    for ac_exec_ext in '' $ac_executable_extensions; do
7526  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7527    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7528    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7529    break 2
7530  fi
7531done
7532  done
7533IFS=$as_save_IFS
7534
7535  ;;
7536esac
7537fi
7538HEAD=$ac_cv_path_HEAD
7539if test -n "$HEAD"; then
7540  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7541$as_echo "$HEAD" >&6; }
7542else
7543  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7544$as_echo "no" >&6; }
7545fi
7546
7547
7548        if test "x$HEAD" = x; then
7549          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7550        fi
7551      else
7552        # Otherwise we believe it is a complete path. Use it as it is.
7553        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5
7554$as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;}
7555        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5
7556$as_echo_n "checking for HEAD... " >&6; }
7557        if test ! -x "$tool_specified"; then
7558          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7559$as_echo "not found" >&6; }
7560          as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5
7561        fi
7562        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7563$as_echo "$tool_specified" >&6; }
7564      fi
7565    fi
7566  fi
7567
7568
7569
7570  if test "x$HEAD" = x; then
7571    as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5
7572  fi
7573
7574
7575
7576
7577
7578  # Publish this variable in the help.
7579
7580
7581  if test "x$LN" = x; then
7582    # The variable is not set by user, try to locate tool using the code snippet
7583    for ac_prog in ln
7584do
7585  # Extract the first word of "$ac_prog", so it can be a program name with args.
7586set dummy $ac_prog; ac_word=$2
7587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7588$as_echo_n "checking for $ac_word... " >&6; }
7589if ${ac_cv_path_LN+:} false; then :
7590  $as_echo_n "(cached) " >&6
7591else
7592  case $LN in
7593  [\\/]* | ?:[\\/]*)
7594  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7595  ;;
7596  *)
7597  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7598for as_dir in $PATH
7599do
7600  IFS=$as_save_IFS
7601  test -z "$as_dir" && as_dir=.
7602    for ac_exec_ext in '' $ac_executable_extensions; do
7603  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7604    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7605    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7606    break 2
7607  fi
7608done
7609  done
7610IFS=$as_save_IFS
7611
7612  ;;
7613esac
7614fi
7615LN=$ac_cv_path_LN
7616if test -n "$LN"; then
7617  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7618$as_echo "$LN" >&6; }
7619else
7620  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7621$as_echo "no" >&6; }
7622fi
7623
7624
7625  test -n "$LN" && break
7626done
7627
7628  else
7629    # The variable is set, but is it from the command line or the environment?
7630
7631    # Try to remove the string !LN! from our list.
7632    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/}
7633    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7634      # If it failed, the variable was not from the command line. Ignore it,
7635      # but warn the user (except for BASH, which is always set by the calling BASH).
7636      if test "xLN" != xBASH; then
7637        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5
7638$as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;}
7639      fi
7640      # Try to locate tool using the code snippet
7641      for ac_prog in ln
7642do
7643  # Extract the first word of "$ac_prog", so it can be a program name with args.
7644set dummy $ac_prog; ac_word=$2
7645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7646$as_echo_n "checking for $ac_word... " >&6; }
7647if ${ac_cv_path_LN+:} false; then :
7648  $as_echo_n "(cached) " >&6
7649else
7650  case $LN in
7651  [\\/]* | ?:[\\/]*)
7652  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7653  ;;
7654  *)
7655  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7656for as_dir in $PATH
7657do
7658  IFS=$as_save_IFS
7659  test -z "$as_dir" && as_dir=.
7660    for ac_exec_ext in '' $ac_executable_extensions; do
7661  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7662    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7663    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7664    break 2
7665  fi
7666done
7667  done
7668IFS=$as_save_IFS
7669
7670  ;;
7671esac
7672fi
7673LN=$ac_cv_path_LN
7674if test -n "$LN"; then
7675  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7676$as_echo "$LN" >&6; }
7677else
7678  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7679$as_echo "no" >&6; }
7680fi
7681
7682
7683  test -n "$LN" && break
7684done
7685
7686    else
7687      # If it succeeded, then it was overridden by the user. We will use it
7688      # for the tool.
7689
7690      # First remove it from the list of overridden variables, so we can test
7691      # for unknown variables in the end.
7692      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7693
7694      # Check if the provided tool contains a complete path.
7695      tool_specified="$LN"
7696      tool_basename="${tool_specified##*/}"
7697      if test "x$tool_basename" = "x$tool_specified"; then
7698        # A command without a complete path is provided, search $PATH.
7699        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5
7700$as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;}
7701        # Extract the first word of "$tool_basename", so it can be a program name with args.
7702set dummy $tool_basename; ac_word=$2
7703{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7704$as_echo_n "checking for $ac_word... " >&6; }
7705if ${ac_cv_path_LN+:} false; then :
7706  $as_echo_n "(cached) " >&6
7707else
7708  case $LN in
7709  [\\/]* | ?:[\\/]*)
7710  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7711  ;;
7712  *)
7713  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7714for as_dir in $PATH
7715do
7716  IFS=$as_save_IFS
7717  test -z "$as_dir" && as_dir=.
7718    for ac_exec_ext in '' $ac_executable_extensions; do
7719  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7720    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7721    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7722    break 2
7723  fi
7724done
7725  done
7726IFS=$as_save_IFS
7727
7728  ;;
7729esac
7730fi
7731LN=$ac_cv_path_LN
7732if test -n "$LN"; then
7733  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7734$as_echo "$LN" >&6; }
7735else
7736  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7737$as_echo "no" >&6; }
7738fi
7739
7740
7741        if test "x$LN" = x; then
7742          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7743        fi
7744      else
7745        # Otherwise we believe it is a complete path. Use it as it is.
7746        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5
7747$as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;}
7748        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5
7749$as_echo_n "checking for LN... " >&6; }
7750        if test ! -x "$tool_specified"; then
7751          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7752$as_echo "not found" >&6; }
7753          as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5
7754        fi
7755        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7756$as_echo "$tool_specified" >&6; }
7757      fi
7758    fi
7759  fi
7760
7761
7762
7763  if test "x$LN" = x; then
7764    as_fn_error $? "Could not find required tool for LN" "$LINENO" 5
7765  fi
7766
7767
7768
7769
7770
7771  # Publish this variable in the help.
7772
7773
7774  if test "x$LS" = x; then
7775    # The variable is not set by user, try to locate tool using the code snippet
7776    for ac_prog in ls
7777do
7778  # Extract the first word of "$ac_prog", so it can be a program name with args.
7779set dummy $ac_prog; ac_word=$2
7780{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7781$as_echo_n "checking for $ac_word... " >&6; }
7782if ${ac_cv_path_LS+:} false; then :
7783  $as_echo_n "(cached) " >&6
7784else
7785  case $LS in
7786  [\\/]* | ?:[\\/]*)
7787  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7788  ;;
7789  *)
7790  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7791for as_dir in $PATH
7792do
7793  IFS=$as_save_IFS
7794  test -z "$as_dir" && as_dir=.
7795    for ac_exec_ext in '' $ac_executable_extensions; do
7796  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7797    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7798    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7799    break 2
7800  fi
7801done
7802  done
7803IFS=$as_save_IFS
7804
7805  ;;
7806esac
7807fi
7808LS=$ac_cv_path_LS
7809if test -n "$LS"; then
7810  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7811$as_echo "$LS" >&6; }
7812else
7813  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7814$as_echo "no" >&6; }
7815fi
7816
7817
7818  test -n "$LS" && break
7819done
7820
7821  else
7822    # The variable is set, but is it from the command line or the environment?
7823
7824    # Try to remove the string !LS! from our list.
7825    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/}
7826    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7827      # If it failed, the variable was not from the command line. Ignore it,
7828      # but warn the user (except for BASH, which is always set by the calling BASH).
7829      if test "xLS" != xBASH; then
7830        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5
7831$as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;}
7832      fi
7833      # Try to locate tool using the code snippet
7834      for ac_prog in ls
7835do
7836  # Extract the first word of "$ac_prog", so it can be a program name with args.
7837set dummy $ac_prog; ac_word=$2
7838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7839$as_echo_n "checking for $ac_word... " >&6; }
7840if ${ac_cv_path_LS+:} false; then :
7841  $as_echo_n "(cached) " >&6
7842else
7843  case $LS in
7844  [\\/]* | ?:[\\/]*)
7845  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7846  ;;
7847  *)
7848  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7849for as_dir in $PATH
7850do
7851  IFS=$as_save_IFS
7852  test -z "$as_dir" && as_dir=.
7853    for ac_exec_ext in '' $ac_executable_extensions; do
7854  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7855    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7856    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7857    break 2
7858  fi
7859done
7860  done
7861IFS=$as_save_IFS
7862
7863  ;;
7864esac
7865fi
7866LS=$ac_cv_path_LS
7867if test -n "$LS"; then
7868  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7869$as_echo "$LS" >&6; }
7870else
7871  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7872$as_echo "no" >&6; }
7873fi
7874
7875
7876  test -n "$LS" && break
7877done
7878
7879    else
7880      # If it succeeded, then it was overridden by the user. We will use it
7881      # for the tool.
7882
7883      # First remove it from the list of overridden variables, so we can test
7884      # for unknown variables in the end.
7885      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7886
7887      # Check if the provided tool contains a complete path.
7888      tool_specified="$LS"
7889      tool_basename="${tool_specified##*/}"
7890      if test "x$tool_basename" = "x$tool_specified"; then
7891        # A command without a complete path is provided, search $PATH.
7892        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5
7893$as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;}
7894        # Extract the first word of "$tool_basename", so it can be a program name with args.
7895set dummy $tool_basename; ac_word=$2
7896{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7897$as_echo_n "checking for $ac_word... " >&6; }
7898if ${ac_cv_path_LS+:} false; then :
7899  $as_echo_n "(cached) " >&6
7900else
7901  case $LS in
7902  [\\/]* | ?:[\\/]*)
7903  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7904  ;;
7905  *)
7906  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7907for as_dir in $PATH
7908do
7909  IFS=$as_save_IFS
7910  test -z "$as_dir" && as_dir=.
7911    for ac_exec_ext in '' $ac_executable_extensions; do
7912  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7913    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7914    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7915    break 2
7916  fi
7917done
7918  done
7919IFS=$as_save_IFS
7920
7921  ;;
7922esac
7923fi
7924LS=$ac_cv_path_LS
7925if test -n "$LS"; then
7926  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7927$as_echo "$LS" >&6; }
7928else
7929  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7930$as_echo "no" >&6; }
7931fi
7932
7933
7934        if test "x$LS" = x; then
7935          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7936        fi
7937      else
7938        # Otherwise we believe it is a complete path. Use it as it is.
7939        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5
7940$as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;}
7941        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5
7942$as_echo_n "checking for LS... " >&6; }
7943        if test ! -x "$tool_specified"; then
7944          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7945$as_echo "not found" >&6; }
7946          as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5
7947        fi
7948        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7949$as_echo "$tool_specified" >&6; }
7950      fi
7951    fi
7952  fi
7953
7954
7955
7956  if test "x$LS" = x; then
7957    as_fn_error $? "Could not find required tool for LS" "$LINENO" 5
7958  fi
7959
7960
7961
7962
7963
7964  # Publish this variable in the help.
7965
7966
7967  if test "x$MKDIR" = x; then
7968    # The variable is not set by user, try to locate tool using the code snippet
7969    for ac_prog in mkdir
7970do
7971  # Extract the first word of "$ac_prog", so it can be a program name with args.
7972set dummy $ac_prog; ac_word=$2
7973{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7974$as_echo_n "checking for $ac_word... " >&6; }
7975if ${ac_cv_path_MKDIR+:} false; then :
7976  $as_echo_n "(cached) " >&6
7977else
7978  case $MKDIR in
7979  [\\/]* | ?:[\\/]*)
7980  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7981  ;;
7982  *)
7983  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7984for as_dir in $PATH
7985do
7986  IFS=$as_save_IFS
7987  test -z "$as_dir" && as_dir=.
7988    for ac_exec_ext in '' $ac_executable_extensions; do
7989  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7990    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7991    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7992    break 2
7993  fi
7994done
7995  done
7996IFS=$as_save_IFS
7997
7998  ;;
7999esac
8000fi
8001MKDIR=$ac_cv_path_MKDIR
8002if test -n "$MKDIR"; then
8003  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8004$as_echo "$MKDIR" >&6; }
8005else
8006  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8007$as_echo "no" >&6; }
8008fi
8009
8010
8011  test -n "$MKDIR" && break
8012done
8013
8014  else
8015    # The variable is set, but is it from the command line or the environment?
8016
8017    # Try to remove the string !MKDIR! from our list.
8018    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/}
8019    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8020      # If it failed, the variable was not from the command line. Ignore it,
8021      # but warn the user (except for BASH, which is always set by the calling BASH).
8022      if test "xMKDIR" != xBASH; then
8023        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5
8024$as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;}
8025      fi
8026      # Try to locate tool using the code snippet
8027      for ac_prog in mkdir
8028do
8029  # Extract the first word of "$ac_prog", so it can be a program name with args.
8030set dummy $ac_prog; ac_word=$2
8031{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8032$as_echo_n "checking for $ac_word... " >&6; }
8033if ${ac_cv_path_MKDIR+:} false; then :
8034  $as_echo_n "(cached) " >&6
8035else
8036  case $MKDIR in
8037  [\\/]* | ?:[\\/]*)
8038  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8039  ;;
8040  *)
8041  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8042for as_dir in $PATH
8043do
8044  IFS=$as_save_IFS
8045  test -z "$as_dir" && as_dir=.
8046    for ac_exec_ext in '' $ac_executable_extensions; do
8047  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8048    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8049    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8050    break 2
8051  fi
8052done
8053  done
8054IFS=$as_save_IFS
8055
8056  ;;
8057esac
8058fi
8059MKDIR=$ac_cv_path_MKDIR
8060if test -n "$MKDIR"; then
8061  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8062$as_echo "$MKDIR" >&6; }
8063else
8064  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8065$as_echo "no" >&6; }
8066fi
8067
8068
8069  test -n "$MKDIR" && break
8070done
8071
8072    else
8073      # If it succeeded, then it was overridden by the user. We will use it
8074      # for the tool.
8075
8076      # First remove it from the list of overridden variables, so we can test
8077      # for unknown variables in the end.
8078      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8079
8080      # Check if the provided tool contains a complete path.
8081      tool_specified="$MKDIR"
8082      tool_basename="${tool_specified##*/}"
8083      if test "x$tool_basename" = "x$tool_specified"; then
8084        # A command without a complete path is provided, search $PATH.
8085        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5
8086$as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;}
8087        # Extract the first word of "$tool_basename", so it can be a program name with args.
8088set dummy $tool_basename; ac_word=$2
8089{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8090$as_echo_n "checking for $ac_word... " >&6; }
8091if ${ac_cv_path_MKDIR+:} false; then :
8092  $as_echo_n "(cached) " >&6
8093else
8094  case $MKDIR in
8095  [\\/]* | ?:[\\/]*)
8096  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8097  ;;
8098  *)
8099  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8100for as_dir in $PATH
8101do
8102  IFS=$as_save_IFS
8103  test -z "$as_dir" && as_dir=.
8104    for ac_exec_ext in '' $ac_executable_extensions; do
8105  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8106    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8107    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8108    break 2
8109  fi
8110done
8111  done
8112IFS=$as_save_IFS
8113
8114  ;;
8115esac
8116fi
8117MKDIR=$ac_cv_path_MKDIR
8118if test -n "$MKDIR"; then
8119  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8120$as_echo "$MKDIR" >&6; }
8121else
8122  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8123$as_echo "no" >&6; }
8124fi
8125
8126
8127        if test "x$MKDIR" = x; then
8128          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8129        fi
8130      else
8131        # Otherwise we believe it is a complete path. Use it as it is.
8132        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5
8133$as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;}
8134        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5
8135$as_echo_n "checking for MKDIR... " >&6; }
8136        if test ! -x "$tool_specified"; then
8137          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8138$as_echo "not found" >&6; }
8139          as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5
8140        fi
8141        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8142$as_echo "$tool_specified" >&6; }
8143      fi
8144    fi
8145  fi
8146
8147
8148
8149  if test "x$MKDIR" = x; then
8150    as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5
8151  fi
8152
8153
8154
8155
8156
8157  # Publish this variable in the help.
8158
8159
8160  if test "x$MKTEMP" = x; then
8161    # The variable is not set by user, try to locate tool using the code snippet
8162    for ac_prog in mktemp
8163do
8164  # Extract the first word of "$ac_prog", so it can be a program name with args.
8165set dummy $ac_prog; ac_word=$2
8166{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8167$as_echo_n "checking for $ac_word... " >&6; }
8168if ${ac_cv_path_MKTEMP+:} false; then :
8169  $as_echo_n "(cached) " >&6
8170else
8171  case $MKTEMP in
8172  [\\/]* | ?:[\\/]*)
8173  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8174  ;;
8175  *)
8176  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8177for as_dir in $PATH
8178do
8179  IFS=$as_save_IFS
8180  test -z "$as_dir" && as_dir=.
8181    for ac_exec_ext in '' $ac_executable_extensions; do
8182  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8183    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8184    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8185    break 2
8186  fi
8187done
8188  done
8189IFS=$as_save_IFS
8190
8191  ;;
8192esac
8193fi
8194MKTEMP=$ac_cv_path_MKTEMP
8195if test -n "$MKTEMP"; then
8196  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8197$as_echo "$MKTEMP" >&6; }
8198else
8199  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8200$as_echo "no" >&6; }
8201fi
8202
8203
8204  test -n "$MKTEMP" && break
8205done
8206
8207  else
8208    # The variable is set, but is it from the command line or the environment?
8209
8210    # Try to remove the string !MKTEMP! from our list.
8211    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/}
8212    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8213      # If it failed, the variable was not from the command line. Ignore it,
8214      # but warn the user (except for BASH, which is always set by the calling BASH).
8215      if test "xMKTEMP" != xBASH; then
8216        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5
8217$as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;}
8218      fi
8219      # Try to locate tool using the code snippet
8220      for ac_prog in mktemp
8221do
8222  # Extract the first word of "$ac_prog", so it can be a program name with args.
8223set dummy $ac_prog; ac_word=$2
8224{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8225$as_echo_n "checking for $ac_word... " >&6; }
8226if ${ac_cv_path_MKTEMP+:} false; then :
8227  $as_echo_n "(cached) " >&6
8228else
8229  case $MKTEMP in
8230  [\\/]* | ?:[\\/]*)
8231  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8232  ;;
8233  *)
8234  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8235for as_dir in $PATH
8236do
8237  IFS=$as_save_IFS
8238  test -z "$as_dir" && as_dir=.
8239    for ac_exec_ext in '' $ac_executable_extensions; do
8240  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8241    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8242    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8243    break 2
8244  fi
8245done
8246  done
8247IFS=$as_save_IFS
8248
8249  ;;
8250esac
8251fi
8252MKTEMP=$ac_cv_path_MKTEMP
8253if test -n "$MKTEMP"; then
8254  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8255$as_echo "$MKTEMP" >&6; }
8256else
8257  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8258$as_echo "no" >&6; }
8259fi
8260
8261
8262  test -n "$MKTEMP" && break
8263done
8264
8265    else
8266      # If it succeeded, then it was overridden by the user. We will use it
8267      # for the tool.
8268
8269      # First remove it from the list of overridden variables, so we can test
8270      # for unknown variables in the end.
8271      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8272
8273      # Check if the provided tool contains a complete path.
8274      tool_specified="$MKTEMP"
8275      tool_basename="${tool_specified##*/}"
8276      if test "x$tool_basename" = "x$tool_specified"; then
8277        # A command without a complete path is provided, search $PATH.
8278        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5
8279$as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;}
8280        # Extract the first word of "$tool_basename", so it can be a program name with args.
8281set dummy $tool_basename; ac_word=$2
8282{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8283$as_echo_n "checking for $ac_word... " >&6; }
8284if ${ac_cv_path_MKTEMP+:} false; then :
8285  $as_echo_n "(cached) " >&6
8286else
8287  case $MKTEMP in
8288  [\\/]* | ?:[\\/]*)
8289  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8290  ;;
8291  *)
8292  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8293for as_dir in $PATH
8294do
8295  IFS=$as_save_IFS
8296  test -z "$as_dir" && as_dir=.
8297    for ac_exec_ext in '' $ac_executable_extensions; do
8298  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8299    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8300    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8301    break 2
8302  fi
8303done
8304  done
8305IFS=$as_save_IFS
8306
8307  ;;
8308esac
8309fi
8310MKTEMP=$ac_cv_path_MKTEMP
8311if test -n "$MKTEMP"; then
8312  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8313$as_echo "$MKTEMP" >&6; }
8314else
8315  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8316$as_echo "no" >&6; }
8317fi
8318
8319
8320        if test "x$MKTEMP" = x; then
8321          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8322        fi
8323      else
8324        # Otherwise we believe it is a complete path. Use it as it is.
8325        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5
8326$as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;}
8327        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5
8328$as_echo_n "checking for MKTEMP... " >&6; }
8329        if test ! -x "$tool_specified"; then
8330          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8331$as_echo "not found" >&6; }
8332          as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5
8333        fi
8334        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8335$as_echo "$tool_specified" >&6; }
8336      fi
8337    fi
8338  fi
8339
8340
8341
8342  if test "x$MKTEMP" = x; then
8343    as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5
8344  fi
8345
8346
8347
8348
8349
8350  # Publish this variable in the help.
8351
8352
8353  if test "x$MV" = x; then
8354    # The variable is not set by user, try to locate tool using the code snippet
8355    for ac_prog in mv
8356do
8357  # Extract the first word of "$ac_prog", so it can be a program name with args.
8358set dummy $ac_prog; ac_word=$2
8359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8360$as_echo_n "checking for $ac_word... " >&6; }
8361if ${ac_cv_path_MV+:} false; then :
8362  $as_echo_n "(cached) " >&6
8363else
8364  case $MV in
8365  [\\/]* | ?:[\\/]*)
8366  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8367  ;;
8368  *)
8369  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8370for as_dir in $PATH
8371do
8372  IFS=$as_save_IFS
8373  test -z "$as_dir" && as_dir=.
8374    for ac_exec_ext in '' $ac_executable_extensions; do
8375  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8376    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8377    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8378    break 2
8379  fi
8380done
8381  done
8382IFS=$as_save_IFS
8383
8384  ;;
8385esac
8386fi
8387MV=$ac_cv_path_MV
8388if test -n "$MV"; then
8389  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8390$as_echo "$MV" >&6; }
8391else
8392  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8393$as_echo "no" >&6; }
8394fi
8395
8396
8397  test -n "$MV" && break
8398done
8399
8400  else
8401    # The variable is set, but is it from the command line or the environment?
8402
8403    # Try to remove the string !MV! from our list.
8404    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/}
8405    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8406      # If it failed, the variable was not from the command line. Ignore it,
8407      # but warn the user (except for BASH, which is always set by the calling BASH).
8408      if test "xMV" != xBASH; then
8409        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5
8410$as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;}
8411      fi
8412      # Try to locate tool using the code snippet
8413      for ac_prog in mv
8414do
8415  # Extract the first word of "$ac_prog", so it can be a program name with args.
8416set dummy $ac_prog; ac_word=$2
8417{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8418$as_echo_n "checking for $ac_word... " >&6; }
8419if ${ac_cv_path_MV+:} false; then :
8420  $as_echo_n "(cached) " >&6
8421else
8422  case $MV in
8423  [\\/]* | ?:[\\/]*)
8424  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8425  ;;
8426  *)
8427  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8428for as_dir in $PATH
8429do
8430  IFS=$as_save_IFS
8431  test -z "$as_dir" && as_dir=.
8432    for ac_exec_ext in '' $ac_executable_extensions; do
8433  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8434    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8435    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8436    break 2
8437  fi
8438done
8439  done
8440IFS=$as_save_IFS
8441
8442  ;;
8443esac
8444fi
8445MV=$ac_cv_path_MV
8446if test -n "$MV"; then
8447  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8448$as_echo "$MV" >&6; }
8449else
8450  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8451$as_echo "no" >&6; }
8452fi
8453
8454
8455  test -n "$MV" && break
8456done
8457
8458    else
8459      # If it succeeded, then it was overridden by the user. We will use it
8460      # for the tool.
8461
8462      # First remove it from the list of overridden variables, so we can test
8463      # for unknown variables in the end.
8464      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8465
8466      # Check if the provided tool contains a complete path.
8467      tool_specified="$MV"
8468      tool_basename="${tool_specified##*/}"
8469      if test "x$tool_basename" = "x$tool_specified"; then
8470        # A command without a complete path is provided, search $PATH.
8471        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5
8472$as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;}
8473        # Extract the first word of "$tool_basename", so it can be a program name with args.
8474set dummy $tool_basename; ac_word=$2
8475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8476$as_echo_n "checking for $ac_word... " >&6; }
8477if ${ac_cv_path_MV+:} false; then :
8478  $as_echo_n "(cached) " >&6
8479else
8480  case $MV in
8481  [\\/]* | ?:[\\/]*)
8482  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8483  ;;
8484  *)
8485  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8486for as_dir in $PATH
8487do
8488  IFS=$as_save_IFS
8489  test -z "$as_dir" && as_dir=.
8490    for ac_exec_ext in '' $ac_executable_extensions; do
8491  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8492    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8493    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8494    break 2
8495  fi
8496done
8497  done
8498IFS=$as_save_IFS
8499
8500  ;;
8501esac
8502fi
8503MV=$ac_cv_path_MV
8504if test -n "$MV"; then
8505  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8506$as_echo "$MV" >&6; }
8507else
8508  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8509$as_echo "no" >&6; }
8510fi
8511
8512
8513        if test "x$MV" = x; then
8514          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8515        fi
8516      else
8517        # Otherwise we believe it is a complete path. Use it as it is.
8518        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5
8519$as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;}
8520        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5
8521$as_echo_n "checking for MV... " >&6; }
8522        if test ! -x "$tool_specified"; then
8523          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8524$as_echo "not found" >&6; }
8525          as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5
8526        fi
8527        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8528$as_echo "$tool_specified" >&6; }
8529      fi
8530    fi
8531  fi
8532
8533
8534
8535  if test "x$MV" = x; then
8536    as_fn_error $? "Could not find required tool for MV" "$LINENO" 5
8537  fi
8538
8539
8540
8541
8542
8543  # Publish this variable in the help.
8544
8545
8546  if test "x$NAWK" = x; then
8547    # The variable is not set by user, try to locate tool using the code snippet
8548    for ac_prog in nawk gawk awk
8549do
8550  # Extract the first word of "$ac_prog", so it can be a program name with args.
8551set dummy $ac_prog; ac_word=$2
8552{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8553$as_echo_n "checking for $ac_word... " >&6; }
8554if ${ac_cv_path_NAWK+:} false; then :
8555  $as_echo_n "(cached) " >&6
8556else
8557  case $NAWK in
8558  [\\/]* | ?:[\\/]*)
8559  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8560  ;;
8561  *)
8562  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8563for as_dir in $PATH
8564do
8565  IFS=$as_save_IFS
8566  test -z "$as_dir" && as_dir=.
8567    for ac_exec_ext in '' $ac_executable_extensions; do
8568  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8569    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8570    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8571    break 2
8572  fi
8573done
8574  done
8575IFS=$as_save_IFS
8576
8577  ;;
8578esac
8579fi
8580NAWK=$ac_cv_path_NAWK
8581if test -n "$NAWK"; then
8582  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8583$as_echo "$NAWK" >&6; }
8584else
8585  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8586$as_echo "no" >&6; }
8587fi
8588
8589
8590  test -n "$NAWK" && break
8591done
8592
8593  else
8594    # The variable is set, but is it from the command line or the environment?
8595
8596    # Try to remove the string !NAWK! from our list.
8597    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/}
8598    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8599      # If it failed, the variable was not from the command line. Ignore it,
8600      # but warn the user (except for BASH, which is always set by the calling BASH).
8601      if test "xNAWK" != xBASH; then
8602        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5
8603$as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;}
8604      fi
8605      # Try to locate tool using the code snippet
8606      for ac_prog in nawk gawk awk
8607do
8608  # Extract the first word of "$ac_prog", so it can be a program name with args.
8609set dummy $ac_prog; ac_word=$2
8610{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8611$as_echo_n "checking for $ac_word... " >&6; }
8612if ${ac_cv_path_NAWK+:} false; then :
8613  $as_echo_n "(cached) " >&6
8614else
8615  case $NAWK in
8616  [\\/]* | ?:[\\/]*)
8617  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8618  ;;
8619  *)
8620  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8621for as_dir in $PATH
8622do
8623  IFS=$as_save_IFS
8624  test -z "$as_dir" && as_dir=.
8625    for ac_exec_ext in '' $ac_executable_extensions; do
8626  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8627    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8628    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8629    break 2
8630  fi
8631done
8632  done
8633IFS=$as_save_IFS
8634
8635  ;;
8636esac
8637fi
8638NAWK=$ac_cv_path_NAWK
8639if test -n "$NAWK"; then
8640  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8641$as_echo "$NAWK" >&6; }
8642else
8643  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8644$as_echo "no" >&6; }
8645fi
8646
8647
8648  test -n "$NAWK" && break
8649done
8650
8651    else
8652      # If it succeeded, then it was overridden by the user. We will use it
8653      # for the tool.
8654
8655      # First remove it from the list of overridden variables, so we can test
8656      # for unknown variables in the end.
8657      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8658
8659      # Check if the provided tool contains a complete path.
8660      tool_specified="$NAWK"
8661      tool_basename="${tool_specified##*/}"
8662      if test "x$tool_basename" = "x$tool_specified"; then
8663        # A command without a complete path is provided, search $PATH.
8664        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5
8665$as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;}
8666        # Extract the first word of "$tool_basename", so it can be a program name with args.
8667set dummy $tool_basename; ac_word=$2
8668{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8669$as_echo_n "checking for $ac_word... " >&6; }
8670if ${ac_cv_path_NAWK+:} false; then :
8671  $as_echo_n "(cached) " >&6
8672else
8673  case $NAWK in
8674  [\\/]* | ?:[\\/]*)
8675  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8676  ;;
8677  *)
8678  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8679for as_dir in $PATH
8680do
8681  IFS=$as_save_IFS
8682  test -z "$as_dir" && as_dir=.
8683    for ac_exec_ext in '' $ac_executable_extensions; do
8684  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8685    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8686    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8687    break 2
8688  fi
8689done
8690  done
8691IFS=$as_save_IFS
8692
8693  ;;
8694esac
8695fi
8696NAWK=$ac_cv_path_NAWK
8697if test -n "$NAWK"; then
8698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8699$as_echo "$NAWK" >&6; }
8700else
8701  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8702$as_echo "no" >&6; }
8703fi
8704
8705
8706        if test "x$NAWK" = x; then
8707          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8708        fi
8709      else
8710        # Otherwise we believe it is a complete path. Use it as it is.
8711        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5
8712$as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;}
8713        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5
8714$as_echo_n "checking for NAWK... " >&6; }
8715        if test ! -x "$tool_specified"; then
8716          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8717$as_echo "not found" >&6; }
8718          as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5
8719        fi
8720        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8721$as_echo "$tool_specified" >&6; }
8722      fi
8723    fi
8724  fi
8725
8726
8727
8728  if test "x$NAWK" = x; then
8729    as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5
8730  fi
8731
8732
8733
8734
8735
8736  # Publish this variable in the help.
8737
8738
8739  if test "x$PRINTF" = x; then
8740    # The variable is not set by user, try to locate tool using the code snippet
8741    for ac_prog in printf
8742do
8743  # Extract the first word of "$ac_prog", so it can be a program name with args.
8744set dummy $ac_prog; ac_word=$2
8745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8746$as_echo_n "checking for $ac_word... " >&6; }
8747if ${ac_cv_path_PRINTF+:} false; then :
8748  $as_echo_n "(cached) " >&6
8749else
8750  case $PRINTF in
8751  [\\/]* | ?:[\\/]*)
8752  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8753  ;;
8754  *)
8755  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8756for as_dir in $PATH
8757do
8758  IFS=$as_save_IFS
8759  test -z "$as_dir" && as_dir=.
8760    for ac_exec_ext in '' $ac_executable_extensions; do
8761  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8762    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8763    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8764    break 2
8765  fi
8766done
8767  done
8768IFS=$as_save_IFS
8769
8770  ;;
8771esac
8772fi
8773PRINTF=$ac_cv_path_PRINTF
8774if test -n "$PRINTF"; then
8775  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8776$as_echo "$PRINTF" >&6; }
8777else
8778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8779$as_echo "no" >&6; }
8780fi
8781
8782
8783  test -n "$PRINTF" && break
8784done
8785
8786  else
8787    # The variable is set, but is it from the command line or the environment?
8788
8789    # Try to remove the string !PRINTF! from our list.
8790    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/}
8791    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8792      # If it failed, the variable was not from the command line. Ignore it,
8793      # but warn the user (except for BASH, which is always set by the calling BASH).
8794      if test "xPRINTF" != xBASH; then
8795        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5
8796$as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;}
8797      fi
8798      # Try to locate tool using the code snippet
8799      for ac_prog in printf
8800do
8801  # Extract the first word of "$ac_prog", so it can be a program name with args.
8802set dummy $ac_prog; ac_word=$2
8803{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8804$as_echo_n "checking for $ac_word... " >&6; }
8805if ${ac_cv_path_PRINTF+:} false; then :
8806  $as_echo_n "(cached) " >&6
8807else
8808  case $PRINTF in
8809  [\\/]* | ?:[\\/]*)
8810  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8811  ;;
8812  *)
8813  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8814for as_dir in $PATH
8815do
8816  IFS=$as_save_IFS
8817  test -z "$as_dir" && as_dir=.
8818    for ac_exec_ext in '' $ac_executable_extensions; do
8819  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8820    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8821    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8822    break 2
8823  fi
8824done
8825  done
8826IFS=$as_save_IFS
8827
8828  ;;
8829esac
8830fi
8831PRINTF=$ac_cv_path_PRINTF
8832if test -n "$PRINTF"; then
8833  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8834$as_echo "$PRINTF" >&6; }
8835else
8836  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8837$as_echo "no" >&6; }
8838fi
8839
8840
8841  test -n "$PRINTF" && break
8842done
8843
8844    else
8845      # If it succeeded, then it was overridden by the user. We will use it
8846      # for the tool.
8847
8848      # First remove it from the list of overridden variables, so we can test
8849      # for unknown variables in the end.
8850      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8851
8852      # Check if the provided tool contains a complete path.
8853      tool_specified="$PRINTF"
8854      tool_basename="${tool_specified##*/}"
8855      if test "x$tool_basename" = "x$tool_specified"; then
8856        # A command without a complete path is provided, search $PATH.
8857        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5
8858$as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;}
8859        # Extract the first word of "$tool_basename", so it can be a program name with args.
8860set dummy $tool_basename; ac_word=$2
8861{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8862$as_echo_n "checking for $ac_word... " >&6; }
8863if ${ac_cv_path_PRINTF+:} false; then :
8864  $as_echo_n "(cached) " >&6
8865else
8866  case $PRINTF in
8867  [\\/]* | ?:[\\/]*)
8868  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8869  ;;
8870  *)
8871  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8872for as_dir in $PATH
8873do
8874  IFS=$as_save_IFS
8875  test -z "$as_dir" && as_dir=.
8876    for ac_exec_ext in '' $ac_executable_extensions; do
8877  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8878    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8879    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8880    break 2
8881  fi
8882done
8883  done
8884IFS=$as_save_IFS
8885
8886  ;;
8887esac
8888fi
8889PRINTF=$ac_cv_path_PRINTF
8890if test -n "$PRINTF"; then
8891  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8892$as_echo "$PRINTF" >&6; }
8893else
8894  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8895$as_echo "no" >&6; }
8896fi
8897
8898
8899        if test "x$PRINTF" = x; then
8900          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8901        fi
8902      else
8903        # Otherwise we believe it is a complete path. Use it as it is.
8904        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5
8905$as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;}
8906        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5
8907$as_echo_n "checking for PRINTF... " >&6; }
8908        if test ! -x "$tool_specified"; then
8909          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8910$as_echo "not found" >&6; }
8911          as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5
8912        fi
8913        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8914$as_echo "$tool_specified" >&6; }
8915      fi
8916    fi
8917  fi
8918
8919
8920
8921  if test "x$PRINTF" = x; then
8922    as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5
8923  fi
8924
8925
8926
8927
8928
8929  # Publish this variable in the help.
8930
8931
8932  if test "x$RM" = x; then
8933    # The variable is not set by user, try to locate tool using the code snippet
8934    for ac_prog in rm
8935do
8936  # Extract the first word of "$ac_prog", so it can be a program name with args.
8937set dummy $ac_prog; ac_word=$2
8938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8939$as_echo_n "checking for $ac_word... " >&6; }
8940if ${ac_cv_path_RM+:} false; then :
8941  $as_echo_n "(cached) " >&6
8942else
8943  case $RM in
8944  [\\/]* | ?:[\\/]*)
8945  ac_cv_path_RM="$RM" # Let the user override the test with a path.
8946  ;;
8947  *)
8948  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8949for as_dir in $PATH
8950do
8951  IFS=$as_save_IFS
8952  test -z "$as_dir" && as_dir=.
8953    for ac_exec_ext in '' $ac_executable_extensions; do
8954  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8955    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8956    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8957    break 2
8958  fi
8959done
8960  done
8961IFS=$as_save_IFS
8962
8963  ;;
8964esac
8965fi
8966RM=$ac_cv_path_RM
8967if test -n "$RM"; then
8968  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8969$as_echo "$RM" >&6; }
8970else
8971  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8972$as_echo "no" >&6; }
8973fi
8974
8975
8976  test -n "$RM" && break
8977done
8978
8979  else
8980    # The variable is set, but is it from the command line or the environment?
8981
8982    # Try to remove the string !RM! from our list.
8983    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/}
8984    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8985      # If it failed, the variable was not from the command line. Ignore it,
8986      # but warn the user (except for BASH, which is always set by the calling BASH).
8987      if test "xRM" != xBASH; then
8988        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5
8989$as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;}
8990      fi
8991      # Try to locate tool using the code snippet
8992      for ac_prog in rm
8993do
8994  # Extract the first word of "$ac_prog", so it can be a program name with args.
8995set dummy $ac_prog; ac_word=$2
8996{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8997$as_echo_n "checking for $ac_word... " >&6; }
8998if ${ac_cv_path_RM+:} false; then :
8999  $as_echo_n "(cached) " >&6
9000else
9001  case $RM in
9002  [\\/]* | ?:[\\/]*)
9003  ac_cv_path_RM="$RM" # Let the user override the test with a path.
9004  ;;
9005  *)
9006  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9007for as_dir in $PATH
9008do
9009  IFS=$as_save_IFS
9010  test -z "$as_dir" && as_dir=.
9011    for ac_exec_ext in '' $ac_executable_extensions; do
9012  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9013    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
9014    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9015    break 2
9016  fi
9017done
9018  done
9019IFS=$as_save_IFS
9020
9021  ;;
9022esac
9023fi
9024RM=$ac_cv_path_RM
9025if test -n "$RM"; then
9026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9027$as_echo "$RM" >&6; }
9028else
9029  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9030$as_echo "no" >&6; }
9031fi
9032
9033
9034  test -n "$RM" && break
9035done
9036
9037    else
9038      # If it succeeded, then it was overridden by the user. We will use it
9039      # for the tool.
9040
9041      # First remove it from the list of overridden variables, so we can test
9042      # for unknown variables in the end.
9043      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9044
9045      # Check if the provided tool contains a complete path.
9046      tool_specified="$RM"
9047      tool_basename="${tool_specified##*/}"
9048      if test "x$tool_basename" = "x$tool_specified"; then
9049        # A command without a complete path is provided, search $PATH.
9050        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5
9051$as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;}
9052        # Extract the first word of "$tool_basename", so it can be a program name with args.
9053set dummy $tool_basename; ac_word=$2
9054{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9055$as_echo_n "checking for $ac_word... " >&6; }
9056if ${ac_cv_path_RM+:} false; then :
9057  $as_echo_n "(cached) " >&6
9058else
9059  case $RM in
9060  [\\/]* | ?:[\\/]*)
9061  ac_cv_path_RM="$RM" # Let the user override the test with a path.
9062  ;;
9063  *)
9064  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9065for as_dir in $PATH
9066do
9067  IFS=$as_save_IFS
9068  test -z "$as_dir" && as_dir=.
9069    for ac_exec_ext in '' $ac_executable_extensions; do
9070  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9071    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
9072    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9073    break 2
9074  fi
9075done
9076  done
9077IFS=$as_save_IFS
9078
9079  ;;
9080esac
9081fi
9082RM=$ac_cv_path_RM
9083if test -n "$RM"; then
9084  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9085$as_echo "$RM" >&6; }
9086else
9087  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9088$as_echo "no" >&6; }
9089fi
9090
9091
9092        if test "x$RM" = x; then
9093          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9094        fi
9095      else
9096        # Otherwise we believe it is a complete path. Use it as it is.
9097        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5
9098$as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;}
9099        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5
9100$as_echo_n "checking for RM... " >&6; }
9101        if test ! -x "$tool_specified"; then
9102          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9103$as_echo "not found" >&6; }
9104          as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5
9105        fi
9106        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9107$as_echo "$tool_specified" >&6; }
9108      fi
9109    fi
9110  fi
9111
9112
9113
9114  if test "x$RM" = x; then
9115    as_fn_error $? "Could not find required tool for RM" "$LINENO" 5
9116  fi
9117
9118
9119
9120
9121
9122  # Publish this variable in the help.
9123
9124
9125  if test "x$SH" = x; then
9126    # The variable is not set by user, try to locate tool using the code snippet
9127    for ac_prog in sh
9128do
9129  # Extract the first word of "$ac_prog", so it can be a program name with args.
9130set dummy $ac_prog; ac_word=$2
9131{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9132$as_echo_n "checking for $ac_word... " >&6; }
9133if ${ac_cv_path_SH+:} false; then :
9134  $as_echo_n "(cached) " >&6
9135else
9136  case $SH in
9137  [\\/]* | ?:[\\/]*)
9138  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9139  ;;
9140  *)
9141  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9142for as_dir in $PATH
9143do
9144  IFS=$as_save_IFS
9145  test -z "$as_dir" && as_dir=.
9146    for ac_exec_ext in '' $ac_executable_extensions; do
9147  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9148    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9149    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9150    break 2
9151  fi
9152done
9153  done
9154IFS=$as_save_IFS
9155
9156  ;;
9157esac
9158fi
9159SH=$ac_cv_path_SH
9160if test -n "$SH"; then
9161  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9162$as_echo "$SH" >&6; }
9163else
9164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9165$as_echo "no" >&6; }
9166fi
9167
9168
9169  test -n "$SH" && break
9170done
9171
9172  else
9173    # The variable is set, but is it from the command line or the environment?
9174
9175    # Try to remove the string !SH! from our list.
9176    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/}
9177    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9178      # If it failed, the variable was not from the command line. Ignore it,
9179      # but warn the user (except for BASH, which is always set by the calling BASH).
9180      if test "xSH" != xBASH; then
9181        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5
9182$as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;}
9183      fi
9184      # Try to locate tool using the code snippet
9185      for ac_prog in sh
9186do
9187  # Extract the first word of "$ac_prog", so it can be a program name with args.
9188set dummy $ac_prog; ac_word=$2
9189{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9190$as_echo_n "checking for $ac_word... " >&6; }
9191if ${ac_cv_path_SH+:} false; then :
9192  $as_echo_n "(cached) " >&6
9193else
9194  case $SH in
9195  [\\/]* | ?:[\\/]*)
9196  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9197  ;;
9198  *)
9199  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9200for as_dir in $PATH
9201do
9202  IFS=$as_save_IFS
9203  test -z "$as_dir" && as_dir=.
9204    for ac_exec_ext in '' $ac_executable_extensions; do
9205  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9206    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9207    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9208    break 2
9209  fi
9210done
9211  done
9212IFS=$as_save_IFS
9213
9214  ;;
9215esac
9216fi
9217SH=$ac_cv_path_SH
9218if test -n "$SH"; then
9219  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9220$as_echo "$SH" >&6; }
9221else
9222  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9223$as_echo "no" >&6; }
9224fi
9225
9226
9227  test -n "$SH" && break
9228done
9229
9230    else
9231      # If it succeeded, then it was overridden by the user. We will use it
9232      # for the tool.
9233
9234      # First remove it from the list of overridden variables, so we can test
9235      # for unknown variables in the end.
9236      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9237
9238      # Check if the provided tool contains a complete path.
9239      tool_specified="$SH"
9240      tool_basename="${tool_specified##*/}"
9241      if test "x$tool_basename" = "x$tool_specified"; then
9242        # A command without a complete path is provided, search $PATH.
9243        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5
9244$as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;}
9245        # Extract the first word of "$tool_basename", so it can be a program name with args.
9246set dummy $tool_basename; ac_word=$2
9247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9248$as_echo_n "checking for $ac_word... " >&6; }
9249if ${ac_cv_path_SH+:} false; then :
9250  $as_echo_n "(cached) " >&6
9251else
9252  case $SH in
9253  [\\/]* | ?:[\\/]*)
9254  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9255  ;;
9256  *)
9257  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9258for as_dir in $PATH
9259do
9260  IFS=$as_save_IFS
9261  test -z "$as_dir" && as_dir=.
9262    for ac_exec_ext in '' $ac_executable_extensions; do
9263  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9264    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9265    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9266    break 2
9267  fi
9268done
9269  done
9270IFS=$as_save_IFS
9271
9272  ;;
9273esac
9274fi
9275SH=$ac_cv_path_SH
9276if test -n "$SH"; then
9277  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9278$as_echo "$SH" >&6; }
9279else
9280  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9281$as_echo "no" >&6; }
9282fi
9283
9284
9285        if test "x$SH" = x; then
9286          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9287        fi
9288      else
9289        # Otherwise we believe it is a complete path. Use it as it is.
9290        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5
9291$as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;}
9292        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5
9293$as_echo_n "checking for SH... " >&6; }
9294        if test ! -x "$tool_specified"; then
9295          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9296$as_echo "not found" >&6; }
9297          as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5
9298        fi
9299        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9300$as_echo "$tool_specified" >&6; }
9301      fi
9302    fi
9303  fi
9304
9305
9306
9307  if test "x$SH" = x; then
9308    as_fn_error $? "Could not find required tool for SH" "$LINENO" 5
9309  fi
9310
9311
9312
9313
9314
9315  # Publish this variable in the help.
9316
9317
9318  if test "x$SORT" = x; then
9319    # The variable is not set by user, try to locate tool using the code snippet
9320    for ac_prog in sort
9321do
9322  # Extract the first word of "$ac_prog", so it can be a program name with args.
9323set dummy $ac_prog; ac_word=$2
9324{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9325$as_echo_n "checking for $ac_word... " >&6; }
9326if ${ac_cv_path_SORT+:} false; then :
9327  $as_echo_n "(cached) " >&6
9328else
9329  case $SORT in
9330  [\\/]* | ?:[\\/]*)
9331  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9332  ;;
9333  *)
9334  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9335for as_dir in $PATH
9336do
9337  IFS=$as_save_IFS
9338  test -z "$as_dir" && as_dir=.
9339    for ac_exec_ext in '' $ac_executable_extensions; do
9340  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9341    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9342    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9343    break 2
9344  fi
9345done
9346  done
9347IFS=$as_save_IFS
9348
9349  ;;
9350esac
9351fi
9352SORT=$ac_cv_path_SORT
9353if test -n "$SORT"; then
9354  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9355$as_echo "$SORT" >&6; }
9356else
9357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9358$as_echo "no" >&6; }
9359fi
9360
9361
9362  test -n "$SORT" && break
9363done
9364
9365  else
9366    # The variable is set, but is it from the command line or the environment?
9367
9368    # Try to remove the string !SORT! from our list.
9369    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/}
9370    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9371      # If it failed, the variable was not from the command line. Ignore it,
9372      # but warn the user (except for BASH, which is always set by the calling BASH).
9373      if test "xSORT" != xBASH; then
9374        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5
9375$as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;}
9376      fi
9377      # Try to locate tool using the code snippet
9378      for ac_prog in sort
9379do
9380  # Extract the first word of "$ac_prog", so it can be a program name with args.
9381set dummy $ac_prog; ac_word=$2
9382{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9383$as_echo_n "checking for $ac_word... " >&6; }
9384if ${ac_cv_path_SORT+:} false; then :
9385  $as_echo_n "(cached) " >&6
9386else
9387  case $SORT in
9388  [\\/]* | ?:[\\/]*)
9389  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9390  ;;
9391  *)
9392  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9393for as_dir in $PATH
9394do
9395  IFS=$as_save_IFS
9396  test -z "$as_dir" && as_dir=.
9397    for ac_exec_ext in '' $ac_executable_extensions; do
9398  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9399    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9400    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9401    break 2
9402  fi
9403done
9404  done
9405IFS=$as_save_IFS
9406
9407  ;;
9408esac
9409fi
9410SORT=$ac_cv_path_SORT
9411if test -n "$SORT"; then
9412  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9413$as_echo "$SORT" >&6; }
9414else
9415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9416$as_echo "no" >&6; }
9417fi
9418
9419
9420  test -n "$SORT" && break
9421done
9422
9423    else
9424      # If it succeeded, then it was overridden by the user. We will use it
9425      # for the tool.
9426
9427      # First remove it from the list of overridden variables, so we can test
9428      # for unknown variables in the end.
9429      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9430
9431      # Check if the provided tool contains a complete path.
9432      tool_specified="$SORT"
9433      tool_basename="${tool_specified##*/}"
9434      if test "x$tool_basename" = "x$tool_specified"; then
9435        # A command without a complete path is provided, search $PATH.
9436        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5
9437$as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;}
9438        # Extract the first word of "$tool_basename", so it can be a program name with args.
9439set dummy $tool_basename; ac_word=$2
9440{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9441$as_echo_n "checking for $ac_word... " >&6; }
9442if ${ac_cv_path_SORT+:} false; then :
9443  $as_echo_n "(cached) " >&6
9444else
9445  case $SORT in
9446  [\\/]* | ?:[\\/]*)
9447  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9448  ;;
9449  *)
9450  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9451for as_dir in $PATH
9452do
9453  IFS=$as_save_IFS
9454  test -z "$as_dir" && as_dir=.
9455    for ac_exec_ext in '' $ac_executable_extensions; do
9456  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9457    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9458    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9459    break 2
9460  fi
9461done
9462  done
9463IFS=$as_save_IFS
9464
9465  ;;
9466esac
9467fi
9468SORT=$ac_cv_path_SORT
9469if test -n "$SORT"; then
9470  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9471$as_echo "$SORT" >&6; }
9472else
9473  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9474$as_echo "no" >&6; }
9475fi
9476
9477
9478        if test "x$SORT" = x; then
9479          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9480        fi
9481      else
9482        # Otherwise we believe it is a complete path. Use it as it is.
9483        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5
9484$as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;}
9485        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5
9486$as_echo_n "checking for SORT... " >&6; }
9487        if test ! -x "$tool_specified"; then
9488          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9489$as_echo "not found" >&6; }
9490          as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5
9491        fi
9492        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9493$as_echo "$tool_specified" >&6; }
9494      fi
9495    fi
9496  fi
9497
9498
9499
9500  if test "x$SORT" = x; then
9501    as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5
9502  fi
9503
9504
9505
9506
9507
9508  # Publish this variable in the help.
9509
9510
9511  if test "x$TAIL" = x; then
9512    # The variable is not set by user, try to locate tool using the code snippet
9513    for ac_prog in tail
9514do
9515  # Extract the first word of "$ac_prog", so it can be a program name with args.
9516set dummy $ac_prog; ac_word=$2
9517{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9518$as_echo_n "checking for $ac_word... " >&6; }
9519if ${ac_cv_path_TAIL+:} false; then :
9520  $as_echo_n "(cached) " >&6
9521else
9522  case $TAIL in
9523  [\\/]* | ?:[\\/]*)
9524  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9525  ;;
9526  *)
9527  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9528for as_dir in $PATH
9529do
9530  IFS=$as_save_IFS
9531  test -z "$as_dir" && as_dir=.
9532    for ac_exec_ext in '' $ac_executable_extensions; do
9533  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9534    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9535    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9536    break 2
9537  fi
9538done
9539  done
9540IFS=$as_save_IFS
9541
9542  ;;
9543esac
9544fi
9545TAIL=$ac_cv_path_TAIL
9546if test -n "$TAIL"; then
9547  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9548$as_echo "$TAIL" >&6; }
9549else
9550  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9551$as_echo "no" >&6; }
9552fi
9553
9554
9555  test -n "$TAIL" && break
9556done
9557
9558  else
9559    # The variable is set, but is it from the command line or the environment?
9560
9561    # Try to remove the string !TAIL! from our list.
9562    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/}
9563    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9564      # If it failed, the variable was not from the command line. Ignore it,
9565      # but warn the user (except for BASH, which is always set by the calling BASH).
9566      if test "xTAIL" != xBASH; then
9567        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5
9568$as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;}
9569      fi
9570      # Try to locate tool using the code snippet
9571      for ac_prog in tail
9572do
9573  # Extract the first word of "$ac_prog", so it can be a program name with args.
9574set dummy $ac_prog; ac_word=$2
9575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9576$as_echo_n "checking for $ac_word... " >&6; }
9577if ${ac_cv_path_TAIL+:} false; then :
9578  $as_echo_n "(cached) " >&6
9579else
9580  case $TAIL in
9581  [\\/]* | ?:[\\/]*)
9582  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9583  ;;
9584  *)
9585  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9586for as_dir in $PATH
9587do
9588  IFS=$as_save_IFS
9589  test -z "$as_dir" && as_dir=.
9590    for ac_exec_ext in '' $ac_executable_extensions; do
9591  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9592    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9593    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9594    break 2
9595  fi
9596done
9597  done
9598IFS=$as_save_IFS
9599
9600  ;;
9601esac
9602fi
9603TAIL=$ac_cv_path_TAIL
9604if test -n "$TAIL"; then
9605  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9606$as_echo "$TAIL" >&6; }
9607else
9608  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9609$as_echo "no" >&6; }
9610fi
9611
9612
9613  test -n "$TAIL" && break
9614done
9615
9616    else
9617      # If it succeeded, then it was overridden by the user. We will use it
9618      # for the tool.
9619
9620      # First remove it from the list of overridden variables, so we can test
9621      # for unknown variables in the end.
9622      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9623
9624      # Check if the provided tool contains a complete path.
9625      tool_specified="$TAIL"
9626      tool_basename="${tool_specified##*/}"
9627      if test "x$tool_basename" = "x$tool_specified"; then
9628        # A command without a complete path is provided, search $PATH.
9629        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5
9630$as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;}
9631        # Extract the first word of "$tool_basename", so it can be a program name with args.
9632set dummy $tool_basename; ac_word=$2
9633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9634$as_echo_n "checking for $ac_word... " >&6; }
9635if ${ac_cv_path_TAIL+:} false; then :
9636  $as_echo_n "(cached) " >&6
9637else
9638  case $TAIL in
9639  [\\/]* | ?:[\\/]*)
9640  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9641  ;;
9642  *)
9643  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9644for as_dir in $PATH
9645do
9646  IFS=$as_save_IFS
9647  test -z "$as_dir" && as_dir=.
9648    for ac_exec_ext in '' $ac_executable_extensions; do
9649  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9650    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9651    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9652    break 2
9653  fi
9654done
9655  done
9656IFS=$as_save_IFS
9657
9658  ;;
9659esac
9660fi
9661TAIL=$ac_cv_path_TAIL
9662if test -n "$TAIL"; then
9663  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9664$as_echo "$TAIL" >&6; }
9665else
9666  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9667$as_echo "no" >&6; }
9668fi
9669
9670
9671        if test "x$TAIL" = x; then
9672          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9673        fi
9674      else
9675        # Otherwise we believe it is a complete path. Use it as it is.
9676        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5
9677$as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;}
9678        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5
9679$as_echo_n "checking for TAIL... " >&6; }
9680        if test ! -x "$tool_specified"; then
9681          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9682$as_echo "not found" >&6; }
9683          as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5
9684        fi
9685        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9686$as_echo "$tool_specified" >&6; }
9687      fi
9688    fi
9689  fi
9690
9691
9692
9693  if test "x$TAIL" = x; then
9694    as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5
9695  fi
9696
9697
9698
9699
9700
9701  # Publish this variable in the help.
9702
9703
9704  if test "x$TAR" = x; then
9705    # The variable is not set by user, try to locate tool using the code snippet
9706    for ac_prog in tar
9707do
9708  # Extract the first word of "$ac_prog", so it can be a program name with args.
9709set dummy $ac_prog; ac_word=$2
9710{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9711$as_echo_n "checking for $ac_word... " >&6; }
9712if ${ac_cv_path_TAR+:} false; then :
9713  $as_echo_n "(cached) " >&6
9714else
9715  case $TAR in
9716  [\\/]* | ?:[\\/]*)
9717  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9718  ;;
9719  *)
9720  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9721for as_dir in $PATH
9722do
9723  IFS=$as_save_IFS
9724  test -z "$as_dir" && as_dir=.
9725    for ac_exec_ext in '' $ac_executable_extensions; do
9726  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9727    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9728    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9729    break 2
9730  fi
9731done
9732  done
9733IFS=$as_save_IFS
9734
9735  ;;
9736esac
9737fi
9738TAR=$ac_cv_path_TAR
9739if test -n "$TAR"; then
9740  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9741$as_echo "$TAR" >&6; }
9742else
9743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9744$as_echo "no" >&6; }
9745fi
9746
9747
9748  test -n "$TAR" && break
9749done
9750
9751  else
9752    # The variable is set, but is it from the command line or the environment?
9753
9754    # Try to remove the string !TAR! from our list.
9755    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/}
9756    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9757      # If it failed, the variable was not from the command line. Ignore it,
9758      # but warn the user (except for BASH, which is always set by the calling BASH).
9759      if test "xTAR" != xBASH; then
9760        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5
9761$as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;}
9762      fi
9763      # Try to locate tool using the code snippet
9764      for ac_prog in tar
9765do
9766  # Extract the first word of "$ac_prog", so it can be a program name with args.
9767set dummy $ac_prog; ac_word=$2
9768{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9769$as_echo_n "checking for $ac_word... " >&6; }
9770if ${ac_cv_path_TAR+:} false; then :
9771  $as_echo_n "(cached) " >&6
9772else
9773  case $TAR in
9774  [\\/]* | ?:[\\/]*)
9775  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9776  ;;
9777  *)
9778  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9779for as_dir in $PATH
9780do
9781  IFS=$as_save_IFS
9782  test -z "$as_dir" && as_dir=.
9783    for ac_exec_ext in '' $ac_executable_extensions; do
9784  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9785    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9786    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9787    break 2
9788  fi
9789done
9790  done
9791IFS=$as_save_IFS
9792
9793  ;;
9794esac
9795fi
9796TAR=$ac_cv_path_TAR
9797if test -n "$TAR"; then
9798  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9799$as_echo "$TAR" >&6; }
9800else
9801  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9802$as_echo "no" >&6; }
9803fi
9804
9805
9806  test -n "$TAR" && break
9807done
9808
9809    else
9810      # If it succeeded, then it was overridden by the user. We will use it
9811      # for the tool.
9812
9813      # First remove it from the list of overridden variables, so we can test
9814      # for unknown variables in the end.
9815      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9816
9817      # Check if the provided tool contains a complete path.
9818      tool_specified="$TAR"
9819      tool_basename="${tool_specified##*/}"
9820      if test "x$tool_basename" = "x$tool_specified"; then
9821        # A command without a complete path is provided, search $PATH.
9822        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5
9823$as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;}
9824        # Extract the first word of "$tool_basename", so it can be a program name with args.
9825set dummy $tool_basename; ac_word=$2
9826{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9827$as_echo_n "checking for $ac_word... " >&6; }
9828if ${ac_cv_path_TAR+:} false; then :
9829  $as_echo_n "(cached) " >&6
9830else
9831  case $TAR in
9832  [\\/]* | ?:[\\/]*)
9833  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9834  ;;
9835  *)
9836  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9837for as_dir in $PATH
9838do
9839  IFS=$as_save_IFS
9840  test -z "$as_dir" && as_dir=.
9841    for ac_exec_ext in '' $ac_executable_extensions; do
9842  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9843    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9844    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9845    break 2
9846  fi
9847done
9848  done
9849IFS=$as_save_IFS
9850
9851  ;;
9852esac
9853fi
9854TAR=$ac_cv_path_TAR
9855if test -n "$TAR"; then
9856  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9857$as_echo "$TAR" >&6; }
9858else
9859  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9860$as_echo "no" >&6; }
9861fi
9862
9863
9864        if test "x$TAR" = x; then
9865          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9866        fi
9867      else
9868        # Otherwise we believe it is a complete path. Use it as it is.
9869        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5
9870$as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;}
9871        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9872$as_echo_n "checking for TAR... " >&6; }
9873        if test ! -x "$tool_specified"; then
9874          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9875$as_echo "not found" >&6; }
9876          as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5
9877        fi
9878        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9879$as_echo "$tool_specified" >&6; }
9880      fi
9881    fi
9882  fi
9883
9884
9885
9886  if test "x$TAR" = x; then
9887    as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5
9888  fi
9889
9890
9891
9892
9893
9894  # Publish this variable in the help.
9895
9896
9897  if test "x$TEE" = x; then
9898    # The variable is not set by user, try to locate tool using the code snippet
9899    for ac_prog in tee
9900do
9901  # Extract the first word of "$ac_prog", so it can be a program name with args.
9902set dummy $ac_prog; ac_word=$2
9903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9904$as_echo_n "checking for $ac_word... " >&6; }
9905if ${ac_cv_path_TEE+:} false; then :
9906  $as_echo_n "(cached) " >&6
9907else
9908  case $TEE in
9909  [\\/]* | ?:[\\/]*)
9910  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9911  ;;
9912  *)
9913  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9914for as_dir in $PATH
9915do
9916  IFS=$as_save_IFS
9917  test -z "$as_dir" && as_dir=.
9918    for ac_exec_ext in '' $ac_executable_extensions; do
9919  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9920    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9921    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9922    break 2
9923  fi
9924done
9925  done
9926IFS=$as_save_IFS
9927
9928  ;;
9929esac
9930fi
9931TEE=$ac_cv_path_TEE
9932if test -n "$TEE"; then
9933  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9934$as_echo "$TEE" >&6; }
9935else
9936  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9937$as_echo "no" >&6; }
9938fi
9939
9940
9941  test -n "$TEE" && break
9942done
9943
9944  else
9945    # The variable is set, but is it from the command line or the environment?
9946
9947    # Try to remove the string !TEE! from our list.
9948    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/}
9949    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9950      # If it failed, the variable was not from the command line. Ignore it,
9951      # but warn the user (except for BASH, which is always set by the calling BASH).
9952      if test "xTEE" != xBASH; then
9953        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5
9954$as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;}
9955      fi
9956      # Try to locate tool using the code snippet
9957      for ac_prog in tee
9958do
9959  # Extract the first word of "$ac_prog", so it can be a program name with args.
9960set dummy $ac_prog; ac_word=$2
9961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9962$as_echo_n "checking for $ac_word... " >&6; }
9963if ${ac_cv_path_TEE+:} false; then :
9964  $as_echo_n "(cached) " >&6
9965else
9966  case $TEE in
9967  [\\/]* | ?:[\\/]*)
9968  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9969  ;;
9970  *)
9971  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9972for as_dir in $PATH
9973do
9974  IFS=$as_save_IFS
9975  test -z "$as_dir" && as_dir=.
9976    for ac_exec_ext in '' $ac_executable_extensions; do
9977  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9978    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9979    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9980    break 2
9981  fi
9982done
9983  done
9984IFS=$as_save_IFS
9985
9986  ;;
9987esac
9988fi
9989TEE=$ac_cv_path_TEE
9990if test -n "$TEE"; then
9991  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9992$as_echo "$TEE" >&6; }
9993else
9994  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9995$as_echo "no" >&6; }
9996fi
9997
9998
9999  test -n "$TEE" && break
10000done
10001
10002    else
10003      # If it succeeded, then it was overridden by the user. We will use it
10004      # for the tool.
10005
10006      # First remove it from the list of overridden variables, so we can test
10007      # for unknown variables in the end.
10008      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10009
10010      # Check if the provided tool contains a complete path.
10011      tool_specified="$TEE"
10012      tool_basename="${tool_specified##*/}"
10013      if test "x$tool_basename" = "x$tool_specified"; then
10014        # A command without a complete path is provided, search $PATH.
10015        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5
10016$as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;}
10017        # Extract the first word of "$tool_basename", so it can be a program name with args.
10018set dummy $tool_basename; ac_word=$2
10019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10020$as_echo_n "checking for $ac_word... " >&6; }
10021if ${ac_cv_path_TEE+:} false; then :
10022  $as_echo_n "(cached) " >&6
10023else
10024  case $TEE in
10025  [\\/]* | ?:[\\/]*)
10026  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
10027  ;;
10028  *)
10029  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10030for as_dir in $PATH
10031do
10032  IFS=$as_save_IFS
10033  test -z "$as_dir" && as_dir=.
10034    for ac_exec_ext in '' $ac_executable_extensions; do
10035  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10036    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
10037    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10038    break 2
10039  fi
10040done
10041  done
10042IFS=$as_save_IFS
10043
10044  ;;
10045esac
10046fi
10047TEE=$ac_cv_path_TEE
10048if test -n "$TEE"; then
10049  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
10050$as_echo "$TEE" >&6; }
10051else
10052  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10053$as_echo "no" >&6; }
10054fi
10055
10056
10057        if test "x$TEE" = x; then
10058          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10059        fi
10060      else
10061        # Otherwise we believe it is a complete path. Use it as it is.
10062        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5
10063$as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;}
10064        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5
10065$as_echo_n "checking for TEE... " >&6; }
10066        if test ! -x "$tool_specified"; then
10067          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10068$as_echo "not found" >&6; }
10069          as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5
10070        fi
10071        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10072$as_echo "$tool_specified" >&6; }
10073      fi
10074    fi
10075  fi
10076
10077
10078
10079  if test "x$TEE" = x; then
10080    as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5
10081  fi
10082
10083
10084
10085
10086
10087  # Publish this variable in the help.
10088
10089
10090  if test "x$TOUCH" = x; then
10091    # The variable is not set by user, try to locate tool using the code snippet
10092    for ac_prog in touch
10093do
10094  # Extract the first word of "$ac_prog", so it can be a program name with args.
10095set dummy $ac_prog; ac_word=$2
10096{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10097$as_echo_n "checking for $ac_word... " >&6; }
10098if ${ac_cv_path_TOUCH+:} false; then :
10099  $as_echo_n "(cached) " >&6
10100else
10101  case $TOUCH in
10102  [\\/]* | ?:[\\/]*)
10103  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10104  ;;
10105  *)
10106  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10107for as_dir in $PATH
10108do
10109  IFS=$as_save_IFS
10110  test -z "$as_dir" && as_dir=.
10111    for ac_exec_ext in '' $ac_executable_extensions; do
10112  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10113    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10114    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10115    break 2
10116  fi
10117done
10118  done
10119IFS=$as_save_IFS
10120
10121  ;;
10122esac
10123fi
10124TOUCH=$ac_cv_path_TOUCH
10125if test -n "$TOUCH"; then
10126  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10127$as_echo "$TOUCH" >&6; }
10128else
10129  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10130$as_echo "no" >&6; }
10131fi
10132
10133
10134  test -n "$TOUCH" && break
10135done
10136
10137  else
10138    # The variable is set, but is it from the command line or the environment?
10139
10140    # Try to remove the string !TOUCH! from our list.
10141    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/}
10142    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10143      # If it failed, the variable was not from the command line. Ignore it,
10144      # but warn the user (except for BASH, which is always set by the calling BASH).
10145      if test "xTOUCH" != xBASH; then
10146        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5
10147$as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;}
10148      fi
10149      # Try to locate tool using the code snippet
10150      for ac_prog in touch
10151do
10152  # Extract the first word of "$ac_prog", so it can be a program name with args.
10153set dummy $ac_prog; ac_word=$2
10154{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10155$as_echo_n "checking for $ac_word... " >&6; }
10156if ${ac_cv_path_TOUCH+:} false; then :
10157  $as_echo_n "(cached) " >&6
10158else
10159  case $TOUCH in
10160  [\\/]* | ?:[\\/]*)
10161  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10162  ;;
10163  *)
10164  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10165for as_dir in $PATH
10166do
10167  IFS=$as_save_IFS
10168  test -z "$as_dir" && as_dir=.
10169    for ac_exec_ext in '' $ac_executable_extensions; do
10170  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10171    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10172    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10173    break 2
10174  fi
10175done
10176  done
10177IFS=$as_save_IFS
10178
10179  ;;
10180esac
10181fi
10182TOUCH=$ac_cv_path_TOUCH
10183if test -n "$TOUCH"; then
10184  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10185$as_echo "$TOUCH" >&6; }
10186else
10187  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10188$as_echo "no" >&6; }
10189fi
10190
10191
10192  test -n "$TOUCH" && break
10193done
10194
10195    else
10196      # If it succeeded, then it was overridden by the user. We will use it
10197      # for the tool.
10198
10199      # First remove it from the list of overridden variables, so we can test
10200      # for unknown variables in the end.
10201      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10202
10203      # Check if the provided tool contains a complete path.
10204      tool_specified="$TOUCH"
10205      tool_basename="${tool_specified##*/}"
10206      if test "x$tool_basename" = "x$tool_specified"; then
10207        # A command without a complete path is provided, search $PATH.
10208        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5
10209$as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;}
10210        # Extract the first word of "$tool_basename", so it can be a program name with args.
10211set dummy $tool_basename; ac_word=$2
10212{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10213$as_echo_n "checking for $ac_word... " >&6; }
10214if ${ac_cv_path_TOUCH+:} false; then :
10215  $as_echo_n "(cached) " >&6
10216else
10217  case $TOUCH in
10218  [\\/]* | ?:[\\/]*)
10219  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10220  ;;
10221  *)
10222  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10223for as_dir in $PATH
10224do
10225  IFS=$as_save_IFS
10226  test -z "$as_dir" && as_dir=.
10227    for ac_exec_ext in '' $ac_executable_extensions; do
10228  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10229    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10230    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10231    break 2
10232  fi
10233done
10234  done
10235IFS=$as_save_IFS
10236
10237  ;;
10238esac
10239fi
10240TOUCH=$ac_cv_path_TOUCH
10241if test -n "$TOUCH"; then
10242  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10243$as_echo "$TOUCH" >&6; }
10244else
10245  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10246$as_echo "no" >&6; }
10247fi
10248
10249
10250        if test "x$TOUCH" = x; then
10251          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10252        fi
10253      else
10254        # Otherwise we believe it is a complete path. Use it as it is.
10255        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5
10256$as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;}
10257        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5
10258$as_echo_n "checking for TOUCH... " >&6; }
10259        if test ! -x "$tool_specified"; then
10260          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10261$as_echo "not found" >&6; }
10262          as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5
10263        fi
10264        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10265$as_echo "$tool_specified" >&6; }
10266      fi
10267    fi
10268  fi
10269
10270
10271
10272  if test "x$TOUCH" = x; then
10273    as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5
10274  fi
10275
10276
10277
10278
10279
10280  # Publish this variable in the help.
10281
10282
10283  if test "x$TR" = x; then
10284    # The variable is not set by user, try to locate tool using the code snippet
10285    for ac_prog in tr
10286do
10287  # Extract the first word of "$ac_prog", so it can be a program name with args.
10288set dummy $ac_prog; ac_word=$2
10289{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10290$as_echo_n "checking for $ac_word... " >&6; }
10291if ${ac_cv_path_TR+:} false; then :
10292  $as_echo_n "(cached) " >&6
10293else
10294  case $TR in
10295  [\\/]* | ?:[\\/]*)
10296  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10297  ;;
10298  *)
10299  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10300for as_dir in $PATH
10301do
10302  IFS=$as_save_IFS
10303  test -z "$as_dir" && as_dir=.
10304    for ac_exec_ext in '' $ac_executable_extensions; do
10305  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10306    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10307    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10308    break 2
10309  fi
10310done
10311  done
10312IFS=$as_save_IFS
10313
10314  ;;
10315esac
10316fi
10317TR=$ac_cv_path_TR
10318if test -n "$TR"; then
10319  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10320$as_echo "$TR" >&6; }
10321else
10322  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10323$as_echo "no" >&6; }
10324fi
10325
10326
10327  test -n "$TR" && break
10328done
10329
10330  else
10331    # The variable is set, but is it from the command line or the environment?
10332
10333    # Try to remove the string !TR! from our list.
10334    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/}
10335    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10336      # If it failed, the variable was not from the command line. Ignore it,
10337      # but warn the user (except for BASH, which is always set by the calling BASH).
10338      if test "xTR" != xBASH; then
10339        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5
10340$as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;}
10341      fi
10342      # Try to locate tool using the code snippet
10343      for ac_prog in tr
10344do
10345  # Extract the first word of "$ac_prog", so it can be a program name with args.
10346set dummy $ac_prog; ac_word=$2
10347{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10348$as_echo_n "checking for $ac_word... " >&6; }
10349if ${ac_cv_path_TR+:} false; then :
10350  $as_echo_n "(cached) " >&6
10351else
10352  case $TR in
10353  [\\/]* | ?:[\\/]*)
10354  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10355  ;;
10356  *)
10357  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10358for as_dir in $PATH
10359do
10360  IFS=$as_save_IFS
10361  test -z "$as_dir" && as_dir=.
10362    for ac_exec_ext in '' $ac_executable_extensions; do
10363  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10364    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10365    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10366    break 2
10367  fi
10368done
10369  done
10370IFS=$as_save_IFS
10371
10372  ;;
10373esac
10374fi
10375TR=$ac_cv_path_TR
10376if test -n "$TR"; then
10377  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10378$as_echo "$TR" >&6; }
10379else
10380  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10381$as_echo "no" >&6; }
10382fi
10383
10384
10385  test -n "$TR" && break
10386done
10387
10388    else
10389      # If it succeeded, then it was overridden by the user. We will use it
10390      # for the tool.
10391
10392      # First remove it from the list of overridden variables, so we can test
10393      # for unknown variables in the end.
10394      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10395
10396      # Check if the provided tool contains a complete path.
10397      tool_specified="$TR"
10398      tool_basename="${tool_specified##*/}"
10399      if test "x$tool_basename" = "x$tool_specified"; then
10400        # A command without a complete path is provided, search $PATH.
10401        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5
10402$as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;}
10403        # Extract the first word of "$tool_basename", so it can be a program name with args.
10404set dummy $tool_basename; ac_word=$2
10405{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10406$as_echo_n "checking for $ac_word... " >&6; }
10407if ${ac_cv_path_TR+:} false; then :
10408  $as_echo_n "(cached) " >&6
10409else
10410  case $TR in
10411  [\\/]* | ?:[\\/]*)
10412  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10413  ;;
10414  *)
10415  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10416for as_dir in $PATH
10417do
10418  IFS=$as_save_IFS
10419  test -z "$as_dir" && as_dir=.
10420    for ac_exec_ext in '' $ac_executable_extensions; do
10421  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10422    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10423    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10424    break 2
10425  fi
10426done
10427  done
10428IFS=$as_save_IFS
10429
10430  ;;
10431esac
10432fi
10433TR=$ac_cv_path_TR
10434if test -n "$TR"; then
10435  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10436$as_echo "$TR" >&6; }
10437else
10438  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10439$as_echo "no" >&6; }
10440fi
10441
10442
10443        if test "x$TR" = x; then
10444          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10445        fi
10446      else
10447        # Otherwise we believe it is a complete path. Use it as it is.
10448        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5
10449$as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;}
10450        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5
10451$as_echo_n "checking for TR... " >&6; }
10452        if test ! -x "$tool_specified"; then
10453          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10454$as_echo "not found" >&6; }
10455          as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5
10456        fi
10457        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10458$as_echo "$tool_specified" >&6; }
10459      fi
10460    fi
10461  fi
10462
10463
10464
10465  if test "x$TR" = x; then
10466    as_fn_error $? "Could not find required tool for TR" "$LINENO" 5
10467  fi
10468
10469
10470
10471
10472
10473  # Publish this variable in the help.
10474
10475
10476  if test "x$UNAME" = x; then
10477    # The variable is not set by user, try to locate tool using the code snippet
10478    for ac_prog in uname
10479do
10480  # Extract the first word of "$ac_prog", so it can be a program name with args.
10481set dummy $ac_prog; ac_word=$2
10482{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10483$as_echo_n "checking for $ac_word... " >&6; }
10484if ${ac_cv_path_UNAME+:} false; then :
10485  $as_echo_n "(cached) " >&6
10486else
10487  case $UNAME in
10488  [\\/]* | ?:[\\/]*)
10489  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10490  ;;
10491  *)
10492  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10493for as_dir in $PATH
10494do
10495  IFS=$as_save_IFS
10496  test -z "$as_dir" && as_dir=.
10497    for ac_exec_ext in '' $ac_executable_extensions; do
10498  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10499    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10500    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10501    break 2
10502  fi
10503done
10504  done
10505IFS=$as_save_IFS
10506
10507  ;;
10508esac
10509fi
10510UNAME=$ac_cv_path_UNAME
10511if test -n "$UNAME"; then
10512  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10513$as_echo "$UNAME" >&6; }
10514else
10515  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10516$as_echo "no" >&6; }
10517fi
10518
10519
10520  test -n "$UNAME" && break
10521done
10522
10523  else
10524    # The variable is set, but is it from the command line or the environment?
10525
10526    # Try to remove the string !UNAME! from our list.
10527    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/}
10528    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10529      # If it failed, the variable was not from the command line. Ignore it,
10530      # but warn the user (except for BASH, which is always set by the calling BASH).
10531      if test "xUNAME" != xBASH; then
10532        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5
10533$as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;}
10534      fi
10535      # Try to locate tool using the code snippet
10536      for ac_prog in uname
10537do
10538  # Extract the first word of "$ac_prog", so it can be a program name with args.
10539set dummy $ac_prog; ac_word=$2
10540{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10541$as_echo_n "checking for $ac_word... " >&6; }
10542if ${ac_cv_path_UNAME+:} false; then :
10543  $as_echo_n "(cached) " >&6
10544else
10545  case $UNAME in
10546  [\\/]* | ?:[\\/]*)
10547  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10548  ;;
10549  *)
10550  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10551for as_dir in $PATH
10552do
10553  IFS=$as_save_IFS
10554  test -z "$as_dir" && as_dir=.
10555    for ac_exec_ext in '' $ac_executable_extensions; do
10556  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10557    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10558    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10559    break 2
10560  fi
10561done
10562  done
10563IFS=$as_save_IFS
10564
10565  ;;
10566esac
10567fi
10568UNAME=$ac_cv_path_UNAME
10569if test -n "$UNAME"; then
10570  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10571$as_echo "$UNAME" >&6; }
10572else
10573  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10574$as_echo "no" >&6; }
10575fi
10576
10577
10578  test -n "$UNAME" && break
10579done
10580
10581    else
10582      # If it succeeded, then it was overridden by the user. We will use it
10583      # for the tool.
10584
10585      # First remove it from the list of overridden variables, so we can test
10586      # for unknown variables in the end.
10587      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10588
10589      # Check if the provided tool contains a complete path.
10590      tool_specified="$UNAME"
10591      tool_basename="${tool_specified##*/}"
10592      if test "x$tool_basename" = "x$tool_specified"; then
10593        # A command without a complete path is provided, search $PATH.
10594        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5
10595$as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;}
10596        # Extract the first word of "$tool_basename", so it can be a program name with args.
10597set dummy $tool_basename; ac_word=$2
10598{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10599$as_echo_n "checking for $ac_word... " >&6; }
10600if ${ac_cv_path_UNAME+:} false; then :
10601  $as_echo_n "(cached) " >&6
10602else
10603  case $UNAME in
10604  [\\/]* | ?:[\\/]*)
10605  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10606  ;;
10607  *)
10608  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10609for as_dir in $PATH
10610do
10611  IFS=$as_save_IFS
10612  test -z "$as_dir" && as_dir=.
10613    for ac_exec_ext in '' $ac_executable_extensions; do
10614  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10615    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10616    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10617    break 2
10618  fi
10619done
10620  done
10621IFS=$as_save_IFS
10622
10623  ;;
10624esac
10625fi
10626UNAME=$ac_cv_path_UNAME
10627if test -n "$UNAME"; then
10628  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10629$as_echo "$UNAME" >&6; }
10630else
10631  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10632$as_echo "no" >&6; }
10633fi
10634
10635
10636        if test "x$UNAME" = x; then
10637          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10638        fi
10639      else
10640        # Otherwise we believe it is a complete path. Use it as it is.
10641        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5
10642$as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;}
10643        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5
10644$as_echo_n "checking for UNAME... " >&6; }
10645        if test ! -x "$tool_specified"; then
10646          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10647$as_echo "not found" >&6; }
10648          as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
10649        fi
10650        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10651$as_echo "$tool_specified" >&6; }
10652      fi
10653    fi
10654  fi
10655
10656
10657
10658  if test "x$UNAME" = x; then
10659    as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5
10660  fi
10661
10662
10663
10664
10665
10666  # Publish this variable in the help.
10667
10668
10669  if test "x$UNIQ" = x; then
10670    # The variable is not set by user, try to locate tool using the code snippet
10671    for ac_prog in uniq
10672do
10673  # Extract the first word of "$ac_prog", so it can be a program name with args.
10674set dummy $ac_prog; ac_word=$2
10675{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10676$as_echo_n "checking for $ac_word... " >&6; }
10677if ${ac_cv_path_UNIQ+:} false; then :
10678  $as_echo_n "(cached) " >&6
10679else
10680  case $UNIQ in
10681  [\\/]* | ?:[\\/]*)
10682  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10683  ;;
10684  *)
10685  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10686for as_dir in $PATH
10687do
10688  IFS=$as_save_IFS
10689  test -z "$as_dir" && as_dir=.
10690    for ac_exec_ext in '' $ac_executable_extensions; do
10691  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10692    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10693    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10694    break 2
10695  fi
10696done
10697  done
10698IFS=$as_save_IFS
10699
10700  ;;
10701esac
10702fi
10703UNIQ=$ac_cv_path_UNIQ
10704if test -n "$UNIQ"; then
10705  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10706$as_echo "$UNIQ" >&6; }
10707else
10708  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10709$as_echo "no" >&6; }
10710fi
10711
10712
10713  test -n "$UNIQ" && break
10714done
10715
10716  else
10717    # The variable is set, but is it from the command line or the environment?
10718
10719    # Try to remove the string !UNIQ! from our list.
10720    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/}
10721    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10722      # If it failed, the variable was not from the command line. Ignore it,
10723      # but warn the user (except for BASH, which is always set by the calling BASH).
10724      if test "xUNIQ" != xBASH; then
10725        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5
10726$as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;}
10727      fi
10728      # Try to locate tool using the code snippet
10729      for ac_prog in uniq
10730do
10731  # Extract the first word of "$ac_prog", so it can be a program name with args.
10732set dummy $ac_prog; ac_word=$2
10733{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10734$as_echo_n "checking for $ac_word... " >&6; }
10735if ${ac_cv_path_UNIQ+:} false; then :
10736  $as_echo_n "(cached) " >&6
10737else
10738  case $UNIQ in
10739  [\\/]* | ?:[\\/]*)
10740  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10741  ;;
10742  *)
10743  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10744for as_dir in $PATH
10745do
10746  IFS=$as_save_IFS
10747  test -z "$as_dir" && as_dir=.
10748    for ac_exec_ext in '' $ac_executable_extensions; do
10749  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10750    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10751    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10752    break 2
10753  fi
10754done
10755  done
10756IFS=$as_save_IFS
10757
10758  ;;
10759esac
10760fi
10761UNIQ=$ac_cv_path_UNIQ
10762if test -n "$UNIQ"; then
10763  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10764$as_echo "$UNIQ" >&6; }
10765else
10766  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10767$as_echo "no" >&6; }
10768fi
10769
10770
10771  test -n "$UNIQ" && break
10772done
10773
10774    else
10775      # If it succeeded, then it was overridden by the user. We will use it
10776      # for the tool.
10777
10778      # First remove it from the list of overridden variables, so we can test
10779      # for unknown variables in the end.
10780      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10781
10782      # Check if the provided tool contains a complete path.
10783      tool_specified="$UNIQ"
10784      tool_basename="${tool_specified##*/}"
10785      if test "x$tool_basename" = "x$tool_specified"; then
10786        # A command without a complete path is provided, search $PATH.
10787        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5
10788$as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;}
10789        # Extract the first word of "$tool_basename", so it can be a program name with args.
10790set dummy $tool_basename; ac_word=$2
10791{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10792$as_echo_n "checking for $ac_word... " >&6; }
10793if ${ac_cv_path_UNIQ+:} false; then :
10794  $as_echo_n "(cached) " >&6
10795else
10796  case $UNIQ in
10797  [\\/]* | ?:[\\/]*)
10798  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10799  ;;
10800  *)
10801  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10802for as_dir in $PATH
10803do
10804  IFS=$as_save_IFS
10805  test -z "$as_dir" && as_dir=.
10806    for ac_exec_ext in '' $ac_executable_extensions; do
10807  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10808    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10809    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10810    break 2
10811  fi
10812done
10813  done
10814IFS=$as_save_IFS
10815
10816  ;;
10817esac
10818fi
10819UNIQ=$ac_cv_path_UNIQ
10820if test -n "$UNIQ"; then
10821  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10822$as_echo "$UNIQ" >&6; }
10823else
10824  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10825$as_echo "no" >&6; }
10826fi
10827
10828
10829        if test "x$UNIQ" = x; then
10830          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10831        fi
10832      else
10833        # Otherwise we believe it is a complete path. Use it as it is.
10834        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5
10835$as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;}
10836        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5
10837$as_echo_n "checking for UNIQ... " >&6; }
10838        if test ! -x "$tool_specified"; then
10839          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10840$as_echo "not found" >&6; }
10841          as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5
10842        fi
10843        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10844$as_echo "$tool_specified" >&6; }
10845      fi
10846    fi
10847  fi
10848
10849
10850
10851  if test "x$UNIQ" = x; then
10852    as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5
10853  fi
10854
10855
10856
10857
10858
10859  # Publish this variable in the help.
10860
10861
10862  if test "x$WC" = x; then
10863    # The variable is not set by user, try to locate tool using the code snippet
10864    for ac_prog in wc
10865do
10866  # Extract the first word of "$ac_prog", so it can be a program name with args.
10867set dummy $ac_prog; ac_word=$2
10868{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10869$as_echo_n "checking for $ac_word... " >&6; }
10870if ${ac_cv_path_WC+:} false; then :
10871  $as_echo_n "(cached) " >&6
10872else
10873  case $WC in
10874  [\\/]* | ?:[\\/]*)
10875  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10876  ;;
10877  *)
10878  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10879for as_dir in $PATH
10880do
10881  IFS=$as_save_IFS
10882  test -z "$as_dir" && as_dir=.
10883    for ac_exec_ext in '' $ac_executable_extensions; do
10884  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10885    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10886    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10887    break 2
10888  fi
10889done
10890  done
10891IFS=$as_save_IFS
10892
10893  ;;
10894esac
10895fi
10896WC=$ac_cv_path_WC
10897if test -n "$WC"; then
10898  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10899$as_echo "$WC" >&6; }
10900else
10901  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10902$as_echo "no" >&6; }
10903fi
10904
10905
10906  test -n "$WC" && break
10907done
10908
10909  else
10910    # The variable is set, but is it from the command line or the environment?
10911
10912    # Try to remove the string !WC! from our list.
10913    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/}
10914    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10915      # If it failed, the variable was not from the command line. Ignore it,
10916      # but warn the user (except for BASH, which is always set by the calling BASH).
10917      if test "xWC" != xBASH; then
10918        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5
10919$as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;}
10920      fi
10921      # Try to locate tool using the code snippet
10922      for ac_prog in wc
10923do
10924  # Extract the first word of "$ac_prog", so it can be a program name with args.
10925set dummy $ac_prog; ac_word=$2
10926{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10927$as_echo_n "checking for $ac_word... " >&6; }
10928if ${ac_cv_path_WC+:} false; then :
10929  $as_echo_n "(cached) " >&6
10930else
10931  case $WC in
10932  [\\/]* | ?:[\\/]*)
10933  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10934  ;;
10935  *)
10936  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10937for as_dir in $PATH
10938do
10939  IFS=$as_save_IFS
10940  test -z "$as_dir" && as_dir=.
10941    for ac_exec_ext in '' $ac_executable_extensions; do
10942  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10943    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10944    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10945    break 2
10946  fi
10947done
10948  done
10949IFS=$as_save_IFS
10950
10951  ;;
10952esac
10953fi
10954WC=$ac_cv_path_WC
10955if test -n "$WC"; then
10956  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10957$as_echo "$WC" >&6; }
10958else
10959  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10960$as_echo "no" >&6; }
10961fi
10962
10963
10964  test -n "$WC" && break
10965done
10966
10967    else
10968      # If it succeeded, then it was overridden by the user. We will use it
10969      # for the tool.
10970
10971      # First remove it from the list of overridden variables, so we can test
10972      # for unknown variables in the end.
10973      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10974
10975      # Check if the provided tool contains a complete path.
10976      tool_specified="$WC"
10977      tool_basename="${tool_specified##*/}"
10978      if test "x$tool_basename" = "x$tool_specified"; then
10979        # A command without a complete path is provided, search $PATH.
10980        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5
10981$as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;}
10982        # Extract the first word of "$tool_basename", so it can be a program name with args.
10983set dummy $tool_basename; ac_word=$2
10984{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10985$as_echo_n "checking for $ac_word... " >&6; }
10986if ${ac_cv_path_WC+:} false; then :
10987  $as_echo_n "(cached) " >&6
10988else
10989  case $WC in
10990  [\\/]* | ?:[\\/]*)
10991  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10992  ;;
10993  *)
10994  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10995for as_dir in $PATH
10996do
10997  IFS=$as_save_IFS
10998  test -z "$as_dir" && as_dir=.
10999    for ac_exec_ext in '' $ac_executable_extensions; do
11000  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11001    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
11002    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11003    break 2
11004  fi
11005done
11006  done
11007IFS=$as_save_IFS
11008
11009  ;;
11010esac
11011fi
11012WC=$ac_cv_path_WC
11013if test -n "$WC"; then
11014  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
11015$as_echo "$WC" >&6; }
11016else
11017  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11018$as_echo "no" >&6; }
11019fi
11020
11021
11022        if test "x$WC" = x; then
11023          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11024        fi
11025      else
11026        # Otherwise we believe it is a complete path. Use it as it is.
11027        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5
11028$as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;}
11029        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5
11030$as_echo_n "checking for WC... " >&6; }
11031        if test ! -x "$tool_specified"; then
11032          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11033$as_echo "not found" >&6; }
11034          as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5
11035        fi
11036        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11037$as_echo "$tool_specified" >&6; }
11038      fi
11039    fi
11040  fi
11041
11042
11043
11044  if test "x$WC" = x; then
11045    as_fn_error $? "Could not find required tool for WC" "$LINENO" 5
11046  fi
11047
11048
11049
11050
11051
11052  # Publish this variable in the help.
11053
11054
11055  if test "x$WHICH" = x; then
11056    # The variable is not set by user, try to locate tool using the code snippet
11057    for ac_prog in which
11058do
11059  # Extract the first word of "$ac_prog", so it can be a program name with args.
11060set dummy $ac_prog; ac_word=$2
11061{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11062$as_echo_n "checking for $ac_word... " >&6; }
11063if ${ac_cv_path_WHICH+:} false; then :
11064  $as_echo_n "(cached) " >&6
11065else
11066  case $WHICH in
11067  [\\/]* | ?:[\\/]*)
11068  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11069  ;;
11070  *)
11071  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11072for as_dir in $PATH
11073do
11074  IFS=$as_save_IFS
11075  test -z "$as_dir" && as_dir=.
11076    for ac_exec_ext in '' $ac_executable_extensions; do
11077  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11078    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11079    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11080    break 2
11081  fi
11082done
11083  done
11084IFS=$as_save_IFS
11085
11086  ;;
11087esac
11088fi
11089WHICH=$ac_cv_path_WHICH
11090if test -n "$WHICH"; then
11091  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11092$as_echo "$WHICH" >&6; }
11093else
11094  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11095$as_echo "no" >&6; }
11096fi
11097
11098
11099  test -n "$WHICH" && break
11100done
11101
11102  else
11103    # The variable is set, but is it from the command line or the environment?
11104
11105    # Try to remove the string !WHICH! from our list.
11106    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/}
11107    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11108      # If it failed, the variable was not from the command line. Ignore it,
11109      # but warn the user (except for BASH, which is always set by the calling BASH).
11110      if test "xWHICH" != xBASH; then
11111        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5
11112$as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;}
11113      fi
11114      # Try to locate tool using the code snippet
11115      for ac_prog in which
11116do
11117  # Extract the first word of "$ac_prog", so it can be a program name with args.
11118set dummy $ac_prog; ac_word=$2
11119{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11120$as_echo_n "checking for $ac_word... " >&6; }
11121if ${ac_cv_path_WHICH+:} false; then :
11122  $as_echo_n "(cached) " >&6
11123else
11124  case $WHICH in
11125  [\\/]* | ?:[\\/]*)
11126  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11127  ;;
11128  *)
11129  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11130for as_dir in $PATH
11131do
11132  IFS=$as_save_IFS
11133  test -z "$as_dir" && as_dir=.
11134    for ac_exec_ext in '' $ac_executable_extensions; do
11135  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11136    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11137    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11138    break 2
11139  fi
11140done
11141  done
11142IFS=$as_save_IFS
11143
11144  ;;
11145esac
11146fi
11147WHICH=$ac_cv_path_WHICH
11148if test -n "$WHICH"; then
11149  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11150$as_echo "$WHICH" >&6; }
11151else
11152  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11153$as_echo "no" >&6; }
11154fi
11155
11156
11157  test -n "$WHICH" && break
11158done
11159
11160    else
11161      # If it succeeded, then it was overridden by the user. We will use it
11162      # for the tool.
11163
11164      # First remove it from the list of overridden variables, so we can test
11165      # for unknown variables in the end.
11166      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11167
11168      # Check if the provided tool contains a complete path.
11169      tool_specified="$WHICH"
11170      tool_basename="${tool_specified##*/}"
11171      if test "x$tool_basename" = "x$tool_specified"; then
11172        # A command without a complete path is provided, search $PATH.
11173        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5
11174$as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;}
11175        # Extract the first word of "$tool_basename", so it can be a program name with args.
11176set dummy $tool_basename; ac_word=$2
11177{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11178$as_echo_n "checking for $ac_word... " >&6; }
11179if ${ac_cv_path_WHICH+:} false; then :
11180  $as_echo_n "(cached) " >&6
11181else
11182  case $WHICH in
11183  [\\/]* | ?:[\\/]*)
11184  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11185  ;;
11186  *)
11187  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11188for as_dir in $PATH
11189do
11190  IFS=$as_save_IFS
11191  test -z "$as_dir" && as_dir=.
11192    for ac_exec_ext in '' $ac_executable_extensions; do
11193  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11194    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11195    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11196    break 2
11197  fi
11198done
11199  done
11200IFS=$as_save_IFS
11201
11202  ;;
11203esac
11204fi
11205WHICH=$ac_cv_path_WHICH
11206if test -n "$WHICH"; then
11207  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11208$as_echo "$WHICH" >&6; }
11209else
11210  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11211$as_echo "no" >&6; }
11212fi
11213
11214
11215        if test "x$WHICH" = x; then
11216          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11217        fi
11218      else
11219        # Otherwise we believe it is a complete path. Use it as it is.
11220        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5
11221$as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;}
11222        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5
11223$as_echo_n "checking for WHICH... " >&6; }
11224        if test ! -x "$tool_specified"; then
11225          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11226$as_echo "not found" >&6; }
11227          as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5
11228        fi
11229        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11230$as_echo "$tool_specified" >&6; }
11231      fi
11232    fi
11233  fi
11234
11235
11236
11237  if test "x$WHICH" = x; then
11238    as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5
11239  fi
11240
11241
11242
11243
11244
11245  # Publish this variable in the help.
11246
11247
11248  if test "x$XARGS" = x; then
11249    # The variable is not set by user, try to locate tool using the code snippet
11250    for ac_prog in xargs
11251do
11252  # Extract the first word of "$ac_prog", so it can be a program name with args.
11253set dummy $ac_prog; ac_word=$2
11254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11255$as_echo_n "checking for $ac_word... " >&6; }
11256if ${ac_cv_path_XARGS+:} false; then :
11257  $as_echo_n "(cached) " >&6
11258else
11259  case $XARGS in
11260  [\\/]* | ?:[\\/]*)
11261  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11262  ;;
11263  *)
11264  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11265for as_dir in $PATH
11266do
11267  IFS=$as_save_IFS
11268  test -z "$as_dir" && as_dir=.
11269    for ac_exec_ext in '' $ac_executable_extensions; do
11270  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11271    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11272    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11273    break 2
11274  fi
11275done
11276  done
11277IFS=$as_save_IFS
11278
11279  ;;
11280esac
11281fi
11282XARGS=$ac_cv_path_XARGS
11283if test -n "$XARGS"; then
11284  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11285$as_echo "$XARGS" >&6; }
11286else
11287  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11288$as_echo "no" >&6; }
11289fi
11290
11291
11292  test -n "$XARGS" && break
11293done
11294
11295  else
11296    # The variable is set, but is it from the command line or the environment?
11297
11298    # Try to remove the string !XARGS! from our list.
11299    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/}
11300    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11301      # If it failed, the variable was not from the command line. Ignore it,
11302      # but warn the user (except for BASH, which is always set by the calling BASH).
11303      if test "xXARGS" != xBASH; then
11304        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5
11305$as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;}
11306      fi
11307      # Try to locate tool using the code snippet
11308      for ac_prog in xargs
11309do
11310  # Extract the first word of "$ac_prog", so it can be a program name with args.
11311set dummy $ac_prog; ac_word=$2
11312{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11313$as_echo_n "checking for $ac_word... " >&6; }
11314if ${ac_cv_path_XARGS+:} false; then :
11315  $as_echo_n "(cached) " >&6
11316else
11317  case $XARGS in
11318  [\\/]* | ?:[\\/]*)
11319  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11320  ;;
11321  *)
11322  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11323for as_dir in $PATH
11324do
11325  IFS=$as_save_IFS
11326  test -z "$as_dir" && as_dir=.
11327    for ac_exec_ext in '' $ac_executable_extensions; do
11328  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11329    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11330    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11331    break 2
11332  fi
11333done
11334  done
11335IFS=$as_save_IFS
11336
11337  ;;
11338esac
11339fi
11340XARGS=$ac_cv_path_XARGS
11341if test -n "$XARGS"; then
11342  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11343$as_echo "$XARGS" >&6; }
11344else
11345  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11346$as_echo "no" >&6; }
11347fi
11348
11349
11350  test -n "$XARGS" && break
11351done
11352
11353    else
11354      # If it succeeded, then it was overridden by the user. We will use it
11355      # for the tool.
11356
11357      # First remove it from the list of overridden variables, so we can test
11358      # for unknown variables in the end.
11359      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11360
11361      # Check if the provided tool contains a complete path.
11362      tool_specified="$XARGS"
11363      tool_basename="${tool_specified##*/}"
11364      if test "x$tool_basename" = "x$tool_specified"; then
11365        # A command without a complete path is provided, search $PATH.
11366        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5
11367$as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;}
11368        # Extract the first word of "$tool_basename", so it can be a program name with args.
11369set dummy $tool_basename; ac_word=$2
11370{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11371$as_echo_n "checking for $ac_word... " >&6; }
11372if ${ac_cv_path_XARGS+:} false; then :
11373  $as_echo_n "(cached) " >&6
11374else
11375  case $XARGS in
11376  [\\/]* | ?:[\\/]*)
11377  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11378  ;;
11379  *)
11380  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11381for as_dir in $PATH
11382do
11383  IFS=$as_save_IFS
11384  test -z "$as_dir" && as_dir=.
11385    for ac_exec_ext in '' $ac_executable_extensions; do
11386  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11387    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11388    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11389    break 2
11390  fi
11391done
11392  done
11393IFS=$as_save_IFS
11394
11395  ;;
11396esac
11397fi
11398XARGS=$ac_cv_path_XARGS
11399if test -n "$XARGS"; then
11400  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11401$as_echo "$XARGS" >&6; }
11402else
11403  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11404$as_echo "no" >&6; }
11405fi
11406
11407
11408        if test "x$XARGS" = x; then
11409          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11410        fi
11411      else
11412        # Otherwise we believe it is a complete path. Use it as it is.
11413        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5
11414$as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;}
11415        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5
11416$as_echo_n "checking for XARGS... " >&6; }
11417        if test ! -x "$tool_specified"; then
11418          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11419$as_echo "not found" >&6; }
11420          as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5
11421        fi
11422        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11423$as_echo "$tool_specified" >&6; }
11424      fi
11425    fi
11426  fi
11427
11428
11429
11430  if test "x$XARGS" = x; then
11431    as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5
11432  fi
11433
11434
11435
11436  # Then required tools that require some special treatment.
11437
11438
11439  # Publish this variable in the help.
11440
11441
11442  if test "x$AWK" = x; then
11443    # The variable is not set by user, try to locate tool using the code snippet
11444    for ac_prog in gawk mawk nawk awk
11445do
11446  # Extract the first word of "$ac_prog", so it can be a program name with args.
11447set dummy $ac_prog; ac_word=$2
11448{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11449$as_echo_n "checking for $ac_word... " >&6; }
11450if ${ac_cv_prog_AWK+:} false; then :
11451  $as_echo_n "(cached) " >&6
11452else
11453  if test -n "$AWK"; then
11454  ac_cv_prog_AWK="$AWK" # Let the user override the test.
11455else
11456as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11457for as_dir in $PATH
11458do
11459  IFS=$as_save_IFS
11460  test -z "$as_dir" && as_dir=.
11461    for ac_exec_ext in '' $ac_executable_extensions; do
11462  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11463    ac_cv_prog_AWK="$ac_prog"
11464    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11465    break 2
11466  fi
11467done
11468  done
11469IFS=$as_save_IFS
11470
11471fi
11472fi
11473AWK=$ac_cv_prog_AWK
11474if test -n "$AWK"; then
11475  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11476$as_echo "$AWK" >&6; }
11477else
11478  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11479$as_echo "no" >&6; }
11480fi
11481
11482
11483  test -n "$AWK" && break
11484done
11485
11486  else
11487    # The variable is set, but is it from the command line or the environment?
11488
11489    # Try to remove the string !AWK! from our list.
11490    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/}
11491    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11492      # If it failed, the variable was not from the command line. Ignore it,
11493      # but warn the user (except for BASH, which is always set by the calling BASH).
11494      if test "xAWK" != xBASH; then
11495        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5
11496$as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;}
11497      fi
11498      # Try to locate tool using the code snippet
11499      for ac_prog in gawk mawk nawk awk
11500do
11501  # Extract the first word of "$ac_prog", so it can be a program name with args.
11502set dummy $ac_prog; ac_word=$2
11503{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11504$as_echo_n "checking for $ac_word... " >&6; }
11505if ${ac_cv_prog_AWK+:} false; then :
11506  $as_echo_n "(cached) " >&6
11507else
11508  if test -n "$AWK"; then
11509  ac_cv_prog_AWK="$AWK" # Let the user override the test.
11510else
11511as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11512for as_dir in $PATH
11513do
11514  IFS=$as_save_IFS
11515  test -z "$as_dir" && as_dir=.
11516    for ac_exec_ext in '' $ac_executable_extensions; do
11517  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11518    ac_cv_prog_AWK="$ac_prog"
11519    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11520    break 2
11521  fi
11522done
11523  done
11524IFS=$as_save_IFS
11525
11526fi
11527fi
11528AWK=$ac_cv_prog_AWK
11529if test -n "$AWK"; then
11530  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11531$as_echo "$AWK" >&6; }
11532else
11533  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11534$as_echo "no" >&6; }
11535fi
11536
11537
11538  test -n "$AWK" && break
11539done
11540
11541    else
11542      # If it succeeded, then it was overridden by the user. We will use it
11543      # for the tool.
11544
11545      # First remove it from the list of overridden variables, so we can test
11546      # for unknown variables in the end.
11547      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11548
11549      # Check if the provided tool contains a complete path.
11550      tool_specified="$AWK"
11551      tool_basename="${tool_specified##*/}"
11552      if test "x$tool_basename" = "x$tool_specified"; then
11553        # A command without a complete path is provided, search $PATH.
11554        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5
11555$as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;}
11556        # Extract the first word of "$tool_basename", so it can be a program name with args.
11557set dummy $tool_basename; ac_word=$2
11558{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11559$as_echo_n "checking for $ac_word... " >&6; }
11560if ${ac_cv_path_AWK+:} false; then :
11561  $as_echo_n "(cached) " >&6
11562else
11563  case $AWK in
11564  [\\/]* | ?:[\\/]*)
11565  ac_cv_path_AWK="$AWK" # Let the user override the test with a path.
11566  ;;
11567  *)
11568  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11569for as_dir in $PATH
11570do
11571  IFS=$as_save_IFS
11572  test -z "$as_dir" && as_dir=.
11573    for ac_exec_ext in '' $ac_executable_extensions; do
11574  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11575    ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext"
11576    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11577    break 2
11578  fi
11579done
11580  done
11581IFS=$as_save_IFS
11582
11583  ;;
11584esac
11585fi
11586AWK=$ac_cv_path_AWK
11587if test -n "$AWK"; then
11588  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11589$as_echo "$AWK" >&6; }
11590else
11591  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11592$as_echo "no" >&6; }
11593fi
11594
11595
11596        if test "x$AWK" = x; then
11597          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11598        fi
11599      else
11600        # Otherwise we believe it is a complete path. Use it as it is.
11601        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5
11602$as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;}
11603        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5
11604$as_echo_n "checking for AWK... " >&6; }
11605        if test ! -x "$tool_specified"; then
11606          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11607$as_echo "not found" >&6; }
11608          as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5
11609        fi
11610        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11611$as_echo "$tool_specified" >&6; }
11612      fi
11613    fi
11614  fi
11615
11616
11617  if test "x$AWK" = x; then
11618    as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5
11619  fi
11620
11621
11622
11623
11624  # Publish this variable in the help.
11625
11626
11627  if test "x$GREP" = x; then
11628    # The variable is not set by user, try to locate tool using the code snippet
11629    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11630$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11631if ${ac_cv_path_GREP+:} false; then :
11632  $as_echo_n "(cached) " >&6
11633else
11634  if test -z "$GREP"; then
11635  ac_path_GREP_found=false
11636  # Loop through the user's path and test for each of PROGNAME-LIST
11637  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11638for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11639do
11640  IFS=$as_save_IFS
11641  test -z "$as_dir" && as_dir=.
11642    for ac_prog in grep ggrep; do
11643    for ac_exec_ext in '' $ac_executable_extensions; do
11644      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11645      as_fn_executable_p "$ac_path_GREP" || continue
11646# Check for GNU ac_path_GREP and select it if it is found.
11647  # Check for GNU $ac_path_GREP
11648case `"$ac_path_GREP" --version 2>&1` in
11649*GNU*)
11650  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11651*)
11652  ac_count=0
11653  $as_echo_n 0123456789 >"conftest.in"
11654  while :
11655  do
11656    cat "conftest.in" "conftest.in" >"conftest.tmp"
11657    mv "conftest.tmp" "conftest.in"
11658    cp "conftest.in" "conftest.nl"
11659    $as_echo 'GREP' >> "conftest.nl"
11660    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11661    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11662    as_fn_arith $ac_count + 1 && ac_count=$as_val
11663    if test $ac_count -gt ${ac_path_GREP_max-0}; then
11664      # Best one so far, save it but keep looking for a better one
11665      ac_cv_path_GREP="$ac_path_GREP"
11666      ac_path_GREP_max=$ac_count
11667    fi
11668    # 10*(2^10) chars as input seems more than enough
11669    test $ac_count -gt 10 && break
11670  done
11671  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11672esac
11673
11674      $ac_path_GREP_found && break 3
11675    done
11676  done
11677  done
11678IFS=$as_save_IFS
11679  if test -z "$ac_cv_path_GREP"; then
11680    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11681  fi
11682else
11683  ac_cv_path_GREP=$GREP
11684fi
11685
11686fi
11687{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11688$as_echo "$ac_cv_path_GREP" >&6; }
11689 GREP="$ac_cv_path_GREP"
11690
11691
11692  else
11693    # The variable is set, but is it from the command line or the environment?
11694
11695    # Try to remove the string !GREP! from our list.
11696    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/}
11697    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11698      # If it failed, the variable was not from the command line. Ignore it,
11699      # but warn the user (except for BASH, which is always set by the calling BASH).
11700      if test "xGREP" != xBASH; then
11701        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5
11702$as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;}
11703      fi
11704      # Try to locate tool using the code snippet
11705      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11706$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11707if ${ac_cv_path_GREP+:} false; then :
11708  $as_echo_n "(cached) " >&6
11709else
11710  if test -z "$GREP"; then
11711  ac_path_GREP_found=false
11712  # Loop through the user's path and test for each of PROGNAME-LIST
11713  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11714for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11715do
11716  IFS=$as_save_IFS
11717  test -z "$as_dir" && as_dir=.
11718    for ac_prog in grep ggrep; do
11719    for ac_exec_ext in '' $ac_executable_extensions; do
11720      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11721      as_fn_executable_p "$ac_path_GREP" || continue
11722# Check for GNU ac_path_GREP and select it if it is found.
11723  # Check for GNU $ac_path_GREP
11724case `"$ac_path_GREP" --version 2>&1` in
11725*GNU*)
11726  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11727*)
11728  ac_count=0
11729  $as_echo_n 0123456789 >"conftest.in"
11730  while :
11731  do
11732    cat "conftest.in" "conftest.in" >"conftest.tmp"
11733    mv "conftest.tmp" "conftest.in"
11734    cp "conftest.in" "conftest.nl"
11735    $as_echo 'GREP' >> "conftest.nl"
11736    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11737    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11738    as_fn_arith $ac_count + 1 && ac_count=$as_val
11739    if test $ac_count -gt ${ac_path_GREP_max-0}; then
11740      # Best one so far, save it but keep looking for a better one
11741      ac_cv_path_GREP="$ac_path_GREP"
11742      ac_path_GREP_max=$ac_count
11743    fi
11744    # 10*(2^10) chars as input seems more than enough
11745    test $ac_count -gt 10 && break
11746  done
11747  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11748esac
11749
11750      $ac_path_GREP_found && break 3
11751    done
11752  done
11753  done
11754IFS=$as_save_IFS
11755  if test -z "$ac_cv_path_GREP"; then
11756    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11757  fi
11758else
11759  ac_cv_path_GREP=$GREP
11760fi
11761
11762fi
11763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11764$as_echo "$ac_cv_path_GREP" >&6; }
11765 GREP="$ac_cv_path_GREP"
11766
11767
11768    else
11769      # If it succeeded, then it was overridden by the user. We will use it
11770      # for the tool.
11771
11772      # First remove it from the list of overridden variables, so we can test
11773      # for unknown variables in the end.
11774      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11775
11776      # Check if the provided tool contains a complete path.
11777      tool_specified="$GREP"
11778      tool_basename="${tool_specified##*/}"
11779      if test "x$tool_basename" = "x$tool_specified"; then
11780        # A command without a complete path is provided, search $PATH.
11781        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5
11782$as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;}
11783        # Extract the first word of "$tool_basename", so it can be a program name with args.
11784set dummy $tool_basename; ac_word=$2
11785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11786$as_echo_n "checking for $ac_word... " >&6; }
11787if ${ac_cv_path_GREP+:} false; then :
11788  $as_echo_n "(cached) " >&6
11789else
11790  case $GREP in
11791  [\\/]* | ?:[\\/]*)
11792  ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
11793  ;;
11794  *)
11795  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11796for as_dir in $PATH
11797do
11798  IFS=$as_save_IFS
11799  test -z "$as_dir" && as_dir=.
11800    for ac_exec_ext in '' $ac_executable_extensions; do
11801  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11802    ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
11803    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11804    break 2
11805  fi
11806done
11807  done
11808IFS=$as_save_IFS
11809
11810  ;;
11811esac
11812fi
11813GREP=$ac_cv_path_GREP
11814if test -n "$GREP"; then
11815  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
11816$as_echo "$GREP" >&6; }
11817else
11818  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11819$as_echo "no" >&6; }
11820fi
11821
11822
11823        if test "x$GREP" = x; then
11824          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11825        fi
11826      else
11827        # Otherwise we believe it is a complete path. Use it as it is.
11828        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5
11829$as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;}
11830        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5
11831$as_echo_n "checking for GREP... " >&6; }
11832        if test ! -x "$tool_specified"; then
11833          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11834$as_echo "not found" >&6; }
11835          as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11836        fi
11837        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11838$as_echo "$tool_specified" >&6; }
11839      fi
11840    fi
11841  fi
11842
11843
11844  if test "x$GREP" = x; then
11845    as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5
11846  fi
11847
11848
11849
11850
11851  # Publish this variable in the help.
11852
11853
11854  if test "x$EGREP" = x; then
11855    # The variable is not set by user, try to locate tool using the code snippet
11856    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11857$as_echo_n "checking for egrep... " >&6; }
11858if ${ac_cv_path_EGREP+:} false; then :
11859  $as_echo_n "(cached) " >&6
11860else
11861  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11862   then ac_cv_path_EGREP="$GREP -E"
11863   else
11864     if test -z "$EGREP"; then
11865  ac_path_EGREP_found=false
11866  # Loop through the user's path and test for each of PROGNAME-LIST
11867  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11868for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11869do
11870  IFS=$as_save_IFS
11871  test -z "$as_dir" && as_dir=.
11872    for ac_prog in egrep; do
11873    for ac_exec_ext in '' $ac_executable_extensions; do
11874      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11875      as_fn_executable_p "$ac_path_EGREP" || continue
11876# Check for GNU ac_path_EGREP and select it if it is found.
11877  # Check for GNU $ac_path_EGREP
11878case `"$ac_path_EGREP" --version 2>&1` in
11879*GNU*)
11880  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11881*)
11882  ac_count=0
11883  $as_echo_n 0123456789 >"conftest.in"
11884  while :
11885  do
11886    cat "conftest.in" "conftest.in" >"conftest.tmp"
11887    mv "conftest.tmp" "conftest.in"
11888    cp "conftest.in" "conftest.nl"
11889    $as_echo 'EGREP' >> "conftest.nl"
11890    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11891    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11892    as_fn_arith $ac_count + 1 && ac_count=$as_val
11893    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11894      # Best one so far, save it but keep looking for a better one
11895      ac_cv_path_EGREP="$ac_path_EGREP"
11896      ac_path_EGREP_max=$ac_count
11897    fi
11898    # 10*(2^10) chars as input seems more than enough
11899    test $ac_count -gt 10 && break
11900  done
11901  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11902esac
11903
11904      $ac_path_EGREP_found && break 3
11905    done
11906  done
11907  done
11908IFS=$as_save_IFS
11909  if test -z "$ac_cv_path_EGREP"; then
11910    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11911  fi
11912else
11913  ac_cv_path_EGREP=$EGREP
11914fi
11915
11916   fi
11917fi
11918{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11919$as_echo "$ac_cv_path_EGREP" >&6; }
11920 EGREP="$ac_cv_path_EGREP"
11921
11922
11923  else
11924    # The variable is set, but is it from the command line or the environment?
11925
11926    # Try to remove the string !EGREP! from our list.
11927    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/}
11928    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11929      # If it failed, the variable was not from the command line. Ignore it,
11930      # but warn the user (except for BASH, which is always set by the calling BASH).
11931      if test "xEGREP" != xBASH; then
11932        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5
11933$as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;}
11934      fi
11935      # Try to locate tool using the code snippet
11936      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11937$as_echo_n "checking for egrep... " >&6; }
11938if ${ac_cv_path_EGREP+:} false; then :
11939  $as_echo_n "(cached) " >&6
11940else
11941  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11942   then ac_cv_path_EGREP="$GREP -E"
11943   else
11944     if test -z "$EGREP"; then
11945  ac_path_EGREP_found=false
11946  # Loop through the user's path and test for each of PROGNAME-LIST
11947  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11948for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11949do
11950  IFS=$as_save_IFS
11951  test -z "$as_dir" && as_dir=.
11952    for ac_prog in egrep; do
11953    for ac_exec_ext in '' $ac_executable_extensions; do
11954      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11955      as_fn_executable_p "$ac_path_EGREP" || continue
11956# Check for GNU ac_path_EGREP and select it if it is found.
11957  # Check for GNU $ac_path_EGREP
11958case `"$ac_path_EGREP" --version 2>&1` in
11959*GNU*)
11960  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11961*)
11962  ac_count=0
11963  $as_echo_n 0123456789 >"conftest.in"
11964  while :
11965  do
11966    cat "conftest.in" "conftest.in" >"conftest.tmp"
11967    mv "conftest.tmp" "conftest.in"
11968    cp "conftest.in" "conftest.nl"
11969    $as_echo 'EGREP' >> "conftest.nl"
11970    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11971    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11972    as_fn_arith $ac_count + 1 && ac_count=$as_val
11973    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11974      # Best one so far, save it but keep looking for a better one
11975      ac_cv_path_EGREP="$ac_path_EGREP"
11976      ac_path_EGREP_max=$ac_count
11977    fi
11978    # 10*(2^10) chars as input seems more than enough
11979    test $ac_count -gt 10 && break
11980  done
11981  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11982esac
11983
11984      $ac_path_EGREP_found && break 3
11985    done
11986  done
11987  done
11988IFS=$as_save_IFS
11989  if test -z "$ac_cv_path_EGREP"; then
11990    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11991  fi
11992else
11993  ac_cv_path_EGREP=$EGREP
11994fi
11995
11996   fi
11997fi
11998{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11999$as_echo "$ac_cv_path_EGREP" >&6; }
12000 EGREP="$ac_cv_path_EGREP"
12001
12002
12003    else
12004      # If it succeeded, then it was overridden by the user. We will use it
12005      # for the tool.
12006
12007      # First remove it from the list of overridden variables, so we can test
12008      # for unknown variables in the end.
12009      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12010
12011      # Check if the provided tool contains a complete path.
12012      tool_specified="$EGREP"
12013      tool_basename="${tool_specified##*/}"
12014      if test "x$tool_basename" = "x$tool_specified"; then
12015        # A command without a complete path is provided, search $PATH.
12016        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5
12017$as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;}
12018        # Extract the first word of "$tool_basename", so it can be a program name with args.
12019set dummy $tool_basename; ac_word=$2
12020{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12021$as_echo_n "checking for $ac_word... " >&6; }
12022if ${ac_cv_path_EGREP+:} false; then :
12023  $as_echo_n "(cached) " >&6
12024else
12025  case $EGREP in
12026  [\\/]* | ?:[\\/]*)
12027  ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
12028  ;;
12029  *)
12030  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12031for as_dir in $PATH
12032do
12033  IFS=$as_save_IFS
12034  test -z "$as_dir" && as_dir=.
12035    for ac_exec_ext in '' $ac_executable_extensions; do
12036  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12037    ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
12038    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12039    break 2
12040  fi
12041done
12042  done
12043IFS=$as_save_IFS
12044
12045  ;;
12046esac
12047fi
12048EGREP=$ac_cv_path_EGREP
12049if test -n "$EGREP"; then
12050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
12051$as_echo "$EGREP" >&6; }
12052else
12053  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12054$as_echo "no" >&6; }
12055fi
12056
12057
12058        if test "x$EGREP" = x; then
12059          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12060        fi
12061      else
12062        # Otherwise we believe it is a complete path. Use it as it is.
12063        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5
12064$as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;}
12065        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5
12066$as_echo_n "checking for EGREP... " >&6; }
12067        if test ! -x "$tool_specified"; then
12068          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12069$as_echo "not found" >&6; }
12070          as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12071        fi
12072        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12073$as_echo "$tool_specified" >&6; }
12074      fi
12075    fi
12076  fi
12077
12078
12079  if test "x$EGREP" = x; then
12080    as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5
12081  fi
12082
12083
12084
12085
12086  # Publish this variable in the help.
12087
12088
12089  if test "x$FGREP" = x; then
12090    # The variable is not set by user, try to locate tool using the code snippet
12091    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12092$as_echo_n "checking for fgrep... " >&6; }
12093if ${ac_cv_path_FGREP+:} false; then :
12094  $as_echo_n "(cached) " >&6
12095else
12096  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12097   then ac_cv_path_FGREP="$GREP -F"
12098   else
12099     if test -z "$FGREP"; then
12100  ac_path_FGREP_found=false
12101  # Loop through the user's path and test for each of PROGNAME-LIST
12102  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12103for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12104do
12105  IFS=$as_save_IFS
12106  test -z "$as_dir" && as_dir=.
12107    for ac_prog in fgrep; do
12108    for ac_exec_ext in '' $ac_executable_extensions; do
12109      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12110      as_fn_executable_p "$ac_path_FGREP" || continue
12111# Check for GNU ac_path_FGREP and select it if it is found.
12112  # Check for GNU $ac_path_FGREP
12113case `"$ac_path_FGREP" --version 2>&1` in
12114*GNU*)
12115  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12116*)
12117  ac_count=0
12118  $as_echo_n 0123456789 >"conftest.in"
12119  while :
12120  do
12121    cat "conftest.in" "conftest.in" >"conftest.tmp"
12122    mv "conftest.tmp" "conftest.in"
12123    cp "conftest.in" "conftest.nl"
12124    $as_echo 'FGREP' >> "conftest.nl"
12125    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12126    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12127    as_fn_arith $ac_count + 1 && ac_count=$as_val
12128    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12129      # Best one so far, save it but keep looking for a better one
12130      ac_cv_path_FGREP="$ac_path_FGREP"
12131      ac_path_FGREP_max=$ac_count
12132    fi
12133    # 10*(2^10) chars as input seems more than enough
12134    test $ac_count -gt 10 && break
12135  done
12136  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12137esac
12138
12139      $ac_path_FGREP_found && break 3
12140    done
12141  done
12142  done
12143IFS=$as_save_IFS
12144  if test -z "$ac_cv_path_FGREP"; then
12145    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12146  fi
12147else
12148  ac_cv_path_FGREP=$FGREP
12149fi
12150
12151   fi
12152fi
12153{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12154$as_echo "$ac_cv_path_FGREP" >&6; }
12155 FGREP="$ac_cv_path_FGREP"
12156
12157
12158  else
12159    # The variable is set, but is it from the command line or the environment?
12160
12161    # Try to remove the string !FGREP! from our list.
12162    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/}
12163    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12164      # If it failed, the variable was not from the command line. Ignore it,
12165      # but warn the user (except for BASH, which is always set by the calling BASH).
12166      if test "xFGREP" != xBASH; then
12167        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5
12168$as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;}
12169      fi
12170      # Try to locate tool using the code snippet
12171      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12172$as_echo_n "checking for fgrep... " >&6; }
12173if ${ac_cv_path_FGREP+:} false; then :
12174  $as_echo_n "(cached) " >&6
12175else
12176  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12177   then ac_cv_path_FGREP="$GREP -F"
12178   else
12179     if test -z "$FGREP"; then
12180  ac_path_FGREP_found=false
12181  # Loop through the user's path and test for each of PROGNAME-LIST
12182  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12183for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12184do
12185  IFS=$as_save_IFS
12186  test -z "$as_dir" && as_dir=.
12187    for ac_prog in fgrep; do
12188    for ac_exec_ext in '' $ac_executable_extensions; do
12189      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12190      as_fn_executable_p "$ac_path_FGREP" || continue
12191# Check for GNU ac_path_FGREP and select it if it is found.
12192  # Check for GNU $ac_path_FGREP
12193case `"$ac_path_FGREP" --version 2>&1` in
12194*GNU*)
12195  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12196*)
12197  ac_count=0
12198  $as_echo_n 0123456789 >"conftest.in"
12199  while :
12200  do
12201    cat "conftest.in" "conftest.in" >"conftest.tmp"
12202    mv "conftest.tmp" "conftest.in"
12203    cp "conftest.in" "conftest.nl"
12204    $as_echo 'FGREP' >> "conftest.nl"
12205    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12206    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12207    as_fn_arith $ac_count + 1 && ac_count=$as_val
12208    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12209      # Best one so far, save it but keep looking for a better one
12210      ac_cv_path_FGREP="$ac_path_FGREP"
12211      ac_path_FGREP_max=$ac_count
12212    fi
12213    # 10*(2^10) chars as input seems more than enough
12214    test $ac_count -gt 10 && break
12215  done
12216  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12217esac
12218
12219      $ac_path_FGREP_found && break 3
12220    done
12221  done
12222  done
12223IFS=$as_save_IFS
12224  if test -z "$ac_cv_path_FGREP"; then
12225    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12226  fi
12227else
12228  ac_cv_path_FGREP=$FGREP
12229fi
12230
12231   fi
12232fi
12233{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12234$as_echo "$ac_cv_path_FGREP" >&6; }
12235 FGREP="$ac_cv_path_FGREP"
12236
12237
12238    else
12239      # If it succeeded, then it was overridden by the user. We will use it
12240      # for the tool.
12241
12242      # First remove it from the list of overridden variables, so we can test
12243      # for unknown variables in the end.
12244      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12245
12246      # Check if the provided tool contains a complete path.
12247      tool_specified="$FGREP"
12248      tool_basename="${tool_specified##*/}"
12249      if test "x$tool_basename" = "x$tool_specified"; then
12250        # A command without a complete path is provided, search $PATH.
12251        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5
12252$as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;}
12253        # Extract the first word of "$tool_basename", so it can be a program name with args.
12254set dummy $tool_basename; ac_word=$2
12255{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12256$as_echo_n "checking for $ac_word... " >&6; }
12257if ${ac_cv_path_FGREP+:} false; then :
12258  $as_echo_n "(cached) " >&6
12259else
12260  case $FGREP in
12261  [\\/]* | ?:[\\/]*)
12262  ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
12263  ;;
12264  *)
12265  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12266for as_dir in $PATH
12267do
12268  IFS=$as_save_IFS
12269  test -z "$as_dir" && as_dir=.
12270    for ac_exec_ext in '' $ac_executable_extensions; do
12271  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12272    ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext"
12273    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12274    break 2
12275  fi
12276done
12277  done
12278IFS=$as_save_IFS
12279
12280  ;;
12281esac
12282fi
12283FGREP=$ac_cv_path_FGREP
12284if test -n "$FGREP"; then
12285  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5
12286$as_echo "$FGREP" >&6; }
12287else
12288  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12289$as_echo "no" >&6; }
12290fi
12291
12292
12293        if test "x$FGREP" = x; then
12294          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12295        fi
12296      else
12297        # Otherwise we believe it is a complete path. Use it as it is.
12298        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5
12299$as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;}
12300        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5
12301$as_echo_n "checking for FGREP... " >&6; }
12302        if test ! -x "$tool_specified"; then
12303          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12304$as_echo "not found" >&6; }
12305          as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12306        fi
12307        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12308$as_echo "$tool_specified" >&6; }
12309      fi
12310    fi
12311  fi
12312
12313
12314  if test "x$FGREP" = x; then
12315    as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5
12316  fi
12317
12318
12319
12320
12321  # Publish this variable in the help.
12322
12323
12324  if test "x$SED" = x; then
12325    # The variable is not set by user, try to locate tool using the code snippet
12326    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12327$as_echo_n "checking for a sed that does not truncate output... " >&6; }
12328if ${ac_cv_path_SED+:} false; then :
12329  $as_echo_n "(cached) " >&6
12330else
12331            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12332     for ac_i in 1 2 3 4 5 6 7; do
12333       ac_script="$ac_script$as_nl$ac_script"
12334     done
12335     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12336     { ac_script=; unset ac_script;}
12337     if test -z "$SED"; then
12338  ac_path_SED_found=false
12339  # Loop through the user's path and test for each of PROGNAME-LIST
12340  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12341for as_dir in $PATH
12342do
12343  IFS=$as_save_IFS
12344  test -z "$as_dir" && as_dir=.
12345    for ac_prog in sed gsed; do
12346    for ac_exec_ext in '' $ac_executable_extensions; do
12347      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12348      as_fn_executable_p "$ac_path_SED" || continue
12349# Check for GNU ac_path_SED and select it if it is found.
12350  # Check for GNU $ac_path_SED
12351case `"$ac_path_SED" --version 2>&1` in
12352*GNU*)
12353  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12354*)
12355  ac_count=0
12356  $as_echo_n 0123456789 >"conftest.in"
12357  while :
12358  do
12359    cat "conftest.in" "conftest.in" >"conftest.tmp"
12360    mv "conftest.tmp" "conftest.in"
12361    cp "conftest.in" "conftest.nl"
12362    $as_echo '' >> "conftest.nl"
12363    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12364    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12365    as_fn_arith $ac_count + 1 && ac_count=$as_val
12366    if test $ac_count -gt ${ac_path_SED_max-0}; then
12367      # Best one so far, save it but keep looking for a better one
12368      ac_cv_path_SED="$ac_path_SED"
12369      ac_path_SED_max=$ac_count
12370    fi
12371    # 10*(2^10) chars as input seems more than enough
12372    test $ac_count -gt 10 && break
12373  done
12374  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12375esac
12376
12377      $ac_path_SED_found && break 3
12378    done
12379  done
12380  done
12381IFS=$as_save_IFS
12382  if test -z "$ac_cv_path_SED"; then
12383    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12384  fi
12385else
12386  ac_cv_path_SED=$SED
12387fi
12388
12389fi
12390{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12391$as_echo "$ac_cv_path_SED" >&6; }
12392 SED="$ac_cv_path_SED"
12393  rm -f conftest.sed
12394
12395  else
12396    # The variable is set, but is it from the command line or the environment?
12397
12398    # Try to remove the string !SED! from our list.
12399    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/}
12400    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12401      # If it failed, the variable was not from the command line. Ignore it,
12402      # but warn the user (except for BASH, which is always set by the calling BASH).
12403      if test "xSED" != xBASH; then
12404        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5
12405$as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;}
12406      fi
12407      # Try to locate tool using the code snippet
12408      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12409$as_echo_n "checking for a sed that does not truncate output... " >&6; }
12410if ${ac_cv_path_SED+:} false; then :
12411  $as_echo_n "(cached) " >&6
12412else
12413            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12414     for ac_i in 1 2 3 4 5 6 7; do
12415       ac_script="$ac_script$as_nl$ac_script"
12416     done
12417     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12418     { ac_script=; unset ac_script;}
12419     if test -z "$SED"; then
12420  ac_path_SED_found=false
12421  # Loop through the user's path and test for each of PROGNAME-LIST
12422  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12423for as_dir in $PATH
12424do
12425  IFS=$as_save_IFS
12426  test -z "$as_dir" && as_dir=.
12427    for ac_prog in sed gsed; do
12428    for ac_exec_ext in '' $ac_executable_extensions; do
12429      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12430      as_fn_executable_p "$ac_path_SED" || continue
12431# Check for GNU ac_path_SED and select it if it is found.
12432  # Check for GNU $ac_path_SED
12433case `"$ac_path_SED" --version 2>&1` in
12434*GNU*)
12435  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12436*)
12437  ac_count=0
12438  $as_echo_n 0123456789 >"conftest.in"
12439  while :
12440  do
12441    cat "conftest.in" "conftest.in" >"conftest.tmp"
12442    mv "conftest.tmp" "conftest.in"
12443    cp "conftest.in" "conftest.nl"
12444    $as_echo '' >> "conftest.nl"
12445    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12446    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12447    as_fn_arith $ac_count + 1 && ac_count=$as_val
12448    if test $ac_count -gt ${ac_path_SED_max-0}; then
12449      # Best one so far, save it but keep looking for a better one
12450      ac_cv_path_SED="$ac_path_SED"
12451      ac_path_SED_max=$ac_count
12452    fi
12453    # 10*(2^10) chars as input seems more than enough
12454    test $ac_count -gt 10 && break
12455  done
12456  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12457esac
12458
12459      $ac_path_SED_found && break 3
12460    done
12461  done
12462  done
12463IFS=$as_save_IFS
12464  if test -z "$ac_cv_path_SED"; then
12465    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12466  fi
12467else
12468  ac_cv_path_SED=$SED
12469fi
12470
12471fi
12472{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12473$as_echo "$ac_cv_path_SED" >&6; }
12474 SED="$ac_cv_path_SED"
12475  rm -f conftest.sed
12476
12477    else
12478      # If it succeeded, then it was overridden by the user. We will use it
12479      # for the tool.
12480
12481      # First remove it from the list of overridden variables, so we can test
12482      # for unknown variables in the end.
12483      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12484
12485      # Check if the provided tool contains a complete path.
12486      tool_specified="$SED"
12487      tool_basename="${tool_specified##*/}"
12488      if test "x$tool_basename" = "x$tool_specified"; then
12489        # A command without a complete path is provided, search $PATH.
12490        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5
12491$as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;}
12492        # Extract the first word of "$tool_basename", so it can be a program name with args.
12493set dummy $tool_basename; ac_word=$2
12494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12495$as_echo_n "checking for $ac_word... " >&6; }
12496if ${ac_cv_path_SED+:} false; then :
12497  $as_echo_n "(cached) " >&6
12498else
12499  case $SED in
12500  [\\/]* | ?:[\\/]*)
12501  ac_cv_path_SED="$SED" # Let the user override the test with a path.
12502  ;;
12503  *)
12504  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12505for as_dir in $PATH
12506do
12507  IFS=$as_save_IFS
12508  test -z "$as_dir" && as_dir=.
12509    for ac_exec_ext in '' $ac_executable_extensions; do
12510  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12511    ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
12512    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12513    break 2
12514  fi
12515done
12516  done
12517IFS=$as_save_IFS
12518
12519  ;;
12520esac
12521fi
12522SED=$ac_cv_path_SED
12523if test -n "$SED"; then
12524  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
12525$as_echo "$SED" >&6; }
12526else
12527  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12528$as_echo "no" >&6; }
12529fi
12530
12531
12532        if test "x$SED" = x; then
12533          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12534        fi
12535      else
12536        # Otherwise we believe it is a complete path. Use it as it is.
12537        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5
12538$as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;}
12539        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5
12540$as_echo_n "checking for SED... " >&6; }
12541        if test ! -x "$tool_specified"; then
12542          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12543$as_echo "not found" >&6; }
12544          as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5
12545        fi
12546        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12547$as_echo "$tool_specified" >&6; }
12548      fi
12549    fi
12550  fi
12551
12552
12553  if test "x$SED" = x; then
12554    as_fn_error $? "Could not find required tool for SED" "$LINENO" 5
12555  fi
12556
12557
12558
12559  # Always force rm.
12560  RM="$RM -f"
12561
12562  # pwd behaves differently on various platforms and some don't support the -L flag.
12563  # Always use the bash builtin pwd to get uniform behavior.
12564  THEPWDCMD=pwd
12565
12566  # These are not required on all platforms
12567
12568
12569  # Publish this variable in the help.
12570
12571
12572  if test "x$CYGPATH" = x; then
12573    # The variable is not set by user, try to locate tool using the code snippet
12574    for ac_prog in cygpath
12575do
12576  # Extract the first word of "$ac_prog", so it can be a program name with args.
12577set dummy $ac_prog; ac_word=$2
12578{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12579$as_echo_n "checking for $ac_word... " >&6; }
12580if ${ac_cv_path_CYGPATH+:} false; then :
12581  $as_echo_n "(cached) " >&6
12582else
12583  case $CYGPATH in
12584  [\\/]* | ?:[\\/]*)
12585  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12586  ;;
12587  *)
12588  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12589for as_dir in $PATH
12590do
12591  IFS=$as_save_IFS
12592  test -z "$as_dir" && as_dir=.
12593    for ac_exec_ext in '' $ac_executable_extensions; do
12594  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12595    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12596    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12597    break 2
12598  fi
12599done
12600  done
12601IFS=$as_save_IFS
12602
12603  ;;
12604esac
12605fi
12606CYGPATH=$ac_cv_path_CYGPATH
12607if test -n "$CYGPATH"; then
12608  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12609$as_echo "$CYGPATH" >&6; }
12610else
12611  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12612$as_echo "no" >&6; }
12613fi
12614
12615
12616  test -n "$CYGPATH" && break
12617done
12618
12619  else
12620    # The variable is set, but is it from the command line or the environment?
12621
12622    # Try to remove the string !CYGPATH! from our list.
12623    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/}
12624    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12625      # If it failed, the variable was not from the command line. Ignore it,
12626      # but warn the user (except for BASH, which is always set by the calling BASH).
12627      if test "xCYGPATH" != xBASH; then
12628        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5
12629$as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;}
12630      fi
12631      # Try to locate tool using the code snippet
12632      for ac_prog in cygpath
12633do
12634  # Extract the first word of "$ac_prog", so it can be a program name with args.
12635set dummy $ac_prog; ac_word=$2
12636{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12637$as_echo_n "checking for $ac_word... " >&6; }
12638if ${ac_cv_path_CYGPATH+:} false; then :
12639  $as_echo_n "(cached) " >&6
12640else
12641  case $CYGPATH in
12642  [\\/]* | ?:[\\/]*)
12643  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12644  ;;
12645  *)
12646  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12647for as_dir in $PATH
12648do
12649  IFS=$as_save_IFS
12650  test -z "$as_dir" && as_dir=.
12651    for ac_exec_ext in '' $ac_executable_extensions; do
12652  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12653    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12654    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12655    break 2
12656  fi
12657done
12658  done
12659IFS=$as_save_IFS
12660
12661  ;;
12662esac
12663fi
12664CYGPATH=$ac_cv_path_CYGPATH
12665if test -n "$CYGPATH"; then
12666  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12667$as_echo "$CYGPATH" >&6; }
12668else
12669  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12670$as_echo "no" >&6; }
12671fi
12672
12673
12674  test -n "$CYGPATH" && break
12675done
12676
12677    else
12678      # If it succeeded, then it was overridden by the user. We will use it
12679      # for the tool.
12680
12681      # First remove it from the list of overridden variables, so we can test
12682      # for unknown variables in the end.
12683      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12684
12685      # Check if the provided tool contains a complete path.
12686      tool_specified="$CYGPATH"
12687      tool_basename="${tool_specified##*/}"
12688      if test "x$tool_basename" = "x$tool_specified"; then
12689        # A command without a complete path is provided, search $PATH.
12690        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5
12691$as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;}
12692        # Extract the first word of "$tool_basename", so it can be a program name with args.
12693set dummy $tool_basename; ac_word=$2
12694{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12695$as_echo_n "checking for $ac_word... " >&6; }
12696if ${ac_cv_path_CYGPATH+:} false; then :
12697  $as_echo_n "(cached) " >&6
12698else
12699  case $CYGPATH in
12700  [\\/]* | ?:[\\/]*)
12701  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12702  ;;
12703  *)
12704  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12705for as_dir in $PATH
12706do
12707  IFS=$as_save_IFS
12708  test -z "$as_dir" && as_dir=.
12709    for ac_exec_ext in '' $ac_executable_extensions; do
12710  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12711    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12712    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12713    break 2
12714  fi
12715done
12716  done
12717IFS=$as_save_IFS
12718
12719  ;;
12720esac
12721fi
12722CYGPATH=$ac_cv_path_CYGPATH
12723if test -n "$CYGPATH"; then
12724  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12725$as_echo "$CYGPATH" >&6; }
12726else
12727  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12728$as_echo "no" >&6; }
12729fi
12730
12731
12732        if test "x$CYGPATH" = x; then
12733          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12734        fi
12735      else
12736        # Otherwise we believe it is a complete path. Use it as it is.
12737        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5
12738$as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;}
12739        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5
12740$as_echo_n "checking for CYGPATH... " >&6; }
12741        if test ! -x "$tool_specified"; then
12742          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12743$as_echo "not found" >&6; }
12744          as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5
12745        fi
12746        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12747$as_echo "$tool_specified" >&6; }
12748      fi
12749    fi
12750  fi
12751
12752
12753
12754
12755  # Publish this variable in the help.
12756
12757
12758  if test "x$READLINK" = x; then
12759    # The variable is not set by user, try to locate tool using the code snippet
12760    for ac_prog in greadlink readlink
12761do
12762  # Extract the first word of "$ac_prog", so it can be a program name with args.
12763set dummy $ac_prog; ac_word=$2
12764{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12765$as_echo_n "checking for $ac_word... " >&6; }
12766if ${ac_cv_path_READLINK+:} false; then :
12767  $as_echo_n "(cached) " >&6
12768else
12769  case $READLINK in
12770  [\\/]* | ?:[\\/]*)
12771  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12772  ;;
12773  *)
12774  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12775for as_dir in $PATH
12776do
12777  IFS=$as_save_IFS
12778  test -z "$as_dir" && as_dir=.
12779    for ac_exec_ext in '' $ac_executable_extensions; do
12780  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12781    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12782    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12783    break 2
12784  fi
12785done
12786  done
12787IFS=$as_save_IFS
12788
12789  ;;
12790esac
12791fi
12792READLINK=$ac_cv_path_READLINK
12793if test -n "$READLINK"; then
12794  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12795$as_echo "$READLINK" >&6; }
12796else
12797  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12798$as_echo "no" >&6; }
12799fi
12800
12801
12802  test -n "$READLINK" && break
12803done
12804
12805  else
12806    # The variable is set, but is it from the command line or the environment?
12807
12808    # Try to remove the string !READLINK! from our list.
12809    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/}
12810    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12811      # If it failed, the variable was not from the command line. Ignore it,
12812      # but warn the user (except for BASH, which is always set by the calling BASH).
12813      if test "xREADLINK" != xBASH; then
12814        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5
12815$as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;}
12816      fi
12817      # Try to locate tool using the code snippet
12818      for ac_prog in greadlink readlink
12819do
12820  # Extract the first word of "$ac_prog", so it can be a program name with args.
12821set dummy $ac_prog; ac_word=$2
12822{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12823$as_echo_n "checking for $ac_word... " >&6; }
12824if ${ac_cv_path_READLINK+:} false; then :
12825  $as_echo_n "(cached) " >&6
12826else
12827  case $READLINK in
12828  [\\/]* | ?:[\\/]*)
12829  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12830  ;;
12831  *)
12832  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12833for as_dir in $PATH
12834do
12835  IFS=$as_save_IFS
12836  test -z "$as_dir" && as_dir=.
12837    for ac_exec_ext in '' $ac_executable_extensions; do
12838  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12839    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12840    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12841    break 2
12842  fi
12843done
12844  done
12845IFS=$as_save_IFS
12846
12847  ;;
12848esac
12849fi
12850READLINK=$ac_cv_path_READLINK
12851if test -n "$READLINK"; then
12852  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12853$as_echo "$READLINK" >&6; }
12854else
12855  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12856$as_echo "no" >&6; }
12857fi
12858
12859
12860  test -n "$READLINK" && break
12861done
12862
12863    else
12864      # If it succeeded, then it was overridden by the user. We will use it
12865      # for the tool.
12866
12867      # First remove it from the list of overridden variables, so we can test
12868      # for unknown variables in the end.
12869      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12870
12871      # Check if the provided tool contains a complete path.
12872      tool_specified="$READLINK"
12873      tool_basename="${tool_specified##*/}"
12874      if test "x$tool_basename" = "x$tool_specified"; then
12875        # A command without a complete path is provided, search $PATH.
12876        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5
12877$as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;}
12878        # Extract the first word of "$tool_basename", so it can be a program name with args.
12879set dummy $tool_basename; ac_word=$2
12880{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12881$as_echo_n "checking for $ac_word... " >&6; }
12882if ${ac_cv_path_READLINK+:} false; then :
12883  $as_echo_n "(cached) " >&6
12884else
12885  case $READLINK in
12886  [\\/]* | ?:[\\/]*)
12887  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12888  ;;
12889  *)
12890  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12891for as_dir in $PATH
12892do
12893  IFS=$as_save_IFS
12894  test -z "$as_dir" && as_dir=.
12895    for ac_exec_ext in '' $ac_executable_extensions; do
12896  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12897    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12898    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12899    break 2
12900  fi
12901done
12902  done
12903IFS=$as_save_IFS
12904
12905  ;;
12906esac
12907fi
12908READLINK=$ac_cv_path_READLINK
12909if test -n "$READLINK"; then
12910  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12911$as_echo "$READLINK" >&6; }
12912else
12913  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12914$as_echo "no" >&6; }
12915fi
12916
12917
12918        if test "x$READLINK" = x; then
12919          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12920        fi
12921      else
12922        # Otherwise we believe it is a complete path. Use it as it is.
12923        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5
12924$as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;}
12925        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5
12926$as_echo_n "checking for READLINK... " >&6; }
12927        if test ! -x "$tool_specified"; then
12928          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12929$as_echo "not found" >&6; }
12930          as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5
12931        fi
12932        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12933$as_echo "$tool_specified" >&6; }
12934      fi
12935    fi
12936  fi
12937
12938
12939
12940
12941  # Publish this variable in the help.
12942
12943
12944  if test "x$DF" = x; then
12945    # The variable is not set by user, try to locate tool using the code snippet
12946    for ac_prog in df
12947do
12948  # Extract the first word of "$ac_prog", so it can be a program name with args.
12949set dummy $ac_prog; ac_word=$2
12950{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12951$as_echo_n "checking for $ac_word... " >&6; }
12952if ${ac_cv_path_DF+:} false; then :
12953  $as_echo_n "(cached) " >&6
12954else
12955  case $DF in
12956  [\\/]* | ?:[\\/]*)
12957  ac_cv_path_DF="$DF" # Let the user override the test with a path.
12958  ;;
12959  *)
12960  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12961for as_dir in $PATH
12962do
12963  IFS=$as_save_IFS
12964  test -z "$as_dir" && as_dir=.
12965    for ac_exec_ext in '' $ac_executable_extensions; do
12966  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12967    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12968    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12969    break 2
12970  fi
12971done
12972  done
12973IFS=$as_save_IFS
12974
12975  ;;
12976esac
12977fi
12978DF=$ac_cv_path_DF
12979if test -n "$DF"; then
12980  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12981$as_echo "$DF" >&6; }
12982else
12983  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12984$as_echo "no" >&6; }
12985fi
12986
12987
12988  test -n "$DF" && break
12989done
12990
12991  else
12992    # The variable is set, but is it from the command line or the environment?
12993
12994    # Try to remove the string !DF! from our list.
12995    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/}
12996    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12997      # If it failed, the variable was not from the command line. Ignore it,
12998      # but warn the user (except for BASH, which is always set by the calling BASH).
12999      if test "xDF" != xBASH; then
13000        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5
13001$as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;}
13002      fi
13003      # Try to locate tool using the code snippet
13004      for ac_prog in df
13005do
13006  # Extract the first word of "$ac_prog", so it can be a program name with args.
13007set dummy $ac_prog; ac_word=$2
13008{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13009$as_echo_n "checking for $ac_word... " >&6; }
13010if ${ac_cv_path_DF+:} false; then :
13011  $as_echo_n "(cached) " >&6
13012else
13013  case $DF in
13014  [\\/]* | ?:[\\/]*)
13015  ac_cv_path_DF="$DF" # Let the user override the test with a path.
13016  ;;
13017  *)
13018  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13019for as_dir in $PATH
13020do
13021  IFS=$as_save_IFS
13022  test -z "$as_dir" && as_dir=.
13023    for ac_exec_ext in '' $ac_executable_extensions; do
13024  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13025    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13026    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13027    break 2
13028  fi
13029done
13030  done
13031IFS=$as_save_IFS
13032
13033  ;;
13034esac
13035fi
13036DF=$ac_cv_path_DF
13037if test -n "$DF"; then
13038  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13039$as_echo "$DF" >&6; }
13040else
13041  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13042$as_echo "no" >&6; }
13043fi
13044
13045
13046  test -n "$DF" && break
13047done
13048
13049    else
13050      # If it succeeded, then it was overridden by the user. We will use it
13051      # for the tool.
13052
13053      # First remove it from the list of overridden variables, so we can test
13054      # for unknown variables in the end.
13055      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13056
13057      # Check if the provided tool contains a complete path.
13058      tool_specified="$DF"
13059      tool_basename="${tool_specified##*/}"
13060      if test "x$tool_basename" = "x$tool_specified"; then
13061        # A command without a complete path is provided, search $PATH.
13062        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5
13063$as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;}
13064        # Extract the first word of "$tool_basename", so it can be a program name with args.
13065set dummy $tool_basename; ac_word=$2
13066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13067$as_echo_n "checking for $ac_word... " >&6; }
13068if ${ac_cv_path_DF+:} false; then :
13069  $as_echo_n "(cached) " >&6
13070else
13071  case $DF in
13072  [\\/]* | ?:[\\/]*)
13073  ac_cv_path_DF="$DF" # Let the user override the test with a path.
13074  ;;
13075  *)
13076  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13077for as_dir in $PATH
13078do
13079  IFS=$as_save_IFS
13080  test -z "$as_dir" && as_dir=.
13081    for ac_exec_ext in '' $ac_executable_extensions; do
13082  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13083    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13084    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13085    break 2
13086  fi
13087done
13088  done
13089IFS=$as_save_IFS
13090
13091  ;;
13092esac
13093fi
13094DF=$ac_cv_path_DF
13095if test -n "$DF"; then
13096  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13097$as_echo "$DF" >&6; }
13098else
13099  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13100$as_echo "no" >&6; }
13101fi
13102
13103
13104        if test "x$DF" = x; then
13105          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13106        fi
13107      else
13108        # Otherwise we believe it is a complete path. Use it as it is.
13109        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5
13110$as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;}
13111        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5
13112$as_echo_n "checking for DF... " >&6; }
13113        if test ! -x "$tool_specified"; then
13114          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13115$as_echo "not found" >&6; }
13116          as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5
13117        fi
13118        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13119$as_echo "$tool_specified" >&6; }
13120      fi
13121    fi
13122  fi
13123
13124
13125
13126
13127  # Publish this variable in the help.
13128
13129
13130  if test "x$SETFILE" = x; then
13131    # The variable is not set by user, try to locate tool using the code snippet
13132    for ac_prog in SetFile
13133do
13134  # Extract the first word of "$ac_prog", so it can be a program name with args.
13135set dummy $ac_prog; ac_word=$2
13136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13137$as_echo_n "checking for $ac_word... " >&6; }
13138if ${ac_cv_path_SETFILE+:} false; then :
13139  $as_echo_n "(cached) " >&6
13140else
13141  case $SETFILE in
13142  [\\/]* | ?:[\\/]*)
13143  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13144  ;;
13145  *)
13146  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13147for as_dir in $PATH
13148do
13149  IFS=$as_save_IFS
13150  test -z "$as_dir" && as_dir=.
13151    for ac_exec_ext in '' $ac_executable_extensions; do
13152  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13153    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13154    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13155    break 2
13156  fi
13157done
13158  done
13159IFS=$as_save_IFS
13160
13161  ;;
13162esac
13163fi
13164SETFILE=$ac_cv_path_SETFILE
13165if test -n "$SETFILE"; then
13166  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13167$as_echo "$SETFILE" >&6; }
13168else
13169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13170$as_echo "no" >&6; }
13171fi
13172
13173
13174  test -n "$SETFILE" && break
13175done
13176
13177  else
13178    # The variable is set, but is it from the command line or the environment?
13179
13180    # Try to remove the string !SETFILE! from our list.
13181    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/}
13182    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13183      # If it failed, the variable was not from the command line. Ignore it,
13184      # but warn the user (except for BASH, which is always set by the calling BASH).
13185      if test "xSETFILE" != xBASH; then
13186        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5
13187$as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;}
13188      fi
13189      # Try to locate tool using the code snippet
13190      for ac_prog in SetFile
13191do
13192  # Extract the first word of "$ac_prog", so it can be a program name with args.
13193set dummy $ac_prog; ac_word=$2
13194{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13195$as_echo_n "checking for $ac_word... " >&6; }
13196if ${ac_cv_path_SETFILE+:} false; then :
13197  $as_echo_n "(cached) " >&6
13198else
13199  case $SETFILE in
13200  [\\/]* | ?:[\\/]*)
13201  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13202  ;;
13203  *)
13204  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13205for as_dir in $PATH
13206do
13207  IFS=$as_save_IFS
13208  test -z "$as_dir" && as_dir=.
13209    for ac_exec_ext in '' $ac_executable_extensions; do
13210  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13211    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13212    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13213    break 2
13214  fi
13215done
13216  done
13217IFS=$as_save_IFS
13218
13219  ;;
13220esac
13221fi
13222SETFILE=$ac_cv_path_SETFILE
13223if test -n "$SETFILE"; then
13224  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13225$as_echo "$SETFILE" >&6; }
13226else
13227  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13228$as_echo "no" >&6; }
13229fi
13230
13231
13232  test -n "$SETFILE" && break
13233done
13234
13235    else
13236      # If it succeeded, then it was overridden by the user. We will use it
13237      # for the tool.
13238
13239      # First remove it from the list of overridden variables, so we can test
13240      # for unknown variables in the end.
13241      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13242
13243      # Check if the provided tool contains a complete path.
13244      tool_specified="$SETFILE"
13245      tool_basename="${tool_specified##*/}"
13246      if test "x$tool_basename" = "x$tool_specified"; then
13247        # A command without a complete path is provided, search $PATH.
13248        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5
13249$as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;}
13250        # Extract the first word of "$tool_basename", so it can be a program name with args.
13251set dummy $tool_basename; ac_word=$2
13252{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13253$as_echo_n "checking for $ac_word... " >&6; }
13254if ${ac_cv_path_SETFILE+:} false; then :
13255  $as_echo_n "(cached) " >&6
13256else
13257  case $SETFILE in
13258  [\\/]* | ?:[\\/]*)
13259  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13260  ;;
13261  *)
13262  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13263for as_dir in $PATH
13264do
13265  IFS=$as_save_IFS
13266  test -z "$as_dir" && as_dir=.
13267    for ac_exec_ext in '' $ac_executable_extensions; do
13268  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13269    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13270    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13271    break 2
13272  fi
13273done
13274  done
13275IFS=$as_save_IFS
13276
13277  ;;
13278esac
13279fi
13280SETFILE=$ac_cv_path_SETFILE
13281if test -n "$SETFILE"; then
13282  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13283$as_echo "$SETFILE" >&6; }
13284else
13285  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13286$as_echo "no" >&6; }
13287fi
13288
13289
13290        if test "x$SETFILE" = x; then
13291          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13292        fi
13293      else
13294        # Otherwise we believe it is a complete path. Use it as it is.
13295        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5
13296$as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;}
13297        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5
13298$as_echo_n "checking for SETFILE... " >&6; }
13299        if test ! -x "$tool_specified"; then
13300          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13301$as_echo "not found" >&6; }
13302          as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5
13303        fi
13304        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13305$as_echo "$tool_specified" >&6; }
13306      fi
13307    fi
13308  fi
13309
13310
13311
13312
13313# Now we can determine OpenJDK build and target platforms. This is required to
13314# have early on.
13315# Make sure we can run config.sub.
13316$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
13317  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
13318
13319{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
13320$as_echo_n "checking build system type... " >&6; }
13321if ${ac_cv_build+:} false; then :
13322  $as_echo_n "(cached) " >&6
13323else
13324  ac_build_alias=$build_alias
13325test "x$ac_build_alias" = x &&
13326  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
13327test "x$ac_build_alias" = x &&
13328  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
13329ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
13330  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
13331
13332fi
13333{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
13334$as_echo "$ac_cv_build" >&6; }
13335case $ac_cv_build in
13336*-*-*) ;;
13337*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
13338esac
13339build=$ac_cv_build
13340ac_save_IFS=$IFS; IFS='-'
13341set x $ac_cv_build
13342shift
13343build_cpu=$1
13344build_vendor=$2
13345shift; shift
13346# Remember, the first character of IFS is used to create $*,
13347# except with old shells:
13348build_os=$*
13349IFS=$ac_save_IFS
13350case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
13351
13352
13353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
13354$as_echo_n "checking host system type... " >&6; }
13355if ${ac_cv_host+:} false; then :
13356  $as_echo_n "(cached) " >&6
13357else
13358  if test "x$host_alias" = x; then
13359  ac_cv_host=$ac_cv_build
13360else
13361  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
13362    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
13363fi
13364
13365fi
13366{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
13367$as_echo "$ac_cv_host" >&6; }
13368case $ac_cv_host in
13369*-*-*) ;;
13370*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
13371esac
13372host=$ac_cv_host
13373ac_save_IFS=$IFS; IFS='-'
13374set x $ac_cv_host
13375shift
13376host_cpu=$1
13377host_vendor=$2
13378shift; shift
13379# Remember, the first character of IFS is used to create $*,
13380# except with old shells:
13381host_os=$*
13382IFS=$ac_save_IFS
13383case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
13384
13385
13386{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
13387$as_echo_n "checking target system type... " >&6; }
13388if ${ac_cv_target+:} false; then :
13389  $as_echo_n "(cached) " >&6
13390else
13391  if test "x$target_alias" = x; then
13392  ac_cv_target=$ac_cv_host
13393else
13394  ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
13395    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
13396fi
13397
13398fi
13399{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
13400$as_echo "$ac_cv_target" >&6; }
13401case $ac_cv_target in
13402*-*-*) ;;
13403*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
13404esac
13405target=$ac_cv_target
13406ac_save_IFS=$IFS; IFS='-'
13407set x $ac_cv_target
13408shift
13409target_cpu=$1
13410target_vendor=$2
13411shift; shift
13412# Remember, the first character of IFS is used to create $*,
13413# except with old shells:
13414target_os=$*
13415IFS=$ac_save_IFS
13416case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
13417
13418
13419# The aliases save the names the user supplied, while $host etc.
13420# will get canonicalized.
13421test -n "$target_alias" &&
13422  test "$program_prefix$program_suffix$program_transform_name" = \
13423    NONENONEs,x,x, &&
13424  program_prefix=${target_alias}-
13425
13426  # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target"
13427  # is confusing; it assumes you are cross-compiling a cross-compiler (!)  and "target" is thus the target of the
13428  # product you're building. The target of this build is called "host". Since this is confusing to most people, we
13429  # have not adopted that system, but use "target" as the platform we are building for. In some places though we need
13430  # to use the configure naming style.
13431
13432
13433
13434
13435
13436  # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME
13437  # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME
13438  # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build,
13439  # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME.
13440  OPENJDK_TARGET_AUTOCONF_NAME="$host"
13441  OPENJDK_BUILD_AUTOCONF_NAME="$build"
13442
13443
13444
13445  # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13446
13447  case "$build_os" in
13448    *linux*)
13449      VAR_OS=linux
13450      VAR_OS_API=posix
13451      VAR_OS_ENV=linux
13452      ;;
13453    *solaris*)
13454      VAR_OS=solaris
13455      VAR_OS_API=posix
13456      VAR_OS_ENV=solaris
13457      ;;
13458    *darwin*)
13459      VAR_OS=macosx
13460      VAR_OS_API=posix
13461      VAR_OS_ENV=macosx
13462      ;;
13463    *bsd*)
13464      VAR_OS=bsd
13465      VAR_OS_API=posix
13466      VAR_OS_ENV=bsd
13467      ;;
13468    *cygwin*)
13469      VAR_OS=windows
13470      VAR_OS_API=winapi
13471      VAR_OS_ENV=windows.cygwin
13472      ;;
13473    *mingw*)
13474      VAR_OS=windows
13475      VAR_OS_API=winapi
13476      VAR_OS_ENV=windows.msys
13477      ;;
13478    *aix*)
13479      VAR_OS=aix
13480      VAR_OS_API=posix
13481      VAR_OS_ENV=aix
13482      ;;
13483    *)
13484      as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
13485      ;;
13486  esac
13487
13488
13489  # First argument is the cpu name from the trip/quad
13490  case "$build_cpu" in
13491    x86_64)
13492      VAR_CPU=x86_64
13493      VAR_CPU_ARCH=x86
13494      VAR_CPU_BITS=64
13495      VAR_CPU_ENDIAN=little
13496      ;;
13497    i?86)
13498      VAR_CPU=x86
13499      VAR_CPU_ARCH=x86
13500      VAR_CPU_BITS=32
13501      VAR_CPU_ENDIAN=little
13502      ;;
13503    arm*)
13504      VAR_CPU=arm
13505      VAR_CPU_ARCH=arm
13506      VAR_CPU_BITS=32
13507      VAR_CPU_ENDIAN=little
13508      ;;
13509    powerpc)
13510      VAR_CPU=ppc
13511      VAR_CPU_ARCH=ppc
13512      VAR_CPU_BITS=32
13513      VAR_CPU_ENDIAN=big
13514      ;;
13515    powerpc64)
13516      VAR_CPU=ppc64
13517      VAR_CPU_ARCH=ppc
13518      VAR_CPU_BITS=64
13519      VAR_CPU_ENDIAN=big
13520      ;;
13521    s390)
13522      VAR_CPU=s390
13523      VAR_CPU_ARCH=s390
13524      VAR_CPU_BITS=32
13525      VAR_CPU_ENDIAN=big
13526      ;;
13527    s390x)
13528      VAR_CPU=s390x
13529      VAR_CPU_ARCH=s390
13530      VAR_CPU_BITS=64
13531      VAR_CPU_ENDIAN=big
13532      ;;
13533    sparc)
13534      VAR_CPU=sparc
13535      VAR_CPU_ARCH=sparc
13536      VAR_CPU_BITS=32
13537      VAR_CPU_ENDIAN=big
13538      ;;
13539    sparcv9)
13540      VAR_CPU=sparcv9
13541      VAR_CPU_ARCH=sparc
13542      VAR_CPU_BITS=64
13543      VAR_CPU_ENDIAN=big
13544      ;;
13545    *)
13546      as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5
13547      ;;
13548  esac
13549
13550  # ..and setup our own variables. (Do this explicitely to facilitate searching)
13551  OPENJDK_BUILD_OS="$VAR_OS"
13552  OPENJDK_BUILD_OS_API="$VAR_OS_API"
13553  OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV"
13554  OPENJDK_BUILD_CPU="$VAR_CPU"
13555  OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH"
13556  OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS"
13557  OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13558
13559
13560
13561
13562
13563
13564
13565  { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5
13566$as_echo_n "checking openjdk-build os-cpu... " >&6; }
13567  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5
13568$as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; }
13569
13570  # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13571
13572  case "$host_os" in
13573    *linux*)
13574      VAR_OS=linux
13575      VAR_OS_API=posix
13576      VAR_OS_ENV=linux
13577      ;;
13578    *solaris*)
13579      VAR_OS=solaris
13580      VAR_OS_API=posix
13581      VAR_OS_ENV=solaris
13582      ;;
13583    *darwin*)
13584      VAR_OS=macosx
13585      VAR_OS_API=posix
13586      VAR_OS_ENV=macosx
13587      ;;
13588    *bsd*)
13589      VAR_OS=bsd
13590      VAR_OS_API=posix
13591      VAR_OS_ENV=bsd
13592      ;;
13593    *cygwin*)
13594      VAR_OS=windows
13595      VAR_OS_API=winapi
13596      VAR_OS_ENV=windows.cygwin
13597      ;;
13598    *mingw*)
13599      VAR_OS=windows
13600      VAR_OS_API=winapi
13601      VAR_OS_ENV=windows.msys
13602      ;;
13603    *aix*)
13604      VAR_OS=aix
13605      VAR_OS_API=posix
13606      VAR_OS_ENV=aix
13607      ;;
13608    *)
13609      as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
13610      ;;
13611  esac
13612
13613
13614  # First argument is the cpu name from the trip/quad
13615  case "$host_cpu" in
13616    x86_64)
13617      VAR_CPU=x86_64
13618      VAR_CPU_ARCH=x86
13619      VAR_CPU_BITS=64
13620      VAR_CPU_ENDIAN=little
13621      ;;
13622    i?86)
13623      VAR_CPU=x86
13624      VAR_CPU_ARCH=x86
13625      VAR_CPU_BITS=32
13626      VAR_CPU_ENDIAN=little
13627      ;;
13628    arm*)
13629      VAR_CPU=arm
13630      VAR_CPU_ARCH=arm
13631      VAR_CPU_BITS=32
13632      VAR_CPU_ENDIAN=little
13633      ;;
13634    powerpc)
13635      VAR_CPU=ppc
13636      VAR_CPU_ARCH=ppc
13637      VAR_CPU_BITS=32
13638      VAR_CPU_ENDIAN=big
13639      ;;
13640    powerpc64)
13641      VAR_CPU=ppc64
13642      VAR_CPU_ARCH=ppc
13643      VAR_CPU_BITS=64
13644      VAR_CPU_ENDIAN=big
13645      ;;
13646    s390)
13647      VAR_CPU=s390
13648      VAR_CPU_ARCH=s390
13649      VAR_CPU_BITS=32
13650      VAR_CPU_ENDIAN=big
13651      ;;
13652    s390x)
13653      VAR_CPU=s390x
13654      VAR_CPU_ARCH=s390
13655      VAR_CPU_BITS=64
13656      VAR_CPU_ENDIAN=big
13657      ;;
13658    sparc)
13659      VAR_CPU=sparc
13660      VAR_CPU_ARCH=sparc
13661      VAR_CPU_BITS=32
13662      VAR_CPU_ENDIAN=big
13663      ;;
13664    sparcv9)
13665      VAR_CPU=sparcv9
13666      VAR_CPU_ARCH=sparc
13667      VAR_CPU_BITS=64
13668      VAR_CPU_ENDIAN=big
13669      ;;
13670    *)
13671      as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5
13672      ;;
13673  esac
13674
13675  # ... and setup our own variables. (Do this explicitely to facilitate searching)
13676  OPENJDK_TARGET_OS="$VAR_OS"
13677  OPENJDK_TARGET_OS_API="$VAR_OS_API"
13678  OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV"
13679  OPENJDK_TARGET_CPU="$VAR_CPU"
13680  OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH"
13681  OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS"
13682  OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13683
13684
13685
13686
13687
13688
13689
13690  { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5
13691$as_echo_n "checking openjdk-target os-cpu... " >&6; }
13692  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5
13693$as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; }
13694
13695
13696
13697# Check whether --with-target-bits was given.
13698if test "${with_target_bits+set}" = set; then :
13699  withval=$with_target_bits;
13700fi
13701
13702
13703  # We have three types of compiles:
13704  # native  == normal compilation, target system == build system
13705  # cross   == traditional cross compilation, target system != build system; special toolchain needed
13706  # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines
13707  #
13708  if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then
13709    # We're doing a proper cross-compilation
13710    COMPILE_TYPE="cross"
13711  else
13712    COMPILE_TYPE="native"
13713  fi
13714
13715  if test "x$with_target_bits" != x; then
13716    if test "x$COMPILE_TYPE" = "xcross"; then
13717      as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5
13718    fi
13719
13720    if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13721      # A reduced build is requested
13722      COMPILE_TYPE="reduced"
13723      OPENJDK_TARGET_CPU_BITS=32
13724      if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
13725        OPENJDK_TARGET_CPU=x86
13726      elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
13727        OPENJDK_TARGET_CPU=sparc
13728      else
13729        as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5
13730      fi
13731    elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
13732      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
13733    elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then
13734      { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5
13735$as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;}
13736    else
13737      as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5
13738    fi
13739  fi
13740
13741
13742  { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5
13743$as_echo_n "checking compilation type... " >&6; }
13744  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5
13745$as_echo "$COMPILE_TYPE" >&6; }
13746
13747
13748  if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
13749    REQUIRED_OS_NAME=SunOS
13750    REQUIRED_OS_VERSION=5.10
13751  fi
13752  if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
13753    REQUIRED_OS_NAME=Linux
13754    REQUIRED_OS_VERSION=2.6
13755  fi
13756  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13757    REQUIRED_OS_NAME=Windows
13758    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
13759      REQUIRED_OS_VERSION=5.2
13760    else
13761      REQUIRED_OS_VERSION=5.1
13762    fi
13763  fi
13764  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
13765    REQUIRED_OS_NAME=Darwin
13766    REQUIRED_OS_VERSION=11.2
13767  fi
13768
13769
13770
13771
13772
13773  # Also store the legacy naming of the cpu.
13774  # Ie i586 and amd64 instead of x86 and x86_64
13775  OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU"
13776  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13777    OPENJDK_TARGET_CPU_LEGACY="i586"
13778  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13779    # On all platforms except MacOSX replace x86_64 with amd64.
13780    OPENJDK_TARGET_CPU_LEGACY="amd64"
13781  fi
13782
13783
13784  # And the second legacy naming of the cpu.
13785  # Ie i386 and amd64 instead of x86 and x86_64.
13786  OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU"
13787  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13788    OPENJDK_TARGET_CPU_LEGACY_LIB="i386"
13789  elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13790    OPENJDK_TARGET_CPU_LEGACY_LIB="amd64"
13791  fi
13792
13793
13794  # This is the name of the cpu (but using i386 and amd64 instead of
13795  # x86 and x86_64, respectively), preceeded by a /, to be used when
13796  # locating libraries. On macosx, it's empty, though.
13797  OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB"
13798  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13799    OPENJDK_TARGET_CPU_LIBDIR=""
13800  fi
13801
13802
13803  # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to
13804  # /amd64 or /sparcv9. This string is appended to some library paths, like this:
13805  # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so
13806  OPENJDK_TARGET_CPU_ISADIR=""
13807  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13808    if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13809      OPENJDK_TARGET_CPU_ISADIR="/amd64"
13810    elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then
13811      OPENJDK_TARGET_CPU_ISADIR="/sparcv9"
13812    fi
13813  fi
13814
13815
13816  # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property
13817  OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU"
13818  if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then
13819    # On linux only, we replace x86 with i386.
13820    OPENJDK_TARGET_CPU_OSARCH="i386"
13821  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13822    # On all platforms except macosx, we replace x86_64 with amd64.
13823    OPENJDK_TARGET_CPU_OSARCH="amd64"
13824  fi
13825
13826
13827  OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU"
13828  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13829    OPENJDK_TARGET_CPU_JLI="i386"
13830  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13831    # On all platforms except macosx, we replace x86_64 with amd64.
13832    OPENJDK_TARGET_CPU_JLI="amd64"
13833  fi
13834  # Now setup the -D flags for building libjli.
13835  OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'"
13836  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13837    if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then
13838      OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'"
13839    elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
13840      OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'"
13841    fi
13842  fi
13843
13844
13845  # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths.
13846  if test "x$OPENJDK_TARGET_OS_API" = xposix; then
13847    OPENJDK_TARGET_OS_API_DIR="solaris"
13848  fi
13849  if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then
13850    OPENJDK_TARGET_OS_API_DIR="windows"
13851  fi
13852
13853
13854  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13855      OPENJDK_TARGET_OS_EXPORT_DIR=macosx
13856  else
13857      OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_API_DIR}
13858  fi
13859
13860
13861  if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13862    A_LP64="LP64:="
13863    # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
13864    # unpack200.exe
13865    if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then
13866      ADD_LP64="-D_LP64=1"
13867    fi
13868  fi
13869  LP64=$A_LP64
13870
13871
13872  if test "x$COMPILE_TYPE" = "xcross"; then
13873    # FIXME: ... or should this include reduced builds..?
13874    DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY"
13875  else
13876    DEFINE_CROSS_COMPILE_ARCH=""
13877  fi
13878
13879
13880  # ZERO_ARCHDEF is used to enable architecture-specific code
13881  case "${OPENJDK_TARGET_CPU}" in
13882    ppc*)    ZERO_ARCHDEF=PPC   ;;
13883    s390*)   ZERO_ARCHDEF=S390  ;;
13884    sparc*)  ZERO_ARCHDEF=SPARC ;;
13885    x86_64*) ZERO_ARCHDEF=AMD64 ;;
13886    x86)     ZERO_ARCHDEF=IA32  ;;
13887    *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
13888  esac
13889
13890
13891
13892
13893# Continue setting up basic stuff. Most remaining code require fundamental tools.
13894
13895  # Save the current directory this script was started from
13896  CURDIR="$PWD"
13897
13898  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13899    PATH_SEP=";"
13900
13901  SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m`
13902  if test $SRC_ROOT_LENGTH -gt 100; then
13903    as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5
13904  fi
13905
13906  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13907    { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5
13908$as_echo_n "checking cygwin release... " >&6; }
13909    CYGWIN_VERSION=`$UNAME -r`
13910    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5
13911$as_echo "$CYGWIN_VERSION" >&6; }
13912    WINDOWS_ENV_VENDOR='cygwin'
13913    WINDOWS_ENV_VERSION="$CYGWIN_VERSION"
13914
13915    CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.`
13916    if test "x$CYGWIN_VERSION_OK" = x; then
13917      { $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
13918$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;}
13919      as_fn_error $? "Cannot continue" "$LINENO" 5
13920    fi
13921    if test "x$CYGPATH" = x; then
13922      as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5
13923    fi
13924    { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5
13925$as_echo_n "checking cygwin root directory as unix-style path... " >&6; }
13926    # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
13927    cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"`
13928    # Force cygpath to report the proper root by including a trailing space, and then stripping it off again.
13929    CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "`
13930    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5
13931$as_echo "$CYGWIN_ROOT_PATH" >&6; }
13932    WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH"
13933    test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/`
13934    if test "x$test_cygdrive_prefix" = x; then
13935      as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5
13936    fi
13937  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13938    { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5
13939$as_echo_n "checking msys release... " >&6; }
13940    MSYS_VERSION=`$UNAME -r`
13941    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5
13942$as_echo "$MSYS_VERSION" >&6; }
13943
13944    WINDOWS_ENV_VENDOR='msys'
13945    WINDOWS_ENV_VERSION="$MSYS_VERSION"
13946
13947    { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5
13948$as_echo_n "checking msys root directory as unix-style path... " >&6; }
13949    # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
13950    MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"`
13951
13952  windows_path="$MSYS_ROOT_PATH"
13953  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13954    unix_path=`$CYGPATH -u "$windows_path"`
13955    MSYS_ROOT_PATH="$unix_path"
13956  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13957    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
13958    MSYS_ROOT_PATH="$unix_path"
13959  fi
13960
13961    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5
13962$as_echo "$MSYS_ROOT_PATH" >&6; }
13963    WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH"
13964  else
13965    as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5
13966  fi
13967
13968  # Test if windows or unix (cygwin/msys) find is first in path.
13969  { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5
13970$as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; }
13971  FIND_BINARY_OUTPUT=`find --version 2>&1`
13972  if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then
13973    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5
13974$as_echo "unix style" >&6; }
13975  elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then
13976    { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5
13977$as_echo "Windows" >&6; }
13978    { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5
13979$as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;}
13980    { $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
13981$as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;}
13982    as_fn_error $? "Cannot continue" "$LINENO" 5
13983  else
13984    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
13985$as_echo "unknown" >&6; }
13986    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5
13987$as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;}
13988  fi
13989
13990  else
13991    PATH_SEP=":"
13992  fi
13993
13994
13995  # We get the top-level directory from the supporting wrappers.
13996  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5
13997$as_echo_n "checking for top-level directory... " >&6; }
13998  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5
13999$as_echo "$TOPDIR" >&6; }
14000
14001
14002  # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS.
14003
14004  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14005
14006  # Input might be given as Windows format, start by converting to
14007  # unix format.
14008  path="$CURDIR"
14009  new_path=`$CYGPATH -u "$path"`
14010
14011  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14012  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14013  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14014  # "foo.exe" is OK but "foo" is an error.
14015  #
14016  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14017  # It is also a way to make sure we got the proper file name for the real test later on.
14018  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14019  if test "x$test_shortpath" = x; then
14020    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14021$as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14022    as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5
14023  fi
14024
14025  # Call helper function which possibly converts this using DOS-style short mode.
14026  # If so, the updated path is stored in $new_path.
14027
14028  input_path="$new_path"
14029  # Check if we need to convert this using DOS-style short mode. If the path
14030  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14031  # take no chances and rewrite it.
14032  # Note: m4 eats our [], so we need to use [ and ] instead.
14033  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14034  if test "x$has_forbidden_chars" != x; then
14035    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14036    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14037    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14038    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14039      # Going to short mode and back again did indeed matter. Since short mode is
14040      # case insensitive, let's make it lowercase to improve readability.
14041      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14042      # Now convert it back to Unix-stile (cygpath)
14043      input_path=`$CYGPATH -u "$shortmode_path"`
14044      new_path="$input_path"
14045    fi
14046  fi
14047
14048  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14049  if test "x$test_cygdrive_prefix" = x; then
14050    # As a simple fix, exclude /usr/bin since it's not a real path.
14051    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14052      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14053      # a path prefixed by /cygdrive for fixpath to work.
14054      new_path="$CYGWIN_ROOT_PATH$input_path"
14055    fi
14056  fi
14057
14058
14059  if test "x$path" != "x$new_path"; then
14060    CURDIR="$new_path"
14061    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14062$as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14063  fi
14064
14065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14066
14067  path="$CURDIR"
14068  has_colon=`$ECHO $path | $GREP ^.:`
14069  new_path="$path"
14070  if test "x$has_colon" = x; then
14071    # Not in mixed or Windows style, start by that.
14072    new_path=`cmd //c echo $path`
14073  fi
14074
14075
14076  input_path="$new_path"
14077  # Check if we need to convert this using DOS-style short mode. If the path
14078  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14079  # take no chances and rewrite it.
14080  # Note: m4 eats our [], so we need to use [ and ] instead.
14081  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14082  if test "x$has_forbidden_chars" != x; then
14083    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14084    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14085  fi
14086
14087
14088  windows_path="$new_path"
14089  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14090    unix_path=`$CYGPATH -u "$windows_path"`
14091    new_path="$unix_path"
14092  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14093    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14094    new_path="$unix_path"
14095  fi
14096
14097  if test "x$path" != "x$new_path"; then
14098    CURDIR="$new_path"
14099    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14100$as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14101  fi
14102
14103  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14104  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14105
14106  else
14107    # We're on a posix platform. Hooray! :)
14108    path="$CURDIR"
14109    has_space=`$ECHO "$path" | $GREP " "`
14110    if test "x$has_space" != x; then
14111      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14112$as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14113      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14114    fi
14115
14116    # Use eval to expand a potential ~
14117    eval path="$path"
14118    if test ! -f "$path" && test ! -d "$path"; then
14119      as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14120    fi
14121
14122    CURDIR="`cd "$path"; $THEPWDCMD -L`"
14123  fi
14124
14125
14126  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14127
14128  # Input might be given as Windows format, start by converting to
14129  # unix format.
14130  path="$TOPDIR"
14131  new_path=`$CYGPATH -u "$path"`
14132
14133  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14134  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14135  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14136  # "foo.exe" is OK but "foo" is an error.
14137  #
14138  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14139  # It is also a way to make sure we got the proper file name for the real test later on.
14140  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14141  if test "x$test_shortpath" = x; then
14142    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14143$as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14144    as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5
14145  fi
14146
14147  # Call helper function which possibly converts this using DOS-style short mode.
14148  # If so, the updated path is stored in $new_path.
14149
14150  input_path="$new_path"
14151  # Check if we need to convert this using DOS-style short mode. If the path
14152  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14153  # take no chances and rewrite it.
14154  # Note: m4 eats our [], so we need to use [ and ] instead.
14155  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14156  if test "x$has_forbidden_chars" != x; then
14157    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14158    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14159    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14160    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14161      # Going to short mode and back again did indeed matter. Since short mode is
14162      # case insensitive, let's make it lowercase to improve readability.
14163      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14164      # Now convert it back to Unix-stile (cygpath)
14165      input_path=`$CYGPATH -u "$shortmode_path"`
14166      new_path="$input_path"
14167    fi
14168  fi
14169
14170  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14171  if test "x$test_cygdrive_prefix" = x; then
14172    # As a simple fix, exclude /usr/bin since it's not a real path.
14173    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14174      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14175      # a path prefixed by /cygdrive for fixpath to work.
14176      new_path="$CYGWIN_ROOT_PATH$input_path"
14177    fi
14178  fi
14179
14180
14181  if test "x$path" != "x$new_path"; then
14182    TOPDIR="$new_path"
14183    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
14184$as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
14185  fi
14186
14187  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14188
14189  path="$TOPDIR"
14190  has_colon=`$ECHO $path | $GREP ^.:`
14191  new_path="$path"
14192  if test "x$has_colon" = x; then
14193    # Not in mixed or Windows style, start by that.
14194    new_path=`cmd //c echo $path`
14195  fi
14196
14197
14198  input_path="$new_path"
14199  # Check if we need to convert this using DOS-style short mode. If the path
14200  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14201  # take no chances and rewrite it.
14202  # Note: m4 eats our [], so we need to use [ and ] instead.
14203  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14204  if test "x$has_forbidden_chars" != x; then
14205    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14206    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14207  fi
14208
14209
14210  windows_path="$new_path"
14211  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14212    unix_path=`$CYGPATH -u "$windows_path"`
14213    new_path="$unix_path"
14214  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14215    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14216    new_path="$unix_path"
14217  fi
14218
14219  if test "x$path" != "x$new_path"; then
14220    TOPDIR="$new_path"
14221    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
14222$as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
14223  fi
14224
14225  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14226  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14227
14228  else
14229    # We're on a posix platform. Hooray! :)
14230    path="$TOPDIR"
14231    has_space=`$ECHO "$path" | $GREP " "`
14232    if test "x$has_space" != x; then
14233      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14234$as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14235      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14236    fi
14237
14238    # Use eval to expand a potential ~
14239    eval path="$path"
14240    if test ! -f "$path" && test ! -d "$path"; then
14241      as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14242    fi
14243
14244    TOPDIR="`cd "$path"; $THEPWDCMD -L`"
14245  fi
14246
14247  # SRC_ROOT is a traditional alias for TOPDIR.
14248  SRC_ROOT=$TOPDIR
14249
14250  # Locate the directory of this script.
14251  AUTOCONF_DIR=$TOPDIR/common/autoconf
14252
14253
14254  # Setup default logging of stdout and stderr to build.log in the output root.
14255  BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14256  BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14257  BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14258
14259
14260
14261
14262
14263# Check if it's a pure open build or if custom sources are to be used.
14264
14265  # Check whether --enable-openjdk-only was given.
14266if test "${enable_openjdk_only+set}" = set; then :
14267  enableval=$enable_openjdk_only;
14268else
14269  enable_openjdk_only="no"
14270fi
14271
14272
14273  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5
14274$as_echo_n "checking for presence of closed sources... " >&6; }
14275  if test -d "$SRC_ROOT/jdk/src/closed"; then
14276    CLOSED_SOURCE_PRESENT=yes
14277  else
14278    CLOSED_SOURCE_PRESENT=no
14279  fi
14280  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5
14281$as_echo "$CLOSED_SOURCE_PRESENT" >&6; }
14282
14283  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5
14284$as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; }
14285  SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only"
14286  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5
14287$as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; }
14288
14289  if test "x$CLOSED_SOURCE_PRESENT" = xno; then
14290    OPENJDK=true
14291    if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14292      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5
14293$as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;}
14294    fi
14295  else
14296    if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14297      OPENJDK=true
14298    else
14299      OPENJDK=false
14300    fi
14301  fi
14302
14303  if test "x$OPENJDK" = "xtrue"; then
14304    SET_OPENJDK="OPENJDK=true"
14305  fi
14306
14307
14308
14309  # custom-make-dir is deprecated. Please use your custom-hook.m4 to override
14310  # the IncludeCustomExtension macro.
14311
14312
14313# Check whether --with-custom-make-dir was given.
14314if test "${with_custom_make_dir+set}" = set; then :
14315  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
14316$as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;}
14317fi
14318
14319
14320
14321
14322# These are needed to be able to create a configuration name (and thus the output directory)
14323
14324  ###############################################################################
14325  #
14326  # Check which variant of the JDK that we want to build.
14327  # Currently we have:
14328  #    normal:   standard edition
14329  # but the custom make system may add other variants
14330  #
14331  # Effectively the JDK variant gives a name to a specific set of
14332  # modules to compile into the JDK. In the future, these modules
14333  # might even be Jigsaw modules.
14334  #
14335  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5
14336$as_echo_n "checking which variant of the JDK to build... " >&6; }
14337
14338# Check whether --with-jdk-variant was given.
14339if test "${with_jdk_variant+set}" = set; then :
14340  withval=$with_jdk_variant;
14341fi
14342
14343
14344  if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then
14345    JDK_VARIANT="normal"
14346  else
14347    as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5
14348  fi
14349
14350
14351
14352  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5
14353$as_echo "$JDK_VARIANT" >&6; }
14354
14355
14356###############################################################################
14357#
14358# Check which interpreter of the JVM we want to build.
14359# Currently we have:
14360#    template: Template interpreter (the default)
14361#    cpp     : C++ interpreter
14362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5
14363$as_echo_n "checking which interpreter of the JVM to build... " >&6; }
14364
14365# Check whether --with-jvm-interpreter was given.
14366if test "${with_jvm_interpreter+set}" = set; then :
14367  withval=$with_jvm_interpreter;
14368fi
14369
14370
14371if test "x$with_jvm_interpreter" = x; then
14372     with_jvm_interpreter="template"
14373fi
14374
14375JVM_INTERPRETER="$with_jvm_interpreter"
14376
14377if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then
14378   as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5
14379fi
14380
14381
14382
14383{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_interpreter" >&5
14384$as_echo "$with_jvm_interpreter" >&6; }
14385
14386
14387
14388  ###############################################################################
14389  #
14390  # Check which variants of the JVM that we want to build.
14391  # Currently we have:
14392  #    server: normal interpreter and a tiered C1/C2 compiler
14393  #    client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms)
14394  #    minimal1: reduced form of client with optional VM services and features stripped out
14395  #    kernel: kernel footprint JVM that passes the TCK without major performance problems,
14396  #             ie normal interpreter and C1, only the serial GC, kernel jvmti etc
14397  #    zero: no machine code interpreter, no compiler
14398  #    zeroshark: zero interpreter and shark/llvm compiler backend
14399#    core: interpreter only, no compiler (only works on some platforms)
14400  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5
14401$as_echo_n "checking which variants of the JVM to build... " >&6; }
14402
14403# Check whether --with-jvm-variants was given.
14404if test "${with_jvm_variants+set}" = set; then :
14405  withval=$with_jvm_variants;
14406fi
14407
14408
14409  if test "x$with_jvm_variants" = x; then
14410    with_jvm_variants="server"
14411  fi
14412
14413  JVM_VARIANTS=",$with_jvm_variants,"
14414  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,//'`
14415
14416  if test "x$TEST_VARIANTS" != "x,"; then
14417     as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark, core" "$LINENO" 5
14418  fi
14419  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5
14420$as_echo "$with_jvm_variants" >&6; }
14421
14422  JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
14423  JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
14424  JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'`
14425  JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'`
14426  JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
14427  JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
14428  JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
14429
14430  if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14431    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14432      as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5
14433    fi
14434  fi
14435  if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14436    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14437      as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5
14438    fi
14439  fi
14440  if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14441    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14442      as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5
14443    fi
14444  fi
14445
14446  # Replace the commas with AND for use in the build directory name.
14447  ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'`
14448  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/'`
14449  if test "x$COUNT_VARIANTS" != "x,1"; then
14450    BUILDING_MULTIPLE_JVM_VARIANTS=yes
14451  else
14452    BUILDING_MULTIPLE_JVM_VARIANTS=no
14453  fi
14454
14455
14456
14457
14458
14459
14460
14461
14462
14463
14464  INCLUDE_SA=true
14465  if test "x$JVM_VARIANT_ZERO" = xtrue ; then
14466    INCLUDE_SA=false
14467  fi
14468  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then
14469    INCLUDE_SA=false
14470  fi
14471  if test "x$VAR_CPU" = xppc64 ; then
14472    INCLUDE_SA=false
14473  fi
14474
14475
14476  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
14477    MACOSX_UNIVERSAL="true"
14478  fi
14479
14480
14481
14482
14483  ###############################################################################
14484  #
14485  # Set the debug level
14486  #    release: no debug information, all optimizations, no asserts.
14487  #    optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'.
14488  #    fastdebug: debug information (-g), all optimizations, all asserts
14489  #    slowdebug: debug information (-g), no optimizations, all asserts
14490  #
14491  DEBUG_LEVEL="release"
14492  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5
14493$as_echo_n "checking which debug level to use... " >&6; }
14494  # Check whether --enable-debug was given.
14495if test "${enable_debug+set}" = set; then :
14496  enableval=$enable_debug;
14497        ENABLE_DEBUG="${enableval}"
14498        DEBUG_LEVEL="fastdebug"
14499
14500else
14501  ENABLE_DEBUG="no"
14502fi
14503
14504
14505
14506# Check whether --with-debug-level was given.
14507if test "${with_debug_level+set}" = set; then :
14508  withval=$with_debug_level;
14509        DEBUG_LEVEL="${withval}"
14510        if test "x$ENABLE_DEBUG" = xyes; then
14511          as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5
14512        fi
14513
14514fi
14515
14516  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5
14517$as_echo "$DEBUG_LEVEL" >&6; }
14518
14519  if test "x$DEBUG_LEVEL" != xrelease && \
14520      test "x$DEBUG_LEVEL" != xoptimized && \
14521      test "x$DEBUG_LEVEL" != xfastdebug && \
14522      test "x$DEBUG_LEVEL" != xslowdebug; then
14523    as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5
14524  fi
14525
14526
14527  ###############################################################################
14528  #
14529  # Setup legacy vars/targets and new vars to deal with different debug levels.
14530  #
14531
14532  case $DEBUG_LEVEL in
14533    release )
14534      VARIANT="OPT"
14535      FASTDEBUG="false"
14536      DEBUG_CLASSFILES="false"
14537      BUILD_VARIANT_RELEASE=""
14538      HOTSPOT_DEBUG_LEVEL="product"
14539      HOTSPOT_EXPORT="product"
14540      ;;
14541    fastdebug )
14542      VARIANT="DBG"
14543      FASTDEBUG="true"
14544      DEBUG_CLASSFILES="true"
14545      BUILD_VARIANT_RELEASE="-fastdebug"
14546      HOTSPOT_DEBUG_LEVEL="fastdebug"
14547      HOTSPOT_EXPORT="fastdebug"
14548      ;;
14549    slowdebug )
14550      VARIANT="DBG"
14551      FASTDEBUG="false"
14552      DEBUG_CLASSFILES="true"
14553      BUILD_VARIANT_RELEASE="-debug"
14554      HOTSPOT_DEBUG_LEVEL="jvmg"
14555      HOTSPOT_EXPORT="debug"
14556      ;;
14557    optimized )
14558      VARIANT="OPT"
14559      FASTDEBUG="false"
14560      DEBUG_CLASSFILES="false"
14561      BUILD_VARIANT_RELEASE="-optimized"
14562      HOTSPOT_DEBUG_LEVEL="optimized"
14563      HOTSPOT_EXPORT="optimized"
14564      ;;
14565  esac
14566
14567  # The debug level 'optimized' is a little special because it is currently only
14568  # applicable to the HotSpot build where it means to build a completely
14569  # optimized version of the VM without any debugging code (like for the
14570  # 'release' debug level which is called 'product' in the HotSpot build) but
14571  # with the exception that it can contain additional code which is otherwise
14572  # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to
14573  # test new and/or experimental features which are not intended for customer
14574  # shipment. Because these new features need to be tested and benchmarked in
14575  # real world scenarios, we want to build the containing JDK at the 'release'
14576  # debug level.
14577  if test "x$DEBUG_LEVEL" = xoptimized; then
14578    DEBUG_LEVEL="release"
14579  fi
14580
14581  #####
14582  # Generate the legacy makefile targets for hotspot.
14583  # The hotspot api for selecting the build artifacts, really, needs to be improved.
14584  # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to
14585  # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc
14586  # But until then ...
14587  HOTSPOT_TARGET=""
14588
14589  if test "x$JVM_VARIANT_SERVER" = xtrue; then
14590    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
14591  fi
14592
14593  if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14594    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
14595  fi
14596
14597  if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14598    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
14599  fi
14600
14601  if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14602    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel "
14603  fi
14604
14605  if test "x$JVM_VARIANT_ZERO" = xtrue; then
14606    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
14607  fi
14608
14609  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
14610    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
14611  fi
14612
14613  if test "x$JVM_VARIANT_CORE" = xtrue; then
14614    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
14615  fi
14616
14617  HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT"
14618
14619  # On Macosx universal binaries are produced, but they only contain
14620  # 64 bit intel. This invalidates control of which jvms are built
14621  # from configure, but only server is valid anyway. Fix this
14622  # when hotspot makefiles are rewritten.
14623  if test "x$MACOSX_UNIVERSAL" = xtrue; then
14624    HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT}
14625  fi
14626
14627  #####
14628
14629
14630
14631
14632
14633
14634
14635
14636# With basic setup done, call the custom early hook.
14637
14638
14639# Check if we have devkits, extra paths or sysroot set.
14640
14641
14642# Check whether --with-devkit was given.
14643if test "${with_devkit+set}" = set; then :
14644  withval=$with_devkit;
14645
14646  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14647
14648  # Input might be given as Windows format, start by converting to
14649  # unix format.
14650  path="$with_devkit"
14651  new_path=`$CYGPATH -u "$path"`
14652
14653  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14654  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14655  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14656  # "foo.exe" is OK but "foo" is an error.
14657  #
14658  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14659  # It is also a way to make sure we got the proper file name for the real test later on.
14660  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14661  if test "x$test_shortpath" = x; then
14662    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14663$as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14664    as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5
14665  fi
14666
14667  # Call helper function which possibly converts this using DOS-style short mode.
14668  # If so, the updated path is stored in $new_path.
14669
14670  input_path="$new_path"
14671  # Check if we need to convert this using DOS-style short mode. If the path
14672  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14673  # take no chances and rewrite it.
14674  # Note: m4 eats our [], so we need to use [ and ] instead.
14675  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14676  if test "x$has_forbidden_chars" != x; then
14677    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14678    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14679    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14680    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14681      # Going to short mode and back again did indeed matter. Since short mode is
14682      # case insensitive, let's make it lowercase to improve readability.
14683      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14684      # Now convert it back to Unix-stile (cygpath)
14685      input_path=`$CYGPATH -u "$shortmode_path"`
14686      new_path="$input_path"
14687    fi
14688  fi
14689
14690  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14691  if test "x$test_cygdrive_prefix" = x; then
14692    # As a simple fix, exclude /usr/bin since it's not a real path.
14693    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14694      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14695      # a path prefixed by /cygdrive for fixpath to work.
14696      new_path="$CYGWIN_ROOT_PATH$input_path"
14697    fi
14698  fi
14699
14700
14701  if test "x$path" != "x$new_path"; then
14702    with_devkit="$new_path"
14703    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14704$as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14705  fi
14706
14707  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14708
14709  path="$with_devkit"
14710  has_colon=`$ECHO $path | $GREP ^.:`
14711  new_path="$path"
14712  if test "x$has_colon" = x; then
14713    # Not in mixed or Windows style, start by that.
14714    new_path=`cmd //c echo $path`
14715  fi
14716
14717
14718  input_path="$new_path"
14719  # Check if we need to convert this using DOS-style short mode. If the path
14720  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14721  # take no chances and rewrite it.
14722  # Note: m4 eats our [], so we need to use [ and ] instead.
14723  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14724  if test "x$has_forbidden_chars" != x; then
14725    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14726    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14727  fi
14728
14729
14730  windows_path="$new_path"
14731  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14732    unix_path=`$CYGPATH -u "$windows_path"`
14733    new_path="$unix_path"
14734  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14735    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14736    new_path="$unix_path"
14737  fi
14738
14739  if test "x$path" != "x$new_path"; then
14740    with_devkit="$new_path"
14741    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14742$as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14743  fi
14744
14745  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14746  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14747
14748  else
14749    # We're on a posix platform. Hooray! :)
14750    path="$with_devkit"
14751    has_space=`$ECHO "$path" | $GREP " "`
14752    if test "x$has_space" != x; then
14753      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14754$as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14755      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14756    fi
14757
14758    # Use eval to expand a potential ~
14759    eval path="$path"
14760    if test ! -f "$path" && test ! -d "$path"; then
14761      as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14762    fi
14763
14764    with_devkit="`cd "$path"; $THEPWDCMD -L`"
14765  fi
14766
14767        DEVKIT_ROOT="$with_devkit"
14768        # Check for a meta data info file in the root of the devkit
14769        if test -f "$DEVKIT_ROOT/devkit.info"; then
14770          # This potentially sets the following:
14771          # DEVKIT_NAME: A descriptive name of the devkit
14772          # DEVKIT_TOOLCHAIN_PATH: Corresponds to --with-toolchain-path
14773          # DEVKIT_EXTRA_PATH: Corresponds to --with-extra-path
14774          # DEVKIT_SYSROOT: Corresponds to --with-sysroot
14775          . $DEVKIT_ROOT/devkit.info
14776        fi
14777
14778        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5
14779$as_echo_n "checking for devkit... " >&6; }
14780        if test "x$DEVKIT_NAME" != x; then
14781          { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5
14782$as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; }
14783        else
14784          { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5
14785$as_echo "$DEVKIT_ROOT" >&6; }
14786        fi
14787
14788        if test "x$DEVKIT_EXTRA_PATH" != x; then
14789
14790  if test "x$DEVKIT_EXTRA_PATH" != x; then
14791    if test "x$EXTRA_PATH" = x; then
14792      EXTRA_PATH="$DEVKIT_EXTRA_PATH"
14793    else
14794      EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH"
14795    fi
14796  fi
14797
14798        fi
14799
14800        # Fallback default of just /bin if DEVKIT_PATH is not defined
14801        if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then
14802          DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin"
14803        fi
14804
14805  if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then
14806    if test "x$TOOLCHAIN_PATH" = x; then
14807      TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH"
14808    else
14809      TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH"
14810    fi
14811  fi
14812
14813
14814        # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known
14815        # places for backwards compatiblity.
14816        if test "x$DEVKIT_SYSROOT" != x; then
14817          SYSROOT="$DEVKIT_SYSROOT"
14818        elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then
14819          SYSROOT="$DEVKIT_ROOT/$host_alias/libc"
14820        elif test -d "$DEVKIT_ROOT/$host/sys-root"; then
14821          SYSROOT="$DEVKIT_ROOT/$host/sys-root"
14822        fi
14823
14824
14825fi
14826
14827
14828  # You can force the sysroot if the sysroot encoded into the compiler tools
14829  # is not correct.
14830
14831# Check whether --with-sys-root was given.
14832if test "${with_sys_root+set}" = set; then :
14833  withval=$with_sys_root; SYSROOT=$with_sys_root
14834
14835fi
14836
14837
14838
14839# Check whether --with-sysroot was given.
14840if test "${with_sysroot+set}" = set; then :
14841  withval=$with_sysroot; SYSROOT=$with_sysroot
14842
14843fi
14844
14845
14846
14847# Check whether --with-tools-dir was given.
14848if test "${with_tools_dir+set}" = set; then :
14849  withval=$with_tools_dir;
14850  if test "x$with_tools_dir" != x; then
14851    if test "x$TOOLCHAIN_PATH" = x; then
14852      TOOLCHAIN_PATH="$with_tools_dir"
14853    else
14854      TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH"
14855    fi
14856  fi
14857
14858
14859fi
14860
14861
14862
14863# Check whether --with-toolchain-path was given.
14864if test "${with_toolchain_path+set}" = set; then :
14865  withval=$with_toolchain_path;
14866  if test "x$with_toolchain_path" != x; then
14867    if test "x$TOOLCHAIN_PATH" = x; then
14868      TOOLCHAIN_PATH="$with_toolchain_path"
14869    else
14870      TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH"
14871    fi
14872  fi
14873
14874
14875fi
14876
14877
14878
14879# Check whether --with-extra-path was given.
14880if test "${with_extra_path+set}" = set; then :
14881  withval=$with_extra_path;
14882  if test "x$with_extra_path" != x; then
14883    if test "x$EXTRA_PATH" = x; then
14884      EXTRA_PATH="$with_extra_path"
14885    else
14886      EXTRA_PATH="$with_extra_path:$EXTRA_PATH"
14887    fi
14888  fi
14889
14890
14891fi
14892
14893
14894  # Prepend the extra path to the global path
14895
14896  if test "x$EXTRA_PATH" != x; then
14897    if test "x$PATH" = x; then
14898      PATH="$EXTRA_PATH"
14899    else
14900      PATH="$EXTRA_PATH:$PATH"
14901    fi
14902  fi
14903
14904
14905  if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14906    # Add extra search paths on solaris for utilities like ar and as etc...
14907    PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14908  fi
14909
14910  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
14911$as_echo_n "checking for sysroot... " >&6; }
14912  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5
14913$as_echo "$SYSROOT" >&6; }
14914  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5
14915$as_echo_n "checking for toolchain path... " >&6; }
14916  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5
14917$as_echo "$TOOLCHAIN_PATH" >&6; }
14918  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5
14919$as_echo_n "checking for extra path... " >&6; }
14920  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5
14921$as_echo "$EXTRA_PATH" >&6; }
14922
14923
14924# To properly create a configuration name, we need to have the OpenJDK target
14925# and options (variants and debug level) parsed.
14926
14927
14928
14929# Check whether --with-conf-name was given.
14930if test "${with_conf_name+set}" = set; then :
14931  withval=$with_conf_name;  CONF_NAME=${with_conf_name}
14932fi
14933
14934
14935  # Test from where we are running configure, in or outside of src root.
14936  { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5
14937$as_echo_n "checking where to store configuration... " >&6; }
14938  if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \
14939      || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \
14940      || test "x$CURDIR" = "x$SRC_ROOT/make" ; then
14941    # We are running configure from the src root.
14942    # Create a default ./build/target-variant-debuglevel output root.
14943    if test "x${CONF_NAME}" = x; then
14944      { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5
14945$as_echo "in default location" >&6; }
14946      CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}"
14947    else
14948      { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5
14949$as_echo "in build directory with custom name" >&6; }
14950    fi
14951    OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}"
14952    $MKDIR -p "$OUTPUT_ROOT"
14953    if test ! -d "$OUTPUT_ROOT"; then
14954      as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5
14955    fi
14956  else
14957    # We are running configure from outside of the src dir.
14958    # Then use the current directory as output dir!
14959    # If configuration is situated in normal build directory, just use the build
14960    # directory name as configuration name, otherwise use the complete path.
14961    if test "x${CONF_NAME}" = x; then
14962      CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"`
14963    fi
14964    OUTPUT_ROOT="$CURDIR"
14965    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5
14966$as_echo "in current directory" >&6; }
14967
14968    # WARNING: This might be a bad thing to do. You need to be sure you want to
14969    # have a configuration in this directory. Do some sanity checks!
14970
14971    if test ! -e "$OUTPUT_ROOT/spec.gmk"; then
14972      # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for
14973      # other files
14974      files_present=`$LS $OUTPUT_ROOT`
14975      # Configure has already touched config.log and confdefs.h in the current dir when this check
14976      # is performed.
14977      filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \
14978      | $TR -d '\n'`
14979      if test "x$filtered_files" != x; then
14980        { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5
14981$as_echo "$as_me: Current directory is $CURDIR." >&6;}
14982        { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5
14983$as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;}
14984        { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5
14985$as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;}
14986        { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5
14987$as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;}
14988        { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5
14989$as_echo "$as_me: seriously mess up just about everything." >&6;}
14990        { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5
14991$as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;}
14992        { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5
14993$as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;}
14994        as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5
14995      fi
14996    fi
14997  fi
14998  { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5
14999$as_echo_n "checking what configuration name to use... " >&6; }
15000  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5
15001$as_echo "$CONF_NAME" >&6; }
15002
15003
15004  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15005
15006  # Input might be given as Windows format, start by converting to
15007  # unix format.
15008  path="$OUTPUT_ROOT"
15009  new_path=`$CYGPATH -u "$path"`
15010
15011  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15012  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15013  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15014  # "foo.exe" is OK but "foo" is an error.
15015  #
15016  # This test is therefore slightly more accurate than "test -f" to check for file precense.
15017  # It is also a way to make sure we got the proper file name for the real test later on.
15018  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15019  if test "x$test_shortpath" = x; then
15020    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
15021$as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
15022    as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5
15023  fi
15024
15025  # Call helper function which possibly converts this using DOS-style short mode.
15026  # If so, the updated path is stored in $new_path.
15027
15028  input_path="$new_path"
15029  # Check if we need to convert this using DOS-style short mode. If the path
15030  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15031  # take no chances and rewrite it.
15032  # Note: m4 eats our [], so we need to use [ and ] instead.
15033  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15034  if test "x$has_forbidden_chars" != x; then
15035    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15036    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15037    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15038    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15039      # Going to short mode and back again did indeed matter. Since short mode is
15040      # case insensitive, let's make it lowercase to improve readability.
15041      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15042      # Now convert it back to Unix-stile (cygpath)
15043      input_path=`$CYGPATH -u "$shortmode_path"`
15044      new_path="$input_path"
15045    fi
15046  fi
15047
15048  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15049  if test "x$test_cygdrive_prefix" = x; then
15050    # As a simple fix, exclude /usr/bin since it's not a real path.
15051    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
15052      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15053      # a path prefixed by /cygdrive for fixpath to work.
15054      new_path="$CYGWIN_ROOT_PATH$input_path"
15055    fi
15056  fi
15057
15058
15059  if test "x$path" != "x$new_path"; then
15060    OUTPUT_ROOT="$new_path"
15061    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
15062$as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
15063  fi
15064
15065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15066
15067  path="$OUTPUT_ROOT"
15068  has_colon=`$ECHO $path | $GREP ^.:`
15069  new_path="$path"
15070  if test "x$has_colon" = x; then
15071    # Not in mixed or Windows style, start by that.
15072    new_path=`cmd //c echo $path`
15073  fi
15074
15075
15076  input_path="$new_path"
15077  # Check if we need to convert this using DOS-style short mode. If the path
15078  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15079  # take no chances and rewrite it.
15080  # Note: m4 eats our [], so we need to use [ and ] instead.
15081  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15082  if test "x$has_forbidden_chars" != x; then
15083    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15084    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15085  fi
15086
15087
15088  windows_path="$new_path"
15089  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15090    unix_path=`$CYGPATH -u "$windows_path"`
15091    new_path="$unix_path"
15092  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15093    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15094    new_path="$unix_path"
15095  fi
15096
15097  if test "x$path" != "x$new_path"; then
15098    OUTPUT_ROOT="$new_path"
15099    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
15100$as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
15101  fi
15102
15103  # Save the first 10 bytes of this path to the storage, so fixpath can work.
15104  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15105
15106  else
15107    # We're on a posix platform. Hooray! :)
15108    path="$OUTPUT_ROOT"
15109    has_space=`$ECHO "$path" | $GREP " "`
15110    if test "x$has_space" != x; then
15111      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
15112$as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
15113      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
15114    fi
15115
15116    # Use eval to expand a potential ~
15117    eval path="$path"
15118    if test ! -f "$path" && test ! -d "$path"; then
15119      as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5
15120    fi
15121
15122    OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`"
15123  fi
15124
15125
15126  SPEC=$OUTPUT_ROOT/spec.gmk
15127
15128  CONF_NAME=$CONF_NAME
15129
15130  OUTPUT_ROOT=$OUTPUT_ROOT
15131
15132
15133  # Most of the probed defines are put into config.h
15134  ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in"
15135
15136  # The spec.gmk file contains all variables for the make system.
15137  ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in"
15138
15139  # The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
15140  ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in"
15141
15142  # The bootcycle-spec.gmk file contains support for boot cycle builds.
15143  ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in"
15144
15145  # The compare.sh is used to compare the build output to other builds.
15146  ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in"
15147
15148  # Spec.sh is currently used by compare-objects.sh
15149  ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in"
15150
15151  # The generated Makefile knows where the spec.gmk is and where the source is.
15152  # You can run make from the OUTPUT_ROOT, or from the top-level Makefile
15153  # which will look for generated configurations
15154  ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in"
15155
15156
15157
15158# Must be done before we can call HELP_MSG_MISSING_DEPENDENCY.
15159
15160  for ac_prog in apt-get yum port pkgutil pkgadd
15161do
15162  # Extract the first word of "$ac_prog", so it can be a program name with args.
15163set dummy $ac_prog; ac_word=$2
15164{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15165$as_echo_n "checking for $ac_word... " >&6; }
15166if ${ac_cv_prog_PKGHANDLER+:} false; then :
15167  $as_echo_n "(cached) " >&6
15168else
15169  if test -n "$PKGHANDLER"; then
15170  ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test.
15171else
15172as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15173for as_dir in $PATH
15174do
15175  IFS=$as_save_IFS
15176  test -z "$as_dir" && as_dir=.
15177    for ac_exec_ext in '' $ac_executable_extensions; do
15178  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15179    ac_cv_prog_PKGHANDLER="$ac_prog"
15180    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15181    break 2
15182  fi
15183done
15184  done
15185IFS=$as_save_IFS
15186
15187fi
15188fi
15189PKGHANDLER=$ac_cv_prog_PKGHANDLER
15190if test -n "$PKGHANDLER"; then
15191  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5
15192$as_echo "$PKGHANDLER" >&6; }
15193else
15194  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15195$as_echo "no" >&6; }
15196fi
15197
15198
15199  test -n "$PKGHANDLER" && break
15200done
15201
15202
15203
15204# Setup tools that requires more complex handling, or that is not needed by the configure script.
15205
15206
15207  # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky.
15208  if test "x$MAKE" != x; then
15209    # User has supplied a make, test it.
15210    if test ! -f "$MAKE"; then
15211      as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5
15212    fi
15213
15214  MAKE_CANDIDATE=""$MAKE""
15215  DESCRIPTION="user supplied MAKE=$MAKE"
15216  if test "x$MAKE_CANDIDATE" != x; then
15217    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15218$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15219    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15220    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15221    if test "x$IS_GNU_MAKE" = x; then
15222      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15223$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15224    else
15225      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15226      if test "x$IS_MODERN_MAKE" = x; then
15227        { $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
15228$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;}
15229      else
15230        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15231          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15232            MAKE_EXPECTED_ENV='cygwin'
15233          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15234            MAKE_EXPECTED_ENV='msys'
15235          else
15236            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15237          fi
15238          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15239          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15240        else
15241          # Not relevant for non-Windows
15242          IS_MAKE_CORRECT_ENV=true
15243        fi
15244        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15245          { $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
15246$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;}
15247        else
15248          FOUND_MAKE=$MAKE_CANDIDATE
15249
15250  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15251
15252  # First separate the path from the arguments. This will split at the first
15253  # space.
15254  complete="$FOUND_MAKE"
15255  path="${complete%% *}"
15256  tmp="$complete EOL"
15257  arguments="${tmp#* }"
15258
15259  # Input might be given as Windows format, start by converting to
15260  # unix format.
15261  new_path=`$CYGPATH -u "$path"`
15262
15263  # Now try to locate executable using which
15264  new_path=`$WHICH "$new_path" 2> /dev/null`
15265  # bat and cmd files are not always considered executable in cygwin causing which
15266  # to not find them
15267  if test "x$new_path" = x \
15268      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15269      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15270    new_path=`$CYGPATH -u "$path"`
15271  fi
15272  if test "x$new_path" = x; then
15273    # Oops. Which didn't find the executable.
15274    # The splitting of arguments from the executable at a space might have been incorrect,
15275    # since paths with space are more likely in Windows. Give it another try with the whole
15276    # argument.
15277    path="$complete"
15278    arguments="EOL"
15279    new_path=`$CYGPATH -u "$path"`
15280    new_path=`$WHICH "$new_path" 2> /dev/null`
15281    # bat and cmd files are not always considered executable in cygwin causing which
15282    # to not find them
15283    if test "x$new_path" = x \
15284        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15285        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15286      new_path=`$CYGPATH -u "$path"`
15287    fi
15288    if test "x$new_path" = x; then
15289      # It's still not found. Now this is an unrecoverable error.
15290      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15291$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15292      has_space=`$ECHO "$complete" | $GREP " "`
15293      if test "x$has_space" != x; then
15294        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15295$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15296      fi
15297      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15298    fi
15299  fi
15300
15301  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15302  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15303  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15304  # "foo.exe" is OK but "foo" is an error.
15305  #
15306  # This test is therefore slightly more accurate than "test -f" to check for file presence.
15307  # It is also a way to make sure we got the proper file name for the real test later on.
15308  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15309  if test "x$test_shortpath" = x; then
15310    # Short path failed, file does not exist as specified.
15311    # Try adding .exe or .cmd
15312    if test -f "${new_path}.exe"; then
15313      input_to_shortpath="${new_path}.exe"
15314    elif test -f "${new_path}.cmd"; then
15315      input_to_shortpath="${new_path}.cmd"
15316    else
15317      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15318$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15319      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15320$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15321      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15322    fi
15323  else
15324    input_to_shortpath="$new_path"
15325  fi
15326
15327  # Call helper function which possibly converts this using DOS-style short mode.
15328  # If so, the updated path is stored in $new_path.
15329  new_path="$input_to_shortpath"
15330
15331  input_path="$input_to_shortpath"
15332  # Check if we need to convert this using DOS-style short mode. If the path
15333  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15334  # take no chances and rewrite it.
15335  # Note: m4 eats our [], so we need to use [ and ] instead.
15336  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15337  if test "x$has_forbidden_chars" != x; then
15338    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15339    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15340    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15341    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15342      # Going to short mode and back again did indeed matter. Since short mode is
15343      # case insensitive, let's make it lowercase to improve readability.
15344      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15345      # Now convert it back to Unix-stile (cygpath)
15346      input_path=`$CYGPATH -u "$shortmode_path"`
15347      new_path="$input_path"
15348    fi
15349  fi
15350
15351  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15352  if test "x$test_cygdrive_prefix" = x; then
15353    # As a simple fix, exclude /usr/bin since it's not a real path.
15354    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15355      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15356      # a path prefixed by /cygdrive for fixpath to work.
15357      new_path="$CYGWIN_ROOT_PATH$input_path"
15358    fi
15359  fi
15360
15361  # remove trailing .exe if any
15362  new_path="${new_path/%.exe/}"
15363
15364  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15365
15366  # First separate the path from the arguments. This will split at the first
15367  # space.
15368  complete="$FOUND_MAKE"
15369  path="${complete%% *}"
15370  tmp="$complete EOL"
15371  arguments="${tmp#* }"
15372
15373  # Input might be given as Windows format, start by converting to
15374  # unix format.
15375  new_path="$path"
15376
15377  windows_path="$new_path"
15378  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15379    unix_path=`$CYGPATH -u "$windows_path"`
15380    new_path="$unix_path"
15381  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15382    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15383    new_path="$unix_path"
15384  fi
15385
15386
15387  # Now try to locate executable using which
15388  new_path=`$WHICH "$new_path" 2> /dev/null`
15389
15390  if test "x$new_path" = x; then
15391    # Oops. Which didn't find the executable.
15392    # The splitting of arguments from the executable at a space might have been incorrect,
15393    # since paths with space are more likely in Windows. Give it another try with the whole
15394    # argument.
15395    path="$complete"
15396    arguments="EOL"
15397    new_path="$path"
15398
15399  windows_path="$new_path"
15400  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15401    unix_path=`$CYGPATH -u "$windows_path"`
15402    new_path="$unix_path"
15403  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15404    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15405    new_path="$unix_path"
15406  fi
15407
15408
15409    new_path=`$WHICH "$new_path" 2> /dev/null`
15410
15411    if test "x$new_path" = x; then
15412      # It's still not found. Now this is an unrecoverable error.
15413      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15414$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15415      has_space=`$ECHO "$complete" | $GREP " "`
15416      if test "x$has_space" != x; then
15417        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15418$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15419      fi
15420      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15421    fi
15422  fi
15423
15424  # Now new_path has a complete unix path to the binary
15425  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15426    # Keep paths in /bin as-is, but remove trailing .exe if any
15427    new_path="${new_path/%.exe/}"
15428    # Do not save /bin paths to all_fixpath_prefixes!
15429  else
15430    # Not in mixed or Windows style, start by that.
15431    new_path=`cmd //c echo $new_path`
15432
15433  input_path="$new_path"
15434  # Check if we need to convert this using DOS-style short mode. If the path
15435  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15436  # take no chances and rewrite it.
15437  # Note: m4 eats our [], so we need to use [ and ] instead.
15438  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15439  if test "x$has_forbidden_chars" != x; then
15440    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15441    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15442  fi
15443
15444    # Output is in $new_path
15445
15446  windows_path="$new_path"
15447  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15448    unix_path=`$CYGPATH -u "$windows_path"`
15449    new_path="$unix_path"
15450  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15451    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15452    new_path="$unix_path"
15453  fi
15454
15455    # remove trailing .exe if any
15456    new_path="${new_path/%.exe/}"
15457
15458    # Save the first 10 bytes of this path to the storage, so fixpath can work.
15459    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15460  fi
15461
15462  else
15463    # We're on a posix platform. Hooray! :)
15464    # First separate the path from the arguments. This will split at the first
15465    # space.
15466    complete="$FOUND_MAKE"
15467    path="${complete%% *}"
15468    tmp="$complete EOL"
15469    arguments="${tmp#* }"
15470
15471    # Cannot rely on the command "which" here since it doesn't always work.
15472    is_absolute_path=`$ECHO "$path" | $GREP ^/`
15473    if test -z "$is_absolute_path"; then
15474      # Path to executable is not absolute. Find it.
15475      IFS_save="$IFS"
15476      IFS=:
15477      for p in $PATH; do
15478        if test -f "$p/$path" && test -x "$p/$path"; then
15479          new_path="$p/$path"
15480          break
15481        fi
15482      done
15483      IFS="$IFS_save"
15484    else
15485      # This is an absolute path, we can use it without further modifications.
15486      new_path="$path"
15487    fi
15488
15489    if test "x$new_path" = x; then
15490      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15491$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15492      has_space=`$ECHO "$complete" | $GREP " "`
15493      if test "x$has_space" != x; then
15494        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15495$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15496      fi
15497      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15498    fi
15499  fi
15500
15501  # Now join together the path and the arguments once again
15502  if test "x$arguments" != xEOL; then
15503    new_complete="$new_path ${arguments% *}"
15504  else
15505    new_complete="$new_path"
15506  fi
15507
15508  if test "x$complete" != "x$new_complete"; then
15509    FOUND_MAKE="$new_complete"
15510    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15511$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15512  fi
15513
15514        fi
15515      fi
15516    fi
15517  fi
15518
15519    if test "x$FOUND_MAKE" = x; then
15520      as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5
15521    fi
15522  else
15523    # Try our hardest to locate a correct version of GNU make
15524    for ac_prog in gmake
15525do
15526  # Extract the first word of "$ac_prog", so it can be a program name with args.
15527set dummy $ac_prog; ac_word=$2
15528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15529$as_echo_n "checking for $ac_word... " >&6; }
15530if ${ac_cv_path_CHECK_GMAKE+:} false; then :
15531  $as_echo_n "(cached) " >&6
15532else
15533  case $CHECK_GMAKE in
15534  [\\/]* | ?:[\\/]*)
15535  ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path.
15536  ;;
15537  *)
15538  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15539for as_dir in $PATH
15540do
15541  IFS=$as_save_IFS
15542  test -z "$as_dir" && as_dir=.
15543    for ac_exec_ext in '' $ac_executable_extensions; do
15544  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15545    ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15546    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15547    break 2
15548  fi
15549done
15550  done
15551IFS=$as_save_IFS
15552
15553  ;;
15554esac
15555fi
15556CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE
15557if test -n "$CHECK_GMAKE"; then
15558  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5
15559$as_echo "$CHECK_GMAKE" >&6; }
15560else
15561  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15562$as_echo "no" >&6; }
15563fi
15564
15565
15566  test -n "$CHECK_GMAKE" && break
15567done
15568
15569
15570  MAKE_CANDIDATE=""$CHECK_GMAKE""
15571  DESCRIPTION="gmake in PATH"
15572  if test "x$MAKE_CANDIDATE" != x; then
15573    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15574$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15575    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15576    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15577    if test "x$IS_GNU_MAKE" = x; then
15578      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15579$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15580    else
15581      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15582      if test "x$IS_MODERN_MAKE" = x; then
15583        { $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
15584$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;}
15585      else
15586        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15587          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15588            MAKE_EXPECTED_ENV='cygwin'
15589          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15590            MAKE_EXPECTED_ENV='msys'
15591          else
15592            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15593          fi
15594          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15595          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15596        else
15597          # Not relevant for non-Windows
15598          IS_MAKE_CORRECT_ENV=true
15599        fi
15600        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15601          { $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
15602$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;}
15603        else
15604          FOUND_MAKE=$MAKE_CANDIDATE
15605
15606  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15607
15608  # First separate the path from the arguments. This will split at the first
15609  # space.
15610  complete="$FOUND_MAKE"
15611  path="${complete%% *}"
15612  tmp="$complete EOL"
15613  arguments="${tmp#* }"
15614
15615  # Input might be given as Windows format, start by converting to
15616  # unix format.
15617  new_path=`$CYGPATH -u "$path"`
15618
15619  # Now try to locate executable using which
15620  new_path=`$WHICH "$new_path" 2> /dev/null`
15621  # bat and cmd files are not always considered executable in cygwin causing which
15622  # to not find them
15623  if test "x$new_path" = x \
15624      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15625      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15626    new_path=`$CYGPATH -u "$path"`
15627  fi
15628  if test "x$new_path" = x; then
15629    # Oops. Which didn't find the executable.
15630    # The splitting of arguments from the executable at a space might have been incorrect,
15631    # since paths with space are more likely in Windows. Give it another try with the whole
15632    # argument.
15633    path="$complete"
15634    arguments="EOL"
15635    new_path=`$CYGPATH -u "$path"`
15636    new_path=`$WHICH "$new_path" 2> /dev/null`
15637    # bat and cmd files are not always considered executable in cygwin causing which
15638    # to not find them
15639    if test "x$new_path" = x \
15640        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15641        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15642      new_path=`$CYGPATH -u "$path"`
15643    fi
15644    if test "x$new_path" = x; then
15645      # It's still not found. Now this is an unrecoverable error.
15646      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15647$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15648      has_space=`$ECHO "$complete" | $GREP " "`
15649      if test "x$has_space" != x; then
15650        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15651$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15652      fi
15653      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15654    fi
15655  fi
15656
15657  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15658  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15659  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15660  # "foo.exe" is OK but "foo" is an error.
15661  #
15662  # This test is therefore slightly more accurate than "test -f" to check for file presence.
15663  # It is also a way to make sure we got the proper file name for the real test later on.
15664  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15665  if test "x$test_shortpath" = x; then
15666    # Short path failed, file does not exist as specified.
15667    # Try adding .exe or .cmd
15668    if test -f "${new_path}.exe"; then
15669      input_to_shortpath="${new_path}.exe"
15670    elif test -f "${new_path}.cmd"; then
15671      input_to_shortpath="${new_path}.cmd"
15672    else
15673      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15674$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15675      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15676$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15677      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15678    fi
15679  else
15680    input_to_shortpath="$new_path"
15681  fi
15682
15683  # Call helper function which possibly converts this using DOS-style short mode.
15684  # If so, the updated path is stored in $new_path.
15685  new_path="$input_to_shortpath"
15686
15687  input_path="$input_to_shortpath"
15688  # Check if we need to convert this using DOS-style short mode. If the path
15689  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15690  # take no chances and rewrite it.
15691  # Note: m4 eats our [], so we need to use [ and ] instead.
15692  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15693  if test "x$has_forbidden_chars" != x; then
15694    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15695    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15696    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15697    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15698      # Going to short mode and back again did indeed matter. Since short mode is
15699      # case insensitive, let's make it lowercase to improve readability.
15700      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15701      # Now convert it back to Unix-stile (cygpath)
15702      input_path=`$CYGPATH -u "$shortmode_path"`
15703      new_path="$input_path"
15704    fi
15705  fi
15706
15707  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15708  if test "x$test_cygdrive_prefix" = x; then
15709    # As a simple fix, exclude /usr/bin since it's not a real path.
15710    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15711      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15712      # a path prefixed by /cygdrive for fixpath to work.
15713      new_path="$CYGWIN_ROOT_PATH$input_path"
15714    fi
15715  fi
15716
15717  # remove trailing .exe if any
15718  new_path="${new_path/%.exe/}"
15719
15720  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15721
15722  # First separate the path from the arguments. This will split at the first
15723  # space.
15724  complete="$FOUND_MAKE"
15725  path="${complete%% *}"
15726  tmp="$complete EOL"
15727  arguments="${tmp#* }"
15728
15729  # Input might be given as Windows format, start by converting to
15730  # unix format.
15731  new_path="$path"
15732
15733  windows_path="$new_path"
15734  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15735    unix_path=`$CYGPATH -u "$windows_path"`
15736    new_path="$unix_path"
15737  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15738    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15739    new_path="$unix_path"
15740  fi
15741
15742
15743  # Now try to locate executable using which
15744  new_path=`$WHICH "$new_path" 2> /dev/null`
15745
15746  if test "x$new_path" = x; then
15747    # Oops. Which didn't find the executable.
15748    # The splitting of arguments from the executable at a space might have been incorrect,
15749    # since paths with space are more likely in Windows. Give it another try with the whole
15750    # argument.
15751    path="$complete"
15752    arguments="EOL"
15753    new_path="$path"
15754
15755  windows_path="$new_path"
15756  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15757    unix_path=`$CYGPATH -u "$windows_path"`
15758    new_path="$unix_path"
15759  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15760    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15761    new_path="$unix_path"
15762  fi
15763
15764
15765    new_path=`$WHICH "$new_path" 2> /dev/null`
15766
15767    if test "x$new_path" = x; then
15768      # It's still not found. Now this is an unrecoverable error.
15769      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15770$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15771      has_space=`$ECHO "$complete" | $GREP " "`
15772      if test "x$has_space" != x; then
15773        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15774$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15775      fi
15776      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15777    fi
15778  fi
15779
15780  # Now new_path has a complete unix path to the binary
15781  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15782    # Keep paths in /bin as-is, but remove trailing .exe if any
15783    new_path="${new_path/%.exe/}"
15784    # Do not save /bin paths to all_fixpath_prefixes!
15785  else
15786    # Not in mixed or Windows style, start by that.
15787    new_path=`cmd //c echo $new_path`
15788
15789  input_path="$new_path"
15790  # Check if we need to convert this using DOS-style short mode. If the path
15791  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15792  # take no chances and rewrite it.
15793  # Note: m4 eats our [], so we need to use [ and ] instead.
15794  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15795  if test "x$has_forbidden_chars" != x; then
15796    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15797    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15798  fi
15799
15800    # Output is in $new_path
15801
15802  windows_path="$new_path"
15803  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15804    unix_path=`$CYGPATH -u "$windows_path"`
15805    new_path="$unix_path"
15806  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15807    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15808    new_path="$unix_path"
15809  fi
15810
15811    # remove trailing .exe if any
15812    new_path="${new_path/%.exe/}"
15813
15814    # Save the first 10 bytes of this path to the storage, so fixpath can work.
15815    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15816  fi
15817
15818  else
15819    # We're on a posix platform. Hooray! :)
15820    # First separate the path from the arguments. This will split at the first
15821    # space.
15822    complete="$FOUND_MAKE"
15823    path="${complete%% *}"
15824    tmp="$complete EOL"
15825    arguments="${tmp#* }"
15826
15827    # Cannot rely on the command "which" here since it doesn't always work.
15828    is_absolute_path=`$ECHO "$path" | $GREP ^/`
15829    if test -z "$is_absolute_path"; then
15830      # Path to executable is not absolute. Find it.
15831      IFS_save="$IFS"
15832      IFS=:
15833      for p in $PATH; do
15834        if test -f "$p/$path" && test -x "$p/$path"; then
15835          new_path="$p/$path"
15836          break
15837        fi
15838      done
15839      IFS="$IFS_save"
15840    else
15841      # This is an absolute path, we can use it without further modifications.
15842      new_path="$path"
15843    fi
15844
15845    if test "x$new_path" = x; then
15846      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15847$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15848      has_space=`$ECHO "$complete" | $GREP " "`
15849      if test "x$has_space" != x; then
15850        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15851$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15852      fi
15853      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15854    fi
15855  fi
15856
15857  # Now join together the path and the arguments once again
15858  if test "x$arguments" != xEOL; then
15859    new_complete="$new_path ${arguments% *}"
15860  else
15861    new_complete="$new_path"
15862  fi
15863
15864  if test "x$complete" != "x$new_complete"; then
15865    FOUND_MAKE="$new_complete"
15866    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15867$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15868  fi
15869
15870        fi
15871      fi
15872    fi
15873  fi
15874
15875
15876    if test "x$FOUND_MAKE" = x; then
15877      for ac_prog in make
15878do
15879  # Extract the first word of "$ac_prog", so it can be a program name with args.
15880set dummy $ac_prog; ac_word=$2
15881{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15882$as_echo_n "checking for $ac_word... " >&6; }
15883if ${ac_cv_path_CHECK_MAKE+:} false; then :
15884  $as_echo_n "(cached) " >&6
15885else
15886  case $CHECK_MAKE in
15887  [\\/]* | ?:[\\/]*)
15888  ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path.
15889  ;;
15890  *)
15891  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15892for as_dir in $PATH
15893do
15894  IFS=$as_save_IFS
15895  test -z "$as_dir" && as_dir=.
15896    for ac_exec_ext in '' $ac_executable_extensions; do
15897  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15898    ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext"
15899    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15900    break 2
15901  fi
15902done
15903  done
15904IFS=$as_save_IFS
15905
15906  ;;
15907esac
15908fi
15909CHECK_MAKE=$ac_cv_path_CHECK_MAKE
15910if test -n "$CHECK_MAKE"; then
15911  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5
15912$as_echo "$CHECK_MAKE" >&6; }
15913else
15914  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15915$as_echo "no" >&6; }
15916fi
15917
15918
15919  test -n "$CHECK_MAKE" && break
15920done
15921
15922
15923  MAKE_CANDIDATE=""$CHECK_MAKE""
15924  DESCRIPTION="make in PATH"
15925  if test "x$MAKE_CANDIDATE" != x; then
15926    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15927$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15928    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15929    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15930    if test "x$IS_GNU_MAKE" = x; then
15931      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15932$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15933    else
15934      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15935      if test "x$IS_MODERN_MAKE" = x; then
15936        { $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
15937$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;}
15938      else
15939        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15940          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15941            MAKE_EXPECTED_ENV='cygwin'
15942          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15943            MAKE_EXPECTED_ENV='msys'
15944          else
15945            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15946          fi
15947          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15948          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15949        else
15950          # Not relevant for non-Windows
15951          IS_MAKE_CORRECT_ENV=true
15952        fi
15953        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15954          { $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
15955$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;}
15956        else
15957          FOUND_MAKE=$MAKE_CANDIDATE
15958
15959  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15960
15961  # First separate the path from the arguments. This will split at the first
15962  # space.
15963  complete="$FOUND_MAKE"
15964  path="${complete%% *}"
15965  tmp="$complete EOL"
15966  arguments="${tmp#* }"
15967
15968  # Input might be given as Windows format, start by converting to
15969  # unix format.
15970  new_path=`$CYGPATH -u "$path"`
15971
15972  # Now try to locate executable using which
15973  new_path=`$WHICH "$new_path" 2> /dev/null`
15974  # bat and cmd files are not always considered executable in cygwin causing which
15975  # to not find them
15976  if test "x$new_path" = x \
15977      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15978      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15979    new_path=`$CYGPATH -u "$path"`
15980  fi
15981  if test "x$new_path" = x; then
15982    # Oops. Which didn't find the executable.
15983    # The splitting of arguments from the executable at a space might have been incorrect,
15984    # since paths with space are more likely in Windows. Give it another try with the whole
15985    # argument.
15986    path="$complete"
15987    arguments="EOL"
15988    new_path=`$CYGPATH -u "$path"`
15989    new_path=`$WHICH "$new_path" 2> /dev/null`
15990    # bat and cmd files are not always considered executable in cygwin causing which
15991    # to not find them
15992    if test "x$new_path" = x \
15993        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15994        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15995      new_path=`$CYGPATH -u "$path"`
15996    fi
15997    if test "x$new_path" = x; then
15998      # It's still not found. Now this is an unrecoverable error.
15999      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16000$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16001      has_space=`$ECHO "$complete" | $GREP " "`
16002      if test "x$has_space" != x; then
16003        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16004$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16005      fi
16006      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16007    fi
16008  fi
16009
16010  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16011  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16012  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16013  # "foo.exe" is OK but "foo" is an error.
16014  #
16015  # This test is therefore slightly more accurate than "test -f" to check for file presence.
16016  # It is also a way to make sure we got the proper file name for the real test later on.
16017  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16018  if test "x$test_shortpath" = x; then
16019    # Short path failed, file does not exist as specified.
16020    # Try adding .exe or .cmd
16021    if test -f "${new_path}.exe"; then
16022      input_to_shortpath="${new_path}.exe"
16023    elif test -f "${new_path}.cmd"; then
16024      input_to_shortpath="${new_path}.cmd"
16025    else
16026      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16027$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16028      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16029$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16030      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16031    fi
16032  else
16033    input_to_shortpath="$new_path"
16034  fi
16035
16036  # Call helper function which possibly converts this using DOS-style short mode.
16037  # If so, the updated path is stored in $new_path.
16038  new_path="$input_to_shortpath"
16039
16040  input_path="$input_to_shortpath"
16041  # Check if we need to convert this using DOS-style short mode. If the path
16042  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16043  # take no chances and rewrite it.
16044  # Note: m4 eats our [], so we need to use [ and ] instead.
16045  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16046  if test "x$has_forbidden_chars" != x; then
16047    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16048    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16049    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16050    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16051      # Going to short mode and back again did indeed matter. Since short mode is
16052      # case insensitive, let's make it lowercase to improve readability.
16053      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16054      # Now convert it back to Unix-stile (cygpath)
16055      input_path=`$CYGPATH -u "$shortmode_path"`
16056      new_path="$input_path"
16057    fi
16058  fi
16059
16060  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16061  if test "x$test_cygdrive_prefix" = x; then
16062    # As a simple fix, exclude /usr/bin since it's not a real path.
16063    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16064      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16065      # a path prefixed by /cygdrive for fixpath to work.
16066      new_path="$CYGWIN_ROOT_PATH$input_path"
16067    fi
16068  fi
16069
16070  # remove trailing .exe if any
16071  new_path="${new_path/%.exe/}"
16072
16073  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16074
16075  # First separate the path from the arguments. This will split at the first
16076  # space.
16077  complete="$FOUND_MAKE"
16078  path="${complete%% *}"
16079  tmp="$complete EOL"
16080  arguments="${tmp#* }"
16081
16082  # Input might be given as Windows format, start by converting to
16083  # unix format.
16084  new_path="$path"
16085
16086  windows_path="$new_path"
16087  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16088    unix_path=`$CYGPATH -u "$windows_path"`
16089    new_path="$unix_path"
16090  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16091    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16092    new_path="$unix_path"
16093  fi
16094
16095
16096  # Now try to locate executable using which
16097  new_path=`$WHICH "$new_path" 2> /dev/null`
16098
16099  if test "x$new_path" = x; then
16100    # Oops. Which didn't find the executable.
16101    # The splitting of arguments from the executable at a space might have been incorrect,
16102    # since paths with space are more likely in Windows. Give it another try with the whole
16103    # argument.
16104    path="$complete"
16105    arguments="EOL"
16106    new_path="$path"
16107
16108  windows_path="$new_path"
16109  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16110    unix_path=`$CYGPATH -u "$windows_path"`
16111    new_path="$unix_path"
16112  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16113    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16114    new_path="$unix_path"
16115  fi
16116
16117
16118    new_path=`$WHICH "$new_path" 2> /dev/null`
16119
16120    if test "x$new_path" = x; then
16121      # It's still not found. Now this is an unrecoverable error.
16122      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16123$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16124      has_space=`$ECHO "$complete" | $GREP " "`
16125      if test "x$has_space" != x; then
16126        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16127$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16128      fi
16129      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16130    fi
16131  fi
16132
16133  # Now new_path has a complete unix path to the binary
16134  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16135    # Keep paths in /bin as-is, but remove trailing .exe if any
16136    new_path="${new_path/%.exe/}"
16137    # Do not save /bin paths to all_fixpath_prefixes!
16138  else
16139    # Not in mixed or Windows style, start by that.
16140    new_path=`cmd //c echo $new_path`
16141
16142  input_path="$new_path"
16143  # Check if we need to convert this using DOS-style short mode. If the path
16144  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16145  # take no chances and rewrite it.
16146  # Note: m4 eats our [], so we need to use [ and ] instead.
16147  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16148  if test "x$has_forbidden_chars" != x; then
16149    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16150    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16151  fi
16152
16153    # Output is in $new_path
16154
16155  windows_path="$new_path"
16156  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16157    unix_path=`$CYGPATH -u "$windows_path"`
16158    new_path="$unix_path"
16159  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16160    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16161    new_path="$unix_path"
16162  fi
16163
16164    # remove trailing .exe if any
16165    new_path="${new_path/%.exe/}"
16166
16167    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16168    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16169  fi
16170
16171  else
16172    # We're on a posix platform. Hooray! :)
16173    # First separate the path from the arguments. This will split at the first
16174    # space.
16175    complete="$FOUND_MAKE"
16176    path="${complete%% *}"
16177    tmp="$complete EOL"
16178    arguments="${tmp#* }"
16179
16180    # Cannot rely on the command "which" here since it doesn't always work.
16181    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16182    if test -z "$is_absolute_path"; then
16183      # Path to executable is not absolute. Find it.
16184      IFS_save="$IFS"
16185      IFS=:
16186      for p in $PATH; do
16187        if test -f "$p/$path" && test -x "$p/$path"; then
16188          new_path="$p/$path"
16189          break
16190        fi
16191      done
16192      IFS="$IFS_save"
16193    else
16194      # This is an absolute path, we can use it without further modifications.
16195      new_path="$path"
16196    fi
16197
16198    if test "x$new_path" = x; then
16199      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16200$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16201      has_space=`$ECHO "$complete" | $GREP " "`
16202      if test "x$has_space" != x; then
16203        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16204$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16205      fi
16206      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16207    fi
16208  fi
16209
16210  # Now join together the path and the arguments once again
16211  if test "x$arguments" != xEOL; then
16212    new_complete="$new_path ${arguments% *}"
16213  else
16214    new_complete="$new_path"
16215  fi
16216
16217  if test "x$complete" != "x$new_complete"; then
16218    FOUND_MAKE="$new_complete"
16219    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16220$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16221  fi
16222
16223        fi
16224      fi
16225    fi
16226  fi
16227
16228    fi
16229
16230    if test "x$FOUND_MAKE" = x; then
16231      if test "x$TOOLCHAIN_PATH" != x; then
16232        # We have a toolchain path, check that as well before giving up.
16233        OLD_PATH=$PATH
16234        PATH=$TOOLCHAIN_PATH:$PATH
16235        for ac_prog in gmake
16236do
16237  # Extract the first word of "$ac_prog", so it can be a program name with args.
16238set dummy $ac_prog; ac_word=$2
16239{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16240$as_echo_n "checking for $ac_word... " >&6; }
16241if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16242  $as_echo_n "(cached) " >&6
16243else
16244  case $CHECK_TOOLSDIR_GMAKE in
16245  [\\/]* | ?:[\\/]*)
16246  ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16247  ;;
16248  *)
16249  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16250for as_dir in $PATH
16251do
16252  IFS=$as_save_IFS
16253  test -z "$as_dir" && as_dir=.
16254    for ac_exec_ext in '' $ac_executable_extensions; do
16255  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16256    ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext"
16257    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16258    break 2
16259  fi
16260done
16261  done
16262IFS=$as_save_IFS
16263
16264  ;;
16265esac
16266fi
16267CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE
16268if test -n "$CHECK_TOOLSDIR_GMAKE"; then
16269  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5
16270$as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; }
16271else
16272  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16273$as_echo "no" >&6; }
16274fi
16275
16276
16277  test -n "$CHECK_TOOLSDIR_GMAKE" && break
16278done
16279
16280
16281  MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE""
16282  DESCRIPTION="gmake in tools-dir"
16283  if test "x$MAKE_CANDIDATE" != x; then
16284    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16285$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16286    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16287    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16288    if test "x$IS_GNU_MAKE" = x; then
16289      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16290$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16291    else
16292      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16293      if test "x$IS_MODERN_MAKE" = x; then
16294        { $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
16295$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;}
16296      else
16297        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16298          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16299            MAKE_EXPECTED_ENV='cygwin'
16300          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16301            MAKE_EXPECTED_ENV='msys'
16302          else
16303            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16304          fi
16305          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16306          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16307        else
16308          # Not relevant for non-Windows
16309          IS_MAKE_CORRECT_ENV=true
16310        fi
16311        if test "x$IS_MAKE_CORRECT_ENV" = x; then
16312          { $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
16313$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;}
16314        else
16315          FOUND_MAKE=$MAKE_CANDIDATE
16316
16317  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16318
16319  # First separate the path from the arguments. This will split at the first
16320  # space.
16321  complete="$FOUND_MAKE"
16322  path="${complete%% *}"
16323  tmp="$complete EOL"
16324  arguments="${tmp#* }"
16325
16326  # Input might be given as Windows format, start by converting to
16327  # unix format.
16328  new_path=`$CYGPATH -u "$path"`
16329
16330  # Now try to locate executable using which
16331  new_path=`$WHICH "$new_path" 2> /dev/null`
16332  # bat and cmd files are not always considered executable in cygwin causing which
16333  # to not find them
16334  if test "x$new_path" = x \
16335      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16336      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16337    new_path=`$CYGPATH -u "$path"`
16338  fi
16339  if test "x$new_path" = x; then
16340    # Oops. Which didn't find the executable.
16341    # The splitting of arguments from the executable at a space might have been incorrect,
16342    # since paths with space are more likely in Windows. Give it another try with the whole
16343    # argument.
16344    path="$complete"
16345    arguments="EOL"
16346    new_path=`$CYGPATH -u "$path"`
16347    new_path=`$WHICH "$new_path" 2> /dev/null`
16348    # bat and cmd files are not always considered executable in cygwin causing which
16349    # to not find them
16350    if test "x$new_path" = x \
16351        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16352        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16353      new_path=`$CYGPATH -u "$path"`
16354    fi
16355    if test "x$new_path" = x; then
16356      # It's still not found. Now this is an unrecoverable error.
16357      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16358$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16359      has_space=`$ECHO "$complete" | $GREP " "`
16360      if test "x$has_space" != x; then
16361        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16362$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16363      fi
16364      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16365    fi
16366  fi
16367
16368  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16369  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16370  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16371  # "foo.exe" is OK but "foo" is an error.
16372  #
16373  # This test is therefore slightly more accurate than "test -f" to check for file presence.
16374  # It is also a way to make sure we got the proper file name for the real test later on.
16375  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16376  if test "x$test_shortpath" = x; then
16377    # Short path failed, file does not exist as specified.
16378    # Try adding .exe or .cmd
16379    if test -f "${new_path}.exe"; then
16380      input_to_shortpath="${new_path}.exe"
16381    elif test -f "${new_path}.cmd"; then
16382      input_to_shortpath="${new_path}.cmd"
16383    else
16384      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16385$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16386      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16387$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16388      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16389    fi
16390  else
16391    input_to_shortpath="$new_path"
16392  fi
16393
16394  # Call helper function which possibly converts this using DOS-style short mode.
16395  # If so, the updated path is stored in $new_path.
16396  new_path="$input_to_shortpath"
16397
16398  input_path="$input_to_shortpath"
16399  # Check if we need to convert this using DOS-style short mode. If the path
16400  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16401  # take no chances and rewrite it.
16402  # Note: m4 eats our [], so we need to use [ and ] instead.
16403  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16404  if test "x$has_forbidden_chars" != x; then
16405    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16406    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16407    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16408    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16409      # Going to short mode and back again did indeed matter. Since short mode is
16410      # case insensitive, let's make it lowercase to improve readability.
16411      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16412      # Now convert it back to Unix-stile (cygpath)
16413      input_path=`$CYGPATH -u "$shortmode_path"`
16414      new_path="$input_path"
16415    fi
16416  fi
16417
16418  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16419  if test "x$test_cygdrive_prefix" = x; then
16420    # As a simple fix, exclude /usr/bin since it's not a real path.
16421    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16422      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16423      # a path prefixed by /cygdrive for fixpath to work.
16424      new_path="$CYGWIN_ROOT_PATH$input_path"
16425    fi
16426  fi
16427
16428  # remove trailing .exe if any
16429  new_path="${new_path/%.exe/}"
16430
16431  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16432
16433  # First separate the path from the arguments. This will split at the first
16434  # space.
16435  complete="$FOUND_MAKE"
16436  path="${complete%% *}"
16437  tmp="$complete EOL"
16438  arguments="${tmp#* }"
16439
16440  # Input might be given as Windows format, start by converting to
16441  # unix format.
16442  new_path="$path"
16443
16444  windows_path="$new_path"
16445  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16446    unix_path=`$CYGPATH -u "$windows_path"`
16447    new_path="$unix_path"
16448  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16449    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16450    new_path="$unix_path"
16451  fi
16452
16453
16454  # Now try to locate executable using which
16455  new_path=`$WHICH "$new_path" 2> /dev/null`
16456
16457  if test "x$new_path" = x; then
16458    # Oops. Which didn't find the executable.
16459    # The splitting of arguments from the executable at a space might have been incorrect,
16460    # since paths with space are more likely in Windows. Give it another try with the whole
16461    # argument.
16462    path="$complete"
16463    arguments="EOL"
16464    new_path="$path"
16465
16466  windows_path="$new_path"
16467  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16468    unix_path=`$CYGPATH -u "$windows_path"`
16469    new_path="$unix_path"
16470  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16471    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16472    new_path="$unix_path"
16473  fi
16474
16475
16476    new_path=`$WHICH "$new_path" 2> /dev/null`
16477
16478    if test "x$new_path" = x; then
16479      # It's still not found. Now this is an unrecoverable error.
16480      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16481$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16482      has_space=`$ECHO "$complete" | $GREP " "`
16483      if test "x$has_space" != x; then
16484        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16485$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16486      fi
16487      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16488    fi
16489  fi
16490
16491  # Now new_path has a complete unix path to the binary
16492  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16493    # Keep paths in /bin as-is, but remove trailing .exe if any
16494    new_path="${new_path/%.exe/}"
16495    # Do not save /bin paths to all_fixpath_prefixes!
16496  else
16497    # Not in mixed or Windows style, start by that.
16498    new_path=`cmd //c echo $new_path`
16499
16500  input_path="$new_path"
16501  # Check if we need to convert this using DOS-style short mode. If the path
16502  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16503  # take no chances and rewrite it.
16504  # Note: m4 eats our [], so we need to use [ and ] instead.
16505  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16506  if test "x$has_forbidden_chars" != x; then
16507    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16508    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16509  fi
16510
16511    # Output is in $new_path
16512
16513  windows_path="$new_path"
16514  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16515    unix_path=`$CYGPATH -u "$windows_path"`
16516    new_path="$unix_path"
16517  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16518    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16519    new_path="$unix_path"
16520  fi
16521
16522    # remove trailing .exe if any
16523    new_path="${new_path/%.exe/}"
16524
16525    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16526    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16527  fi
16528
16529  else
16530    # We're on a posix platform. Hooray! :)
16531    # First separate the path from the arguments. This will split at the first
16532    # space.
16533    complete="$FOUND_MAKE"
16534    path="${complete%% *}"
16535    tmp="$complete EOL"
16536    arguments="${tmp#* }"
16537
16538    # Cannot rely on the command "which" here since it doesn't always work.
16539    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16540    if test -z "$is_absolute_path"; then
16541      # Path to executable is not absolute. Find it.
16542      IFS_save="$IFS"
16543      IFS=:
16544      for p in $PATH; do
16545        if test -f "$p/$path" && test -x "$p/$path"; then
16546          new_path="$p/$path"
16547          break
16548        fi
16549      done
16550      IFS="$IFS_save"
16551    else
16552      # This is an absolute path, we can use it without further modifications.
16553      new_path="$path"
16554    fi
16555
16556    if test "x$new_path" = x; then
16557      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16558$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16559      has_space=`$ECHO "$complete" | $GREP " "`
16560      if test "x$has_space" != x; then
16561        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16562$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16563      fi
16564      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16565    fi
16566  fi
16567
16568  # Now join together the path and the arguments once again
16569  if test "x$arguments" != xEOL; then
16570    new_complete="$new_path ${arguments% *}"
16571  else
16572    new_complete="$new_path"
16573  fi
16574
16575  if test "x$complete" != "x$new_complete"; then
16576    FOUND_MAKE="$new_complete"
16577    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16578$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16579  fi
16580
16581        fi
16582      fi
16583    fi
16584  fi
16585
16586        if test "x$FOUND_MAKE" = x; then
16587          for ac_prog in make
16588do
16589  # Extract the first word of "$ac_prog", so it can be a program name with args.
16590set dummy $ac_prog; ac_word=$2
16591{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16592$as_echo_n "checking for $ac_word... " >&6; }
16593if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then :
16594  $as_echo_n "(cached) " >&6
16595else
16596  case $CHECK_TOOLSDIR_MAKE in
16597  [\\/]* | ?:[\\/]*)
16598  ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path.
16599  ;;
16600  *)
16601  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16602for as_dir in $PATH
16603do
16604  IFS=$as_save_IFS
16605  test -z "$as_dir" && as_dir=.
16606    for ac_exec_ext in '' $ac_executable_extensions; do
16607  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16608    ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext"
16609    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16610    break 2
16611  fi
16612done
16613  done
16614IFS=$as_save_IFS
16615
16616  ;;
16617esac
16618fi
16619CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE
16620if test -n "$CHECK_TOOLSDIR_MAKE"; then
16621  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5
16622$as_echo "$CHECK_TOOLSDIR_MAKE" >&6; }
16623else
16624  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16625$as_echo "no" >&6; }
16626fi
16627
16628
16629  test -n "$CHECK_TOOLSDIR_MAKE" && break
16630done
16631
16632
16633  MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE""
16634  DESCRIPTION="make in tools-dir"
16635  if test "x$MAKE_CANDIDATE" != x; then
16636    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16637$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16638    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16639    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16640    if test "x$IS_GNU_MAKE" = x; then
16641      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16642$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16643    else
16644      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16645      if test "x$IS_MODERN_MAKE" = x; then
16646        { $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
16647$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;}
16648      else
16649        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16650          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16651            MAKE_EXPECTED_ENV='cygwin'
16652          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16653            MAKE_EXPECTED_ENV='msys'
16654          else
16655            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16656          fi
16657          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16658          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16659        else
16660          # Not relevant for non-Windows
16661          IS_MAKE_CORRECT_ENV=true
16662        fi
16663        if test "x$IS_MAKE_CORRECT_ENV" = x; then
16664          { $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
16665$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;}
16666        else
16667          FOUND_MAKE=$MAKE_CANDIDATE
16668
16669  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16670
16671  # First separate the path from the arguments. This will split at the first
16672  # space.
16673  complete="$FOUND_MAKE"
16674  path="${complete%% *}"
16675  tmp="$complete EOL"
16676  arguments="${tmp#* }"
16677
16678  # Input might be given as Windows format, start by converting to
16679  # unix format.
16680  new_path=`$CYGPATH -u "$path"`
16681
16682  # Now try to locate executable using which
16683  new_path=`$WHICH "$new_path" 2> /dev/null`
16684  # bat and cmd files are not always considered executable in cygwin causing which
16685  # to not find them
16686  if test "x$new_path" = x \
16687      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16688      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16689    new_path=`$CYGPATH -u "$path"`
16690  fi
16691  if test "x$new_path" = x; then
16692    # Oops. Which didn't find the executable.
16693    # The splitting of arguments from the executable at a space might have been incorrect,
16694    # since paths with space are more likely in Windows. Give it another try with the whole
16695    # argument.
16696    path="$complete"
16697    arguments="EOL"
16698    new_path=`$CYGPATH -u "$path"`
16699    new_path=`$WHICH "$new_path" 2> /dev/null`
16700    # bat and cmd files are not always considered executable in cygwin causing which
16701    # to not find them
16702    if test "x$new_path" = x \
16703        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16704        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16705      new_path=`$CYGPATH -u "$path"`
16706    fi
16707    if test "x$new_path" = x; then
16708      # It's still not found. Now this is an unrecoverable error.
16709      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16710$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16711      has_space=`$ECHO "$complete" | $GREP " "`
16712      if test "x$has_space" != x; then
16713        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16714$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16715      fi
16716      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16717    fi
16718  fi
16719
16720  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16721  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16722  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16723  # "foo.exe" is OK but "foo" is an error.
16724  #
16725  # This test is therefore slightly more accurate than "test -f" to check for file presence.
16726  # It is also a way to make sure we got the proper file name for the real test later on.
16727  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16728  if test "x$test_shortpath" = x; then
16729    # Short path failed, file does not exist as specified.
16730    # Try adding .exe or .cmd
16731    if test -f "${new_path}.exe"; then
16732      input_to_shortpath="${new_path}.exe"
16733    elif test -f "${new_path}.cmd"; then
16734      input_to_shortpath="${new_path}.cmd"
16735    else
16736      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16737$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16738      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16739$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16740      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16741    fi
16742  else
16743    input_to_shortpath="$new_path"
16744  fi
16745
16746  # Call helper function which possibly converts this using DOS-style short mode.
16747  # If so, the updated path is stored in $new_path.
16748  new_path="$input_to_shortpath"
16749
16750  input_path="$input_to_shortpath"
16751  # Check if we need to convert this using DOS-style short mode. If the path
16752  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16753  # take no chances and rewrite it.
16754  # Note: m4 eats our [], so we need to use [ and ] instead.
16755  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16756  if test "x$has_forbidden_chars" != x; then
16757    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16758    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16759    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16760    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16761      # Going to short mode and back again did indeed matter. Since short mode is
16762      # case insensitive, let's make it lowercase to improve readability.
16763      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16764      # Now convert it back to Unix-stile (cygpath)
16765      input_path=`$CYGPATH -u "$shortmode_path"`
16766      new_path="$input_path"
16767    fi
16768  fi
16769
16770  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16771  if test "x$test_cygdrive_prefix" = x; then
16772    # As a simple fix, exclude /usr/bin since it's not a real path.
16773    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16774      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16775      # a path prefixed by /cygdrive for fixpath to work.
16776      new_path="$CYGWIN_ROOT_PATH$input_path"
16777    fi
16778  fi
16779
16780  # remove trailing .exe if any
16781  new_path="${new_path/%.exe/}"
16782
16783  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16784
16785  # First separate the path from the arguments. This will split at the first
16786  # space.
16787  complete="$FOUND_MAKE"
16788  path="${complete%% *}"
16789  tmp="$complete EOL"
16790  arguments="${tmp#* }"
16791
16792  # Input might be given as Windows format, start by converting to
16793  # unix format.
16794  new_path="$path"
16795
16796  windows_path="$new_path"
16797  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16798    unix_path=`$CYGPATH -u "$windows_path"`
16799    new_path="$unix_path"
16800  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16801    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16802    new_path="$unix_path"
16803  fi
16804
16805
16806  # Now try to locate executable using which
16807  new_path=`$WHICH "$new_path" 2> /dev/null`
16808
16809  if test "x$new_path" = x; then
16810    # Oops. Which didn't find the executable.
16811    # The splitting of arguments from the executable at a space might have been incorrect,
16812    # since paths with space are more likely in Windows. Give it another try with the whole
16813    # argument.
16814    path="$complete"
16815    arguments="EOL"
16816    new_path="$path"
16817
16818  windows_path="$new_path"
16819  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16820    unix_path=`$CYGPATH -u "$windows_path"`
16821    new_path="$unix_path"
16822  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16823    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16824    new_path="$unix_path"
16825  fi
16826
16827
16828    new_path=`$WHICH "$new_path" 2> /dev/null`
16829
16830    if test "x$new_path" = x; then
16831      # It's still not found. Now this is an unrecoverable error.
16832      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16833$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16834      has_space=`$ECHO "$complete" | $GREP " "`
16835      if test "x$has_space" != x; then
16836        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16837$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16838      fi
16839      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16840    fi
16841  fi
16842
16843  # Now new_path has a complete unix path to the binary
16844  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16845    # Keep paths in /bin as-is, but remove trailing .exe if any
16846    new_path="${new_path/%.exe/}"
16847    # Do not save /bin paths to all_fixpath_prefixes!
16848  else
16849    # Not in mixed or Windows style, start by that.
16850    new_path=`cmd //c echo $new_path`
16851
16852  input_path="$new_path"
16853  # Check if we need to convert this using DOS-style short mode. If the path
16854  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16855  # take no chances and rewrite it.
16856  # Note: m4 eats our [], so we need to use [ and ] instead.
16857  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16858  if test "x$has_forbidden_chars" != x; then
16859    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16860    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16861  fi
16862
16863    # Output is in $new_path
16864
16865  windows_path="$new_path"
16866  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16867    unix_path=`$CYGPATH -u "$windows_path"`
16868    new_path="$unix_path"
16869  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16870    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16871    new_path="$unix_path"
16872  fi
16873
16874    # remove trailing .exe if any
16875    new_path="${new_path/%.exe/}"
16876
16877    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16878    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16879  fi
16880
16881  else
16882    # We're on a posix platform. Hooray! :)
16883    # First separate the path from the arguments. This will split at the first
16884    # space.
16885    complete="$FOUND_MAKE"
16886    path="${complete%% *}"
16887    tmp="$complete EOL"
16888    arguments="${tmp#* }"
16889
16890    # Cannot rely on the command "which" here since it doesn't always work.
16891    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16892    if test -z "$is_absolute_path"; then
16893      # Path to executable is not absolute. Find it.
16894      IFS_save="$IFS"
16895      IFS=:
16896      for p in $PATH; do
16897        if test -f "$p/$path" && test -x "$p/$path"; then
16898          new_path="$p/$path"
16899          break
16900        fi
16901      done
16902      IFS="$IFS_save"
16903    else
16904      # This is an absolute path, we can use it without further modifications.
16905      new_path="$path"
16906    fi
16907
16908    if test "x$new_path" = x; then
16909      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16910$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16911      has_space=`$ECHO "$complete" | $GREP " "`
16912      if test "x$has_space" != x; then
16913        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16914$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16915      fi
16916      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16917    fi
16918  fi
16919
16920  # Now join together the path and the arguments once again
16921  if test "x$arguments" != xEOL; then
16922    new_complete="$new_path ${arguments% *}"
16923  else
16924    new_complete="$new_path"
16925  fi
16926
16927  if test "x$complete" != "x$new_complete"; then
16928    FOUND_MAKE="$new_complete"
16929    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16930$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16931  fi
16932
16933        fi
16934      fi
16935    fi
16936  fi
16937
16938        fi
16939        PATH=$OLD_PATH
16940      fi
16941    fi
16942
16943    if test "x$FOUND_MAKE" = x; then
16944      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
16945    fi
16946  fi
16947
16948  MAKE=$FOUND_MAKE
16949
16950  { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5
16951$as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;}
16952
16953
16954
16955  # Test if find supports -delete
16956  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5
16957$as_echo_n "checking if find supports -delete... " >&6; }
16958  FIND_DELETE="-delete"
16959
16960  DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?)
16961
16962  echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete
16963
16964  TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1`
16965  if test -f $DELETEDIR/TestIfFindSupportsDelete; then
16966    # No, it does not.
16967    rm $DELETEDIR/TestIfFindSupportsDelete
16968    FIND_DELETE="-exec rm \{\} \+"
16969    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16970$as_echo "no" >&6; }
16971  else
16972    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16973$as_echo "yes" >&6; }
16974  fi
16975  rmdir $DELETEDIR
16976
16977
16978
16979  # These tools might not be installed by default,
16980  # need hint on how to install them.
16981
16982
16983
16984  # Publish this variable in the help.
16985
16986
16987  if test "x$UNZIP" = x; then
16988    # The variable is not set by user, try to locate tool using the code snippet
16989    for ac_prog in unzip
16990do
16991  # Extract the first word of "$ac_prog", so it can be a program name with args.
16992set dummy $ac_prog; ac_word=$2
16993{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16994$as_echo_n "checking for $ac_word... " >&6; }
16995if ${ac_cv_path_UNZIP+:} false; then :
16996  $as_echo_n "(cached) " >&6
16997else
16998  case $UNZIP in
16999  [\\/]* | ?:[\\/]*)
17000  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17001  ;;
17002  *)
17003  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17004for as_dir in $PATH
17005do
17006  IFS=$as_save_IFS
17007  test -z "$as_dir" && as_dir=.
17008    for ac_exec_ext in '' $ac_executable_extensions; do
17009  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17010    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17011    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17012    break 2
17013  fi
17014done
17015  done
17016IFS=$as_save_IFS
17017
17018  ;;
17019esac
17020fi
17021UNZIP=$ac_cv_path_UNZIP
17022if test -n "$UNZIP"; then
17023  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17024$as_echo "$UNZIP" >&6; }
17025else
17026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17027$as_echo "no" >&6; }
17028fi
17029
17030
17031  test -n "$UNZIP" && break
17032done
17033
17034  else
17035    # The variable is set, but is it from the command line or the environment?
17036
17037    # Try to remove the string !UNZIP! from our list.
17038    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/}
17039    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17040      # If it failed, the variable was not from the command line. Ignore it,
17041      # but warn the user (except for BASH, which is always set by the calling BASH).
17042      if test "xUNZIP" != xBASH; then
17043        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5
17044$as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;}
17045      fi
17046      # Try to locate tool using the code snippet
17047      for ac_prog in unzip
17048do
17049  # Extract the first word of "$ac_prog", so it can be a program name with args.
17050set dummy $ac_prog; ac_word=$2
17051{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17052$as_echo_n "checking for $ac_word... " >&6; }
17053if ${ac_cv_path_UNZIP+:} false; then :
17054  $as_echo_n "(cached) " >&6
17055else
17056  case $UNZIP in
17057  [\\/]* | ?:[\\/]*)
17058  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17059  ;;
17060  *)
17061  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17062for as_dir in $PATH
17063do
17064  IFS=$as_save_IFS
17065  test -z "$as_dir" && as_dir=.
17066    for ac_exec_ext in '' $ac_executable_extensions; do
17067  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17068    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17069    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17070    break 2
17071  fi
17072done
17073  done
17074IFS=$as_save_IFS
17075
17076  ;;
17077esac
17078fi
17079UNZIP=$ac_cv_path_UNZIP
17080if test -n "$UNZIP"; then
17081  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17082$as_echo "$UNZIP" >&6; }
17083else
17084  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17085$as_echo "no" >&6; }
17086fi
17087
17088
17089  test -n "$UNZIP" && break
17090done
17091
17092    else
17093      # If it succeeded, then it was overridden by the user. We will use it
17094      # for the tool.
17095
17096      # First remove it from the list of overridden variables, so we can test
17097      # for unknown variables in the end.
17098      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17099
17100      # Check if the provided tool contains a complete path.
17101      tool_specified="$UNZIP"
17102      tool_basename="${tool_specified##*/}"
17103      if test "x$tool_basename" = "x$tool_specified"; then
17104        # A command without a complete path is provided, search $PATH.
17105        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5
17106$as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;}
17107        # Extract the first word of "$tool_basename", so it can be a program name with args.
17108set dummy $tool_basename; ac_word=$2
17109{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17110$as_echo_n "checking for $ac_word... " >&6; }
17111if ${ac_cv_path_UNZIP+:} false; then :
17112  $as_echo_n "(cached) " >&6
17113else
17114  case $UNZIP in
17115  [\\/]* | ?:[\\/]*)
17116  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17117  ;;
17118  *)
17119  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17120for as_dir in $PATH
17121do
17122  IFS=$as_save_IFS
17123  test -z "$as_dir" && as_dir=.
17124    for ac_exec_ext in '' $ac_executable_extensions; do
17125  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17126    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17127    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17128    break 2
17129  fi
17130done
17131  done
17132IFS=$as_save_IFS
17133
17134  ;;
17135esac
17136fi
17137UNZIP=$ac_cv_path_UNZIP
17138if test -n "$UNZIP"; then
17139  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17140$as_echo "$UNZIP" >&6; }
17141else
17142  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17143$as_echo "no" >&6; }
17144fi
17145
17146
17147        if test "x$UNZIP" = x; then
17148          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17149        fi
17150      else
17151        # Otherwise we believe it is a complete path. Use it as it is.
17152        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5
17153$as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;}
17154        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5
17155$as_echo_n "checking for UNZIP... " >&6; }
17156        if test ! -x "$tool_specified"; then
17157          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17158$as_echo "not found" >&6; }
17159          as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17160        fi
17161        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17162$as_echo "$tool_specified" >&6; }
17163      fi
17164    fi
17165  fi
17166
17167
17168
17169  if test "x$UNZIP" = x; then
17170    as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5
17171  fi
17172
17173
17174
17175
17176
17177  # Publish this variable in the help.
17178
17179
17180  if test "x$ZIP" = x; then
17181    # The variable is not set by user, try to locate tool using the code snippet
17182    for ac_prog in zip
17183do
17184  # Extract the first word of "$ac_prog", so it can be a program name with args.
17185set dummy $ac_prog; ac_word=$2
17186{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17187$as_echo_n "checking for $ac_word... " >&6; }
17188if ${ac_cv_path_ZIP+:} false; then :
17189  $as_echo_n "(cached) " >&6
17190else
17191  case $ZIP in
17192  [\\/]* | ?:[\\/]*)
17193  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17194  ;;
17195  *)
17196  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17197for as_dir in $PATH
17198do
17199  IFS=$as_save_IFS
17200  test -z "$as_dir" && as_dir=.
17201    for ac_exec_ext in '' $ac_executable_extensions; do
17202  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17203    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17204    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17205    break 2
17206  fi
17207done
17208  done
17209IFS=$as_save_IFS
17210
17211  ;;
17212esac
17213fi
17214ZIP=$ac_cv_path_ZIP
17215if test -n "$ZIP"; then
17216  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17217$as_echo "$ZIP" >&6; }
17218else
17219  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17220$as_echo "no" >&6; }
17221fi
17222
17223
17224  test -n "$ZIP" && break
17225done
17226
17227  else
17228    # The variable is set, but is it from the command line or the environment?
17229
17230    # Try to remove the string !ZIP! from our list.
17231    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/}
17232    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17233      # If it failed, the variable was not from the command line. Ignore it,
17234      # but warn the user (except for BASH, which is always set by the calling BASH).
17235      if test "xZIP" != xBASH; then
17236        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5
17237$as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;}
17238      fi
17239      # Try to locate tool using the code snippet
17240      for ac_prog in zip
17241do
17242  # Extract the first word of "$ac_prog", so it can be a program name with args.
17243set dummy $ac_prog; ac_word=$2
17244{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17245$as_echo_n "checking for $ac_word... " >&6; }
17246if ${ac_cv_path_ZIP+:} false; then :
17247  $as_echo_n "(cached) " >&6
17248else
17249  case $ZIP in
17250  [\\/]* | ?:[\\/]*)
17251  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17252  ;;
17253  *)
17254  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17255for as_dir in $PATH
17256do
17257  IFS=$as_save_IFS
17258  test -z "$as_dir" && as_dir=.
17259    for ac_exec_ext in '' $ac_executable_extensions; do
17260  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17261    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17262    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17263    break 2
17264  fi
17265done
17266  done
17267IFS=$as_save_IFS
17268
17269  ;;
17270esac
17271fi
17272ZIP=$ac_cv_path_ZIP
17273if test -n "$ZIP"; then
17274  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17275$as_echo "$ZIP" >&6; }
17276else
17277  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17278$as_echo "no" >&6; }
17279fi
17280
17281
17282  test -n "$ZIP" && break
17283done
17284
17285    else
17286      # If it succeeded, then it was overridden by the user. We will use it
17287      # for the tool.
17288
17289      # First remove it from the list of overridden variables, so we can test
17290      # for unknown variables in the end.
17291      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17292
17293      # Check if the provided tool contains a complete path.
17294      tool_specified="$ZIP"
17295      tool_basename="${tool_specified##*/}"
17296      if test "x$tool_basename" = "x$tool_specified"; then
17297        # A command without a complete path is provided, search $PATH.
17298        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5
17299$as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;}
17300        # Extract the first word of "$tool_basename", so it can be a program name with args.
17301set dummy $tool_basename; ac_word=$2
17302{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17303$as_echo_n "checking for $ac_word... " >&6; }
17304if ${ac_cv_path_ZIP+:} false; then :
17305  $as_echo_n "(cached) " >&6
17306else
17307  case $ZIP in
17308  [\\/]* | ?:[\\/]*)
17309  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17310  ;;
17311  *)
17312  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17313for as_dir in $PATH
17314do
17315  IFS=$as_save_IFS
17316  test -z "$as_dir" && as_dir=.
17317    for ac_exec_ext in '' $ac_executable_extensions; do
17318  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17319    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17320    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17321    break 2
17322  fi
17323done
17324  done
17325IFS=$as_save_IFS
17326
17327  ;;
17328esac
17329fi
17330ZIP=$ac_cv_path_ZIP
17331if test -n "$ZIP"; then
17332  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17333$as_echo "$ZIP" >&6; }
17334else
17335  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17336$as_echo "no" >&6; }
17337fi
17338
17339
17340        if test "x$ZIP" = x; then
17341          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17342        fi
17343      else
17344        # Otherwise we believe it is a complete path. Use it as it is.
17345        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5
17346$as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;}
17347        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5
17348$as_echo_n "checking for ZIP... " >&6; }
17349        if test ! -x "$tool_specified"; then
17350          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17351$as_echo "not found" >&6; }
17352          as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17353        fi
17354        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17355$as_echo "$tool_specified" >&6; }
17356      fi
17357    fi
17358  fi
17359
17360
17361
17362  if test "x$ZIP" = x; then
17363    as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5
17364  fi
17365
17366
17367
17368  # Non-required basic tools
17369
17370
17371
17372  # Publish this variable in the help.
17373
17374
17375  if test "x$LDD" = x; then
17376    # The variable is not set by user, try to locate tool using the code snippet
17377    for ac_prog in ldd
17378do
17379  # Extract the first word of "$ac_prog", so it can be a program name with args.
17380set dummy $ac_prog; ac_word=$2
17381{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17382$as_echo_n "checking for $ac_word... " >&6; }
17383if ${ac_cv_path_LDD+:} false; then :
17384  $as_echo_n "(cached) " >&6
17385else
17386  case $LDD in
17387  [\\/]* | ?:[\\/]*)
17388  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17389  ;;
17390  *)
17391  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17392for as_dir in $PATH
17393do
17394  IFS=$as_save_IFS
17395  test -z "$as_dir" && as_dir=.
17396    for ac_exec_ext in '' $ac_executable_extensions; do
17397  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17398    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17399    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17400    break 2
17401  fi
17402done
17403  done
17404IFS=$as_save_IFS
17405
17406  ;;
17407esac
17408fi
17409LDD=$ac_cv_path_LDD
17410if test -n "$LDD"; then
17411  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17412$as_echo "$LDD" >&6; }
17413else
17414  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17415$as_echo "no" >&6; }
17416fi
17417
17418
17419  test -n "$LDD" && break
17420done
17421
17422  else
17423    # The variable is set, but is it from the command line or the environment?
17424
17425    # Try to remove the string !LDD! from our list.
17426    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/}
17427    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17428      # If it failed, the variable was not from the command line. Ignore it,
17429      # but warn the user (except for BASH, which is always set by the calling BASH).
17430      if test "xLDD" != xBASH; then
17431        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5
17432$as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;}
17433      fi
17434      # Try to locate tool using the code snippet
17435      for ac_prog in ldd
17436do
17437  # Extract the first word of "$ac_prog", so it can be a program name with args.
17438set dummy $ac_prog; ac_word=$2
17439{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17440$as_echo_n "checking for $ac_word... " >&6; }
17441if ${ac_cv_path_LDD+:} false; then :
17442  $as_echo_n "(cached) " >&6
17443else
17444  case $LDD in
17445  [\\/]* | ?:[\\/]*)
17446  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17447  ;;
17448  *)
17449  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17450for as_dir in $PATH
17451do
17452  IFS=$as_save_IFS
17453  test -z "$as_dir" && as_dir=.
17454    for ac_exec_ext in '' $ac_executable_extensions; do
17455  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17456    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17457    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17458    break 2
17459  fi
17460done
17461  done
17462IFS=$as_save_IFS
17463
17464  ;;
17465esac
17466fi
17467LDD=$ac_cv_path_LDD
17468if test -n "$LDD"; then
17469  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17470$as_echo "$LDD" >&6; }
17471else
17472  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17473$as_echo "no" >&6; }
17474fi
17475
17476
17477  test -n "$LDD" && break
17478done
17479
17480    else
17481      # If it succeeded, then it was overridden by the user. We will use it
17482      # for the tool.
17483
17484      # First remove it from the list of overridden variables, so we can test
17485      # for unknown variables in the end.
17486      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17487
17488      # Check if the provided tool contains a complete path.
17489      tool_specified="$LDD"
17490      tool_basename="${tool_specified##*/}"
17491      if test "x$tool_basename" = "x$tool_specified"; then
17492        # A command without a complete path is provided, search $PATH.
17493        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5
17494$as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;}
17495        # Extract the first word of "$tool_basename", so it can be a program name with args.
17496set dummy $tool_basename; ac_word=$2
17497{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17498$as_echo_n "checking for $ac_word... " >&6; }
17499if ${ac_cv_path_LDD+:} false; then :
17500  $as_echo_n "(cached) " >&6
17501else
17502  case $LDD in
17503  [\\/]* | ?:[\\/]*)
17504  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17505  ;;
17506  *)
17507  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17508for as_dir in $PATH
17509do
17510  IFS=$as_save_IFS
17511  test -z "$as_dir" && as_dir=.
17512    for ac_exec_ext in '' $ac_executable_extensions; do
17513  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17514    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17515    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17516    break 2
17517  fi
17518done
17519  done
17520IFS=$as_save_IFS
17521
17522  ;;
17523esac
17524fi
17525LDD=$ac_cv_path_LDD
17526if test -n "$LDD"; then
17527  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17528$as_echo "$LDD" >&6; }
17529else
17530  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17531$as_echo "no" >&6; }
17532fi
17533
17534
17535        if test "x$LDD" = x; then
17536          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17537        fi
17538      else
17539        # Otherwise we believe it is a complete path. Use it as it is.
17540        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5
17541$as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;}
17542        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5
17543$as_echo_n "checking for LDD... " >&6; }
17544        if test ! -x "$tool_specified"; then
17545          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17546$as_echo "not found" >&6; }
17547          as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5
17548        fi
17549        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17550$as_echo "$tool_specified" >&6; }
17551      fi
17552    fi
17553  fi
17554
17555
17556  if test "x$LDD" = "x"; then
17557    # List shared lib dependencies is used for
17558    # debug output and checking for forbidden dependencies.
17559    # We can build without it.
17560    LDD="true"
17561  fi
17562
17563
17564  # Publish this variable in the help.
17565
17566
17567  if test "x$OTOOL" = x; then
17568    # The variable is not set by user, try to locate tool using the code snippet
17569    for ac_prog in otool
17570do
17571  # Extract the first word of "$ac_prog", so it can be a program name with args.
17572set dummy $ac_prog; ac_word=$2
17573{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17574$as_echo_n "checking for $ac_word... " >&6; }
17575if ${ac_cv_path_OTOOL+:} false; then :
17576  $as_echo_n "(cached) " >&6
17577else
17578  case $OTOOL in
17579  [\\/]* | ?:[\\/]*)
17580  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17581  ;;
17582  *)
17583  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17584for as_dir in $PATH
17585do
17586  IFS=$as_save_IFS
17587  test -z "$as_dir" && as_dir=.
17588    for ac_exec_ext in '' $ac_executable_extensions; do
17589  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17590    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17591    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17592    break 2
17593  fi
17594done
17595  done
17596IFS=$as_save_IFS
17597
17598  ;;
17599esac
17600fi
17601OTOOL=$ac_cv_path_OTOOL
17602if test -n "$OTOOL"; then
17603  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17604$as_echo "$OTOOL" >&6; }
17605else
17606  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17607$as_echo "no" >&6; }
17608fi
17609
17610
17611  test -n "$OTOOL" && break
17612done
17613
17614  else
17615    # The variable is set, but is it from the command line or the environment?
17616
17617    # Try to remove the string !OTOOL! from our list.
17618    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/}
17619    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17620      # If it failed, the variable was not from the command line. Ignore it,
17621      # but warn the user (except for BASH, which is always set by the calling BASH).
17622      if test "xOTOOL" != xBASH; then
17623        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5
17624$as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;}
17625      fi
17626      # Try to locate tool using the code snippet
17627      for ac_prog in otool
17628do
17629  # Extract the first word of "$ac_prog", so it can be a program name with args.
17630set dummy $ac_prog; ac_word=$2
17631{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17632$as_echo_n "checking for $ac_word... " >&6; }
17633if ${ac_cv_path_OTOOL+:} false; then :
17634  $as_echo_n "(cached) " >&6
17635else
17636  case $OTOOL in
17637  [\\/]* | ?:[\\/]*)
17638  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17639  ;;
17640  *)
17641  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17642for as_dir in $PATH
17643do
17644  IFS=$as_save_IFS
17645  test -z "$as_dir" && as_dir=.
17646    for ac_exec_ext in '' $ac_executable_extensions; do
17647  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17648    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17649    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17650    break 2
17651  fi
17652done
17653  done
17654IFS=$as_save_IFS
17655
17656  ;;
17657esac
17658fi
17659OTOOL=$ac_cv_path_OTOOL
17660if test -n "$OTOOL"; then
17661  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17662$as_echo "$OTOOL" >&6; }
17663else
17664  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17665$as_echo "no" >&6; }
17666fi
17667
17668
17669  test -n "$OTOOL" && break
17670done
17671
17672    else
17673      # If it succeeded, then it was overridden by the user. We will use it
17674      # for the tool.
17675
17676      # First remove it from the list of overridden variables, so we can test
17677      # for unknown variables in the end.
17678      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17679
17680      # Check if the provided tool contains a complete path.
17681      tool_specified="$OTOOL"
17682      tool_basename="${tool_specified##*/}"
17683      if test "x$tool_basename" = "x$tool_specified"; then
17684        # A command without a complete path is provided, search $PATH.
17685        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5
17686$as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;}
17687        # Extract the first word of "$tool_basename", so it can be a program name with args.
17688set dummy $tool_basename; ac_word=$2
17689{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17690$as_echo_n "checking for $ac_word... " >&6; }
17691if ${ac_cv_path_OTOOL+:} false; then :
17692  $as_echo_n "(cached) " >&6
17693else
17694  case $OTOOL in
17695  [\\/]* | ?:[\\/]*)
17696  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17697  ;;
17698  *)
17699  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17700for as_dir in $PATH
17701do
17702  IFS=$as_save_IFS
17703  test -z "$as_dir" && as_dir=.
17704    for ac_exec_ext in '' $ac_executable_extensions; do
17705  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17706    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17707    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17708    break 2
17709  fi
17710done
17711  done
17712IFS=$as_save_IFS
17713
17714  ;;
17715esac
17716fi
17717OTOOL=$ac_cv_path_OTOOL
17718if test -n "$OTOOL"; then
17719  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17720$as_echo "$OTOOL" >&6; }
17721else
17722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17723$as_echo "no" >&6; }
17724fi
17725
17726
17727        if test "x$OTOOL" = x; then
17728          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17729        fi
17730      else
17731        # Otherwise we believe it is a complete path. Use it as it is.
17732        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5
17733$as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;}
17734        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5
17735$as_echo_n "checking for OTOOL... " >&6; }
17736        if test ! -x "$tool_specified"; then
17737          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17738$as_echo "not found" >&6; }
17739          as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5
17740        fi
17741        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17742$as_echo "$tool_specified" >&6; }
17743      fi
17744    fi
17745  fi
17746
17747
17748  if test "x$OTOOL" = "x"; then
17749    OTOOL="true"
17750  fi
17751
17752
17753  # Publish this variable in the help.
17754
17755
17756  if test "x$READELF" = x; then
17757    # The variable is not set by user, try to locate tool using the code snippet
17758    for ac_prog in greadelf readelf
17759do
17760  # Extract the first word of "$ac_prog", so it can be a program name with args.
17761set dummy $ac_prog; ac_word=$2
17762{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17763$as_echo_n "checking for $ac_word... " >&6; }
17764if ${ac_cv_path_READELF+:} false; then :
17765  $as_echo_n "(cached) " >&6
17766else
17767  case $READELF in
17768  [\\/]* | ?:[\\/]*)
17769  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17770  ;;
17771  *)
17772  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17773for as_dir in $PATH
17774do
17775  IFS=$as_save_IFS
17776  test -z "$as_dir" && as_dir=.
17777    for ac_exec_ext in '' $ac_executable_extensions; do
17778  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17779    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17780    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17781    break 2
17782  fi
17783done
17784  done
17785IFS=$as_save_IFS
17786
17787  ;;
17788esac
17789fi
17790READELF=$ac_cv_path_READELF
17791if test -n "$READELF"; then
17792  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17793$as_echo "$READELF" >&6; }
17794else
17795  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17796$as_echo "no" >&6; }
17797fi
17798
17799
17800  test -n "$READELF" && break
17801done
17802
17803  else
17804    # The variable is set, but is it from the command line or the environment?
17805
17806    # Try to remove the string !READELF! from our list.
17807    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/}
17808    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17809      # If it failed, the variable was not from the command line. Ignore it,
17810      # but warn the user (except for BASH, which is always set by the calling BASH).
17811      if test "xREADELF" != xBASH; then
17812        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5
17813$as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;}
17814      fi
17815      # Try to locate tool using the code snippet
17816      for ac_prog in greadelf readelf
17817do
17818  # Extract the first word of "$ac_prog", so it can be a program name with args.
17819set dummy $ac_prog; ac_word=$2
17820{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17821$as_echo_n "checking for $ac_word... " >&6; }
17822if ${ac_cv_path_READELF+:} false; then :
17823  $as_echo_n "(cached) " >&6
17824else
17825  case $READELF in
17826  [\\/]* | ?:[\\/]*)
17827  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17828  ;;
17829  *)
17830  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17831for as_dir in $PATH
17832do
17833  IFS=$as_save_IFS
17834  test -z "$as_dir" && as_dir=.
17835    for ac_exec_ext in '' $ac_executable_extensions; do
17836  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17837    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17838    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17839    break 2
17840  fi
17841done
17842  done
17843IFS=$as_save_IFS
17844
17845  ;;
17846esac
17847fi
17848READELF=$ac_cv_path_READELF
17849if test -n "$READELF"; then
17850  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17851$as_echo "$READELF" >&6; }
17852else
17853  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17854$as_echo "no" >&6; }
17855fi
17856
17857
17858  test -n "$READELF" && break
17859done
17860
17861    else
17862      # If it succeeded, then it was overridden by the user. We will use it
17863      # for the tool.
17864
17865      # First remove it from the list of overridden variables, so we can test
17866      # for unknown variables in the end.
17867      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17868
17869      # Check if the provided tool contains a complete path.
17870      tool_specified="$READELF"
17871      tool_basename="${tool_specified##*/}"
17872      if test "x$tool_basename" = "x$tool_specified"; then
17873        # A command without a complete path is provided, search $PATH.
17874        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5
17875$as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;}
17876        # Extract the first word of "$tool_basename", so it can be a program name with args.
17877set dummy $tool_basename; ac_word=$2
17878{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17879$as_echo_n "checking for $ac_word... " >&6; }
17880if ${ac_cv_path_READELF+:} false; then :
17881  $as_echo_n "(cached) " >&6
17882else
17883  case $READELF in
17884  [\\/]* | ?:[\\/]*)
17885  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17886  ;;
17887  *)
17888  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17889for as_dir in $PATH
17890do
17891  IFS=$as_save_IFS
17892  test -z "$as_dir" && as_dir=.
17893    for ac_exec_ext in '' $ac_executable_extensions; do
17894  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17895    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17896    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17897    break 2
17898  fi
17899done
17900  done
17901IFS=$as_save_IFS
17902
17903  ;;
17904esac
17905fi
17906READELF=$ac_cv_path_READELF
17907if test -n "$READELF"; then
17908  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17909$as_echo "$READELF" >&6; }
17910else
17911  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17912$as_echo "no" >&6; }
17913fi
17914
17915
17916        if test "x$READELF" = x; then
17917          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17918        fi
17919      else
17920        # Otherwise we believe it is a complete path. Use it as it is.
17921        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5
17922$as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;}
17923        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5
17924$as_echo_n "checking for READELF... " >&6; }
17925        if test ! -x "$tool_specified"; then
17926          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17927$as_echo "not found" >&6; }
17928          as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5
17929        fi
17930        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17931$as_echo "$tool_specified" >&6; }
17932      fi
17933    fi
17934  fi
17935
17936
17937
17938
17939  # Publish this variable in the help.
17940
17941
17942  if test "x$HG" = x; then
17943    # The variable is not set by user, try to locate tool using the code snippet
17944    for ac_prog in hg
17945do
17946  # Extract the first word of "$ac_prog", so it can be a program name with args.
17947set dummy $ac_prog; ac_word=$2
17948{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17949$as_echo_n "checking for $ac_word... " >&6; }
17950if ${ac_cv_path_HG+:} false; then :
17951  $as_echo_n "(cached) " >&6
17952else
17953  case $HG in
17954  [\\/]* | ?:[\\/]*)
17955  ac_cv_path_HG="$HG" # Let the user override the test with a path.
17956  ;;
17957  *)
17958  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17959for as_dir in $PATH
17960do
17961  IFS=$as_save_IFS
17962  test -z "$as_dir" && as_dir=.
17963    for ac_exec_ext in '' $ac_executable_extensions; do
17964  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17965    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17966    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17967    break 2
17968  fi
17969done
17970  done
17971IFS=$as_save_IFS
17972
17973  ;;
17974esac
17975fi
17976HG=$ac_cv_path_HG
17977if test -n "$HG"; then
17978  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17979$as_echo "$HG" >&6; }
17980else
17981  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17982$as_echo "no" >&6; }
17983fi
17984
17985
17986  test -n "$HG" && break
17987done
17988
17989  else
17990    # The variable is set, but is it from the command line or the environment?
17991
17992    # Try to remove the string !HG! from our list.
17993    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/}
17994    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17995      # If it failed, the variable was not from the command line. Ignore it,
17996      # but warn the user (except for BASH, which is always set by the calling BASH).
17997      if test "xHG" != xBASH; then
17998        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5
17999$as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;}
18000      fi
18001      # Try to locate tool using the code snippet
18002      for ac_prog in hg
18003do
18004  # Extract the first word of "$ac_prog", so it can be a program name with args.
18005set dummy $ac_prog; ac_word=$2
18006{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18007$as_echo_n "checking for $ac_word... " >&6; }
18008if ${ac_cv_path_HG+:} false; then :
18009  $as_echo_n "(cached) " >&6
18010else
18011  case $HG in
18012  [\\/]* | ?:[\\/]*)
18013  ac_cv_path_HG="$HG" # Let the user override the test with a path.
18014  ;;
18015  *)
18016  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18017for as_dir in $PATH
18018do
18019  IFS=$as_save_IFS
18020  test -z "$as_dir" && as_dir=.
18021    for ac_exec_ext in '' $ac_executable_extensions; do
18022  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18023    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
18024    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18025    break 2
18026  fi
18027done
18028  done
18029IFS=$as_save_IFS
18030
18031  ;;
18032esac
18033fi
18034HG=$ac_cv_path_HG
18035if test -n "$HG"; then
18036  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
18037$as_echo "$HG" >&6; }
18038else
18039  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18040$as_echo "no" >&6; }
18041fi
18042
18043
18044  test -n "$HG" && break
18045done
18046
18047    else
18048      # If it succeeded, then it was overridden by the user. We will use it
18049      # for the tool.
18050
18051      # First remove it from the list of overridden variables, so we can test
18052      # for unknown variables in the end.
18053      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18054
18055      # Check if the provided tool contains a complete path.
18056      tool_specified="$HG"
18057      tool_basename="${tool_specified##*/}"
18058      if test "x$tool_basename" = "x$tool_specified"; then
18059        # A command without a complete path is provided, search $PATH.
18060        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5
18061$as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;}
18062        # Extract the first word of "$tool_basename", so it can be a program name with args.
18063set dummy $tool_basename; ac_word=$2
18064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18065$as_echo_n "checking for $ac_word... " >&6; }
18066if ${ac_cv_path_HG+:} false; then :
18067  $as_echo_n "(cached) " >&6
18068else
18069  case $HG in
18070  [\\/]* | ?:[\\/]*)
18071  ac_cv_path_HG="$HG" # Let the user override the test with a path.
18072  ;;
18073  *)
18074  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18075for as_dir in $PATH
18076do
18077  IFS=$as_save_IFS
18078  test -z "$as_dir" && as_dir=.
18079    for ac_exec_ext in '' $ac_executable_extensions; do
18080  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18081    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
18082    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18083    break 2
18084  fi
18085done
18086  done
18087IFS=$as_save_IFS
18088
18089  ;;
18090esac
18091fi
18092HG=$ac_cv_path_HG
18093if test -n "$HG"; then
18094  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
18095$as_echo "$HG" >&6; }
18096else
18097  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18098$as_echo "no" >&6; }
18099fi
18100
18101
18102        if test "x$HG" = x; then
18103          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18104        fi
18105      else
18106        # Otherwise we believe it is a complete path. Use it as it is.
18107        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5
18108$as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;}
18109        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5
18110$as_echo_n "checking for HG... " >&6; }
18111        if test ! -x "$tool_specified"; then
18112          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18113$as_echo "not found" >&6; }
18114          as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5
18115        fi
18116        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18117$as_echo "$tool_specified" >&6; }
18118      fi
18119    fi
18120  fi
18121
18122
18123
18124
18125  # Publish this variable in the help.
18126
18127
18128  if test "x$STAT" = x; then
18129    # The variable is not set by user, try to locate tool using the code snippet
18130    for ac_prog in stat
18131do
18132  # Extract the first word of "$ac_prog", so it can be a program name with args.
18133set dummy $ac_prog; ac_word=$2
18134{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18135$as_echo_n "checking for $ac_word... " >&6; }
18136if ${ac_cv_path_STAT+:} false; then :
18137  $as_echo_n "(cached) " >&6
18138else
18139  case $STAT in
18140  [\\/]* | ?:[\\/]*)
18141  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18142  ;;
18143  *)
18144  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18145for as_dir in $PATH
18146do
18147  IFS=$as_save_IFS
18148  test -z "$as_dir" && as_dir=.
18149    for ac_exec_ext in '' $ac_executable_extensions; do
18150  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18151    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18152    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18153    break 2
18154  fi
18155done
18156  done
18157IFS=$as_save_IFS
18158
18159  ;;
18160esac
18161fi
18162STAT=$ac_cv_path_STAT
18163if test -n "$STAT"; then
18164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18165$as_echo "$STAT" >&6; }
18166else
18167  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18168$as_echo "no" >&6; }
18169fi
18170
18171
18172  test -n "$STAT" && break
18173done
18174
18175  else
18176    # The variable is set, but is it from the command line or the environment?
18177
18178    # Try to remove the string !STAT! from our list.
18179    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/}
18180    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18181      # If it failed, the variable was not from the command line. Ignore it,
18182      # but warn the user (except for BASH, which is always set by the calling BASH).
18183      if test "xSTAT" != xBASH; then
18184        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5
18185$as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;}
18186      fi
18187      # Try to locate tool using the code snippet
18188      for ac_prog in stat
18189do
18190  # Extract the first word of "$ac_prog", so it can be a program name with args.
18191set dummy $ac_prog; ac_word=$2
18192{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18193$as_echo_n "checking for $ac_word... " >&6; }
18194if ${ac_cv_path_STAT+:} false; then :
18195  $as_echo_n "(cached) " >&6
18196else
18197  case $STAT in
18198  [\\/]* | ?:[\\/]*)
18199  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18200  ;;
18201  *)
18202  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18203for as_dir in $PATH
18204do
18205  IFS=$as_save_IFS
18206  test -z "$as_dir" && as_dir=.
18207    for ac_exec_ext in '' $ac_executable_extensions; do
18208  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18209    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18210    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18211    break 2
18212  fi
18213done
18214  done
18215IFS=$as_save_IFS
18216
18217  ;;
18218esac
18219fi
18220STAT=$ac_cv_path_STAT
18221if test -n "$STAT"; then
18222  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18223$as_echo "$STAT" >&6; }
18224else
18225  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18226$as_echo "no" >&6; }
18227fi
18228
18229
18230  test -n "$STAT" && break
18231done
18232
18233    else
18234      # If it succeeded, then it was overridden by the user. We will use it
18235      # for the tool.
18236
18237      # First remove it from the list of overridden variables, so we can test
18238      # for unknown variables in the end.
18239      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18240
18241      # Check if the provided tool contains a complete path.
18242      tool_specified="$STAT"
18243      tool_basename="${tool_specified##*/}"
18244      if test "x$tool_basename" = "x$tool_specified"; then
18245        # A command without a complete path is provided, search $PATH.
18246        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5
18247$as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;}
18248        # Extract the first word of "$tool_basename", so it can be a program name with args.
18249set dummy $tool_basename; ac_word=$2
18250{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18251$as_echo_n "checking for $ac_word... " >&6; }
18252if ${ac_cv_path_STAT+:} false; then :
18253  $as_echo_n "(cached) " >&6
18254else
18255  case $STAT in
18256  [\\/]* | ?:[\\/]*)
18257  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18258  ;;
18259  *)
18260  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18261for as_dir in $PATH
18262do
18263  IFS=$as_save_IFS
18264  test -z "$as_dir" && as_dir=.
18265    for ac_exec_ext in '' $ac_executable_extensions; do
18266  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18267    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18268    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18269    break 2
18270  fi
18271done
18272  done
18273IFS=$as_save_IFS
18274
18275  ;;
18276esac
18277fi
18278STAT=$ac_cv_path_STAT
18279if test -n "$STAT"; then
18280  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18281$as_echo "$STAT" >&6; }
18282else
18283  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18284$as_echo "no" >&6; }
18285fi
18286
18287
18288        if test "x$STAT" = x; then
18289          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18290        fi
18291      else
18292        # Otherwise we believe it is a complete path. Use it as it is.
18293        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5
18294$as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;}
18295        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5
18296$as_echo_n "checking for STAT... " >&6; }
18297        if test ! -x "$tool_specified"; then
18298          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18299$as_echo "not found" >&6; }
18300          as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5
18301        fi
18302        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18303$as_echo "$tool_specified" >&6; }
18304      fi
18305    fi
18306  fi
18307
18308
18309
18310
18311  # Publish this variable in the help.
18312
18313
18314  if test "x$TIME" = x; then
18315    # The variable is not set by user, try to locate tool using the code snippet
18316    for ac_prog in time
18317do
18318  # Extract the first word of "$ac_prog", so it can be a program name with args.
18319set dummy $ac_prog; ac_word=$2
18320{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18321$as_echo_n "checking for $ac_word... " >&6; }
18322if ${ac_cv_path_TIME+:} false; then :
18323  $as_echo_n "(cached) " >&6
18324else
18325  case $TIME in
18326  [\\/]* | ?:[\\/]*)
18327  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18328  ;;
18329  *)
18330  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18331for as_dir in $PATH
18332do
18333  IFS=$as_save_IFS
18334  test -z "$as_dir" && as_dir=.
18335    for ac_exec_ext in '' $ac_executable_extensions; do
18336  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18337    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18338    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18339    break 2
18340  fi
18341done
18342  done
18343IFS=$as_save_IFS
18344
18345  ;;
18346esac
18347fi
18348TIME=$ac_cv_path_TIME
18349if test -n "$TIME"; then
18350  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18351$as_echo "$TIME" >&6; }
18352else
18353  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18354$as_echo "no" >&6; }
18355fi
18356
18357
18358  test -n "$TIME" && break
18359done
18360
18361  else
18362    # The variable is set, but is it from the command line or the environment?
18363
18364    # Try to remove the string !TIME! from our list.
18365    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/}
18366    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18367      # If it failed, the variable was not from the command line. Ignore it,
18368      # but warn the user (except for BASH, which is always set by the calling BASH).
18369      if test "xTIME" != xBASH; then
18370        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5
18371$as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;}
18372      fi
18373      # Try to locate tool using the code snippet
18374      for ac_prog in time
18375do
18376  # Extract the first word of "$ac_prog", so it can be a program name with args.
18377set dummy $ac_prog; ac_word=$2
18378{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18379$as_echo_n "checking for $ac_word... " >&6; }
18380if ${ac_cv_path_TIME+:} false; then :
18381  $as_echo_n "(cached) " >&6
18382else
18383  case $TIME in
18384  [\\/]* | ?:[\\/]*)
18385  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18386  ;;
18387  *)
18388  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18389for as_dir in $PATH
18390do
18391  IFS=$as_save_IFS
18392  test -z "$as_dir" && as_dir=.
18393    for ac_exec_ext in '' $ac_executable_extensions; do
18394  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18395    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18396    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18397    break 2
18398  fi
18399done
18400  done
18401IFS=$as_save_IFS
18402
18403  ;;
18404esac
18405fi
18406TIME=$ac_cv_path_TIME
18407if test -n "$TIME"; then
18408  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18409$as_echo "$TIME" >&6; }
18410else
18411  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18412$as_echo "no" >&6; }
18413fi
18414
18415
18416  test -n "$TIME" && break
18417done
18418
18419    else
18420      # If it succeeded, then it was overridden by the user. We will use it
18421      # for the tool.
18422
18423      # First remove it from the list of overridden variables, so we can test
18424      # for unknown variables in the end.
18425      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18426
18427      # Check if the provided tool contains a complete path.
18428      tool_specified="$TIME"
18429      tool_basename="${tool_specified##*/}"
18430      if test "x$tool_basename" = "x$tool_specified"; then
18431        # A command without a complete path is provided, search $PATH.
18432        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5
18433$as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;}
18434        # Extract the first word of "$tool_basename", so it can be a program name with args.
18435set dummy $tool_basename; ac_word=$2
18436{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18437$as_echo_n "checking for $ac_word... " >&6; }
18438if ${ac_cv_path_TIME+:} false; then :
18439  $as_echo_n "(cached) " >&6
18440else
18441  case $TIME in
18442  [\\/]* | ?:[\\/]*)
18443  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18444  ;;
18445  *)
18446  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18447for as_dir in $PATH
18448do
18449  IFS=$as_save_IFS
18450  test -z "$as_dir" && as_dir=.
18451    for ac_exec_ext in '' $ac_executable_extensions; do
18452  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18453    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18454    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18455    break 2
18456  fi
18457done
18458  done
18459IFS=$as_save_IFS
18460
18461  ;;
18462esac
18463fi
18464TIME=$ac_cv_path_TIME
18465if test -n "$TIME"; then
18466  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18467$as_echo "$TIME" >&6; }
18468else
18469  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18470$as_echo "no" >&6; }
18471fi
18472
18473
18474        if test "x$TIME" = x; then
18475          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18476        fi
18477      else
18478        # Otherwise we believe it is a complete path. Use it as it is.
18479        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5
18480$as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;}
18481        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5
18482$as_echo_n "checking for TIME... " >&6; }
18483        if test ! -x "$tool_specified"; then
18484          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18485$as_echo "not found" >&6; }
18486          as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5
18487        fi
18488        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18489$as_echo "$tool_specified" >&6; }
18490      fi
18491    fi
18492  fi
18493
18494
18495  # Check if it's GNU time
18496  IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'`
18497  if test "x$IS_GNU_TIME" != x; then
18498    IS_GNU_TIME=yes
18499  else
18500    IS_GNU_TIME=no
18501  fi
18502
18503
18504  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
18505
18506
18507
18508  # Publish this variable in the help.
18509
18510
18511  if test "x$COMM" = x; then
18512    # The variable is not set by user, try to locate tool using the code snippet
18513    for ac_prog in comm
18514do
18515  # Extract the first word of "$ac_prog", so it can be a program name with args.
18516set dummy $ac_prog; ac_word=$2
18517{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18518$as_echo_n "checking for $ac_word... " >&6; }
18519if ${ac_cv_path_COMM+:} false; then :
18520  $as_echo_n "(cached) " >&6
18521else
18522  case $COMM in
18523  [\\/]* | ?:[\\/]*)
18524  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18525  ;;
18526  *)
18527  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18528for as_dir in $PATH
18529do
18530  IFS=$as_save_IFS
18531  test -z "$as_dir" && as_dir=.
18532    for ac_exec_ext in '' $ac_executable_extensions; do
18533  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18534    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18535    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18536    break 2
18537  fi
18538done
18539  done
18540IFS=$as_save_IFS
18541
18542  ;;
18543esac
18544fi
18545COMM=$ac_cv_path_COMM
18546if test -n "$COMM"; then
18547  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18548$as_echo "$COMM" >&6; }
18549else
18550  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18551$as_echo "no" >&6; }
18552fi
18553
18554
18555  test -n "$COMM" && break
18556done
18557
18558  else
18559    # The variable is set, but is it from the command line or the environment?
18560
18561    # Try to remove the string !COMM! from our list.
18562    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
18563    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18564      # If it failed, the variable was not from the command line. Ignore it,
18565      # but warn the user (except for BASH, which is always set by the calling BASH).
18566      if test "xCOMM" != xBASH; then
18567        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
18568$as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
18569      fi
18570      # Try to locate tool using the code snippet
18571      for ac_prog in comm
18572do
18573  # Extract the first word of "$ac_prog", so it can be a program name with args.
18574set dummy $ac_prog; ac_word=$2
18575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18576$as_echo_n "checking for $ac_word... " >&6; }
18577if ${ac_cv_path_COMM+:} false; then :
18578  $as_echo_n "(cached) " >&6
18579else
18580  case $COMM in
18581  [\\/]* | ?:[\\/]*)
18582  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18583  ;;
18584  *)
18585  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18586for as_dir in $PATH
18587do
18588  IFS=$as_save_IFS
18589  test -z "$as_dir" && as_dir=.
18590    for ac_exec_ext in '' $ac_executable_extensions; do
18591  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18592    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18593    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18594    break 2
18595  fi
18596done
18597  done
18598IFS=$as_save_IFS
18599
18600  ;;
18601esac
18602fi
18603COMM=$ac_cv_path_COMM
18604if test -n "$COMM"; then
18605  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18606$as_echo "$COMM" >&6; }
18607else
18608  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18609$as_echo "no" >&6; }
18610fi
18611
18612
18613  test -n "$COMM" && break
18614done
18615
18616    else
18617      # If it succeeded, then it was overridden by the user. We will use it
18618      # for the tool.
18619
18620      # First remove it from the list of overridden variables, so we can test
18621      # for unknown variables in the end.
18622      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18623
18624      # Check if the provided tool contains a complete path.
18625      tool_specified="$COMM"
18626      tool_basename="${tool_specified##*/}"
18627      if test "x$tool_basename" = "x$tool_specified"; then
18628        # A command without a complete path is provided, search $PATH.
18629        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
18630$as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
18631        # Extract the first word of "$tool_basename", so it can be a program name with args.
18632set dummy $tool_basename; ac_word=$2
18633{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18634$as_echo_n "checking for $ac_word... " >&6; }
18635if ${ac_cv_path_COMM+:} false; then :
18636  $as_echo_n "(cached) " >&6
18637else
18638  case $COMM in
18639  [\\/]* | ?:[\\/]*)
18640  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18641  ;;
18642  *)
18643  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18644for as_dir in $PATH
18645do
18646  IFS=$as_save_IFS
18647  test -z "$as_dir" && as_dir=.
18648    for ac_exec_ext in '' $ac_executable_extensions; do
18649  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18650    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18651    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18652    break 2
18653  fi
18654done
18655  done
18656IFS=$as_save_IFS
18657
18658  ;;
18659esac
18660fi
18661COMM=$ac_cv_path_COMM
18662if test -n "$COMM"; then
18663  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18664$as_echo "$COMM" >&6; }
18665else
18666  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18667$as_echo "no" >&6; }
18668fi
18669
18670
18671        if test "x$COMM" = x; then
18672          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18673        fi
18674      else
18675        # Otherwise we believe it is a complete path. Use it as it is.
18676        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
18677$as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
18678        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
18679$as_echo_n "checking for COMM... " >&6; }
18680        if test ! -x "$tool_specified"; then
18681          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18682$as_echo "not found" >&6; }
18683          as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
18684        fi
18685        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18686$as_echo "$tool_specified" >&6; }
18687      fi
18688    fi
18689  fi
18690
18691
18692
18693  if test "x$COMM" = x; then
18694    as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
18695  fi
18696
18697
18698  fi
18699
18700  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
18701
18702
18703
18704  # Publish this variable in the help.
18705
18706
18707  if test "x$DSYMUTIL" = x; then
18708    # The variable is not set by user, try to locate tool using the code snippet
18709    for ac_prog in dsymutil
18710do
18711  # Extract the first word of "$ac_prog", so it can be a program name with args.
18712set dummy $ac_prog; ac_word=$2
18713{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18714$as_echo_n "checking for $ac_word... " >&6; }
18715if ${ac_cv_path_DSYMUTIL+:} false; then :
18716  $as_echo_n "(cached) " >&6
18717else
18718  case $DSYMUTIL in
18719  [\\/]* | ?:[\\/]*)
18720  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18721  ;;
18722  *)
18723  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18724for as_dir in $PATH
18725do
18726  IFS=$as_save_IFS
18727  test -z "$as_dir" && as_dir=.
18728    for ac_exec_ext in '' $ac_executable_extensions; do
18729  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18730    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18731    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18732    break 2
18733  fi
18734done
18735  done
18736IFS=$as_save_IFS
18737
18738  ;;
18739esac
18740fi
18741DSYMUTIL=$ac_cv_path_DSYMUTIL
18742if test -n "$DSYMUTIL"; then
18743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18744$as_echo "$DSYMUTIL" >&6; }
18745else
18746  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18747$as_echo "no" >&6; }
18748fi
18749
18750
18751  test -n "$DSYMUTIL" && break
18752done
18753
18754  else
18755    # The variable is set, but is it from the command line or the environment?
18756
18757    # Try to remove the string !DSYMUTIL! from our list.
18758    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/}
18759    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18760      # If it failed, the variable was not from the command line. Ignore it,
18761      # but warn the user (except for BASH, which is always set by the calling BASH).
18762      if test "xDSYMUTIL" != xBASH; then
18763        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5
18764$as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;}
18765      fi
18766      # Try to locate tool using the code snippet
18767      for ac_prog in dsymutil
18768do
18769  # Extract the first word of "$ac_prog", so it can be a program name with args.
18770set dummy $ac_prog; ac_word=$2
18771{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18772$as_echo_n "checking for $ac_word... " >&6; }
18773if ${ac_cv_path_DSYMUTIL+:} false; then :
18774  $as_echo_n "(cached) " >&6
18775else
18776  case $DSYMUTIL in
18777  [\\/]* | ?:[\\/]*)
18778  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18779  ;;
18780  *)
18781  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18782for as_dir in $PATH
18783do
18784  IFS=$as_save_IFS
18785  test -z "$as_dir" && as_dir=.
18786    for ac_exec_ext in '' $ac_executable_extensions; do
18787  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18788    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18789    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18790    break 2
18791  fi
18792done
18793  done
18794IFS=$as_save_IFS
18795
18796  ;;
18797esac
18798fi
18799DSYMUTIL=$ac_cv_path_DSYMUTIL
18800if test -n "$DSYMUTIL"; then
18801  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18802$as_echo "$DSYMUTIL" >&6; }
18803else
18804  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18805$as_echo "no" >&6; }
18806fi
18807
18808
18809  test -n "$DSYMUTIL" && break
18810done
18811
18812    else
18813      # If it succeeded, then it was overridden by the user. We will use it
18814      # for the tool.
18815
18816      # First remove it from the list of overridden variables, so we can test
18817      # for unknown variables in the end.
18818      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18819
18820      # Check if the provided tool contains a complete path.
18821      tool_specified="$DSYMUTIL"
18822      tool_basename="${tool_specified##*/}"
18823      if test "x$tool_basename" = "x$tool_specified"; then
18824        # A command without a complete path is provided, search $PATH.
18825        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5
18826$as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;}
18827        # Extract the first word of "$tool_basename", so it can be a program name with args.
18828set dummy $tool_basename; ac_word=$2
18829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18830$as_echo_n "checking for $ac_word... " >&6; }
18831if ${ac_cv_path_DSYMUTIL+:} false; then :
18832  $as_echo_n "(cached) " >&6
18833else
18834  case $DSYMUTIL in
18835  [\\/]* | ?:[\\/]*)
18836  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18837  ;;
18838  *)
18839  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18840for as_dir in $PATH
18841do
18842  IFS=$as_save_IFS
18843  test -z "$as_dir" && as_dir=.
18844    for ac_exec_ext in '' $ac_executable_extensions; do
18845  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18846    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18847    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18848    break 2
18849  fi
18850done
18851  done
18852IFS=$as_save_IFS
18853
18854  ;;
18855esac
18856fi
18857DSYMUTIL=$ac_cv_path_DSYMUTIL
18858if test -n "$DSYMUTIL"; then
18859  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18860$as_echo "$DSYMUTIL" >&6; }
18861else
18862  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18863$as_echo "no" >&6; }
18864fi
18865
18866
18867        if test "x$DSYMUTIL" = x; then
18868          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18869        fi
18870      else
18871        # Otherwise we believe it is a complete path. Use it as it is.
18872        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5
18873$as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;}
18874        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5
18875$as_echo_n "checking for DSYMUTIL... " >&6; }
18876        if test ! -x "$tool_specified"; then
18877          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18878$as_echo "not found" >&6; }
18879          as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5
18880        fi
18881        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18882$as_echo "$tool_specified" >&6; }
18883      fi
18884    fi
18885  fi
18886
18887
18888
18889  if test "x$DSYMUTIL" = x; then
18890    as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5
18891  fi
18892
18893
18894
18895
18896
18897  # Publish this variable in the help.
18898
18899
18900  if test "x$XATTR" = x; then
18901    # The variable is not set by user, try to locate tool using the code snippet
18902    for ac_prog in xattr
18903do
18904  # Extract the first word of "$ac_prog", so it can be a program name with args.
18905set dummy $ac_prog; ac_word=$2
18906{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18907$as_echo_n "checking for $ac_word... " >&6; }
18908if ${ac_cv_path_XATTR+:} false; then :
18909  $as_echo_n "(cached) " >&6
18910else
18911  case $XATTR in
18912  [\\/]* | ?:[\\/]*)
18913  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18914  ;;
18915  *)
18916  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18917for as_dir in $PATH
18918do
18919  IFS=$as_save_IFS
18920  test -z "$as_dir" && as_dir=.
18921    for ac_exec_ext in '' $ac_executable_extensions; do
18922  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18923    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18924    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18925    break 2
18926  fi
18927done
18928  done
18929IFS=$as_save_IFS
18930
18931  ;;
18932esac
18933fi
18934XATTR=$ac_cv_path_XATTR
18935if test -n "$XATTR"; then
18936  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18937$as_echo "$XATTR" >&6; }
18938else
18939  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18940$as_echo "no" >&6; }
18941fi
18942
18943
18944  test -n "$XATTR" && break
18945done
18946
18947  else
18948    # The variable is set, but is it from the command line or the environment?
18949
18950    # Try to remove the string !XATTR! from our list.
18951    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/}
18952    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18953      # If it failed, the variable was not from the command line. Ignore it,
18954      # but warn the user (except for BASH, which is always set by the calling BASH).
18955      if test "xXATTR" != xBASH; then
18956        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5
18957$as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;}
18958      fi
18959      # Try to locate tool using the code snippet
18960      for ac_prog in xattr
18961do
18962  # Extract the first word of "$ac_prog", so it can be a program name with args.
18963set dummy $ac_prog; ac_word=$2
18964{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18965$as_echo_n "checking for $ac_word... " >&6; }
18966if ${ac_cv_path_XATTR+:} false; then :
18967  $as_echo_n "(cached) " >&6
18968else
18969  case $XATTR in
18970  [\\/]* | ?:[\\/]*)
18971  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18972  ;;
18973  *)
18974  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18975for as_dir in $PATH
18976do
18977  IFS=$as_save_IFS
18978  test -z "$as_dir" && as_dir=.
18979    for ac_exec_ext in '' $ac_executable_extensions; do
18980  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18981    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18982    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18983    break 2
18984  fi
18985done
18986  done
18987IFS=$as_save_IFS
18988
18989  ;;
18990esac
18991fi
18992XATTR=$ac_cv_path_XATTR
18993if test -n "$XATTR"; then
18994  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18995$as_echo "$XATTR" >&6; }
18996else
18997  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18998$as_echo "no" >&6; }
18999fi
19000
19001
19002  test -n "$XATTR" && break
19003done
19004
19005    else
19006      # If it succeeded, then it was overridden by the user. We will use it
19007      # for the tool.
19008
19009      # First remove it from the list of overridden variables, so we can test
19010      # for unknown variables in the end.
19011      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19012
19013      # Check if the provided tool contains a complete path.
19014      tool_specified="$XATTR"
19015      tool_basename="${tool_specified##*/}"
19016      if test "x$tool_basename" = "x$tool_specified"; then
19017        # A command without a complete path is provided, search $PATH.
19018        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5
19019$as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;}
19020        # Extract the first word of "$tool_basename", so it can be a program name with args.
19021set dummy $tool_basename; ac_word=$2
19022{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19023$as_echo_n "checking for $ac_word... " >&6; }
19024if ${ac_cv_path_XATTR+:} false; then :
19025  $as_echo_n "(cached) " >&6
19026else
19027  case $XATTR in
19028  [\\/]* | ?:[\\/]*)
19029  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
19030  ;;
19031  *)
19032  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19033for as_dir in $PATH
19034do
19035  IFS=$as_save_IFS
19036  test -z "$as_dir" && as_dir=.
19037    for ac_exec_ext in '' $ac_executable_extensions; do
19038  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19039    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
19040    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19041    break 2
19042  fi
19043done
19044  done
19045IFS=$as_save_IFS
19046
19047  ;;
19048esac
19049fi
19050XATTR=$ac_cv_path_XATTR
19051if test -n "$XATTR"; then
19052  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
19053$as_echo "$XATTR" >&6; }
19054else
19055  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19056$as_echo "no" >&6; }
19057fi
19058
19059
19060        if test "x$XATTR" = x; then
19061          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19062        fi
19063      else
19064        # Otherwise we believe it is a complete path. Use it as it is.
19065        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5
19066$as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;}
19067        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5
19068$as_echo_n "checking for XATTR... " >&6; }
19069        if test ! -x "$tool_specified"; then
19070          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19071$as_echo "not found" >&6; }
19072          as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5
19073        fi
19074        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19075$as_echo "$tool_specified" >&6; }
19076      fi
19077    fi
19078  fi
19079
19080
19081
19082  if test "x$XATTR" = x; then
19083    as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5
19084  fi
19085
19086
19087
19088
19089  # Publish this variable in the help.
19090
19091
19092  if test "x$CODESIGN" = x; then
19093    # The variable is not set by user, try to locate tool using the code snippet
19094    for ac_prog in codesign
19095do
19096  # Extract the first word of "$ac_prog", so it can be a program name with args.
19097set dummy $ac_prog; ac_word=$2
19098{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19099$as_echo_n "checking for $ac_word... " >&6; }
19100if ${ac_cv_path_CODESIGN+:} false; then :
19101  $as_echo_n "(cached) " >&6
19102else
19103  case $CODESIGN in
19104  [\\/]* | ?:[\\/]*)
19105  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19106  ;;
19107  *)
19108  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19109for as_dir in $PATH
19110do
19111  IFS=$as_save_IFS
19112  test -z "$as_dir" && as_dir=.
19113    for ac_exec_ext in '' $ac_executable_extensions; do
19114  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19115    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19116    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19117    break 2
19118  fi
19119done
19120  done
19121IFS=$as_save_IFS
19122
19123  ;;
19124esac
19125fi
19126CODESIGN=$ac_cv_path_CODESIGN
19127if test -n "$CODESIGN"; then
19128  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19129$as_echo "$CODESIGN" >&6; }
19130else
19131  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19132$as_echo "no" >&6; }
19133fi
19134
19135
19136  test -n "$CODESIGN" && break
19137done
19138
19139  else
19140    # The variable is set, but is it from the command line or the environment?
19141
19142    # Try to remove the string !CODESIGN! from our list.
19143    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/}
19144    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
19145      # If it failed, the variable was not from the command line. Ignore it,
19146      # but warn the user (except for BASH, which is always set by the calling BASH).
19147      if test "xCODESIGN" != xBASH; then
19148        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5
19149$as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;}
19150      fi
19151      # Try to locate tool using the code snippet
19152      for ac_prog in codesign
19153do
19154  # Extract the first word of "$ac_prog", so it can be a program name with args.
19155set dummy $ac_prog; ac_word=$2
19156{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19157$as_echo_n "checking for $ac_word... " >&6; }
19158if ${ac_cv_path_CODESIGN+:} false; then :
19159  $as_echo_n "(cached) " >&6
19160else
19161  case $CODESIGN in
19162  [\\/]* | ?:[\\/]*)
19163  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19164  ;;
19165  *)
19166  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19167for as_dir in $PATH
19168do
19169  IFS=$as_save_IFS
19170  test -z "$as_dir" && as_dir=.
19171    for ac_exec_ext in '' $ac_executable_extensions; do
19172  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19173    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19174    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19175    break 2
19176  fi
19177done
19178  done
19179IFS=$as_save_IFS
19180
19181  ;;
19182esac
19183fi
19184CODESIGN=$ac_cv_path_CODESIGN
19185if test -n "$CODESIGN"; then
19186  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19187$as_echo "$CODESIGN" >&6; }
19188else
19189  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19190$as_echo "no" >&6; }
19191fi
19192
19193
19194  test -n "$CODESIGN" && break
19195done
19196
19197    else
19198      # If it succeeded, then it was overridden by the user. We will use it
19199      # for the tool.
19200
19201      # First remove it from the list of overridden variables, so we can test
19202      # for unknown variables in the end.
19203      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19204
19205      # Check if the provided tool contains a complete path.
19206      tool_specified="$CODESIGN"
19207      tool_basename="${tool_specified##*/}"
19208      if test "x$tool_basename" = "x$tool_specified"; then
19209        # A command without a complete path is provided, search $PATH.
19210        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5
19211$as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;}
19212        # Extract the first word of "$tool_basename", so it can be a program name with args.
19213set dummy $tool_basename; ac_word=$2
19214{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19215$as_echo_n "checking for $ac_word... " >&6; }
19216if ${ac_cv_path_CODESIGN+:} false; then :
19217  $as_echo_n "(cached) " >&6
19218else
19219  case $CODESIGN in
19220  [\\/]* | ?:[\\/]*)
19221  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19222  ;;
19223  *)
19224  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19225for as_dir in $PATH
19226do
19227  IFS=$as_save_IFS
19228  test -z "$as_dir" && as_dir=.
19229    for ac_exec_ext in '' $ac_executable_extensions; do
19230  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19231    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19232    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19233    break 2
19234  fi
19235done
19236  done
19237IFS=$as_save_IFS
19238
19239  ;;
19240esac
19241fi
19242CODESIGN=$ac_cv_path_CODESIGN
19243if test -n "$CODESIGN"; then
19244  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19245$as_echo "$CODESIGN" >&6; }
19246else
19247  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19248$as_echo "no" >&6; }
19249fi
19250
19251
19252        if test "x$CODESIGN" = x; then
19253          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19254        fi
19255      else
19256        # Otherwise we believe it is a complete path. Use it as it is.
19257        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5
19258$as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;}
19259        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5
19260$as_echo_n "checking for CODESIGN... " >&6; }
19261        if test ! -x "$tool_specified"; then
19262          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19263$as_echo "not found" >&6; }
19264          as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5
19265        fi
19266        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19267$as_echo "$tool_specified" >&6; }
19268      fi
19269    fi
19270  fi
19271
19272
19273    if test "x$CODESIGN" != "x"; then
19274      # Verify that the openjdk_codesign certificate is present
19275      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5
19276$as_echo_n "checking if openjdk_codesign certificate is present... " >&6; }
19277      rm -f codesign-testfile
19278      touch codesign-testfile
19279      codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN=
19280      rm -f codesign-testfile
19281      if test "x$CODESIGN" = x; then
19282        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19283$as_echo "no" >&6; }
19284      else
19285        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19286$as_echo "yes" >&6; }
19287      fi
19288    fi
19289  fi
19290
19291
19292# Check if pkg-config is available.
19293
19294
19295if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
19296	if test -n "$ac_tool_prefix"; then
19297  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
19298set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
19299{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19300$as_echo_n "checking for $ac_word... " >&6; }
19301if ${ac_cv_path_PKG_CONFIG+:} false; then :
19302  $as_echo_n "(cached) " >&6
19303else
19304  case $PKG_CONFIG in
19305  [\\/]* | ?:[\\/]*)
19306  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
19307  ;;
19308  *)
19309  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19310for as_dir in $PATH
19311do
19312  IFS=$as_save_IFS
19313  test -z "$as_dir" && as_dir=.
19314    for ac_exec_ext in '' $ac_executable_extensions; do
19315  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19316    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19317    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19318    break 2
19319  fi
19320done
19321  done
19322IFS=$as_save_IFS
19323
19324  ;;
19325esac
19326fi
19327PKG_CONFIG=$ac_cv_path_PKG_CONFIG
19328if test -n "$PKG_CONFIG"; then
19329  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19330$as_echo "$PKG_CONFIG" >&6; }
19331else
19332  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19333$as_echo "no" >&6; }
19334fi
19335
19336
19337fi
19338if test -z "$ac_cv_path_PKG_CONFIG"; then
19339  ac_pt_PKG_CONFIG=$PKG_CONFIG
19340  # Extract the first word of "pkg-config", so it can be a program name with args.
19341set dummy pkg-config; ac_word=$2
19342{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19343$as_echo_n "checking for $ac_word... " >&6; }
19344if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
19345  $as_echo_n "(cached) " >&6
19346else
19347  case $ac_pt_PKG_CONFIG in
19348  [\\/]* | ?:[\\/]*)
19349  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
19350  ;;
19351  *)
19352  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19353for as_dir in $PATH
19354do
19355  IFS=$as_save_IFS
19356  test -z "$as_dir" && as_dir=.
19357    for ac_exec_ext in '' $ac_executable_extensions; do
19358  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19359    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19360    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19361    break 2
19362  fi
19363done
19364  done
19365IFS=$as_save_IFS
19366
19367  ;;
19368esac
19369fi
19370ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
19371if test -n "$ac_pt_PKG_CONFIG"; then
19372  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
19373$as_echo "$ac_pt_PKG_CONFIG" >&6; }
19374else
19375  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19376$as_echo "no" >&6; }
19377fi
19378
19379  if test "x$ac_pt_PKG_CONFIG" = x; then
19380    PKG_CONFIG=""
19381  else
19382    case $cross_compiling:$ac_tool_warned in
19383yes:)
19384{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19385$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19386ac_tool_warned=yes ;;
19387esac
19388    PKG_CONFIG=$ac_pt_PKG_CONFIG
19389  fi
19390else
19391  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
19392fi
19393
19394fi
19395if test -n "$PKG_CONFIG"; then
19396	_pkg_min_version=0.9.0
19397	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
19398$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
19399	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
19400		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19401$as_echo "yes" >&6; }
19402	else
19403		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19404$as_echo "no" >&6; }
19405		PKG_CONFIG=""
19406	fi
19407
19408fi
19409
19410# After basic tools have been setup, we can check build os specific details.
19411
19412  ###############################################################################
19413
19414  # Note that this is the build platform OS version!
19415
19416  OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`"
19417  OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`"
19418  OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`"
19419  OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`"
19420
19421
19422
19423
19424
19425# Setup builddeps, for automatic downloading of tools we need.
19426# This is needed before we can call BDEPS_CHECK_MODULE, which is done in
19427# boot-jdk setup, but we need to have basic tools setup first.
19428
19429
19430# Check whether --with-builddeps-conf was given.
19431if test "${with_builddeps_conf+set}" = set; then :
19432  withval=$with_builddeps_conf;
19433fi
19434
19435
19436
19437# Check whether --with-builddeps-server was given.
19438if test "${with_builddeps_server+set}" = set; then :
19439  withval=$with_builddeps_server;
19440fi
19441
19442
19443
19444# Check whether --with-builddeps-dir was given.
19445if test "${with_builddeps_dir+set}" = set; then :
19446  withval=$with_builddeps_dir;
19447else
19448  with_builddeps_dir=/localhome/builddeps
19449fi
19450
19451
19452
19453# Check whether --with-builddeps-group was given.
19454if test "${with_builddeps_group+set}" = set; then :
19455  withval=$with_builddeps_group;
19456fi
19457
19458
19459
19460
19461  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19462    if test "x$with_builddeps_conf" != x; then
19463      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5
19464$as_echo_n "checking for supplied builddeps configuration file... " >&6; }
19465      builddepsfile=$with_builddeps_conf
19466      if test -s $builddepsfile; then
19467        . $builddepsfile
19468        { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5
19469$as_echo "loaded!" >&6; }
19470      else
19471        as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5
19472      fi
19473    else
19474      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5
19475$as_echo_n "checking for builddeps.conf files in sources...... " >&6; }
19476      builddepsfile=`mktemp`
19477      touch $builddepsfile
19478      # Put all found confs into a single file.
19479      find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile
19480      # Source the file to acquire the variables
19481      if test -s $builddepsfile; then
19482        . $builddepsfile
19483        { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5
19484$as_echo "found at least one!" >&6; }
19485      else
19486        as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5
19487      fi
19488    fi
19489    # Create build and target names that use _ instead of "-" and ".".
19490    # This is necessary to use them in variable names.
19491    build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19492    target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19493    # Extract rewrite information for build and target
19494    eval rewritten_build=\${REWRITE_${build_var}}
19495    if test "x$rewritten_build" = x; then
19496      rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME}
19497      echo Build stays the same $rewritten_build
19498    else
19499      echo Rewriting build for builddeps into $rewritten_build
19500    fi
19501    eval rewritten_target=\${REWRITE_${target_var}}
19502    if test "x$rewritten_target" = x; then
19503      rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME}
19504      echo Target stays the same $rewritten_target
19505    else
19506      echo Rewriting target for builddeps into $rewritten_target
19507    fi
19508    rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'`
19509    rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'`
19510  fi
19511  for ac_prog in 7z unzip
19512do
19513  # Extract the first word of "$ac_prog", so it can be a program name with args.
19514set dummy $ac_prog; ac_word=$2
19515{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19516$as_echo_n "checking for $ac_word... " >&6; }
19517if ${ac_cv_prog_BDEPS_UNZIP+:} false; then :
19518  $as_echo_n "(cached) " >&6
19519else
19520  if test -n "$BDEPS_UNZIP"; then
19521  ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test.
19522else
19523as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19524for as_dir in $PATH
19525do
19526  IFS=$as_save_IFS
19527  test -z "$as_dir" && as_dir=.
19528    for ac_exec_ext in '' $ac_executable_extensions; do
19529  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19530    ac_cv_prog_BDEPS_UNZIP="$ac_prog"
19531    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19532    break 2
19533  fi
19534done
19535  done
19536IFS=$as_save_IFS
19537
19538fi
19539fi
19540BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP
19541if test -n "$BDEPS_UNZIP"; then
19542  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5
19543$as_echo "$BDEPS_UNZIP" >&6; }
19544else
19545  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19546$as_echo "no" >&6; }
19547fi
19548
19549
19550  test -n "$BDEPS_UNZIP" && break
19551done
19552
19553  if test "x$BDEPS_UNZIP" = x7z; then
19554    BDEPS_UNZIP="7z x"
19555  fi
19556
19557  for ac_prog in wget lftp ftp
19558do
19559  # Extract the first word of "$ac_prog", so it can be a program name with args.
19560set dummy $ac_prog; ac_word=$2
19561{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19562$as_echo_n "checking for $ac_word... " >&6; }
19563if ${ac_cv_prog_BDEPS_FTP+:} false; then :
19564  $as_echo_n "(cached) " >&6
19565else
19566  if test -n "$BDEPS_FTP"; then
19567  ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test.
19568else
19569as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19570for as_dir in $PATH
19571do
19572  IFS=$as_save_IFS
19573  test -z "$as_dir" && as_dir=.
19574    for ac_exec_ext in '' $ac_executable_extensions; do
19575  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19576    ac_cv_prog_BDEPS_FTP="$ac_prog"
19577    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19578    break 2
19579  fi
19580done
19581  done
19582IFS=$as_save_IFS
19583
19584fi
19585fi
19586BDEPS_FTP=$ac_cv_prog_BDEPS_FTP
19587if test -n "$BDEPS_FTP"; then
19588  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5
19589$as_echo "$BDEPS_FTP" >&6; }
19590else
19591  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19592$as_echo "no" >&6; }
19593fi
19594
19595
19596  test -n "$BDEPS_FTP" && break
19597done
19598
19599
19600
19601###############################################################################
19602#
19603# Determine OpenJDK variants, options and version numbers.
19604#
19605###############################################################################
19606
19607# We need build & target for this.
19608
19609
19610  ###############################################################################
19611  #
19612  # Should we build a JDK/JVM with headful support (ie a graphical ui)?
19613  # We always build headless support.
19614  #
19615  { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5
19616$as_echo_n "checking headful support... " >&6; }
19617  # Check whether --enable-headful was given.
19618if test "${enable_headful+set}" = set; then :
19619  enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful}
19620else
19621  SUPPORT_HEADFUL=yes
19622fi
19623
19624
19625  SUPPORT_HEADLESS=yes
19626  BUILD_HEADLESS="BUILD_HEADLESS:=true"
19627
19628  if test "x$SUPPORT_HEADFUL" = xyes; then
19629    # We are building both headful and headless.
19630    headful_msg="include support for both headful and headless"
19631  fi
19632
19633  if test "x$SUPPORT_HEADFUL" = xno; then
19634    # Thus we are building headless only.
19635    BUILD_HEADLESS="BUILD_HEADLESS:=true"
19636    headful_msg="headless only"
19637  fi
19638
19639  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5
19640$as_echo "$headful_msg" >&6; }
19641
19642
19643
19644
19645
19646  # Control wether Hotspot runs Queens test after build.
19647  # Check whether --enable-hotspot-test-in-build was given.
19648if test "${enable_hotspot_test_in_build+set}" = set; then :
19649  enableval=$enable_hotspot_test_in_build;
19650else
19651  enable_hotspot_test_in_build=no
19652fi
19653
19654  if test "x$enable_hotspot_test_in_build" = "xyes"; then
19655    TEST_IN_BUILD=true
19656  else
19657    TEST_IN_BUILD=false
19658  fi
19659
19660
19661  ###############################################################################
19662  #
19663  # Choose cacerts source file
19664  #
19665
19666# Check whether --with-cacerts-file was given.
19667if test "${with_cacerts_file+set}" = set; then :
19668  withval=$with_cacerts_file;
19669fi
19670
19671  if test "x$with_cacerts_file" != x; then
19672    CACERTS_FILE=$with_cacerts_file
19673  else
19674    CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts
19675  fi
19676
19677
19678  ###############################################################################
19679  #
19680  # Enable or disable unlimited crypto
19681  #
19682  # Check whether --enable-unlimited-crypto was given.
19683if test "${enable_unlimited_crypto+set}" = set; then :
19684  enableval=$enable_unlimited_crypto;
19685else
19686  enable_unlimited_crypto=no
19687fi
19688
19689  if test "x$enable_unlimited_crypto" = "xyes"; then
19690    UNLIMITED_CRYPTO=true
19691  else
19692    UNLIMITED_CRYPTO=false
19693  fi
19694
19695
19696  ###############################################################################
19697  #
19698  # Enable or disable the elliptic curve crypto implementation
19699  #
19700
19701
19702  ###############################################################################
19703  #
19704  # --enable-rmiconnector-iiop
19705  #
19706  # Check whether --enable-rmiconnector-iiop was given.
19707if test "${enable_rmiconnector_iiop+set}" = set; then :
19708  enableval=$enable_rmiconnector_iiop;
19709fi
19710
19711  if test "x$enable_rmiconnector_iiop" = "xyes"; then
19712    RMICONNECTOR_IIOP=true
19713  else
19714    RMICONNECTOR_IIOP=false
19715  fi
19716
19717
19718  ###############################################################################
19719  #
19720  # Compress jars
19721  #
19722  COMPRESS_JARS=false
19723
19724
19725
19726
19727  # Source the version numbers
19728  . $AUTOCONF_DIR/version-numbers
19729
19730  # Get the settings from parameters
19731
19732# Check whether --with-milestone was given.
19733if test "${with_milestone+set}" = set; then :
19734  withval=$with_milestone;
19735fi
19736
19737  if test "x$with_milestone" = xyes; then
19738    as_fn_error $? "Milestone must have a value" "$LINENO" 5
19739  elif test "x$with_milestone" != x; then
19740    MILESTONE="$with_milestone"
19741  fi
19742  if test "x$MILESTONE" = x; then
19743    MILESTONE=internal
19744  fi
19745
19746
19747# Check whether --with-update-version was given.
19748if test "${with_update_version+set}" = set; then :
19749  withval=$with_update_version;
19750fi
19751
19752  if test "x$with_update_version" = xyes; then
19753    as_fn_error $? "Update version must have a value" "$LINENO" 5
19754  elif test "x$with_update_version" != x; then
19755    JDK_UPDATE_VERSION="$with_update_version"
19756    # On macosx 10.7, it's not possible to set --with-update-version=0X due
19757    # to a bug in expr (which reduces it to just X). To work around this, we
19758    # always add a 0 to one digit update versions.
19759    if test "${#JDK_UPDATE_VERSION}" = "1"; then
19760      JDK_UPDATE_VERSION="0${JDK_UPDATE_VERSION}"
19761    fi
19762  fi
19763
19764
19765# Check whether --with-user-release-suffix was given.
19766if test "${with_user_release_suffix+set}" = set; then :
19767  withval=$with_user_release_suffix;
19768fi
19769
19770  if test "x$with_user_release_suffix" = xyes; then
19771    as_fn_error $? "Release suffix must have a value" "$LINENO" 5
19772  elif test "x$with_user_release_suffix" != x; then
19773    USER_RELEASE_SUFFIX="$with_user_release_suffix"
19774  fi
19775
19776
19777# Check whether --with-build-number was given.
19778if test "${with_build_number+set}" = set; then :
19779  withval=$with_build_number;
19780fi
19781
19782  if test "x$with_build_number" = xyes; then
19783    as_fn_error $? "Build number must have a value" "$LINENO" 5
19784  elif test "x$with_build_number" != x; then
19785    JDK_BUILD_NUMBER="$with_build_number"
19786  fi
19787  # Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
19788  if test "x$JDK_BUILD_NUMBER" = x; then
19789    JDK_BUILD_NUMBER=b00
19790    if test "x$USER_RELEASE_SUFFIX" = x; then
19791      BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
19792      # Avoid [:alnum:] since it depends on the locale.
19793      CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
19794      USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19795    fi
19796  fi
19797
19798  # Now set the JDK version, milestone, build number etc.
19799
19800
19801
19802
19803
19804
19805
19806
19807
19808
19809
19810
19811
19812
19813
19814  COPYRIGHT_YEAR=`date +'%Y'`
19815
19816
19817  if test "x$JDK_UPDATE_VERSION" != x; then
19818    JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}"
19819  else
19820    JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}"
19821  fi
19822
19823
19824  COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'`
19825
19826
19827
19828###############################################################################
19829#
19830# Setup BootJDK, used to bootstrap the build.
19831#
19832###############################################################################
19833
19834
19835  BOOT_JDK_FOUND=no
19836
19837# Check whether --with-boot-jdk was given.
19838if test "${with_boot_jdk+set}" = set; then :
19839  withval=$with_boot_jdk;
19840fi
19841
19842
19843  # We look for the Boot JDK through various means, going from more certain to
19844  # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if
19845  # we detected something (if so, the path to the jdk is in BOOT_JDK). But we
19846  # must check if this is indeed valid; otherwise we'll continue looking.
19847
19848  # Test: Is bootjdk explicitely set by command line arguments?
19849
19850  if test "x$BOOT_JDK_FOUND" = xno; then
19851    # Now execute the test
19852
19853  if test "x$with_boot_jdk" != x; then
19854    BOOT_JDK=$with_boot_jdk
19855    BOOT_JDK_FOUND=maybe
19856    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5
19857$as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;}
19858  fi
19859
19860
19861    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
19862    if test "x$BOOT_JDK_FOUND" = xmaybe; then
19863      # Do we have a bin/java?
19864      if test ! -x "$BOOT_JDK/bin/java"; then
19865        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
19866$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
19867        BOOT_JDK_FOUND=no
19868      else
19869        # Do we have a bin/javac?
19870        if test ! -x "$BOOT_JDK/bin/javac"; then
19871          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
19872$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
19873          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
19874$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
19875          BOOT_JDK_FOUND=no
19876        else
19877          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
19878          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
19879            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
19880$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
19881            BOOT_JDK_FOUND=no
19882          else
19883            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
19884            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
19885
19886            # Extra M4 quote needed to protect [] in grep expression.
19887            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
19888            if test "x$FOUND_CORRECT_VERSION" = x; then
19889              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
19890$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
19891              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
19892$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
19893              BOOT_JDK_FOUND=no
19894            else
19895              # We're done! :-)
19896              BOOT_JDK_FOUND=yes
19897
19898  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19899
19900  # Input might be given as Windows format, start by converting to
19901  # unix format.
19902  path="$BOOT_JDK"
19903  new_path=`$CYGPATH -u "$path"`
19904
19905  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
19906  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
19907  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
19908  # "foo.exe" is OK but "foo" is an error.
19909  #
19910  # This test is therefore slightly more accurate than "test -f" to check for file precense.
19911  # It is also a way to make sure we got the proper file name for the real test later on.
19912  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
19913  if test "x$test_shortpath" = x; then
19914    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19915$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19916    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
19917  fi
19918
19919  # Call helper function which possibly converts this using DOS-style short mode.
19920  # If so, the updated path is stored in $new_path.
19921
19922  input_path="$new_path"
19923  # Check if we need to convert this using DOS-style short mode. If the path
19924  # contains just simple characters, use it. Otherwise (spaces, weird characters),
19925  # take no chances and rewrite it.
19926  # Note: m4 eats our [], so we need to use [ and ] instead.
19927  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
19928  if test "x$has_forbidden_chars" != x; then
19929    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19930    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
19931    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
19932    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
19933      # Going to short mode and back again did indeed matter. Since short mode is
19934      # case insensitive, let's make it lowercase to improve readability.
19935      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19936      # Now convert it back to Unix-stile (cygpath)
19937      input_path=`$CYGPATH -u "$shortmode_path"`
19938      new_path="$input_path"
19939    fi
19940  fi
19941
19942  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
19943  if test "x$test_cygdrive_prefix" = x; then
19944    # As a simple fix, exclude /usr/bin since it's not a real path.
19945    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
19946      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
19947      # a path prefixed by /cygdrive for fixpath to work.
19948      new_path="$CYGWIN_ROOT_PATH$input_path"
19949    fi
19950  fi
19951
19952
19953  if test "x$path" != "x$new_path"; then
19954    BOOT_JDK="$new_path"
19955    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19956$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19957  fi
19958
19959  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19960
19961  path="$BOOT_JDK"
19962  has_colon=`$ECHO $path | $GREP ^.:`
19963  new_path="$path"
19964  if test "x$has_colon" = x; then
19965    # Not in mixed or Windows style, start by that.
19966    new_path=`cmd //c echo $path`
19967  fi
19968
19969
19970  input_path="$new_path"
19971  # Check if we need to convert this using DOS-style short mode. If the path
19972  # contains just simple characters, use it. Otherwise (spaces, weird characters),
19973  # take no chances and rewrite it.
19974  # Note: m4 eats our [], so we need to use [ and ] instead.
19975  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
19976  if test "x$has_forbidden_chars" != x; then
19977    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19978    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19979  fi
19980
19981
19982  windows_path="$new_path"
19983  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19984    unix_path=`$CYGPATH -u "$windows_path"`
19985    new_path="$unix_path"
19986  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19987    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
19988    new_path="$unix_path"
19989  fi
19990
19991  if test "x$path" != "x$new_path"; then
19992    BOOT_JDK="$new_path"
19993    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19994$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19995  fi
19996
19997  # Save the first 10 bytes of this path to the storage, so fixpath can work.
19998  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
19999
20000  else
20001    # We're on a posix platform. Hooray! :)
20002    path="$BOOT_JDK"
20003    has_space=`$ECHO "$path" | $GREP " "`
20004    if test "x$has_space" != x; then
20005      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20006$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20007      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20008    fi
20009
20010    # Use eval to expand a potential ~
20011    eval path="$path"
20012    if test ! -f "$path" && test ! -d "$path"; then
20013      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20014    fi
20015
20016    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20017  fi
20018
20019              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20020$as_echo_n "checking for Boot JDK... " >&6; }
20021              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20022$as_echo "$BOOT_JDK" >&6; }
20023              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20024$as_echo_n "checking Boot JDK version... " >&6; }
20025              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20026              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20027$as_echo "$BOOT_JDK_VERSION" >&6; }
20028            fi # end check jdk version
20029          fi # end check rt.jar
20030        fi # end check javac
20031      fi # end check java
20032    fi # end check boot jdk found
20033  fi
20034
20035  if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then
20036    # Having specified an argument which is incorrect will produce an instant failure;
20037    # we should not go on looking
20038    as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5
20039  fi
20040
20041  # Test: Is bootjdk available from builddeps?
20042
20043  if test "x$BOOT_JDK_FOUND" = xno; then
20044    # Now execute the test
20045
20046
20047
20048  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
20049    # Source the builddeps file again, to make sure it uses the latest variables!
20050    . $builddepsfile
20051    # Look for a target and build machine specific resource!
20052    eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
20053    if test "x$resource" = x; then
20054      # Ok, lets instead look for a target specific resource
20055      eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}}
20056    fi
20057    if test "x$resource" = x; then
20058      # Ok, lets instead look for a build specific resource
20059      eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}}
20060    fi
20061    if test "x$resource" = x; then
20062      # Ok, lets instead look for a generic resource
20063      # (The bootjdk comes from M4 and not the shell, thus no need for eval here.)
20064      resource=${builddep_bootjdk}
20065    fi
20066    if test "x$resource" != x; then
20067      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5
20068$as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;}
20069      # If the resource in the builddeps.conf file is an existing directory,
20070      # for example /java/linux/cups
20071      if test -d ${resource}; then
20072        depdir=${resource}
20073      else
20074
20075  # bootjdk is for example mymodule
20076  # $resource is for example libs/general/libmymod_1_2_3.zip
20077  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
20078  # $with_builddeps_dir is for example /localhome/builddeps
20079  # depdir is the name of the variable into which we store the depdir, eg MYMOD
20080  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
20081  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
20082  filename=`basename $resource`
20083  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
20084  filebase=${filename%%.*}
20085  extension=${filename#*.}
20086  installdir=$with_builddeps_dir/$filebase
20087  if test ! -f $installdir/$filename.unpacked; then
20088    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5
20089$as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;}
20090    if test ! -d $installdir; then
20091      mkdir -p $installdir
20092    fi
20093    if test ! -d $installdir; then
20094      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
20095    fi
20096    tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX`
20097    touch $tmpfile
20098    if test ! -f $tmpfile; then
20099      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
20100    fi
20101
20102  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
20103  # $tmpfile is the local file name for the downloaded file.
20104  VALID_TOOL=no
20105  if test "x$BDEPS_FTP" = xwget; then
20106    VALID_TOOL=yes
20107    wget -O $tmpfile $with_builddeps_server/$resource
20108  fi
20109  if test "x$BDEPS_FTP" = xlftp; then
20110    VALID_TOOL=yes
20111    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
20112  fi
20113  if test "x$BDEPS_FTP" = xftp; then
20114    VALID_TOOL=yes
20115    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
20116    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
20117    FTPUSERPWD=${FTPSERVER%%@*}
20118    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
20119      FTPUSER=${userpwd%%:*}
20120      FTPPWD=${userpwd#*@}
20121      FTPSERVER=${FTPSERVER#*@}
20122    else
20123      FTPUSER=ftp
20124      FTPPWD=ftp
20125    fi
20126    # the "pass" command does not work on some
20127    # ftp clients (read ftp.exe) but if it works,
20128    # passive mode is better!
20129    ( \
20130        echo "user $FTPUSER $FTPPWD"        ; \
20131        echo "pass"                         ; \
20132        echo "bin"                          ; \
20133        echo "get $FTPPATH $tmpfile"              ; \
20134    ) | ftp -in $FTPSERVER
20135  fi
20136  if test "x$VALID_TOOL" != xyes; then
20137    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
20138  fi
20139
20140    mv $tmpfile $installdir/$filename
20141    if test ! -s $installdir/$filename; then
20142      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
20143    fi
20144    case "$extension" in
20145      zip)  echo "Unzipping $installdir/$filename..."
20146        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
20147        ;;
20148      tar.gz) echo "Untaring $installdir/$filename..."
20149        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
20150        ;;
20151      tgz) echo "Untaring $installdir/$filename..."
20152        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
20153        ;;
20154      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
20155        ;;
20156    esac
20157  fi
20158  if test -f $installdir/$filename.unpacked; then
20159    depdir=$installdir
20160  fi
20161
20162      fi
20163      # Source the builddeps file again, because in the previous command, the depdir
20164      # was updated to point at the current build dependency install directory.
20165      . $builddepsfile
20166      # Now extract variables from the builddeps.conf files.
20167      theroot=${builddep_bootjdk_ROOT}
20168      thecflags=${builddep_bootjdk_CFLAGS}
20169      thelibs=${builddep_bootjdk_LIBS}
20170      if test "x$depdir" = x; then
20171        as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5
20172      fi
20173      BOOT_JDK=$depdir
20174      if test "x$theroot" != x; then
20175        BOOT_JDK="$theroot"
20176      fi
20177      if test "x$thecflags" != x; then
20178        BOOT_JDK_CFLAGS="$thecflags"
20179      fi
20180      if test "x$thelibs" != x; then
20181        BOOT_JDK_LIBS="$thelibs"
20182      fi
20183      BOOT_JDK_FOUND=maybe
20184      else BOOT_JDK_FOUND=no
20185
20186    fi
20187    else BOOT_JDK_FOUND=no
20188
20189  fi
20190
20191
20192
20193    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20194    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20195      # Do we have a bin/java?
20196      if test ! -x "$BOOT_JDK/bin/java"; then
20197        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20198$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20199        BOOT_JDK_FOUND=no
20200      else
20201        # Do we have a bin/javac?
20202        if test ! -x "$BOOT_JDK/bin/javac"; then
20203          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20204$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20205          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20206$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20207          BOOT_JDK_FOUND=no
20208        else
20209          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20210          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20211            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20212$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20213            BOOT_JDK_FOUND=no
20214          else
20215            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20216            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20217
20218            # Extra M4 quote needed to protect [] in grep expression.
20219            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20220            if test "x$FOUND_CORRECT_VERSION" = x; then
20221              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20222$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20223              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20224$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20225              BOOT_JDK_FOUND=no
20226            else
20227              # We're done! :-)
20228              BOOT_JDK_FOUND=yes
20229
20230  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20231
20232  # Input might be given as Windows format, start by converting to
20233  # unix format.
20234  path="$BOOT_JDK"
20235  new_path=`$CYGPATH -u "$path"`
20236
20237  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20238  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20239  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20240  # "foo.exe" is OK but "foo" is an error.
20241  #
20242  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20243  # It is also a way to make sure we got the proper file name for the real test later on.
20244  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20245  if test "x$test_shortpath" = x; then
20246    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20247$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20248    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20249  fi
20250
20251  # Call helper function which possibly converts this using DOS-style short mode.
20252  # If so, the updated path is stored in $new_path.
20253
20254  input_path="$new_path"
20255  # Check if we need to convert this using DOS-style short mode. If the path
20256  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20257  # take no chances and rewrite it.
20258  # Note: m4 eats our [], so we need to use [ and ] instead.
20259  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20260  if test "x$has_forbidden_chars" != x; then
20261    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20262    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20263    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20264    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20265      # Going to short mode and back again did indeed matter. Since short mode is
20266      # case insensitive, let's make it lowercase to improve readability.
20267      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20268      # Now convert it back to Unix-stile (cygpath)
20269      input_path=`$CYGPATH -u "$shortmode_path"`
20270      new_path="$input_path"
20271    fi
20272  fi
20273
20274  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20275  if test "x$test_cygdrive_prefix" = x; then
20276    # As a simple fix, exclude /usr/bin since it's not a real path.
20277    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20278      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20279      # a path prefixed by /cygdrive for fixpath to work.
20280      new_path="$CYGWIN_ROOT_PATH$input_path"
20281    fi
20282  fi
20283
20284
20285  if test "x$path" != "x$new_path"; then
20286    BOOT_JDK="$new_path"
20287    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20288$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20289  fi
20290
20291  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20292
20293  path="$BOOT_JDK"
20294  has_colon=`$ECHO $path | $GREP ^.:`
20295  new_path="$path"
20296  if test "x$has_colon" = x; then
20297    # Not in mixed or Windows style, start by that.
20298    new_path=`cmd //c echo $path`
20299  fi
20300
20301
20302  input_path="$new_path"
20303  # Check if we need to convert this using DOS-style short mode. If the path
20304  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20305  # take no chances and rewrite it.
20306  # Note: m4 eats our [], so we need to use [ and ] instead.
20307  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20308  if test "x$has_forbidden_chars" != x; then
20309    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20310    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20311  fi
20312
20313
20314  windows_path="$new_path"
20315  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20316    unix_path=`$CYGPATH -u "$windows_path"`
20317    new_path="$unix_path"
20318  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20319    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20320    new_path="$unix_path"
20321  fi
20322
20323  if test "x$path" != "x$new_path"; then
20324    BOOT_JDK="$new_path"
20325    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20326$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20327  fi
20328
20329  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20330  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20331
20332  else
20333    # We're on a posix platform. Hooray! :)
20334    path="$BOOT_JDK"
20335    has_space=`$ECHO "$path" | $GREP " "`
20336    if test "x$has_space" != x; then
20337      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20338$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20339      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20340    fi
20341
20342    # Use eval to expand a potential ~
20343    eval path="$path"
20344    if test ! -f "$path" && test ! -d "$path"; then
20345      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20346    fi
20347
20348    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20349  fi
20350
20351              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20352$as_echo_n "checking for Boot JDK... " >&6; }
20353              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20354$as_echo "$BOOT_JDK" >&6; }
20355              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20356$as_echo_n "checking Boot JDK version... " >&6; }
20357              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20358              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20359$as_echo "$BOOT_JDK_VERSION" >&6; }
20360            fi # end check jdk version
20361          fi # end check rt.jar
20362        fi # end check javac
20363      fi # end check java
20364    fi # end check boot jdk found
20365  fi
20366
20367
20368  # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
20369
20370  if test "x$BOOT_JDK_FOUND" = xno; then
20371    # Now execute the test
20372
20373  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
20374    # First check at user selected default
20375
20376  if test "x$BOOT_JDK_FOUND" = xno; then
20377    # Now execute the test
20378
20379  if test -x /usr/libexec/java_home; then
20380    BOOT_JDK=`/usr/libexec/java_home `
20381    BOOT_JDK_FOUND=maybe
20382    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5
20383$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;}
20384  fi
20385
20386
20387    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20388    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20389      # Do we have a bin/java?
20390      if test ! -x "$BOOT_JDK/bin/java"; then
20391        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20392$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20393        BOOT_JDK_FOUND=no
20394      else
20395        # Do we have a bin/javac?
20396        if test ! -x "$BOOT_JDK/bin/javac"; then
20397          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20398$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20399          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20400$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20401          BOOT_JDK_FOUND=no
20402        else
20403          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20404          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20405            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20406$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20407            BOOT_JDK_FOUND=no
20408          else
20409            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20410            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20411
20412            # Extra M4 quote needed to protect [] in grep expression.
20413            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20414            if test "x$FOUND_CORRECT_VERSION" = x; then
20415              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20416$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20417              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20418$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20419              BOOT_JDK_FOUND=no
20420            else
20421              # We're done! :-)
20422              BOOT_JDK_FOUND=yes
20423
20424  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20425
20426  # Input might be given as Windows format, start by converting to
20427  # unix format.
20428  path="$BOOT_JDK"
20429  new_path=`$CYGPATH -u "$path"`
20430
20431  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20432  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20433  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20434  # "foo.exe" is OK but "foo" is an error.
20435  #
20436  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20437  # It is also a way to make sure we got the proper file name for the real test later on.
20438  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20439  if test "x$test_shortpath" = x; then
20440    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20441$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20442    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20443  fi
20444
20445  # Call helper function which possibly converts this using DOS-style short mode.
20446  # If so, the updated path is stored in $new_path.
20447
20448  input_path="$new_path"
20449  # Check if we need to convert this using DOS-style short mode. If the path
20450  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20451  # take no chances and rewrite it.
20452  # Note: m4 eats our [], so we need to use [ and ] instead.
20453  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20454  if test "x$has_forbidden_chars" != x; then
20455    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20456    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20457    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20458    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20459      # Going to short mode and back again did indeed matter. Since short mode is
20460      # case insensitive, let's make it lowercase to improve readability.
20461      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20462      # Now convert it back to Unix-stile (cygpath)
20463      input_path=`$CYGPATH -u "$shortmode_path"`
20464      new_path="$input_path"
20465    fi
20466  fi
20467
20468  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20469  if test "x$test_cygdrive_prefix" = x; then
20470    # As a simple fix, exclude /usr/bin since it's not a real path.
20471    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20472      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20473      # a path prefixed by /cygdrive for fixpath to work.
20474      new_path="$CYGWIN_ROOT_PATH$input_path"
20475    fi
20476  fi
20477
20478
20479  if test "x$path" != "x$new_path"; then
20480    BOOT_JDK="$new_path"
20481    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20482$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20483  fi
20484
20485  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20486
20487  path="$BOOT_JDK"
20488  has_colon=`$ECHO $path | $GREP ^.:`
20489  new_path="$path"
20490  if test "x$has_colon" = x; then
20491    # Not in mixed or Windows style, start by that.
20492    new_path=`cmd //c echo $path`
20493  fi
20494
20495
20496  input_path="$new_path"
20497  # Check if we need to convert this using DOS-style short mode. If the path
20498  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20499  # take no chances and rewrite it.
20500  # Note: m4 eats our [], so we need to use [ and ] instead.
20501  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20502  if test "x$has_forbidden_chars" != x; then
20503    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20504    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20505  fi
20506
20507
20508  windows_path="$new_path"
20509  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20510    unix_path=`$CYGPATH -u "$windows_path"`
20511    new_path="$unix_path"
20512  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20513    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20514    new_path="$unix_path"
20515  fi
20516
20517  if test "x$path" != "x$new_path"; then
20518    BOOT_JDK="$new_path"
20519    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20520$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20521  fi
20522
20523  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20524  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20525
20526  else
20527    # We're on a posix platform. Hooray! :)
20528    path="$BOOT_JDK"
20529    has_space=`$ECHO "$path" | $GREP " "`
20530    if test "x$has_space" != x; then
20531      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20532$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20533      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20534    fi
20535
20536    # Use eval to expand a potential ~
20537    eval path="$path"
20538    if test ! -f "$path" && test ! -d "$path"; then
20539      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20540    fi
20541
20542    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20543  fi
20544
20545              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20546$as_echo_n "checking for Boot JDK... " >&6; }
20547              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20548$as_echo "$BOOT_JDK" >&6; }
20549              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20550$as_echo_n "checking Boot JDK version... " >&6; }
20551              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20552              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20553$as_echo "$BOOT_JDK_VERSION" >&6; }
20554            fi # end check jdk version
20555          fi # end check rt.jar
20556        fi # end check javac
20557      fi # end check java
20558    fi # end check boot jdk found
20559  fi
20560
20561    # If that did not work out (e.g. too old), try explicit versions instead
20562
20563  if test "x$BOOT_JDK_FOUND" = xno; then
20564    # Now execute the test
20565
20566  if test -x /usr/libexec/java_home; then
20567    BOOT_JDK=`/usr/libexec/java_home -v 1.9`
20568    BOOT_JDK_FOUND=maybe
20569    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5
20570$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;}
20571  fi
20572
20573
20574    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20575    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20576      # Do we have a bin/java?
20577      if test ! -x "$BOOT_JDK/bin/java"; then
20578        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20579$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20580        BOOT_JDK_FOUND=no
20581      else
20582        # Do we have a bin/javac?
20583        if test ! -x "$BOOT_JDK/bin/javac"; then
20584          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20585$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20586          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20587$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20588          BOOT_JDK_FOUND=no
20589        else
20590          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20591          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20592            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20593$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20594            BOOT_JDK_FOUND=no
20595          else
20596            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20597            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20598
20599            # Extra M4 quote needed to protect [] in grep expression.
20600            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20601            if test "x$FOUND_CORRECT_VERSION" = x; then
20602              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20603$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20604              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20605$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20606              BOOT_JDK_FOUND=no
20607            else
20608              # We're done! :-)
20609              BOOT_JDK_FOUND=yes
20610
20611  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20612
20613  # Input might be given as Windows format, start by converting to
20614  # unix format.
20615  path="$BOOT_JDK"
20616  new_path=`$CYGPATH -u "$path"`
20617
20618  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20619  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20620  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20621  # "foo.exe" is OK but "foo" is an error.
20622  #
20623  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20624  # It is also a way to make sure we got the proper file name for the real test later on.
20625  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20626  if test "x$test_shortpath" = x; then
20627    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20628$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20629    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20630  fi
20631
20632  # Call helper function which possibly converts this using DOS-style short mode.
20633  # If so, the updated path is stored in $new_path.
20634
20635  input_path="$new_path"
20636  # Check if we need to convert this using DOS-style short mode. If the path
20637  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20638  # take no chances and rewrite it.
20639  # Note: m4 eats our [], so we need to use [ and ] instead.
20640  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20641  if test "x$has_forbidden_chars" != x; then
20642    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20643    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20644    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20645    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20646      # Going to short mode and back again did indeed matter. Since short mode is
20647      # case insensitive, let's make it lowercase to improve readability.
20648      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20649      # Now convert it back to Unix-stile (cygpath)
20650      input_path=`$CYGPATH -u "$shortmode_path"`
20651      new_path="$input_path"
20652    fi
20653  fi
20654
20655  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20656  if test "x$test_cygdrive_prefix" = x; then
20657    # As a simple fix, exclude /usr/bin since it's not a real path.
20658    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20659      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20660      # a path prefixed by /cygdrive for fixpath to work.
20661      new_path="$CYGWIN_ROOT_PATH$input_path"
20662    fi
20663  fi
20664
20665
20666  if test "x$path" != "x$new_path"; then
20667    BOOT_JDK="$new_path"
20668    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20669$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20670  fi
20671
20672  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20673
20674  path="$BOOT_JDK"
20675  has_colon=`$ECHO $path | $GREP ^.:`
20676  new_path="$path"
20677  if test "x$has_colon" = x; then
20678    # Not in mixed or Windows style, start by that.
20679    new_path=`cmd //c echo $path`
20680  fi
20681
20682
20683  input_path="$new_path"
20684  # Check if we need to convert this using DOS-style short mode. If the path
20685  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20686  # take no chances and rewrite it.
20687  # Note: m4 eats our [], so we need to use [ and ] instead.
20688  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20689  if test "x$has_forbidden_chars" != x; then
20690    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20691    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20692  fi
20693
20694
20695  windows_path="$new_path"
20696  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20697    unix_path=`$CYGPATH -u "$windows_path"`
20698    new_path="$unix_path"
20699  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20700    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20701    new_path="$unix_path"
20702  fi
20703
20704  if test "x$path" != "x$new_path"; then
20705    BOOT_JDK="$new_path"
20706    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20707$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20708  fi
20709
20710  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20711  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20712
20713  else
20714    # We're on a posix platform. Hooray! :)
20715    path="$BOOT_JDK"
20716    has_space=`$ECHO "$path" | $GREP " "`
20717    if test "x$has_space" != x; then
20718      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20719$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20720      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20721    fi
20722
20723    # Use eval to expand a potential ~
20724    eval path="$path"
20725    if test ! -f "$path" && test ! -d "$path"; then
20726      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20727    fi
20728
20729    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20730  fi
20731
20732              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20733$as_echo_n "checking for Boot JDK... " >&6; }
20734              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20735$as_echo "$BOOT_JDK" >&6; }
20736              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20737$as_echo_n "checking Boot JDK version... " >&6; }
20738              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20739              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20740$as_echo "$BOOT_JDK_VERSION" >&6; }
20741            fi # end check jdk version
20742          fi # end check rt.jar
20743        fi # end check javac
20744      fi # end check java
20745    fi # end check boot jdk found
20746  fi
20747
20748
20749  if test "x$BOOT_JDK_FOUND" = xno; then
20750    # Now execute the test
20751
20752  if test -x /usr/libexec/java_home; then
20753    BOOT_JDK=`/usr/libexec/java_home -v 1.8`
20754    BOOT_JDK_FOUND=maybe
20755    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5
20756$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;}
20757  fi
20758
20759
20760    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20761    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20762      # Do we have a bin/java?
20763      if test ! -x "$BOOT_JDK/bin/java"; then
20764        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20765$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20766        BOOT_JDK_FOUND=no
20767      else
20768        # Do we have a bin/javac?
20769        if test ! -x "$BOOT_JDK/bin/javac"; then
20770          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20771$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20772          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20773$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20774          BOOT_JDK_FOUND=no
20775        else
20776          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20777          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20778            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20779$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20780            BOOT_JDK_FOUND=no
20781          else
20782            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20783            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20784
20785            # Extra M4 quote needed to protect [] in grep expression.
20786            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20787            if test "x$FOUND_CORRECT_VERSION" = x; then
20788              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20789$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20790              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20791$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20792              BOOT_JDK_FOUND=no
20793            else
20794              # We're done! :-)
20795              BOOT_JDK_FOUND=yes
20796
20797  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20798
20799  # Input might be given as Windows format, start by converting to
20800  # unix format.
20801  path="$BOOT_JDK"
20802  new_path=`$CYGPATH -u "$path"`
20803
20804  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20805  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20806  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20807  # "foo.exe" is OK but "foo" is an error.
20808  #
20809  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20810  # It is also a way to make sure we got the proper file name for the real test later on.
20811  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20812  if test "x$test_shortpath" = x; then
20813    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20814$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20815    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20816  fi
20817
20818  # Call helper function which possibly converts this using DOS-style short mode.
20819  # If so, the updated path is stored in $new_path.
20820
20821  input_path="$new_path"
20822  # Check if we need to convert this using DOS-style short mode. If the path
20823  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20824  # take no chances and rewrite it.
20825  # Note: m4 eats our [], so we need to use [ and ] instead.
20826  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20827  if test "x$has_forbidden_chars" != x; then
20828    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20829    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20830    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20831    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20832      # Going to short mode and back again did indeed matter. Since short mode is
20833      # case insensitive, let's make it lowercase to improve readability.
20834      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20835      # Now convert it back to Unix-stile (cygpath)
20836      input_path=`$CYGPATH -u "$shortmode_path"`
20837      new_path="$input_path"
20838    fi
20839  fi
20840
20841  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20842  if test "x$test_cygdrive_prefix" = x; then
20843    # As a simple fix, exclude /usr/bin since it's not a real path.
20844    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20845      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20846      # a path prefixed by /cygdrive for fixpath to work.
20847      new_path="$CYGWIN_ROOT_PATH$input_path"
20848    fi
20849  fi
20850
20851
20852  if test "x$path" != "x$new_path"; then
20853    BOOT_JDK="$new_path"
20854    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20855$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20856  fi
20857
20858  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20859
20860  path="$BOOT_JDK"
20861  has_colon=`$ECHO $path | $GREP ^.:`
20862  new_path="$path"
20863  if test "x$has_colon" = x; then
20864    # Not in mixed or Windows style, start by that.
20865    new_path=`cmd //c echo $path`
20866  fi
20867
20868
20869  input_path="$new_path"
20870  # Check if we need to convert this using DOS-style short mode. If the path
20871  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20872  # take no chances and rewrite it.
20873  # Note: m4 eats our [], so we need to use [ and ] instead.
20874  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20875  if test "x$has_forbidden_chars" != x; then
20876    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20877    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20878  fi
20879
20880
20881  windows_path="$new_path"
20882  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20883    unix_path=`$CYGPATH -u "$windows_path"`
20884    new_path="$unix_path"
20885  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20886    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20887    new_path="$unix_path"
20888  fi
20889
20890  if test "x$path" != "x$new_path"; then
20891    BOOT_JDK="$new_path"
20892    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20893$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20894  fi
20895
20896  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20897  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20898
20899  else
20900    # We're on a posix platform. Hooray! :)
20901    path="$BOOT_JDK"
20902    has_space=`$ECHO "$path" | $GREP " "`
20903    if test "x$has_space" != x; then
20904      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20905$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20906      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20907    fi
20908
20909    # Use eval to expand a potential ~
20910    eval path="$path"
20911    if test ! -f "$path" && test ! -d "$path"; then
20912      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20913    fi
20914
20915    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20916  fi
20917
20918              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20919$as_echo_n "checking for Boot JDK... " >&6; }
20920              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20921$as_echo "$BOOT_JDK" >&6; }
20922              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20923$as_echo_n "checking Boot JDK version... " >&6; }
20924              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20925              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20926$as_echo "$BOOT_JDK_VERSION" >&6; }
20927            fi # end check jdk version
20928          fi # end check rt.jar
20929        fi # end check javac
20930      fi # end check java
20931    fi # end check boot jdk found
20932  fi
20933
20934
20935  if test "x$BOOT_JDK_FOUND" = xno; then
20936    # Now execute the test
20937
20938  if test -x /usr/libexec/java_home; then
20939    BOOT_JDK=`/usr/libexec/java_home -v 1.7`
20940    BOOT_JDK_FOUND=maybe
20941    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5
20942$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;}
20943  fi
20944
20945
20946    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20947    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20948      # Do we have a bin/java?
20949      if test ! -x "$BOOT_JDK/bin/java"; then
20950        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20951$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20952        BOOT_JDK_FOUND=no
20953      else
20954        # Do we have a bin/javac?
20955        if test ! -x "$BOOT_JDK/bin/javac"; then
20956          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20957$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20958          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20959$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20960          BOOT_JDK_FOUND=no
20961        else
20962          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20963          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20964            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20965$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20966            BOOT_JDK_FOUND=no
20967          else
20968            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20969            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20970
20971            # Extra M4 quote needed to protect [] in grep expression.
20972            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20973            if test "x$FOUND_CORRECT_VERSION" = x; then
20974              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20975$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20976              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20977$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20978              BOOT_JDK_FOUND=no
20979            else
20980              # We're done! :-)
20981              BOOT_JDK_FOUND=yes
20982
20983  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20984
20985  # Input might be given as Windows format, start by converting to
20986  # unix format.
20987  path="$BOOT_JDK"
20988  new_path=`$CYGPATH -u "$path"`
20989
20990  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20991  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20992  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20993  # "foo.exe" is OK but "foo" is an error.
20994  #
20995  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20996  # It is also a way to make sure we got the proper file name for the real test later on.
20997  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20998  if test "x$test_shortpath" = x; then
20999    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21000$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21001    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21002  fi
21003
21004  # Call helper function which possibly converts this using DOS-style short mode.
21005  # If so, the updated path is stored in $new_path.
21006
21007  input_path="$new_path"
21008  # Check if we need to convert this using DOS-style short mode. If the path
21009  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21010  # take no chances and rewrite it.
21011  # Note: m4 eats our [], so we need to use [ and ] instead.
21012  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21013  if test "x$has_forbidden_chars" != x; then
21014    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21015    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21016    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21017    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21018      # Going to short mode and back again did indeed matter. Since short mode is
21019      # case insensitive, let's make it lowercase to improve readability.
21020      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21021      # Now convert it back to Unix-stile (cygpath)
21022      input_path=`$CYGPATH -u "$shortmode_path"`
21023      new_path="$input_path"
21024    fi
21025  fi
21026
21027  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21028  if test "x$test_cygdrive_prefix" = x; then
21029    # As a simple fix, exclude /usr/bin since it's not a real path.
21030    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21031      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21032      # a path prefixed by /cygdrive for fixpath to work.
21033      new_path="$CYGWIN_ROOT_PATH$input_path"
21034    fi
21035  fi
21036
21037
21038  if test "x$path" != "x$new_path"; then
21039    BOOT_JDK="$new_path"
21040    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21041$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21042  fi
21043
21044  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21045
21046  path="$BOOT_JDK"
21047  has_colon=`$ECHO $path | $GREP ^.:`
21048  new_path="$path"
21049  if test "x$has_colon" = x; then
21050    # Not in mixed or Windows style, start by that.
21051    new_path=`cmd //c echo $path`
21052  fi
21053
21054
21055  input_path="$new_path"
21056  # Check if we need to convert this using DOS-style short mode. If the path
21057  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21058  # take no chances and rewrite it.
21059  # Note: m4 eats our [], so we need to use [ and ] instead.
21060  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21061  if test "x$has_forbidden_chars" != x; then
21062    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21063    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21064  fi
21065
21066
21067  windows_path="$new_path"
21068  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21069    unix_path=`$CYGPATH -u "$windows_path"`
21070    new_path="$unix_path"
21071  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21072    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21073    new_path="$unix_path"
21074  fi
21075
21076  if test "x$path" != "x$new_path"; then
21077    BOOT_JDK="$new_path"
21078    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21079$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21080  fi
21081
21082  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21083  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21084
21085  else
21086    # We're on a posix platform. Hooray! :)
21087    path="$BOOT_JDK"
21088    has_space=`$ECHO "$path" | $GREP " "`
21089    if test "x$has_space" != x; then
21090      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21091$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21092      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21093    fi
21094
21095    # Use eval to expand a potential ~
21096    eval path="$path"
21097    if test ! -f "$path" && test ! -d "$path"; then
21098      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21099    fi
21100
21101    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21102  fi
21103
21104              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21105$as_echo_n "checking for Boot JDK... " >&6; }
21106              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21107$as_echo "$BOOT_JDK" >&6; }
21108              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21109$as_echo_n "checking Boot JDK version... " >&6; }
21110              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21111              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21112$as_echo "$BOOT_JDK_VERSION" >&6; }
21113            fi # end check jdk version
21114          fi # end check rt.jar
21115        fi # end check javac
21116      fi # end check java
21117    fi # end check boot jdk found
21118  fi
21119
21120  fi
21121
21122
21123    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21124    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21125      # Do we have a bin/java?
21126      if test ! -x "$BOOT_JDK/bin/java"; then
21127        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21128$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21129        BOOT_JDK_FOUND=no
21130      else
21131        # Do we have a bin/javac?
21132        if test ! -x "$BOOT_JDK/bin/javac"; then
21133          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21134$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21135          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21136$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21137          BOOT_JDK_FOUND=no
21138        else
21139          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21140          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21141            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21142$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21143            BOOT_JDK_FOUND=no
21144          else
21145            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21146            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21147
21148            # Extra M4 quote needed to protect [] in grep expression.
21149            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21150            if test "x$FOUND_CORRECT_VERSION" = x; then
21151              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21152$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21153              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21154$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21155              BOOT_JDK_FOUND=no
21156            else
21157              # We're done! :-)
21158              BOOT_JDK_FOUND=yes
21159
21160  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21161
21162  # Input might be given as Windows format, start by converting to
21163  # unix format.
21164  path="$BOOT_JDK"
21165  new_path=`$CYGPATH -u "$path"`
21166
21167  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21168  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21169  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21170  # "foo.exe" is OK but "foo" is an error.
21171  #
21172  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21173  # It is also a way to make sure we got the proper file name for the real test later on.
21174  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21175  if test "x$test_shortpath" = x; then
21176    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21177$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21178    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21179  fi
21180
21181  # Call helper function which possibly converts this using DOS-style short mode.
21182  # If so, the updated path is stored in $new_path.
21183
21184  input_path="$new_path"
21185  # Check if we need to convert this using DOS-style short mode. If the path
21186  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21187  # take no chances and rewrite it.
21188  # Note: m4 eats our [], so we need to use [ and ] instead.
21189  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21190  if test "x$has_forbidden_chars" != x; then
21191    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21192    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21193    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21194    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21195      # Going to short mode and back again did indeed matter. Since short mode is
21196      # case insensitive, let's make it lowercase to improve readability.
21197      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21198      # Now convert it back to Unix-stile (cygpath)
21199      input_path=`$CYGPATH -u "$shortmode_path"`
21200      new_path="$input_path"
21201    fi
21202  fi
21203
21204  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21205  if test "x$test_cygdrive_prefix" = x; then
21206    # As a simple fix, exclude /usr/bin since it's not a real path.
21207    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21208      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21209      # a path prefixed by /cygdrive for fixpath to work.
21210      new_path="$CYGWIN_ROOT_PATH$input_path"
21211    fi
21212  fi
21213
21214
21215  if test "x$path" != "x$new_path"; then
21216    BOOT_JDK="$new_path"
21217    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21218$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21219  fi
21220
21221  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21222
21223  path="$BOOT_JDK"
21224  has_colon=`$ECHO $path | $GREP ^.:`
21225  new_path="$path"
21226  if test "x$has_colon" = x; then
21227    # Not in mixed or Windows style, start by that.
21228    new_path=`cmd //c echo $path`
21229  fi
21230
21231
21232  input_path="$new_path"
21233  # Check if we need to convert this using DOS-style short mode. If the path
21234  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21235  # take no chances and rewrite it.
21236  # Note: m4 eats our [], so we need to use [ and ] instead.
21237  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21238  if test "x$has_forbidden_chars" != x; then
21239    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21240    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21241  fi
21242
21243
21244  windows_path="$new_path"
21245  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21246    unix_path=`$CYGPATH -u "$windows_path"`
21247    new_path="$unix_path"
21248  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21249    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21250    new_path="$unix_path"
21251  fi
21252
21253  if test "x$path" != "x$new_path"; then
21254    BOOT_JDK="$new_path"
21255    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21256$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21257  fi
21258
21259  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21260  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21261
21262  else
21263    # We're on a posix platform. Hooray! :)
21264    path="$BOOT_JDK"
21265    has_space=`$ECHO "$path" | $GREP " "`
21266    if test "x$has_space" != x; then
21267      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21268$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21269      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21270    fi
21271
21272    # Use eval to expand a potential ~
21273    eval path="$path"
21274    if test ! -f "$path" && test ! -d "$path"; then
21275      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21276    fi
21277
21278    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21279  fi
21280
21281              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21282$as_echo_n "checking for Boot JDK... " >&6; }
21283              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21284$as_echo "$BOOT_JDK" >&6; }
21285              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21286$as_echo_n "checking Boot JDK version... " >&6; }
21287              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21288              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21289$as_echo "$BOOT_JDK_VERSION" >&6; }
21290            fi # end check jdk version
21291          fi # end check rt.jar
21292        fi # end check javac
21293      fi # end check java
21294    fi # end check boot jdk found
21295  fi
21296
21297
21298  # Test: Is $JAVA_HOME set?
21299
21300  if test "x$BOOT_JDK_FOUND" = xno; then
21301    # Now execute the test
21302
21303  if test "x$JAVA_HOME" != x; then
21304    JAVA_HOME_PROCESSED="$JAVA_HOME"
21305
21306  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21307
21308  # Input might be given as Windows format, start by converting to
21309  # unix format.
21310  path="$JAVA_HOME_PROCESSED"
21311  new_path=`$CYGPATH -u "$path"`
21312
21313  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21314  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21315  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21316  # "foo.exe" is OK but "foo" is an error.
21317  #
21318  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21319  # It is also a way to make sure we got the proper file name for the real test later on.
21320  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21321  if test "x$test_shortpath" = x; then
21322    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21323$as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21324    as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5
21325  fi
21326
21327  # Call helper function which possibly converts this using DOS-style short mode.
21328  # If so, the updated path is stored in $new_path.
21329
21330  input_path="$new_path"
21331  # Check if we need to convert this using DOS-style short mode. If the path
21332  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21333  # take no chances and rewrite it.
21334  # Note: m4 eats our [], so we need to use [ and ] instead.
21335  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21336  if test "x$has_forbidden_chars" != x; then
21337    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21338    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21339    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21340    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21341      # Going to short mode and back again did indeed matter. Since short mode is
21342      # case insensitive, let's make it lowercase to improve readability.
21343      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21344      # Now convert it back to Unix-stile (cygpath)
21345      input_path=`$CYGPATH -u "$shortmode_path"`
21346      new_path="$input_path"
21347    fi
21348  fi
21349
21350  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21351  if test "x$test_cygdrive_prefix" = x; then
21352    # As a simple fix, exclude /usr/bin since it's not a real path.
21353    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21354      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21355      # a path prefixed by /cygdrive for fixpath to work.
21356      new_path="$CYGWIN_ROOT_PATH$input_path"
21357    fi
21358  fi
21359
21360
21361  if test "x$path" != "x$new_path"; then
21362    JAVA_HOME_PROCESSED="$new_path"
21363    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21364$as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21365  fi
21366
21367  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21368
21369  path="$JAVA_HOME_PROCESSED"
21370  has_colon=`$ECHO $path | $GREP ^.:`
21371  new_path="$path"
21372  if test "x$has_colon" = x; then
21373    # Not in mixed or Windows style, start by that.
21374    new_path=`cmd //c echo $path`
21375  fi
21376
21377
21378  input_path="$new_path"
21379  # Check if we need to convert this using DOS-style short mode. If the path
21380  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21381  # take no chances and rewrite it.
21382  # Note: m4 eats our [], so we need to use [ and ] instead.
21383  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21384  if test "x$has_forbidden_chars" != x; then
21385    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21386    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21387  fi
21388
21389
21390  windows_path="$new_path"
21391  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21392    unix_path=`$CYGPATH -u "$windows_path"`
21393    new_path="$unix_path"
21394  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21395    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21396    new_path="$unix_path"
21397  fi
21398
21399  if test "x$path" != "x$new_path"; then
21400    JAVA_HOME_PROCESSED="$new_path"
21401    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21402$as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21403  fi
21404
21405  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21406  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21407
21408  else
21409    # We're on a posix platform. Hooray! :)
21410    path="$JAVA_HOME_PROCESSED"
21411    has_space=`$ECHO "$path" | $GREP " "`
21412    if test "x$has_space" != x; then
21413      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21414$as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21415      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21416    fi
21417
21418    # Use eval to expand a potential ~
21419    eval path="$path"
21420    if test ! -f "$path" && test ! -d "$path"; then
21421      as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5
21422    fi
21423
21424    JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`"
21425  fi
21426
21427    if test ! -d "$JAVA_HOME_PROCESSED"; then
21428      { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5
21429$as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;}
21430    else
21431      # Aha, the user has set a JAVA_HOME
21432      # let us use that as the Boot JDK.
21433      BOOT_JDK="$JAVA_HOME_PROCESSED"
21434      BOOT_JDK_FOUND=maybe
21435      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5
21436$as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;}
21437    fi
21438  fi
21439
21440
21441    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21442    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21443      # Do we have a bin/java?
21444      if test ! -x "$BOOT_JDK/bin/java"; then
21445        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21446$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21447        BOOT_JDK_FOUND=no
21448      else
21449        # Do we have a bin/javac?
21450        if test ! -x "$BOOT_JDK/bin/javac"; then
21451          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21452$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21453          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21454$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21455          BOOT_JDK_FOUND=no
21456        else
21457          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21458          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21459            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21460$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21461            BOOT_JDK_FOUND=no
21462          else
21463            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21464            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21465
21466            # Extra M4 quote needed to protect [] in grep expression.
21467            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21468            if test "x$FOUND_CORRECT_VERSION" = x; then
21469              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21470$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21471              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21472$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21473              BOOT_JDK_FOUND=no
21474            else
21475              # We're done! :-)
21476              BOOT_JDK_FOUND=yes
21477
21478  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21479
21480  # Input might be given as Windows format, start by converting to
21481  # unix format.
21482  path="$BOOT_JDK"
21483  new_path=`$CYGPATH -u "$path"`
21484
21485  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21486  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21487  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21488  # "foo.exe" is OK but "foo" is an error.
21489  #
21490  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21491  # It is also a way to make sure we got the proper file name for the real test later on.
21492  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21493  if test "x$test_shortpath" = x; then
21494    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21495$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21496    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21497  fi
21498
21499  # Call helper function which possibly converts this using DOS-style short mode.
21500  # If so, the updated path is stored in $new_path.
21501
21502  input_path="$new_path"
21503  # Check if we need to convert this using DOS-style short mode. If the path
21504  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21505  # take no chances and rewrite it.
21506  # Note: m4 eats our [], so we need to use [ and ] instead.
21507  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21508  if test "x$has_forbidden_chars" != x; then
21509    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21510    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21511    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21512    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21513      # Going to short mode and back again did indeed matter. Since short mode is
21514      # case insensitive, let's make it lowercase to improve readability.
21515      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21516      # Now convert it back to Unix-stile (cygpath)
21517      input_path=`$CYGPATH -u "$shortmode_path"`
21518      new_path="$input_path"
21519    fi
21520  fi
21521
21522  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21523  if test "x$test_cygdrive_prefix" = x; then
21524    # As a simple fix, exclude /usr/bin since it's not a real path.
21525    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21526      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21527      # a path prefixed by /cygdrive for fixpath to work.
21528      new_path="$CYGWIN_ROOT_PATH$input_path"
21529    fi
21530  fi
21531
21532
21533  if test "x$path" != "x$new_path"; then
21534    BOOT_JDK="$new_path"
21535    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21536$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21537  fi
21538
21539  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21540
21541  path="$BOOT_JDK"
21542  has_colon=`$ECHO $path | $GREP ^.:`
21543  new_path="$path"
21544  if test "x$has_colon" = x; then
21545    # Not in mixed or Windows style, start by that.
21546    new_path=`cmd //c echo $path`
21547  fi
21548
21549
21550  input_path="$new_path"
21551  # Check if we need to convert this using DOS-style short mode. If the path
21552  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21553  # take no chances and rewrite it.
21554  # Note: m4 eats our [], so we need to use [ and ] instead.
21555  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21556  if test "x$has_forbidden_chars" != x; then
21557    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21558    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21559  fi
21560
21561
21562  windows_path="$new_path"
21563  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21564    unix_path=`$CYGPATH -u "$windows_path"`
21565    new_path="$unix_path"
21566  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21567    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21568    new_path="$unix_path"
21569  fi
21570
21571  if test "x$path" != "x$new_path"; then
21572    BOOT_JDK="$new_path"
21573    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21574$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21575  fi
21576
21577  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21578  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21579
21580  else
21581    # We're on a posix platform. Hooray! :)
21582    path="$BOOT_JDK"
21583    has_space=`$ECHO "$path" | $GREP " "`
21584    if test "x$has_space" != x; then
21585      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21586$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21587      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21588    fi
21589
21590    # Use eval to expand a potential ~
21591    eval path="$path"
21592    if test ! -f "$path" && test ! -d "$path"; then
21593      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21594    fi
21595
21596    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21597  fi
21598
21599              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21600$as_echo_n "checking for Boot JDK... " >&6; }
21601              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21602$as_echo "$BOOT_JDK" >&6; }
21603              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21604$as_echo_n "checking Boot JDK version... " >&6; }
21605              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21606              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21607$as_echo "$BOOT_JDK_VERSION" >&6; }
21608            fi # end check jdk version
21609          fi # end check rt.jar
21610        fi # end check javac
21611      fi # end check java
21612    fi # end check boot jdk found
21613  fi
21614
21615
21616  # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
21617
21618  if test "x$BOOT_JDK_FOUND" = xno; then
21619    # Now execute the test
21620
21621  # Extract the first word of "javac", so it can be a program name with args.
21622set dummy javac; ac_word=$2
21623{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21624$as_echo_n "checking for $ac_word... " >&6; }
21625if ${ac_cv_path_JAVAC_CHECK+:} false; then :
21626  $as_echo_n "(cached) " >&6
21627else
21628  case $JAVAC_CHECK in
21629  [\\/]* | ?:[\\/]*)
21630  ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path.
21631  ;;
21632  *)
21633  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21634for as_dir in $PATH
21635do
21636  IFS=$as_save_IFS
21637  test -z "$as_dir" && as_dir=.
21638    for ac_exec_ext in '' $ac_executable_extensions; do
21639  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21640    ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext"
21641    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21642    break 2
21643  fi
21644done
21645  done
21646IFS=$as_save_IFS
21647
21648  ;;
21649esac
21650fi
21651JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK
21652if test -n "$JAVAC_CHECK"; then
21653  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5
21654$as_echo "$JAVAC_CHECK" >&6; }
21655else
21656  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21657$as_echo "no" >&6; }
21658fi
21659
21660
21661  # Extract the first word of "java", so it can be a program name with args.
21662set dummy java; ac_word=$2
21663{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21664$as_echo_n "checking for $ac_word... " >&6; }
21665if ${ac_cv_path_JAVA_CHECK+:} false; then :
21666  $as_echo_n "(cached) " >&6
21667else
21668  case $JAVA_CHECK in
21669  [\\/]* | ?:[\\/]*)
21670  ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path.
21671  ;;
21672  *)
21673  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21674for as_dir in $PATH
21675do
21676  IFS=$as_save_IFS
21677  test -z "$as_dir" && as_dir=.
21678    for ac_exec_ext in '' $ac_executable_extensions; do
21679  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21680    ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext"
21681    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21682    break 2
21683  fi
21684done
21685  done
21686IFS=$as_save_IFS
21687
21688  ;;
21689esac
21690fi
21691JAVA_CHECK=$ac_cv_path_JAVA_CHECK
21692if test -n "$JAVA_CHECK"; then
21693  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5
21694$as_echo "$JAVA_CHECK" >&6; }
21695else
21696  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21697$as_echo "no" >&6; }
21698fi
21699
21700
21701  BINARY="$JAVAC_CHECK"
21702  if test "x$JAVAC_CHECK" = x; then
21703    BINARY="$JAVA_CHECK"
21704  fi
21705  if test "x$BINARY" != x; then
21706    # So there is a java(c) binary, it might be part of a JDK.
21707    # Lets find the JDK/JRE directory by following symbolic links.
21708    # Linux/GNU systems often have links from /usr/bin/java to
21709    # /etc/alternatives/java to the real JDK binary.
21710
21711  if test "x$OPENJDK_BUILD_OS" != xwindows; then
21712    # Follow a chain of symbolic links. Use readlink
21713    # where it exists, else fall back to horribly
21714    # complicated shell code.
21715    if test "x$READLINK_TESTED" != yes; then
21716      # On MacOSX there is a readlink tool with a different
21717      # purpose than the GNU readlink tool. Check the found readlink.
21718      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
21719      if test "x$ISGNU" = x; then
21720        # A readlink that we do not know how to use.
21721        # Are there other non-GNU readlinks out there?
21722        READLINK_TESTED=yes
21723        READLINK=
21724      fi
21725    fi
21726
21727    if test "x$READLINK" != x; then
21728      BINARY=`$READLINK -f $BINARY`
21729    else
21730      # Save the current directory for restoring afterwards
21731      STARTDIR=$PWD
21732      COUNTER=0
21733      sym_link_dir=`$DIRNAME $BINARY`
21734      sym_link_file=`$BASENAME $BINARY`
21735      cd $sym_link_dir
21736      # Use -P flag to resolve symlinks in directories.
21737      cd `$THEPWDCMD -P`
21738      sym_link_dir=`$THEPWDCMD -P`
21739      # Resolve file symlinks
21740      while test $COUNTER -lt 20; do
21741        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
21742        if test "x$ISLINK" == x; then
21743          # This is not a symbolic link! We are done!
21744          break
21745        fi
21746        # Again resolve directory symlinks since the target of the just found
21747        # link could be in a different directory
21748        cd `$DIRNAME $ISLINK`
21749        sym_link_dir=`$THEPWDCMD -P`
21750        sym_link_file=`$BASENAME $ISLINK`
21751        let COUNTER=COUNTER+1
21752      done
21753      cd $STARTDIR
21754      BINARY=$sym_link_dir/$sym_link_file
21755    fi
21756  fi
21757
21758    BOOT_JDK=`dirname "$BINARY"`
21759    BOOT_JDK=`cd "$BOOT_JDK/.."; pwd`
21760    if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then
21761      # Looks like we found ourselves an JDK
21762      BOOT_JDK_FOUND=maybe
21763      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5
21764$as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;}
21765    fi
21766  fi
21767
21768
21769    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21770    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21771      # Do we have a bin/java?
21772      if test ! -x "$BOOT_JDK/bin/java"; then
21773        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21774$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21775        BOOT_JDK_FOUND=no
21776      else
21777        # Do we have a bin/javac?
21778        if test ! -x "$BOOT_JDK/bin/javac"; then
21779          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21780$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21781          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21782$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21783          BOOT_JDK_FOUND=no
21784        else
21785          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21786          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21787            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21788$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21789            BOOT_JDK_FOUND=no
21790          else
21791            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21792            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21793
21794            # Extra M4 quote needed to protect [] in grep expression.
21795            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21796            if test "x$FOUND_CORRECT_VERSION" = x; then
21797              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21798$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21799              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21800$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21801              BOOT_JDK_FOUND=no
21802            else
21803              # We're done! :-)
21804              BOOT_JDK_FOUND=yes
21805
21806  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21807
21808  # Input might be given as Windows format, start by converting to
21809  # unix format.
21810  path="$BOOT_JDK"
21811  new_path=`$CYGPATH -u "$path"`
21812
21813  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21814  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21815  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21816  # "foo.exe" is OK but "foo" is an error.
21817  #
21818  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21819  # It is also a way to make sure we got the proper file name for the real test later on.
21820  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21821  if test "x$test_shortpath" = x; then
21822    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21823$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21824    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21825  fi
21826
21827  # Call helper function which possibly converts this using DOS-style short mode.
21828  # If so, the updated path is stored in $new_path.
21829
21830  input_path="$new_path"
21831  # Check if we need to convert this using DOS-style short mode. If the path
21832  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21833  # take no chances and rewrite it.
21834  # Note: m4 eats our [], so we need to use [ and ] instead.
21835  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21836  if test "x$has_forbidden_chars" != x; then
21837    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21838    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21839    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21840    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21841      # Going to short mode and back again did indeed matter. Since short mode is
21842      # case insensitive, let's make it lowercase to improve readability.
21843      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21844      # Now convert it back to Unix-stile (cygpath)
21845      input_path=`$CYGPATH -u "$shortmode_path"`
21846      new_path="$input_path"
21847    fi
21848  fi
21849
21850  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21851  if test "x$test_cygdrive_prefix" = x; then
21852    # As a simple fix, exclude /usr/bin since it's not a real path.
21853    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21854      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21855      # a path prefixed by /cygdrive for fixpath to work.
21856      new_path="$CYGWIN_ROOT_PATH$input_path"
21857    fi
21858  fi
21859
21860
21861  if test "x$path" != "x$new_path"; then
21862    BOOT_JDK="$new_path"
21863    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21864$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21865  fi
21866
21867  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21868
21869  path="$BOOT_JDK"
21870  has_colon=`$ECHO $path | $GREP ^.:`
21871  new_path="$path"
21872  if test "x$has_colon" = x; then
21873    # Not in mixed or Windows style, start by that.
21874    new_path=`cmd //c echo $path`
21875  fi
21876
21877
21878  input_path="$new_path"
21879  # Check if we need to convert this using DOS-style short mode. If the path
21880  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21881  # take no chances and rewrite it.
21882  # Note: m4 eats our [], so we need to use [ and ] instead.
21883  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21884  if test "x$has_forbidden_chars" != x; then
21885    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21886    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21887  fi
21888
21889
21890  windows_path="$new_path"
21891  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21892    unix_path=`$CYGPATH -u "$windows_path"`
21893    new_path="$unix_path"
21894  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21895    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21896    new_path="$unix_path"
21897  fi
21898
21899  if test "x$path" != "x$new_path"; then
21900    BOOT_JDK="$new_path"
21901    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21902$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21903  fi
21904
21905  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21906  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21907
21908  else
21909    # We're on a posix platform. Hooray! :)
21910    path="$BOOT_JDK"
21911    has_space=`$ECHO "$path" | $GREP " "`
21912    if test "x$has_space" != x; then
21913      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21914$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21915      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21916    fi
21917
21918    # Use eval to expand a potential ~
21919    eval path="$path"
21920    if test ! -f "$path" && test ! -d "$path"; then
21921      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21922    fi
21923
21924    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21925  fi
21926
21927              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21928$as_echo_n "checking for Boot JDK... " >&6; }
21929              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21930$as_echo "$BOOT_JDK" >&6; }
21931              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21932$as_echo_n "checking Boot JDK version... " >&6; }
21933              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21934              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21935$as_echo "$BOOT_JDK_VERSION" >&6; }
21936            fi # end check jdk version
21937          fi # end check rt.jar
21938        fi # end check javac
21939      fi # end check java
21940    fi # end check boot jdk found
21941  fi
21942
21943
21944  # Test: Is there a JDK installed in default, well-known locations?
21945
21946  if test "x$BOOT_JDK_FOUND" = xno; then
21947    # Now execute the test
21948
21949  if test "x$OPENJDK_TARGET_OS" = xwindows; then
21950
21951  if test "x$BOOT_JDK_FOUND" = xno; then
21952    # Now execute the test
21953
21954  if test "x$ProgramW6432" != x; then
21955    VIRTUAL_DIR="$ProgramW6432/Java"
21956
21957  windows_path="$VIRTUAL_DIR"
21958  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21959    unix_path=`$CYGPATH -u "$windows_path"`
21960    VIRTUAL_DIR="$unix_path"
21961  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21962    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21963    VIRTUAL_DIR="$unix_path"
21964  fi
21965
21966
21967  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
21968  BOOT_JDK_SUFFIX=""
21969  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
21970  if test "x$ALL_JDKS_FOUND" != x; then
21971    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
21972
21973  if test "x$BOOT_JDK_FOUND" = xno; then
21974    # Now execute the test
21975
21976        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
21977        if test -d "$BOOT_JDK"; then
21978          BOOT_JDK_FOUND=maybe
21979          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
21980$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
21981        fi
21982
21983
21984    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21985    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21986      # Do we have a bin/java?
21987      if test ! -x "$BOOT_JDK/bin/java"; then
21988        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21989$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21990        BOOT_JDK_FOUND=no
21991      else
21992        # Do we have a bin/javac?
21993        if test ! -x "$BOOT_JDK/bin/javac"; then
21994          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21995$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21996          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21997$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21998          BOOT_JDK_FOUND=no
21999        else
22000          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22001          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22002            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22003$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22004            BOOT_JDK_FOUND=no
22005          else
22006            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22007            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22008
22009            # Extra M4 quote needed to protect [] in grep expression.
22010            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22011            if test "x$FOUND_CORRECT_VERSION" = x; then
22012              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22013$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22014              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22015$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22016              BOOT_JDK_FOUND=no
22017            else
22018              # We're done! :-)
22019              BOOT_JDK_FOUND=yes
22020
22021  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22022
22023  # Input might be given as Windows format, start by converting to
22024  # unix format.
22025  path="$BOOT_JDK"
22026  new_path=`$CYGPATH -u "$path"`
22027
22028  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22029  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22030  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22031  # "foo.exe" is OK but "foo" is an error.
22032  #
22033  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22034  # It is also a way to make sure we got the proper file name for the real test later on.
22035  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22036  if test "x$test_shortpath" = x; then
22037    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22038$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22039    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22040  fi
22041
22042  # Call helper function which possibly converts this using DOS-style short mode.
22043  # If so, the updated path is stored in $new_path.
22044
22045  input_path="$new_path"
22046  # Check if we need to convert this using DOS-style short mode. If the path
22047  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22048  # take no chances and rewrite it.
22049  # Note: m4 eats our [], so we need to use [ and ] instead.
22050  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22051  if test "x$has_forbidden_chars" != x; then
22052    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22053    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22054    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22055    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22056      # Going to short mode and back again did indeed matter. Since short mode is
22057      # case insensitive, let's make it lowercase to improve readability.
22058      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22059      # Now convert it back to Unix-stile (cygpath)
22060      input_path=`$CYGPATH -u "$shortmode_path"`
22061      new_path="$input_path"
22062    fi
22063  fi
22064
22065  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22066  if test "x$test_cygdrive_prefix" = x; then
22067    # As a simple fix, exclude /usr/bin since it's not a real path.
22068    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22069      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22070      # a path prefixed by /cygdrive for fixpath to work.
22071      new_path="$CYGWIN_ROOT_PATH$input_path"
22072    fi
22073  fi
22074
22075
22076  if test "x$path" != "x$new_path"; then
22077    BOOT_JDK="$new_path"
22078    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22079$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22080  fi
22081
22082  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22083
22084  path="$BOOT_JDK"
22085  has_colon=`$ECHO $path | $GREP ^.:`
22086  new_path="$path"
22087  if test "x$has_colon" = x; then
22088    # Not in mixed or Windows style, start by that.
22089    new_path=`cmd //c echo $path`
22090  fi
22091
22092
22093  input_path="$new_path"
22094  # Check if we need to convert this using DOS-style short mode. If the path
22095  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22096  # take no chances and rewrite it.
22097  # Note: m4 eats our [], so we need to use [ and ] instead.
22098  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22099  if test "x$has_forbidden_chars" != x; then
22100    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22101    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22102  fi
22103
22104
22105  windows_path="$new_path"
22106  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22107    unix_path=`$CYGPATH -u "$windows_path"`
22108    new_path="$unix_path"
22109  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22110    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22111    new_path="$unix_path"
22112  fi
22113
22114  if test "x$path" != "x$new_path"; then
22115    BOOT_JDK="$new_path"
22116    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22117$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22118  fi
22119
22120  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22121  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22122
22123  else
22124    # We're on a posix platform. Hooray! :)
22125    path="$BOOT_JDK"
22126    has_space=`$ECHO "$path" | $GREP " "`
22127    if test "x$has_space" != x; then
22128      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22129$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22130      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22131    fi
22132
22133    # Use eval to expand a potential ~
22134    eval path="$path"
22135    if test ! -f "$path" && test ! -d "$path"; then
22136      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22137    fi
22138
22139    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22140  fi
22141
22142              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22143$as_echo_n "checking for Boot JDK... " >&6; }
22144              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22145$as_echo "$BOOT_JDK" >&6; }
22146              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22147$as_echo_n "checking Boot JDK version... " >&6; }
22148              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22149              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22150$as_echo "$BOOT_JDK_VERSION" >&6; }
22151            fi # end check jdk version
22152          fi # end check rt.jar
22153        fi # end check javac
22154      fi # end check java
22155    fi # end check boot jdk found
22156  fi
22157
22158    done
22159  fi
22160
22161  fi
22162
22163
22164    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22165    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22166      # Do we have a bin/java?
22167      if test ! -x "$BOOT_JDK/bin/java"; then
22168        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22169$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22170        BOOT_JDK_FOUND=no
22171      else
22172        # Do we have a bin/javac?
22173        if test ! -x "$BOOT_JDK/bin/javac"; then
22174          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22175$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22176          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22177$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22178          BOOT_JDK_FOUND=no
22179        else
22180          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22181          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22182            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22183$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22184            BOOT_JDK_FOUND=no
22185          else
22186            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22187            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22188
22189            # Extra M4 quote needed to protect [] in grep expression.
22190            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22191            if test "x$FOUND_CORRECT_VERSION" = x; then
22192              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22193$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22194              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22195$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22196              BOOT_JDK_FOUND=no
22197            else
22198              # We're done! :-)
22199              BOOT_JDK_FOUND=yes
22200
22201  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22202
22203  # Input might be given as Windows format, start by converting to
22204  # unix format.
22205  path="$BOOT_JDK"
22206  new_path=`$CYGPATH -u "$path"`
22207
22208  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22209  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22210  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22211  # "foo.exe" is OK but "foo" is an error.
22212  #
22213  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22214  # It is also a way to make sure we got the proper file name for the real test later on.
22215  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22216  if test "x$test_shortpath" = x; then
22217    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22218$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22219    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22220  fi
22221
22222  # Call helper function which possibly converts this using DOS-style short mode.
22223  # If so, the updated path is stored in $new_path.
22224
22225  input_path="$new_path"
22226  # Check if we need to convert this using DOS-style short mode. If the path
22227  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22228  # take no chances and rewrite it.
22229  # Note: m4 eats our [], so we need to use [ and ] instead.
22230  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22231  if test "x$has_forbidden_chars" != x; then
22232    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22233    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22234    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22235    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22236      # Going to short mode and back again did indeed matter. Since short mode is
22237      # case insensitive, let's make it lowercase to improve readability.
22238      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22239      # Now convert it back to Unix-stile (cygpath)
22240      input_path=`$CYGPATH -u "$shortmode_path"`
22241      new_path="$input_path"
22242    fi
22243  fi
22244
22245  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22246  if test "x$test_cygdrive_prefix" = x; then
22247    # As a simple fix, exclude /usr/bin since it's not a real path.
22248    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22249      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22250      # a path prefixed by /cygdrive for fixpath to work.
22251      new_path="$CYGWIN_ROOT_PATH$input_path"
22252    fi
22253  fi
22254
22255
22256  if test "x$path" != "x$new_path"; then
22257    BOOT_JDK="$new_path"
22258    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22259$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22260  fi
22261
22262  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22263
22264  path="$BOOT_JDK"
22265  has_colon=`$ECHO $path | $GREP ^.:`
22266  new_path="$path"
22267  if test "x$has_colon" = x; then
22268    # Not in mixed or Windows style, start by that.
22269    new_path=`cmd //c echo $path`
22270  fi
22271
22272
22273  input_path="$new_path"
22274  # Check if we need to convert this using DOS-style short mode. If the path
22275  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22276  # take no chances and rewrite it.
22277  # Note: m4 eats our [], so we need to use [ and ] instead.
22278  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22279  if test "x$has_forbidden_chars" != x; then
22280    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22281    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22282  fi
22283
22284
22285  windows_path="$new_path"
22286  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22287    unix_path=`$CYGPATH -u "$windows_path"`
22288    new_path="$unix_path"
22289  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22290    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22291    new_path="$unix_path"
22292  fi
22293
22294  if test "x$path" != "x$new_path"; then
22295    BOOT_JDK="$new_path"
22296    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22297$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22298  fi
22299
22300  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22301  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22302
22303  else
22304    # We're on a posix platform. Hooray! :)
22305    path="$BOOT_JDK"
22306    has_space=`$ECHO "$path" | $GREP " "`
22307    if test "x$has_space" != x; then
22308      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22309$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22310      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22311    fi
22312
22313    # Use eval to expand a potential ~
22314    eval path="$path"
22315    if test ! -f "$path" && test ! -d "$path"; then
22316      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22317    fi
22318
22319    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22320  fi
22321
22322              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22323$as_echo_n "checking for Boot JDK... " >&6; }
22324              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22325$as_echo "$BOOT_JDK" >&6; }
22326              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22327$as_echo_n "checking Boot JDK version... " >&6; }
22328              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22329              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22330$as_echo "$BOOT_JDK_VERSION" >&6; }
22331            fi # end check jdk version
22332          fi # end check rt.jar
22333        fi # end check javac
22334      fi # end check java
22335    fi # end check boot jdk found
22336  fi
22337
22338
22339  if test "x$BOOT_JDK_FOUND" = xno; then
22340    # Now execute the test
22341
22342  if test "x$PROGRAMW6432" != x; then
22343    VIRTUAL_DIR="$PROGRAMW6432/Java"
22344
22345  windows_path="$VIRTUAL_DIR"
22346  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22347    unix_path=`$CYGPATH -u "$windows_path"`
22348    VIRTUAL_DIR="$unix_path"
22349  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22350    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22351    VIRTUAL_DIR="$unix_path"
22352  fi
22353
22354
22355  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22356  BOOT_JDK_SUFFIX=""
22357  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22358  if test "x$ALL_JDKS_FOUND" != x; then
22359    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22360
22361  if test "x$BOOT_JDK_FOUND" = xno; then
22362    # Now execute the test
22363
22364        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22365        if test -d "$BOOT_JDK"; then
22366          BOOT_JDK_FOUND=maybe
22367          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22368$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22369        fi
22370
22371
22372    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22373    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22374      # Do we have a bin/java?
22375      if test ! -x "$BOOT_JDK/bin/java"; then
22376        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22377$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22378        BOOT_JDK_FOUND=no
22379      else
22380        # Do we have a bin/javac?
22381        if test ! -x "$BOOT_JDK/bin/javac"; then
22382          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22383$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22384          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22385$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22386          BOOT_JDK_FOUND=no
22387        else
22388          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22389          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22390            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22391$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22392            BOOT_JDK_FOUND=no
22393          else
22394            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22395            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22396
22397            # Extra M4 quote needed to protect [] in grep expression.
22398            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22399            if test "x$FOUND_CORRECT_VERSION" = x; then
22400              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22401$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22402              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22403$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22404              BOOT_JDK_FOUND=no
22405            else
22406              # We're done! :-)
22407              BOOT_JDK_FOUND=yes
22408
22409  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22410
22411  # Input might be given as Windows format, start by converting to
22412  # unix format.
22413  path="$BOOT_JDK"
22414  new_path=`$CYGPATH -u "$path"`
22415
22416  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22417  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22418  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22419  # "foo.exe" is OK but "foo" is an error.
22420  #
22421  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22422  # It is also a way to make sure we got the proper file name for the real test later on.
22423  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22424  if test "x$test_shortpath" = x; then
22425    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22426$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22427    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22428  fi
22429
22430  # Call helper function which possibly converts this using DOS-style short mode.
22431  # If so, the updated path is stored in $new_path.
22432
22433  input_path="$new_path"
22434  # Check if we need to convert this using DOS-style short mode. If the path
22435  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22436  # take no chances and rewrite it.
22437  # Note: m4 eats our [], so we need to use [ and ] instead.
22438  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22439  if test "x$has_forbidden_chars" != x; then
22440    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22441    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22442    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22443    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22444      # Going to short mode and back again did indeed matter. Since short mode is
22445      # case insensitive, let's make it lowercase to improve readability.
22446      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22447      # Now convert it back to Unix-stile (cygpath)
22448      input_path=`$CYGPATH -u "$shortmode_path"`
22449      new_path="$input_path"
22450    fi
22451  fi
22452
22453  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22454  if test "x$test_cygdrive_prefix" = x; then
22455    # As a simple fix, exclude /usr/bin since it's not a real path.
22456    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22457      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22458      # a path prefixed by /cygdrive for fixpath to work.
22459      new_path="$CYGWIN_ROOT_PATH$input_path"
22460    fi
22461  fi
22462
22463
22464  if test "x$path" != "x$new_path"; then
22465    BOOT_JDK="$new_path"
22466    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22467$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22468  fi
22469
22470  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22471
22472  path="$BOOT_JDK"
22473  has_colon=`$ECHO $path | $GREP ^.:`
22474  new_path="$path"
22475  if test "x$has_colon" = x; then
22476    # Not in mixed or Windows style, start by that.
22477    new_path=`cmd //c echo $path`
22478  fi
22479
22480
22481  input_path="$new_path"
22482  # Check if we need to convert this using DOS-style short mode. If the path
22483  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22484  # take no chances and rewrite it.
22485  # Note: m4 eats our [], so we need to use [ and ] instead.
22486  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22487  if test "x$has_forbidden_chars" != x; then
22488    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22489    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22490  fi
22491
22492
22493  windows_path="$new_path"
22494  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22495    unix_path=`$CYGPATH -u "$windows_path"`
22496    new_path="$unix_path"
22497  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22498    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22499    new_path="$unix_path"
22500  fi
22501
22502  if test "x$path" != "x$new_path"; then
22503    BOOT_JDK="$new_path"
22504    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22505$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22506  fi
22507
22508  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22509  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22510
22511  else
22512    # We're on a posix platform. Hooray! :)
22513    path="$BOOT_JDK"
22514    has_space=`$ECHO "$path" | $GREP " "`
22515    if test "x$has_space" != x; then
22516      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22517$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22518      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22519    fi
22520
22521    # Use eval to expand a potential ~
22522    eval path="$path"
22523    if test ! -f "$path" && test ! -d "$path"; then
22524      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22525    fi
22526
22527    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22528  fi
22529
22530              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22531$as_echo_n "checking for Boot JDK... " >&6; }
22532              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22533$as_echo "$BOOT_JDK" >&6; }
22534              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22535$as_echo_n "checking Boot JDK version... " >&6; }
22536              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22537              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22538$as_echo "$BOOT_JDK_VERSION" >&6; }
22539            fi # end check jdk version
22540          fi # end check rt.jar
22541        fi # end check javac
22542      fi # end check java
22543    fi # end check boot jdk found
22544  fi
22545
22546    done
22547  fi
22548
22549  fi
22550
22551
22552    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22553    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22554      # Do we have a bin/java?
22555      if test ! -x "$BOOT_JDK/bin/java"; then
22556        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22557$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22558        BOOT_JDK_FOUND=no
22559      else
22560        # Do we have a bin/javac?
22561        if test ! -x "$BOOT_JDK/bin/javac"; then
22562          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22563$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22564          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22565$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22566          BOOT_JDK_FOUND=no
22567        else
22568          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22569          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22570            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22571$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22572            BOOT_JDK_FOUND=no
22573          else
22574            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22575            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22576
22577            # Extra M4 quote needed to protect [] in grep expression.
22578            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22579            if test "x$FOUND_CORRECT_VERSION" = x; then
22580              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22581$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22582              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22583$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22584              BOOT_JDK_FOUND=no
22585            else
22586              # We're done! :-)
22587              BOOT_JDK_FOUND=yes
22588
22589  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22590
22591  # Input might be given as Windows format, start by converting to
22592  # unix format.
22593  path="$BOOT_JDK"
22594  new_path=`$CYGPATH -u "$path"`
22595
22596  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22597  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22598  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22599  # "foo.exe" is OK but "foo" is an error.
22600  #
22601  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22602  # It is also a way to make sure we got the proper file name for the real test later on.
22603  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22604  if test "x$test_shortpath" = x; then
22605    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22606$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22607    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22608  fi
22609
22610  # Call helper function which possibly converts this using DOS-style short mode.
22611  # If so, the updated path is stored in $new_path.
22612
22613  input_path="$new_path"
22614  # Check if we need to convert this using DOS-style short mode. If the path
22615  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22616  # take no chances and rewrite it.
22617  # Note: m4 eats our [], so we need to use [ and ] instead.
22618  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22619  if test "x$has_forbidden_chars" != x; then
22620    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22621    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22622    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22623    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22624      # Going to short mode and back again did indeed matter. Since short mode is
22625      # case insensitive, let's make it lowercase to improve readability.
22626      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22627      # Now convert it back to Unix-stile (cygpath)
22628      input_path=`$CYGPATH -u "$shortmode_path"`
22629      new_path="$input_path"
22630    fi
22631  fi
22632
22633  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22634  if test "x$test_cygdrive_prefix" = x; then
22635    # As a simple fix, exclude /usr/bin since it's not a real path.
22636    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22637      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22638      # a path prefixed by /cygdrive for fixpath to work.
22639      new_path="$CYGWIN_ROOT_PATH$input_path"
22640    fi
22641  fi
22642
22643
22644  if test "x$path" != "x$new_path"; then
22645    BOOT_JDK="$new_path"
22646    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22647$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22648  fi
22649
22650  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22651
22652  path="$BOOT_JDK"
22653  has_colon=`$ECHO $path | $GREP ^.:`
22654  new_path="$path"
22655  if test "x$has_colon" = x; then
22656    # Not in mixed or Windows style, start by that.
22657    new_path=`cmd //c echo $path`
22658  fi
22659
22660
22661  input_path="$new_path"
22662  # Check if we need to convert this using DOS-style short mode. If the path
22663  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22664  # take no chances and rewrite it.
22665  # Note: m4 eats our [], so we need to use [ and ] instead.
22666  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22667  if test "x$has_forbidden_chars" != x; then
22668    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22669    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22670  fi
22671
22672
22673  windows_path="$new_path"
22674  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22675    unix_path=`$CYGPATH -u "$windows_path"`
22676    new_path="$unix_path"
22677  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22678    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22679    new_path="$unix_path"
22680  fi
22681
22682  if test "x$path" != "x$new_path"; then
22683    BOOT_JDK="$new_path"
22684    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22685$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22686  fi
22687
22688  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22689  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22690
22691  else
22692    # We're on a posix platform. Hooray! :)
22693    path="$BOOT_JDK"
22694    has_space=`$ECHO "$path" | $GREP " "`
22695    if test "x$has_space" != x; then
22696      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22697$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22698      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22699    fi
22700
22701    # Use eval to expand a potential ~
22702    eval path="$path"
22703    if test ! -f "$path" && test ! -d "$path"; then
22704      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22705    fi
22706
22707    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22708  fi
22709
22710              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22711$as_echo_n "checking for Boot JDK... " >&6; }
22712              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22713$as_echo "$BOOT_JDK" >&6; }
22714              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22715$as_echo_n "checking Boot JDK version... " >&6; }
22716              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22717              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22718$as_echo "$BOOT_JDK_VERSION" >&6; }
22719            fi # end check jdk version
22720          fi # end check rt.jar
22721        fi # end check javac
22722      fi # end check java
22723    fi # end check boot jdk found
22724  fi
22725
22726
22727  if test "x$BOOT_JDK_FOUND" = xno; then
22728    # Now execute the test
22729
22730  if test "x$PROGRAMFILES" != x; then
22731    VIRTUAL_DIR="$PROGRAMFILES/Java"
22732
22733  windows_path="$VIRTUAL_DIR"
22734  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22735    unix_path=`$CYGPATH -u "$windows_path"`
22736    VIRTUAL_DIR="$unix_path"
22737  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22738    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22739    VIRTUAL_DIR="$unix_path"
22740  fi
22741
22742
22743  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22744  BOOT_JDK_SUFFIX=""
22745  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22746  if test "x$ALL_JDKS_FOUND" != x; then
22747    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22748
22749  if test "x$BOOT_JDK_FOUND" = xno; then
22750    # Now execute the test
22751
22752        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22753        if test -d "$BOOT_JDK"; then
22754          BOOT_JDK_FOUND=maybe
22755          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22756$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22757        fi
22758
22759
22760    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22761    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22762      # Do we have a bin/java?
22763      if test ! -x "$BOOT_JDK/bin/java"; then
22764        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22765$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22766        BOOT_JDK_FOUND=no
22767      else
22768        # Do we have a bin/javac?
22769        if test ! -x "$BOOT_JDK/bin/javac"; then
22770          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22771$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22772          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22773$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22774          BOOT_JDK_FOUND=no
22775        else
22776          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22777          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22778            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22779$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22780            BOOT_JDK_FOUND=no
22781          else
22782            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22783            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22784
22785            # Extra M4 quote needed to protect [] in grep expression.
22786            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22787            if test "x$FOUND_CORRECT_VERSION" = x; then
22788              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22789$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22790              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22791$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22792              BOOT_JDK_FOUND=no
22793            else
22794              # We're done! :-)
22795              BOOT_JDK_FOUND=yes
22796
22797  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22798
22799  # Input might be given as Windows format, start by converting to
22800  # unix format.
22801  path="$BOOT_JDK"
22802  new_path=`$CYGPATH -u "$path"`
22803
22804  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22805  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22806  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22807  # "foo.exe" is OK but "foo" is an error.
22808  #
22809  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22810  # It is also a way to make sure we got the proper file name for the real test later on.
22811  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22812  if test "x$test_shortpath" = x; then
22813    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22814$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22815    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22816  fi
22817
22818  # Call helper function which possibly converts this using DOS-style short mode.
22819  # If so, the updated path is stored in $new_path.
22820
22821  input_path="$new_path"
22822  # Check if we need to convert this using DOS-style short mode. If the path
22823  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22824  # take no chances and rewrite it.
22825  # Note: m4 eats our [], so we need to use [ and ] instead.
22826  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22827  if test "x$has_forbidden_chars" != x; then
22828    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22829    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22830    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22831    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22832      # Going to short mode and back again did indeed matter. Since short mode is
22833      # case insensitive, let's make it lowercase to improve readability.
22834      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22835      # Now convert it back to Unix-stile (cygpath)
22836      input_path=`$CYGPATH -u "$shortmode_path"`
22837      new_path="$input_path"
22838    fi
22839  fi
22840
22841  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22842  if test "x$test_cygdrive_prefix" = x; then
22843    # As a simple fix, exclude /usr/bin since it's not a real path.
22844    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22845      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22846      # a path prefixed by /cygdrive for fixpath to work.
22847      new_path="$CYGWIN_ROOT_PATH$input_path"
22848    fi
22849  fi
22850
22851
22852  if test "x$path" != "x$new_path"; then
22853    BOOT_JDK="$new_path"
22854    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22855$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22856  fi
22857
22858  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22859
22860  path="$BOOT_JDK"
22861  has_colon=`$ECHO $path | $GREP ^.:`
22862  new_path="$path"
22863  if test "x$has_colon" = x; then
22864    # Not in mixed or Windows style, start by that.
22865    new_path=`cmd //c echo $path`
22866  fi
22867
22868
22869  input_path="$new_path"
22870  # Check if we need to convert this using DOS-style short mode. If the path
22871  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22872  # take no chances and rewrite it.
22873  # Note: m4 eats our [], so we need to use [ and ] instead.
22874  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22875  if test "x$has_forbidden_chars" != x; then
22876    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22877    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22878  fi
22879
22880
22881  windows_path="$new_path"
22882  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22883    unix_path=`$CYGPATH -u "$windows_path"`
22884    new_path="$unix_path"
22885  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22886    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22887    new_path="$unix_path"
22888  fi
22889
22890  if test "x$path" != "x$new_path"; then
22891    BOOT_JDK="$new_path"
22892    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22893$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22894  fi
22895
22896  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22897  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22898
22899  else
22900    # We're on a posix platform. Hooray! :)
22901    path="$BOOT_JDK"
22902    has_space=`$ECHO "$path" | $GREP " "`
22903    if test "x$has_space" != x; then
22904      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22905$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22906      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22907    fi
22908
22909    # Use eval to expand a potential ~
22910    eval path="$path"
22911    if test ! -f "$path" && test ! -d "$path"; then
22912      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22913    fi
22914
22915    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22916  fi
22917
22918              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22919$as_echo_n "checking for Boot JDK... " >&6; }
22920              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22921$as_echo "$BOOT_JDK" >&6; }
22922              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22923$as_echo_n "checking Boot JDK version... " >&6; }
22924              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22925              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22926$as_echo "$BOOT_JDK_VERSION" >&6; }
22927            fi # end check jdk version
22928          fi # end check rt.jar
22929        fi # end check javac
22930      fi # end check java
22931    fi # end check boot jdk found
22932  fi
22933
22934    done
22935  fi
22936
22937  fi
22938
22939
22940    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22941    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22942      # Do we have a bin/java?
22943      if test ! -x "$BOOT_JDK/bin/java"; then
22944        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22945$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22946        BOOT_JDK_FOUND=no
22947      else
22948        # Do we have a bin/javac?
22949        if test ! -x "$BOOT_JDK/bin/javac"; then
22950          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22951$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22952          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22953$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22954          BOOT_JDK_FOUND=no
22955        else
22956          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22957          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22958            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22959$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22960            BOOT_JDK_FOUND=no
22961          else
22962            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22963            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22964
22965            # Extra M4 quote needed to protect [] in grep expression.
22966            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22967            if test "x$FOUND_CORRECT_VERSION" = x; then
22968              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22969$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22970              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22971$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22972              BOOT_JDK_FOUND=no
22973            else
22974              # We're done! :-)
22975              BOOT_JDK_FOUND=yes
22976
22977  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22978
22979  # Input might be given as Windows format, start by converting to
22980  # unix format.
22981  path="$BOOT_JDK"
22982  new_path=`$CYGPATH -u "$path"`
22983
22984  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22985  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22986  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22987  # "foo.exe" is OK but "foo" is an error.
22988  #
22989  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22990  # It is also a way to make sure we got the proper file name for the real test later on.
22991  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22992  if test "x$test_shortpath" = x; then
22993    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22994$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22995    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22996  fi
22997
22998  # Call helper function which possibly converts this using DOS-style short mode.
22999  # If so, the updated path is stored in $new_path.
23000
23001  input_path="$new_path"
23002  # Check if we need to convert this using DOS-style short mode. If the path
23003  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23004  # take no chances and rewrite it.
23005  # Note: m4 eats our [], so we need to use [ and ] instead.
23006  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23007  if test "x$has_forbidden_chars" != x; then
23008    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23009    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23010    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23011    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23012      # Going to short mode and back again did indeed matter. Since short mode is
23013      # case insensitive, let's make it lowercase to improve readability.
23014      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23015      # Now convert it back to Unix-stile (cygpath)
23016      input_path=`$CYGPATH -u "$shortmode_path"`
23017      new_path="$input_path"
23018    fi
23019  fi
23020
23021  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23022  if test "x$test_cygdrive_prefix" = x; then
23023    # As a simple fix, exclude /usr/bin since it's not a real path.
23024    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23025      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23026      # a path prefixed by /cygdrive for fixpath to work.
23027      new_path="$CYGWIN_ROOT_PATH$input_path"
23028    fi
23029  fi
23030
23031
23032  if test "x$path" != "x$new_path"; then
23033    BOOT_JDK="$new_path"
23034    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23035$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23036  fi
23037
23038  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23039
23040  path="$BOOT_JDK"
23041  has_colon=`$ECHO $path | $GREP ^.:`
23042  new_path="$path"
23043  if test "x$has_colon" = x; then
23044    # Not in mixed or Windows style, start by that.
23045    new_path=`cmd //c echo $path`
23046  fi
23047
23048
23049  input_path="$new_path"
23050  # Check if we need to convert this using DOS-style short mode. If the path
23051  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23052  # take no chances and rewrite it.
23053  # Note: m4 eats our [], so we need to use [ and ] instead.
23054  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23055  if test "x$has_forbidden_chars" != x; then
23056    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23057    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23058  fi
23059
23060
23061  windows_path="$new_path"
23062  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23063    unix_path=`$CYGPATH -u "$windows_path"`
23064    new_path="$unix_path"
23065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23066    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23067    new_path="$unix_path"
23068  fi
23069
23070  if test "x$path" != "x$new_path"; then
23071    BOOT_JDK="$new_path"
23072    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23073$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23074  fi
23075
23076  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23077  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23078
23079  else
23080    # We're on a posix platform. Hooray! :)
23081    path="$BOOT_JDK"
23082    has_space=`$ECHO "$path" | $GREP " "`
23083    if test "x$has_space" != x; then
23084      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23085$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23086      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23087    fi
23088
23089    # Use eval to expand a potential ~
23090    eval path="$path"
23091    if test ! -f "$path" && test ! -d "$path"; then
23092      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23093    fi
23094
23095    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23096  fi
23097
23098              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23099$as_echo_n "checking for Boot JDK... " >&6; }
23100              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23101$as_echo "$BOOT_JDK" >&6; }
23102              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23103$as_echo_n "checking Boot JDK version... " >&6; }
23104              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23105              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23106$as_echo "$BOOT_JDK_VERSION" >&6; }
23107            fi # end check jdk version
23108          fi # end check rt.jar
23109        fi # end check javac
23110      fi # end check java
23111    fi # end check boot jdk found
23112  fi
23113
23114
23115  if test "x$BOOT_JDK_FOUND" = xno; then
23116    # Now execute the test
23117
23118  if test "x$ProgramFiles" != x; then
23119    VIRTUAL_DIR="$ProgramFiles/Java"
23120
23121  windows_path="$VIRTUAL_DIR"
23122  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23123    unix_path=`$CYGPATH -u "$windows_path"`
23124    VIRTUAL_DIR="$unix_path"
23125  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23126    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23127    VIRTUAL_DIR="$unix_path"
23128  fi
23129
23130
23131  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
23132  BOOT_JDK_SUFFIX=""
23133  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23134  if test "x$ALL_JDKS_FOUND" != x; then
23135    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23136
23137  if test "x$BOOT_JDK_FOUND" = xno; then
23138    # Now execute the test
23139
23140        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23141        if test -d "$BOOT_JDK"; then
23142          BOOT_JDK_FOUND=maybe
23143          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23144$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23145        fi
23146
23147
23148    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23149    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23150      # Do we have a bin/java?
23151      if test ! -x "$BOOT_JDK/bin/java"; then
23152        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23153$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23154        BOOT_JDK_FOUND=no
23155      else
23156        # Do we have a bin/javac?
23157        if test ! -x "$BOOT_JDK/bin/javac"; then
23158          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23159$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23160          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23161$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23162          BOOT_JDK_FOUND=no
23163        else
23164          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23165          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23166            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23167$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23168            BOOT_JDK_FOUND=no
23169          else
23170            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23171            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23172
23173            # Extra M4 quote needed to protect [] in grep expression.
23174            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23175            if test "x$FOUND_CORRECT_VERSION" = x; then
23176              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23177$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23178              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23179$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23180              BOOT_JDK_FOUND=no
23181            else
23182              # We're done! :-)
23183              BOOT_JDK_FOUND=yes
23184
23185  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23186
23187  # Input might be given as Windows format, start by converting to
23188  # unix format.
23189  path="$BOOT_JDK"
23190  new_path=`$CYGPATH -u "$path"`
23191
23192  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23193  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23194  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23195  # "foo.exe" is OK but "foo" is an error.
23196  #
23197  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23198  # It is also a way to make sure we got the proper file name for the real test later on.
23199  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23200  if test "x$test_shortpath" = x; then
23201    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23202$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23203    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23204  fi
23205
23206  # Call helper function which possibly converts this using DOS-style short mode.
23207  # If so, the updated path is stored in $new_path.
23208
23209  input_path="$new_path"
23210  # Check if we need to convert this using DOS-style short mode. If the path
23211  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23212  # take no chances and rewrite it.
23213  # Note: m4 eats our [], so we need to use [ and ] instead.
23214  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23215  if test "x$has_forbidden_chars" != x; then
23216    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23217    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23218    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23219    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23220      # Going to short mode and back again did indeed matter. Since short mode is
23221      # case insensitive, let's make it lowercase to improve readability.
23222      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23223      # Now convert it back to Unix-stile (cygpath)
23224      input_path=`$CYGPATH -u "$shortmode_path"`
23225      new_path="$input_path"
23226    fi
23227  fi
23228
23229  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23230  if test "x$test_cygdrive_prefix" = x; then
23231    # As a simple fix, exclude /usr/bin since it's not a real path.
23232    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23233      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23234      # a path prefixed by /cygdrive for fixpath to work.
23235      new_path="$CYGWIN_ROOT_PATH$input_path"
23236    fi
23237  fi
23238
23239
23240  if test "x$path" != "x$new_path"; then
23241    BOOT_JDK="$new_path"
23242    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23243$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23244  fi
23245
23246  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23247
23248  path="$BOOT_JDK"
23249  has_colon=`$ECHO $path | $GREP ^.:`
23250  new_path="$path"
23251  if test "x$has_colon" = x; then
23252    # Not in mixed or Windows style, start by that.
23253    new_path=`cmd //c echo $path`
23254  fi
23255
23256
23257  input_path="$new_path"
23258  # Check if we need to convert this using DOS-style short mode. If the path
23259  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23260  # take no chances and rewrite it.
23261  # Note: m4 eats our [], so we need to use [ and ] instead.
23262  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23263  if test "x$has_forbidden_chars" != x; then
23264    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23265    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23266  fi
23267
23268
23269  windows_path="$new_path"
23270  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23271    unix_path=`$CYGPATH -u "$windows_path"`
23272    new_path="$unix_path"
23273  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23274    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23275    new_path="$unix_path"
23276  fi
23277
23278  if test "x$path" != "x$new_path"; then
23279    BOOT_JDK="$new_path"
23280    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23281$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23282  fi
23283
23284  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23285  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23286
23287  else
23288    # We're on a posix platform. Hooray! :)
23289    path="$BOOT_JDK"
23290    has_space=`$ECHO "$path" | $GREP " "`
23291    if test "x$has_space" != x; then
23292      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23293$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23294      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23295    fi
23296
23297    # Use eval to expand a potential ~
23298    eval path="$path"
23299    if test ! -f "$path" && test ! -d "$path"; then
23300      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23301    fi
23302
23303    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23304  fi
23305
23306              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23307$as_echo_n "checking for Boot JDK... " >&6; }
23308              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23309$as_echo "$BOOT_JDK" >&6; }
23310              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23311$as_echo_n "checking Boot JDK version... " >&6; }
23312              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23313              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23314$as_echo "$BOOT_JDK_VERSION" >&6; }
23315            fi # end check jdk version
23316          fi # end check rt.jar
23317        fi # end check javac
23318      fi # end check java
23319    fi # end check boot jdk found
23320  fi
23321
23322    done
23323  fi
23324
23325  fi
23326
23327
23328    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23329    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23330      # Do we have a bin/java?
23331      if test ! -x "$BOOT_JDK/bin/java"; then
23332        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23333$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23334        BOOT_JDK_FOUND=no
23335      else
23336        # Do we have a bin/javac?
23337        if test ! -x "$BOOT_JDK/bin/javac"; then
23338          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23339$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23340          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23341$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23342          BOOT_JDK_FOUND=no
23343        else
23344          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23345          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23346            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23347$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23348            BOOT_JDK_FOUND=no
23349          else
23350            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23351            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23352
23353            # Extra M4 quote needed to protect [] in grep expression.
23354            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23355            if test "x$FOUND_CORRECT_VERSION" = x; then
23356              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23357$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23358              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23359$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23360              BOOT_JDK_FOUND=no
23361            else
23362              # We're done! :-)
23363              BOOT_JDK_FOUND=yes
23364
23365  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23366
23367  # Input might be given as Windows format, start by converting to
23368  # unix format.
23369  path="$BOOT_JDK"
23370  new_path=`$CYGPATH -u "$path"`
23371
23372  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23373  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23374  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23375  # "foo.exe" is OK but "foo" is an error.
23376  #
23377  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23378  # It is also a way to make sure we got the proper file name for the real test later on.
23379  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23380  if test "x$test_shortpath" = x; then
23381    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23382$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23383    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23384  fi
23385
23386  # Call helper function which possibly converts this using DOS-style short mode.
23387  # If so, the updated path is stored in $new_path.
23388
23389  input_path="$new_path"
23390  # Check if we need to convert this using DOS-style short mode. If the path
23391  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23392  # take no chances and rewrite it.
23393  # Note: m4 eats our [], so we need to use [ and ] instead.
23394  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23395  if test "x$has_forbidden_chars" != x; then
23396    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23397    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23398    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23399    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23400      # Going to short mode and back again did indeed matter. Since short mode is
23401      # case insensitive, let's make it lowercase to improve readability.
23402      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23403      # Now convert it back to Unix-stile (cygpath)
23404      input_path=`$CYGPATH -u "$shortmode_path"`
23405      new_path="$input_path"
23406    fi
23407  fi
23408
23409  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23410  if test "x$test_cygdrive_prefix" = x; then
23411    # As a simple fix, exclude /usr/bin since it's not a real path.
23412    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23413      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23414      # a path prefixed by /cygdrive for fixpath to work.
23415      new_path="$CYGWIN_ROOT_PATH$input_path"
23416    fi
23417  fi
23418
23419
23420  if test "x$path" != "x$new_path"; then
23421    BOOT_JDK="$new_path"
23422    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23423$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23424  fi
23425
23426  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23427
23428  path="$BOOT_JDK"
23429  has_colon=`$ECHO $path | $GREP ^.:`
23430  new_path="$path"
23431  if test "x$has_colon" = x; then
23432    # Not in mixed or Windows style, start by that.
23433    new_path=`cmd //c echo $path`
23434  fi
23435
23436
23437  input_path="$new_path"
23438  # Check if we need to convert this using DOS-style short mode. If the path
23439  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23440  # take no chances and rewrite it.
23441  # Note: m4 eats our [], so we need to use [ and ] instead.
23442  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23443  if test "x$has_forbidden_chars" != x; then
23444    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23445    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23446  fi
23447
23448
23449  windows_path="$new_path"
23450  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23451    unix_path=`$CYGPATH -u "$windows_path"`
23452    new_path="$unix_path"
23453  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23454    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23455    new_path="$unix_path"
23456  fi
23457
23458  if test "x$path" != "x$new_path"; then
23459    BOOT_JDK="$new_path"
23460    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23461$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23462  fi
23463
23464  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23465  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23466
23467  else
23468    # We're on a posix platform. Hooray! :)
23469    path="$BOOT_JDK"
23470    has_space=`$ECHO "$path" | $GREP " "`
23471    if test "x$has_space" != x; then
23472      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23473$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23474      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23475    fi
23476
23477    # Use eval to expand a potential ~
23478    eval path="$path"
23479    if test ! -f "$path" && test ! -d "$path"; then
23480      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23481    fi
23482
23483    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23484  fi
23485
23486              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23487$as_echo_n "checking for Boot JDK... " >&6; }
23488              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23489$as_echo "$BOOT_JDK" >&6; }
23490              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23491$as_echo_n "checking Boot JDK version... " >&6; }
23492              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23493              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23494$as_echo "$BOOT_JDK_VERSION" >&6; }
23495            fi # end check jdk version
23496          fi # end check rt.jar
23497        fi # end check javac
23498      fi # end check java
23499    fi # end check boot jdk found
23500  fi
23501
23502
23503  if test "x$BOOT_JDK_FOUND" = xno; then
23504    # Now execute the test
23505
23506  BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java"
23507  BOOT_JDK_SUFFIX=""
23508  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23509  if test "x$ALL_JDKS_FOUND" != x; then
23510    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23511
23512  if test "x$BOOT_JDK_FOUND" = xno; then
23513    # Now execute the test
23514
23515        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23516        if test -d "$BOOT_JDK"; then
23517          BOOT_JDK_FOUND=maybe
23518          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23519$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23520        fi
23521
23522
23523    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23524    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23525      # Do we have a bin/java?
23526      if test ! -x "$BOOT_JDK/bin/java"; then
23527        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23528$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23529        BOOT_JDK_FOUND=no
23530      else
23531        # Do we have a bin/javac?
23532        if test ! -x "$BOOT_JDK/bin/javac"; then
23533          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23534$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23535          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23536$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23537          BOOT_JDK_FOUND=no
23538        else
23539          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23540          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23541            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23542$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23543            BOOT_JDK_FOUND=no
23544          else
23545            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23546            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23547
23548            # Extra M4 quote needed to protect [] in grep expression.
23549            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23550            if test "x$FOUND_CORRECT_VERSION" = x; then
23551              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23552$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23553              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23554$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23555              BOOT_JDK_FOUND=no
23556            else
23557              # We're done! :-)
23558              BOOT_JDK_FOUND=yes
23559
23560  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23561
23562  # Input might be given as Windows format, start by converting to
23563  # unix format.
23564  path="$BOOT_JDK"
23565  new_path=`$CYGPATH -u "$path"`
23566
23567  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23568  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23569  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23570  # "foo.exe" is OK but "foo" is an error.
23571  #
23572  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23573  # It is also a way to make sure we got the proper file name for the real test later on.
23574  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23575  if test "x$test_shortpath" = x; then
23576    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23577$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23578    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23579  fi
23580
23581  # Call helper function which possibly converts this using DOS-style short mode.
23582  # If so, the updated path is stored in $new_path.
23583
23584  input_path="$new_path"
23585  # Check if we need to convert this using DOS-style short mode. If the path
23586  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23587  # take no chances and rewrite it.
23588  # Note: m4 eats our [], so we need to use [ and ] instead.
23589  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23590  if test "x$has_forbidden_chars" != x; then
23591    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23592    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23593    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23594    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23595      # Going to short mode and back again did indeed matter. Since short mode is
23596      # case insensitive, let's make it lowercase to improve readability.
23597      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23598      # Now convert it back to Unix-stile (cygpath)
23599      input_path=`$CYGPATH -u "$shortmode_path"`
23600      new_path="$input_path"
23601    fi
23602  fi
23603
23604  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23605  if test "x$test_cygdrive_prefix" = x; then
23606    # As a simple fix, exclude /usr/bin since it's not a real path.
23607    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23608      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23609      # a path prefixed by /cygdrive for fixpath to work.
23610      new_path="$CYGWIN_ROOT_PATH$input_path"
23611    fi
23612  fi
23613
23614
23615  if test "x$path" != "x$new_path"; then
23616    BOOT_JDK="$new_path"
23617    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23618$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23619  fi
23620
23621  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23622
23623  path="$BOOT_JDK"
23624  has_colon=`$ECHO $path | $GREP ^.:`
23625  new_path="$path"
23626  if test "x$has_colon" = x; then
23627    # Not in mixed or Windows style, start by that.
23628    new_path=`cmd //c echo $path`
23629  fi
23630
23631
23632  input_path="$new_path"
23633  # Check if we need to convert this using DOS-style short mode. If the path
23634  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23635  # take no chances and rewrite it.
23636  # Note: m4 eats our [], so we need to use [ and ] instead.
23637  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23638  if test "x$has_forbidden_chars" != x; then
23639    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23640    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23641  fi
23642
23643
23644  windows_path="$new_path"
23645  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23646    unix_path=`$CYGPATH -u "$windows_path"`
23647    new_path="$unix_path"
23648  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23649    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23650    new_path="$unix_path"
23651  fi
23652
23653  if test "x$path" != "x$new_path"; then
23654    BOOT_JDK="$new_path"
23655    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23656$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23657  fi
23658
23659  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23660  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23661
23662  else
23663    # We're on a posix platform. Hooray! :)
23664    path="$BOOT_JDK"
23665    has_space=`$ECHO "$path" | $GREP " "`
23666    if test "x$has_space" != x; then
23667      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23668$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23669      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23670    fi
23671
23672    # Use eval to expand a potential ~
23673    eval path="$path"
23674    if test ! -f "$path" && test ! -d "$path"; then
23675      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23676    fi
23677
23678    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23679  fi
23680
23681              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23682$as_echo_n "checking for Boot JDK... " >&6; }
23683              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23684$as_echo "$BOOT_JDK" >&6; }
23685              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23686$as_echo_n "checking Boot JDK version... " >&6; }
23687              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23688              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23689$as_echo "$BOOT_JDK_VERSION" >&6; }
23690            fi # end check jdk version
23691          fi # end check rt.jar
23692        fi # end check javac
23693      fi # end check java
23694    fi # end check boot jdk found
23695  fi
23696
23697    done
23698  fi
23699
23700
23701    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23702    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23703      # Do we have a bin/java?
23704      if test ! -x "$BOOT_JDK/bin/java"; then
23705        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23706$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23707        BOOT_JDK_FOUND=no
23708      else
23709        # Do we have a bin/javac?
23710        if test ! -x "$BOOT_JDK/bin/javac"; then
23711          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23712$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23713          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23714$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23715          BOOT_JDK_FOUND=no
23716        else
23717          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23718          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23719            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23720$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23721            BOOT_JDK_FOUND=no
23722          else
23723            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23724            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23725
23726            # Extra M4 quote needed to protect [] in grep expression.
23727            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23728            if test "x$FOUND_CORRECT_VERSION" = x; then
23729              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23730$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23731              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23732$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23733              BOOT_JDK_FOUND=no
23734            else
23735              # We're done! :-)
23736              BOOT_JDK_FOUND=yes
23737
23738  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23739
23740  # Input might be given as Windows format, start by converting to
23741  # unix format.
23742  path="$BOOT_JDK"
23743  new_path=`$CYGPATH -u "$path"`
23744
23745  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23746  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23747  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23748  # "foo.exe" is OK but "foo" is an error.
23749  #
23750  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23751  # It is also a way to make sure we got the proper file name for the real test later on.
23752  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23753  if test "x$test_shortpath" = x; then
23754    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23755$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23756    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23757  fi
23758
23759  # Call helper function which possibly converts this using DOS-style short mode.
23760  # If so, the updated path is stored in $new_path.
23761
23762  input_path="$new_path"
23763  # Check if we need to convert this using DOS-style short mode. If the path
23764  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23765  # take no chances and rewrite it.
23766  # Note: m4 eats our [], so we need to use [ and ] instead.
23767  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23768  if test "x$has_forbidden_chars" != x; then
23769    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23770    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23771    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23772    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23773      # Going to short mode and back again did indeed matter. Since short mode is
23774      # case insensitive, let's make it lowercase to improve readability.
23775      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23776      # Now convert it back to Unix-stile (cygpath)
23777      input_path=`$CYGPATH -u "$shortmode_path"`
23778      new_path="$input_path"
23779    fi
23780  fi
23781
23782  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23783  if test "x$test_cygdrive_prefix" = x; then
23784    # As a simple fix, exclude /usr/bin since it's not a real path.
23785    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23786      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23787      # a path prefixed by /cygdrive for fixpath to work.
23788      new_path="$CYGWIN_ROOT_PATH$input_path"
23789    fi
23790  fi
23791
23792
23793  if test "x$path" != "x$new_path"; then
23794    BOOT_JDK="$new_path"
23795    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23796$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23797  fi
23798
23799  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23800
23801  path="$BOOT_JDK"
23802  has_colon=`$ECHO $path | $GREP ^.:`
23803  new_path="$path"
23804  if test "x$has_colon" = x; then
23805    # Not in mixed or Windows style, start by that.
23806    new_path=`cmd //c echo $path`
23807  fi
23808
23809
23810  input_path="$new_path"
23811  # Check if we need to convert this using DOS-style short mode. If the path
23812  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23813  # take no chances and rewrite it.
23814  # Note: m4 eats our [], so we need to use [ and ] instead.
23815  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23816  if test "x$has_forbidden_chars" != x; then
23817    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23818    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23819  fi
23820
23821
23822  windows_path="$new_path"
23823  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23824    unix_path=`$CYGPATH -u "$windows_path"`
23825    new_path="$unix_path"
23826  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23827    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23828    new_path="$unix_path"
23829  fi
23830
23831  if test "x$path" != "x$new_path"; then
23832    BOOT_JDK="$new_path"
23833    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23834$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23835  fi
23836
23837  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23838  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23839
23840  else
23841    # We're on a posix platform. Hooray! :)
23842    path="$BOOT_JDK"
23843    has_space=`$ECHO "$path" | $GREP " "`
23844    if test "x$has_space" != x; then
23845      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23846$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23847      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23848    fi
23849
23850    # Use eval to expand a potential ~
23851    eval path="$path"
23852    if test ! -f "$path" && test ! -d "$path"; then
23853      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23854    fi
23855
23856    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23857  fi
23858
23859              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23860$as_echo_n "checking for Boot JDK... " >&6; }
23861              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23862$as_echo "$BOOT_JDK" >&6; }
23863              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23864$as_echo_n "checking Boot JDK version... " >&6; }
23865              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23866              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23867$as_echo "$BOOT_JDK_VERSION" >&6; }
23868            fi # end check jdk version
23869          fi # end check rt.jar
23870        fi # end check javac
23871      fi # end check java
23872    fi # end check boot jdk found
23873  fi
23874
23875  elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
23876
23877  if test "x$BOOT_JDK_FOUND" = xno; then
23878    # Now execute the test
23879
23880  BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines"
23881  BOOT_JDK_SUFFIX="/Contents/Home"
23882  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23883  if test "x$ALL_JDKS_FOUND" != x; then
23884    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23885
23886  if test "x$BOOT_JDK_FOUND" = xno; then
23887    # Now execute the test
23888
23889        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23890        if test -d "$BOOT_JDK"; then
23891          BOOT_JDK_FOUND=maybe
23892          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23893$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23894        fi
23895
23896
23897    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23898    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23899      # Do we have a bin/java?
23900      if test ! -x "$BOOT_JDK/bin/java"; then
23901        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23902$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23903        BOOT_JDK_FOUND=no
23904      else
23905        # Do we have a bin/javac?
23906        if test ! -x "$BOOT_JDK/bin/javac"; then
23907          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23908$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23909          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23910$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23911          BOOT_JDK_FOUND=no
23912        else
23913          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23914          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23915            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23916$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23917            BOOT_JDK_FOUND=no
23918          else
23919            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23920            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23921
23922            # Extra M4 quote needed to protect [] in grep expression.
23923            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23924            if test "x$FOUND_CORRECT_VERSION" = x; then
23925              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23926$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23927              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23928$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23929              BOOT_JDK_FOUND=no
23930            else
23931              # We're done! :-)
23932              BOOT_JDK_FOUND=yes
23933
23934  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23935
23936  # Input might be given as Windows format, start by converting to
23937  # unix format.
23938  path="$BOOT_JDK"
23939  new_path=`$CYGPATH -u "$path"`
23940
23941  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23942  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23943  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23944  # "foo.exe" is OK but "foo" is an error.
23945  #
23946  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23947  # It is also a way to make sure we got the proper file name for the real test later on.
23948  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23949  if test "x$test_shortpath" = x; then
23950    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23951$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23952    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23953  fi
23954
23955  # Call helper function which possibly converts this using DOS-style short mode.
23956  # If so, the updated path is stored in $new_path.
23957
23958  input_path="$new_path"
23959  # Check if we need to convert this using DOS-style short mode. If the path
23960  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23961  # take no chances and rewrite it.
23962  # Note: m4 eats our [], so we need to use [ and ] instead.
23963  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23964  if test "x$has_forbidden_chars" != x; then
23965    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23966    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23967    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23968    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23969      # Going to short mode and back again did indeed matter. Since short mode is
23970      # case insensitive, let's make it lowercase to improve readability.
23971      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23972      # Now convert it back to Unix-stile (cygpath)
23973      input_path=`$CYGPATH -u "$shortmode_path"`
23974      new_path="$input_path"
23975    fi
23976  fi
23977
23978  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23979  if test "x$test_cygdrive_prefix" = x; then
23980    # As a simple fix, exclude /usr/bin since it's not a real path.
23981    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23982      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23983      # a path prefixed by /cygdrive for fixpath to work.
23984      new_path="$CYGWIN_ROOT_PATH$input_path"
23985    fi
23986  fi
23987
23988
23989  if test "x$path" != "x$new_path"; then
23990    BOOT_JDK="$new_path"
23991    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23992$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23993  fi
23994
23995  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23996
23997  path="$BOOT_JDK"
23998  has_colon=`$ECHO $path | $GREP ^.:`
23999  new_path="$path"
24000  if test "x$has_colon" = x; then
24001    # Not in mixed or Windows style, start by that.
24002    new_path=`cmd //c echo $path`
24003  fi
24004
24005
24006  input_path="$new_path"
24007  # Check if we need to convert this using DOS-style short mode. If the path
24008  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24009  # take no chances and rewrite it.
24010  # Note: m4 eats our [], so we need to use [ and ] instead.
24011  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24012  if test "x$has_forbidden_chars" != x; then
24013    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24014    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24015  fi
24016
24017
24018  windows_path="$new_path"
24019  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24020    unix_path=`$CYGPATH -u "$windows_path"`
24021    new_path="$unix_path"
24022  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24023    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24024    new_path="$unix_path"
24025  fi
24026
24027  if test "x$path" != "x$new_path"; then
24028    BOOT_JDK="$new_path"
24029    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24030$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24031  fi
24032
24033  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24034  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24035
24036  else
24037    # We're on a posix platform. Hooray! :)
24038    path="$BOOT_JDK"
24039    has_space=`$ECHO "$path" | $GREP " "`
24040    if test "x$has_space" != x; then
24041      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24042$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24043      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24044    fi
24045
24046    # Use eval to expand a potential ~
24047    eval path="$path"
24048    if test ! -f "$path" && test ! -d "$path"; then
24049      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24050    fi
24051
24052    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24053  fi
24054
24055              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24056$as_echo_n "checking for Boot JDK... " >&6; }
24057              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24058$as_echo "$BOOT_JDK" >&6; }
24059              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24060$as_echo_n "checking Boot JDK version... " >&6; }
24061              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24062              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24063$as_echo "$BOOT_JDK_VERSION" >&6; }
24064            fi # end check jdk version
24065          fi # end check rt.jar
24066        fi # end check javac
24067      fi # end check java
24068    fi # end check boot jdk found
24069  fi
24070
24071    done
24072  fi
24073
24074
24075    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24076    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24077      # Do we have a bin/java?
24078      if test ! -x "$BOOT_JDK/bin/java"; then
24079        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24080$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24081        BOOT_JDK_FOUND=no
24082      else
24083        # Do we have a bin/javac?
24084        if test ! -x "$BOOT_JDK/bin/javac"; then
24085          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24086$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24087          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24088$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24089          BOOT_JDK_FOUND=no
24090        else
24091          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24092          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24093            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24094$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24095            BOOT_JDK_FOUND=no
24096          else
24097            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24098            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24099
24100            # Extra M4 quote needed to protect [] in grep expression.
24101            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24102            if test "x$FOUND_CORRECT_VERSION" = x; then
24103              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24104$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24105              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24106$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24107              BOOT_JDK_FOUND=no
24108            else
24109              # We're done! :-)
24110              BOOT_JDK_FOUND=yes
24111
24112  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24113
24114  # Input might be given as Windows format, start by converting to
24115  # unix format.
24116  path="$BOOT_JDK"
24117  new_path=`$CYGPATH -u "$path"`
24118
24119  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24120  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24121  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24122  # "foo.exe" is OK but "foo" is an error.
24123  #
24124  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24125  # It is also a way to make sure we got the proper file name for the real test later on.
24126  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24127  if test "x$test_shortpath" = x; then
24128    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24129$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24130    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24131  fi
24132
24133  # Call helper function which possibly converts this using DOS-style short mode.
24134  # If so, the updated path is stored in $new_path.
24135
24136  input_path="$new_path"
24137  # Check if we need to convert this using DOS-style short mode. If the path
24138  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24139  # take no chances and rewrite it.
24140  # Note: m4 eats our [], so we need to use [ and ] instead.
24141  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24142  if test "x$has_forbidden_chars" != x; then
24143    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24144    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24145    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24146    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24147      # Going to short mode and back again did indeed matter. Since short mode is
24148      # case insensitive, let's make it lowercase to improve readability.
24149      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24150      # Now convert it back to Unix-stile (cygpath)
24151      input_path=`$CYGPATH -u "$shortmode_path"`
24152      new_path="$input_path"
24153    fi
24154  fi
24155
24156  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24157  if test "x$test_cygdrive_prefix" = x; then
24158    # As a simple fix, exclude /usr/bin since it's not a real path.
24159    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24160      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24161      # a path prefixed by /cygdrive for fixpath to work.
24162      new_path="$CYGWIN_ROOT_PATH$input_path"
24163    fi
24164  fi
24165
24166
24167  if test "x$path" != "x$new_path"; then
24168    BOOT_JDK="$new_path"
24169    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24170$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24171  fi
24172
24173  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24174
24175  path="$BOOT_JDK"
24176  has_colon=`$ECHO $path | $GREP ^.:`
24177  new_path="$path"
24178  if test "x$has_colon" = x; then
24179    # Not in mixed or Windows style, start by that.
24180    new_path=`cmd //c echo $path`
24181  fi
24182
24183
24184  input_path="$new_path"
24185  # Check if we need to convert this using DOS-style short mode. If the path
24186  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24187  # take no chances and rewrite it.
24188  # Note: m4 eats our [], so we need to use [ and ] instead.
24189  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24190  if test "x$has_forbidden_chars" != x; then
24191    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24192    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24193  fi
24194
24195
24196  windows_path="$new_path"
24197  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24198    unix_path=`$CYGPATH -u "$windows_path"`
24199    new_path="$unix_path"
24200  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24201    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24202    new_path="$unix_path"
24203  fi
24204
24205  if test "x$path" != "x$new_path"; then
24206    BOOT_JDK="$new_path"
24207    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24208$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24209  fi
24210
24211  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24212  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24213
24214  else
24215    # We're on a posix platform. Hooray! :)
24216    path="$BOOT_JDK"
24217    has_space=`$ECHO "$path" | $GREP " "`
24218    if test "x$has_space" != x; then
24219      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24220$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24221      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24222    fi
24223
24224    # Use eval to expand a potential ~
24225    eval path="$path"
24226    if test ! -f "$path" && test ! -d "$path"; then
24227      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24228    fi
24229
24230    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24231  fi
24232
24233              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24234$as_echo_n "checking for Boot JDK... " >&6; }
24235              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24236$as_echo "$BOOT_JDK" >&6; }
24237              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24238$as_echo_n "checking Boot JDK version... " >&6; }
24239              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24240              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24241$as_echo "$BOOT_JDK_VERSION" >&6; }
24242            fi # end check jdk version
24243          fi # end check rt.jar
24244        fi # end check javac
24245      fi # end check java
24246    fi # end check boot jdk found
24247  fi
24248
24249
24250  if test "x$BOOT_JDK_FOUND" = xno; then
24251    # Now execute the test
24252
24253  BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines"
24254  BOOT_JDK_SUFFIX="/Contents/Home"
24255  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24256  if test "x$ALL_JDKS_FOUND" != x; then
24257    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24258
24259  if test "x$BOOT_JDK_FOUND" = xno; then
24260    # Now execute the test
24261
24262        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24263        if test -d "$BOOT_JDK"; then
24264          BOOT_JDK_FOUND=maybe
24265          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24266$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24267        fi
24268
24269
24270    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24271    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24272      # Do we have a bin/java?
24273      if test ! -x "$BOOT_JDK/bin/java"; then
24274        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24275$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24276        BOOT_JDK_FOUND=no
24277      else
24278        # Do we have a bin/javac?
24279        if test ! -x "$BOOT_JDK/bin/javac"; then
24280          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24281$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24282          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24283$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24284          BOOT_JDK_FOUND=no
24285        else
24286          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24287          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24288            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24289$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24290            BOOT_JDK_FOUND=no
24291          else
24292            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24293            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24294
24295            # Extra M4 quote needed to protect [] in grep expression.
24296            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24297            if test "x$FOUND_CORRECT_VERSION" = x; then
24298              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24299$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24300              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24301$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24302              BOOT_JDK_FOUND=no
24303            else
24304              # We're done! :-)
24305              BOOT_JDK_FOUND=yes
24306
24307  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24308
24309  # Input might be given as Windows format, start by converting to
24310  # unix format.
24311  path="$BOOT_JDK"
24312  new_path=`$CYGPATH -u "$path"`
24313
24314  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24315  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24316  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24317  # "foo.exe" is OK but "foo" is an error.
24318  #
24319  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24320  # It is also a way to make sure we got the proper file name for the real test later on.
24321  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24322  if test "x$test_shortpath" = x; then
24323    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24324$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24325    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24326  fi
24327
24328  # Call helper function which possibly converts this using DOS-style short mode.
24329  # If so, the updated path is stored in $new_path.
24330
24331  input_path="$new_path"
24332  # Check if we need to convert this using DOS-style short mode. If the path
24333  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24334  # take no chances and rewrite it.
24335  # Note: m4 eats our [], so we need to use [ and ] instead.
24336  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24337  if test "x$has_forbidden_chars" != x; then
24338    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24339    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24340    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24341    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24342      # Going to short mode and back again did indeed matter. Since short mode is
24343      # case insensitive, let's make it lowercase to improve readability.
24344      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24345      # Now convert it back to Unix-stile (cygpath)
24346      input_path=`$CYGPATH -u "$shortmode_path"`
24347      new_path="$input_path"
24348    fi
24349  fi
24350
24351  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24352  if test "x$test_cygdrive_prefix" = x; then
24353    # As a simple fix, exclude /usr/bin since it's not a real path.
24354    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24355      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24356      # a path prefixed by /cygdrive for fixpath to work.
24357      new_path="$CYGWIN_ROOT_PATH$input_path"
24358    fi
24359  fi
24360
24361
24362  if test "x$path" != "x$new_path"; then
24363    BOOT_JDK="$new_path"
24364    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24365$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24366  fi
24367
24368  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24369
24370  path="$BOOT_JDK"
24371  has_colon=`$ECHO $path | $GREP ^.:`
24372  new_path="$path"
24373  if test "x$has_colon" = x; then
24374    # Not in mixed or Windows style, start by that.
24375    new_path=`cmd //c echo $path`
24376  fi
24377
24378
24379  input_path="$new_path"
24380  # Check if we need to convert this using DOS-style short mode. If the path
24381  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24382  # take no chances and rewrite it.
24383  # Note: m4 eats our [], so we need to use [ and ] instead.
24384  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24385  if test "x$has_forbidden_chars" != x; then
24386    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24387    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24388  fi
24389
24390
24391  windows_path="$new_path"
24392  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24393    unix_path=`$CYGPATH -u "$windows_path"`
24394    new_path="$unix_path"
24395  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24396    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24397    new_path="$unix_path"
24398  fi
24399
24400  if test "x$path" != "x$new_path"; then
24401    BOOT_JDK="$new_path"
24402    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24403$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24404  fi
24405
24406  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24407  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24408
24409  else
24410    # We're on a posix platform. Hooray! :)
24411    path="$BOOT_JDK"
24412    has_space=`$ECHO "$path" | $GREP " "`
24413    if test "x$has_space" != x; then
24414      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24415$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24416      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24417    fi
24418
24419    # Use eval to expand a potential ~
24420    eval path="$path"
24421    if test ! -f "$path" && test ! -d "$path"; then
24422      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24423    fi
24424
24425    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24426  fi
24427
24428              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24429$as_echo_n "checking for Boot JDK... " >&6; }
24430              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24431$as_echo "$BOOT_JDK" >&6; }
24432              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24433$as_echo_n "checking Boot JDK version... " >&6; }
24434              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24435              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24436$as_echo "$BOOT_JDK_VERSION" >&6; }
24437            fi # end check jdk version
24438          fi # end check rt.jar
24439        fi # end check javac
24440      fi # end check java
24441    fi # end check boot jdk found
24442  fi
24443
24444    done
24445  fi
24446
24447
24448    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24449    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24450      # Do we have a bin/java?
24451      if test ! -x "$BOOT_JDK/bin/java"; then
24452        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24453$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24454        BOOT_JDK_FOUND=no
24455      else
24456        # Do we have a bin/javac?
24457        if test ! -x "$BOOT_JDK/bin/javac"; then
24458          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24459$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24460          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24461$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24462          BOOT_JDK_FOUND=no
24463        else
24464          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24465          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24466            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24467$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24468            BOOT_JDK_FOUND=no
24469          else
24470            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24471            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24472
24473            # Extra M4 quote needed to protect [] in grep expression.
24474            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24475            if test "x$FOUND_CORRECT_VERSION" = x; then
24476              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24477$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24478              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24479$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24480              BOOT_JDK_FOUND=no
24481            else
24482              # We're done! :-)
24483              BOOT_JDK_FOUND=yes
24484
24485  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24486
24487  # Input might be given as Windows format, start by converting to
24488  # unix format.
24489  path="$BOOT_JDK"
24490  new_path=`$CYGPATH -u "$path"`
24491
24492  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24493  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24494  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24495  # "foo.exe" is OK but "foo" is an error.
24496  #
24497  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24498  # It is also a way to make sure we got the proper file name for the real test later on.
24499  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24500  if test "x$test_shortpath" = x; then
24501    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24502$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24503    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24504  fi
24505
24506  # Call helper function which possibly converts this using DOS-style short mode.
24507  # If so, the updated path is stored in $new_path.
24508
24509  input_path="$new_path"
24510  # Check if we need to convert this using DOS-style short mode. If the path
24511  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24512  # take no chances and rewrite it.
24513  # Note: m4 eats our [], so we need to use [ and ] instead.
24514  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24515  if test "x$has_forbidden_chars" != x; then
24516    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24517    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24518    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24519    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24520      # Going to short mode and back again did indeed matter. Since short mode is
24521      # case insensitive, let's make it lowercase to improve readability.
24522      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24523      # Now convert it back to Unix-stile (cygpath)
24524      input_path=`$CYGPATH -u "$shortmode_path"`
24525      new_path="$input_path"
24526    fi
24527  fi
24528
24529  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24530  if test "x$test_cygdrive_prefix" = x; then
24531    # As a simple fix, exclude /usr/bin since it's not a real path.
24532    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24533      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24534      # a path prefixed by /cygdrive for fixpath to work.
24535      new_path="$CYGWIN_ROOT_PATH$input_path"
24536    fi
24537  fi
24538
24539
24540  if test "x$path" != "x$new_path"; then
24541    BOOT_JDK="$new_path"
24542    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24543$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24544  fi
24545
24546  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24547
24548  path="$BOOT_JDK"
24549  has_colon=`$ECHO $path | $GREP ^.:`
24550  new_path="$path"
24551  if test "x$has_colon" = x; then
24552    # Not in mixed or Windows style, start by that.
24553    new_path=`cmd //c echo $path`
24554  fi
24555
24556
24557  input_path="$new_path"
24558  # Check if we need to convert this using DOS-style short mode. If the path
24559  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24560  # take no chances and rewrite it.
24561  # Note: m4 eats our [], so we need to use [ and ] instead.
24562  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24563  if test "x$has_forbidden_chars" != x; then
24564    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24565    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24566  fi
24567
24568
24569  windows_path="$new_path"
24570  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24571    unix_path=`$CYGPATH -u "$windows_path"`
24572    new_path="$unix_path"
24573  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24574    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24575    new_path="$unix_path"
24576  fi
24577
24578  if test "x$path" != "x$new_path"; then
24579    BOOT_JDK="$new_path"
24580    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24581$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24582  fi
24583
24584  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24585  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24586
24587  else
24588    # We're on a posix platform. Hooray! :)
24589    path="$BOOT_JDK"
24590    has_space=`$ECHO "$path" | $GREP " "`
24591    if test "x$has_space" != x; then
24592      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24593$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24594      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24595    fi
24596
24597    # Use eval to expand a potential ~
24598    eval path="$path"
24599    if test ! -f "$path" && test ! -d "$path"; then
24600      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24601    fi
24602
24603    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24604  fi
24605
24606              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24607$as_echo_n "checking for Boot JDK... " >&6; }
24608              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24609$as_echo "$BOOT_JDK" >&6; }
24610              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24611$as_echo_n "checking Boot JDK version... " >&6; }
24612              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24613              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24614$as_echo "$BOOT_JDK_VERSION" >&6; }
24615            fi # end check jdk version
24616          fi # end check rt.jar
24617        fi # end check javac
24618      fi # end check java
24619    fi # end check boot jdk found
24620  fi
24621
24622  elif test "x$OPENJDK_TARGET_OS" = xlinux; then
24623
24624  if test "x$BOOT_JDK_FOUND" = xno; then
24625    # Now execute the test
24626
24627  BOOT_JDK_PREFIX="/usr/lib/jvm"
24628  BOOT_JDK_SUFFIX=""
24629  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24630  if test "x$ALL_JDKS_FOUND" != x; then
24631    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24632
24633  if test "x$BOOT_JDK_FOUND" = xno; then
24634    # Now execute the test
24635
24636        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24637        if test -d "$BOOT_JDK"; then
24638          BOOT_JDK_FOUND=maybe
24639          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24640$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24641        fi
24642
24643
24644    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24645    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24646      # Do we have a bin/java?
24647      if test ! -x "$BOOT_JDK/bin/java"; then
24648        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24649$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24650        BOOT_JDK_FOUND=no
24651      else
24652        # Do we have a bin/javac?
24653        if test ! -x "$BOOT_JDK/bin/javac"; then
24654          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24655$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24656          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24657$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24658          BOOT_JDK_FOUND=no
24659        else
24660          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24661          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24662            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24663$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24664            BOOT_JDK_FOUND=no
24665          else
24666            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24667            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24668
24669            # Extra M4 quote needed to protect [] in grep expression.
24670            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24671            if test "x$FOUND_CORRECT_VERSION" = x; then
24672              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24673$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24674              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24675$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24676              BOOT_JDK_FOUND=no
24677            else
24678              # We're done! :-)
24679              BOOT_JDK_FOUND=yes
24680
24681  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24682
24683  # Input might be given as Windows format, start by converting to
24684  # unix format.
24685  path="$BOOT_JDK"
24686  new_path=`$CYGPATH -u "$path"`
24687
24688  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24689  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24690  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24691  # "foo.exe" is OK but "foo" is an error.
24692  #
24693  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24694  # It is also a way to make sure we got the proper file name for the real test later on.
24695  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24696  if test "x$test_shortpath" = x; then
24697    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24698$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24699    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24700  fi
24701
24702  # Call helper function which possibly converts this using DOS-style short mode.
24703  # If so, the updated path is stored in $new_path.
24704
24705  input_path="$new_path"
24706  # Check if we need to convert this using DOS-style short mode. If the path
24707  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24708  # take no chances and rewrite it.
24709  # Note: m4 eats our [], so we need to use [ and ] instead.
24710  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24711  if test "x$has_forbidden_chars" != x; then
24712    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24713    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24714    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24715    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24716      # Going to short mode and back again did indeed matter. Since short mode is
24717      # case insensitive, let's make it lowercase to improve readability.
24718      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24719      # Now convert it back to Unix-stile (cygpath)
24720      input_path=`$CYGPATH -u "$shortmode_path"`
24721      new_path="$input_path"
24722    fi
24723  fi
24724
24725  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24726  if test "x$test_cygdrive_prefix" = x; then
24727    # As a simple fix, exclude /usr/bin since it's not a real path.
24728    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24729      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24730      # a path prefixed by /cygdrive for fixpath to work.
24731      new_path="$CYGWIN_ROOT_PATH$input_path"
24732    fi
24733  fi
24734
24735
24736  if test "x$path" != "x$new_path"; then
24737    BOOT_JDK="$new_path"
24738    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24739$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24740  fi
24741
24742  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24743
24744  path="$BOOT_JDK"
24745  has_colon=`$ECHO $path | $GREP ^.:`
24746  new_path="$path"
24747  if test "x$has_colon" = x; then
24748    # Not in mixed or Windows style, start by that.
24749    new_path=`cmd //c echo $path`
24750  fi
24751
24752
24753  input_path="$new_path"
24754  # Check if we need to convert this using DOS-style short mode. If the path
24755  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24756  # take no chances and rewrite it.
24757  # Note: m4 eats our [], so we need to use [ and ] instead.
24758  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24759  if test "x$has_forbidden_chars" != x; then
24760    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24761    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24762  fi
24763
24764
24765  windows_path="$new_path"
24766  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24767    unix_path=`$CYGPATH -u "$windows_path"`
24768    new_path="$unix_path"
24769  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24770    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24771    new_path="$unix_path"
24772  fi
24773
24774  if test "x$path" != "x$new_path"; then
24775    BOOT_JDK="$new_path"
24776    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24777$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24778  fi
24779
24780  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24781  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24782
24783  else
24784    # We're on a posix platform. Hooray! :)
24785    path="$BOOT_JDK"
24786    has_space=`$ECHO "$path" | $GREP " "`
24787    if test "x$has_space" != x; then
24788      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24789$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24790      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24791    fi
24792
24793    # Use eval to expand a potential ~
24794    eval path="$path"
24795    if test ! -f "$path" && test ! -d "$path"; then
24796      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24797    fi
24798
24799    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24800  fi
24801
24802              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24803$as_echo_n "checking for Boot JDK... " >&6; }
24804              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24805$as_echo "$BOOT_JDK" >&6; }
24806              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24807$as_echo_n "checking Boot JDK version... " >&6; }
24808              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24809              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24810$as_echo "$BOOT_JDK_VERSION" >&6; }
24811            fi # end check jdk version
24812          fi # end check rt.jar
24813        fi # end check javac
24814      fi # end check java
24815    fi # end check boot jdk found
24816  fi
24817
24818    done
24819  fi
24820
24821
24822    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24823    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24824      # Do we have a bin/java?
24825      if test ! -x "$BOOT_JDK/bin/java"; then
24826        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24827$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24828        BOOT_JDK_FOUND=no
24829      else
24830        # Do we have a bin/javac?
24831        if test ! -x "$BOOT_JDK/bin/javac"; then
24832          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24833$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24834          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24835$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24836          BOOT_JDK_FOUND=no
24837        else
24838          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24839          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24840            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24841$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24842            BOOT_JDK_FOUND=no
24843          else
24844            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24845            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24846
24847            # Extra M4 quote needed to protect [] in grep expression.
24848            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24849            if test "x$FOUND_CORRECT_VERSION" = x; then
24850              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24851$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24852              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24853$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24854              BOOT_JDK_FOUND=no
24855            else
24856              # We're done! :-)
24857              BOOT_JDK_FOUND=yes
24858
24859  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24860
24861  # Input might be given as Windows format, start by converting to
24862  # unix format.
24863  path="$BOOT_JDK"
24864  new_path=`$CYGPATH -u "$path"`
24865
24866  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24867  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24868  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24869  # "foo.exe" is OK but "foo" is an error.
24870  #
24871  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24872  # It is also a way to make sure we got the proper file name for the real test later on.
24873  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24874  if test "x$test_shortpath" = x; then
24875    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24876$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24877    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24878  fi
24879
24880  # Call helper function which possibly converts this using DOS-style short mode.
24881  # If so, the updated path is stored in $new_path.
24882
24883  input_path="$new_path"
24884  # Check if we need to convert this using DOS-style short mode. If the path
24885  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24886  # take no chances and rewrite it.
24887  # Note: m4 eats our [], so we need to use [ and ] instead.
24888  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24889  if test "x$has_forbidden_chars" != x; then
24890    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24891    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24892    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24893    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24894      # Going to short mode and back again did indeed matter. Since short mode is
24895      # case insensitive, let's make it lowercase to improve readability.
24896      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24897      # Now convert it back to Unix-stile (cygpath)
24898      input_path=`$CYGPATH -u "$shortmode_path"`
24899      new_path="$input_path"
24900    fi
24901  fi
24902
24903  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24904  if test "x$test_cygdrive_prefix" = x; then
24905    # As a simple fix, exclude /usr/bin since it's not a real path.
24906    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24907      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24908      # a path prefixed by /cygdrive for fixpath to work.
24909      new_path="$CYGWIN_ROOT_PATH$input_path"
24910    fi
24911  fi
24912
24913
24914  if test "x$path" != "x$new_path"; then
24915    BOOT_JDK="$new_path"
24916    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24917$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24918  fi
24919
24920  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24921
24922  path="$BOOT_JDK"
24923  has_colon=`$ECHO $path | $GREP ^.:`
24924  new_path="$path"
24925  if test "x$has_colon" = x; then
24926    # Not in mixed or Windows style, start by that.
24927    new_path=`cmd //c echo $path`
24928  fi
24929
24930
24931  input_path="$new_path"
24932  # Check if we need to convert this using DOS-style short mode. If the path
24933  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24934  # take no chances and rewrite it.
24935  # Note: m4 eats our [], so we need to use [ and ] instead.
24936  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24937  if test "x$has_forbidden_chars" != x; then
24938    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24939    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24940  fi
24941
24942
24943  windows_path="$new_path"
24944  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24945    unix_path=`$CYGPATH -u "$windows_path"`
24946    new_path="$unix_path"
24947  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24948    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24949    new_path="$unix_path"
24950  fi
24951
24952  if test "x$path" != "x$new_path"; then
24953    BOOT_JDK="$new_path"
24954    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24955$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24956  fi
24957
24958  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24959  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24960
24961  else
24962    # We're on a posix platform. Hooray! :)
24963    path="$BOOT_JDK"
24964    has_space=`$ECHO "$path" | $GREP " "`
24965    if test "x$has_space" != x; then
24966      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24967$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24968      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24969    fi
24970
24971    # Use eval to expand a potential ~
24972    eval path="$path"
24973    if test ! -f "$path" && test ! -d "$path"; then
24974      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24975    fi
24976
24977    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24978  fi
24979
24980              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24981$as_echo_n "checking for Boot JDK... " >&6; }
24982              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24983$as_echo "$BOOT_JDK" >&6; }
24984              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24985$as_echo_n "checking Boot JDK version... " >&6; }
24986              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24987              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24988$as_echo "$BOOT_JDK_VERSION" >&6; }
24989            fi # end check jdk version
24990          fi # end check rt.jar
24991        fi # end check javac
24992      fi # end check java
24993    fi # end check boot jdk found
24994  fi
24995
24996  fi
24997
24998
24999    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
25000    if test "x$BOOT_JDK_FOUND" = xmaybe; then
25001      # Do we have a bin/java?
25002      if test ! -x "$BOOT_JDK/bin/java"; then
25003        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
25004$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
25005        BOOT_JDK_FOUND=no
25006      else
25007        # Do we have a bin/javac?
25008        if test ! -x "$BOOT_JDK/bin/javac"; then
25009          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
25010$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
25011          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
25012$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
25013          BOOT_JDK_FOUND=no
25014        else
25015          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
25016          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
25017            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
25018$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
25019            BOOT_JDK_FOUND=no
25020          else
25021            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
25022            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
25023
25024            # Extra M4 quote needed to protect [] in grep expression.
25025            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
25026            if test "x$FOUND_CORRECT_VERSION" = x; then
25027              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
25028$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
25029              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
25030$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
25031              BOOT_JDK_FOUND=no
25032            else
25033              # We're done! :-)
25034              BOOT_JDK_FOUND=yes
25035
25036  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25037
25038  # Input might be given as Windows format, start by converting to
25039  # unix format.
25040  path="$BOOT_JDK"
25041  new_path=`$CYGPATH -u "$path"`
25042
25043  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
25044  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
25045  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
25046  # "foo.exe" is OK but "foo" is an error.
25047  #
25048  # This test is therefore slightly more accurate than "test -f" to check for file precense.
25049  # It is also a way to make sure we got the proper file name for the real test later on.
25050  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
25051  if test "x$test_shortpath" = x; then
25052    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25053$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25054    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
25055  fi
25056
25057  # Call helper function which possibly converts this using DOS-style short mode.
25058  # If so, the updated path is stored in $new_path.
25059
25060  input_path="$new_path"
25061  # Check if we need to convert this using DOS-style short mode. If the path
25062  # contains just simple characters, use it. Otherwise (spaces, weird characters),
25063  # take no chances and rewrite it.
25064  # Note: m4 eats our [], so we need to use [ and ] instead.
25065  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
25066  if test "x$has_forbidden_chars" != x; then
25067    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25068    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
25069    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
25070    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
25071      # Going to short mode and back again did indeed matter. Since short mode is
25072      # case insensitive, let's make it lowercase to improve readability.
25073      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25074      # Now convert it back to Unix-stile (cygpath)
25075      input_path=`$CYGPATH -u "$shortmode_path"`
25076      new_path="$input_path"
25077    fi
25078  fi
25079
25080  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
25081  if test "x$test_cygdrive_prefix" = x; then
25082    # As a simple fix, exclude /usr/bin since it's not a real path.
25083    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
25084      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
25085      # a path prefixed by /cygdrive for fixpath to work.
25086      new_path="$CYGWIN_ROOT_PATH$input_path"
25087    fi
25088  fi
25089
25090
25091  if test "x$path" != "x$new_path"; then
25092    BOOT_JDK="$new_path"
25093    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25094$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25095  fi
25096
25097  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25098
25099  path="$BOOT_JDK"
25100  has_colon=`$ECHO $path | $GREP ^.:`
25101  new_path="$path"
25102  if test "x$has_colon" = x; then
25103    # Not in mixed or Windows style, start by that.
25104    new_path=`cmd //c echo $path`
25105  fi
25106
25107
25108  input_path="$new_path"
25109  # Check if we need to convert this using DOS-style short mode. If the path
25110  # contains just simple characters, use it. Otherwise (spaces, weird characters),
25111  # take no chances and rewrite it.
25112  # Note: m4 eats our [], so we need to use [ and ] instead.
25113  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
25114  if test "x$has_forbidden_chars" != x; then
25115    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25116    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25117  fi
25118
25119
25120  windows_path="$new_path"
25121  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25122    unix_path=`$CYGPATH -u "$windows_path"`
25123    new_path="$unix_path"
25124  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25125    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
25126    new_path="$unix_path"
25127  fi
25128
25129  if test "x$path" != "x$new_path"; then
25130    BOOT_JDK="$new_path"
25131    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25132$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25133  fi
25134
25135  # Save the first 10 bytes of this path to the storage, so fixpath can work.
25136  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
25137
25138  else
25139    # We're on a posix platform. Hooray! :)
25140    path="$BOOT_JDK"
25141    has_space=`$ECHO "$path" | $GREP " "`
25142    if test "x$has_space" != x; then
25143      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25144$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25145      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
25146    fi
25147
25148    # Use eval to expand a potential ~
25149    eval path="$path"
25150    if test ! -f "$path" && test ! -d "$path"; then
25151      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
25152    fi
25153
25154    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
25155  fi
25156
25157              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
25158$as_echo_n "checking for Boot JDK... " >&6; }
25159              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25160$as_echo "$BOOT_JDK" >&6; }
25161              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25162$as_echo_n "checking Boot JDK version... " >&6; }
25163              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25164              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25165$as_echo "$BOOT_JDK_VERSION" >&6; }
25166            fi # end check jdk version
25167          fi # end check rt.jar
25168        fi # end check javac
25169      fi # end check java
25170    fi # end check boot jdk found
25171  fi
25172
25173
25174  # If we haven't found anything yet, we've truly lost. Give up.
25175  if test "x$BOOT_JDK_FOUND" = xno; then
25176
25177  # Print a helpful message on how to acquire the necessary build dependency.
25178  # openjdk is the help tag: freetype, cups, pulse, alsa etc
25179  MISSING_DEPENDENCY=openjdk
25180
25181  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25182    cygwin_help $MISSING_DEPENDENCY
25183  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25184    msys_help $MISSING_DEPENDENCY
25185  else
25186    PKGHANDLER_COMMAND=
25187
25188    case $PKGHANDLER in
25189      apt-get)
25190        apt_help     $MISSING_DEPENDENCY ;;
25191      yum)
25192        yum_help     $MISSING_DEPENDENCY ;;
25193      port)
25194        port_help    $MISSING_DEPENDENCY ;;
25195      pkgutil)
25196        pkgutil_help $MISSING_DEPENDENCY ;;
25197      pkgadd)
25198        pkgadd_help  $MISSING_DEPENDENCY ;;
25199    esac
25200
25201    if test "x$PKGHANDLER_COMMAND" != x; then
25202      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
25203    fi
25204  fi
25205
25206    { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5
25207$as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;}
25208    { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5
25209$as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25210    as_fn_error $? "Cannot continue" "$LINENO" 5
25211  fi
25212
25213  # Setup proper paths for what we found
25214  BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar"
25215  if test ! -f "$BOOT_RTJAR"; then
25216    # On MacOSX it is called classes.jar
25217    BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar"
25218    if test -f "$BOOT_RTJAR"; then
25219      # Remove the ..
25220      BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}"
25221    fi
25222  fi
25223  BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar"
25224  BOOT_JDK="$BOOT_JDK"
25225
25226
25227
25228
25229  # Setup tools from the Boot JDK.
25230
25231  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25232
25233  # Publish this variable in the help.
25234
25235
25236  if test "x$JAVA" = x; then
25237    # The variable is not set by user, try to locate tool using the code snippet
25238
25239      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25240$as_echo_n "checking for java in Boot JDK... " >&6; }
25241      JAVA=$BOOT_JDK/bin/java
25242      if test ! -x $JAVA; then
25243        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25244$as_echo "not found" >&6; }
25245        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25246$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25247        as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25248      fi
25249      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25250$as_echo "ok" >&6; }
25251
25252
25253  else
25254    # The variable is set, but is it from the command line or the environment?
25255
25256    # Try to remove the string !JAVA! from our list.
25257    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/}
25258    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25259      # If it failed, the variable was not from the command line. Ignore it,
25260      # but warn the user (except for BASH, which is always set by the calling BASH).
25261      if test "xJAVA" != xBASH; then
25262        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5
25263$as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;}
25264      fi
25265      # Try to locate tool using the code snippet
25266
25267      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25268$as_echo_n "checking for java in Boot JDK... " >&6; }
25269      JAVA=$BOOT_JDK/bin/java
25270      if test ! -x $JAVA; then
25271        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25272$as_echo "not found" >&6; }
25273        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25274$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25275        as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25276      fi
25277      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25278$as_echo "ok" >&6; }
25279
25280
25281    else
25282      # If it succeeded, then it was overridden by the user. We will use it
25283      # for the tool.
25284
25285      # First remove it from the list of overridden variables, so we can test
25286      # for unknown variables in the end.
25287      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25288
25289      # Check if the provided tool contains a complete path.
25290      tool_specified="$JAVA"
25291      tool_basename="${tool_specified##*/}"
25292      if test "x$tool_basename" = "x$tool_specified"; then
25293        # A command without a complete path is provided, search $PATH.
25294        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5
25295$as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;}
25296        # Extract the first word of "$tool_basename", so it can be a program name with args.
25297set dummy $tool_basename; ac_word=$2
25298{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25299$as_echo_n "checking for $ac_word... " >&6; }
25300if ${ac_cv_path_JAVA+:} false; then :
25301  $as_echo_n "(cached) " >&6
25302else
25303  case $JAVA in
25304  [\\/]* | ?:[\\/]*)
25305  ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path.
25306  ;;
25307  *)
25308  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25309for as_dir in $PATH
25310do
25311  IFS=$as_save_IFS
25312  test -z "$as_dir" && as_dir=.
25313    for ac_exec_ext in '' $ac_executable_extensions; do
25314  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25315    ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext"
25316    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25317    break 2
25318  fi
25319done
25320  done
25321IFS=$as_save_IFS
25322
25323  ;;
25324esac
25325fi
25326JAVA=$ac_cv_path_JAVA
25327if test -n "$JAVA"; then
25328  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5
25329$as_echo "$JAVA" >&6; }
25330else
25331  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25332$as_echo "no" >&6; }
25333fi
25334
25335
25336        if test "x$JAVA" = x; then
25337          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25338        fi
25339      else
25340        # Otherwise we believe it is a complete path. Use it as it is.
25341        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5
25342$as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;}
25343        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5
25344$as_echo_n "checking for JAVA... " >&6; }
25345        if test ! -x "$tool_specified"; then
25346          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25347$as_echo "not found" >&6; }
25348          as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5
25349        fi
25350        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25351$as_echo "$tool_specified" >&6; }
25352      fi
25353    fi
25354  fi
25355
25356
25357
25358  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25359
25360  # Publish this variable in the help.
25361
25362
25363  if test "x$JAVAC" = x; then
25364    # The variable is not set by user, try to locate tool using the code snippet
25365
25366      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25367$as_echo_n "checking for javac in Boot JDK... " >&6; }
25368      JAVAC=$BOOT_JDK/bin/javac
25369      if test ! -x $JAVAC; then
25370        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25371$as_echo "not found" >&6; }
25372        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25373$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25374        as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25375      fi
25376      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25377$as_echo "ok" >&6; }
25378
25379
25380  else
25381    # The variable is set, but is it from the command line or the environment?
25382
25383    # Try to remove the string !JAVAC! from our list.
25384    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/}
25385    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25386      # If it failed, the variable was not from the command line. Ignore it,
25387      # but warn the user (except for BASH, which is always set by the calling BASH).
25388      if test "xJAVAC" != xBASH; then
25389        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5
25390$as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;}
25391      fi
25392      # Try to locate tool using the code snippet
25393
25394      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25395$as_echo_n "checking for javac in Boot JDK... " >&6; }
25396      JAVAC=$BOOT_JDK/bin/javac
25397      if test ! -x $JAVAC; then
25398        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25399$as_echo "not found" >&6; }
25400        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25401$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25402        as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25403      fi
25404      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25405$as_echo "ok" >&6; }
25406
25407
25408    else
25409      # If it succeeded, then it was overridden by the user. We will use it
25410      # for the tool.
25411
25412      # First remove it from the list of overridden variables, so we can test
25413      # for unknown variables in the end.
25414      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25415
25416      # Check if the provided tool contains a complete path.
25417      tool_specified="$JAVAC"
25418      tool_basename="${tool_specified##*/}"
25419      if test "x$tool_basename" = "x$tool_specified"; then
25420        # A command without a complete path is provided, search $PATH.
25421        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5
25422$as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;}
25423        # Extract the first word of "$tool_basename", so it can be a program name with args.
25424set dummy $tool_basename; ac_word=$2
25425{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25426$as_echo_n "checking for $ac_word... " >&6; }
25427if ${ac_cv_path_JAVAC+:} false; then :
25428  $as_echo_n "(cached) " >&6
25429else
25430  case $JAVAC in
25431  [\\/]* | ?:[\\/]*)
25432  ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path.
25433  ;;
25434  *)
25435  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25436for as_dir in $PATH
25437do
25438  IFS=$as_save_IFS
25439  test -z "$as_dir" && as_dir=.
25440    for ac_exec_ext in '' $ac_executable_extensions; do
25441  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25442    ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext"
25443    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25444    break 2
25445  fi
25446done
25447  done
25448IFS=$as_save_IFS
25449
25450  ;;
25451esac
25452fi
25453JAVAC=$ac_cv_path_JAVAC
25454if test -n "$JAVAC"; then
25455  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5
25456$as_echo "$JAVAC" >&6; }
25457else
25458  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25459$as_echo "no" >&6; }
25460fi
25461
25462
25463        if test "x$JAVAC" = x; then
25464          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25465        fi
25466      else
25467        # Otherwise we believe it is a complete path. Use it as it is.
25468        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5
25469$as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;}
25470        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5
25471$as_echo_n "checking for JAVAC... " >&6; }
25472        if test ! -x "$tool_specified"; then
25473          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25474$as_echo "not found" >&6; }
25475          as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5
25476        fi
25477        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25478$as_echo "$tool_specified" >&6; }
25479      fi
25480    fi
25481  fi
25482
25483
25484
25485  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25486
25487  # Publish this variable in the help.
25488
25489
25490  if test "x$JAVAH" = x; then
25491    # The variable is not set by user, try to locate tool using the code snippet
25492
25493      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25494$as_echo_n "checking for javah in Boot JDK... " >&6; }
25495      JAVAH=$BOOT_JDK/bin/javah
25496      if test ! -x $JAVAH; then
25497        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25498$as_echo "not found" >&6; }
25499        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25500$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25501        as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25502      fi
25503      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25504$as_echo "ok" >&6; }
25505
25506
25507  else
25508    # The variable is set, but is it from the command line or the environment?
25509
25510    # Try to remove the string !JAVAH! from our list.
25511    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/}
25512    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25513      # If it failed, the variable was not from the command line. Ignore it,
25514      # but warn the user (except for BASH, which is always set by the calling BASH).
25515      if test "xJAVAH" != xBASH; then
25516        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5
25517$as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;}
25518      fi
25519      # Try to locate tool using the code snippet
25520
25521      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25522$as_echo_n "checking for javah in Boot JDK... " >&6; }
25523      JAVAH=$BOOT_JDK/bin/javah
25524      if test ! -x $JAVAH; then
25525        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25526$as_echo "not found" >&6; }
25527        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25528$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25529        as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25530      fi
25531      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25532$as_echo "ok" >&6; }
25533
25534
25535    else
25536      # If it succeeded, then it was overridden by the user. We will use it
25537      # for the tool.
25538
25539      # First remove it from the list of overridden variables, so we can test
25540      # for unknown variables in the end.
25541      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25542
25543      # Check if the provided tool contains a complete path.
25544      tool_specified="$JAVAH"
25545      tool_basename="${tool_specified##*/}"
25546      if test "x$tool_basename" = "x$tool_specified"; then
25547        # A command without a complete path is provided, search $PATH.
25548        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5
25549$as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;}
25550        # Extract the first word of "$tool_basename", so it can be a program name with args.
25551set dummy $tool_basename; ac_word=$2
25552{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25553$as_echo_n "checking for $ac_word... " >&6; }
25554if ${ac_cv_path_JAVAH+:} false; then :
25555  $as_echo_n "(cached) " >&6
25556else
25557  case $JAVAH in
25558  [\\/]* | ?:[\\/]*)
25559  ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path.
25560  ;;
25561  *)
25562  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25563for as_dir in $PATH
25564do
25565  IFS=$as_save_IFS
25566  test -z "$as_dir" && as_dir=.
25567    for ac_exec_ext in '' $ac_executable_extensions; do
25568  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25569    ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext"
25570    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25571    break 2
25572  fi
25573done
25574  done
25575IFS=$as_save_IFS
25576
25577  ;;
25578esac
25579fi
25580JAVAH=$ac_cv_path_JAVAH
25581if test -n "$JAVAH"; then
25582  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5
25583$as_echo "$JAVAH" >&6; }
25584else
25585  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25586$as_echo "no" >&6; }
25587fi
25588
25589
25590        if test "x$JAVAH" = x; then
25591          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25592        fi
25593      else
25594        # Otherwise we believe it is a complete path. Use it as it is.
25595        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5
25596$as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;}
25597        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5
25598$as_echo_n "checking for JAVAH... " >&6; }
25599        if test ! -x "$tool_specified"; then
25600          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25601$as_echo "not found" >&6; }
25602          as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5
25603        fi
25604        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25605$as_echo "$tool_specified" >&6; }
25606      fi
25607    fi
25608  fi
25609
25610
25611
25612  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25613
25614  # Publish this variable in the help.
25615
25616
25617  if test "x$JAR" = x; then
25618    # The variable is not set by user, try to locate tool using the code snippet
25619
25620      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25621$as_echo_n "checking for jar in Boot JDK... " >&6; }
25622      JAR=$BOOT_JDK/bin/jar
25623      if test ! -x $JAR; then
25624        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25625$as_echo "not found" >&6; }
25626        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25627$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25628        as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25629      fi
25630      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25631$as_echo "ok" >&6; }
25632
25633
25634  else
25635    # The variable is set, but is it from the command line or the environment?
25636
25637    # Try to remove the string !JAR! from our list.
25638    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/}
25639    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25640      # If it failed, the variable was not from the command line. Ignore it,
25641      # but warn the user (except for BASH, which is always set by the calling BASH).
25642      if test "xJAR" != xBASH; then
25643        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5
25644$as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;}
25645      fi
25646      # Try to locate tool using the code snippet
25647
25648      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25649$as_echo_n "checking for jar in Boot JDK... " >&6; }
25650      JAR=$BOOT_JDK/bin/jar
25651      if test ! -x $JAR; then
25652        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25653$as_echo "not found" >&6; }
25654        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25655$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25656        as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25657      fi
25658      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25659$as_echo "ok" >&6; }
25660
25661
25662    else
25663      # If it succeeded, then it was overridden by the user. We will use it
25664      # for the tool.
25665
25666      # First remove it from the list of overridden variables, so we can test
25667      # for unknown variables in the end.
25668      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25669
25670      # Check if the provided tool contains a complete path.
25671      tool_specified="$JAR"
25672      tool_basename="${tool_specified##*/}"
25673      if test "x$tool_basename" = "x$tool_specified"; then
25674        # A command without a complete path is provided, search $PATH.
25675        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5
25676$as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;}
25677        # Extract the first word of "$tool_basename", so it can be a program name with args.
25678set dummy $tool_basename; ac_word=$2
25679{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25680$as_echo_n "checking for $ac_word... " >&6; }
25681if ${ac_cv_path_JAR+:} false; then :
25682  $as_echo_n "(cached) " >&6
25683else
25684  case $JAR in
25685  [\\/]* | ?:[\\/]*)
25686  ac_cv_path_JAR="$JAR" # Let the user override the test with a path.
25687  ;;
25688  *)
25689  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25690for as_dir in $PATH
25691do
25692  IFS=$as_save_IFS
25693  test -z "$as_dir" && as_dir=.
25694    for ac_exec_ext in '' $ac_executable_extensions; do
25695  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25696    ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext"
25697    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25698    break 2
25699  fi
25700done
25701  done
25702IFS=$as_save_IFS
25703
25704  ;;
25705esac
25706fi
25707JAR=$ac_cv_path_JAR
25708if test -n "$JAR"; then
25709  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5
25710$as_echo "$JAR" >&6; }
25711else
25712  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25713$as_echo "no" >&6; }
25714fi
25715
25716
25717        if test "x$JAR" = x; then
25718          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25719        fi
25720      else
25721        # Otherwise we believe it is a complete path. Use it as it is.
25722        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5
25723$as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;}
25724        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5
25725$as_echo_n "checking for JAR... " >&6; }
25726        if test ! -x "$tool_specified"; then
25727          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25728$as_echo "not found" >&6; }
25729          as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5
25730        fi
25731        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25732$as_echo "$tool_specified" >&6; }
25733      fi
25734    fi
25735  fi
25736
25737
25738
25739  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25740
25741  # Publish this variable in the help.
25742
25743
25744  if test "x$NATIVE2ASCII" = x; then
25745    # The variable is not set by user, try to locate tool using the code snippet
25746
25747      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25748$as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25749      NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25750      if test ! -x $NATIVE2ASCII; then
25751        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25752$as_echo "not found" >&6; }
25753        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25754$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25755        as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25756      fi
25757      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25758$as_echo "ok" >&6; }
25759
25760
25761  else
25762    # The variable is set, but is it from the command line or the environment?
25763
25764    # Try to remove the string !NATIVE2ASCII! from our list.
25765    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NATIVE2ASCII!/}
25766    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25767      # If it failed, the variable was not from the command line. Ignore it,
25768      # but warn the user (except for BASH, which is always set by the calling BASH).
25769      if test "xNATIVE2ASCII" != xBASH; then
25770        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&5
25771$as_echo "$as_me: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&2;}
25772      fi
25773      # Try to locate tool using the code snippet
25774
25775      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25776$as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25777      NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25778      if test ! -x $NATIVE2ASCII; then
25779        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25780$as_echo "not found" >&6; }
25781        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25782$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25783        as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25784      fi
25785      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25786$as_echo "ok" >&6; }
25787
25788
25789    else
25790      # If it succeeded, then it was overridden by the user. We will use it
25791      # for the tool.
25792
25793      # First remove it from the list of overridden variables, so we can test
25794      # for unknown variables in the end.
25795      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25796
25797      # Check if the provided tool contains a complete path.
25798      tool_specified="$NATIVE2ASCII"
25799      tool_basename="${tool_specified##*/}"
25800      if test "x$tool_basename" = "x$tool_specified"; then
25801        # A command without a complete path is provided, search $PATH.
25802        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&5
25803$as_echo "$as_me: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&6;}
25804        # Extract the first word of "$tool_basename", so it can be a program name with args.
25805set dummy $tool_basename; ac_word=$2
25806{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25807$as_echo_n "checking for $ac_word... " >&6; }
25808if ${ac_cv_path_NATIVE2ASCII+:} false; then :
25809  $as_echo_n "(cached) " >&6
25810else
25811  case $NATIVE2ASCII in
25812  [\\/]* | ?:[\\/]*)
25813  ac_cv_path_NATIVE2ASCII="$NATIVE2ASCII" # Let the user override the test with a path.
25814  ;;
25815  *)
25816  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25817for as_dir in $PATH
25818do
25819  IFS=$as_save_IFS
25820  test -z "$as_dir" && as_dir=.
25821    for ac_exec_ext in '' $ac_executable_extensions; do
25822  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25823    ac_cv_path_NATIVE2ASCII="$as_dir/$ac_word$ac_exec_ext"
25824    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25825    break 2
25826  fi
25827done
25828  done
25829IFS=$as_save_IFS
25830
25831  ;;
25832esac
25833fi
25834NATIVE2ASCII=$ac_cv_path_NATIVE2ASCII
25835if test -n "$NATIVE2ASCII"; then
25836  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE2ASCII" >&5
25837$as_echo "$NATIVE2ASCII" >&6; }
25838else
25839  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25840$as_echo "no" >&6; }
25841fi
25842
25843
25844        if test "x$NATIVE2ASCII" = x; then
25845          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25846        fi
25847      else
25848        # Otherwise we believe it is a complete path. Use it as it is.
25849        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&5
25850$as_echo "$as_me: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&6;}
25851        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NATIVE2ASCII" >&5
25852$as_echo_n "checking for NATIVE2ASCII... " >&6; }
25853        if test ! -x "$tool_specified"; then
25854          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25855$as_echo "not found" >&6; }
25856          as_fn_error $? "User supplied tool NATIVE2ASCII=$tool_specified does not exist or is not executable" "$LINENO" 5
25857        fi
25858        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25859$as_echo "$tool_specified" >&6; }
25860      fi
25861    fi
25862  fi
25863
25864
25865
25866  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25867
25868  # Publish this variable in the help.
25869
25870
25871  if test "x$JARSIGNER" = x; then
25872    # The variable is not set by user, try to locate tool using the code snippet
25873
25874      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25875$as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25876      JARSIGNER=$BOOT_JDK/bin/jarsigner
25877      if test ! -x $JARSIGNER; then
25878        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25879$as_echo "not found" >&6; }
25880        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25881$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25882        as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25883      fi
25884      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25885$as_echo "ok" >&6; }
25886
25887
25888  else
25889    # The variable is set, but is it from the command line or the environment?
25890
25891    # Try to remove the string !JARSIGNER! from our list.
25892    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/}
25893    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25894      # If it failed, the variable was not from the command line. Ignore it,
25895      # but warn the user (except for BASH, which is always set by the calling BASH).
25896      if test "xJARSIGNER" != xBASH; then
25897        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5
25898$as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;}
25899      fi
25900      # Try to locate tool using the code snippet
25901
25902      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25903$as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25904      JARSIGNER=$BOOT_JDK/bin/jarsigner
25905      if test ! -x $JARSIGNER; then
25906        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25907$as_echo "not found" >&6; }
25908        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25909$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25910        as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25911      fi
25912      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25913$as_echo "ok" >&6; }
25914
25915
25916    else
25917      # If it succeeded, then it was overridden by the user. We will use it
25918      # for the tool.
25919
25920      # First remove it from the list of overridden variables, so we can test
25921      # for unknown variables in the end.
25922      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25923
25924      # Check if the provided tool contains a complete path.
25925      tool_specified="$JARSIGNER"
25926      tool_basename="${tool_specified##*/}"
25927      if test "x$tool_basename" = "x$tool_specified"; then
25928        # A command without a complete path is provided, search $PATH.
25929        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5
25930$as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;}
25931        # Extract the first word of "$tool_basename", so it can be a program name with args.
25932set dummy $tool_basename; ac_word=$2
25933{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25934$as_echo_n "checking for $ac_word... " >&6; }
25935if ${ac_cv_path_JARSIGNER+:} false; then :
25936  $as_echo_n "(cached) " >&6
25937else
25938  case $JARSIGNER in
25939  [\\/]* | ?:[\\/]*)
25940  ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path.
25941  ;;
25942  *)
25943  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25944for as_dir in $PATH
25945do
25946  IFS=$as_save_IFS
25947  test -z "$as_dir" && as_dir=.
25948    for ac_exec_ext in '' $ac_executable_extensions; do
25949  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25950    ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext"
25951    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25952    break 2
25953  fi
25954done
25955  done
25956IFS=$as_save_IFS
25957
25958  ;;
25959esac
25960fi
25961JARSIGNER=$ac_cv_path_JARSIGNER
25962if test -n "$JARSIGNER"; then
25963  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5
25964$as_echo "$JARSIGNER" >&6; }
25965else
25966  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25967$as_echo "no" >&6; }
25968fi
25969
25970
25971        if test "x$JARSIGNER" = x; then
25972          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25973        fi
25974      else
25975        # Otherwise we believe it is a complete path. Use it as it is.
25976        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5
25977$as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;}
25978        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5
25979$as_echo_n "checking for JARSIGNER... " >&6; }
25980        if test ! -x "$tool_specified"; then
25981          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25982$as_echo "not found" >&6; }
25983          as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5
25984        fi
25985        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25986$as_echo "$tool_specified" >&6; }
25987      fi
25988    fi
25989  fi
25990
25991
25992
25993  # Finally, set some other options...
25994
25995  # When compiling code to be executed by the Boot JDK, force jdk7 compatibility.
25996  BOOT_JDK_SOURCETARGET="-source 7 -target 7"
25997
25998
25999
26000
26001  ##############################################################################
26002  #
26003  # Specify jvm options for anything that is run with the Boot JDK.
26004  # Not all JVM:s accept the same arguments on the command line.
26005  #
26006
26007# Check whether --with-boot-jdk-jvmargs was given.
26008if test "${with_boot_jdk_jvmargs+set}" = set; then :
26009  withval=$with_boot_jdk_jvmargs;
26010fi
26011
26012
26013  { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5
26014$as_echo_n "checking flags for boot jdk java command ... " >&6; }
26015
26016  # Disable special log output when a debug build is used as Boot JDK...
26017
26018  $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5
26019  $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5
26020  OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1`
26021  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26022  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26023  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26024    boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput"
26025    JVM_ARG_OK=true
26026  else
26027    $ECHO "Arg failed:" >&5
26028    $ECHO "$OUTPUT" >&5
26029    JVM_ARG_OK=false
26030  fi
26031
26032
26033  # Apply user provided options.
26034
26035  $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5
26036  $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5
26037  OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1`
26038  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26039  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26040  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26041    boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs"
26042    JVM_ARG_OK=true
26043  else
26044    $ECHO "Arg failed:" >&5
26045    $ECHO "$OUTPUT" >&5
26046    JVM_ARG_OK=false
26047  fi
26048
26049
26050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5
26051$as_echo "$boot_jdk_jvmargs" >&6; }
26052
26053  # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs
26054  JAVA_FLAGS=$boot_jdk_jvmargs
26055
26056
26057
26058  { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5
26059$as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; }
26060
26061  # Starting amount of heap memory.
26062
26063  $ECHO "Check if jvm arg is ok: -Xms64M" >&5
26064  $ECHO "Command: $JAVA -Xms64M -version" >&5
26065  OUTPUT=`$JAVA -Xms64M -version 2>&1`
26066  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26067  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26068  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26069    boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M"
26070    JVM_ARG_OK=true
26071  else
26072    $ECHO "Arg failed:" >&5
26073    $ECHO "$OUTPUT" >&5
26074    JVM_ARG_OK=false
26075  fi
26076
26077
26078  # Maximum amount of heap memory.
26079  # Maximum stack size.
26080  if test "x$BUILD_NUM_BITS" = x32; then
26081    JVM_MAX_HEAP=1100M
26082    STACK_SIZE=768
26083  else
26084    # Running Javac on a JVM on a 64-bit machine, takes more space since 64-bit
26085    # pointers are used. Apparently, we need to increase the heap and stack
26086    # space for the jvm. More specifically, when running javac to build huge
26087    # jdk batch
26088    JVM_MAX_HEAP=1600M
26089    STACK_SIZE=1536
26090  fi
26091
26092  $ECHO "Check if jvm arg is ok: -Xmx$JVM_MAX_HEAP" >&5
26093  $ECHO "Command: $JAVA -Xmx$JVM_MAX_HEAP -version" >&5
26094  OUTPUT=`$JAVA -Xmx$JVM_MAX_HEAP -version 2>&1`
26095  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26096  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26097  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26098    boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx$JVM_MAX_HEAP"
26099    JVM_ARG_OK=true
26100  else
26101    $ECHO "Arg failed:" >&5
26102    $ECHO "$OUTPUT" >&5
26103    JVM_ARG_OK=false
26104  fi
26105
26106
26107  $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5
26108  $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5
26109  OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1`
26110  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26111  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26112  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26113    boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE"
26114    JVM_ARG_OK=true
26115  else
26116    $ECHO "Arg failed:" >&5
26117    $ECHO "$OUTPUT" >&5
26118    JVM_ARG_OK=false
26119  fi
26120
26121
26122  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5
26123$as_echo "$boot_jdk_jvmargs_big" >&6; }
26124
26125  JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big
26126
26127
26128
26129  { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5
26130$as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; }
26131
26132  # Use serial gc for small short lived tools if possible
26133
26134  $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5
26135  $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5
26136  OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1`
26137  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26138  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26139  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26140    boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC"
26141    JVM_ARG_OK=true
26142  else
26143    $ECHO "Arg failed:" >&5
26144    $ECHO "$OUTPUT" >&5
26145    JVM_ARG_OK=false
26146  fi
26147
26148
26149  $ECHO "Check if jvm arg is ok: -Xms32M" >&5
26150  $ECHO "Command: $JAVA -Xms32M -version" >&5
26151  OUTPUT=`$JAVA -Xms32M -version 2>&1`
26152  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26153  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26154  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26155    boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M"
26156    JVM_ARG_OK=true
26157  else
26158    $ECHO "Arg failed:" >&5
26159    $ECHO "$OUTPUT" >&5
26160    JVM_ARG_OK=false
26161  fi
26162
26163
26164  $ECHO "Check if jvm arg is ok: -Xmx512M" >&5
26165  $ECHO "Command: $JAVA -Xmx512M -version" >&5
26166  OUTPUT=`$JAVA -Xmx512M -version 2>&1`
26167  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
26168  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
26169  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
26170    boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M"
26171    JVM_ARG_OK=true
26172  else
26173    $ECHO "Arg failed:" >&5
26174    $ECHO "$OUTPUT" >&5
26175    JVM_ARG_OK=false
26176  fi
26177
26178
26179  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5
26180$as_echo "$boot_jdk_jvmargs_small" >&6; }
26181
26182  JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small
26183
26184
26185
26186###############################################################################
26187#
26188# Configure the sources to use. We can add or override individual directories.
26189#
26190###############################################################################
26191
26192
26193  # Where are the sources. Any of these can be overridden
26194  # using --with-override-corba and the likes.
26195  LANGTOOLS_TOPDIR="$SRC_ROOT/langtools"
26196  CORBA_TOPDIR="$SRC_ROOT/corba"
26197  JAXP_TOPDIR="$SRC_ROOT/jaxp"
26198  JAXWS_TOPDIR="$SRC_ROOT/jaxws"
26199  HOTSPOT_TOPDIR="$SRC_ROOT/hotspot"
26200  NASHORN_TOPDIR="$SRC_ROOT/nashorn"
26201  JDK_TOPDIR="$SRC_ROOT/jdk"
26202
26203
26204
26205
26206
26207
26208
26209
26210
26211
26212  ###############################################################################
26213  #
26214  # Pickup additional source for a component from outside of the source root
26215  # or override source for a component.
26216  #
26217
26218# Check whether --with-add-source-root was given.
26219if test "${with_add_source_root+set}" = set; then :
26220  withval=$with_add_source_root;
26221fi
26222
26223
26224
26225# Check whether --with-override-source-root was given.
26226if test "${with_override_source_root+set}" = set; then :
26227  withval=$with_override_source_root;
26228fi
26229
26230
26231
26232# Check whether --with-adds-and-overrides was given.
26233if test "${with_adds_and_overrides+set}" = set; then :
26234  withval=$with_adds_and_overrides;
26235fi
26236
26237
26238  if test "x$with_adds_and_overrides" != x; then
26239    with_add_source_root="$with_adds_and_overrides/adds"
26240    with_override_source_root="$with_adds_and_overrides/overrides"
26241  fi
26242
26243  if test "x$with_add_source_root" != x; then
26244    if ! test -d $with_add_source_root; then
26245      as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5
26246    fi
26247    CURDIR="$PWD"
26248    cd "$with_add_source_root"
26249    ADD_SRC_ROOT="`pwd`"
26250    cd "$CURDIR"
26251    # Verify that the addon source root does not have any root makefiles.
26252    # If it does, then it is usually an error, prevent this.
26253    if test -f $with_add_source_root/langtools/make/Makefile; then
26254      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
26255    fi
26256    if test -f $with_add_source_root/corba/make/Makefile; then
26257      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
26258    fi
26259    if test -f $with_add_source_root/jaxp/make/Makefile; then
26260      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
26261    fi
26262    if test -f $with_add_source_root/jaxws/make/Makefile; then
26263      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
26264    fi
26265    if test -f $with_add_source_root/hotspot/make/Makefile; then
26266      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
26267    fi
26268    if test -f $with_add_source_root/nashorn/make/Makefile; then
26269      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
26270    fi
26271    if test -f $with_add_source_root/jdk/make/Makefile; then
26272      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
26273    fi
26274  fi
26275
26276
26277  if test "x$with_override_source_root" != x; then
26278    if ! test -d $with_override_source_root; then
26279      as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5
26280    fi
26281    CURDIR="$PWD"
26282    cd "$with_override_source_root"
26283    OVERRIDE_SRC_ROOT="`pwd`"
26284    cd "$CURDIR"
26285    if test -f $with_override_source_root/langtools/make/Makefile; then
26286      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
26287    fi
26288    if test -f $with_override_source_root/corba/make/Makefile; then
26289      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
26290    fi
26291    if test -f $with_override_source_root/jaxp/make/Makefile; then
26292      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
26293    fi
26294    if test -f $with_override_source_root/jaxws/make/Makefile; then
26295      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
26296    fi
26297    if test -f $with_override_source_root/hotspot/make/Makefile; then
26298      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
26299    fi
26300    if test -f $with_override_source_root/nashorn/make/Makefile; then
26301      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
26302    fi
26303    if test -f $with_override_source_root/jdk/make/Makefile; then
26304      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
26305    fi
26306  fi
26307
26308
26309  ###############################################################################
26310  #
26311  # Override a repo completely, this is used for example when you have 3 small
26312  # development sandboxes of the langtools sources and want to avoid having 3 full
26313  # OpenJDK sources checked out on disk.
26314  #
26315  # Assuming that the 3 langtools sandboxes are located here:
26316  # /home/fredrik/sandbox1/langtools
26317  # /home/fredrik/sandbox2/langtools
26318  # /home/fredrik/sandbox3/langtools
26319  #
26320  # From the source root you create build subdirs manually:
26321  #     mkdir -p build1 build2 build3
26322  # in each build directory run:
26323  #     (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make)
26324  #     (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make)
26325  #     (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make)
26326  #
26327
26328
26329# Check whether --with-override-langtools was given.
26330if test "${with_override_langtools+set}" = set; then :
26331  withval=$with_override_langtools;
26332fi
26333
26334
26335
26336# Check whether --with-override-corba was given.
26337if test "${with_override_corba+set}" = set; then :
26338  withval=$with_override_corba;
26339fi
26340
26341
26342
26343# Check whether --with-override-jaxp was given.
26344if test "${with_override_jaxp+set}" = set; then :
26345  withval=$with_override_jaxp;
26346fi
26347
26348
26349
26350# Check whether --with-override-jaxws was given.
26351if test "${with_override_jaxws+set}" = set; then :
26352  withval=$with_override_jaxws;
26353fi
26354
26355
26356
26357# Check whether --with-override-hotspot was given.
26358if test "${with_override_hotspot+set}" = set; then :
26359  withval=$with_override_hotspot;
26360fi
26361
26362
26363
26364# Check whether --with-override-nashorn was given.
26365if test "${with_override_nashorn+set}" = set; then :
26366  withval=$with_override_nashorn;
26367fi
26368
26369
26370
26371# Check whether --with-override-jdk was given.
26372if test "${with_override_jdk+set}" = set; then :
26373  withval=$with_override_jdk;
26374fi
26375
26376
26377  if test "x$with_override_langtools" != x; then
26378    CURDIR="$PWD"
26379    cd "$with_override_langtools"
26380    LANGTOOLS_TOPDIR="`pwd`"
26381    cd "$CURDIR"
26382    if ! test -f $LANGTOOLS_TOPDIR/make/Makefile; then
26383      as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5
26384    fi
26385    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5
26386$as_echo_n "checking if langtools should be overridden... " >&6; }
26387    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5
26388$as_echo "yes with $LANGTOOLS_TOPDIR" >&6; }
26389  fi
26390  if test "x$with_override_corba" != x; then
26391    CURDIR="$PWD"
26392    cd "$with_override_corba"
26393    CORBA_TOPDIR="`pwd`"
26394    cd "$CURDIR"
26395    if ! test -f $CORBA_TOPDIR/make/Makefile; then
26396      as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5
26397    fi
26398    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5
26399$as_echo_n "checking if corba should be overridden... " >&6; }
26400    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5
26401$as_echo "yes with $CORBA_TOPDIR" >&6; }
26402  fi
26403  if test "x$with_override_jaxp" != x; then
26404    CURDIR="$PWD"
26405    cd "$with_override_jaxp"
26406    JAXP_TOPDIR="`pwd`"
26407    cd "$CURDIR"
26408    if ! test -f $JAXP_TOPDIR/make/Makefile; then
26409      as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5
26410    fi
26411    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5
26412$as_echo_n "checking if jaxp should be overridden... " >&6; }
26413    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5
26414$as_echo "yes with $JAXP_TOPDIR" >&6; }
26415  fi
26416  if test "x$with_override_jaxws" != x; then
26417    CURDIR="$PWD"
26418    cd "$with_override_jaxws"
26419    JAXWS_TOPDIR="`pwd`"
26420    cd "$CURDIR"
26421    if ! test -f $JAXWS_TOPDIR/make/Makefile; then
26422      as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5
26423    fi
26424    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5
26425$as_echo_n "checking if jaxws should be overridden... " >&6; }
26426    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5
26427$as_echo "yes with $JAXWS_TOPDIR" >&6; }
26428  fi
26429  if test "x$with_override_hotspot" != x; then
26430    CURDIR="$PWD"
26431    cd "$with_override_hotspot"
26432    HOTSPOT_TOPDIR="`pwd`"
26433    cd "$CURDIR"
26434    if ! test -f $HOTSPOT_TOPDIR/make/Makefile; then
26435      as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5
26436    fi
26437    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5
26438$as_echo_n "checking if hotspot should be overridden... " >&6; }
26439    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5
26440$as_echo "yes with $HOTSPOT_TOPDIR" >&6; }
26441  fi
26442  if test "x$with_override_nashorn" != x; then
26443    CURDIR="$PWD"
26444    cd "$with_override_nashorn"
26445    NASHORN_TOPDIR="`pwd`"
26446    cd "$CURDIR"
26447    if ! test -f $NASHORN_TOPDIR/make/Makefile; then
26448      as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
26449    fi
26450    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
26451$as_echo_n "checking if nashorn should be overridden... " >&6; }
26452    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5
26453$as_echo "yes with $NASHORN_TOPDIR" >&6; }
26454  fi
26455  if test "x$with_override_jdk" != x; then
26456    CURDIR="$PWD"
26457    cd "$with_override_jdk"
26458    JDK_TOPDIR="`pwd`"
26459    cd "$CURDIR"
26460    if ! test -f $JDK_TOPDIR/make/Makefile; then
26461      as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5
26462    fi
26463    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5
26464$as_echo_n "checking if JDK should be overridden... " >&6; }
26465    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5
26466$as_echo "yes with $JDK_TOPDIR" >&6; }
26467  fi
26468
26469
26470  BUILD_OUTPUT="$OUTPUT_ROOT"
26471
26472
26473  HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist"
26474  BUILD_HOTSPOT=true
26475
26476
26477
26478# Check whether --with-import-hotspot was given.
26479if test "${with_import_hotspot+set}" = set; then :
26480  withval=$with_import_hotspot;
26481fi
26482
26483  if test "x$with_import_hotspot" != x; then
26484    CURDIR="$PWD"
26485    cd "$with_import_hotspot"
26486    HOTSPOT_DIST="`pwd`"
26487    cd "$CURDIR"
26488    if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then
26489      as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5
26490    fi
26491    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5
26492$as_echo_n "checking if hotspot should be imported... " >&6; }
26493    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5
26494$as_echo "yes from $HOTSPOT_DIST" >&6; }
26495    BUILD_HOTSPOT=false
26496  fi
26497
26498  JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk"
26499
26500
26501###############################################################################
26502#
26503# Setup the toolchain (compilers etc), i.e. tools used to compile and process
26504# native code.
26505#
26506###############################################################################
26507
26508# First determine the toolchain type (compiler family)
26509
26510
26511# Check whether --with-toolchain-type was given.
26512if test "${with_toolchain_type+set}" = set; then :
26513  withval=$with_toolchain_type;
26514fi
26515
26516
26517  # Use indirect variable referencing
26518  toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS
26519  VALID_TOOLCHAINS=${!toolchain_var_name}
26520
26521  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26522    # On Mac OS X, default toolchain to clang after Xcode 5
26523    XCODE_VERSION_OUTPUT=`xcodebuild -version 2>&1 | $HEAD -n 1`
26524    $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null
26525    if test $? -ne 0; then
26526      as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5
26527    fi
26528    XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \
26529        $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \
26530        $CUT -f 1 -d .`
26531    { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5
26532$as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;}
26533    if test $XCODE_MAJOR_VERSION -ge 5; then
26534        DEFAULT_TOOLCHAIN="clang"
26535    else
26536        DEFAULT_TOOLCHAIN="gcc"
26537    fi
26538  else
26539    # First toolchain type in the list is the default
26540    DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *}
26541  fi
26542
26543  if test "x$with_toolchain_type" = xlist; then
26544    # List all toolchains
26545    { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5
26546$as_echo "$as_me: The following toolchains are valid on this platform:" >&6;}
26547    for toolchain in $VALID_TOOLCHAINS; do
26548      toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
26549      TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26550      $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
26551    done
26552
26553    exit 0
26554  elif test "x$with_toolchain_type" != x; then
26555    # User override; check that it is valid
26556    if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then
26557      { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5
26558$as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;}
26559      { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5
26560$as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;}
26561      as_fn_error $? "Cannot continue." "$LINENO" 5
26562    fi
26563    TOOLCHAIN_TYPE=$with_toolchain_type
26564  else
26565    # No flag given, use default
26566    TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN
26567  fi
26568
26569
26570  TOOLCHAIN_CC_BINARY_clang="clang"
26571  TOOLCHAIN_CC_BINARY_gcc="gcc"
26572  TOOLCHAIN_CC_BINARY_microsoft="cl"
26573  TOOLCHAIN_CC_BINARY_solstudio="cc"
26574  TOOLCHAIN_CC_BINARY_xlc="xlc_r"
26575
26576  TOOLCHAIN_CXX_BINARY_clang="clang++"
26577  TOOLCHAIN_CXX_BINARY_gcc="g++"
26578  TOOLCHAIN_CXX_BINARY_microsoft="cl"
26579  TOOLCHAIN_CXX_BINARY_solstudio="CC"
26580  TOOLCHAIN_CXX_BINARY_xlc="xlC_r"
26581
26582  # Use indirect variable referencing
26583  toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE
26584  TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26585  toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE
26586  TOOLCHAIN_CC_BINARY=${!toolchain_var_name}
26587  toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE
26588  TOOLCHAIN_CXX_BINARY=${!toolchain_var_name}
26589
26590
26591  # Define filename patterns
26592  if test "x$OPENJDK_TARGET_OS" = xwindows; then
26593    LIBRARY_PREFIX=
26594    SHARED_LIBRARY_SUFFIX='.dll'
26595    STATIC_LIBRARY_SUFFIX='.lib'
26596    SHARED_LIBRARY='$1.dll'
26597    STATIC_LIBRARY='$1.lib'
26598    OBJ_SUFFIX='.obj'
26599    EXE_SUFFIX='.exe'
26600  else
26601    LIBRARY_PREFIX=lib
26602    SHARED_LIBRARY_SUFFIX='.so'
26603    STATIC_LIBRARY_SUFFIX='.a'
26604    SHARED_LIBRARY='lib$1.so'
26605    STATIC_LIBRARY='lib$1.a'
26606    OBJ_SUFFIX='.o'
26607    EXE_SUFFIX=''
26608    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26609      SHARED_LIBRARY='lib$1.dylib'
26610      SHARED_LIBRARY_SUFFIX='.dylib'
26611    fi
26612  fi
26613
26614
26615
26616
26617
26618
26619
26620
26621
26622
26623  if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then
26624    { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5
26625$as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;}
26626  else
26627    { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5
26628$as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;}
26629  fi
26630
26631
26632# Then detect the actual binaries needed
26633
26634  # FIXME: Is this needed?
26635  ac_ext=cpp
26636ac_cpp='$CXXCPP $CPPFLAGS'
26637ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26638ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26639ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26640
26641
26642  # Store the CFLAGS etc passed to the configure script.
26643  ORG_CFLAGS="$CFLAGS"
26644  ORG_CXXFLAGS="$CXXFLAGS"
26645  ORG_OBJCFLAGS="$OBJCFLAGS"
26646
26647  # On Windows, we need to detect the visual studio installation first.
26648  # This will change the PATH, but we need to keep that new PATH even
26649  # after toolchain detection is done, since the compiler (on x86) uses
26650  # it for DLL resolution in runtime.
26651  if test "x$OPENJDK_BUILD_OS" = "xwindows" && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then
26652
26653  # Store path to cygwin link.exe to help excluding it when searching for
26654  # VS linker. This must be done before changing the PATH when looking for VS.
26655  # Extract the first word of "link", so it can be a program name with args.
26656set dummy link; ac_word=$2
26657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26658$as_echo_n "checking for $ac_word... " >&6; }
26659if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26660  $as_echo_n "(cached) " >&6
26661else
26662  case $CYGWIN_LINK in
26663  [\\/]* | ?:[\\/]*)
26664  ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26665  ;;
26666  *)
26667  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26668for as_dir in $PATH
26669do
26670  IFS=$as_save_IFS
26671  test -z "$as_dir" && as_dir=.
26672    for ac_exec_ext in '' $ac_executable_extensions; do
26673  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26674    ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26675    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26676    break 2
26677  fi
26678done
26679  done
26680IFS=$as_save_IFS
26681
26682  ;;
26683esac
26684fi
26685CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26686if test -n "$CYGWIN_LINK"; then
26687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26688$as_echo "$CYGWIN_LINK" >&6; }
26689else
26690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26691$as_echo "no" >&6; }
26692fi
26693
26694
26695  if test "x$CYGWIN_LINK" != x; then
26696    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26697$as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26698    "$CYGWIN_LINK" --version > /dev/null
26699    if test $? -eq 0 ; then
26700      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26701$as_echo "yes" >&6; }
26702    else
26703      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26704$as_echo "no" >&6; }
26705      # This might be the VS linker. Don't exclude it later on.
26706      CYGWIN_LINK=""
26707    fi
26708  fi
26709
26710  # First-hand choice is to locate and run the vsvars bat file.
26711
26712  if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26713    VCVARSFILE="vc/bin/vcvars32.bat"
26714  else
26715    VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26716  fi
26717
26718  VS_ENV_CMD=""
26719  VS_ENV_ARGS=""
26720  if test "x$with_toolsdir" != x; then
26721
26722  if test "x$VS_ENV_CMD" = x; then
26723    VS100BASE="$with_toolsdir/../.."
26724    METHOD="--with-tools-dir"
26725
26726  windows_path="$VS100BASE"
26727  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26728    unix_path=`$CYGPATH -u "$windows_path"`
26729    VS100BASE="$unix_path"
26730  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26731    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26732    VS100BASE="$unix_path"
26733  fi
26734
26735    if test -d "$VS100BASE"; then
26736      if test -f "$VS100BASE/$VCVARSFILE"; then
26737        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26738$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26739        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26740      else
26741        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26742$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26743        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26744$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26745      fi
26746    fi
26747  fi
26748
26749  fi
26750
26751  if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26752    # Having specified an argument which is incorrect will produce an instant failure;
26753    # we should not go on looking
26754    { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26755$as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26756    { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26757$as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26758    as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26759  fi
26760
26761  if test "x$VS100COMNTOOLS" != x; then
26762
26763  if test "x$VS_ENV_CMD" = x; then
26764    VS100BASE="$VS100COMNTOOLS/../.."
26765    METHOD="VS100COMNTOOLS variable"
26766
26767  windows_path="$VS100BASE"
26768  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26769    unix_path=`$CYGPATH -u "$windows_path"`
26770    VS100BASE="$unix_path"
26771  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26772    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26773    VS100BASE="$unix_path"
26774  fi
26775
26776    if test -d "$VS100BASE"; then
26777      if test -f "$VS100BASE/$VCVARSFILE"; then
26778        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26779$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26780        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26781      else
26782        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26783$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26784        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26785$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26786      fi
26787    fi
26788  fi
26789
26790  fi
26791  if test "x$PROGRAMFILES" != x; then
26792
26793  if test "x$VS_ENV_CMD" = x; then
26794    VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26795    METHOD="well-known name"
26796
26797  windows_path="$VS100BASE"
26798  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26799    unix_path=`$CYGPATH -u "$windows_path"`
26800    VS100BASE="$unix_path"
26801  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26802    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26803    VS100BASE="$unix_path"
26804  fi
26805
26806    if test -d "$VS100BASE"; then
26807      if test -f "$VS100BASE/$VCVARSFILE"; then
26808        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26809$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26810        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26811      else
26812        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26813$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26814        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26815$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26816      fi
26817    fi
26818  fi
26819
26820  fi
26821
26822  if test "x$VS_ENV_CMD" = x; then
26823    VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26824    METHOD="well-known name"
26825
26826  windows_path="$VS100BASE"
26827  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26828    unix_path=`$CYGPATH -u "$windows_path"`
26829    VS100BASE="$unix_path"
26830  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26831    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26832    VS100BASE="$unix_path"
26833  fi
26834
26835    if test -d "$VS100BASE"; then
26836      if test -f "$VS100BASE/$VCVARSFILE"; then
26837        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26838$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26839        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26840      else
26841        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26842$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26843        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26844$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26845      fi
26846    fi
26847  fi
26848
26849
26850  if test "x$VS_ENV_CMD" = x; then
26851    VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
26852    METHOD="well-known name"
26853
26854  windows_path="$VS100BASE"
26855  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26856    unix_path=`$CYGPATH -u "$windows_path"`
26857    VS100BASE="$unix_path"
26858  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26859    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26860    VS100BASE="$unix_path"
26861  fi
26862
26863    if test -d "$VS100BASE"; then
26864      if test -f "$VS100BASE/$VCVARSFILE"; then
26865        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26866$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26867        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26868      else
26869        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26870$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26871        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26872$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26873      fi
26874    fi
26875  fi
26876
26877
26878  if test "x$ProgramW6432" != x; then
26879
26880  if test "x$VS_ENV_CMD" = x; then
26881    WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
26882    METHOD="well-known name"
26883
26884  windows_path="$WIN_SDK_BASE"
26885  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26886    unix_path=`$CYGPATH -u "$windows_path"`
26887    WIN_SDK_BASE="$unix_path"
26888  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26889    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26890    WIN_SDK_BASE="$unix_path"
26891  fi
26892
26893    if test -d "$WIN_SDK_BASE"; then
26894      # There have been cases of partial or broken SDK installations. A missing
26895      # lib dir is not going to work.
26896      if test ! -d "$WIN_SDK_BASE/../lib"; then
26897        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26898$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26899        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26900$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26901      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26902        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26903$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26904        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26905        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26906          VS_ENV_ARGS="/x86"
26907        else
26908          VS_ENV_ARGS="/x64"
26909        fi
26910      else
26911        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26912$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26913        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26914$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26915      fi
26916    fi
26917  fi
26918
26919  fi
26920  if test "x$PROGRAMW6432" != x; then
26921
26922  if test "x$VS_ENV_CMD" = x; then
26923    WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
26924    METHOD="well-known name"
26925
26926  windows_path="$WIN_SDK_BASE"
26927  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26928    unix_path=`$CYGPATH -u "$windows_path"`
26929    WIN_SDK_BASE="$unix_path"
26930  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26931    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26932    WIN_SDK_BASE="$unix_path"
26933  fi
26934
26935    if test -d "$WIN_SDK_BASE"; then
26936      # There have been cases of partial or broken SDK installations. A missing
26937      # lib dir is not going to work.
26938      if test ! -d "$WIN_SDK_BASE/../lib"; then
26939        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26940$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26941        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26942$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26943      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26944        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26945$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26946        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26947        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26948          VS_ENV_ARGS="/x86"
26949        else
26950          VS_ENV_ARGS="/x64"
26951        fi
26952      else
26953        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26954$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26955        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26956$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26957      fi
26958    fi
26959  fi
26960
26961  fi
26962  if test "x$PROGRAMFILES" != x; then
26963
26964  if test "x$VS_ENV_CMD" = x; then
26965    WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
26966    METHOD="well-known name"
26967
26968  windows_path="$WIN_SDK_BASE"
26969  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26970    unix_path=`$CYGPATH -u "$windows_path"`
26971    WIN_SDK_BASE="$unix_path"
26972  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26973    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26974    WIN_SDK_BASE="$unix_path"
26975  fi
26976
26977    if test -d "$WIN_SDK_BASE"; then
26978      # There have been cases of partial or broken SDK installations. A missing
26979      # lib dir is not going to work.
26980      if test ! -d "$WIN_SDK_BASE/../lib"; then
26981        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26982$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26983        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26984$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26985      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26986        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26987$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26988        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26989        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26990          VS_ENV_ARGS="/x86"
26991        else
26992          VS_ENV_ARGS="/x64"
26993        fi
26994      else
26995        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26996$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26997        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26998$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26999      fi
27000    fi
27001  fi
27002
27003  fi
27004
27005  if test "x$VS_ENV_CMD" = x; then
27006    WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
27007    METHOD="well-known name"
27008
27009  windows_path="$WIN_SDK_BASE"
27010  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27011    unix_path=`$CYGPATH -u "$windows_path"`
27012    WIN_SDK_BASE="$unix_path"
27013  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27014    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27015    WIN_SDK_BASE="$unix_path"
27016  fi
27017
27018    if test -d "$WIN_SDK_BASE"; then
27019      # There have been cases of partial or broken SDK installations. A missing
27020      # lib dir is not going to work.
27021      if test ! -d "$WIN_SDK_BASE/../lib"; then
27022        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27023$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27024        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27025$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27026      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27027        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27028$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27029        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27030        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27031          VS_ENV_ARGS="/x86"
27032        else
27033          VS_ENV_ARGS="/x64"
27034        fi
27035      else
27036        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27037$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27038        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27039$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27040      fi
27041    fi
27042  fi
27043
27044
27045  if test "x$VS_ENV_CMD" = x; then
27046    WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
27047    METHOD="well-known name"
27048
27049  windows_path="$WIN_SDK_BASE"
27050  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27051    unix_path=`$CYGPATH -u "$windows_path"`
27052    WIN_SDK_BASE="$unix_path"
27053  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27054    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27055    WIN_SDK_BASE="$unix_path"
27056  fi
27057
27058    if test -d "$WIN_SDK_BASE"; then
27059      # There have been cases of partial or broken SDK installations. A missing
27060      # lib dir is not going to work.
27061      if test ! -d "$WIN_SDK_BASE/../lib"; then
27062        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27063$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27064        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27065$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27066      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27067        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27068$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27069        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27070        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27071          VS_ENV_ARGS="/x86"
27072        else
27073          VS_ENV_ARGS="/x64"
27074        fi
27075      else
27076        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27077$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27078        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27079$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27080      fi
27081    fi
27082  fi
27083
27084
27085  if test "x$VS_ENV_CMD" != x; then
27086    # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
27087
27088  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27089
27090  # First separate the path from the arguments. This will split at the first
27091  # space.
27092  complete="$VS_ENV_CMD"
27093  path="${complete%% *}"
27094  tmp="$complete EOL"
27095  arguments="${tmp#* }"
27096
27097  # Input might be given as Windows format, start by converting to
27098  # unix format.
27099  new_path=`$CYGPATH -u "$path"`
27100
27101  # Now try to locate executable using which
27102  new_path=`$WHICH "$new_path" 2> /dev/null`
27103  # bat and cmd files are not always considered executable in cygwin causing which
27104  # to not find them
27105  if test "x$new_path" = x \
27106      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27107      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27108    new_path=`$CYGPATH -u "$path"`
27109  fi
27110  if test "x$new_path" = x; then
27111    # Oops. Which didn't find the executable.
27112    # The splitting of arguments from the executable at a space might have been incorrect,
27113    # since paths with space are more likely in Windows. Give it another try with the whole
27114    # argument.
27115    path="$complete"
27116    arguments="EOL"
27117    new_path=`$CYGPATH -u "$path"`
27118    new_path=`$WHICH "$new_path" 2> /dev/null`
27119    # bat and cmd files are not always considered executable in cygwin causing which
27120    # to not find them
27121    if test "x$new_path" = x \
27122        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27123        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27124      new_path=`$CYGPATH -u "$path"`
27125    fi
27126    if test "x$new_path" = x; then
27127      # It's still not found. Now this is an unrecoverable error.
27128      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27129$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27130      has_space=`$ECHO "$complete" | $GREP " "`
27131      if test "x$has_space" != x; then
27132        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27133$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27134      fi
27135      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27136    fi
27137  fi
27138
27139  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27140  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27141  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27142  # "foo.exe" is OK but "foo" is an error.
27143  #
27144  # This test is therefore slightly more accurate than "test -f" to check for file presence.
27145  # It is also a way to make sure we got the proper file name for the real test later on.
27146  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27147  if test "x$test_shortpath" = x; then
27148    # Short path failed, file does not exist as specified.
27149    # Try adding .exe or .cmd
27150    if test -f "${new_path}.exe"; then
27151      input_to_shortpath="${new_path}.exe"
27152    elif test -f "${new_path}.cmd"; then
27153      input_to_shortpath="${new_path}.cmd"
27154    else
27155      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
27156$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
27157      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27158$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27159      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27160    fi
27161  else
27162    input_to_shortpath="$new_path"
27163  fi
27164
27165  # Call helper function which possibly converts this using DOS-style short mode.
27166  # If so, the updated path is stored in $new_path.
27167  new_path="$input_to_shortpath"
27168
27169  input_path="$input_to_shortpath"
27170  # Check if we need to convert this using DOS-style short mode. If the path
27171  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27172  # take no chances and rewrite it.
27173  # Note: m4 eats our [], so we need to use [ and ] instead.
27174  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27175  if test "x$has_forbidden_chars" != x; then
27176    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27177    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27178    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27179    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27180      # Going to short mode and back again did indeed matter. Since short mode is
27181      # case insensitive, let's make it lowercase to improve readability.
27182      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27183      # Now convert it back to Unix-stile (cygpath)
27184      input_path=`$CYGPATH -u "$shortmode_path"`
27185      new_path="$input_path"
27186    fi
27187  fi
27188
27189  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27190  if test "x$test_cygdrive_prefix" = x; then
27191    # As a simple fix, exclude /usr/bin since it's not a real path.
27192    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27193      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27194      # a path prefixed by /cygdrive for fixpath to work.
27195      new_path="$CYGWIN_ROOT_PATH$input_path"
27196    fi
27197  fi
27198
27199  # remove trailing .exe if any
27200  new_path="${new_path/%.exe/}"
27201
27202  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27203
27204  # First separate the path from the arguments. This will split at the first
27205  # space.
27206  complete="$VS_ENV_CMD"
27207  path="${complete%% *}"
27208  tmp="$complete EOL"
27209  arguments="${tmp#* }"
27210
27211  # Input might be given as Windows format, start by converting to
27212  # unix format.
27213  new_path="$path"
27214
27215  windows_path="$new_path"
27216  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27217    unix_path=`$CYGPATH -u "$windows_path"`
27218    new_path="$unix_path"
27219  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27220    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27221    new_path="$unix_path"
27222  fi
27223
27224
27225  # Now try to locate executable using which
27226  new_path=`$WHICH "$new_path" 2> /dev/null`
27227
27228  if test "x$new_path" = x; then
27229    # Oops. Which didn't find the executable.
27230    # The splitting of arguments from the executable at a space might have been incorrect,
27231    # since paths with space are more likely in Windows. Give it another try with the whole
27232    # argument.
27233    path="$complete"
27234    arguments="EOL"
27235    new_path="$path"
27236
27237  windows_path="$new_path"
27238  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27239    unix_path=`$CYGPATH -u "$windows_path"`
27240    new_path="$unix_path"
27241  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27242    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27243    new_path="$unix_path"
27244  fi
27245
27246
27247    new_path=`$WHICH "$new_path" 2> /dev/null`
27248
27249    if test "x$new_path" = x; then
27250      # It's still not found. Now this is an unrecoverable error.
27251      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27252$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27253      has_space=`$ECHO "$complete" | $GREP " "`
27254      if test "x$has_space" != x; then
27255        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27256$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27257      fi
27258      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27259    fi
27260  fi
27261
27262  # Now new_path has a complete unix path to the binary
27263  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27264    # Keep paths in /bin as-is, but remove trailing .exe if any
27265    new_path="${new_path/%.exe/}"
27266    # Do not save /bin paths to all_fixpath_prefixes!
27267  else
27268    # Not in mixed or Windows style, start by that.
27269    new_path=`cmd //c echo $new_path`
27270
27271  input_path="$new_path"
27272  # Check if we need to convert this using DOS-style short mode. If the path
27273  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27274  # take no chances and rewrite it.
27275  # Note: m4 eats our [], so we need to use [ and ] instead.
27276  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27277  if test "x$has_forbidden_chars" != x; then
27278    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27279    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27280  fi
27281
27282    # Output is in $new_path
27283
27284  windows_path="$new_path"
27285  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27286    unix_path=`$CYGPATH -u "$windows_path"`
27287    new_path="$unix_path"
27288  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27289    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27290    new_path="$unix_path"
27291  fi
27292
27293    # remove trailing .exe if any
27294    new_path="${new_path/%.exe/}"
27295
27296    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27297    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27298  fi
27299
27300  else
27301    # We're on a posix platform. Hooray! :)
27302    # First separate the path from the arguments. This will split at the first
27303    # space.
27304    complete="$VS_ENV_CMD"
27305    path="${complete%% *}"
27306    tmp="$complete EOL"
27307    arguments="${tmp#* }"
27308
27309    # Cannot rely on the command "which" here since it doesn't always work.
27310    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27311    if test -z "$is_absolute_path"; then
27312      # Path to executable is not absolute. Find it.
27313      IFS_save="$IFS"
27314      IFS=:
27315      for p in $PATH; do
27316        if test -f "$p/$path" && test -x "$p/$path"; then
27317          new_path="$p/$path"
27318          break
27319        fi
27320      done
27321      IFS="$IFS_save"
27322    else
27323      # This is an absolute path, we can use it without further modifications.
27324      new_path="$path"
27325    fi
27326
27327    if test "x$new_path" = x; then
27328      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27329$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27330      has_space=`$ECHO "$complete" | $GREP " "`
27331      if test "x$has_space" != x; then
27332        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27333$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27334      fi
27335      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27336    fi
27337  fi
27338
27339  # Now join together the path and the arguments once again
27340  if test "x$arguments" != xEOL; then
27341    new_complete="$new_path ${arguments% *}"
27342  else
27343    new_complete="$new_path"
27344  fi
27345
27346  if test "x$complete" != "x$new_complete"; then
27347    VS_ENV_CMD="$new_complete"
27348    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27349$as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27350  fi
27351
27352
27353    # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27354    { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27355$as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27356
27357    # We need to create a couple of temporary files.
27358    VS_ENV_TMP_DIR="$OUTPUT_ROOT/vs-env"
27359    $MKDIR -p $VS_ENV_TMP_DIR
27360
27361    # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment).
27362    # Instead create a shell script which will set the relevant variables when run.
27363    WINPATH_VS_ENV_CMD="$VS_ENV_CMD"
27364
27365  unix_path="$WINPATH_VS_ENV_CMD"
27366  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27367    windows_path=`$CYGPATH -m "$unix_path"`
27368    WINPATH_VS_ENV_CMD="$windows_path"
27369  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27370    windows_path=`cmd //c echo $unix_path`
27371    WINPATH_VS_ENV_CMD="$windows_path"
27372  fi
27373
27374    WINPATH_BASH="$BASH"
27375
27376  unix_path="$WINPATH_BASH"
27377  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27378    windows_path=`$CYGPATH -m "$unix_path"`
27379    WINPATH_BASH="$windows_path"
27380  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27381    windows_path=`cmd //c echo $unix_path`
27382    WINPATH_BASH="$windows_path"
27383  fi
27384
27385
27386    # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell
27387    # script (executable by bash) that will setup the important variables.
27388    EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat"
27389    $ECHO "@echo off" >  $EXTRACT_VC_ENV_BAT_FILE
27390    # This will end up something like:
27391    # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat
27392    $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE
27393    # These will end up something like:
27394    # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh
27395    # The trailing space for everyone except PATH is no typo, but is needed due
27396    # to trailing \ in the Windows paths. These will be stripped later.
27397    $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27398    $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27399    $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27400    $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27401    $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27402    $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27403
27404    # Now execute the newly created bat file.
27405    # The | cat is to stop SetEnv.Cmd to mess with system colors on msys.
27406    # Change directory so we don't need to mess with Windows paths in redirects.
27407    cd $VS_ENV_TMP_DIR
27408    cmd /c extract-vs-env.bat | $CAT
27409    cd $CURDIR
27410
27411    if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then
27412      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27413$as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27414      { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27415$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27416      { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27417$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27418      as_fn_error $? "Cannot continue" "$LINENO" 5
27419    fi
27420
27421    # Now set all paths and other env variables. This will allow the rest of
27422    # the configure script to find and run the compiler in the proper way.
27423    { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27424$as_echo "$as_me: Setting extracted environment variables" >&6;}
27425    . $VS_ENV_TMP_DIR/set-vs-env.sh
27426    # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we
27427    # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR.
27428  else
27429    # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27430    { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27431$as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27432  fi
27433
27434  # At this point, we should have correct variables in the environment, or we can't continue.
27435  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27436$as_echo_n "checking for Visual Studio variables... " >&6; }
27437
27438  if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27439    if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then
27440      { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27441$as_echo "present but broken" >&6; }
27442      as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27443    else
27444      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27445$as_echo "ok" >&6; }
27446      # Remove any trailing "\" and " " from the variables.
27447      VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED 's/\\\\* *$//'`
27448      VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\* *$//'`
27449      VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'`
27450      WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'`
27451      WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'`
27452
27453
27454
27455
27456    fi
27457  else
27458    { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27459$as_echo "not found" >&6; }
27460
27461    if test "x$VS_ENV_CMD" = x; then
27462      { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27463$as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27464      { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27465$as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27466    else
27467      { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27468$as_echo "$as_me: Running the extraction script failed." >&6;}
27469    fi
27470    { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27471$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27472    { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27473$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27474    as_fn_error $? "Cannot continue" "$LINENO" 5
27475  fi
27476
27477    # Reset path to VS_PATH. It will include everything that was on PATH at the time we
27478    # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV.
27479    PATH="$VS_PATH"
27480    # The microsoft toolchain also requires INCLUDE and LIB to be set.
27481    export INCLUDE="$VS_INCLUDE"
27482    export LIB="$VS_LIB"
27483  fi
27484
27485  # autoconf magic only relies on PATH, so update it if tools dir is specified
27486  OLD_PATH="$PATH"
27487
27488  # For solaris we really need solaris tools, and not the GNU equivalent.
27489  # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27490  # so add that to path before starting to probe.
27491  # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27492  if test "x$OPENJDK_BUILD_OS" = xsolaris; then
27493    PATH="/usr/ccs/bin:$PATH"
27494  fi
27495
27496  # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to
27497  # override all other locations.
27498  if test "x$TOOLCHAIN_PATH" != x; then
27499    PATH=$TOOLCHAIN_PATH:$PATH
27500  fi
27501
27502
27503  #
27504  # Setup the compilers (CC and CXX)
27505  #
27506
27507  COMPILER_NAME=C
27508  SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27509
27510  if test "x$CC" != x; then
27511    # User has supplied compiler name already, always let that override.
27512    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27513$as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27514    if test "x`basename $CC`" = "x$CC"; then
27515      # A command without a complete path is provided, search $PATH.
27516
27517      for ac_prog in $CC
27518do
27519  # Extract the first word of "$ac_prog", so it can be a program name with args.
27520set dummy $ac_prog; ac_word=$2
27521{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27522$as_echo_n "checking for $ac_word... " >&6; }
27523if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27524  $as_echo_n "(cached) " >&6
27525else
27526  case $POTENTIAL_CC in
27527  [\\/]* | ?:[\\/]*)
27528  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27529  ;;
27530  *)
27531  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27532for as_dir in $PATH
27533do
27534  IFS=$as_save_IFS
27535  test -z "$as_dir" && as_dir=.
27536    for ac_exec_ext in '' $ac_executable_extensions; do
27537  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27538    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27539    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27540    break 2
27541  fi
27542done
27543  done
27544IFS=$as_save_IFS
27545
27546  ;;
27547esac
27548fi
27549POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27550if test -n "$POTENTIAL_CC"; then
27551  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27552$as_echo "$POTENTIAL_CC" >&6; }
27553else
27554  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27555$as_echo "no" >&6; }
27556fi
27557
27558
27559  test -n "$POTENTIAL_CC" && break
27560done
27561
27562      if test "x$POTENTIAL_CC" != x; then
27563        CC=$POTENTIAL_CC
27564      else
27565        as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27566      fi
27567    else
27568      # Otherwise it might already be a complete path
27569      if test ! -x "$CC"; then
27570        as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27571      fi
27572    fi
27573  else
27574    # No user supplied value. Locate compiler ourselves.
27575
27576    # If we are cross compiling, assume cross compilation tools follows the
27577    # cross compilation standard where they are prefixed with the autoconf
27578    # standard name for the target. For example the binary
27579    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27580    # If we are not cross compiling, then the default compiler name will be
27581    # used.
27582
27583    CC=
27584    # If TOOLCHAIN_PATH is set, check for all compiler names in there first
27585    # before checking the rest of the PATH.
27586    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27587    # step, this should not be necessary.
27588    if test -n "$TOOLCHAIN_PATH"; then
27589      PATH_save="$PATH"
27590      PATH="$TOOLCHAIN_PATH"
27591      for ac_prog in $SEARCH_LIST
27592do
27593  # Extract the first word of "$ac_prog", so it can be a program name with args.
27594set dummy $ac_prog; ac_word=$2
27595{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27596$as_echo_n "checking for $ac_word... " >&6; }
27597if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then :
27598  $as_echo_n "(cached) " >&6
27599else
27600  case $TOOLCHAIN_PATH_CC in
27601  [\\/]* | ?:[\\/]*)
27602  ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path.
27603  ;;
27604  *)
27605  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27606for as_dir in $PATH
27607do
27608  IFS=$as_save_IFS
27609  test -z "$as_dir" && as_dir=.
27610    for ac_exec_ext in '' $ac_executable_extensions; do
27611  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27612    ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext"
27613    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27614    break 2
27615  fi
27616done
27617  done
27618IFS=$as_save_IFS
27619
27620  ;;
27621esac
27622fi
27623TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC
27624if test -n "$TOOLCHAIN_PATH_CC"; then
27625  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5
27626$as_echo "$TOOLCHAIN_PATH_CC" >&6; }
27627else
27628  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27629$as_echo "no" >&6; }
27630fi
27631
27632
27633  test -n "$TOOLCHAIN_PATH_CC" && break
27634done
27635
27636      CC=$TOOLCHAIN_PATH_CC
27637      PATH="$PATH_save"
27638    fi
27639
27640    # AC_PATH_PROGS can't be run multiple times with the same variable,
27641    # so create a new name for this run.
27642    if test "x$CC" = x; then
27643      for ac_prog in $SEARCH_LIST
27644do
27645  # Extract the first word of "$ac_prog", so it can be a program name with args.
27646set dummy $ac_prog; ac_word=$2
27647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27648$as_echo_n "checking for $ac_word... " >&6; }
27649if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27650  $as_echo_n "(cached) " >&6
27651else
27652  case $POTENTIAL_CC in
27653  [\\/]* | ?:[\\/]*)
27654  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27655  ;;
27656  *)
27657  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27658for as_dir in $PATH
27659do
27660  IFS=$as_save_IFS
27661  test -z "$as_dir" && as_dir=.
27662    for ac_exec_ext in '' $ac_executable_extensions; do
27663  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27664    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27665    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27666    break 2
27667  fi
27668done
27669  done
27670IFS=$as_save_IFS
27671
27672  ;;
27673esac
27674fi
27675POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27676if test -n "$POTENTIAL_CC"; then
27677  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27678$as_echo "$POTENTIAL_CC" >&6; }
27679else
27680  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27681$as_echo "no" >&6; }
27682fi
27683
27684
27685  test -n "$POTENTIAL_CC" && break
27686done
27687
27688      CC=$POTENTIAL_CC
27689    fi
27690
27691    if test "x$CC" = x; then
27692
27693  # Print a helpful message on how to acquire the necessary build dependency.
27694  # devkit is the help tag: freetype, cups, pulse, alsa etc
27695  MISSING_DEPENDENCY=devkit
27696
27697  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27698    cygwin_help $MISSING_DEPENDENCY
27699  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27700    msys_help $MISSING_DEPENDENCY
27701  else
27702    PKGHANDLER_COMMAND=
27703
27704    case $PKGHANDLER in
27705      apt-get)
27706        apt_help     $MISSING_DEPENDENCY ;;
27707      yum)
27708        yum_help     $MISSING_DEPENDENCY ;;
27709      port)
27710        port_help    $MISSING_DEPENDENCY ;;
27711      pkgutil)
27712        pkgutil_help $MISSING_DEPENDENCY ;;
27713      pkgadd)
27714        pkgadd_help  $MISSING_DEPENDENCY ;;
27715    esac
27716
27717    if test "x$PKGHANDLER_COMMAND" != x; then
27718      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
27719    fi
27720  fi
27721
27722      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
27723    fi
27724  fi
27725
27726  # Now we have a compiler binary in CC. Make sure it's okay.
27727
27728  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27729
27730  # First separate the path from the arguments. This will split at the first
27731  # space.
27732  complete="$CC"
27733  path="${complete%% *}"
27734  tmp="$complete EOL"
27735  arguments="${tmp#* }"
27736
27737  # Input might be given as Windows format, start by converting to
27738  # unix format.
27739  new_path=`$CYGPATH -u "$path"`
27740
27741  # Now try to locate executable using which
27742  new_path=`$WHICH "$new_path" 2> /dev/null`
27743  # bat and cmd files are not always considered executable in cygwin causing which
27744  # to not find them
27745  if test "x$new_path" = x \
27746      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27747      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27748    new_path=`$CYGPATH -u "$path"`
27749  fi
27750  if test "x$new_path" = x; then
27751    # Oops. Which didn't find the executable.
27752    # The splitting of arguments from the executable at a space might have been incorrect,
27753    # since paths with space are more likely in Windows. Give it another try with the whole
27754    # argument.
27755    path="$complete"
27756    arguments="EOL"
27757    new_path=`$CYGPATH -u "$path"`
27758    new_path=`$WHICH "$new_path" 2> /dev/null`
27759    # bat and cmd files are not always considered executable in cygwin causing which
27760    # to not find them
27761    if test "x$new_path" = x \
27762        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27763        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27764      new_path=`$CYGPATH -u "$path"`
27765    fi
27766    if test "x$new_path" = x; then
27767      # It's still not found. Now this is an unrecoverable error.
27768      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27769$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27770      has_space=`$ECHO "$complete" | $GREP " "`
27771      if test "x$has_space" != x; then
27772        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27773$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27774      fi
27775      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27776    fi
27777  fi
27778
27779  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27780  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27781  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27782  # "foo.exe" is OK but "foo" is an error.
27783  #
27784  # This test is therefore slightly more accurate than "test -f" to check for file presence.
27785  # It is also a way to make sure we got the proper file name for the real test later on.
27786  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27787  if test "x$test_shortpath" = x; then
27788    # Short path failed, file does not exist as specified.
27789    # Try adding .exe or .cmd
27790    if test -f "${new_path}.exe"; then
27791      input_to_shortpath="${new_path}.exe"
27792    elif test -f "${new_path}.cmd"; then
27793      input_to_shortpath="${new_path}.cmd"
27794    else
27795      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
27796$as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
27797      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27798$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27799      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27800    fi
27801  else
27802    input_to_shortpath="$new_path"
27803  fi
27804
27805  # Call helper function which possibly converts this using DOS-style short mode.
27806  # If so, the updated path is stored in $new_path.
27807  new_path="$input_to_shortpath"
27808
27809  input_path="$input_to_shortpath"
27810  # Check if we need to convert this using DOS-style short mode. If the path
27811  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27812  # take no chances and rewrite it.
27813  # Note: m4 eats our [], so we need to use [ and ] instead.
27814  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27815  if test "x$has_forbidden_chars" != x; then
27816    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27817    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27818    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27819    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27820      # Going to short mode and back again did indeed matter. Since short mode is
27821      # case insensitive, let's make it lowercase to improve readability.
27822      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27823      # Now convert it back to Unix-stile (cygpath)
27824      input_path=`$CYGPATH -u "$shortmode_path"`
27825      new_path="$input_path"
27826    fi
27827  fi
27828
27829  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27830  if test "x$test_cygdrive_prefix" = x; then
27831    # As a simple fix, exclude /usr/bin since it's not a real path.
27832    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27833      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27834      # a path prefixed by /cygdrive for fixpath to work.
27835      new_path="$CYGWIN_ROOT_PATH$input_path"
27836    fi
27837  fi
27838
27839  # remove trailing .exe if any
27840  new_path="${new_path/%.exe/}"
27841
27842  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27843
27844  # First separate the path from the arguments. This will split at the first
27845  # space.
27846  complete="$CC"
27847  path="${complete%% *}"
27848  tmp="$complete EOL"
27849  arguments="${tmp#* }"
27850
27851  # Input might be given as Windows format, start by converting to
27852  # unix format.
27853  new_path="$path"
27854
27855  windows_path="$new_path"
27856  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27857    unix_path=`$CYGPATH -u "$windows_path"`
27858    new_path="$unix_path"
27859  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27860    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27861    new_path="$unix_path"
27862  fi
27863
27864
27865  # Now try to locate executable using which
27866  new_path=`$WHICH "$new_path" 2> /dev/null`
27867
27868  if test "x$new_path" = x; then
27869    # Oops. Which didn't find the executable.
27870    # The splitting of arguments from the executable at a space might have been incorrect,
27871    # since paths with space are more likely in Windows. Give it another try with the whole
27872    # argument.
27873    path="$complete"
27874    arguments="EOL"
27875    new_path="$path"
27876
27877  windows_path="$new_path"
27878  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27879    unix_path=`$CYGPATH -u "$windows_path"`
27880    new_path="$unix_path"
27881  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27882    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27883    new_path="$unix_path"
27884  fi
27885
27886
27887    new_path=`$WHICH "$new_path" 2> /dev/null`
27888
27889    if test "x$new_path" = x; then
27890      # It's still not found. Now this is an unrecoverable error.
27891      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27892$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27893      has_space=`$ECHO "$complete" | $GREP " "`
27894      if test "x$has_space" != x; then
27895        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27896$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27897      fi
27898      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27899    fi
27900  fi
27901
27902  # Now new_path has a complete unix path to the binary
27903  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27904    # Keep paths in /bin as-is, but remove trailing .exe if any
27905    new_path="${new_path/%.exe/}"
27906    # Do not save /bin paths to all_fixpath_prefixes!
27907  else
27908    # Not in mixed or Windows style, start by that.
27909    new_path=`cmd //c echo $new_path`
27910
27911  input_path="$new_path"
27912  # Check if we need to convert this using DOS-style short mode. If the path
27913  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27914  # take no chances and rewrite it.
27915  # Note: m4 eats our [], so we need to use [ and ] instead.
27916  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27917  if test "x$has_forbidden_chars" != x; then
27918    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27919    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27920  fi
27921
27922    # Output is in $new_path
27923
27924  windows_path="$new_path"
27925  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27926    unix_path=`$CYGPATH -u "$windows_path"`
27927    new_path="$unix_path"
27928  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27929    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27930    new_path="$unix_path"
27931  fi
27932
27933    # remove trailing .exe if any
27934    new_path="${new_path/%.exe/}"
27935
27936    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27937    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27938  fi
27939
27940  else
27941    # We're on a posix platform. Hooray! :)
27942    # First separate the path from the arguments. This will split at the first
27943    # space.
27944    complete="$CC"
27945    path="${complete%% *}"
27946    tmp="$complete EOL"
27947    arguments="${tmp#* }"
27948
27949    # Cannot rely on the command "which" here since it doesn't always work.
27950    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27951    if test -z "$is_absolute_path"; then
27952      # Path to executable is not absolute. Find it.
27953      IFS_save="$IFS"
27954      IFS=:
27955      for p in $PATH; do
27956        if test -f "$p/$path" && test -x "$p/$path"; then
27957          new_path="$p/$path"
27958          break
27959        fi
27960      done
27961      IFS="$IFS_save"
27962    else
27963      # This is an absolute path, we can use it without further modifications.
27964      new_path="$path"
27965    fi
27966
27967    if test "x$new_path" = x; then
27968      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27969$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27970      has_space=`$ECHO "$complete" | $GREP " "`
27971      if test "x$has_space" != x; then
27972        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27973$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27974      fi
27975      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27976    fi
27977  fi
27978
27979  # Now join together the path and the arguments once again
27980  if test "x$arguments" != xEOL; then
27981    new_complete="$new_path ${arguments% *}"
27982  else
27983    new_complete="$new_path"
27984  fi
27985
27986  if test "x$complete" != "x$new_complete"; then
27987    CC="$new_complete"
27988    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
27989$as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
27990  fi
27991
27992  TEST_COMPILER="$CC"
27993  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
27994  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
27995  if test "x$OPENJDK_BUILD_OS" != xaix; then
27996    # FIXME: This test should not be needed anymore; we don't do that for any platform.
27997    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
27998$as_echo_n "checking resolved symbolic links for CC... " >&6; }
27999
28000  if test "x$OPENJDK_BUILD_OS" != xwindows; then
28001    # Follow a chain of symbolic links. Use readlink
28002    # where it exists, else fall back to horribly
28003    # complicated shell code.
28004    if test "x$READLINK_TESTED" != yes; then
28005      # On MacOSX there is a readlink tool with a different
28006      # purpose than the GNU readlink tool. Check the found readlink.
28007      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28008      if test "x$ISGNU" = x; then
28009        # A readlink that we do not know how to use.
28010        # Are there other non-GNU readlinks out there?
28011        READLINK_TESTED=yes
28012        READLINK=
28013      fi
28014    fi
28015
28016    if test "x$READLINK" != x; then
28017      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
28018    else
28019      # Save the current directory for restoring afterwards
28020      STARTDIR=$PWD
28021      COUNTER=0
28022      sym_link_dir=`$DIRNAME $TEST_COMPILER`
28023      sym_link_file=`$BASENAME $TEST_COMPILER`
28024      cd $sym_link_dir
28025      # Use -P flag to resolve symlinks in directories.
28026      cd `$THEPWDCMD -P`
28027      sym_link_dir=`$THEPWDCMD -P`
28028      # Resolve file symlinks
28029      while test $COUNTER -lt 20; do
28030        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28031        if test "x$ISLINK" == x; then
28032          # This is not a symbolic link! We are done!
28033          break
28034        fi
28035        # Again resolve directory symlinks since the target of the just found
28036        # link could be in a different directory
28037        cd `$DIRNAME $ISLINK`
28038        sym_link_dir=`$THEPWDCMD -P`
28039        sym_link_file=`$BASENAME $ISLINK`
28040        let COUNTER=COUNTER+1
28041      done
28042      cd $STARTDIR
28043      TEST_COMPILER=$sym_link_dir/$sym_link_file
28044    fi
28045  fi
28046
28047    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
28048$as_echo "$TEST_COMPILER" >&6; }
28049  fi
28050  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
28051$as_echo_n "checking if CC is disguised ccache... " >&6; }
28052
28053  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
28054  if test "x$COMPILER_BASENAME" = "xccache"; then
28055    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
28056$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
28057    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
28058    # We want to control ccache invocation ourselves, so ignore this cc and try
28059    # searching again.
28060
28061    # Remove the path to the fake ccache cc from the PATH
28062    RETRY_COMPILER_SAVED_PATH="$PATH"
28063    COMPILER_DIRNAME=`$DIRNAME $CC`
28064    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
28065
28066    # Try again looking for our compiler
28067    if test -n "$ac_tool_prefix"; then
28068  for ac_prog in $TOOLCHAIN_CC_BINARY
28069  do
28070    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28071set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28072{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28073$as_echo_n "checking for $ac_word... " >&6; }
28074if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
28075  $as_echo_n "(cached) " >&6
28076else
28077  if test -n "$PROPER_COMPILER_CC"; then
28078  ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
28079else
28080as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28081for as_dir in $PATH
28082do
28083  IFS=$as_save_IFS
28084  test -z "$as_dir" && as_dir=.
28085    for ac_exec_ext in '' $ac_executable_extensions; do
28086  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28087    ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
28088    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28089    break 2
28090  fi
28091done
28092  done
28093IFS=$as_save_IFS
28094
28095fi
28096fi
28097PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
28098if test -n "$PROPER_COMPILER_CC"; then
28099  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28100$as_echo "$PROPER_COMPILER_CC" >&6; }
28101else
28102  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28103$as_echo "no" >&6; }
28104fi
28105
28106
28107    test -n "$PROPER_COMPILER_CC" && break
28108  done
28109fi
28110if test -z "$PROPER_COMPILER_CC"; then
28111  ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
28112  for ac_prog in $TOOLCHAIN_CC_BINARY
28113do
28114  # Extract the first word of "$ac_prog", so it can be a program name with args.
28115set dummy $ac_prog; ac_word=$2
28116{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28117$as_echo_n "checking for $ac_word... " >&6; }
28118if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
28119  $as_echo_n "(cached) " >&6
28120else
28121  if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28122  ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
28123else
28124as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28125for as_dir in $PATH
28126do
28127  IFS=$as_save_IFS
28128  test -z "$as_dir" && as_dir=.
28129    for ac_exec_ext in '' $ac_executable_extensions; do
28130  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28131    ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
28132    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28133    break 2
28134  fi
28135done
28136  done
28137IFS=$as_save_IFS
28138
28139fi
28140fi
28141ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
28142if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28143  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
28144$as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
28145else
28146  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28147$as_echo "no" >&6; }
28148fi
28149
28150
28151  test -n "$ac_ct_PROPER_COMPILER_CC" && break
28152done
28153
28154  if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
28155    PROPER_COMPILER_CC=""
28156  else
28157    case $cross_compiling:$ac_tool_warned in
28158yes:)
28159{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28160$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28161ac_tool_warned=yes ;;
28162esac
28163    PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
28164  fi
28165fi
28166
28167
28168  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28169
28170  # First separate the path from the arguments. This will split at the first
28171  # space.
28172  complete="$PROPER_COMPILER_CC"
28173  path="${complete%% *}"
28174  tmp="$complete EOL"
28175  arguments="${tmp#* }"
28176
28177  # Input might be given as Windows format, start by converting to
28178  # unix format.
28179  new_path=`$CYGPATH -u "$path"`
28180
28181  # Now try to locate executable using which
28182  new_path=`$WHICH "$new_path" 2> /dev/null`
28183  # bat and cmd files are not always considered executable in cygwin causing which
28184  # to not find them
28185  if test "x$new_path" = x \
28186      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28187      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28188    new_path=`$CYGPATH -u "$path"`
28189  fi
28190  if test "x$new_path" = x; then
28191    # Oops. Which didn't find the executable.
28192    # The splitting of arguments from the executable at a space might have been incorrect,
28193    # since paths with space are more likely in Windows. Give it another try with the whole
28194    # argument.
28195    path="$complete"
28196    arguments="EOL"
28197    new_path=`$CYGPATH -u "$path"`
28198    new_path=`$WHICH "$new_path" 2> /dev/null`
28199    # bat and cmd files are not always considered executable in cygwin causing which
28200    # to not find them
28201    if test "x$new_path" = x \
28202        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28203        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28204      new_path=`$CYGPATH -u "$path"`
28205    fi
28206    if test "x$new_path" = x; then
28207      # It's still not found. Now this is an unrecoverable error.
28208      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28209$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28210      has_space=`$ECHO "$complete" | $GREP " "`
28211      if test "x$has_space" != x; then
28212        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28213$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28214      fi
28215      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28216    fi
28217  fi
28218
28219  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28220  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28221  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28222  # "foo.exe" is OK but "foo" is an error.
28223  #
28224  # This test is therefore slightly more accurate than "test -f" to check for file presence.
28225  # It is also a way to make sure we got the proper file name for the real test later on.
28226  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28227  if test "x$test_shortpath" = x; then
28228    # Short path failed, file does not exist as specified.
28229    # Try adding .exe or .cmd
28230    if test -f "${new_path}.exe"; then
28231      input_to_shortpath="${new_path}.exe"
28232    elif test -f "${new_path}.cmd"; then
28233      input_to_shortpath="${new_path}.cmd"
28234    else
28235      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
28236$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
28237      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28238$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28239      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28240    fi
28241  else
28242    input_to_shortpath="$new_path"
28243  fi
28244
28245  # Call helper function which possibly converts this using DOS-style short mode.
28246  # If so, the updated path is stored in $new_path.
28247  new_path="$input_to_shortpath"
28248
28249  input_path="$input_to_shortpath"
28250  # Check if we need to convert this using DOS-style short mode. If the path
28251  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28252  # take no chances and rewrite it.
28253  # Note: m4 eats our [], so we need to use [ and ] instead.
28254  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28255  if test "x$has_forbidden_chars" != x; then
28256    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28257    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28258    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28259    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28260      # Going to short mode and back again did indeed matter. Since short mode is
28261      # case insensitive, let's make it lowercase to improve readability.
28262      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28263      # Now convert it back to Unix-stile (cygpath)
28264      input_path=`$CYGPATH -u "$shortmode_path"`
28265      new_path="$input_path"
28266    fi
28267  fi
28268
28269  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28270  if test "x$test_cygdrive_prefix" = x; then
28271    # As a simple fix, exclude /usr/bin since it's not a real path.
28272    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28273      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28274      # a path prefixed by /cygdrive for fixpath to work.
28275      new_path="$CYGWIN_ROOT_PATH$input_path"
28276    fi
28277  fi
28278
28279  # remove trailing .exe if any
28280  new_path="${new_path/%.exe/}"
28281
28282  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28283
28284  # First separate the path from the arguments. This will split at the first
28285  # space.
28286  complete="$PROPER_COMPILER_CC"
28287  path="${complete%% *}"
28288  tmp="$complete EOL"
28289  arguments="${tmp#* }"
28290
28291  # Input might be given as Windows format, start by converting to
28292  # unix format.
28293  new_path="$path"
28294
28295  windows_path="$new_path"
28296  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28297    unix_path=`$CYGPATH -u "$windows_path"`
28298    new_path="$unix_path"
28299  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28300    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28301    new_path="$unix_path"
28302  fi
28303
28304
28305  # Now try to locate executable using which
28306  new_path=`$WHICH "$new_path" 2> /dev/null`
28307
28308  if test "x$new_path" = x; then
28309    # Oops. Which didn't find the executable.
28310    # The splitting of arguments from the executable at a space might have been incorrect,
28311    # since paths with space are more likely in Windows. Give it another try with the whole
28312    # argument.
28313    path="$complete"
28314    arguments="EOL"
28315    new_path="$path"
28316
28317  windows_path="$new_path"
28318  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28319    unix_path=`$CYGPATH -u "$windows_path"`
28320    new_path="$unix_path"
28321  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28322    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28323    new_path="$unix_path"
28324  fi
28325
28326
28327    new_path=`$WHICH "$new_path" 2> /dev/null`
28328
28329    if test "x$new_path" = x; then
28330      # It's still not found. Now this is an unrecoverable error.
28331      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28332$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28333      has_space=`$ECHO "$complete" | $GREP " "`
28334      if test "x$has_space" != x; then
28335        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28336$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28337      fi
28338      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28339    fi
28340  fi
28341
28342  # Now new_path has a complete unix path to the binary
28343  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28344    # Keep paths in /bin as-is, but remove trailing .exe if any
28345    new_path="${new_path/%.exe/}"
28346    # Do not save /bin paths to all_fixpath_prefixes!
28347  else
28348    # Not in mixed or Windows style, start by that.
28349    new_path=`cmd //c echo $new_path`
28350
28351  input_path="$new_path"
28352  # Check if we need to convert this using DOS-style short mode. If the path
28353  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28354  # take no chances and rewrite it.
28355  # Note: m4 eats our [], so we need to use [ and ] instead.
28356  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28357  if test "x$has_forbidden_chars" != x; then
28358    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28359    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28360  fi
28361
28362    # Output is in $new_path
28363
28364  windows_path="$new_path"
28365  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28366    unix_path=`$CYGPATH -u "$windows_path"`
28367    new_path="$unix_path"
28368  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28369    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28370    new_path="$unix_path"
28371  fi
28372
28373    # remove trailing .exe if any
28374    new_path="${new_path/%.exe/}"
28375
28376    # Save the first 10 bytes of this path to the storage, so fixpath can work.
28377    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28378  fi
28379
28380  else
28381    # We're on a posix platform. Hooray! :)
28382    # First separate the path from the arguments. This will split at the first
28383    # space.
28384    complete="$PROPER_COMPILER_CC"
28385    path="${complete%% *}"
28386    tmp="$complete EOL"
28387    arguments="${tmp#* }"
28388
28389    # Cannot rely on the command "which" here since it doesn't always work.
28390    is_absolute_path=`$ECHO "$path" | $GREP ^/`
28391    if test -z "$is_absolute_path"; then
28392      # Path to executable is not absolute. Find it.
28393      IFS_save="$IFS"
28394      IFS=:
28395      for p in $PATH; do
28396        if test -f "$p/$path" && test -x "$p/$path"; then
28397          new_path="$p/$path"
28398          break
28399        fi
28400      done
28401      IFS="$IFS_save"
28402    else
28403      # This is an absolute path, we can use it without further modifications.
28404      new_path="$path"
28405    fi
28406
28407    if test "x$new_path" = x; then
28408      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28409$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28410      has_space=`$ECHO "$complete" | $GREP " "`
28411      if test "x$has_space" != x; then
28412        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28413$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28414      fi
28415      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28416    fi
28417  fi
28418
28419  # Now join together the path and the arguments once again
28420  if test "x$arguments" != xEOL; then
28421    new_complete="$new_path ${arguments% *}"
28422  else
28423    new_complete="$new_path"
28424  fi
28425
28426  if test "x$complete" != "x$new_complete"; then
28427    PROPER_COMPILER_CC="$new_complete"
28428    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
28429$as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
28430  fi
28431
28432    PATH="$RETRY_COMPILER_SAVED_PATH"
28433
28434    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
28435$as_echo_n "checking for resolved symbolic links for CC... " >&6; }
28436
28437  if test "x$OPENJDK_BUILD_OS" != xwindows; then
28438    # Follow a chain of symbolic links. Use readlink
28439    # where it exists, else fall back to horribly
28440    # complicated shell code.
28441    if test "x$READLINK_TESTED" != yes; then
28442      # On MacOSX there is a readlink tool with a different
28443      # purpose than the GNU readlink tool. Check the found readlink.
28444      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28445      if test "x$ISGNU" = x; then
28446        # A readlink that we do not know how to use.
28447        # Are there other non-GNU readlinks out there?
28448        READLINK_TESTED=yes
28449        READLINK=
28450      fi
28451    fi
28452
28453    if test "x$READLINK" != x; then
28454      PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
28455    else
28456      # Save the current directory for restoring afterwards
28457      STARTDIR=$PWD
28458      COUNTER=0
28459      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
28460      sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
28461      cd $sym_link_dir
28462      # Use -P flag to resolve symlinks in directories.
28463      cd `$THEPWDCMD -P`
28464      sym_link_dir=`$THEPWDCMD -P`
28465      # Resolve file symlinks
28466      while test $COUNTER -lt 20; do
28467        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28468        if test "x$ISLINK" == x; then
28469          # This is not a symbolic link! We are done!
28470          break
28471        fi
28472        # Again resolve directory symlinks since the target of the just found
28473        # link could be in a different directory
28474        cd `$DIRNAME $ISLINK`
28475        sym_link_dir=`$THEPWDCMD -P`
28476        sym_link_file=`$BASENAME $ISLINK`
28477        let COUNTER=COUNTER+1
28478      done
28479      cd $STARTDIR
28480      PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
28481    fi
28482  fi
28483
28484    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28485$as_echo "$PROPER_COMPILER_CC" >&6; }
28486    CC="$PROPER_COMPILER_CC"
28487  else
28488    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
28489$as_echo "no, keeping CC" >&6; }
28490  fi
28491
28492
28493  COMPILER=$CC
28494  COMPILER_NAME=$COMPILER_NAME
28495
28496  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
28497    # cc -V output typically looks like
28498    #     cc: Sun C 5.12 Linux_i386 2011/11/16
28499    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
28500    # Check that this is likely to be the Solaris Studio cc.
28501    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
28502    if test $? -ne 0; then
28503      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28504      { $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
28505$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28506      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28507$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28508      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28509$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28510      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28511    fi
28512    # Remove usage instructions (if present), and
28513    # collapse compiler output into a single line
28514    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28515        $SED -e 's/ *[Uu]sage:.*//'`
28516    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28517        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
28518  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
28519    # xlc -qversion output typically looks like
28520    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
28521    #     Version: 11.01.0000.0015
28522    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
28523    # Check that this is likely to be the IBM XL C compiler.
28524    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
28525    if test $? -ne 0; then
28526      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28527      { $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
28528$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28529      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28530$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28531      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28532$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28533      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28534    fi
28535    # Collapse compiler output into a single line
28536    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28537    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28538        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
28539  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
28540    # There is no specific version flag, but all output starts with a version string.
28541    # First line typically looks something like:
28542    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
28543    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
28544    # Check that this is likely to be Microsoft CL.EXE.
28545    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
28546    if test $? -ne 0; then
28547      { $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
28548$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28549      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28550$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28551      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28552    fi
28553    # Collapse compiler output into a single line
28554    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28555    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28556        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
28557  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
28558    # gcc --version output typically looks like
28559    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
28560    #     Copyright (C) 2013 Free Software Foundation, Inc.
28561    #     This is free software; see the source for copying conditions.  There is NO
28562    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28563    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28564    # Check that this is likely to be GCC.
28565    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
28566    if test $? -ne 0; then
28567      { $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
28568$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28569      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
28570$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
28571      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28572    fi
28573    # Remove Copyright and legalese from version string, and
28574    # collapse into a single line
28575    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28576        $SED -e 's/ *Copyright .*//'`
28577    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28578        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
28579  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
28580    # clang --version output typically looks like
28581    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
28582    #    clang version 3.3 (tags/RELEASE_33/final)
28583    # or
28584    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
28585    #    Target: x86_64-pc-linux-gnu
28586    #    Thread model: posix
28587    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28588    # Check that this is likely to be clang
28589    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
28590    if test $? -ne 0; then
28591      { $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
28592$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28593      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28594$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28595      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28596    fi
28597    # Collapse compiler output into a single line
28598    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28599    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28600        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
28601  else
28602      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
28603  fi
28604  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
28605  CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
28606  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
28607  CC_VERSION_STRING="$COMPILER_VERSION_STRING"
28608
28609  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
28610$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
28611
28612
28613  # Now that we have resolved CC ourself, let autoconf have its go at it
28614  ac_ext=c
28615ac_cpp='$CPP $CPPFLAGS'
28616ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28617ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28618ac_compiler_gnu=$ac_cv_c_compiler_gnu
28619if test -n "$ac_tool_prefix"; then
28620  for ac_prog in $CC
28621  do
28622    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28623set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28624{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28625$as_echo_n "checking for $ac_word... " >&6; }
28626if ${ac_cv_prog_CC+:} false; then :
28627  $as_echo_n "(cached) " >&6
28628else
28629  if test -n "$CC"; then
28630  ac_cv_prog_CC="$CC" # Let the user override the test.
28631else
28632as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28633for as_dir in $PATH
28634do
28635  IFS=$as_save_IFS
28636  test -z "$as_dir" && as_dir=.
28637    for ac_exec_ext in '' $ac_executable_extensions; do
28638  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28639    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
28640    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28641    break 2
28642  fi
28643done
28644  done
28645IFS=$as_save_IFS
28646
28647fi
28648fi
28649CC=$ac_cv_prog_CC
28650if test -n "$CC"; then
28651  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
28652$as_echo "$CC" >&6; }
28653else
28654  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28655$as_echo "no" >&6; }
28656fi
28657
28658
28659    test -n "$CC" && break
28660  done
28661fi
28662if test -z "$CC"; then
28663  ac_ct_CC=$CC
28664  for ac_prog in $CC
28665do
28666  # Extract the first word of "$ac_prog", so it can be a program name with args.
28667set dummy $ac_prog; ac_word=$2
28668{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28669$as_echo_n "checking for $ac_word... " >&6; }
28670if ${ac_cv_prog_ac_ct_CC+:} false; then :
28671  $as_echo_n "(cached) " >&6
28672else
28673  if test -n "$ac_ct_CC"; then
28674  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
28675else
28676as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28677for as_dir in $PATH
28678do
28679  IFS=$as_save_IFS
28680  test -z "$as_dir" && as_dir=.
28681    for ac_exec_ext in '' $ac_executable_extensions; do
28682  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28683    ac_cv_prog_ac_ct_CC="$ac_prog"
28684    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28685    break 2
28686  fi
28687done
28688  done
28689IFS=$as_save_IFS
28690
28691fi
28692fi
28693ac_ct_CC=$ac_cv_prog_ac_ct_CC
28694if test -n "$ac_ct_CC"; then
28695  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
28696$as_echo "$ac_ct_CC" >&6; }
28697else
28698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28699$as_echo "no" >&6; }
28700fi
28701
28702
28703  test -n "$ac_ct_CC" && break
28704done
28705
28706  if test "x$ac_ct_CC" = x; then
28707    CC=""
28708  else
28709    case $cross_compiling:$ac_tool_warned in
28710yes:)
28711{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28712$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28713ac_tool_warned=yes ;;
28714esac
28715    CC=$ac_ct_CC
28716  fi
28717fi
28718
28719
28720test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28721$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28722as_fn_error $? "no acceptable C compiler found in \$PATH
28723See \`config.log' for more details" "$LINENO" 5; }
28724
28725# Provide some information about the compiler.
28726$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
28727set X $ac_compile
28728ac_compiler=$2
28729for ac_option in --version -v -V -qversion; do
28730  { { ac_try="$ac_compiler $ac_option >&5"
28731case "(($ac_try" in
28732  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28733  *) ac_try_echo=$ac_try;;
28734esac
28735eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28736$as_echo "$ac_try_echo"; } >&5
28737  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
28738  ac_status=$?
28739  if test -s conftest.err; then
28740    sed '10a\
28741... rest of stderr output deleted ...
28742         10q' conftest.err >conftest.er1
28743    cat conftest.er1 >&5
28744  fi
28745  rm -f conftest.er1 conftest.err
28746  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28747  test $ac_status = 0; }
28748done
28749
28750cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28751/* end confdefs.h.  */
28752
28753int
28754main ()
28755{
28756
28757  ;
28758  return 0;
28759}
28760_ACEOF
28761ac_clean_files_save=$ac_clean_files
28762ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
28763# Try to create an executable without -o first, disregard a.out.
28764# It will help us diagnose broken compilers, and finding out an intuition
28765# of exeext.
28766{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
28767$as_echo_n "checking whether the C compiler works... " >&6; }
28768ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
28769
28770# The possible output files:
28771ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
28772
28773ac_rmfiles=
28774for ac_file in $ac_files
28775do
28776  case $ac_file in
28777    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28778    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
28779  esac
28780done
28781rm -f $ac_rmfiles
28782
28783if { { ac_try="$ac_link_default"
28784case "(($ac_try" in
28785  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28786  *) ac_try_echo=$ac_try;;
28787esac
28788eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28789$as_echo "$ac_try_echo"; } >&5
28790  (eval "$ac_link_default") 2>&5
28791  ac_status=$?
28792  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28793  test $ac_status = 0; }; then :
28794  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
28795# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
28796# in a Makefile.  We should not override ac_cv_exeext if it was cached,
28797# so that the user can short-circuit this test for compilers unknown to
28798# Autoconf.
28799for ac_file in $ac_files ''
28800do
28801  test -f "$ac_file" || continue
28802  case $ac_file in
28803    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
28804	;;
28805    [ab].out )
28806	# We found the default executable, but exeext='' is most
28807	# certainly right.
28808	break;;
28809    *.* )
28810	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
28811	then :; else
28812	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28813	fi
28814	# We set ac_cv_exeext here because the later test for it is not
28815	# safe: cross compilers may not add the suffix if given an `-o'
28816	# argument, so we may need to know it at that point already.
28817	# Even if this section looks crufty: it has the advantage of
28818	# actually working.
28819	break;;
28820    * )
28821	break;;
28822  esac
28823done
28824test "$ac_cv_exeext" = no && ac_cv_exeext=
28825
28826else
28827  ac_file=''
28828fi
28829if test -z "$ac_file"; then :
28830  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28831$as_echo "no" >&6; }
28832$as_echo "$as_me: failed program was:" >&5
28833sed 's/^/| /' conftest.$ac_ext >&5
28834
28835{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28836$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28837as_fn_error 77 "C compiler cannot create executables
28838See \`config.log' for more details" "$LINENO" 5; }
28839else
28840  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28841$as_echo "yes" >&6; }
28842fi
28843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
28844$as_echo_n "checking for C compiler default output file name... " >&6; }
28845{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
28846$as_echo "$ac_file" >&6; }
28847ac_exeext=$ac_cv_exeext
28848
28849rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
28850ac_clean_files=$ac_clean_files_save
28851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
28852$as_echo_n "checking for suffix of executables... " >&6; }
28853if { { ac_try="$ac_link"
28854case "(($ac_try" in
28855  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28856  *) ac_try_echo=$ac_try;;
28857esac
28858eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28859$as_echo "$ac_try_echo"; } >&5
28860  (eval "$ac_link") 2>&5
28861  ac_status=$?
28862  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28863  test $ac_status = 0; }; then :
28864  # If both `conftest.exe' and `conftest' are `present' (well, observable)
28865# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
28866# work properly (i.e., refer to `conftest.exe'), while it won't with
28867# `rm'.
28868for ac_file in conftest.exe conftest conftest.*; do
28869  test -f "$ac_file" || continue
28870  case $ac_file in
28871    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28872    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28873	  break;;
28874    * ) break;;
28875  esac
28876done
28877else
28878  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28879$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28880as_fn_error $? "cannot compute suffix of executables: cannot compile and link
28881See \`config.log' for more details" "$LINENO" 5; }
28882fi
28883rm -f conftest conftest$ac_cv_exeext
28884{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
28885$as_echo "$ac_cv_exeext" >&6; }
28886
28887rm -f conftest.$ac_ext
28888EXEEXT=$ac_cv_exeext
28889ac_exeext=$EXEEXT
28890cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28891/* end confdefs.h.  */
28892#include <stdio.h>
28893int
28894main ()
28895{
28896FILE *f = fopen ("conftest.out", "w");
28897 return ferror (f) || fclose (f) != 0;
28898
28899  ;
28900  return 0;
28901}
28902_ACEOF
28903ac_clean_files="$ac_clean_files conftest.out"
28904# Check that the compiler produces executables we can run.  If not, either
28905# the compiler is broken, or we cross compile.
28906{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
28907$as_echo_n "checking whether we are cross compiling... " >&6; }
28908if test "$cross_compiling" != yes; then
28909  { { ac_try="$ac_link"
28910case "(($ac_try" in
28911  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28912  *) ac_try_echo=$ac_try;;
28913esac
28914eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28915$as_echo "$ac_try_echo"; } >&5
28916  (eval "$ac_link") 2>&5
28917  ac_status=$?
28918  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28919  test $ac_status = 0; }
28920  if { ac_try='./conftest$ac_cv_exeext'
28921  { { case "(($ac_try" in
28922  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28923  *) ac_try_echo=$ac_try;;
28924esac
28925eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28926$as_echo "$ac_try_echo"; } >&5
28927  (eval "$ac_try") 2>&5
28928  ac_status=$?
28929  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28930  test $ac_status = 0; }; }; then
28931    cross_compiling=no
28932  else
28933    if test "$cross_compiling" = maybe; then
28934	cross_compiling=yes
28935    else
28936	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28937$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28938as_fn_error $? "cannot run C compiled programs.
28939If you meant to cross compile, use \`--host'.
28940See \`config.log' for more details" "$LINENO" 5; }
28941    fi
28942  fi
28943fi
28944{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
28945$as_echo "$cross_compiling" >&6; }
28946
28947rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
28948ac_clean_files=$ac_clean_files_save
28949{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
28950$as_echo_n "checking for suffix of object files... " >&6; }
28951if ${ac_cv_objext+:} false; then :
28952  $as_echo_n "(cached) " >&6
28953else
28954  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28955/* end confdefs.h.  */
28956
28957int
28958main ()
28959{
28960
28961  ;
28962  return 0;
28963}
28964_ACEOF
28965rm -f conftest.o conftest.obj
28966if { { ac_try="$ac_compile"
28967case "(($ac_try" in
28968  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28969  *) ac_try_echo=$ac_try;;
28970esac
28971eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28972$as_echo "$ac_try_echo"; } >&5
28973  (eval "$ac_compile") 2>&5
28974  ac_status=$?
28975  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28976  test $ac_status = 0; }; then :
28977  for ac_file in conftest.o conftest.obj conftest.*; do
28978  test -f "$ac_file" || continue;
28979  case $ac_file in
28980    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
28981    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
28982       break;;
28983  esac
28984done
28985else
28986  $as_echo "$as_me: failed program was:" >&5
28987sed 's/^/| /' conftest.$ac_ext >&5
28988
28989{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28990$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28991as_fn_error $? "cannot compute suffix of object files: cannot compile
28992See \`config.log' for more details" "$LINENO" 5; }
28993fi
28994rm -f conftest.$ac_cv_objext conftest.$ac_ext
28995fi
28996{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
28997$as_echo "$ac_cv_objext" >&6; }
28998OBJEXT=$ac_cv_objext
28999ac_objext=$OBJEXT
29000{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
29001$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
29002if ${ac_cv_c_compiler_gnu+:} false; then :
29003  $as_echo_n "(cached) " >&6
29004else
29005  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29006/* end confdefs.h.  */
29007
29008int
29009main ()
29010{
29011#ifndef __GNUC__
29012       choke me
29013#endif
29014
29015  ;
29016  return 0;
29017}
29018_ACEOF
29019if ac_fn_c_try_compile "$LINENO"; then :
29020  ac_compiler_gnu=yes
29021else
29022  ac_compiler_gnu=no
29023fi
29024rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29025ac_cv_c_compiler_gnu=$ac_compiler_gnu
29026
29027fi
29028{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
29029$as_echo "$ac_cv_c_compiler_gnu" >&6; }
29030if test $ac_compiler_gnu = yes; then
29031  GCC=yes
29032else
29033  GCC=
29034fi
29035ac_test_CFLAGS=${CFLAGS+set}
29036ac_save_CFLAGS=$CFLAGS
29037{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
29038$as_echo_n "checking whether $CC accepts -g... " >&6; }
29039if ${ac_cv_prog_cc_g+:} false; then :
29040  $as_echo_n "(cached) " >&6
29041else
29042  ac_save_c_werror_flag=$ac_c_werror_flag
29043   ac_c_werror_flag=yes
29044   ac_cv_prog_cc_g=no
29045   CFLAGS="-g"
29046   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29047/* end confdefs.h.  */
29048
29049int
29050main ()
29051{
29052
29053  ;
29054  return 0;
29055}
29056_ACEOF
29057if ac_fn_c_try_compile "$LINENO"; then :
29058  ac_cv_prog_cc_g=yes
29059else
29060  CFLAGS=""
29061      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29062/* end confdefs.h.  */
29063
29064int
29065main ()
29066{
29067
29068  ;
29069  return 0;
29070}
29071_ACEOF
29072if ac_fn_c_try_compile "$LINENO"; then :
29073
29074else
29075  ac_c_werror_flag=$ac_save_c_werror_flag
29076	 CFLAGS="-g"
29077	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29078/* end confdefs.h.  */
29079
29080int
29081main ()
29082{
29083
29084  ;
29085  return 0;
29086}
29087_ACEOF
29088if ac_fn_c_try_compile "$LINENO"; then :
29089  ac_cv_prog_cc_g=yes
29090fi
29091rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29092fi
29093rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29094fi
29095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29096   ac_c_werror_flag=$ac_save_c_werror_flag
29097fi
29098{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
29099$as_echo "$ac_cv_prog_cc_g" >&6; }
29100if test "$ac_test_CFLAGS" = set; then
29101  CFLAGS=$ac_save_CFLAGS
29102elif test $ac_cv_prog_cc_g = yes; then
29103  if test "$GCC" = yes; then
29104    CFLAGS="-g -O2"
29105  else
29106    CFLAGS="-g"
29107  fi
29108else
29109  if test "$GCC" = yes; then
29110    CFLAGS="-O2"
29111  else
29112    CFLAGS=
29113  fi
29114fi
29115{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
29116$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
29117if ${ac_cv_prog_cc_c89+:} false; then :
29118  $as_echo_n "(cached) " >&6
29119else
29120  ac_cv_prog_cc_c89=no
29121ac_save_CC=$CC
29122cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29123/* end confdefs.h.  */
29124#include <stdarg.h>
29125#include <stdio.h>
29126struct stat;
29127/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
29128struct buf { int x; };
29129FILE * (*rcsopen) (struct buf *, struct stat *, int);
29130static char *e (p, i)
29131     char **p;
29132     int i;
29133{
29134  return p[i];
29135}
29136static char *f (char * (*g) (char **, int), char **p, ...)
29137{
29138  char *s;
29139  va_list v;
29140  va_start (v,p);
29141  s = g (p, va_arg (v,int));
29142  va_end (v);
29143  return s;
29144}
29145
29146/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
29147   function prototypes and stuff, but not '\xHH' hex character constants.
29148   These don't provoke an error unfortunately, instead are silently treated
29149   as 'x'.  The following induces an error, until -std is added to get
29150   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
29151   array size at least.  It's necessary to write '\x00'==0 to get something
29152   that's true only with -std.  */
29153int osf4_cc_array ['\x00' == 0 ? 1 : -1];
29154
29155/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
29156   inside strings and character constants.  */
29157#define FOO(x) 'x'
29158int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
29159
29160int test (int i, double x);
29161struct s1 {int (*f) (int a);};
29162struct s2 {int (*f) (double a);};
29163int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
29164int argc;
29165char **argv;
29166int
29167main ()
29168{
29169return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
29170  ;
29171  return 0;
29172}
29173_ACEOF
29174for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
29175	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
29176do
29177  CC="$ac_save_CC $ac_arg"
29178  if ac_fn_c_try_compile "$LINENO"; then :
29179  ac_cv_prog_cc_c89=$ac_arg
29180fi
29181rm -f core conftest.err conftest.$ac_objext
29182  test "x$ac_cv_prog_cc_c89" != "xno" && break
29183done
29184rm -f conftest.$ac_ext
29185CC=$ac_save_CC
29186
29187fi
29188# AC_CACHE_VAL
29189case "x$ac_cv_prog_cc_c89" in
29190  x)
29191    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
29192$as_echo "none needed" >&6; } ;;
29193  xno)
29194    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
29195$as_echo "unsupported" >&6; } ;;
29196  *)
29197    CC="$CC $ac_cv_prog_cc_c89"
29198    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
29199$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
29200esac
29201if test "x$ac_cv_prog_cc_c89" != xno; then :
29202
29203fi
29204
29205ac_ext=cpp
29206ac_cpp='$CXXCPP $CPPFLAGS'
29207ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29208ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29209ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29210
29211
29212
29213  COMPILER_NAME=C++
29214  SEARCH_LIST="$TOOLCHAIN_CXX_BINARY"
29215
29216  if test "x$CXX" != x; then
29217    # User has supplied compiler name already, always let that override.
29218    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
29219$as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
29220    if test "x`basename $CXX`" = "x$CXX"; then
29221      # A command without a complete path is provided, search $PATH.
29222
29223      for ac_prog in $CXX
29224do
29225  # Extract the first word of "$ac_prog", so it can be a program name with args.
29226set dummy $ac_prog; ac_word=$2
29227{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29228$as_echo_n "checking for $ac_word... " >&6; }
29229if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29230  $as_echo_n "(cached) " >&6
29231else
29232  case $POTENTIAL_CXX in
29233  [\\/]* | ?:[\\/]*)
29234  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29235  ;;
29236  *)
29237  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29238for as_dir in $PATH
29239do
29240  IFS=$as_save_IFS
29241  test -z "$as_dir" && as_dir=.
29242    for ac_exec_ext in '' $ac_executable_extensions; do
29243  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29244    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29245    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29246    break 2
29247  fi
29248done
29249  done
29250IFS=$as_save_IFS
29251
29252  ;;
29253esac
29254fi
29255POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29256if test -n "$POTENTIAL_CXX"; then
29257  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29258$as_echo "$POTENTIAL_CXX" >&6; }
29259else
29260  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29261$as_echo "no" >&6; }
29262fi
29263
29264
29265  test -n "$POTENTIAL_CXX" && break
29266done
29267
29268      if test "x$POTENTIAL_CXX" != x; then
29269        CXX=$POTENTIAL_CXX
29270      else
29271        as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29272      fi
29273    else
29274      # Otherwise it might already be a complete path
29275      if test ! -x "$CXX"; then
29276        as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29277      fi
29278    fi
29279  else
29280    # No user supplied value. Locate compiler ourselves.
29281
29282    # If we are cross compiling, assume cross compilation tools follows the
29283    # cross compilation standard where they are prefixed with the autoconf
29284    # standard name for the target. For example the binary
29285    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29286    # If we are not cross compiling, then the default compiler name will be
29287    # used.
29288
29289    CXX=
29290    # If TOOLCHAIN_PATH is set, check for all compiler names in there first
29291    # before checking the rest of the PATH.
29292    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29293    # step, this should not be necessary.
29294    if test -n "$TOOLCHAIN_PATH"; then
29295      PATH_save="$PATH"
29296      PATH="$TOOLCHAIN_PATH"
29297      for ac_prog in $SEARCH_LIST
29298do
29299  # Extract the first word of "$ac_prog", so it can be a program name with args.
29300set dummy $ac_prog; ac_word=$2
29301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29302$as_echo_n "checking for $ac_word... " >&6; }
29303if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then :
29304  $as_echo_n "(cached) " >&6
29305else
29306  case $TOOLCHAIN_PATH_CXX in
29307  [\\/]* | ?:[\\/]*)
29308  ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path.
29309  ;;
29310  *)
29311  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29312for as_dir in $PATH
29313do
29314  IFS=$as_save_IFS
29315  test -z "$as_dir" && as_dir=.
29316    for ac_exec_ext in '' $ac_executable_extensions; do
29317  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29318    ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext"
29319    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29320    break 2
29321  fi
29322done
29323  done
29324IFS=$as_save_IFS
29325
29326  ;;
29327esac
29328fi
29329TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX
29330if test -n "$TOOLCHAIN_PATH_CXX"; then
29331  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5
29332$as_echo "$TOOLCHAIN_PATH_CXX" >&6; }
29333else
29334  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29335$as_echo "no" >&6; }
29336fi
29337
29338
29339  test -n "$TOOLCHAIN_PATH_CXX" && break
29340done
29341
29342      CXX=$TOOLCHAIN_PATH_CXX
29343      PATH="$PATH_save"
29344    fi
29345
29346    # AC_PATH_PROGS can't be run multiple times with the same variable,
29347    # so create a new name for this run.
29348    if test "x$CXX" = x; then
29349      for ac_prog in $SEARCH_LIST
29350do
29351  # Extract the first word of "$ac_prog", so it can be a program name with args.
29352set dummy $ac_prog; ac_word=$2
29353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29354$as_echo_n "checking for $ac_word... " >&6; }
29355if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29356  $as_echo_n "(cached) " >&6
29357else
29358  case $POTENTIAL_CXX in
29359  [\\/]* | ?:[\\/]*)
29360  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29361  ;;
29362  *)
29363  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29364for as_dir in $PATH
29365do
29366  IFS=$as_save_IFS
29367  test -z "$as_dir" && as_dir=.
29368    for ac_exec_ext in '' $ac_executable_extensions; do
29369  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29370    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29371    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29372    break 2
29373  fi
29374done
29375  done
29376IFS=$as_save_IFS
29377
29378  ;;
29379esac
29380fi
29381POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29382if test -n "$POTENTIAL_CXX"; then
29383  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29384$as_echo "$POTENTIAL_CXX" >&6; }
29385else
29386  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29387$as_echo "no" >&6; }
29388fi
29389
29390
29391  test -n "$POTENTIAL_CXX" && break
29392done
29393
29394      CXX=$POTENTIAL_CXX
29395    fi
29396
29397    if test "x$CXX" = x; then
29398
29399  # Print a helpful message on how to acquire the necessary build dependency.
29400  # devkit is the help tag: freetype, cups, pulse, alsa etc
29401  MISSING_DEPENDENCY=devkit
29402
29403  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29404    cygwin_help $MISSING_DEPENDENCY
29405  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29406    msys_help $MISSING_DEPENDENCY
29407  else
29408    PKGHANDLER_COMMAND=
29409
29410    case $PKGHANDLER in
29411      apt-get)
29412        apt_help     $MISSING_DEPENDENCY ;;
29413      yum)
29414        yum_help     $MISSING_DEPENDENCY ;;
29415      port)
29416        port_help    $MISSING_DEPENDENCY ;;
29417      pkgutil)
29418        pkgutil_help $MISSING_DEPENDENCY ;;
29419      pkgadd)
29420        pkgadd_help  $MISSING_DEPENDENCY ;;
29421    esac
29422
29423    if test "x$PKGHANDLER_COMMAND" != x; then
29424      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29425    fi
29426  fi
29427
29428      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29429    fi
29430  fi
29431
29432  # Now we have a compiler binary in CXX. Make sure it's okay.
29433
29434  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29435
29436  # First separate the path from the arguments. This will split at the first
29437  # space.
29438  complete="$CXX"
29439  path="${complete%% *}"
29440  tmp="$complete EOL"
29441  arguments="${tmp#* }"
29442
29443  # Input might be given as Windows format, start by converting to
29444  # unix format.
29445  new_path=`$CYGPATH -u "$path"`
29446
29447  # Now try to locate executable using which
29448  new_path=`$WHICH "$new_path" 2> /dev/null`
29449  # bat and cmd files are not always considered executable in cygwin causing which
29450  # to not find them
29451  if test "x$new_path" = x \
29452      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29453      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29454    new_path=`$CYGPATH -u "$path"`
29455  fi
29456  if test "x$new_path" = x; then
29457    # Oops. Which didn't find the executable.
29458    # The splitting of arguments from the executable at a space might have been incorrect,
29459    # since paths with space are more likely in Windows. Give it another try with the whole
29460    # argument.
29461    path="$complete"
29462    arguments="EOL"
29463    new_path=`$CYGPATH -u "$path"`
29464    new_path=`$WHICH "$new_path" 2> /dev/null`
29465    # bat and cmd files are not always considered executable in cygwin causing which
29466    # to not find them
29467    if test "x$new_path" = x \
29468        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29469        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29470      new_path=`$CYGPATH -u "$path"`
29471    fi
29472    if test "x$new_path" = x; then
29473      # It's still not found. Now this is an unrecoverable error.
29474      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29475$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29476      has_space=`$ECHO "$complete" | $GREP " "`
29477      if test "x$has_space" != x; then
29478        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29479$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29480      fi
29481      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29482    fi
29483  fi
29484
29485  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29486  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29487  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29488  # "foo.exe" is OK but "foo" is an error.
29489  #
29490  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29491  # It is also a way to make sure we got the proper file name for the real test later on.
29492  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29493  if test "x$test_shortpath" = x; then
29494    # Short path failed, file does not exist as specified.
29495    # Try adding .exe or .cmd
29496    if test -f "${new_path}.exe"; then
29497      input_to_shortpath="${new_path}.exe"
29498    elif test -f "${new_path}.cmd"; then
29499      input_to_shortpath="${new_path}.cmd"
29500    else
29501      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
29502$as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
29503      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29504$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29505      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29506    fi
29507  else
29508    input_to_shortpath="$new_path"
29509  fi
29510
29511  # Call helper function which possibly converts this using DOS-style short mode.
29512  # If so, the updated path is stored in $new_path.
29513  new_path="$input_to_shortpath"
29514
29515  input_path="$input_to_shortpath"
29516  # Check if we need to convert this using DOS-style short mode. If the path
29517  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29518  # take no chances and rewrite it.
29519  # Note: m4 eats our [], so we need to use [ and ] instead.
29520  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29521  if test "x$has_forbidden_chars" != x; then
29522    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29523    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29524    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29525    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29526      # Going to short mode and back again did indeed matter. Since short mode is
29527      # case insensitive, let's make it lowercase to improve readability.
29528      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29529      # Now convert it back to Unix-stile (cygpath)
29530      input_path=`$CYGPATH -u "$shortmode_path"`
29531      new_path="$input_path"
29532    fi
29533  fi
29534
29535  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29536  if test "x$test_cygdrive_prefix" = x; then
29537    # As a simple fix, exclude /usr/bin since it's not a real path.
29538    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29539      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29540      # a path prefixed by /cygdrive for fixpath to work.
29541      new_path="$CYGWIN_ROOT_PATH$input_path"
29542    fi
29543  fi
29544
29545  # remove trailing .exe if any
29546  new_path="${new_path/%.exe/}"
29547
29548  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29549
29550  # First separate the path from the arguments. This will split at the first
29551  # space.
29552  complete="$CXX"
29553  path="${complete%% *}"
29554  tmp="$complete EOL"
29555  arguments="${tmp#* }"
29556
29557  # Input might be given as Windows format, start by converting to
29558  # unix format.
29559  new_path="$path"
29560
29561  windows_path="$new_path"
29562  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29563    unix_path=`$CYGPATH -u "$windows_path"`
29564    new_path="$unix_path"
29565  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29566    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29567    new_path="$unix_path"
29568  fi
29569
29570
29571  # Now try to locate executable using which
29572  new_path=`$WHICH "$new_path" 2> /dev/null`
29573
29574  if test "x$new_path" = x; then
29575    # Oops. Which didn't find the executable.
29576    # The splitting of arguments from the executable at a space might have been incorrect,
29577    # since paths with space are more likely in Windows. Give it another try with the whole
29578    # argument.
29579    path="$complete"
29580    arguments="EOL"
29581    new_path="$path"
29582
29583  windows_path="$new_path"
29584  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29585    unix_path=`$CYGPATH -u "$windows_path"`
29586    new_path="$unix_path"
29587  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29588    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29589    new_path="$unix_path"
29590  fi
29591
29592
29593    new_path=`$WHICH "$new_path" 2> /dev/null`
29594
29595    if test "x$new_path" = x; then
29596      # It's still not found. Now this is an unrecoverable error.
29597      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29598$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29599      has_space=`$ECHO "$complete" | $GREP " "`
29600      if test "x$has_space" != x; then
29601        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29602$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29603      fi
29604      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29605    fi
29606  fi
29607
29608  # Now new_path has a complete unix path to the binary
29609  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29610    # Keep paths in /bin as-is, but remove trailing .exe if any
29611    new_path="${new_path/%.exe/}"
29612    # Do not save /bin paths to all_fixpath_prefixes!
29613  else
29614    # Not in mixed or Windows style, start by that.
29615    new_path=`cmd //c echo $new_path`
29616
29617  input_path="$new_path"
29618  # Check if we need to convert this using DOS-style short mode. If the path
29619  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29620  # take no chances and rewrite it.
29621  # Note: m4 eats our [], so we need to use [ and ] instead.
29622  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29623  if test "x$has_forbidden_chars" != x; then
29624    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29625    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29626  fi
29627
29628    # Output is in $new_path
29629
29630  windows_path="$new_path"
29631  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29632    unix_path=`$CYGPATH -u "$windows_path"`
29633    new_path="$unix_path"
29634  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29635    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29636    new_path="$unix_path"
29637  fi
29638
29639    # remove trailing .exe if any
29640    new_path="${new_path/%.exe/}"
29641
29642    # Save the first 10 bytes of this path to the storage, so fixpath can work.
29643    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29644  fi
29645
29646  else
29647    # We're on a posix platform. Hooray! :)
29648    # First separate the path from the arguments. This will split at the first
29649    # space.
29650    complete="$CXX"
29651    path="${complete%% *}"
29652    tmp="$complete EOL"
29653    arguments="${tmp#* }"
29654
29655    # Cannot rely on the command "which" here since it doesn't always work.
29656    is_absolute_path=`$ECHO "$path" | $GREP ^/`
29657    if test -z "$is_absolute_path"; then
29658      # Path to executable is not absolute. Find it.
29659      IFS_save="$IFS"
29660      IFS=:
29661      for p in $PATH; do
29662        if test -f "$p/$path" && test -x "$p/$path"; then
29663          new_path="$p/$path"
29664          break
29665        fi
29666      done
29667      IFS="$IFS_save"
29668    else
29669      # This is an absolute path, we can use it without further modifications.
29670      new_path="$path"
29671    fi
29672
29673    if test "x$new_path" = x; then
29674      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29675$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29676      has_space=`$ECHO "$complete" | $GREP " "`
29677      if test "x$has_space" != x; then
29678        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29679$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29680      fi
29681      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29682    fi
29683  fi
29684
29685  # Now join together the path and the arguments once again
29686  if test "x$arguments" != xEOL; then
29687    new_complete="$new_path ${arguments% *}"
29688  else
29689    new_complete="$new_path"
29690  fi
29691
29692  if test "x$complete" != "x$new_complete"; then
29693    CXX="$new_complete"
29694    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
29695$as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
29696  fi
29697
29698  TEST_COMPILER="$CXX"
29699  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29700  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29701  if test "x$OPENJDK_BUILD_OS" != xaix; then
29702    # FIXME: This test should not be needed anymore; we don't do that for any platform.
29703    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
29704$as_echo_n "checking resolved symbolic links for CXX... " >&6; }
29705
29706  if test "x$OPENJDK_BUILD_OS" != xwindows; then
29707    # Follow a chain of symbolic links. Use readlink
29708    # where it exists, else fall back to horribly
29709    # complicated shell code.
29710    if test "x$READLINK_TESTED" != yes; then
29711      # On MacOSX there is a readlink tool with a different
29712      # purpose than the GNU readlink tool. Check the found readlink.
29713      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29714      if test "x$ISGNU" = x; then
29715        # A readlink that we do not know how to use.
29716        # Are there other non-GNU readlinks out there?
29717        READLINK_TESTED=yes
29718        READLINK=
29719      fi
29720    fi
29721
29722    if test "x$READLINK" != x; then
29723      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29724    else
29725      # Save the current directory for restoring afterwards
29726      STARTDIR=$PWD
29727      COUNTER=0
29728      sym_link_dir=`$DIRNAME $TEST_COMPILER`
29729      sym_link_file=`$BASENAME $TEST_COMPILER`
29730      cd $sym_link_dir
29731      # Use -P flag to resolve symlinks in directories.
29732      cd `$THEPWDCMD -P`
29733      sym_link_dir=`$THEPWDCMD -P`
29734      # Resolve file symlinks
29735      while test $COUNTER -lt 20; do
29736        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
29737        if test "x$ISLINK" == x; then
29738          # This is not a symbolic link! We are done!
29739          break
29740        fi
29741        # Again resolve directory symlinks since the target of the just found
29742        # link could be in a different directory
29743        cd `$DIRNAME $ISLINK`
29744        sym_link_dir=`$THEPWDCMD -P`
29745        sym_link_file=`$BASENAME $ISLINK`
29746        let COUNTER=COUNTER+1
29747      done
29748      cd $STARTDIR
29749      TEST_COMPILER=$sym_link_dir/$sym_link_file
29750    fi
29751  fi
29752
29753    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
29754$as_echo "$TEST_COMPILER" >&6; }
29755  fi
29756  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
29757$as_echo_n "checking if CXX is disguised ccache... " >&6; }
29758
29759  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
29760  if test "x$COMPILER_BASENAME" = "xccache"; then
29761    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
29762$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
29763    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
29764    # We want to control ccache invocation ourselves, so ignore this cc and try
29765    # searching again.
29766
29767    # Remove the path to the fake ccache cc from the PATH
29768    RETRY_COMPILER_SAVED_PATH="$PATH"
29769    COMPILER_DIRNAME=`$DIRNAME $CXX`
29770    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
29771
29772    # Try again looking for our compiler
29773    if test -n "$ac_tool_prefix"; then
29774  for ac_prog in $TOOLCHAIN_CXX_BINARY
29775  do
29776    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
29777set dummy $ac_tool_prefix$ac_prog; ac_word=$2
29778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29779$as_echo_n "checking for $ac_word... " >&6; }
29780if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
29781  $as_echo_n "(cached) " >&6
29782else
29783  if test -n "$PROPER_COMPILER_CXX"; then
29784  ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
29785else
29786as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29787for as_dir in $PATH
29788do
29789  IFS=$as_save_IFS
29790  test -z "$as_dir" && as_dir=.
29791    for ac_exec_ext in '' $ac_executable_extensions; do
29792  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29793    ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
29794    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29795    break 2
29796  fi
29797done
29798  done
29799IFS=$as_save_IFS
29800
29801fi
29802fi
29803PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
29804if test -n "$PROPER_COMPILER_CXX"; then
29805  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
29806$as_echo "$PROPER_COMPILER_CXX" >&6; }
29807else
29808  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29809$as_echo "no" >&6; }
29810fi
29811
29812
29813    test -n "$PROPER_COMPILER_CXX" && break
29814  done
29815fi
29816if test -z "$PROPER_COMPILER_CXX"; then
29817  ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
29818  for ac_prog in $TOOLCHAIN_CXX_BINARY
29819do
29820  # Extract the first word of "$ac_prog", so it can be a program name with args.
29821set dummy $ac_prog; ac_word=$2
29822{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29823$as_echo_n "checking for $ac_word... " >&6; }
29824if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
29825  $as_echo_n "(cached) " >&6
29826else
29827  if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29828  ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
29829else
29830as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29831for as_dir in $PATH
29832do
29833  IFS=$as_save_IFS
29834  test -z "$as_dir" && as_dir=.
29835    for ac_exec_ext in '' $ac_executable_extensions; do
29836  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29837    ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
29838    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29839    break 2
29840  fi
29841done
29842  done
29843IFS=$as_save_IFS
29844
29845fi
29846fi
29847ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
29848if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29849  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
29850$as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
29851else
29852  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29853$as_echo "no" >&6; }
29854fi
29855
29856
29857  test -n "$ac_ct_PROPER_COMPILER_CXX" && break
29858done
29859
29860  if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
29861    PROPER_COMPILER_CXX=""
29862  else
29863    case $cross_compiling:$ac_tool_warned in
29864yes:)
29865{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
29866$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
29867ac_tool_warned=yes ;;
29868esac
29869    PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
29870  fi
29871fi
29872
29873
29874  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29875
29876  # First separate the path from the arguments. This will split at the first
29877  # space.
29878  complete="$PROPER_COMPILER_CXX"
29879  path="${complete%% *}"
29880  tmp="$complete EOL"
29881  arguments="${tmp#* }"
29882
29883  # Input might be given as Windows format, start by converting to
29884  # unix format.
29885  new_path=`$CYGPATH -u "$path"`
29886
29887  # Now try to locate executable using which
29888  new_path=`$WHICH "$new_path" 2> /dev/null`
29889  # bat and cmd files are not always considered executable in cygwin causing which
29890  # to not find them
29891  if test "x$new_path" = x \
29892      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29893      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29894    new_path=`$CYGPATH -u "$path"`
29895  fi
29896  if test "x$new_path" = x; then
29897    # Oops. Which didn't find the executable.
29898    # The splitting of arguments from the executable at a space might have been incorrect,
29899    # since paths with space are more likely in Windows. Give it another try with the whole
29900    # argument.
29901    path="$complete"
29902    arguments="EOL"
29903    new_path=`$CYGPATH -u "$path"`
29904    new_path=`$WHICH "$new_path" 2> /dev/null`
29905    # bat and cmd files are not always considered executable in cygwin causing which
29906    # to not find them
29907    if test "x$new_path" = x \
29908        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29909        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29910      new_path=`$CYGPATH -u "$path"`
29911    fi
29912    if test "x$new_path" = x; then
29913      # It's still not found. Now this is an unrecoverable error.
29914      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29915$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29916      has_space=`$ECHO "$complete" | $GREP " "`
29917      if test "x$has_space" != x; then
29918        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29919$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29920      fi
29921      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29922    fi
29923  fi
29924
29925  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29926  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29927  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29928  # "foo.exe" is OK but "foo" is an error.
29929  #
29930  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29931  # It is also a way to make sure we got the proper file name for the real test later on.
29932  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29933  if test "x$test_shortpath" = x; then
29934    # Short path failed, file does not exist as specified.
29935    # Try adding .exe or .cmd
29936    if test -f "${new_path}.exe"; then
29937      input_to_shortpath="${new_path}.exe"
29938    elif test -f "${new_path}.cmd"; then
29939      input_to_shortpath="${new_path}.cmd"
29940    else
29941      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
29942$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
29943      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29944$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29945      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29946    fi
29947  else
29948    input_to_shortpath="$new_path"
29949  fi
29950
29951  # Call helper function which possibly converts this using DOS-style short mode.
29952  # If so, the updated path is stored in $new_path.
29953  new_path="$input_to_shortpath"
29954
29955  input_path="$input_to_shortpath"
29956  # Check if we need to convert this using DOS-style short mode. If the path
29957  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29958  # take no chances and rewrite it.
29959  # Note: m4 eats our [], so we need to use [ and ] instead.
29960  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29961  if test "x$has_forbidden_chars" != x; then
29962    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29963    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29964    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29965    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29966      # Going to short mode and back again did indeed matter. Since short mode is
29967      # case insensitive, let's make it lowercase to improve readability.
29968      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29969      # Now convert it back to Unix-stile (cygpath)
29970      input_path=`$CYGPATH -u "$shortmode_path"`
29971      new_path="$input_path"
29972    fi
29973  fi
29974
29975  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29976  if test "x$test_cygdrive_prefix" = x; then
29977    # As a simple fix, exclude /usr/bin since it's not a real path.
29978    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29979      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29980      # a path prefixed by /cygdrive for fixpath to work.
29981      new_path="$CYGWIN_ROOT_PATH$input_path"
29982    fi
29983  fi
29984
29985  # remove trailing .exe if any
29986  new_path="${new_path/%.exe/}"
29987
29988  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29989
29990  # First separate the path from the arguments. This will split at the first
29991  # space.
29992  complete="$PROPER_COMPILER_CXX"
29993  path="${complete%% *}"
29994  tmp="$complete EOL"
29995  arguments="${tmp#* }"
29996
29997  # Input might be given as Windows format, start by converting to
29998  # unix format.
29999  new_path="$path"
30000
30001  windows_path="$new_path"
30002  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30003    unix_path=`$CYGPATH -u "$windows_path"`
30004    new_path="$unix_path"
30005  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30006    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30007    new_path="$unix_path"
30008  fi
30009
30010
30011  # Now try to locate executable using which
30012  new_path=`$WHICH "$new_path" 2> /dev/null`
30013
30014  if test "x$new_path" = x; then
30015    # Oops. Which didn't find the executable.
30016    # The splitting of arguments from the executable at a space might have been incorrect,
30017    # since paths with space are more likely in Windows. Give it another try with the whole
30018    # argument.
30019    path="$complete"
30020    arguments="EOL"
30021    new_path="$path"
30022
30023  windows_path="$new_path"
30024  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30025    unix_path=`$CYGPATH -u "$windows_path"`
30026    new_path="$unix_path"
30027  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30028    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30029    new_path="$unix_path"
30030  fi
30031
30032
30033    new_path=`$WHICH "$new_path" 2> /dev/null`
30034
30035    if test "x$new_path" = x; then
30036      # It's still not found. Now this is an unrecoverable error.
30037      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30038$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30039      has_space=`$ECHO "$complete" | $GREP " "`
30040      if test "x$has_space" != x; then
30041        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30042$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30043      fi
30044      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30045    fi
30046  fi
30047
30048  # Now new_path has a complete unix path to the binary
30049  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30050    # Keep paths in /bin as-is, but remove trailing .exe if any
30051    new_path="${new_path/%.exe/}"
30052    # Do not save /bin paths to all_fixpath_prefixes!
30053  else
30054    # Not in mixed or Windows style, start by that.
30055    new_path=`cmd //c echo $new_path`
30056
30057  input_path="$new_path"
30058  # Check if we need to convert this using DOS-style short mode. If the path
30059  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30060  # take no chances and rewrite it.
30061  # Note: m4 eats our [], so we need to use [ and ] instead.
30062  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30063  if test "x$has_forbidden_chars" != x; then
30064    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30065    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30066  fi
30067
30068    # Output is in $new_path
30069
30070  windows_path="$new_path"
30071  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30072    unix_path=`$CYGPATH -u "$windows_path"`
30073    new_path="$unix_path"
30074  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30075    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30076    new_path="$unix_path"
30077  fi
30078
30079    # remove trailing .exe if any
30080    new_path="${new_path/%.exe/}"
30081
30082    # Save the first 10 bytes of this path to the storage, so fixpath can work.
30083    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30084  fi
30085
30086  else
30087    # We're on a posix platform. Hooray! :)
30088    # First separate the path from the arguments. This will split at the first
30089    # space.
30090    complete="$PROPER_COMPILER_CXX"
30091    path="${complete%% *}"
30092    tmp="$complete EOL"
30093    arguments="${tmp#* }"
30094
30095    # Cannot rely on the command "which" here since it doesn't always work.
30096    is_absolute_path=`$ECHO "$path" | $GREP ^/`
30097    if test -z "$is_absolute_path"; then
30098      # Path to executable is not absolute. Find it.
30099      IFS_save="$IFS"
30100      IFS=:
30101      for p in $PATH; do
30102        if test -f "$p/$path" && test -x "$p/$path"; then
30103          new_path="$p/$path"
30104          break
30105        fi
30106      done
30107      IFS="$IFS_save"
30108    else
30109      # This is an absolute path, we can use it without further modifications.
30110      new_path="$path"
30111    fi
30112
30113    if test "x$new_path" = x; then
30114      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30115$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30116      has_space=`$ECHO "$complete" | $GREP " "`
30117      if test "x$has_space" != x; then
30118        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30119$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30120      fi
30121      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30122    fi
30123  fi
30124
30125  # Now join together the path and the arguments once again
30126  if test "x$arguments" != xEOL; then
30127    new_complete="$new_path ${arguments% *}"
30128  else
30129    new_complete="$new_path"
30130  fi
30131
30132  if test "x$complete" != "x$new_complete"; then
30133    PROPER_COMPILER_CXX="$new_complete"
30134    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
30135$as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
30136  fi
30137
30138    PATH="$RETRY_COMPILER_SAVED_PATH"
30139
30140    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
30141$as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
30142
30143  if test "x$OPENJDK_BUILD_OS" != xwindows; then
30144    # Follow a chain of symbolic links. Use readlink
30145    # where it exists, else fall back to horribly
30146    # complicated shell code.
30147    if test "x$READLINK_TESTED" != yes; then
30148      # On MacOSX there is a readlink tool with a different
30149      # purpose than the GNU readlink tool. Check the found readlink.
30150      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30151      if test "x$ISGNU" = x; then
30152        # A readlink that we do not know how to use.
30153        # Are there other non-GNU readlinks out there?
30154        READLINK_TESTED=yes
30155        READLINK=
30156      fi
30157    fi
30158
30159    if test "x$READLINK" != x; then
30160      PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
30161    else
30162      # Save the current directory for restoring afterwards
30163      STARTDIR=$PWD
30164      COUNTER=0
30165      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
30166      sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
30167      cd $sym_link_dir
30168      # Use -P flag to resolve symlinks in directories.
30169      cd `$THEPWDCMD -P`
30170      sym_link_dir=`$THEPWDCMD -P`
30171      # Resolve file symlinks
30172      while test $COUNTER -lt 20; do
30173        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30174        if test "x$ISLINK" == x; then
30175          # This is not a symbolic link! We are done!
30176          break
30177        fi
30178        # Again resolve directory symlinks since the target of the just found
30179        # link could be in a different directory
30180        cd `$DIRNAME $ISLINK`
30181        sym_link_dir=`$THEPWDCMD -P`
30182        sym_link_file=`$BASENAME $ISLINK`
30183        let COUNTER=COUNTER+1
30184      done
30185      cd $STARTDIR
30186      PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
30187    fi
30188  fi
30189
30190    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30191$as_echo "$PROPER_COMPILER_CXX" >&6; }
30192    CXX="$PROPER_COMPILER_CXX"
30193  else
30194    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
30195$as_echo "no, keeping CXX" >&6; }
30196  fi
30197
30198
30199  COMPILER=$CXX
30200  COMPILER_NAME=$COMPILER_NAME
30201
30202  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
30203    # cc -V output typically looks like
30204    #     cc: Sun C 5.12 Linux_i386 2011/11/16
30205    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
30206    # Check that this is likely to be the Solaris Studio cc.
30207    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30208    if test $? -ne 0; then
30209      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30210      { $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
30211$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30212      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30213$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30214      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30215$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30216      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30217    fi
30218    # Remove usage instructions (if present), and
30219    # collapse compiler output into a single line
30220    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30221        $SED -e 's/ *[Uu]sage:.*//'`
30222    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30223        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
30224  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
30225    # xlc -qversion output typically looks like
30226    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
30227    #     Version: 11.01.0000.0015
30228    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
30229    # Check that this is likely to be the IBM XL C compiler.
30230    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
30231    if test $? -ne 0; then
30232      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30233      { $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
30234$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30235      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30236$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30237      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30238$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30239      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30240    fi
30241    # Collapse compiler output into a single line
30242    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30243    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30244        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
30245  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
30246    # There is no specific version flag, but all output starts with a version string.
30247    # First line typically looks something like:
30248    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30249    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30250    # Check that this is likely to be Microsoft CL.EXE.
30251    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
30252    if test $? -ne 0; then
30253      { $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
30254$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30255      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30256$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30257      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30258    fi
30259    # Collapse compiler output into a single line
30260    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30261    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30262        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
30263  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
30264    # gcc --version output typically looks like
30265    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
30266    #     Copyright (C) 2013 Free Software Foundation, Inc.
30267    #     This is free software; see the source for copying conditions.  There is NO
30268    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30269    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30270    # Check that this is likely to be GCC.
30271    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
30272    if test $? -ne 0; then
30273      { $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
30274$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30275      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
30276$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
30277      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30278    fi
30279    # Remove Copyright and legalese from version string, and
30280    # collapse into a single line
30281    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30282        $SED -e 's/ *Copyright .*//'`
30283    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30284        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
30285  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
30286    # clang --version output typically looks like
30287    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
30288    #    clang version 3.3 (tags/RELEASE_33/final)
30289    # or
30290    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
30291    #    Target: x86_64-pc-linux-gnu
30292    #    Thread model: posix
30293    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30294    # Check that this is likely to be clang
30295    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
30296    if test $? -ne 0; then
30297      { $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
30298$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30299      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30300$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30301      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30302    fi
30303    # Collapse compiler output into a single line
30304    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30305    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30306        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
30307  else
30308      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
30309  fi
30310  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
30311  CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
30312  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
30313  CXX_VERSION_STRING="$COMPILER_VERSION_STRING"
30314
30315  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
30316$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
30317
30318
30319  # Now that we have resolved CXX ourself, let autoconf have its go at it
30320  ac_ext=cpp
30321ac_cpp='$CXXCPP $CPPFLAGS'
30322ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30323ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30324ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30325if test -z "$CXX"; then
30326  if test -n "$CCC"; then
30327    CXX=$CCC
30328  else
30329    if test -n "$ac_tool_prefix"; then
30330  for ac_prog in $CXX
30331  do
30332    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30333set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30334{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30335$as_echo_n "checking for $ac_word... " >&6; }
30336if ${ac_cv_prog_CXX+:} false; then :
30337  $as_echo_n "(cached) " >&6
30338else
30339  if test -n "$CXX"; then
30340  ac_cv_prog_CXX="$CXX" # Let the user override the test.
30341else
30342as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30343for as_dir in $PATH
30344do
30345  IFS=$as_save_IFS
30346  test -z "$as_dir" && as_dir=.
30347    for ac_exec_ext in '' $ac_executable_extensions; do
30348  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30349    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
30350    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30351    break 2
30352  fi
30353done
30354  done
30355IFS=$as_save_IFS
30356
30357fi
30358fi
30359CXX=$ac_cv_prog_CXX
30360if test -n "$CXX"; then
30361  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
30362$as_echo "$CXX" >&6; }
30363else
30364  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30365$as_echo "no" >&6; }
30366fi
30367
30368
30369    test -n "$CXX" && break
30370  done
30371fi
30372if test -z "$CXX"; then
30373  ac_ct_CXX=$CXX
30374  for ac_prog in $CXX
30375do
30376  # Extract the first word of "$ac_prog", so it can be a program name with args.
30377set dummy $ac_prog; ac_word=$2
30378{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30379$as_echo_n "checking for $ac_word... " >&6; }
30380if ${ac_cv_prog_ac_ct_CXX+:} false; then :
30381  $as_echo_n "(cached) " >&6
30382else
30383  if test -n "$ac_ct_CXX"; then
30384  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
30385else
30386as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30387for as_dir in $PATH
30388do
30389  IFS=$as_save_IFS
30390  test -z "$as_dir" && as_dir=.
30391    for ac_exec_ext in '' $ac_executable_extensions; do
30392  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30393    ac_cv_prog_ac_ct_CXX="$ac_prog"
30394    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30395    break 2
30396  fi
30397done
30398  done
30399IFS=$as_save_IFS
30400
30401fi
30402fi
30403ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
30404if test -n "$ac_ct_CXX"; then
30405  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
30406$as_echo "$ac_ct_CXX" >&6; }
30407else
30408  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30409$as_echo "no" >&6; }
30410fi
30411
30412
30413  test -n "$ac_ct_CXX" && break
30414done
30415
30416  if test "x$ac_ct_CXX" = x; then
30417    CXX="g++"
30418  else
30419    case $cross_compiling:$ac_tool_warned in
30420yes:)
30421{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30422$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30423ac_tool_warned=yes ;;
30424esac
30425    CXX=$ac_ct_CXX
30426  fi
30427fi
30428
30429  fi
30430fi
30431# Provide some information about the compiler.
30432$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
30433set X $ac_compile
30434ac_compiler=$2
30435for ac_option in --version -v -V -qversion; do
30436  { { ac_try="$ac_compiler $ac_option >&5"
30437case "(($ac_try" in
30438  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30439  *) ac_try_echo=$ac_try;;
30440esac
30441eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30442$as_echo "$ac_try_echo"; } >&5
30443  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30444  ac_status=$?
30445  if test -s conftest.err; then
30446    sed '10a\
30447... rest of stderr output deleted ...
30448         10q' conftest.err >conftest.er1
30449    cat conftest.er1 >&5
30450  fi
30451  rm -f conftest.er1 conftest.err
30452  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30453  test $ac_status = 0; }
30454done
30455
30456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
30457$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
30458if ${ac_cv_cxx_compiler_gnu+:} false; then :
30459  $as_echo_n "(cached) " >&6
30460else
30461  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30462/* end confdefs.h.  */
30463
30464int
30465main ()
30466{
30467#ifndef __GNUC__
30468       choke me
30469#endif
30470
30471  ;
30472  return 0;
30473}
30474_ACEOF
30475if ac_fn_cxx_try_compile "$LINENO"; then :
30476  ac_compiler_gnu=yes
30477else
30478  ac_compiler_gnu=no
30479fi
30480rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30481ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
30482
30483fi
30484{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
30485$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
30486if test $ac_compiler_gnu = yes; then
30487  GXX=yes
30488else
30489  GXX=
30490fi
30491ac_test_CXXFLAGS=${CXXFLAGS+set}
30492ac_save_CXXFLAGS=$CXXFLAGS
30493{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
30494$as_echo_n "checking whether $CXX accepts -g... " >&6; }
30495if ${ac_cv_prog_cxx_g+:} false; then :
30496  $as_echo_n "(cached) " >&6
30497else
30498  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
30499   ac_cxx_werror_flag=yes
30500   ac_cv_prog_cxx_g=no
30501   CXXFLAGS="-g"
30502   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30503/* end confdefs.h.  */
30504
30505int
30506main ()
30507{
30508
30509  ;
30510  return 0;
30511}
30512_ACEOF
30513if ac_fn_cxx_try_compile "$LINENO"; then :
30514  ac_cv_prog_cxx_g=yes
30515else
30516  CXXFLAGS=""
30517      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30518/* end confdefs.h.  */
30519
30520int
30521main ()
30522{
30523
30524  ;
30525  return 0;
30526}
30527_ACEOF
30528if ac_fn_cxx_try_compile "$LINENO"; then :
30529
30530else
30531  ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30532	 CXXFLAGS="-g"
30533	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30534/* end confdefs.h.  */
30535
30536int
30537main ()
30538{
30539
30540  ;
30541  return 0;
30542}
30543_ACEOF
30544if ac_fn_cxx_try_compile "$LINENO"; then :
30545  ac_cv_prog_cxx_g=yes
30546fi
30547rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30548fi
30549rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30550fi
30551rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30552   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30553fi
30554{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
30555$as_echo "$ac_cv_prog_cxx_g" >&6; }
30556if test "$ac_test_CXXFLAGS" = set; then
30557  CXXFLAGS=$ac_save_CXXFLAGS
30558elif test $ac_cv_prog_cxx_g = yes; then
30559  if test "$GXX" = yes; then
30560    CXXFLAGS="-g -O2"
30561  else
30562    CXXFLAGS="-g"
30563  fi
30564else
30565  if test "$GXX" = yes; then
30566    CXXFLAGS="-O2"
30567  else
30568    CXXFLAGS=
30569  fi
30570fi
30571ac_ext=cpp
30572ac_cpp='$CXXCPP $CPPFLAGS'
30573ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30574ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30575ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30576
30577
30578  #
30579  # Setup the preprocessor (CPP and CXXCPP)
30580  #
30581  ac_ext=c
30582ac_cpp='$CPP $CPPFLAGS'
30583ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30584ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30585ac_compiler_gnu=$ac_cv_c_compiler_gnu
30586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
30587$as_echo_n "checking how to run the C preprocessor... " >&6; }
30588# On Suns, sometimes $CPP names a directory.
30589if test -n "$CPP" && test -d "$CPP"; then
30590  CPP=
30591fi
30592if test -z "$CPP"; then
30593  if ${ac_cv_prog_CPP+:} false; then :
30594  $as_echo_n "(cached) " >&6
30595else
30596      # Double quotes because CPP needs to be expanded
30597    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
30598    do
30599      ac_preproc_ok=false
30600for ac_c_preproc_warn_flag in '' yes
30601do
30602  # Use a header file that comes with gcc, so configuring glibc
30603  # with a fresh cross-compiler works.
30604  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30605  # <limits.h> exists even on freestanding compilers.
30606  # On the NeXT, cc -E runs the code through the compiler's parser,
30607  # not just through cpp. "Syntax error" is here to catch this case.
30608  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30609/* end confdefs.h.  */
30610#ifdef __STDC__
30611# include <limits.h>
30612#else
30613# include <assert.h>
30614#endif
30615		     Syntax error
30616_ACEOF
30617if ac_fn_c_try_cpp "$LINENO"; then :
30618
30619else
30620  # Broken: fails on valid input.
30621continue
30622fi
30623rm -f conftest.err conftest.i conftest.$ac_ext
30624
30625  # OK, works on sane cases.  Now check whether nonexistent headers
30626  # can be detected and how.
30627  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30628/* end confdefs.h.  */
30629#include <ac_nonexistent.h>
30630_ACEOF
30631if ac_fn_c_try_cpp "$LINENO"; then :
30632  # Broken: success on invalid input.
30633continue
30634else
30635  # Passes both tests.
30636ac_preproc_ok=:
30637break
30638fi
30639rm -f conftest.err conftest.i conftest.$ac_ext
30640
30641done
30642# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30643rm -f conftest.i conftest.err conftest.$ac_ext
30644if $ac_preproc_ok; then :
30645  break
30646fi
30647
30648    done
30649    ac_cv_prog_CPP=$CPP
30650
30651fi
30652  CPP=$ac_cv_prog_CPP
30653else
30654  ac_cv_prog_CPP=$CPP
30655fi
30656{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
30657$as_echo "$CPP" >&6; }
30658ac_preproc_ok=false
30659for ac_c_preproc_warn_flag in '' yes
30660do
30661  # Use a header file that comes with gcc, so configuring glibc
30662  # with a fresh cross-compiler works.
30663  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30664  # <limits.h> exists even on freestanding compilers.
30665  # On the NeXT, cc -E runs the code through the compiler's parser,
30666  # not just through cpp. "Syntax error" is here to catch this case.
30667  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30668/* end confdefs.h.  */
30669#ifdef __STDC__
30670# include <limits.h>
30671#else
30672# include <assert.h>
30673#endif
30674		     Syntax error
30675_ACEOF
30676if ac_fn_c_try_cpp "$LINENO"; then :
30677
30678else
30679  # Broken: fails on valid input.
30680continue
30681fi
30682rm -f conftest.err conftest.i conftest.$ac_ext
30683
30684  # OK, works on sane cases.  Now check whether nonexistent headers
30685  # can be detected and how.
30686  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30687/* end confdefs.h.  */
30688#include <ac_nonexistent.h>
30689_ACEOF
30690if ac_fn_c_try_cpp "$LINENO"; then :
30691  # Broken: success on invalid input.
30692continue
30693else
30694  # Passes both tests.
30695ac_preproc_ok=:
30696break
30697fi
30698rm -f conftest.err conftest.i conftest.$ac_ext
30699
30700done
30701# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30702rm -f conftest.i conftest.err conftest.$ac_ext
30703if $ac_preproc_ok; then :
30704
30705else
30706  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30707$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30708as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
30709See \`config.log' for more details" "$LINENO" 5; }
30710fi
30711
30712ac_ext=cpp
30713ac_cpp='$CXXCPP $CPPFLAGS'
30714ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30715ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30716ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30717
30718
30719  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30720
30721  # First separate the path from the arguments. This will split at the first
30722  # space.
30723  complete="$CPP"
30724  path="${complete%% *}"
30725  tmp="$complete EOL"
30726  arguments="${tmp#* }"
30727
30728  # Input might be given as Windows format, start by converting to
30729  # unix format.
30730  new_path=`$CYGPATH -u "$path"`
30731
30732  # Now try to locate executable using which
30733  new_path=`$WHICH "$new_path" 2> /dev/null`
30734  # bat and cmd files are not always considered executable in cygwin causing which
30735  # to not find them
30736  if test "x$new_path" = x \
30737      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30738      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30739    new_path=`$CYGPATH -u "$path"`
30740  fi
30741  if test "x$new_path" = x; then
30742    # Oops. Which didn't find the executable.
30743    # The splitting of arguments from the executable at a space might have been incorrect,
30744    # since paths with space are more likely in Windows. Give it another try with the whole
30745    # argument.
30746    path="$complete"
30747    arguments="EOL"
30748    new_path=`$CYGPATH -u "$path"`
30749    new_path=`$WHICH "$new_path" 2> /dev/null`
30750    # bat and cmd files are not always considered executable in cygwin causing which
30751    # to not find them
30752    if test "x$new_path" = x \
30753        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30754        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30755      new_path=`$CYGPATH -u "$path"`
30756    fi
30757    if test "x$new_path" = x; then
30758      # It's still not found. Now this is an unrecoverable error.
30759      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30760$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30761      has_space=`$ECHO "$complete" | $GREP " "`
30762      if test "x$has_space" != x; then
30763        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30764$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30765      fi
30766      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30767    fi
30768  fi
30769
30770  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30771  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30772  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30773  # "foo.exe" is OK but "foo" is an error.
30774  #
30775  # This test is therefore slightly more accurate than "test -f" to check for file presence.
30776  # It is also a way to make sure we got the proper file name for the real test later on.
30777  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30778  if test "x$test_shortpath" = x; then
30779    # Short path failed, file does not exist as specified.
30780    # Try adding .exe or .cmd
30781    if test -f "${new_path}.exe"; then
30782      input_to_shortpath="${new_path}.exe"
30783    elif test -f "${new_path}.cmd"; then
30784      input_to_shortpath="${new_path}.cmd"
30785    else
30786      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
30787$as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
30788      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30789$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30790      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30791    fi
30792  else
30793    input_to_shortpath="$new_path"
30794  fi
30795
30796  # Call helper function which possibly converts this using DOS-style short mode.
30797  # If so, the updated path is stored in $new_path.
30798  new_path="$input_to_shortpath"
30799
30800  input_path="$input_to_shortpath"
30801  # Check if we need to convert this using DOS-style short mode. If the path
30802  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30803  # take no chances and rewrite it.
30804  # Note: m4 eats our [], so we need to use [ and ] instead.
30805  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30806  if test "x$has_forbidden_chars" != x; then
30807    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30808    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30809    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30810    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30811      # Going to short mode and back again did indeed matter. Since short mode is
30812      # case insensitive, let's make it lowercase to improve readability.
30813      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30814      # Now convert it back to Unix-stile (cygpath)
30815      input_path=`$CYGPATH -u "$shortmode_path"`
30816      new_path="$input_path"
30817    fi
30818  fi
30819
30820  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30821  if test "x$test_cygdrive_prefix" = x; then
30822    # As a simple fix, exclude /usr/bin since it's not a real path.
30823    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30824      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30825      # a path prefixed by /cygdrive for fixpath to work.
30826      new_path="$CYGWIN_ROOT_PATH$input_path"
30827    fi
30828  fi
30829
30830  # remove trailing .exe if any
30831  new_path="${new_path/%.exe/}"
30832
30833  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30834
30835  # First separate the path from the arguments. This will split at the first
30836  # space.
30837  complete="$CPP"
30838  path="${complete%% *}"
30839  tmp="$complete EOL"
30840  arguments="${tmp#* }"
30841
30842  # Input might be given as Windows format, start by converting to
30843  # unix format.
30844  new_path="$path"
30845
30846  windows_path="$new_path"
30847  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30848    unix_path=`$CYGPATH -u "$windows_path"`
30849    new_path="$unix_path"
30850  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30851    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30852    new_path="$unix_path"
30853  fi
30854
30855
30856  # Now try to locate executable using which
30857  new_path=`$WHICH "$new_path" 2> /dev/null`
30858
30859  if test "x$new_path" = x; then
30860    # Oops. Which didn't find the executable.
30861    # The splitting of arguments from the executable at a space might have been incorrect,
30862    # since paths with space are more likely in Windows. Give it another try with the whole
30863    # argument.
30864    path="$complete"
30865    arguments="EOL"
30866    new_path="$path"
30867
30868  windows_path="$new_path"
30869  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30870    unix_path=`$CYGPATH -u "$windows_path"`
30871    new_path="$unix_path"
30872  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30873    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30874    new_path="$unix_path"
30875  fi
30876
30877
30878    new_path=`$WHICH "$new_path" 2> /dev/null`
30879
30880    if test "x$new_path" = x; then
30881      # It's still not found. Now this is an unrecoverable error.
30882      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30883$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30884      has_space=`$ECHO "$complete" | $GREP " "`
30885      if test "x$has_space" != x; then
30886        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30887$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30888      fi
30889      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30890    fi
30891  fi
30892
30893  # Now new_path has a complete unix path to the binary
30894  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30895    # Keep paths in /bin as-is, but remove trailing .exe if any
30896    new_path="${new_path/%.exe/}"
30897    # Do not save /bin paths to all_fixpath_prefixes!
30898  else
30899    # Not in mixed or Windows style, start by that.
30900    new_path=`cmd //c echo $new_path`
30901
30902  input_path="$new_path"
30903  # Check if we need to convert this using DOS-style short mode. If the path
30904  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30905  # take no chances and rewrite it.
30906  # Note: m4 eats our [], so we need to use [ and ] instead.
30907  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30908  if test "x$has_forbidden_chars" != x; then
30909    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30910    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30911  fi
30912
30913    # Output is in $new_path
30914
30915  windows_path="$new_path"
30916  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30917    unix_path=`$CYGPATH -u "$windows_path"`
30918    new_path="$unix_path"
30919  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30920    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30921    new_path="$unix_path"
30922  fi
30923
30924    # remove trailing .exe if any
30925    new_path="${new_path/%.exe/}"
30926
30927    # Save the first 10 bytes of this path to the storage, so fixpath can work.
30928    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30929  fi
30930
30931  else
30932    # We're on a posix platform. Hooray! :)
30933    # First separate the path from the arguments. This will split at the first
30934    # space.
30935    complete="$CPP"
30936    path="${complete%% *}"
30937    tmp="$complete EOL"
30938    arguments="${tmp#* }"
30939
30940    # Cannot rely on the command "which" here since it doesn't always work.
30941    is_absolute_path=`$ECHO "$path" | $GREP ^/`
30942    if test -z "$is_absolute_path"; then
30943      # Path to executable is not absolute. Find it.
30944      IFS_save="$IFS"
30945      IFS=:
30946      for p in $PATH; do
30947        if test -f "$p/$path" && test -x "$p/$path"; then
30948          new_path="$p/$path"
30949          break
30950        fi
30951      done
30952      IFS="$IFS_save"
30953    else
30954      # This is an absolute path, we can use it without further modifications.
30955      new_path="$path"
30956    fi
30957
30958    if test "x$new_path" = x; then
30959      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30960$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30961      has_space=`$ECHO "$complete" | $GREP " "`
30962      if test "x$has_space" != x; then
30963        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30964$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30965      fi
30966      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30967    fi
30968  fi
30969
30970  # Now join together the path and the arguments once again
30971  if test "x$arguments" != xEOL; then
30972    new_complete="$new_path ${arguments% *}"
30973  else
30974    new_complete="$new_path"
30975  fi
30976
30977  if test "x$complete" != "x$new_complete"; then
30978    CPP="$new_complete"
30979    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
30980$as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
30981  fi
30982
30983  ac_ext=cpp
30984ac_cpp='$CXXCPP $CPPFLAGS'
30985ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30986ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30987ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30988{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
30989$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
30990if test -z "$CXXCPP"; then
30991  if ${ac_cv_prog_CXXCPP+:} false; then :
30992  $as_echo_n "(cached) " >&6
30993else
30994      # Double quotes because CXXCPP needs to be expanded
30995    for CXXCPP in "$CXX -E" "/lib/cpp"
30996    do
30997      ac_preproc_ok=false
30998for ac_cxx_preproc_warn_flag in '' yes
30999do
31000  # Use a header file that comes with gcc, so configuring glibc
31001  # with a fresh cross-compiler works.
31002  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31003  # <limits.h> exists even on freestanding compilers.
31004  # On the NeXT, cc -E runs the code through the compiler's parser,
31005  # not just through cpp. "Syntax error" is here to catch this case.
31006  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31007/* end confdefs.h.  */
31008#ifdef __STDC__
31009# include <limits.h>
31010#else
31011# include <assert.h>
31012#endif
31013		     Syntax error
31014_ACEOF
31015if ac_fn_cxx_try_cpp "$LINENO"; then :
31016
31017else
31018  # Broken: fails on valid input.
31019continue
31020fi
31021rm -f conftest.err conftest.i conftest.$ac_ext
31022
31023  # OK, works on sane cases.  Now check whether nonexistent headers
31024  # can be detected and how.
31025  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31026/* end confdefs.h.  */
31027#include <ac_nonexistent.h>
31028_ACEOF
31029if ac_fn_cxx_try_cpp "$LINENO"; then :
31030  # Broken: success on invalid input.
31031continue
31032else
31033  # Passes both tests.
31034ac_preproc_ok=:
31035break
31036fi
31037rm -f conftest.err conftest.i conftest.$ac_ext
31038
31039done
31040# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
31041rm -f conftest.i conftest.err conftest.$ac_ext
31042if $ac_preproc_ok; then :
31043  break
31044fi
31045
31046    done
31047    ac_cv_prog_CXXCPP=$CXXCPP
31048
31049fi
31050  CXXCPP=$ac_cv_prog_CXXCPP
31051else
31052  ac_cv_prog_CXXCPP=$CXXCPP
31053fi
31054{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
31055$as_echo "$CXXCPP" >&6; }
31056ac_preproc_ok=false
31057for ac_cxx_preproc_warn_flag in '' yes
31058do
31059  # Use a header file that comes with gcc, so configuring glibc
31060  # with a fresh cross-compiler works.
31061  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31062  # <limits.h> exists even on freestanding compilers.
31063  # On the NeXT, cc -E runs the code through the compiler's parser,
31064  # not just through cpp. "Syntax error" is here to catch this case.
31065  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31066/* end confdefs.h.  */
31067#ifdef __STDC__
31068# include <limits.h>
31069#else
31070# include <assert.h>
31071#endif
31072		     Syntax error
31073_ACEOF
31074if ac_fn_cxx_try_cpp "$LINENO"; then :
31075
31076else
31077  # Broken: fails on valid input.
31078continue
31079fi
31080rm -f conftest.err conftest.i conftest.$ac_ext
31081
31082  # OK, works on sane cases.  Now check whether nonexistent headers
31083  # can be detected and how.
31084  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31085/* end confdefs.h.  */
31086#include <ac_nonexistent.h>
31087_ACEOF
31088if ac_fn_cxx_try_cpp "$LINENO"; then :
31089  # Broken: success on invalid input.
31090continue
31091else
31092  # Passes both tests.
31093ac_preproc_ok=:
31094break
31095fi
31096rm -f conftest.err conftest.i conftest.$ac_ext
31097
31098done
31099# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
31100rm -f conftest.i conftest.err conftest.$ac_ext
31101if $ac_preproc_ok; then :
31102
31103else
31104  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
31105$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
31106as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
31107See \`config.log' for more details" "$LINENO" 5; }
31108fi
31109
31110ac_ext=cpp
31111ac_cpp='$CXXCPP $CPPFLAGS'
31112ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
31113ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
31114ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
31115
31116
31117  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31118
31119  # First separate the path from the arguments. This will split at the first
31120  # space.
31121  complete="$CXXCPP"
31122  path="${complete%% *}"
31123  tmp="$complete EOL"
31124  arguments="${tmp#* }"
31125
31126  # Input might be given as Windows format, start by converting to
31127  # unix format.
31128  new_path=`$CYGPATH -u "$path"`
31129
31130  # Now try to locate executable using which
31131  new_path=`$WHICH "$new_path" 2> /dev/null`
31132  # bat and cmd files are not always considered executable in cygwin causing which
31133  # to not find them
31134  if test "x$new_path" = x \
31135      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31136      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31137    new_path=`$CYGPATH -u "$path"`
31138  fi
31139  if test "x$new_path" = x; then
31140    # Oops. Which didn't find the executable.
31141    # The splitting of arguments from the executable at a space might have been incorrect,
31142    # since paths with space are more likely in Windows. Give it another try with the whole
31143    # argument.
31144    path="$complete"
31145    arguments="EOL"
31146    new_path=`$CYGPATH -u "$path"`
31147    new_path=`$WHICH "$new_path" 2> /dev/null`
31148    # bat and cmd files are not always considered executable in cygwin causing which
31149    # to not find them
31150    if test "x$new_path" = x \
31151        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31152        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31153      new_path=`$CYGPATH -u "$path"`
31154    fi
31155    if test "x$new_path" = x; then
31156      # It's still not found. Now this is an unrecoverable error.
31157      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31158$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31159      has_space=`$ECHO "$complete" | $GREP " "`
31160      if test "x$has_space" != x; then
31161        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31162$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31163      fi
31164      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31165    fi
31166  fi
31167
31168  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31169  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31170  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31171  # "foo.exe" is OK but "foo" is an error.
31172  #
31173  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31174  # It is also a way to make sure we got the proper file name for the real test later on.
31175  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31176  if test "x$test_shortpath" = x; then
31177    # Short path failed, file does not exist as specified.
31178    # Try adding .exe or .cmd
31179    if test -f "${new_path}.exe"; then
31180      input_to_shortpath="${new_path}.exe"
31181    elif test -f "${new_path}.cmd"; then
31182      input_to_shortpath="${new_path}.cmd"
31183    else
31184      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
31185$as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
31186      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31187$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31188      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31189    fi
31190  else
31191    input_to_shortpath="$new_path"
31192  fi
31193
31194  # Call helper function which possibly converts this using DOS-style short mode.
31195  # If so, the updated path is stored in $new_path.
31196  new_path="$input_to_shortpath"
31197
31198  input_path="$input_to_shortpath"
31199  # Check if we need to convert this using DOS-style short mode. If the path
31200  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31201  # take no chances and rewrite it.
31202  # Note: m4 eats our [], so we need to use [ and ] instead.
31203  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31204  if test "x$has_forbidden_chars" != x; then
31205    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31206    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31207    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31208    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31209      # Going to short mode and back again did indeed matter. Since short mode is
31210      # case insensitive, let's make it lowercase to improve readability.
31211      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31212      # Now convert it back to Unix-stile (cygpath)
31213      input_path=`$CYGPATH -u "$shortmode_path"`
31214      new_path="$input_path"
31215    fi
31216  fi
31217
31218  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31219  if test "x$test_cygdrive_prefix" = x; then
31220    # As a simple fix, exclude /usr/bin since it's not a real path.
31221    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31222      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31223      # a path prefixed by /cygdrive for fixpath to work.
31224      new_path="$CYGWIN_ROOT_PATH$input_path"
31225    fi
31226  fi
31227
31228  # remove trailing .exe if any
31229  new_path="${new_path/%.exe/}"
31230
31231  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31232
31233  # First separate the path from the arguments. This will split at the first
31234  # space.
31235  complete="$CXXCPP"
31236  path="${complete%% *}"
31237  tmp="$complete EOL"
31238  arguments="${tmp#* }"
31239
31240  # Input might be given as Windows format, start by converting to
31241  # unix format.
31242  new_path="$path"
31243
31244  windows_path="$new_path"
31245  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31246    unix_path=`$CYGPATH -u "$windows_path"`
31247    new_path="$unix_path"
31248  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31249    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31250    new_path="$unix_path"
31251  fi
31252
31253
31254  # Now try to locate executable using which
31255  new_path=`$WHICH "$new_path" 2> /dev/null`
31256
31257  if test "x$new_path" = x; then
31258    # Oops. Which didn't find the executable.
31259    # The splitting of arguments from the executable at a space might have been incorrect,
31260    # since paths with space are more likely in Windows. Give it another try with the whole
31261    # argument.
31262    path="$complete"
31263    arguments="EOL"
31264    new_path="$path"
31265
31266  windows_path="$new_path"
31267  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31268    unix_path=`$CYGPATH -u "$windows_path"`
31269    new_path="$unix_path"
31270  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31271    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31272    new_path="$unix_path"
31273  fi
31274
31275
31276    new_path=`$WHICH "$new_path" 2> /dev/null`
31277
31278    if test "x$new_path" = x; then
31279      # It's still not found. Now this is an unrecoverable error.
31280      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31281$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31282      has_space=`$ECHO "$complete" | $GREP " "`
31283      if test "x$has_space" != x; then
31284        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31285$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31286      fi
31287      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31288    fi
31289  fi
31290
31291  # Now new_path has a complete unix path to the binary
31292  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31293    # Keep paths in /bin as-is, but remove trailing .exe if any
31294    new_path="${new_path/%.exe/}"
31295    # Do not save /bin paths to all_fixpath_prefixes!
31296  else
31297    # Not in mixed or Windows style, start by that.
31298    new_path=`cmd //c echo $new_path`
31299
31300  input_path="$new_path"
31301  # Check if we need to convert this using DOS-style short mode. If the path
31302  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31303  # take no chances and rewrite it.
31304  # Note: m4 eats our [], so we need to use [ and ] instead.
31305  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31306  if test "x$has_forbidden_chars" != x; then
31307    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31308    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31309  fi
31310
31311    # Output is in $new_path
31312
31313  windows_path="$new_path"
31314  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31315    unix_path=`$CYGPATH -u "$windows_path"`
31316    new_path="$unix_path"
31317  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31318    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31319    new_path="$unix_path"
31320  fi
31321
31322    # remove trailing .exe if any
31323    new_path="${new_path/%.exe/}"
31324
31325    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31326    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31327  fi
31328
31329  else
31330    # We're on a posix platform. Hooray! :)
31331    # First separate the path from the arguments. This will split at the first
31332    # space.
31333    complete="$CXXCPP"
31334    path="${complete%% *}"
31335    tmp="$complete EOL"
31336    arguments="${tmp#* }"
31337
31338    # Cannot rely on the command "which" here since it doesn't always work.
31339    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31340    if test -z "$is_absolute_path"; then
31341      # Path to executable is not absolute. Find it.
31342      IFS_save="$IFS"
31343      IFS=:
31344      for p in $PATH; do
31345        if test -f "$p/$path" && test -x "$p/$path"; then
31346          new_path="$p/$path"
31347          break
31348        fi
31349      done
31350      IFS="$IFS_save"
31351    else
31352      # This is an absolute path, we can use it without further modifications.
31353      new_path="$path"
31354    fi
31355
31356    if test "x$new_path" = x; then
31357      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31358$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31359      has_space=`$ECHO "$complete" | $GREP " "`
31360      if test "x$has_space" != x; then
31361        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31362$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31363      fi
31364      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31365    fi
31366  fi
31367
31368  # Now join together the path and the arguments once again
31369  if test "x$arguments" != xEOL; then
31370    new_complete="$new_path ${arguments% *}"
31371  else
31372    new_complete="$new_path"
31373  fi
31374
31375  if test "x$complete" != "x$new_complete"; then
31376    CXXCPP="$new_complete"
31377    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
31378$as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
31379  fi
31380
31381
31382  #
31383  # Setup the linker (LD)
31384  #
31385  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
31386    # In the Microsoft toolchain we have a separate LD command "link".
31387    # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is
31388    # a cygwin program for something completely different.
31389    # Extract the first word of "link", so it can be a program name with args.
31390set dummy link; ac_word=$2
31391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31392$as_echo_n "checking for $ac_word... " >&6; }
31393if ${ac_cv_prog_LD+:} false; then :
31394  $as_echo_n "(cached) " >&6
31395else
31396  if test -n "$LD"; then
31397  ac_cv_prog_LD="$LD" # Let the user override the test.
31398else
31399  ac_prog_rejected=no
31400as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31401for as_dir in $PATH
31402do
31403  IFS=$as_save_IFS
31404  test -z "$as_dir" && as_dir=.
31405    for ac_exec_ext in '' $ac_executable_extensions; do
31406  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31407    if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
31408       ac_prog_rejected=yes
31409       continue
31410     fi
31411    ac_cv_prog_LD="link"
31412    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31413    break 2
31414  fi
31415done
31416  done
31417IFS=$as_save_IFS
31418
31419if test $ac_prog_rejected = yes; then
31420  # We found a bogon in the path, so make sure we never use it.
31421  set dummy $ac_cv_prog_LD
31422  shift
31423  if test $# != 0; then
31424    # We chose a different compiler from the bogus one.
31425    # However, it has the same basename, so the bogon will be chosen
31426    # first if we set LD to just the basename; use the full file name.
31427    shift
31428    ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@"
31429  fi
31430fi
31431fi
31432fi
31433LD=$ac_cv_prog_LD
31434if test -n "$LD"; then
31435  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
31436$as_echo "$LD" >&6; }
31437else
31438  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31439$as_echo "no" >&6; }
31440fi
31441
31442
31443
31444  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31445
31446  # First separate the path from the arguments. This will split at the first
31447  # space.
31448  complete="$LD"
31449  path="${complete%% *}"
31450  tmp="$complete EOL"
31451  arguments="${tmp#* }"
31452
31453  # Input might be given as Windows format, start by converting to
31454  # unix format.
31455  new_path=`$CYGPATH -u "$path"`
31456
31457  # Now try to locate executable using which
31458  new_path=`$WHICH "$new_path" 2> /dev/null`
31459  # bat and cmd files are not always considered executable in cygwin causing which
31460  # to not find them
31461  if test "x$new_path" = x \
31462      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31463      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31464    new_path=`$CYGPATH -u "$path"`
31465  fi
31466  if test "x$new_path" = x; then
31467    # Oops. Which didn't find the executable.
31468    # The splitting of arguments from the executable at a space might have been incorrect,
31469    # since paths with space are more likely in Windows. Give it another try with the whole
31470    # argument.
31471    path="$complete"
31472    arguments="EOL"
31473    new_path=`$CYGPATH -u "$path"`
31474    new_path=`$WHICH "$new_path" 2> /dev/null`
31475    # bat and cmd files are not always considered executable in cygwin causing which
31476    # to not find them
31477    if test "x$new_path" = x \
31478        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31479        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31480      new_path=`$CYGPATH -u "$path"`
31481    fi
31482    if test "x$new_path" = x; then
31483      # It's still not found. Now this is an unrecoverable error.
31484      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31485$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31486      has_space=`$ECHO "$complete" | $GREP " "`
31487      if test "x$has_space" != x; then
31488        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31489$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31490      fi
31491      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31492    fi
31493  fi
31494
31495  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31496  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31497  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31498  # "foo.exe" is OK but "foo" is an error.
31499  #
31500  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31501  # It is also a way to make sure we got the proper file name for the real test later on.
31502  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31503  if test "x$test_shortpath" = x; then
31504    # Short path failed, file does not exist as specified.
31505    # Try adding .exe or .cmd
31506    if test -f "${new_path}.exe"; then
31507      input_to_shortpath="${new_path}.exe"
31508    elif test -f "${new_path}.cmd"; then
31509      input_to_shortpath="${new_path}.cmd"
31510    else
31511      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5
31512$as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;}
31513      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31514$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31515      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31516    fi
31517  else
31518    input_to_shortpath="$new_path"
31519  fi
31520
31521  # Call helper function which possibly converts this using DOS-style short mode.
31522  # If so, the updated path is stored in $new_path.
31523  new_path="$input_to_shortpath"
31524
31525  input_path="$input_to_shortpath"
31526  # Check if we need to convert this using DOS-style short mode. If the path
31527  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31528  # take no chances and rewrite it.
31529  # Note: m4 eats our [], so we need to use [ and ] instead.
31530  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31531  if test "x$has_forbidden_chars" != x; then
31532    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31533    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31534    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31535    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31536      # Going to short mode and back again did indeed matter. Since short mode is
31537      # case insensitive, let's make it lowercase to improve readability.
31538      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31539      # Now convert it back to Unix-stile (cygpath)
31540      input_path=`$CYGPATH -u "$shortmode_path"`
31541      new_path="$input_path"
31542    fi
31543  fi
31544
31545  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31546  if test "x$test_cygdrive_prefix" = x; then
31547    # As a simple fix, exclude /usr/bin since it's not a real path.
31548    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31549      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31550      # a path prefixed by /cygdrive for fixpath to work.
31551      new_path="$CYGWIN_ROOT_PATH$input_path"
31552    fi
31553  fi
31554
31555  # remove trailing .exe if any
31556  new_path="${new_path/%.exe/}"
31557
31558  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31559
31560  # First separate the path from the arguments. This will split at the first
31561  # space.
31562  complete="$LD"
31563  path="${complete%% *}"
31564  tmp="$complete EOL"
31565  arguments="${tmp#* }"
31566
31567  # Input might be given as Windows format, start by converting to
31568  # unix format.
31569  new_path="$path"
31570
31571  windows_path="$new_path"
31572  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31573    unix_path=`$CYGPATH -u "$windows_path"`
31574    new_path="$unix_path"
31575  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31576    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31577    new_path="$unix_path"
31578  fi
31579
31580
31581  # Now try to locate executable using which
31582  new_path=`$WHICH "$new_path" 2> /dev/null`
31583
31584  if test "x$new_path" = x; then
31585    # Oops. Which didn't find the executable.
31586    # The splitting of arguments from the executable at a space might have been incorrect,
31587    # since paths with space are more likely in Windows. Give it another try with the whole
31588    # argument.
31589    path="$complete"
31590    arguments="EOL"
31591    new_path="$path"
31592
31593  windows_path="$new_path"
31594  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31595    unix_path=`$CYGPATH -u "$windows_path"`
31596    new_path="$unix_path"
31597  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31598    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31599    new_path="$unix_path"
31600  fi
31601
31602
31603    new_path=`$WHICH "$new_path" 2> /dev/null`
31604
31605    if test "x$new_path" = x; then
31606      # It's still not found. Now this is an unrecoverable error.
31607      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31608$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31609      has_space=`$ECHO "$complete" | $GREP " "`
31610      if test "x$has_space" != x; then
31611        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31612$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31613      fi
31614      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31615    fi
31616  fi
31617
31618  # Now new_path has a complete unix path to the binary
31619  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31620    # Keep paths in /bin as-is, but remove trailing .exe if any
31621    new_path="${new_path/%.exe/}"
31622    # Do not save /bin paths to all_fixpath_prefixes!
31623  else
31624    # Not in mixed or Windows style, start by that.
31625    new_path=`cmd //c echo $new_path`
31626
31627  input_path="$new_path"
31628  # Check if we need to convert this using DOS-style short mode. If the path
31629  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31630  # take no chances and rewrite it.
31631  # Note: m4 eats our [], so we need to use [ and ] instead.
31632  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31633  if test "x$has_forbidden_chars" != x; then
31634    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31635    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31636  fi
31637
31638    # Output is in $new_path
31639
31640  windows_path="$new_path"
31641  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31642    unix_path=`$CYGPATH -u "$windows_path"`
31643    new_path="$unix_path"
31644  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31645    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31646    new_path="$unix_path"
31647  fi
31648
31649    # remove trailing .exe if any
31650    new_path="${new_path/%.exe/}"
31651
31652    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31653    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31654  fi
31655
31656  else
31657    # We're on a posix platform. Hooray! :)
31658    # First separate the path from the arguments. This will split at the first
31659    # space.
31660    complete="$LD"
31661    path="${complete%% *}"
31662    tmp="$complete EOL"
31663    arguments="${tmp#* }"
31664
31665    # Cannot rely on the command "which" here since it doesn't always work.
31666    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31667    if test -z "$is_absolute_path"; then
31668      # Path to executable is not absolute. Find it.
31669      IFS_save="$IFS"
31670      IFS=:
31671      for p in $PATH; do
31672        if test -f "$p/$path" && test -x "$p/$path"; then
31673          new_path="$p/$path"
31674          break
31675        fi
31676      done
31677      IFS="$IFS_save"
31678    else
31679      # This is an absolute path, we can use it without further modifications.
31680      new_path="$path"
31681    fi
31682
31683    if test "x$new_path" = x; then
31684      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31685$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31686      has_space=`$ECHO "$complete" | $GREP " "`
31687      if test "x$has_space" != x; then
31688        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31689$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31690      fi
31691      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31692    fi
31693  fi
31694
31695  # Now join together the path and the arguments once again
31696  if test "x$arguments" != xEOL; then
31697    new_complete="$new_path ${arguments% *}"
31698  else
31699    new_complete="$new_path"
31700  fi
31701
31702  if test "x$complete" != "x$new_complete"; then
31703    LD="$new_complete"
31704    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5
31705$as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;}
31706  fi
31707
31708    # Verify that we indeed succeeded with this trick.
31709    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
31710$as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
31711    "$LD" --version > /dev/null
31712    if test $? -eq 0 ; then
31713      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31714$as_echo "no" >&6; }
31715      as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
31716    else
31717      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31718$as_echo "yes" >&6; }
31719    fi
31720    LDCXX="$LD"
31721  else
31722    # All other toolchains use the compiler to link.
31723    LD="$CC"
31724    LDCXX="$CXX"
31725  fi
31726
31727  # FIXME: it should be CXXLD, according to standard (cf CXXCPP)
31728
31729
31730  #
31731  # Setup the assembler (AS)
31732  #
31733  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
31734    # FIXME: should this really be solaris, or solstudio?
31735
31736
31737  # Publish this variable in the help.
31738
31739
31740  if test "x$AS" = x; then
31741    # The variable is not set by user, try to locate tool using the code snippet
31742    for ac_prog in as
31743do
31744  # Extract the first word of "$ac_prog", so it can be a program name with args.
31745set dummy $ac_prog; ac_word=$2
31746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31747$as_echo_n "checking for $ac_word... " >&6; }
31748if ${ac_cv_path_AS+:} false; then :
31749  $as_echo_n "(cached) " >&6
31750else
31751  case $AS in
31752  [\\/]* | ?:[\\/]*)
31753  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31754  ;;
31755  *)
31756  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31757for as_dir in $PATH
31758do
31759  IFS=$as_save_IFS
31760  test -z "$as_dir" && as_dir=.
31761    for ac_exec_ext in '' $ac_executable_extensions; do
31762  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31763    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31764    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31765    break 2
31766  fi
31767done
31768  done
31769IFS=$as_save_IFS
31770
31771  ;;
31772esac
31773fi
31774AS=$ac_cv_path_AS
31775if test -n "$AS"; then
31776  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31777$as_echo "$AS" >&6; }
31778else
31779  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31780$as_echo "no" >&6; }
31781fi
31782
31783
31784  test -n "$AS" && break
31785done
31786
31787  else
31788    # The variable is set, but is it from the command line or the environment?
31789
31790    # Try to remove the string !AS! from our list.
31791    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
31792    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
31793      # If it failed, the variable was not from the command line. Ignore it,
31794      # but warn the user (except for BASH, which is always set by the calling BASH).
31795      if test "xAS" != xBASH; then
31796        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
31797$as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
31798      fi
31799      # Try to locate tool using the code snippet
31800      for ac_prog in as
31801do
31802  # Extract the first word of "$ac_prog", so it can be a program name with args.
31803set dummy $ac_prog; ac_word=$2
31804{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31805$as_echo_n "checking for $ac_word... " >&6; }
31806if ${ac_cv_path_AS+:} false; then :
31807  $as_echo_n "(cached) " >&6
31808else
31809  case $AS in
31810  [\\/]* | ?:[\\/]*)
31811  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31812  ;;
31813  *)
31814  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31815for as_dir in $PATH
31816do
31817  IFS=$as_save_IFS
31818  test -z "$as_dir" && as_dir=.
31819    for ac_exec_ext in '' $ac_executable_extensions; do
31820  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31821    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31822    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31823    break 2
31824  fi
31825done
31826  done
31827IFS=$as_save_IFS
31828
31829  ;;
31830esac
31831fi
31832AS=$ac_cv_path_AS
31833if test -n "$AS"; then
31834  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31835$as_echo "$AS" >&6; }
31836else
31837  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31838$as_echo "no" >&6; }
31839fi
31840
31841
31842  test -n "$AS" && break
31843done
31844
31845    else
31846      # If it succeeded, then it was overridden by the user. We will use it
31847      # for the tool.
31848
31849      # First remove it from the list of overridden variables, so we can test
31850      # for unknown variables in the end.
31851      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
31852
31853      # Check if the provided tool contains a complete path.
31854      tool_specified="$AS"
31855      tool_basename="${tool_specified##*/}"
31856      if test "x$tool_basename" = "x$tool_specified"; then
31857        # A command without a complete path is provided, search $PATH.
31858        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
31859$as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
31860        # Extract the first word of "$tool_basename", so it can be a program name with args.
31861set dummy $tool_basename; ac_word=$2
31862{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31863$as_echo_n "checking for $ac_word... " >&6; }
31864if ${ac_cv_path_AS+:} false; then :
31865  $as_echo_n "(cached) " >&6
31866else
31867  case $AS in
31868  [\\/]* | ?:[\\/]*)
31869  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31870  ;;
31871  *)
31872  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31873for as_dir in $PATH
31874do
31875  IFS=$as_save_IFS
31876  test -z "$as_dir" && as_dir=.
31877    for ac_exec_ext in '' $ac_executable_extensions; do
31878  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31879    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31880    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31881    break 2
31882  fi
31883done
31884  done
31885IFS=$as_save_IFS
31886
31887  ;;
31888esac
31889fi
31890AS=$ac_cv_path_AS
31891if test -n "$AS"; then
31892  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31893$as_echo "$AS" >&6; }
31894else
31895  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31896$as_echo "no" >&6; }
31897fi
31898
31899
31900        if test "x$AS" = x; then
31901          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
31902        fi
31903      else
31904        # Otherwise we believe it is a complete path. Use it as it is.
31905        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
31906$as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
31907        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
31908$as_echo_n "checking for AS... " >&6; }
31909        if test ! -x "$tool_specified"; then
31910          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
31911$as_echo "not found" >&6; }
31912          as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
31913        fi
31914        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
31915$as_echo "$tool_specified" >&6; }
31916      fi
31917    fi
31918  fi
31919
31920
31921
31922  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31923
31924  # First separate the path from the arguments. This will split at the first
31925  # space.
31926  complete="$AS"
31927  path="${complete%% *}"
31928  tmp="$complete EOL"
31929  arguments="${tmp#* }"
31930
31931  # Input might be given as Windows format, start by converting to
31932  # unix format.
31933  new_path=`$CYGPATH -u "$path"`
31934
31935  # Now try to locate executable using which
31936  new_path=`$WHICH "$new_path" 2> /dev/null`
31937  # bat and cmd files are not always considered executable in cygwin causing which
31938  # to not find them
31939  if test "x$new_path" = x \
31940      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31941      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31942    new_path=`$CYGPATH -u "$path"`
31943  fi
31944  if test "x$new_path" = x; then
31945    # Oops. Which didn't find the executable.
31946    # The splitting of arguments from the executable at a space might have been incorrect,
31947    # since paths with space are more likely in Windows. Give it another try with the whole
31948    # argument.
31949    path="$complete"
31950    arguments="EOL"
31951    new_path=`$CYGPATH -u "$path"`
31952    new_path=`$WHICH "$new_path" 2> /dev/null`
31953    # bat and cmd files are not always considered executable in cygwin causing which
31954    # to not find them
31955    if test "x$new_path" = x \
31956        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31957        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31958      new_path=`$CYGPATH -u "$path"`
31959    fi
31960    if test "x$new_path" = x; then
31961      # It's still not found. Now this is an unrecoverable error.
31962      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31963$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31964      has_space=`$ECHO "$complete" | $GREP " "`
31965      if test "x$has_space" != x; then
31966        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31967$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31968      fi
31969      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31970    fi
31971  fi
31972
31973  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31974  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31975  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31976  # "foo.exe" is OK but "foo" is an error.
31977  #
31978  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31979  # It is also a way to make sure we got the proper file name for the real test later on.
31980  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31981  if test "x$test_shortpath" = x; then
31982    # Short path failed, file does not exist as specified.
31983    # Try adding .exe or .cmd
31984    if test -f "${new_path}.exe"; then
31985      input_to_shortpath="${new_path}.exe"
31986    elif test -f "${new_path}.cmd"; then
31987      input_to_shortpath="${new_path}.cmd"
31988    else
31989      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
31990$as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
31991      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31992$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31993      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31994    fi
31995  else
31996    input_to_shortpath="$new_path"
31997  fi
31998
31999  # Call helper function which possibly converts this using DOS-style short mode.
32000  # If so, the updated path is stored in $new_path.
32001  new_path="$input_to_shortpath"
32002
32003  input_path="$input_to_shortpath"
32004  # Check if we need to convert this using DOS-style short mode. If the path
32005  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32006  # take no chances and rewrite it.
32007  # Note: m4 eats our [], so we need to use [ and ] instead.
32008  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32009  if test "x$has_forbidden_chars" != x; then
32010    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32011    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32012    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32013    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32014      # Going to short mode and back again did indeed matter. Since short mode is
32015      # case insensitive, let's make it lowercase to improve readability.
32016      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32017      # Now convert it back to Unix-stile (cygpath)
32018      input_path=`$CYGPATH -u "$shortmode_path"`
32019      new_path="$input_path"
32020    fi
32021  fi
32022
32023  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32024  if test "x$test_cygdrive_prefix" = x; then
32025    # As a simple fix, exclude /usr/bin since it's not a real path.
32026    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32027      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32028      # a path prefixed by /cygdrive for fixpath to work.
32029      new_path="$CYGWIN_ROOT_PATH$input_path"
32030    fi
32031  fi
32032
32033  # remove trailing .exe if any
32034  new_path="${new_path/%.exe/}"
32035
32036  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32037
32038  # First separate the path from the arguments. This will split at the first
32039  # space.
32040  complete="$AS"
32041  path="${complete%% *}"
32042  tmp="$complete EOL"
32043  arguments="${tmp#* }"
32044
32045  # Input might be given as Windows format, start by converting to
32046  # unix format.
32047  new_path="$path"
32048
32049  windows_path="$new_path"
32050  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32051    unix_path=`$CYGPATH -u "$windows_path"`
32052    new_path="$unix_path"
32053  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32054    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32055    new_path="$unix_path"
32056  fi
32057
32058
32059  # Now try to locate executable using which
32060  new_path=`$WHICH "$new_path" 2> /dev/null`
32061
32062  if test "x$new_path" = x; then
32063    # Oops. Which didn't find the executable.
32064    # The splitting of arguments from the executable at a space might have been incorrect,
32065    # since paths with space are more likely in Windows. Give it another try with the whole
32066    # argument.
32067    path="$complete"
32068    arguments="EOL"
32069    new_path="$path"
32070
32071  windows_path="$new_path"
32072  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32073    unix_path=`$CYGPATH -u "$windows_path"`
32074    new_path="$unix_path"
32075  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32076    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32077    new_path="$unix_path"
32078  fi
32079
32080
32081    new_path=`$WHICH "$new_path" 2> /dev/null`
32082
32083    if test "x$new_path" = x; then
32084      # It's still not found. Now this is an unrecoverable error.
32085      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32086$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32087      has_space=`$ECHO "$complete" | $GREP " "`
32088      if test "x$has_space" != x; then
32089        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32090$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32091      fi
32092      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32093    fi
32094  fi
32095
32096  # Now new_path has a complete unix path to the binary
32097  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32098    # Keep paths in /bin as-is, but remove trailing .exe if any
32099    new_path="${new_path/%.exe/}"
32100    # Do not save /bin paths to all_fixpath_prefixes!
32101  else
32102    # Not in mixed or Windows style, start by that.
32103    new_path=`cmd //c echo $new_path`
32104
32105  input_path="$new_path"
32106  # Check if we need to convert this using DOS-style short mode. If the path
32107  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32108  # take no chances and rewrite it.
32109  # Note: m4 eats our [], so we need to use [ and ] instead.
32110  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32111  if test "x$has_forbidden_chars" != x; then
32112    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32113    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32114  fi
32115
32116    # Output is in $new_path
32117
32118  windows_path="$new_path"
32119  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32120    unix_path=`$CYGPATH -u "$windows_path"`
32121    new_path="$unix_path"
32122  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32123    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32124    new_path="$unix_path"
32125  fi
32126
32127    # remove trailing .exe if any
32128    new_path="${new_path/%.exe/}"
32129
32130    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32131    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32132  fi
32133
32134  else
32135    # We're on a posix platform. Hooray! :)
32136    # First separate the path from the arguments. This will split at the first
32137    # space.
32138    complete="$AS"
32139    path="${complete%% *}"
32140    tmp="$complete EOL"
32141    arguments="${tmp#* }"
32142
32143    # Cannot rely on the command "which" here since it doesn't always work.
32144    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32145    if test -z "$is_absolute_path"; then
32146      # Path to executable is not absolute. Find it.
32147      IFS_save="$IFS"
32148      IFS=:
32149      for p in $PATH; do
32150        if test -f "$p/$path" && test -x "$p/$path"; then
32151          new_path="$p/$path"
32152          break
32153        fi
32154      done
32155      IFS="$IFS_save"
32156    else
32157      # This is an absolute path, we can use it without further modifications.
32158      new_path="$path"
32159    fi
32160
32161    if test "x$new_path" = x; then
32162      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32163$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32164      has_space=`$ECHO "$complete" | $GREP " "`
32165      if test "x$has_space" != x; then
32166        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32167$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32168      fi
32169      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32170    fi
32171  fi
32172
32173  # Now join together the path and the arguments once again
32174  if test "x$arguments" != xEOL; then
32175    new_complete="$new_path ${arguments% *}"
32176  else
32177    new_complete="$new_path"
32178  fi
32179
32180  if test "x$complete" != "x$new_complete"; then
32181    AS="$new_complete"
32182    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
32183$as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
32184  fi
32185
32186  else
32187    # FIXME: is this correct for microsoft?
32188    AS="$CC -c"
32189  fi
32190
32191
32192  #
32193  # Setup the archiver (AR)
32194  #
32195  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
32196    # The corresponding ar tool is lib.exe (used to create static libraries)
32197    # Extract the first word of "lib", so it can be a program name with args.
32198set dummy lib; ac_word=$2
32199{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32200$as_echo_n "checking for $ac_word... " >&6; }
32201if ${ac_cv_prog_AR+:} false; then :
32202  $as_echo_n "(cached) " >&6
32203else
32204  if test -n "$AR"; then
32205  ac_cv_prog_AR="$AR" # Let the user override the test.
32206else
32207as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32208for as_dir in $PATH
32209do
32210  IFS=$as_save_IFS
32211  test -z "$as_dir" && as_dir=.
32212    for ac_exec_ext in '' $ac_executable_extensions; do
32213  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32214    ac_cv_prog_AR="lib"
32215    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32216    break 2
32217  fi
32218done
32219  done
32220IFS=$as_save_IFS
32221
32222fi
32223fi
32224AR=$ac_cv_prog_AR
32225if test -n "$AR"; then
32226  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32227$as_echo "$AR" >&6; }
32228else
32229  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32230$as_echo "no" >&6; }
32231fi
32232
32233
32234  else
32235
32236
32237  # Publish this variable in the help.
32238
32239
32240  if test "x$AR" = x; then
32241    # The variable is not set by user, try to locate tool using the code snippet
32242    if test -n "$ac_tool_prefix"; then
32243  for ac_prog in ar
32244  do
32245    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32246set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32247{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32248$as_echo_n "checking for $ac_word... " >&6; }
32249if ${ac_cv_prog_AR+:} false; then :
32250  $as_echo_n "(cached) " >&6
32251else
32252  if test -n "$AR"; then
32253  ac_cv_prog_AR="$AR" # Let the user override the test.
32254else
32255as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32256for as_dir in $PATH
32257do
32258  IFS=$as_save_IFS
32259  test -z "$as_dir" && as_dir=.
32260    for ac_exec_ext in '' $ac_executable_extensions; do
32261  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32262    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32263    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32264    break 2
32265  fi
32266done
32267  done
32268IFS=$as_save_IFS
32269
32270fi
32271fi
32272AR=$ac_cv_prog_AR
32273if test -n "$AR"; then
32274  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32275$as_echo "$AR" >&6; }
32276else
32277  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32278$as_echo "no" >&6; }
32279fi
32280
32281
32282    test -n "$AR" && break
32283  done
32284fi
32285if test -z "$AR"; then
32286  ac_ct_AR=$AR
32287  for ac_prog in ar
32288do
32289  # Extract the first word of "$ac_prog", so it can be a program name with args.
32290set dummy $ac_prog; ac_word=$2
32291{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32292$as_echo_n "checking for $ac_word... " >&6; }
32293if ${ac_cv_prog_ac_ct_AR+:} false; then :
32294  $as_echo_n "(cached) " >&6
32295else
32296  if test -n "$ac_ct_AR"; then
32297  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32298else
32299as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32300for as_dir in $PATH
32301do
32302  IFS=$as_save_IFS
32303  test -z "$as_dir" && as_dir=.
32304    for ac_exec_ext in '' $ac_executable_extensions; do
32305  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32306    ac_cv_prog_ac_ct_AR="$ac_prog"
32307    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32308    break 2
32309  fi
32310done
32311  done
32312IFS=$as_save_IFS
32313
32314fi
32315fi
32316ac_ct_AR=$ac_cv_prog_ac_ct_AR
32317if test -n "$ac_ct_AR"; then
32318  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32319$as_echo "$ac_ct_AR" >&6; }
32320else
32321  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32322$as_echo "no" >&6; }
32323fi
32324
32325
32326  test -n "$ac_ct_AR" && break
32327done
32328
32329  if test "x$ac_ct_AR" = x; then
32330    AR=""
32331  else
32332    case $cross_compiling:$ac_tool_warned in
32333yes:)
32334{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32335$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32336ac_tool_warned=yes ;;
32337esac
32338    AR=$ac_ct_AR
32339  fi
32340fi
32341
32342  else
32343    # The variable is set, but is it from the command line or the environment?
32344
32345    # Try to remove the string !AR! from our list.
32346    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32347    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32348      # If it failed, the variable was not from the command line. Ignore it,
32349      # but warn the user (except for BASH, which is always set by the calling BASH).
32350      if test "xAR" != xBASH; then
32351        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32352$as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32353      fi
32354      # Try to locate tool using the code snippet
32355      if test -n "$ac_tool_prefix"; then
32356  for ac_prog in ar
32357  do
32358    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32359set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32360{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32361$as_echo_n "checking for $ac_word... " >&6; }
32362if ${ac_cv_prog_AR+:} false; then :
32363  $as_echo_n "(cached) " >&6
32364else
32365  if test -n "$AR"; then
32366  ac_cv_prog_AR="$AR" # Let the user override the test.
32367else
32368as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32369for as_dir in $PATH
32370do
32371  IFS=$as_save_IFS
32372  test -z "$as_dir" && as_dir=.
32373    for ac_exec_ext in '' $ac_executable_extensions; do
32374  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32375    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32376    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32377    break 2
32378  fi
32379done
32380  done
32381IFS=$as_save_IFS
32382
32383fi
32384fi
32385AR=$ac_cv_prog_AR
32386if test -n "$AR"; then
32387  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32388$as_echo "$AR" >&6; }
32389else
32390  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32391$as_echo "no" >&6; }
32392fi
32393
32394
32395    test -n "$AR" && break
32396  done
32397fi
32398if test -z "$AR"; then
32399  ac_ct_AR=$AR
32400  for ac_prog in ar
32401do
32402  # Extract the first word of "$ac_prog", so it can be a program name with args.
32403set dummy $ac_prog; ac_word=$2
32404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32405$as_echo_n "checking for $ac_word... " >&6; }
32406if ${ac_cv_prog_ac_ct_AR+:} false; then :
32407  $as_echo_n "(cached) " >&6
32408else
32409  if test -n "$ac_ct_AR"; then
32410  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32411else
32412as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32413for as_dir in $PATH
32414do
32415  IFS=$as_save_IFS
32416  test -z "$as_dir" && as_dir=.
32417    for ac_exec_ext in '' $ac_executable_extensions; do
32418  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32419    ac_cv_prog_ac_ct_AR="$ac_prog"
32420    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32421    break 2
32422  fi
32423done
32424  done
32425IFS=$as_save_IFS
32426
32427fi
32428fi
32429ac_ct_AR=$ac_cv_prog_ac_ct_AR
32430if test -n "$ac_ct_AR"; then
32431  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32432$as_echo "$ac_ct_AR" >&6; }
32433else
32434  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32435$as_echo "no" >&6; }
32436fi
32437
32438
32439  test -n "$ac_ct_AR" && break
32440done
32441
32442  if test "x$ac_ct_AR" = x; then
32443    AR=""
32444  else
32445    case $cross_compiling:$ac_tool_warned in
32446yes:)
32447{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32448$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32449ac_tool_warned=yes ;;
32450esac
32451    AR=$ac_ct_AR
32452  fi
32453fi
32454
32455    else
32456      # If it succeeded, then it was overridden by the user. We will use it
32457      # for the tool.
32458
32459      # First remove it from the list of overridden variables, so we can test
32460      # for unknown variables in the end.
32461      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32462
32463      # Check if the provided tool contains a complete path.
32464      tool_specified="$AR"
32465      tool_basename="${tool_specified##*/}"
32466      if test "x$tool_basename" = "x$tool_specified"; then
32467        # A command without a complete path is provided, search $PATH.
32468        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
32469$as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
32470        # Extract the first word of "$tool_basename", so it can be a program name with args.
32471set dummy $tool_basename; ac_word=$2
32472{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32473$as_echo_n "checking for $ac_word... " >&6; }
32474if ${ac_cv_path_AR+:} false; then :
32475  $as_echo_n "(cached) " >&6
32476else
32477  case $AR in
32478  [\\/]* | ?:[\\/]*)
32479  ac_cv_path_AR="$AR" # Let the user override the test with a path.
32480  ;;
32481  *)
32482  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32483for as_dir in $PATH
32484do
32485  IFS=$as_save_IFS
32486  test -z "$as_dir" && as_dir=.
32487    for ac_exec_ext in '' $ac_executable_extensions; do
32488  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32489    ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
32490    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32491    break 2
32492  fi
32493done
32494  done
32495IFS=$as_save_IFS
32496
32497  ;;
32498esac
32499fi
32500AR=$ac_cv_path_AR
32501if test -n "$AR"; then
32502  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32503$as_echo "$AR" >&6; }
32504else
32505  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32506$as_echo "no" >&6; }
32507fi
32508
32509
32510        if test "x$AR" = x; then
32511          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32512        fi
32513      else
32514        # Otherwise we believe it is a complete path. Use it as it is.
32515        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
32516$as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
32517        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
32518$as_echo_n "checking for AR... " >&6; }
32519        if test ! -x "$tool_specified"; then
32520          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32521$as_echo "not found" >&6; }
32522          as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
32523        fi
32524        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32525$as_echo "$tool_specified" >&6; }
32526      fi
32527    fi
32528  fi
32529
32530
32531  fi
32532
32533  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32534
32535  # First separate the path from the arguments. This will split at the first
32536  # space.
32537  complete="$AR"
32538  path="${complete%% *}"
32539  tmp="$complete EOL"
32540  arguments="${tmp#* }"
32541
32542  # Input might be given as Windows format, start by converting to
32543  # unix format.
32544  new_path=`$CYGPATH -u "$path"`
32545
32546  # Now try to locate executable using which
32547  new_path=`$WHICH "$new_path" 2> /dev/null`
32548  # bat and cmd files are not always considered executable in cygwin causing which
32549  # to not find them
32550  if test "x$new_path" = x \
32551      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32552      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32553    new_path=`$CYGPATH -u "$path"`
32554  fi
32555  if test "x$new_path" = x; then
32556    # Oops. Which didn't find the executable.
32557    # The splitting of arguments from the executable at a space might have been incorrect,
32558    # since paths with space are more likely in Windows. Give it another try with the whole
32559    # argument.
32560    path="$complete"
32561    arguments="EOL"
32562    new_path=`$CYGPATH -u "$path"`
32563    new_path=`$WHICH "$new_path" 2> /dev/null`
32564    # bat and cmd files are not always considered executable in cygwin causing which
32565    # to not find them
32566    if test "x$new_path" = x \
32567        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32568        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32569      new_path=`$CYGPATH -u "$path"`
32570    fi
32571    if test "x$new_path" = x; then
32572      # It's still not found. Now this is an unrecoverable error.
32573      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32574$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32575      has_space=`$ECHO "$complete" | $GREP " "`
32576      if test "x$has_space" != x; then
32577        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32578$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32579      fi
32580      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32581    fi
32582  fi
32583
32584  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32585  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32586  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32587  # "foo.exe" is OK but "foo" is an error.
32588  #
32589  # This test is therefore slightly more accurate than "test -f" to check for file presence.
32590  # It is also a way to make sure we got the proper file name for the real test later on.
32591  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32592  if test "x$test_shortpath" = x; then
32593    # Short path failed, file does not exist as specified.
32594    # Try adding .exe or .cmd
32595    if test -f "${new_path}.exe"; then
32596      input_to_shortpath="${new_path}.exe"
32597    elif test -f "${new_path}.cmd"; then
32598      input_to_shortpath="${new_path}.cmd"
32599    else
32600      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
32601$as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
32602      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32603$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32604      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32605    fi
32606  else
32607    input_to_shortpath="$new_path"
32608  fi
32609
32610  # Call helper function which possibly converts this using DOS-style short mode.
32611  # If so, the updated path is stored in $new_path.
32612  new_path="$input_to_shortpath"
32613
32614  input_path="$input_to_shortpath"
32615  # Check if we need to convert this using DOS-style short mode. If the path
32616  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32617  # take no chances and rewrite it.
32618  # Note: m4 eats our [], so we need to use [ and ] instead.
32619  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32620  if test "x$has_forbidden_chars" != x; then
32621    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32622    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32623    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32624    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32625      # Going to short mode and back again did indeed matter. Since short mode is
32626      # case insensitive, let's make it lowercase to improve readability.
32627      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32628      # Now convert it back to Unix-stile (cygpath)
32629      input_path=`$CYGPATH -u "$shortmode_path"`
32630      new_path="$input_path"
32631    fi
32632  fi
32633
32634  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32635  if test "x$test_cygdrive_prefix" = x; then
32636    # As a simple fix, exclude /usr/bin since it's not a real path.
32637    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32638      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32639      # a path prefixed by /cygdrive for fixpath to work.
32640      new_path="$CYGWIN_ROOT_PATH$input_path"
32641    fi
32642  fi
32643
32644  # remove trailing .exe if any
32645  new_path="${new_path/%.exe/}"
32646
32647  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32648
32649  # First separate the path from the arguments. This will split at the first
32650  # space.
32651  complete="$AR"
32652  path="${complete%% *}"
32653  tmp="$complete EOL"
32654  arguments="${tmp#* }"
32655
32656  # Input might be given as Windows format, start by converting to
32657  # unix format.
32658  new_path="$path"
32659
32660  windows_path="$new_path"
32661  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32662    unix_path=`$CYGPATH -u "$windows_path"`
32663    new_path="$unix_path"
32664  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32665    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32666    new_path="$unix_path"
32667  fi
32668
32669
32670  # Now try to locate executable using which
32671  new_path=`$WHICH "$new_path" 2> /dev/null`
32672
32673  if test "x$new_path" = x; then
32674    # Oops. Which didn't find the executable.
32675    # The splitting of arguments from the executable at a space might have been incorrect,
32676    # since paths with space are more likely in Windows. Give it another try with the whole
32677    # argument.
32678    path="$complete"
32679    arguments="EOL"
32680    new_path="$path"
32681
32682  windows_path="$new_path"
32683  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32684    unix_path=`$CYGPATH -u "$windows_path"`
32685    new_path="$unix_path"
32686  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32687    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32688    new_path="$unix_path"
32689  fi
32690
32691
32692    new_path=`$WHICH "$new_path" 2> /dev/null`
32693
32694    if test "x$new_path" = x; then
32695      # It's still not found. Now this is an unrecoverable error.
32696      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32697$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32698      has_space=`$ECHO "$complete" | $GREP " "`
32699      if test "x$has_space" != x; then
32700        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32701$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32702      fi
32703      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32704    fi
32705  fi
32706
32707  # Now new_path has a complete unix path to the binary
32708  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32709    # Keep paths in /bin as-is, but remove trailing .exe if any
32710    new_path="${new_path/%.exe/}"
32711    # Do not save /bin paths to all_fixpath_prefixes!
32712  else
32713    # Not in mixed or Windows style, start by that.
32714    new_path=`cmd //c echo $new_path`
32715
32716  input_path="$new_path"
32717  # Check if we need to convert this using DOS-style short mode. If the path
32718  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32719  # take no chances and rewrite it.
32720  # Note: m4 eats our [], so we need to use [ and ] instead.
32721  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32722  if test "x$has_forbidden_chars" != x; then
32723    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32724    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32725  fi
32726
32727    # Output is in $new_path
32728
32729  windows_path="$new_path"
32730  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32731    unix_path=`$CYGPATH -u "$windows_path"`
32732    new_path="$unix_path"
32733  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32734    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32735    new_path="$unix_path"
32736  fi
32737
32738    # remove trailing .exe if any
32739    new_path="${new_path/%.exe/}"
32740
32741    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32742    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32743  fi
32744
32745  else
32746    # We're on a posix platform. Hooray! :)
32747    # First separate the path from the arguments. This will split at the first
32748    # space.
32749    complete="$AR"
32750    path="${complete%% *}"
32751    tmp="$complete EOL"
32752    arguments="${tmp#* }"
32753
32754    # Cannot rely on the command "which" here since it doesn't always work.
32755    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32756    if test -z "$is_absolute_path"; then
32757      # Path to executable is not absolute. Find it.
32758      IFS_save="$IFS"
32759      IFS=:
32760      for p in $PATH; do
32761        if test -f "$p/$path" && test -x "$p/$path"; then
32762          new_path="$p/$path"
32763          break
32764        fi
32765      done
32766      IFS="$IFS_save"
32767    else
32768      # This is an absolute path, we can use it without further modifications.
32769      new_path="$path"
32770    fi
32771
32772    if test "x$new_path" = x; then
32773      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32774$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32775      has_space=`$ECHO "$complete" | $GREP " "`
32776      if test "x$has_space" != x; then
32777        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32778$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32779      fi
32780      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32781    fi
32782  fi
32783
32784  # Now join together the path and the arguments once again
32785  if test "x$arguments" != xEOL; then
32786    new_complete="$new_path ${arguments% *}"
32787  else
32788    new_complete="$new_path"
32789  fi
32790
32791  if test "x$complete" != "x$new_complete"; then
32792    AR="$new_complete"
32793    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
32794$as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
32795  fi
32796
32797
32798
32799  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
32800    ac_ext=m
32801ac_cpp='$OBJCPP $CPPFLAGS'
32802ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32803ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32804ac_compiler_gnu=$ac_cv_objc_compiler_gnu
32805if test -n "$ac_tool_prefix"; then
32806  for ac_prog in gcc objcc objc cc CC
32807  do
32808    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32809set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32811$as_echo_n "checking for $ac_word... " >&6; }
32812if ${ac_cv_prog_OBJC+:} false; then :
32813  $as_echo_n "(cached) " >&6
32814else
32815  if test -n "$OBJC"; then
32816  ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
32817else
32818as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32819for as_dir in $PATH
32820do
32821  IFS=$as_save_IFS
32822  test -z "$as_dir" && as_dir=.
32823    for ac_exec_ext in '' $ac_executable_extensions; do
32824  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32825    ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
32826    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32827    break 2
32828  fi
32829done
32830  done
32831IFS=$as_save_IFS
32832
32833fi
32834fi
32835OBJC=$ac_cv_prog_OBJC
32836if test -n "$OBJC"; then
32837  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
32838$as_echo "$OBJC" >&6; }
32839else
32840  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32841$as_echo "no" >&6; }
32842fi
32843
32844
32845    test -n "$OBJC" && break
32846  done
32847fi
32848if test -z "$OBJC"; then
32849  ac_ct_OBJC=$OBJC
32850  for ac_prog in gcc objcc objc cc CC
32851do
32852  # Extract the first word of "$ac_prog", so it can be a program name with args.
32853set dummy $ac_prog; ac_word=$2
32854{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32855$as_echo_n "checking for $ac_word... " >&6; }
32856if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
32857  $as_echo_n "(cached) " >&6
32858else
32859  if test -n "$ac_ct_OBJC"; then
32860  ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
32861else
32862as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32863for as_dir in $PATH
32864do
32865  IFS=$as_save_IFS
32866  test -z "$as_dir" && as_dir=.
32867    for ac_exec_ext in '' $ac_executable_extensions; do
32868  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32869    ac_cv_prog_ac_ct_OBJC="$ac_prog"
32870    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32871    break 2
32872  fi
32873done
32874  done
32875IFS=$as_save_IFS
32876
32877fi
32878fi
32879ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
32880if test -n "$ac_ct_OBJC"; then
32881  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
32882$as_echo "$ac_ct_OBJC" >&6; }
32883else
32884  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32885$as_echo "no" >&6; }
32886fi
32887
32888
32889  test -n "$ac_ct_OBJC" && break
32890done
32891
32892  if test "x$ac_ct_OBJC" = x; then
32893    OBJC="gcc"
32894  else
32895    case $cross_compiling:$ac_tool_warned in
32896yes:)
32897{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32898$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32899ac_tool_warned=yes ;;
32900esac
32901    OBJC=$ac_ct_OBJC
32902  fi
32903fi
32904
32905# Provide some information about the compiler.
32906$as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
32907set X $ac_compile
32908ac_compiler=$2
32909for ac_option in --version -v -V -qversion; do
32910  { { ac_try="$ac_compiler $ac_option >&5"
32911case "(($ac_try" in
32912  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32913  *) ac_try_echo=$ac_try;;
32914esac
32915eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32916$as_echo "$ac_try_echo"; } >&5
32917  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32918  ac_status=$?
32919  if test -s conftest.err; then
32920    sed '10a\
32921... rest of stderr output deleted ...
32922         10q' conftest.err >conftest.er1
32923    cat conftest.er1 >&5
32924  fi
32925  rm -f conftest.er1 conftest.err
32926  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32927  test $ac_status = 0; }
32928done
32929
32930{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
32931$as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
32932if ${ac_cv_objc_compiler_gnu+:} false; then :
32933  $as_echo_n "(cached) " >&6
32934else
32935  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32936/* end confdefs.h.  */
32937
32938int
32939main ()
32940{
32941#ifndef __GNUC__
32942       choke me
32943#endif
32944
32945  ;
32946  return 0;
32947}
32948_ACEOF
32949if ac_fn_objc_try_compile "$LINENO"; then :
32950  ac_compiler_gnu=yes
32951else
32952  ac_compiler_gnu=no
32953fi
32954rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32955ac_cv_objc_compiler_gnu=$ac_compiler_gnu
32956
32957fi
32958{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
32959$as_echo "$ac_cv_objc_compiler_gnu" >&6; }
32960if test $ac_compiler_gnu = yes; then
32961  GOBJC=yes
32962else
32963  GOBJC=
32964fi
32965ac_test_OBJCFLAGS=${OBJCFLAGS+set}
32966ac_save_OBJCFLAGS=$OBJCFLAGS
32967{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
32968$as_echo_n "checking whether $OBJC accepts -g... " >&6; }
32969if ${ac_cv_prog_objc_g+:} false; then :
32970  $as_echo_n "(cached) " >&6
32971else
32972  ac_save_objc_werror_flag=$ac_objc_werror_flag
32973   ac_objc_werror_flag=yes
32974   ac_cv_prog_objc_g=no
32975   OBJCFLAGS="-g"
32976   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32977/* end confdefs.h.  */
32978
32979int
32980main ()
32981{
32982
32983  ;
32984  return 0;
32985}
32986_ACEOF
32987if ac_fn_objc_try_compile "$LINENO"; then :
32988  ac_cv_prog_objc_g=yes
32989else
32990  OBJCFLAGS=""
32991      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32992/* end confdefs.h.  */
32993
32994int
32995main ()
32996{
32997
32998  ;
32999  return 0;
33000}
33001_ACEOF
33002if ac_fn_objc_try_compile "$LINENO"; then :
33003
33004else
33005  ac_objc_werror_flag=$ac_save_objc_werror_flag
33006	 OBJCFLAGS="-g"
33007	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33008/* end confdefs.h.  */
33009
33010int
33011main ()
33012{
33013
33014  ;
33015  return 0;
33016}
33017_ACEOF
33018if ac_fn_objc_try_compile "$LINENO"; then :
33019  ac_cv_prog_objc_g=yes
33020fi
33021rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33022fi
33023rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33024fi
33025rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33026   ac_objc_werror_flag=$ac_save_objc_werror_flag
33027fi
33028{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
33029$as_echo "$ac_cv_prog_objc_g" >&6; }
33030if test "$ac_test_OBJCFLAGS" = set; then
33031  OBJCFLAGS=$ac_save_OBJCFLAGS
33032elif test $ac_cv_prog_objc_g = yes; then
33033  if test "$GOBJC" = yes; then
33034    OBJCFLAGS="-g -O2"
33035  else
33036    OBJCFLAGS="-g"
33037  fi
33038else
33039  if test "$GOBJC" = yes; then
33040    OBJCFLAGS="-O2"
33041  else
33042    OBJCFLAGS=
33043  fi
33044fi
33045ac_ext=cpp
33046ac_cpp='$CXXCPP $CPPFLAGS'
33047ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
33048ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
33049ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
33050
33051
33052  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33053
33054  # First separate the path from the arguments. This will split at the first
33055  # space.
33056  complete="$OBJC"
33057  path="${complete%% *}"
33058  tmp="$complete EOL"
33059  arguments="${tmp#* }"
33060
33061  # Input might be given as Windows format, start by converting to
33062  # unix format.
33063  new_path=`$CYGPATH -u "$path"`
33064
33065  # Now try to locate executable using which
33066  new_path=`$WHICH "$new_path" 2> /dev/null`
33067  # bat and cmd files are not always considered executable in cygwin causing which
33068  # to not find them
33069  if test "x$new_path" = x \
33070      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33071      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33072    new_path=`$CYGPATH -u "$path"`
33073  fi
33074  if test "x$new_path" = x; then
33075    # Oops. Which didn't find the executable.
33076    # The splitting of arguments from the executable at a space might have been incorrect,
33077    # since paths with space are more likely in Windows. Give it another try with the whole
33078    # argument.
33079    path="$complete"
33080    arguments="EOL"
33081    new_path=`$CYGPATH -u "$path"`
33082    new_path=`$WHICH "$new_path" 2> /dev/null`
33083    # bat and cmd files are not always considered executable in cygwin causing which
33084    # to not find them
33085    if test "x$new_path" = x \
33086        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33087        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33088      new_path=`$CYGPATH -u "$path"`
33089    fi
33090    if test "x$new_path" = x; then
33091      # It's still not found. Now this is an unrecoverable error.
33092      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33093$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33094      has_space=`$ECHO "$complete" | $GREP " "`
33095      if test "x$has_space" != x; then
33096        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33097$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33098      fi
33099      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33100    fi
33101  fi
33102
33103  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33104  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33105  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33106  # "foo.exe" is OK but "foo" is an error.
33107  #
33108  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33109  # It is also a way to make sure we got the proper file name for the real test later on.
33110  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33111  if test "x$test_shortpath" = x; then
33112    # Short path failed, file does not exist as specified.
33113    # Try adding .exe or .cmd
33114    if test -f "${new_path}.exe"; then
33115      input_to_shortpath="${new_path}.exe"
33116    elif test -f "${new_path}.cmd"; then
33117      input_to_shortpath="${new_path}.cmd"
33118    else
33119      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
33120$as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
33121      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33122$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33123      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33124    fi
33125  else
33126    input_to_shortpath="$new_path"
33127  fi
33128
33129  # Call helper function which possibly converts this using DOS-style short mode.
33130  # If so, the updated path is stored in $new_path.
33131  new_path="$input_to_shortpath"
33132
33133  input_path="$input_to_shortpath"
33134  # Check if we need to convert this using DOS-style short mode. If the path
33135  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33136  # take no chances and rewrite it.
33137  # Note: m4 eats our [], so we need to use [ and ] instead.
33138  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33139  if test "x$has_forbidden_chars" != x; then
33140    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33141    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33142    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33143    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33144      # Going to short mode and back again did indeed matter. Since short mode is
33145      # case insensitive, let's make it lowercase to improve readability.
33146      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33147      # Now convert it back to Unix-stile (cygpath)
33148      input_path=`$CYGPATH -u "$shortmode_path"`
33149      new_path="$input_path"
33150    fi
33151  fi
33152
33153  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33154  if test "x$test_cygdrive_prefix" = x; then
33155    # As a simple fix, exclude /usr/bin since it's not a real path.
33156    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33157      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33158      # a path prefixed by /cygdrive for fixpath to work.
33159      new_path="$CYGWIN_ROOT_PATH$input_path"
33160    fi
33161  fi
33162
33163  # remove trailing .exe if any
33164  new_path="${new_path/%.exe/}"
33165
33166  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33167
33168  # First separate the path from the arguments. This will split at the first
33169  # space.
33170  complete="$OBJC"
33171  path="${complete%% *}"
33172  tmp="$complete EOL"
33173  arguments="${tmp#* }"
33174
33175  # Input might be given as Windows format, start by converting to
33176  # unix format.
33177  new_path="$path"
33178
33179  windows_path="$new_path"
33180  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33181    unix_path=`$CYGPATH -u "$windows_path"`
33182    new_path="$unix_path"
33183  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33184    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33185    new_path="$unix_path"
33186  fi
33187
33188
33189  # Now try to locate executable using which
33190  new_path=`$WHICH "$new_path" 2> /dev/null`
33191
33192  if test "x$new_path" = x; then
33193    # Oops. Which didn't find the executable.
33194    # The splitting of arguments from the executable at a space might have been incorrect,
33195    # since paths with space are more likely in Windows. Give it another try with the whole
33196    # argument.
33197    path="$complete"
33198    arguments="EOL"
33199    new_path="$path"
33200
33201  windows_path="$new_path"
33202  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33203    unix_path=`$CYGPATH -u "$windows_path"`
33204    new_path="$unix_path"
33205  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33206    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33207    new_path="$unix_path"
33208  fi
33209
33210
33211    new_path=`$WHICH "$new_path" 2> /dev/null`
33212
33213    if test "x$new_path" = x; then
33214      # It's still not found. Now this is an unrecoverable error.
33215      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33216$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33217      has_space=`$ECHO "$complete" | $GREP " "`
33218      if test "x$has_space" != x; then
33219        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33220$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33221      fi
33222      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33223    fi
33224  fi
33225
33226  # Now new_path has a complete unix path to the binary
33227  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33228    # Keep paths in /bin as-is, but remove trailing .exe if any
33229    new_path="${new_path/%.exe/}"
33230    # Do not save /bin paths to all_fixpath_prefixes!
33231  else
33232    # Not in mixed or Windows style, start by that.
33233    new_path=`cmd //c echo $new_path`
33234
33235  input_path="$new_path"
33236  # Check if we need to convert this using DOS-style short mode. If the path
33237  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33238  # take no chances and rewrite it.
33239  # Note: m4 eats our [], so we need to use [ and ] instead.
33240  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33241  if test "x$has_forbidden_chars" != x; then
33242    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33243    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33244  fi
33245
33246    # Output is in $new_path
33247
33248  windows_path="$new_path"
33249  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33250    unix_path=`$CYGPATH -u "$windows_path"`
33251    new_path="$unix_path"
33252  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33253    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33254    new_path="$unix_path"
33255  fi
33256
33257    # remove trailing .exe if any
33258    new_path="${new_path/%.exe/}"
33259
33260    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33261    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33262  fi
33263
33264  else
33265    # We're on a posix platform. Hooray! :)
33266    # First separate the path from the arguments. This will split at the first
33267    # space.
33268    complete="$OBJC"
33269    path="${complete%% *}"
33270    tmp="$complete EOL"
33271    arguments="${tmp#* }"
33272
33273    # Cannot rely on the command "which" here since it doesn't always work.
33274    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33275    if test -z "$is_absolute_path"; then
33276      # Path to executable is not absolute. Find it.
33277      IFS_save="$IFS"
33278      IFS=:
33279      for p in $PATH; do
33280        if test -f "$p/$path" && test -x "$p/$path"; then
33281          new_path="$p/$path"
33282          break
33283        fi
33284      done
33285      IFS="$IFS_save"
33286    else
33287      # This is an absolute path, we can use it without further modifications.
33288      new_path="$path"
33289    fi
33290
33291    if test "x$new_path" = x; then
33292      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33293$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33294      has_space=`$ECHO "$complete" | $GREP " "`
33295      if test "x$has_space" != x; then
33296        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33297$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33298      fi
33299      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33300    fi
33301  fi
33302
33303  # Now join together the path and the arguments once again
33304  if test "x$arguments" != xEOL; then
33305    new_complete="$new_path ${arguments% *}"
33306  else
33307    new_complete="$new_path"
33308  fi
33309
33310  if test "x$complete" != "x$new_complete"; then
33311    OBJC="$new_complete"
33312    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
33313$as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
33314  fi
33315
33316
33317
33318  # Publish this variable in the help.
33319
33320
33321  if test "x$LIPO" = x; then
33322    # The variable is not set by user, try to locate tool using the code snippet
33323    for ac_prog in lipo
33324do
33325  # Extract the first word of "$ac_prog", so it can be a program name with args.
33326set dummy $ac_prog; ac_word=$2
33327{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33328$as_echo_n "checking for $ac_word... " >&6; }
33329if ${ac_cv_path_LIPO+:} false; then :
33330  $as_echo_n "(cached) " >&6
33331else
33332  case $LIPO in
33333  [\\/]* | ?:[\\/]*)
33334  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33335  ;;
33336  *)
33337  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33338for as_dir in $PATH
33339do
33340  IFS=$as_save_IFS
33341  test -z "$as_dir" && as_dir=.
33342    for ac_exec_ext in '' $ac_executable_extensions; do
33343  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33344    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33345    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33346    break 2
33347  fi
33348done
33349  done
33350IFS=$as_save_IFS
33351
33352  ;;
33353esac
33354fi
33355LIPO=$ac_cv_path_LIPO
33356if test -n "$LIPO"; then
33357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33358$as_echo "$LIPO" >&6; }
33359else
33360  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33361$as_echo "no" >&6; }
33362fi
33363
33364
33365  test -n "$LIPO" && break
33366done
33367
33368  else
33369    # The variable is set, but is it from the command line or the environment?
33370
33371    # Try to remove the string !LIPO! from our list.
33372    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
33373    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
33374      # If it failed, the variable was not from the command line. Ignore it,
33375      # but warn the user (except for BASH, which is always set by the calling BASH).
33376      if test "xLIPO" != xBASH; then
33377        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
33378$as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
33379      fi
33380      # Try to locate tool using the code snippet
33381      for ac_prog in lipo
33382do
33383  # Extract the first word of "$ac_prog", so it can be a program name with args.
33384set dummy $ac_prog; ac_word=$2
33385{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33386$as_echo_n "checking for $ac_word... " >&6; }
33387if ${ac_cv_path_LIPO+:} false; then :
33388  $as_echo_n "(cached) " >&6
33389else
33390  case $LIPO in
33391  [\\/]* | ?:[\\/]*)
33392  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33393  ;;
33394  *)
33395  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33396for as_dir in $PATH
33397do
33398  IFS=$as_save_IFS
33399  test -z "$as_dir" && as_dir=.
33400    for ac_exec_ext in '' $ac_executable_extensions; do
33401  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33402    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33403    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33404    break 2
33405  fi
33406done
33407  done
33408IFS=$as_save_IFS
33409
33410  ;;
33411esac
33412fi
33413LIPO=$ac_cv_path_LIPO
33414if test -n "$LIPO"; then
33415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33416$as_echo "$LIPO" >&6; }
33417else
33418  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33419$as_echo "no" >&6; }
33420fi
33421
33422
33423  test -n "$LIPO" && break
33424done
33425
33426    else
33427      # If it succeeded, then it was overridden by the user. We will use it
33428      # for the tool.
33429
33430      # First remove it from the list of overridden variables, so we can test
33431      # for unknown variables in the end.
33432      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33433
33434      # Check if the provided tool contains a complete path.
33435      tool_specified="$LIPO"
33436      tool_basename="${tool_specified##*/}"
33437      if test "x$tool_basename" = "x$tool_specified"; then
33438        # A command without a complete path is provided, search $PATH.
33439        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
33440$as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
33441        # Extract the first word of "$tool_basename", so it can be a program name with args.
33442set dummy $tool_basename; ac_word=$2
33443{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33444$as_echo_n "checking for $ac_word... " >&6; }
33445if ${ac_cv_path_LIPO+:} false; then :
33446  $as_echo_n "(cached) " >&6
33447else
33448  case $LIPO in
33449  [\\/]* | ?:[\\/]*)
33450  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33451  ;;
33452  *)
33453  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33454for as_dir in $PATH
33455do
33456  IFS=$as_save_IFS
33457  test -z "$as_dir" && as_dir=.
33458    for ac_exec_ext in '' $ac_executable_extensions; do
33459  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33460    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33461    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33462    break 2
33463  fi
33464done
33465  done
33466IFS=$as_save_IFS
33467
33468  ;;
33469esac
33470fi
33471LIPO=$ac_cv_path_LIPO
33472if test -n "$LIPO"; then
33473  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33474$as_echo "$LIPO" >&6; }
33475else
33476  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33477$as_echo "no" >&6; }
33478fi
33479
33480
33481        if test "x$LIPO" = x; then
33482          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33483        fi
33484      else
33485        # Otherwise we believe it is a complete path. Use it as it is.
33486        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
33487$as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
33488        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
33489$as_echo_n "checking for LIPO... " >&6; }
33490        if test ! -x "$tool_specified"; then
33491          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33492$as_echo "not found" >&6; }
33493          as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
33494        fi
33495        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33496$as_echo "$tool_specified" >&6; }
33497      fi
33498    fi
33499  fi
33500
33501
33502
33503  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33504
33505  # First separate the path from the arguments. This will split at the first
33506  # space.
33507  complete="$LIPO"
33508  path="${complete%% *}"
33509  tmp="$complete EOL"
33510  arguments="${tmp#* }"
33511
33512  # Input might be given as Windows format, start by converting to
33513  # unix format.
33514  new_path=`$CYGPATH -u "$path"`
33515
33516  # Now try to locate executable using which
33517  new_path=`$WHICH "$new_path" 2> /dev/null`
33518  # bat and cmd files are not always considered executable in cygwin causing which
33519  # to not find them
33520  if test "x$new_path" = x \
33521      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33522      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33523    new_path=`$CYGPATH -u "$path"`
33524  fi
33525  if test "x$new_path" = x; then
33526    # Oops. Which didn't find the executable.
33527    # The splitting of arguments from the executable at a space might have been incorrect,
33528    # since paths with space are more likely in Windows. Give it another try with the whole
33529    # argument.
33530    path="$complete"
33531    arguments="EOL"
33532    new_path=`$CYGPATH -u "$path"`
33533    new_path=`$WHICH "$new_path" 2> /dev/null`
33534    # bat and cmd files are not always considered executable in cygwin causing which
33535    # to not find them
33536    if test "x$new_path" = x \
33537        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33538        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33539      new_path=`$CYGPATH -u "$path"`
33540    fi
33541    if test "x$new_path" = x; then
33542      # It's still not found. Now this is an unrecoverable error.
33543      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33544$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33545      has_space=`$ECHO "$complete" | $GREP " "`
33546      if test "x$has_space" != x; then
33547        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33548$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33549      fi
33550      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33551    fi
33552  fi
33553
33554  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33555  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33556  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33557  # "foo.exe" is OK but "foo" is an error.
33558  #
33559  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33560  # It is also a way to make sure we got the proper file name for the real test later on.
33561  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33562  if test "x$test_shortpath" = x; then
33563    # Short path failed, file does not exist as specified.
33564    # Try adding .exe or .cmd
33565    if test -f "${new_path}.exe"; then
33566      input_to_shortpath="${new_path}.exe"
33567    elif test -f "${new_path}.cmd"; then
33568      input_to_shortpath="${new_path}.cmd"
33569    else
33570      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
33571$as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
33572      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33573$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33574      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33575    fi
33576  else
33577    input_to_shortpath="$new_path"
33578  fi
33579
33580  # Call helper function which possibly converts this using DOS-style short mode.
33581  # If so, the updated path is stored in $new_path.
33582  new_path="$input_to_shortpath"
33583
33584  input_path="$input_to_shortpath"
33585  # Check if we need to convert this using DOS-style short mode. If the path
33586  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33587  # take no chances and rewrite it.
33588  # Note: m4 eats our [], so we need to use [ and ] instead.
33589  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33590  if test "x$has_forbidden_chars" != x; then
33591    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33592    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33593    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33594    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33595      # Going to short mode and back again did indeed matter. Since short mode is
33596      # case insensitive, let's make it lowercase to improve readability.
33597      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33598      # Now convert it back to Unix-stile (cygpath)
33599      input_path=`$CYGPATH -u "$shortmode_path"`
33600      new_path="$input_path"
33601    fi
33602  fi
33603
33604  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33605  if test "x$test_cygdrive_prefix" = x; then
33606    # As a simple fix, exclude /usr/bin since it's not a real path.
33607    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33608      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33609      # a path prefixed by /cygdrive for fixpath to work.
33610      new_path="$CYGWIN_ROOT_PATH$input_path"
33611    fi
33612  fi
33613
33614  # remove trailing .exe if any
33615  new_path="${new_path/%.exe/}"
33616
33617  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33618
33619  # First separate the path from the arguments. This will split at the first
33620  # space.
33621  complete="$LIPO"
33622  path="${complete%% *}"
33623  tmp="$complete EOL"
33624  arguments="${tmp#* }"
33625
33626  # Input might be given as Windows format, start by converting to
33627  # unix format.
33628  new_path="$path"
33629
33630  windows_path="$new_path"
33631  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33632    unix_path=`$CYGPATH -u "$windows_path"`
33633    new_path="$unix_path"
33634  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33635    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33636    new_path="$unix_path"
33637  fi
33638
33639
33640  # Now try to locate executable using which
33641  new_path=`$WHICH "$new_path" 2> /dev/null`
33642
33643  if test "x$new_path" = x; then
33644    # Oops. Which didn't find the executable.
33645    # The splitting of arguments from the executable at a space might have been incorrect,
33646    # since paths with space are more likely in Windows. Give it another try with the whole
33647    # argument.
33648    path="$complete"
33649    arguments="EOL"
33650    new_path="$path"
33651
33652  windows_path="$new_path"
33653  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33654    unix_path=`$CYGPATH -u "$windows_path"`
33655    new_path="$unix_path"
33656  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33657    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33658    new_path="$unix_path"
33659  fi
33660
33661
33662    new_path=`$WHICH "$new_path" 2> /dev/null`
33663
33664    if test "x$new_path" = x; then
33665      # It's still not found. Now this is an unrecoverable error.
33666      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33667$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33668      has_space=`$ECHO "$complete" | $GREP " "`
33669      if test "x$has_space" != x; then
33670        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33671$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33672      fi
33673      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33674    fi
33675  fi
33676
33677  # Now new_path has a complete unix path to the binary
33678  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33679    # Keep paths in /bin as-is, but remove trailing .exe if any
33680    new_path="${new_path/%.exe/}"
33681    # Do not save /bin paths to all_fixpath_prefixes!
33682  else
33683    # Not in mixed or Windows style, start by that.
33684    new_path=`cmd //c echo $new_path`
33685
33686  input_path="$new_path"
33687  # Check if we need to convert this using DOS-style short mode. If the path
33688  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33689  # take no chances and rewrite it.
33690  # Note: m4 eats our [], so we need to use [ and ] instead.
33691  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33692  if test "x$has_forbidden_chars" != x; then
33693    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33694    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33695  fi
33696
33697    # Output is in $new_path
33698
33699  windows_path="$new_path"
33700  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33701    unix_path=`$CYGPATH -u "$windows_path"`
33702    new_path="$unix_path"
33703  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33704    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33705    new_path="$unix_path"
33706  fi
33707
33708    # remove trailing .exe if any
33709    new_path="${new_path/%.exe/}"
33710
33711    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33712    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33713  fi
33714
33715  else
33716    # We're on a posix platform. Hooray! :)
33717    # First separate the path from the arguments. This will split at the first
33718    # space.
33719    complete="$LIPO"
33720    path="${complete%% *}"
33721    tmp="$complete EOL"
33722    arguments="${tmp#* }"
33723
33724    # Cannot rely on the command "which" here since it doesn't always work.
33725    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33726    if test -z "$is_absolute_path"; then
33727      # Path to executable is not absolute. Find it.
33728      IFS_save="$IFS"
33729      IFS=:
33730      for p in $PATH; do
33731        if test -f "$p/$path" && test -x "$p/$path"; then
33732          new_path="$p/$path"
33733          break
33734        fi
33735      done
33736      IFS="$IFS_save"
33737    else
33738      # This is an absolute path, we can use it without further modifications.
33739      new_path="$path"
33740    fi
33741
33742    if test "x$new_path" = x; then
33743      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33744$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33745      has_space=`$ECHO "$complete" | $GREP " "`
33746      if test "x$has_space" != x; then
33747        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33748$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33749      fi
33750      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33751    fi
33752  fi
33753
33754  # Now join together the path and the arguments once again
33755  if test "x$arguments" != xEOL; then
33756    new_complete="$new_path ${arguments% *}"
33757  else
33758    new_complete="$new_path"
33759  fi
33760
33761  if test "x$complete" != "x$new_complete"; then
33762    LIPO="$new_complete"
33763    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
33764$as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
33765  fi
33766
33767  else
33768    OBJC=
33769  fi
33770
33771  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
33772    # Extract the first word of "mt", so it can be a program name with args.
33773set dummy mt; ac_word=$2
33774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33775$as_echo_n "checking for $ac_word... " >&6; }
33776if ${ac_cv_prog_MT+:} false; then :
33777  $as_echo_n "(cached) " >&6
33778else
33779  if test -n "$MT"; then
33780  ac_cv_prog_MT="$MT" # Let the user override the test.
33781else
33782  ac_prog_rejected=no
33783as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33784for as_dir in $PATH
33785do
33786  IFS=$as_save_IFS
33787  test -z "$as_dir" && as_dir=.
33788    for ac_exec_ext in '' $ac_executable_extensions; do
33789  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33790    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
33791       ac_prog_rejected=yes
33792       continue
33793     fi
33794    ac_cv_prog_MT="mt"
33795    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33796    break 2
33797  fi
33798done
33799  done
33800IFS=$as_save_IFS
33801
33802if test $ac_prog_rejected = yes; then
33803  # We found a bogon in the path, so make sure we never use it.
33804  set dummy $ac_cv_prog_MT
33805  shift
33806  if test $# != 0; then
33807    # We chose a different compiler from the bogus one.
33808    # However, it has the same basename, so the bogon will be chosen
33809    # first if we set MT to just the basename; use the full file name.
33810    shift
33811    ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
33812  fi
33813fi
33814fi
33815fi
33816MT=$ac_cv_prog_MT
33817if test -n "$MT"; then
33818  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
33819$as_echo "$MT" >&6; }
33820else
33821  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33822$as_echo "no" >&6; }
33823fi
33824
33825
33826
33827  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33828
33829  # First separate the path from the arguments. This will split at the first
33830  # space.
33831  complete="$MT"
33832  path="${complete%% *}"
33833  tmp="$complete EOL"
33834  arguments="${tmp#* }"
33835
33836  # Input might be given as Windows format, start by converting to
33837  # unix format.
33838  new_path=`$CYGPATH -u "$path"`
33839
33840  # Now try to locate executable using which
33841  new_path=`$WHICH "$new_path" 2> /dev/null`
33842  # bat and cmd files are not always considered executable in cygwin causing which
33843  # to not find them
33844  if test "x$new_path" = x \
33845      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33846      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33847    new_path=`$CYGPATH -u "$path"`
33848  fi
33849  if test "x$new_path" = x; then
33850    # Oops. Which didn't find the executable.
33851    # The splitting of arguments from the executable at a space might have been incorrect,
33852    # since paths with space are more likely in Windows. Give it another try with the whole
33853    # argument.
33854    path="$complete"
33855    arguments="EOL"
33856    new_path=`$CYGPATH -u "$path"`
33857    new_path=`$WHICH "$new_path" 2> /dev/null`
33858    # bat and cmd files are not always considered executable in cygwin causing which
33859    # to not find them
33860    if test "x$new_path" = x \
33861        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33862        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33863      new_path=`$CYGPATH -u "$path"`
33864    fi
33865    if test "x$new_path" = x; then
33866      # It's still not found. Now this is an unrecoverable error.
33867      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33868$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33869      has_space=`$ECHO "$complete" | $GREP " "`
33870      if test "x$has_space" != x; then
33871        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33872$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33873      fi
33874      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33875    fi
33876  fi
33877
33878  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33879  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33880  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33881  # "foo.exe" is OK but "foo" is an error.
33882  #
33883  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33884  # It is also a way to make sure we got the proper file name for the real test later on.
33885  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33886  if test "x$test_shortpath" = x; then
33887    # Short path failed, file does not exist as specified.
33888    # Try adding .exe or .cmd
33889    if test -f "${new_path}.exe"; then
33890      input_to_shortpath="${new_path}.exe"
33891    elif test -f "${new_path}.cmd"; then
33892      input_to_shortpath="${new_path}.cmd"
33893    else
33894      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
33895$as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
33896      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33897$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33898      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33899    fi
33900  else
33901    input_to_shortpath="$new_path"
33902  fi
33903
33904  # Call helper function which possibly converts this using DOS-style short mode.
33905  # If so, the updated path is stored in $new_path.
33906  new_path="$input_to_shortpath"
33907
33908  input_path="$input_to_shortpath"
33909  # Check if we need to convert this using DOS-style short mode. If the path
33910  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33911  # take no chances and rewrite it.
33912  # Note: m4 eats our [], so we need to use [ and ] instead.
33913  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33914  if test "x$has_forbidden_chars" != x; then
33915    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33916    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33917    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33918    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33919      # Going to short mode and back again did indeed matter. Since short mode is
33920      # case insensitive, let's make it lowercase to improve readability.
33921      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33922      # Now convert it back to Unix-stile (cygpath)
33923      input_path=`$CYGPATH -u "$shortmode_path"`
33924      new_path="$input_path"
33925    fi
33926  fi
33927
33928  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33929  if test "x$test_cygdrive_prefix" = x; then
33930    # As a simple fix, exclude /usr/bin since it's not a real path.
33931    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33932      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33933      # a path prefixed by /cygdrive for fixpath to work.
33934      new_path="$CYGWIN_ROOT_PATH$input_path"
33935    fi
33936  fi
33937
33938  # remove trailing .exe if any
33939  new_path="${new_path/%.exe/}"
33940
33941  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33942
33943  # First separate the path from the arguments. This will split at the first
33944  # space.
33945  complete="$MT"
33946  path="${complete%% *}"
33947  tmp="$complete EOL"
33948  arguments="${tmp#* }"
33949
33950  # Input might be given as Windows format, start by converting to
33951  # unix format.
33952  new_path="$path"
33953
33954  windows_path="$new_path"
33955  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33956    unix_path=`$CYGPATH -u "$windows_path"`
33957    new_path="$unix_path"
33958  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33959    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33960    new_path="$unix_path"
33961  fi
33962
33963
33964  # Now try to locate executable using which
33965  new_path=`$WHICH "$new_path" 2> /dev/null`
33966
33967  if test "x$new_path" = x; then
33968    # Oops. Which didn't find the executable.
33969    # The splitting of arguments from the executable at a space might have been incorrect,
33970    # since paths with space are more likely in Windows. Give it another try with the whole
33971    # argument.
33972    path="$complete"
33973    arguments="EOL"
33974    new_path="$path"
33975
33976  windows_path="$new_path"
33977  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33978    unix_path=`$CYGPATH -u "$windows_path"`
33979    new_path="$unix_path"
33980  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33981    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33982    new_path="$unix_path"
33983  fi
33984
33985
33986    new_path=`$WHICH "$new_path" 2> /dev/null`
33987
33988    if test "x$new_path" = x; then
33989      # It's still not found. Now this is an unrecoverable error.
33990      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33991$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33992      has_space=`$ECHO "$complete" | $GREP " "`
33993      if test "x$has_space" != x; then
33994        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33995$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33996      fi
33997      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33998    fi
33999  fi
34000
34001  # Now new_path has a complete unix path to the binary
34002  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34003    # Keep paths in /bin as-is, but remove trailing .exe if any
34004    new_path="${new_path/%.exe/}"
34005    # Do not save /bin paths to all_fixpath_prefixes!
34006  else
34007    # Not in mixed or Windows style, start by that.
34008    new_path=`cmd //c echo $new_path`
34009
34010  input_path="$new_path"
34011  # Check if we need to convert this using DOS-style short mode. If the path
34012  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34013  # take no chances and rewrite it.
34014  # Note: m4 eats our [], so we need to use [ and ] instead.
34015  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34016  if test "x$has_forbidden_chars" != x; then
34017    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34018    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34019  fi
34020
34021    # Output is in $new_path
34022
34023  windows_path="$new_path"
34024  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34025    unix_path=`$CYGPATH -u "$windows_path"`
34026    new_path="$unix_path"
34027  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34028    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34029    new_path="$unix_path"
34030  fi
34031
34032    # remove trailing .exe if any
34033    new_path="${new_path/%.exe/}"
34034
34035    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34036    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34037  fi
34038
34039  else
34040    # We're on a posix platform. Hooray! :)
34041    # First separate the path from the arguments. This will split at the first
34042    # space.
34043    complete="$MT"
34044    path="${complete%% *}"
34045    tmp="$complete EOL"
34046    arguments="${tmp#* }"
34047
34048    # Cannot rely on the command "which" here since it doesn't always work.
34049    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34050    if test -z "$is_absolute_path"; then
34051      # Path to executable is not absolute. Find it.
34052      IFS_save="$IFS"
34053      IFS=:
34054      for p in $PATH; do
34055        if test -f "$p/$path" && test -x "$p/$path"; then
34056          new_path="$p/$path"
34057          break
34058        fi
34059      done
34060      IFS="$IFS_save"
34061    else
34062      # This is an absolute path, we can use it without further modifications.
34063      new_path="$path"
34064    fi
34065
34066    if test "x$new_path" = x; then
34067      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34068$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
34069      has_space=`$ECHO "$complete" | $GREP " "`
34070      if test "x$has_space" != x; then
34071        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34072$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34073      fi
34074      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34075    fi
34076  fi
34077
34078  # Now join together the path and the arguments once again
34079  if test "x$arguments" != xEOL; then
34080    new_complete="$new_path ${arguments% *}"
34081  else
34082    new_complete="$new_path"
34083  fi
34084
34085  if test "x$complete" != "x$new_complete"; then
34086    MT="$new_complete"
34087    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
34088$as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
34089  fi
34090
34091    # Setup the resource compiler (RC)
34092    # Extract the first word of "rc", so it can be a program name with args.
34093set dummy rc; ac_word=$2
34094{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34095$as_echo_n "checking for $ac_word... " >&6; }
34096if ${ac_cv_prog_RC+:} false; then :
34097  $as_echo_n "(cached) " >&6
34098else
34099  if test -n "$RC"; then
34100  ac_cv_prog_RC="$RC" # Let the user override the test.
34101else
34102  ac_prog_rejected=no
34103as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34104for as_dir in $PATH
34105do
34106  IFS=$as_save_IFS
34107  test -z "$as_dir" && as_dir=.
34108    for ac_exec_ext in '' $ac_executable_extensions; do
34109  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34110    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
34111       ac_prog_rejected=yes
34112       continue
34113     fi
34114    ac_cv_prog_RC="rc"
34115    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34116    break 2
34117  fi
34118done
34119  done
34120IFS=$as_save_IFS
34121
34122if test $ac_prog_rejected = yes; then
34123  # We found a bogon in the path, so make sure we never use it.
34124  set dummy $ac_cv_prog_RC
34125  shift
34126  if test $# != 0; then
34127    # We chose a different compiler from the bogus one.
34128    # However, it has the same basename, so the bogon will be chosen
34129    # first if we set RC to just the basename; use the full file name.
34130    shift
34131    ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34132  fi
34133fi
34134fi
34135fi
34136RC=$ac_cv_prog_RC
34137if test -n "$RC"; then
34138  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34139$as_echo "$RC" >&6; }
34140else
34141  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34142$as_echo "no" >&6; }
34143fi
34144
34145
34146
34147  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34148
34149  # First separate the path from the arguments. This will split at the first
34150  # space.
34151  complete="$RC"
34152  path="${complete%% *}"
34153  tmp="$complete EOL"
34154  arguments="${tmp#* }"
34155
34156  # Input might be given as Windows format, start by converting to
34157  # unix format.
34158  new_path=`$CYGPATH -u "$path"`
34159
34160  # Now try to locate executable using which
34161  new_path=`$WHICH "$new_path" 2> /dev/null`
34162  # bat and cmd files are not always considered executable in cygwin causing which
34163  # to not find them
34164  if test "x$new_path" = x \
34165      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34166      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34167    new_path=`$CYGPATH -u "$path"`
34168  fi
34169  if test "x$new_path" = x; then
34170    # Oops. Which didn't find the executable.
34171    # The splitting of arguments from the executable at a space might have been incorrect,
34172    # since paths with space are more likely in Windows. Give it another try with the whole
34173    # argument.
34174    path="$complete"
34175    arguments="EOL"
34176    new_path=`$CYGPATH -u "$path"`
34177    new_path=`$WHICH "$new_path" 2> /dev/null`
34178    # bat and cmd files are not always considered executable in cygwin causing which
34179    # to not find them
34180    if test "x$new_path" = x \
34181        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34182        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34183      new_path=`$CYGPATH -u "$path"`
34184    fi
34185    if test "x$new_path" = x; then
34186      # It's still not found. Now this is an unrecoverable error.
34187      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34188$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34189      has_space=`$ECHO "$complete" | $GREP " "`
34190      if test "x$has_space" != x; then
34191        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34192$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34193      fi
34194      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34195    fi
34196  fi
34197
34198  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34199  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34200  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34201  # "foo.exe" is OK but "foo" is an error.
34202  #
34203  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34204  # It is also a way to make sure we got the proper file name for the real test later on.
34205  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34206  if test "x$test_shortpath" = x; then
34207    # Short path failed, file does not exist as specified.
34208    # Try adding .exe or .cmd
34209    if test -f "${new_path}.exe"; then
34210      input_to_shortpath="${new_path}.exe"
34211    elif test -f "${new_path}.cmd"; then
34212      input_to_shortpath="${new_path}.cmd"
34213    else
34214      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34215$as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34216      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34217$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34218      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34219    fi
34220  else
34221    input_to_shortpath="$new_path"
34222  fi
34223
34224  # Call helper function which possibly converts this using DOS-style short mode.
34225  # If so, the updated path is stored in $new_path.
34226  new_path="$input_to_shortpath"
34227
34228  input_path="$input_to_shortpath"
34229  # Check if we need to convert this using DOS-style short mode. If the path
34230  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34231  # take no chances and rewrite it.
34232  # Note: m4 eats our [], so we need to use [ and ] instead.
34233  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34234  if test "x$has_forbidden_chars" != x; then
34235    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34236    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34237    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34238    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34239      # Going to short mode and back again did indeed matter. Since short mode is
34240      # case insensitive, let's make it lowercase to improve readability.
34241      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34242      # Now convert it back to Unix-stile (cygpath)
34243      input_path=`$CYGPATH -u "$shortmode_path"`
34244      new_path="$input_path"
34245    fi
34246  fi
34247
34248  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34249  if test "x$test_cygdrive_prefix" = x; then
34250    # As a simple fix, exclude /usr/bin since it's not a real path.
34251    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34252      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34253      # a path prefixed by /cygdrive for fixpath to work.
34254      new_path="$CYGWIN_ROOT_PATH$input_path"
34255    fi
34256  fi
34257
34258  # remove trailing .exe if any
34259  new_path="${new_path/%.exe/}"
34260
34261  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34262
34263  # First separate the path from the arguments. This will split at the first
34264  # space.
34265  complete="$RC"
34266  path="${complete%% *}"
34267  tmp="$complete EOL"
34268  arguments="${tmp#* }"
34269
34270  # Input might be given as Windows format, start by converting to
34271  # unix format.
34272  new_path="$path"
34273
34274  windows_path="$new_path"
34275  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34276    unix_path=`$CYGPATH -u "$windows_path"`
34277    new_path="$unix_path"
34278  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34279    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34280    new_path="$unix_path"
34281  fi
34282
34283
34284  # Now try to locate executable using which
34285  new_path=`$WHICH "$new_path" 2> /dev/null`
34286
34287  if test "x$new_path" = x; then
34288    # Oops. Which didn't find the executable.
34289    # The splitting of arguments from the executable at a space might have been incorrect,
34290    # since paths with space are more likely in Windows. Give it another try with the whole
34291    # argument.
34292    path="$complete"
34293    arguments="EOL"
34294    new_path="$path"
34295
34296  windows_path="$new_path"
34297  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34298    unix_path=`$CYGPATH -u "$windows_path"`
34299    new_path="$unix_path"
34300  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34301    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34302    new_path="$unix_path"
34303  fi
34304
34305
34306    new_path=`$WHICH "$new_path" 2> /dev/null`
34307
34308    if test "x$new_path" = x; then
34309      # It's still not found. Now this is an unrecoverable error.
34310      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34311$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34312      has_space=`$ECHO "$complete" | $GREP " "`
34313      if test "x$has_space" != x; then
34314        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34315$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34316      fi
34317      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34318    fi
34319  fi
34320
34321  # Now new_path has a complete unix path to the binary
34322  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34323    # Keep paths in /bin as-is, but remove trailing .exe if any
34324    new_path="${new_path/%.exe/}"
34325    # Do not save /bin paths to all_fixpath_prefixes!
34326  else
34327    # Not in mixed or Windows style, start by that.
34328    new_path=`cmd //c echo $new_path`
34329
34330  input_path="$new_path"
34331  # Check if we need to convert this using DOS-style short mode. If the path
34332  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34333  # take no chances and rewrite it.
34334  # Note: m4 eats our [], so we need to use [ and ] instead.
34335  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34336  if test "x$has_forbidden_chars" != x; then
34337    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34338    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34339  fi
34340
34341    # Output is in $new_path
34342
34343  windows_path="$new_path"
34344  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34345    unix_path=`$CYGPATH -u "$windows_path"`
34346    new_path="$unix_path"
34347  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34348    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34349    new_path="$unix_path"
34350  fi
34351
34352    # remove trailing .exe if any
34353    new_path="${new_path/%.exe/}"
34354
34355    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34356    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34357  fi
34358
34359  else
34360    # We're on a posix platform. Hooray! :)
34361    # First separate the path from the arguments. This will split at the first
34362    # space.
34363    complete="$RC"
34364    path="${complete%% *}"
34365    tmp="$complete EOL"
34366    arguments="${tmp#* }"
34367
34368    # Cannot rely on the command "which" here since it doesn't always work.
34369    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34370    if test -z "$is_absolute_path"; then
34371      # Path to executable is not absolute. Find it.
34372      IFS_save="$IFS"
34373      IFS=:
34374      for p in $PATH; do
34375        if test -f "$p/$path" && test -x "$p/$path"; then
34376          new_path="$p/$path"
34377          break
34378        fi
34379      done
34380      IFS="$IFS_save"
34381    else
34382      # This is an absolute path, we can use it without further modifications.
34383      new_path="$path"
34384    fi
34385
34386    if test "x$new_path" = x; then
34387      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34388$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34389      has_space=`$ECHO "$complete" | $GREP " "`
34390      if test "x$has_space" != x; then
34391        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34392$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34393      fi
34394      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34395    fi
34396  fi
34397
34398  # Now join together the path and the arguments once again
34399  if test "x$arguments" != xEOL; then
34400    new_complete="$new_path ${arguments% *}"
34401  else
34402    new_complete="$new_path"
34403  fi
34404
34405  if test "x$complete" != "x$new_complete"; then
34406    RC="$new_complete"
34407    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34408$as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34409  fi
34410
34411    # Extract the first word of "dumpbin", so it can be a program name with args.
34412set dummy dumpbin; ac_word=$2
34413{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34414$as_echo_n "checking for $ac_word... " >&6; }
34415if ${ac_cv_prog_DUMPBIN+:} false; then :
34416  $as_echo_n "(cached) " >&6
34417else
34418  if test -n "$DUMPBIN"; then
34419  ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34420else
34421as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34422for as_dir in $PATH
34423do
34424  IFS=$as_save_IFS
34425  test -z "$as_dir" && as_dir=.
34426    for ac_exec_ext in '' $ac_executable_extensions; do
34427  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34428    ac_cv_prog_DUMPBIN="dumpbin"
34429    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34430    break 2
34431  fi
34432done
34433  done
34434IFS=$as_save_IFS
34435
34436fi
34437fi
34438DUMPBIN=$ac_cv_prog_DUMPBIN
34439if test -n "$DUMPBIN"; then
34440  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34441$as_echo "$DUMPBIN" >&6; }
34442else
34443  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34444$as_echo "no" >&6; }
34445fi
34446
34447
34448
34449  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34450
34451  # First separate the path from the arguments. This will split at the first
34452  # space.
34453  complete="$DUMPBIN"
34454  path="${complete%% *}"
34455  tmp="$complete EOL"
34456  arguments="${tmp#* }"
34457
34458  # Input might be given as Windows format, start by converting to
34459  # unix format.
34460  new_path=`$CYGPATH -u "$path"`
34461
34462  # Now try to locate executable using which
34463  new_path=`$WHICH "$new_path" 2> /dev/null`
34464  # bat and cmd files are not always considered executable in cygwin causing which
34465  # to not find them
34466  if test "x$new_path" = x \
34467      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34468      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34469    new_path=`$CYGPATH -u "$path"`
34470  fi
34471  if test "x$new_path" = x; then
34472    # Oops. Which didn't find the executable.
34473    # The splitting of arguments from the executable at a space might have been incorrect,
34474    # since paths with space are more likely in Windows. Give it another try with the whole
34475    # argument.
34476    path="$complete"
34477    arguments="EOL"
34478    new_path=`$CYGPATH -u "$path"`
34479    new_path=`$WHICH "$new_path" 2> /dev/null`
34480    # bat and cmd files are not always considered executable in cygwin causing which
34481    # to not find them
34482    if test "x$new_path" = x \
34483        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34484        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34485      new_path=`$CYGPATH -u "$path"`
34486    fi
34487    if test "x$new_path" = x; then
34488      # It's still not found. Now this is an unrecoverable error.
34489      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34490$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34491      has_space=`$ECHO "$complete" | $GREP " "`
34492      if test "x$has_space" != x; then
34493        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34494$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34495      fi
34496      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34497    fi
34498  fi
34499
34500  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34501  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34502  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34503  # "foo.exe" is OK but "foo" is an error.
34504  #
34505  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34506  # It is also a way to make sure we got the proper file name for the real test later on.
34507  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34508  if test "x$test_shortpath" = x; then
34509    # Short path failed, file does not exist as specified.
34510    # Try adding .exe or .cmd
34511    if test -f "${new_path}.exe"; then
34512      input_to_shortpath="${new_path}.exe"
34513    elif test -f "${new_path}.cmd"; then
34514      input_to_shortpath="${new_path}.cmd"
34515    else
34516      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34517$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34518      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34519$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34520      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34521    fi
34522  else
34523    input_to_shortpath="$new_path"
34524  fi
34525
34526  # Call helper function which possibly converts this using DOS-style short mode.
34527  # If so, the updated path is stored in $new_path.
34528  new_path="$input_to_shortpath"
34529
34530  input_path="$input_to_shortpath"
34531  # Check if we need to convert this using DOS-style short mode. If the path
34532  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34533  # take no chances and rewrite it.
34534  # Note: m4 eats our [], so we need to use [ and ] instead.
34535  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34536  if test "x$has_forbidden_chars" != x; then
34537    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34538    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34539    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34540    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34541      # Going to short mode and back again did indeed matter. Since short mode is
34542      # case insensitive, let's make it lowercase to improve readability.
34543      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34544      # Now convert it back to Unix-stile (cygpath)
34545      input_path=`$CYGPATH -u "$shortmode_path"`
34546      new_path="$input_path"
34547    fi
34548  fi
34549
34550  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34551  if test "x$test_cygdrive_prefix" = x; then
34552    # As a simple fix, exclude /usr/bin since it's not a real path.
34553    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34554      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34555      # a path prefixed by /cygdrive for fixpath to work.
34556      new_path="$CYGWIN_ROOT_PATH$input_path"
34557    fi
34558  fi
34559
34560  # remove trailing .exe if any
34561  new_path="${new_path/%.exe/}"
34562
34563  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34564
34565  # First separate the path from the arguments. This will split at the first
34566  # space.
34567  complete="$DUMPBIN"
34568  path="${complete%% *}"
34569  tmp="$complete EOL"
34570  arguments="${tmp#* }"
34571
34572  # Input might be given as Windows format, start by converting to
34573  # unix format.
34574  new_path="$path"
34575
34576  windows_path="$new_path"
34577  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34578    unix_path=`$CYGPATH -u "$windows_path"`
34579    new_path="$unix_path"
34580  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34581    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34582    new_path="$unix_path"
34583  fi
34584
34585
34586  # Now try to locate executable using which
34587  new_path=`$WHICH "$new_path" 2> /dev/null`
34588
34589  if test "x$new_path" = x; then
34590    # Oops. Which didn't find the executable.
34591    # The splitting of arguments from the executable at a space might have been incorrect,
34592    # since paths with space are more likely in Windows. Give it another try with the whole
34593    # argument.
34594    path="$complete"
34595    arguments="EOL"
34596    new_path="$path"
34597
34598  windows_path="$new_path"
34599  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34600    unix_path=`$CYGPATH -u "$windows_path"`
34601    new_path="$unix_path"
34602  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34603    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34604    new_path="$unix_path"
34605  fi
34606
34607
34608    new_path=`$WHICH "$new_path" 2> /dev/null`
34609
34610    if test "x$new_path" = x; then
34611      # It's still not found. Now this is an unrecoverable error.
34612      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34613$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34614      has_space=`$ECHO "$complete" | $GREP " "`
34615      if test "x$has_space" != x; then
34616        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34617$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34618      fi
34619      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34620    fi
34621  fi
34622
34623  # Now new_path has a complete unix path to the binary
34624  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34625    # Keep paths in /bin as-is, but remove trailing .exe if any
34626    new_path="${new_path/%.exe/}"
34627    # Do not save /bin paths to all_fixpath_prefixes!
34628  else
34629    # Not in mixed or Windows style, start by that.
34630    new_path=`cmd //c echo $new_path`
34631
34632  input_path="$new_path"
34633  # Check if we need to convert this using DOS-style short mode. If the path
34634  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34635  # take no chances and rewrite it.
34636  # Note: m4 eats our [], so we need to use [ and ] instead.
34637  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34638  if test "x$has_forbidden_chars" != x; then
34639    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34640    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34641  fi
34642
34643    # Output is in $new_path
34644
34645  windows_path="$new_path"
34646  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34647    unix_path=`$CYGPATH -u "$windows_path"`
34648    new_path="$unix_path"
34649  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34650    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34651    new_path="$unix_path"
34652  fi
34653
34654    # remove trailing .exe if any
34655    new_path="${new_path/%.exe/}"
34656
34657    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34658    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34659  fi
34660
34661  else
34662    # We're on a posix platform. Hooray! :)
34663    # First separate the path from the arguments. This will split at the first
34664    # space.
34665    complete="$DUMPBIN"
34666    path="${complete%% *}"
34667    tmp="$complete EOL"
34668    arguments="${tmp#* }"
34669
34670    # Cannot rely on the command "which" here since it doesn't always work.
34671    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34672    if test -z "$is_absolute_path"; then
34673      # Path to executable is not absolute. Find it.
34674      IFS_save="$IFS"
34675      IFS=:
34676      for p in $PATH; do
34677        if test -f "$p/$path" && test -x "$p/$path"; then
34678          new_path="$p/$path"
34679          break
34680        fi
34681      done
34682      IFS="$IFS_save"
34683    else
34684      # This is an absolute path, we can use it without further modifications.
34685      new_path="$path"
34686    fi
34687
34688    if test "x$new_path" = x; then
34689      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34690$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34691      has_space=`$ECHO "$complete" | $GREP " "`
34692      if test "x$has_space" != x; then
34693        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34694$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34695      fi
34696      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34697    fi
34698  fi
34699
34700  # Now join together the path and the arguments once again
34701  if test "x$arguments" != xEOL; then
34702    new_complete="$new_path ${arguments% *}"
34703  else
34704    new_complete="$new_path"
34705  fi
34706
34707  if test "x$complete" != "x$new_complete"; then
34708    DUMPBIN="$new_complete"
34709    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
34710$as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
34711  fi
34712
34713  fi
34714
34715  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
34716
34717
34718  # Publish this variable in the help.
34719
34720
34721  if test "x$STRIP" = x; then
34722    # The variable is not set by user, try to locate tool using the code snippet
34723    for ac_prog in strip
34724do
34725  # Extract the first word of "$ac_prog", so it can be a program name with args.
34726set dummy $ac_prog; ac_word=$2
34727{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34728$as_echo_n "checking for $ac_word... " >&6; }
34729if ${ac_cv_path_STRIP+:} false; then :
34730  $as_echo_n "(cached) " >&6
34731else
34732  case $STRIP in
34733  [\\/]* | ?:[\\/]*)
34734  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34735  ;;
34736  *)
34737  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34738for as_dir in $PATH
34739do
34740  IFS=$as_save_IFS
34741  test -z "$as_dir" && as_dir=.
34742    for ac_exec_ext in '' $ac_executable_extensions; do
34743  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34744    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34745    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34746    break 2
34747  fi
34748done
34749  done
34750IFS=$as_save_IFS
34751
34752  ;;
34753esac
34754fi
34755STRIP=$ac_cv_path_STRIP
34756if test -n "$STRIP"; then
34757  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34758$as_echo "$STRIP" >&6; }
34759else
34760  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34761$as_echo "no" >&6; }
34762fi
34763
34764
34765  test -n "$STRIP" && break
34766done
34767
34768  else
34769    # The variable is set, but is it from the command line or the environment?
34770
34771    # Try to remove the string !STRIP! from our list.
34772    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
34773    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
34774      # If it failed, the variable was not from the command line. Ignore it,
34775      # but warn the user (except for BASH, which is always set by the calling BASH).
34776      if test "xSTRIP" != xBASH; then
34777        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
34778$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
34779      fi
34780      # Try to locate tool using the code snippet
34781      for ac_prog in strip
34782do
34783  # Extract the first word of "$ac_prog", so it can be a program name with args.
34784set dummy $ac_prog; ac_word=$2
34785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34786$as_echo_n "checking for $ac_word... " >&6; }
34787if ${ac_cv_path_STRIP+:} false; then :
34788  $as_echo_n "(cached) " >&6
34789else
34790  case $STRIP in
34791  [\\/]* | ?:[\\/]*)
34792  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34793  ;;
34794  *)
34795  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34796for as_dir in $PATH
34797do
34798  IFS=$as_save_IFS
34799  test -z "$as_dir" && as_dir=.
34800    for ac_exec_ext in '' $ac_executable_extensions; do
34801  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34802    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34803    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34804    break 2
34805  fi
34806done
34807  done
34808IFS=$as_save_IFS
34809
34810  ;;
34811esac
34812fi
34813STRIP=$ac_cv_path_STRIP
34814if test -n "$STRIP"; then
34815  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34816$as_echo "$STRIP" >&6; }
34817else
34818  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34819$as_echo "no" >&6; }
34820fi
34821
34822
34823  test -n "$STRIP" && break
34824done
34825
34826    else
34827      # If it succeeded, then it was overridden by the user. We will use it
34828      # for the tool.
34829
34830      # First remove it from the list of overridden variables, so we can test
34831      # for unknown variables in the end.
34832      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
34833
34834      # Check if the provided tool contains a complete path.
34835      tool_specified="$STRIP"
34836      tool_basename="${tool_specified##*/}"
34837      if test "x$tool_basename" = "x$tool_specified"; then
34838        # A command without a complete path is provided, search $PATH.
34839        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
34840$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
34841        # Extract the first word of "$tool_basename", so it can be a program name with args.
34842set dummy $tool_basename; ac_word=$2
34843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34844$as_echo_n "checking for $ac_word... " >&6; }
34845if ${ac_cv_path_STRIP+:} false; then :
34846  $as_echo_n "(cached) " >&6
34847else
34848  case $STRIP in
34849  [\\/]* | ?:[\\/]*)
34850  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34851  ;;
34852  *)
34853  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34854for as_dir in $PATH
34855do
34856  IFS=$as_save_IFS
34857  test -z "$as_dir" && as_dir=.
34858    for ac_exec_ext in '' $ac_executable_extensions; do
34859  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34860    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34861    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34862    break 2
34863  fi
34864done
34865  done
34866IFS=$as_save_IFS
34867
34868  ;;
34869esac
34870fi
34871STRIP=$ac_cv_path_STRIP
34872if test -n "$STRIP"; then
34873  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34874$as_echo "$STRIP" >&6; }
34875else
34876  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34877$as_echo "no" >&6; }
34878fi
34879
34880
34881        if test "x$STRIP" = x; then
34882          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
34883        fi
34884      else
34885        # Otherwise we believe it is a complete path. Use it as it is.
34886        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
34887$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
34888        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
34889$as_echo_n "checking for STRIP... " >&6; }
34890        if test ! -x "$tool_specified"; then
34891          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
34892$as_echo "not found" >&6; }
34893          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
34894        fi
34895        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
34896$as_echo "$tool_specified" >&6; }
34897      fi
34898    fi
34899  fi
34900
34901
34902
34903  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34904
34905  # First separate the path from the arguments. This will split at the first
34906  # space.
34907  complete="$STRIP"
34908  path="${complete%% *}"
34909  tmp="$complete EOL"
34910  arguments="${tmp#* }"
34911
34912  # Input might be given as Windows format, start by converting to
34913  # unix format.
34914  new_path=`$CYGPATH -u "$path"`
34915
34916  # Now try to locate executable using which
34917  new_path=`$WHICH "$new_path" 2> /dev/null`
34918  # bat and cmd files are not always considered executable in cygwin causing which
34919  # to not find them
34920  if test "x$new_path" = x \
34921      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34922      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34923    new_path=`$CYGPATH -u "$path"`
34924  fi
34925  if test "x$new_path" = x; then
34926    # Oops. Which didn't find the executable.
34927    # The splitting of arguments from the executable at a space might have been incorrect,
34928    # since paths with space are more likely in Windows. Give it another try with the whole
34929    # argument.
34930    path="$complete"
34931    arguments="EOL"
34932    new_path=`$CYGPATH -u "$path"`
34933    new_path=`$WHICH "$new_path" 2> /dev/null`
34934    # bat and cmd files are not always considered executable in cygwin causing which
34935    # to not find them
34936    if test "x$new_path" = x \
34937        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34938        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34939      new_path=`$CYGPATH -u "$path"`
34940    fi
34941    if test "x$new_path" = x; then
34942      # It's still not found. Now this is an unrecoverable error.
34943      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34944$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34945      has_space=`$ECHO "$complete" | $GREP " "`
34946      if test "x$has_space" != x; then
34947        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34948$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34949      fi
34950      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34951    fi
34952  fi
34953
34954  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34955  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34956  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34957  # "foo.exe" is OK but "foo" is an error.
34958  #
34959  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34960  # It is also a way to make sure we got the proper file name for the real test later on.
34961  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34962  if test "x$test_shortpath" = x; then
34963    # Short path failed, file does not exist as specified.
34964    # Try adding .exe or .cmd
34965    if test -f "${new_path}.exe"; then
34966      input_to_shortpath="${new_path}.exe"
34967    elif test -f "${new_path}.cmd"; then
34968      input_to_shortpath="${new_path}.cmd"
34969    else
34970      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
34971$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
34972      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34973$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34974      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34975    fi
34976  else
34977    input_to_shortpath="$new_path"
34978  fi
34979
34980  # Call helper function which possibly converts this using DOS-style short mode.
34981  # If so, the updated path is stored in $new_path.
34982  new_path="$input_to_shortpath"
34983
34984  input_path="$input_to_shortpath"
34985  # Check if we need to convert this using DOS-style short mode. If the path
34986  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34987  # take no chances and rewrite it.
34988  # Note: m4 eats our [], so we need to use [ and ] instead.
34989  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34990  if test "x$has_forbidden_chars" != x; then
34991    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34992    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34993    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34994    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34995      # Going to short mode and back again did indeed matter. Since short mode is
34996      # case insensitive, let's make it lowercase to improve readability.
34997      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34998      # Now convert it back to Unix-stile (cygpath)
34999      input_path=`$CYGPATH -u "$shortmode_path"`
35000      new_path="$input_path"
35001    fi
35002  fi
35003
35004  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35005  if test "x$test_cygdrive_prefix" = x; then
35006    # As a simple fix, exclude /usr/bin since it's not a real path.
35007    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35008      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35009      # a path prefixed by /cygdrive for fixpath to work.
35010      new_path="$CYGWIN_ROOT_PATH$input_path"
35011    fi
35012  fi
35013
35014  # remove trailing .exe if any
35015  new_path="${new_path/%.exe/}"
35016
35017  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35018
35019  # First separate the path from the arguments. This will split at the first
35020  # space.
35021  complete="$STRIP"
35022  path="${complete%% *}"
35023  tmp="$complete EOL"
35024  arguments="${tmp#* }"
35025
35026  # Input might be given as Windows format, start by converting to
35027  # unix format.
35028  new_path="$path"
35029
35030  windows_path="$new_path"
35031  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35032    unix_path=`$CYGPATH -u "$windows_path"`
35033    new_path="$unix_path"
35034  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35035    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35036    new_path="$unix_path"
35037  fi
35038
35039
35040  # Now try to locate executable using which
35041  new_path=`$WHICH "$new_path" 2> /dev/null`
35042
35043  if test "x$new_path" = x; then
35044    # Oops. Which didn't find the executable.
35045    # The splitting of arguments from the executable at a space might have been incorrect,
35046    # since paths with space are more likely in Windows. Give it another try with the whole
35047    # argument.
35048    path="$complete"
35049    arguments="EOL"
35050    new_path="$path"
35051
35052  windows_path="$new_path"
35053  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35054    unix_path=`$CYGPATH -u "$windows_path"`
35055    new_path="$unix_path"
35056  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35057    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35058    new_path="$unix_path"
35059  fi
35060
35061
35062    new_path=`$WHICH "$new_path" 2> /dev/null`
35063
35064    if test "x$new_path" = x; then
35065      # It's still not found. Now this is an unrecoverable error.
35066      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35067$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35068      has_space=`$ECHO "$complete" | $GREP " "`
35069      if test "x$has_space" != x; then
35070        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35071$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35072      fi
35073      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35074    fi
35075  fi
35076
35077  # Now new_path has a complete unix path to the binary
35078  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35079    # Keep paths in /bin as-is, but remove trailing .exe if any
35080    new_path="${new_path/%.exe/}"
35081    # Do not save /bin paths to all_fixpath_prefixes!
35082  else
35083    # Not in mixed or Windows style, start by that.
35084    new_path=`cmd //c echo $new_path`
35085
35086  input_path="$new_path"
35087  # Check if we need to convert this using DOS-style short mode. If the path
35088  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35089  # take no chances and rewrite it.
35090  # Note: m4 eats our [], so we need to use [ and ] instead.
35091  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35092  if test "x$has_forbidden_chars" != x; then
35093    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35094    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35095  fi
35096
35097    # Output is in $new_path
35098
35099  windows_path="$new_path"
35100  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35101    unix_path=`$CYGPATH -u "$windows_path"`
35102    new_path="$unix_path"
35103  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35104    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35105    new_path="$unix_path"
35106  fi
35107
35108    # remove trailing .exe if any
35109    new_path="${new_path/%.exe/}"
35110
35111    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35112    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35113  fi
35114
35115  else
35116    # We're on a posix platform. Hooray! :)
35117    # First separate the path from the arguments. This will split at the first
35118    # space.
35119    complete="$STRIP"
35120    path="${complete%% *}"
35121    tmp="$complete EOL"
35122    arguments="${tmp#* }"
35123
35124    # Cannot rely on the command "which" here since it doesn't always work.
35125    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35126    if test -z "$is_absolute_path"; then
35127      # Path to executable is not absolute. Find it.
35128      IFS_save="$IFS"
35129      IFS=:
35130      for p in $PATH; do
35131        if test -f "$p/$path" && test -x "$p/$path"; then
35132          new_path="$p/$path"
35133          break
35134        fi
35135      done
35136      IFS="$IFS_save"
35137    else
35138      # This is an absolute path, we can use it without further modifications.
35139      new_path="$path"
35140    fi
35141
35142    if test "x$new_path" = x; then
35143      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35144$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35145      has_space=`$ECHO "$complete" | $GREP " "`
35146      if test "x$has_space" != x; then
35147        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35148$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35149      fi
35150      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35151    fi
35152  fi
35153
35154  # Now join together the path and the arguments once again
35155  if test "x$arguments" != xEOL; then
35156    new_complete="$new_path ${arguments% *}"
35157  else
35158    new_complete="$new_path"
35159  fi
35160
35161  if test "x$complete" != "x$new_complete"; then
35162    STRIP="$new_complete"
35163    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
35164$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
35165  fi
35166
35167
35168
35169  # Publish this variable in the help.
35170
35171
35172  if test "x$NM" = x; then
35173    # The variable is not set by user, try to locate tool using the code snippet
35174    for ac_prog in nm
35175do
35176  # Extract the first word of "$ac_prog", so it can be a program name with args.
35177set dummy $ac_prog; ac_word=$2
35178{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35179$as_echo_n "checking for $ac_word... " >&6; }
35180if ${ac_cv_path_NM+:} false; then :
35181  $as_echo_n "(cached) " >&6
35182else
35183  case $NM in
35184  [\\/]* | ?:[\\/]*)
35185  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35186  ;;
35187  *)
35188  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35189for as_dir in $PATH
35190do
35191  IFS=$as_save_IFS
35192  test -z "$as_dir" && as_dir=.
35193    for ac_exec_ext in '' $ac_executable_extensions; do
35194  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35195    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35196    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35197    break 2
35198  fi
35199done
35200  done
35201IFS=$as_save_IFS
35202
35203  ;;
35204esac
35205fi
35206NM=$ac_cv_path_NM
35207if test -n "$NM"; then
35208  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35209$as_echo "$NM" >&6; }
35210else
35211  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35212$as_echo "no" >&6; }
35213fi
35214
35215
35216  test -n "$NM" && break
35217done
35218
35219  else
35220    # The variable is set, but is it from the command line or the environment?
35221
35222    # Try to remove the string !NM! from our list.
35223    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
35224    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35225      # If it failed, the variable was not from the command line. Ignore it,
35226      # but warn the user (except for BASH, which is always set by the calling BASH).
35227      if test "xNM" != xBASH; then
35228        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
35229$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
35230      fi
35231      # Try to locate tool using the code snippet
35232      for ac_prog in nm
35233do
35234  # Extract the first word of "$ac_prog", so it can be a program name with args.
35235set dummy $ac_prog; ac_word=$2
35236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35237$as_echo_n "checking for $ac_word... " >&6; }
35238if ${ac_cv_path_NM+:} false; then :
35239  $as_echo_n "(cached) " >&6
35240else
35241  case $NM in
35242  [\\/]* | ?:[\\/]*)
35243  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35244  ;;
35245  *)
35246  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35247for as_dir in $PATH
35248do
35249  IFS=$as_save_IFS
35250  test -z "$as_dir" && as_dir=.
35251    for ac_exec_ext in '' $ac_executable_extensions; do
35252  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35253    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35254    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35255    break 2
35256  fi
35257done
35258  done
35259IFS=$as_save_IFS
35260
35261  ;;
35262esac
35263fi
35264NM=$ac_cv_path_NM
35265if test -n "$NM"; then
35266  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35267$as_echo "$NM" >&6; }
35268else
35269  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35270$as_echo "no" >&6; }
35271fi
35272
35273
35274  test -n "$NM" && break
35275done
35276
35277    else
35278      # If it succeeded, then it was overridden by the user. We will use it
35279      # for the tool.
35280
35281      # First remove it from the list of overridden variables, so we can test
35282      # for unknown variables in the end.
35283      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35284
35285      # Check if the provided tool contains a complete path.
35286      tool_specified="$NM"
35287      tool_basename="${tool_specified##*/}"
35288      if test "x$tool_basename" = "x$tool_specified"; then
35289        # A command without a complete path is provided, search $PATH.
35290        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
35291$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
35292        # Extract the first word of "$tool_basename", so it can be a program name with args.
35293set dummy $tool_basename; ac_word=$2
35294{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35295$as_echo_n "checking for $ac_word... " >&6; }
35296if ${ac_cv_path_NM+:} false; then :
35297  $as_echo_n "(cached) " >&6
35298else
35299  case $NM in
35300  [\\/]* | ?:[\\/]*)
35301  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35302  ;;
35303  *)
35304  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35305for as_dir in $PATH
35306do
35307  IFS=$as_save_IFS
35308  test -z "$as_dir" && as_dir=.
35309    for ac_exec_ext in '' $ac_executable_extensions; do
35310  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35311    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35312    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35313    break 2
35314  fi
35315done
35316  done
35317IFS=$as_save_IFS
35318
35319  ;;
35320esac
35321fi
35322NM=$ac_cv_path_NM
35323if test -n "$NM"; then
35324  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35325$as_echo "$NM" >&6; }
35326else
35327  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35328$as_echo "no" >&6; }
35329fi
35330
35331
35332        if test "x$NM" = x; then
35333          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35334        fi
35335      else
35336        # Otherwise we believe it is a complete path. Use it as it is.
35337        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
35338$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
35339        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
35340$as_echo_n "checking for NM... " >&6; }
35341        if test ! -x "$tool_specified"; then
35342          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35343$as_echo "not found" >&6; }
35344          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
35345        fi
35346        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35347$as_echo "$tool_specified" >&6; }
35348      fi
35349    fi
35350  fi
35351
35352
35353
35354  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35355
35356  # First separate the path from the arguments. This will split at the first
35357  # space.
35358  complete="$NM"
35359  path="${complete%% *}"
35360  tmp="$complete EOL"
35361  arguments="${tmp#* }"
35362
35363  # Input might be given as Windows format, start by converting to
35364  # unix format.
35365  new_path=`$CYGPATH -u "$path"`
35366
35367  # Now try to locate executable using which
35368  new_path=`$WHICH "$new_path" 2> /dev/null`
35369  # bat and cmd files are not always considered executable in cygwin causing which
35370  # to not find them
35371  if test "x$new_path" = x \
35372      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35373      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35374    new_path=`$CYGPATH -u "$path"`
35375  fi
35376  if test "x$new_path" = x; then
35377    # Oops. Which didn't find the executable.
35378    # The splitting of arguments from the executable at a space might have been incorrect,
35379    # since paths with space are more likely in Windows. Give it another try with the whole
35380    # argument.
35381    path="$complete"
35382    arguments="EOL"
35383    new_path=`$CYGPATH -u "$path"`
35384    new_path=`$WHICH "$new_path" 2> /dev/null`
35385    # bat and cmd files are not always considered executable in cygwin causing which
35386    # to not find them
35387    if test "x$new_path" = x \
35388        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35389        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35390      new_path=`$CYGPATH -u "$path"`
35391    fi
35392    if test "x$new_path" = x; then
35393      # It's still not found. Now this is an unrecoverable error.
35394      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35395$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35396      has_space=`$ECHO "$complete" | $GREP " "`
35397      if test "x$has_space" != x; then
35398        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35399$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35400      fi
35401      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35402    fi
35403  fi
35404
35405  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35406  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35407  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35408  # "foo.exe" is OK but "foo" is an error.
35409  #
35410  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35411  # It is also a way to make sure we got the proper file name for the real test later on.
35412  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35413  if test "x$test_shortpath" = x; then
35414    # Short path failed, file does not exist as specified.
35415    # Try adding .exe or .cmd
35416    if test -f "${new_path}.exe"; then
35417      input_to_shortpath="${new_path}.exe"
35418    elif test -f "${new_path}.cmd"; then
35419      input_to_shortpath="${new_path}.cmd"
35420    else
35421      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
35422$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
35423      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35424$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35425      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35426    fi
35427  else
35428    input_to_shortpath="$new_path"
35429  fi
35430
35431  # Call helper function which possibly converts this using DOS-style short mode.
35432  # If so, the updated path is stored in $new_path.
35433  new_path="$input_to_shortpath"
35434
35435  input_path="$input_to_shortpath"
35436  # Check if we need to convert this using DOS-style short mode. If the path
35437  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35438  # take no chances and rewrite it.
35439  # Note: m4 eats our [], so we need to use [ and ] instead.
35440  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35441  if test "x$has_forbidden_chars" != x; then
35442    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35443    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35444    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35445    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35446      # Going to short mode and back again did indeed matter. Since short mode is
35447      # case insensitive, let's make it lowercase to improve readability.
35448      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35449      # Now convert it back to Unix-stile (cygpath)
35450      input_path=`$CYGPATH -u "$shortmode_path"`
35451      new_path="$input_path"
35452    fi
35453  fi
35454
35455  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35456  if test "x$test_cygdrive_prefix" = x; then
35457    # As a simple fix, exclude /usr/bin since it's not a real path.
35458    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35459      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35460      # a path prefixed by /cygdrive for fixpath to work.
35461      new_path="$CYGWIN_ROOT_PATH$input_path"
35462    fi
35463  fi
35464
35465  # remove trailing .exe if any
35466  new_path="${new_path/%.exe/}"
35467
35468  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35469
35470  # First separate the path from the arguments. This will split at the first
35471  # space.
35472  complete="$NM"
35473  path="${complete%% *}"
35474  tmp="$complete EOL"
35475  arguments="${tmp#* }"
35476
35477  # Input might be given as Windows format, start by converting to
35478  # unix format.
35479  new_path="$path"
35480
35481  windows_path="$new_path"
35482  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35483    unix_path=`$CYGPATH -u "$windows_path"`
35484    new_path="$unix_path"
35485  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35486    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35487    new_path="$unix_path"
35488  fi
35489
35490
35491  # Now try to locate executable using which
35492  new_path=`$WHICH "$new_path" 2> /dev/null`
35493
35494  if test "x$new_path" = x; then
35495    # Oops. Which didn't find the executable.
35496    # The splitting of arguments from the executable at a space might have been incorrect,
35497    # since paths with space are more likely in Windows. Give it another try with the whole
35498    # argument.
35499    path="$complete"
35500    arguments="EOL"
35501    new_path="$path"
35502
35503  windows_path="$new_path"
35504  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35505    unix_path=`$CYGPATH -u "$windows_path"`
35506    new_path="$unix_path"
35507  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35508    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35509    new_path="$unix_path"
35510  fi
35511
35512
35513    new_path=`$WHICH "$new_path" 2> /dev/null`
35514
35515    if test "x$new_path" = x; then
35516      # It's still not found. Now this is an unrecoverable error.
35517      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35518$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35519      has_space=`$ECHO "$complete" | $GREP " "`
35520      if test "x$has_space" != x; then
35521        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35522$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35523      fi
35524      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35525    fi
35526  fi
35527
35528  # Now new_path has a complete unix path to the binary
35529  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35530    # Keep paths in /bin as-is, but remove trailing .exe if any
35531    new_path="${new_path/%.exe/}"
35532    # Do not save /bin paths to all_fixpath_prefixes!
35533  else
35534    # Not in mixed or Windows style, start by that.
35535    new_path=`cmd //c echo $new_path`
35536
35537  input_path="$new_path"
35538  # Check if we need to convert this using DOS-style short mode. If the path
35539  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35540  # take no chances and rewrite it.
35541  # Note: m4 eats our [], so we need to use [ and ] instead.
35542  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35543  if test "x$has_forbidden_chars" != x; then
35544    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35545    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35546  fi
35547
35548    # Output is in $new_path
35549
35550  windows_path="$new_path"
35551  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35552    unix_path=`$CYGPATH -u "$windows_path"`
35553    new_path="$unix_path"
35554  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35555    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35556    new_path="$unix_path"
35557  fi
35558
35559    # remove trailing .exe if any
35560    new_path="${new_path/%.exe/}"
35561
35562    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35563    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35564  fi
35565
35566  else
35567    # We're on a posix platform. Hooray! :)
35568    # First separate the path from the arguments. This will split at the first
35569    # space.
35570    complete="$NM"
35571    path="${complete%% *}"
35572    tmp="$complete EOL"
35573    arguments="${tmp#* }"
35574
35575    # Cannot rely on the command "which" here since it doesn't always work.
35576    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35577    if test -z "$is_absolute_path"; then
35578      # Path to executable is not absolute. Find it.
35579      IFS_save="$IFS"
35580      IFS=:
35581      for p in $PATH; do
35582        if test -f "$p/$path" && test -x "$p/$path"; then
35583          new_path="$p/$path"
35584          break
35585        fi
35586      done
35587      IFS="$IFS_save"
35588    else
35589      # This is an absolute path, we can use it without further modifications.
35590      new_path="$path"
35591    fi
35592
35593    if test "x$new_path" = x; then
35594      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35595$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35596      has_space=`$ECHO "$complete" | $GREP " "`
35597      if test "x$has_space" != x; then
35598        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35599$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35600      fi
35601      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35602    fi
35603  fi
35604
35605  # Now join together the path and the arguments once again
35606  if test "x$arguments" != xEOL; then
35607    new_complete="$new_path ${arguments% *}"
35608  else
35609    new_complete="$new_path"
35610  fi
35611
35612  if test "x$complete" != "x$new_complete"; then
35613    NM="$new_complete"
35614    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
35615$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
35616  fi
35617
35618
35619
35620  # Publish this variable in the help.
35621
35622
35623  if test "x$GNM" = x; then
35624    # The variable is not set by user, try to locate tool using the code snippet
35625    for ac_prog in gnm
35626do
35627  # Extract the first word of "$ac_prog", so it can be a program name with args.
35628set dummy $ac_prog; ac_word=$2
35629{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35630$as_echo_n "checking for $ac_word... " >&6; }
35631if ${ac_cv_path_GNM+:} false; then :
35632  $as_echo_n "(cached) " >&6
35633else
35634  case $GNM in
35635  [\\/]* | ?:[\\/]*)
35636  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35637  ;;
35638  *)
35639  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35640for as_dir in $PATH
35641do
35642  IFS=$as_save_IFS
35643  test -z "$as_dir" && as_dir=.
35644    for ac_exec_ext in '' $ac_executable_extensions; do
35645  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35646    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35647    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35648    break 2
35649  fi
35650done
35651  done
35652IFS=$as_save_IFS
35653
35654  ;;
35655esac
35656fi
35657GNM=$ac_cv_path_GNM
35658if test -n "$GNM"; then
35659  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35660$as_echo "$GNM" >&6; }
35661else
35662  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35663$as_echo "no" >&6; }
35664fi
35665
35666
35667  test -n "$GNM" && break
35668done
35669
35670  else
35671    # The variable is set, but is it from the command line or the environment?
35672
35673    # Try to remove the string !GNM! from our list.
35674    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
35675    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35676      # If it failed, the variable was not from the command line. Ignore it,
35677      # but warn the user (except for BASH, which is always set by the calling BASH).
35678      if test "xGNM" != xBASH; then
35679        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
35680$as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
35681      fi
35682      # Try to locate tool using the code snippet
35683      for ac_prog in gnm
35684do
35685  # Extract the first word of "$ac_prog", so it can be a program name with args.
35686set dummy $ac_prog; ac_word=$2
35687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35688$as_echo_n "checking for $ac_word... " >&6; }
35689if ${ac_cv_path_GNM+:} false; then :
35690  $as_echo_n "(cached) " >&6
35691else
35692  case $GNM in
35693  [\\/]* | ?:[\\/]*)
35694  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35695  ;;
35696  *)
35697  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35698for as_dir in $PATH
35699do
35700  IFS=$as_save_IFS
35701  test -z "$as_dir" && as_dir=.
35702    for ac_exec_ext in '' $ac_executable_extensions; do
35703  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35704    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35705    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35706    break 2
35707  fi
35708done
35709  done
35710IFS=$as_save_IFS
35711
35712  ;;
35713esac
35714fi
35715GNM=$ac_cv_path_GNM
35716if test -n "$GNM"; then
35717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35718$as_echo "$GNM" >&6; }
35719else
35720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35721$as_echo "no" >&6; }
35722fi
35723
35724
35725  test -n "$GNM" && break
35726done
35727
35728    else
35729      # If it succeeded, then it was overridden by the user. We will use it
35730      # for the tool.
35731
35732      # First remove it from the list of overridden variables, so we can test
35733      # for unknown variables in the end.
35734      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35735
35736      # Check if the provided tool contains a complete path.
35737      tool_specified="$GNM"
35738      tool_basename="${tool_specified##*/}"
35739      if test "x$tool_basename" = "x$tool_specified"; then
35740        # A command without a complete path is provided, search $PATH.
35741        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
35742$as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
35743        # Extract the first word of "$tool_basename", so it can be a program name with args.
35744set dummy $tool_basename; ac_word=$2
35745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35746$as_echo_n "checking for $ac_word... " >&6; }
35747if ${ac_cv_path_GNM+:} false; then :
35748  $as_echo_n "(cached) " >&6
35749else
35750  case $GNM in
35751  [\\/]* | ?:[\\/]*)
35752  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35753  ;;
35754  *)
35755  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35756for as_dir in $PATH
35757do
35758  IFS=$as_save_IFS
35759  test -z "$as_dir" && as_dir=.
35760    for ac_exec_ext in '' $ac_executable_extensions; do
35761  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35762    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35763    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35764    break 2
35765  fi
35766done
35767  done
35768IFS=$as_save_IFS
35769
35770  ;;
35771esac
35772fi
35773GNM=$ac_cv_path_GNM
35774if test -n "$GNM"; then
35775  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35776$as_echo "$GNM" >&6; }
35777else
35778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35779$as_echo "no" >&6; }
35780fi
35781
35782
35783        if test "x$GNM" = x; then
35784          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35785        fi
35786      else
35787        # Otherwise we believe it is a complete path. Use it as it is.
35788        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
35789$as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
35790        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
35791$as_echo_n "checking for GNM... " >&6; }
35792        if test ! -x "$tool_specified"; then
35793          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35794$as_echo "not found" >&6; }
35795          as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
35796        fi
35797        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35798$as_echo "$tool_specified" >&6; }
35799      fi
35800    fi
35801  fi
35802
35803
35804
35805  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35806
35807  # First separate the path from the arguments. This will split at the first
35808  # space.
35809  complete="$GNM"
35810  path="${complete%% *}"
35811  tmp="$complete EOL"
35812  arguments="${tmp#* }"
35813
35814  # Input might be given as Windows format, start by converting to
35815  # unix format.
35816  new_path=`$CYGPATH -u "$path"`
35817
35818  # Now try to locate executable using which
35819  new_path=`$WHICH "$new_path" 2> /dev/null`
35820  # bat and cmd files are not always considered executable in cygwin causing which
35821  # to not find them
35822  if test "x$new_path" = x \
35823      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35824      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35825    new_path=`$CYGPATH -u "$path"`
35826  fi
35827  if test "x$new_path" = x; then
35828    # Oops. Which didn't find the executable.
35829    # The splitting of arguments from the executable at a space might have been incorrect,
35830    # since paths with space are more likely in Windows. Give it another try with the whole
35831    # argument.
35832    path="$complete"
35833    arguments="EOL"
35834    new_path=`$CYGPATH -u "$path"`
35835    new_path=`$WHICH "$new_path" 2> /dev/null`
35836    # bat and cmd files are not always considered executable in cygwin causing which
35837    # to not find them
35838    if test "x$new_path" = x \
35839        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35840        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35841      new_path=`$CYGPATH -u "$path"`
35842    fi
35843    if test "x$new_path" = x; then
35844      # It's still not found. Now this is an unrecoverable error.
35845      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35846$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35847      has_space=`$ECHO "$complete" | $GREP " "`
35848      if test "x$has_space" != x; then
35849        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35850$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35851      fi
35852      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35853    fi
35854  fi
35855
35856  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35857  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35858  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35859  # "foo.exe" is OK but "foo" is an error.
35860  #
35861  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35862  # It is also a way to make sure we got the proper file name for the real test later on.
35863  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35864  if test "x$test_shortpath" = x; then
35865    # Short path failed, file does not exist as specified.
35866    # Try adding .exe or .cmd
35867    if test -f "${new_path}.exe"; then
35868      input_to_shortpath="${new_path}.exe"
35869    elif test -f "${new_path}.cmd"; then
35870      input_to_shortpath="${new_path}.cmd"
35871    else
35872      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
35873$as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
35874      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35875$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35876      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35877    fi
35878  else
35879    input_to_shortpath="$new_path"
35880  fi
35881
35882  # Call helper function which possibly converts this using DOS-style short mode.
35883  # If so, the updated path is stored in $new_path.
35884  new_path="$input_to_shortpath"
35885
35886  input_path="$input_to_shortpath"
35887  # Check if we need to convert this using DOS-style short mode. If the path
35888  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35889  # take no chances and rewrite it.
35890  # Note: m4 eats our [], so we need to use [ and ] instead.
35891  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35892  if test "x$has_forbidden_chars" != x; then
35893    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35894    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35895    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35896    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35897      # Going to short mode and back again did indeed matter. Since short mode is
35898      # case insensitive, let's make it lowercase to improve readability.
35899      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35900      # Now convert it back to Unix-stile (cygpath)
35901      input_path=`$CYGPATH -u "$shortmode_path"`
35902      new_path="$input_path"
35903    fi
35904  fi
35905
35906  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35907  if test "x$test_cygdrive_prefix" = x; then
35908    # As a simple fix, exclude /usr/bin since it's not a real path.
35909    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35910      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35911      # a path prefixed by /cygdrive for fixpath to work.
35912      new_path="$CYGWIN_ROOT_PATH$input_path"
35913    fi
35914  fi
35915
35916  # remove trailing .exe if any
35917  new_path="${new_path/%.exe/}"
35918
35919  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35920
35921  # First separate the path from the arguments. This will split at the first
35922  # space.
35923  complete="$GNM"
35924  path="${complete%% *}"
35925  tmp="$complete EOL"
35926  arguments="${tmp#* }"
35927
35928  # Input might be given as Windows format, start by converting to
35929  # unix format.
35930  new_path="$path"
35931
35932  windows_path="$new_path"
35933  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35934    unix_path=`$CYGPATH -u "$windows_path"`
35935    new_path="$unix_path"
35936  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35937    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35938    new_path="$unix_path"
35939  fi
35940
35941
35942  # Now try to locate executable using which
35943  new_path=`$WHICH "$new_path" 2> /dev/null`
35944
35945  if test "x$new_path" = x; then
35946    # Oops. Which didn't find the executable.
35947    # The splitting of arguments from the executable at a space might have been incorrect,
35948    # since paths with space are more likely in Windows. Give it another try with the whole
35949    # argument.
35950    path="$complete"
35951    arguments="EOL"
35952    new_path="$path"
35953
35954  windows_path="$new_path"
35955  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35956    unix_path=`$CYGPATH -u "$windows_path"`
35957    new_path="$unix_path"
35958  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35959    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35960    new_path="$unix_path"
35961  fi
35962
35963
35964    new_path=`$WHICH "$new_path" 2> /dev/null`
35965
35966    if test "x$new_path" = x; then
35967      # It's still not found. Now this is an unrecoverable error.
35968      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35969$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35970      has_space=`$ECHO "$complete" | $GREP " "`
35971      if test "x$has_space" != x; then
35972        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35973$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35974      fi
35975      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35976    fi
35977  fi
35978
35979  # Now new_path has a complete unix path to the binary
35980  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35981    # Keep paths in /bin as-is, but remove trailing .exe if any
35982    new_path="${new_path/%.exe/}"
35983    # Do not save /bin paths to all_fixpath_prefixes!
35984  else
35985    # Not in mixed or Windows style, start by that.
35986    new_path=`cmd //c echo $new_path`
35987
35988  input_path="$new_path"
35989  # Check if we need to convert this using DOS-style short mode. If the path
35990  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35991  # take no chances and rewrite it.
35992  # Note: m4 eats our [], so we need to use [ and ] instead.
35993  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35994  if test "x$has_forbidden_chars" != x; then
35995    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35996    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35997  fi
35998
35999    # Output is in $new_path
36000
36001  windows_path="$new_path"
36002  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36003    unix_path=`$CYGPATH -u "$windows_path"`
36004    new_path="$unix_path"
36005  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36006    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36007    new_path="$unix_path"
36008  fi
36009
36010    # remove trailing .exe if any
36011    new_path="${new_path/%.exe/}"
36012
36013    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36014    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36015  fi
36016
36017  else
36018    # We're on a posix platform. Hooray! :)
36019    # First separate the path from the arguments. This will split at the first
36020    # space.
36021    complete="$GNM"
36022    path="${complete%% *}"
36023    tmp="$complete EOL"
36024    arguments="${tmp#* }"
36025
36026    # Cannot rely on the command "which" here since it doesn't always work.
36027    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36028    if test -z "$is_absolute_path"; then
36029      # Path to executable is not absolute. Find it.
36030      IFS_save="$IFS"
36031      IFS=:
36032      for p in $PATH; do
36033        if test -f "$p/$path" && test -x "$p/$path"; then
36034          new_path="$p/$path"
36035          break
36036        fi
36037      done
36038      IFS="$IFS_save"
36039    else
36040      # This is an absolute path, we can use it without further modifications.
36041      new_path="$path"
36042    fi
36043
36044    if test "x$new_path" = x; then
36045      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
36046$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
36047      has_space=`$ECHO "$complete" | $GREP " "`
36048      if test "x$has_space" != x; then
36049        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36050$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36051      fi
36052      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
36053    fi
36054  fi
36055
36056  # Now join together the path and the arguments once again
36057  if test "x$arguments" != xEOL; then
36058    new_complete="$new_path ${arguments% *}"
36059  else
36060    new_complete="$new_path"
36061  fi
36062
36063  if test "x$complete" != "x$new_complete"; then
36064    GNM="$new_complete"
36065    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
36066$as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
36067  fi
36068
36069
36070
36071
36072  # Publish this variable in the help.
36073
36074
36075  if test "x$MCS" = x; then
36076    # The variable is not set by user, try to locate tool using the code snippet
36077    for ac_prog in mcs
36078do
36079  # Extract the first word of "$ac_prog", so it can be a program name with args.
36080set dummy $ac_prog; ac_word=$2
36081{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36082$as_echo_n "checking for $ac_word... " >&6; }
36083if ${ac_cv_path_MCS+:} false; then :
36084  $as_echo_n "(cached) " >&6
36085else
36086  case $MCS in
36087  [\\/]* | ?:[\\/]*)
36088  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36089  ;;
36090  *)
36091  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36092for as_dir in $PATH
36093do
36094  IFS=$as_save_IFS
36095  test -z "$as_dir" && as_dir=.
36096    for ac_exec_ext in '' $ac_executable_extensions; do
36097  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36098    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36099    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36100    break 2
36101  fi
36102done
36103  done
36104IFS=$as_save_IFS
36105
36106  ;;
36107esac
36108fi
36109MCS=$ac_cv_path_MCS
36110if test -n "$MCS"; then
36111  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36112$as_echo "$MCS" >&6; }
36113else
36114  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36115$as_echo "no" >&6; }
36116fi
36117
36118
36119  test -n "$MCS" && break
36120done
36121
36122  else
36123    # The variable is set, but is it from the command line or the environment?
36124
36125    # Try to remove the string !MCS! from our list.
36126    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
36127    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36128      # If it failed, the variable was not from the command line. Ignore it,
36129      # but warn the user (except for BASH, which is always set by the calling BASH).
36130      if test "xMCS" != xBASH; then
36131        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
36132$as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
36133      fi
36134      # Try to locate tool using the code snippet
36135      for ac_prog in mcs
36136do
36137  # Extract the first word of "$ac_prog", so it can be a program name with args.
36138set dummy $ac_prog; ac_word=$2
36139{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36140$as_echo_n "checking for $ac_word... " >&6; }
36141if ${ac_cv_path_MCS+:} false; then :
36142  $as_echo_n "(cached) " >&6
36143else
36144  case $MCS in
36145  [\\/]* | ?:[\\/]*)
36146  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36147  ;;
36148  *)
36149  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36150for as_dir in $PATH
36151do
36152  IFS=$as_save_IFS
36153  test -z "$as_dir" && as_dir=.
36154    for ac_exec_ext in '' $ac_executable_extensions; do
36155  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36156    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36157    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36158    break 2
36159  fi
36160done
36161  done
36162IFS=$as_save_IFS
36163
36164  ;;
36165esac
36166fi
36167MCS=$ac_cv_path_MCS
36168if test -n "$MCS"; then
36169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36170$as_echo "$MCS" >&6; }
36171else
36172  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36173$as_echo "no" >&6; }
36174fi
36175
36176
36177  test -n "$MCS" && break
36178done
36179
36180    else
36181      # If it succeeded, then it was overridden by the user. We will use it
36182      # for the tool.
36183
36184      # First remove it from the list of overridden variables, so we can test
36185      # for unknown variables in the end.
36186      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36187
36188      # Check if the provided tool contains a complete path.
36189      tool_specified="$MCS"
36190      tool_basename="${tool_specified##*/}"
36191      if test "x$tool_basename" = "x$tool_specified"; then
36192        # A command without a complete path is provided, search $PATH.
36193        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
36194$as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
36195        # Extract the first word of "$tool_basename", so it can be a program name with args.
36196set dummy $tool_basename; ac_word=$2
36197{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36198$as_echo_n "checking for $ac_word... " >&6; }
36199if ${ac_cv_path_MCS+:} false; then :
36200  $as_echo_n "(cached) " >&6
36201else
36202  case $MCS in
36203  [\\/]* | ?:[\\/]*)
36204  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36205  ;;
36206  *)
36207  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36208for as_dir in $PATH
36209do
36210  IFS=$as_save_IFS
36211  test -z "$as_dir" && as_dir=.
36212    for ac_exec_ext in '' $ac_executable_extensions; do
36213  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36214    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36215    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36216    break 2
36217  fi
36218done
36219  done
36220IFS=$as_save_IFS
36221
36222  ;;
36223esac
36224fi
36225MCS=$ac_cv_path_MCS
36226if test -n "$MCS"; then
36227  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36228$as_echo "$MCS" >&6; }
36229else
36230  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36231$as_echo "no" >&6; }
36232fi
36233
36234
36235        if test "x$MCS" = x; then
36236          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36237        fi
36238      else
36239        # Otherwise we believe it is a complete path. Use it as it is.
36240        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
36241$as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
36242        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
36243$as_echo_n "checking for MCS... " >&6; }
36244        if test ! -x "$tool_specified"; then
36245          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36246$as_echo "not found" >&6; }
36247          as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
36248        fi
36249        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36250$as_echo "$tool_specified" >&6; }
36251      fi
36252    fi
36253  fi
36254
36255
36256
36257  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36258
36259  # First separate the path from the arguments. This will split at the first
36260  # space.
36261  complete="$MCS"
36262  path="${complete%% *}"
36263  tmp="$complete EOL"
36264  arguments="${tmp#* }"
36265
36266  # Input might be given as Windows format, start by converting to
36267  # unix format.
36268  new_path=`$CYGPATH -u "$path"`
36269
36270  # Now try to locate executable using which
36271  new_path=`$WHICH "$new_path" 2> /dev/null`
36272  # bat and cmd files are not always considered executable in cygwin causing which
36273  # to not find them
36274  if test "x$new_path" = x \
36275      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36276      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36277    new_path=`$CYGPATH -u "$path"`
36278  fi
36279  if test "x$new_path" = x; then
36280    # Oops. Which didn't find the executable.
36281    # The splitting of arguments from the executable at a space might have been incorrect,
36282    # since paths with space are more likely in Windows. Give it another try with the whole
36283    # argument.
36284    path="$complete"
36285    arguments="EOL"
36286    new_path=`$CYGPATH -u "$path"`
36287    new_path=`$WHICH "$new_path" 2> /dev/null`
36288    # bat and cmd files are not always considered executable in cygwin causing which
36289    # to not find them
36290    if test "x$new_path" = x \
36291        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36292        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36293      new_path=`$CYGPATH -u "$path"`
36294    fi
36295    if test "x$new_path" = x; then
36296      # It's still not found. Now this is an unrecoverable error.
36297      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36298$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36299      has_space=`$ECHO "$complete" | $GREP " "`
36300      if test "x$has_space" != x; then
36301        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36302$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36303      fi
36304      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36305    fi
36306  fi
36307
36308  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36309  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36310  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36311  # "foo.exe" is OK but "foo" is an error.
36312  #
36313  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36314  # It is also a way to make sure we got the proper file name for the real test later on.
36315  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36316  if test "x$test_shortpath" = x; then
36317    # Short path failed, file does not exist as specified.
36318    # Try adding .exe or .cmd
36319    if test -f "${new_path}.exe"; then
36320      input_to_shortpath="${new_path}.exe"
36321    elif test -f "${new_path}.cmd"; then
36322      input_to_shortpath="${new_path}.cmd"
36323    else
36324      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
36325$as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
36326      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36327$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36328      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36329    fi
36330  else
36331    input_to_shortpath="$new_path"
36332  fi
36333
36334  # Call helper function which possibly converts this using DOS-style short mode.
36335  # If so, the updated path is stored in $new_path.
36336  new_path="$input_to_shortpath"
36337
36338  input_path="$input_to_shortpath"
36339  # Check if we need to convert this using DOS-style short mode. If the path
36340  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36341  # take no chances and rewrite it.
36342  # Note: m4 eats our [], so we need to use [ and ] instead.
36343  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36344  if test "x$has_forbidden_chars" != x; then
36345    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36346    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36347    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36348    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36349      # Going to short mode and back again did indeed matter. Since short mode is
36350      # case insensitive, let's make it lowercase to improve readability.
36351      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36352      # Now convert it back to Unix-stile (cygpath)
36353      input_path=`$CYGPATH -u "$shortmode_path"`
36354      new_path="$input_path"
36355    fi
36356  fi
36357
36358  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36359  if test "x$test_cygdrive_prefix" = x; then
36360    # As a simple fix, exclude /usr/bin since it's not a real path.
36361    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36362      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36363      # a path prefixed by /cygdrive for fixpath to work.
36364      new_path="$CYGWIN_ROOT_PATH$input_path"
36365    fi
36366  fi
36367
36368  # remove trailing .exe if any
36369  new_path="${new_path/%.exe/}"
36370
36371  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36372
36373  # First separate the path from the arguments. This will split at the first
36374  # space.
36375  complete="$MCS"
36376  path="${complete%% *}"
36377  tmp="$complete EOL"
36378  arguments="${tmp#* }"
36379
36380  # Input might be given as Windows format, start by converting to
36381  # unix format.
36382  new_path="$path"
36383
36384  windows_path="$new_path"
36385  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36386    unix_path=`$CYGPATH -u "$windows_path"`
36387    new_path="$unix_path"
36388  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36389    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36390    new_path="$unix_path"
36391  fi
36392
36393
36394  # Now try to locate executable using which
36395  new_path=`$WHICH "$new_path" 2> /dev/null`
36396
36397  if test "x$new_path" = x; then
36398    # Oops. Which didn't find the executable.
36399    # The splitting of arguments from the executable at a space might have been incorrect,
36400    # since paths with space are more likely in Windows. Give it another try with the whole
36401    # argument.
36402    path="$complete"
36403    arguments="EOL"
36404    new_path="$path"
36405
36406  windows_path="$new_path"
36407  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36408    unix_path=`$CYGPATH -u "$windows_path"`
36409    new_path="$unix_path"
36410  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36411    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36412    new_path="$unix_path"
36413  fi
36414
36415
36416    new_path=`$WHICH "$new_path" 2> /dev/null`
36417
36418    if test "x$new_path" = x; then
36419      # It's still not found. Now this is an unrecoverable error.
36420      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36421$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36422      has_space=`$ECHO "$complete" | $GREP " "`
36423      if test "x$has_space" != x; then
36424        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36425$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36426      fi
36427      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36428    fi
36429  fi
36430
36431  # Now new_path has a complete unix path to the binary
36432  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36433    # Keep paths in /bin as-is, but remove trailing .exe if any
36434    new_path="${new_path/%.exe/}"
36435    # Do not save /bin paths to all_fixpath_prefixes!
36436  else
36437    # Not in mixed or Windows style, start by that.
36438    new_path=`cmd //c echo $new_path`
36439
36440  input_path="$new_path"
36441  # Check if we need to convert this using DOS-style short mode. If the path
36442  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36443  # take no chances and rewrite it.
36444  # Note: m4 eats our [], so we need to use [ and ] instead.
36445  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36446  if test "x$has_forbidden_chars" != x; then
36447    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36448    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36449  fi
36450
36451    # Output is in $new_path
36452
36453  windows_path="$new_path"
36454  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36455    unix_path=`$CYGPATH -u "$windows_path"`
36456    new_path="$unix_path"
36457  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36458    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36459    new_path="$unix_path"
36460  fi
36461
36462    # remove trailing .exe if any
36463    new_path="${new_path/%.exe/}"
36464
36465    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36466    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36467  fi
36468
36469  else
36470    # We're on a posix platform. Hooray! :)
36471    # First separate the path from the arguments. This will split at the first
36472    # space.
36473    complete="$MCS"
36474    path="${complete%% *}"
36475    tmp="$complete EOL"
36476    arguments="${tmp#* }"
36477
36478    # Cannot rely on the command "which" here since it doesn't always work.
36479    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36480    if test -z "$is_absolute_path"; then
36481      # Path to executable is not absolute. Find it.
36482      IFS_save="$IFS"
36483      IFS=:
36484      for p in $PATH; do
36485        if test -f "$p/$path" && test -x "$p/$path"; then
36486          new_path="$p/$path"
36487          break
36488        fi
36489      done
36490      IFS="$IFS_save"
36491    else
36492      # This is an absolute path, we can use it without further modifications.
36493      new_path="$path"
36494    fi
36495
36496    if test "x$new_path" = x; then
36497      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36498$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36499      has_space=`$ECHO "$complete" | $GREP " "`
36500      if test "x$has_space" != x; then
36501        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36502$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36503      fi
36504      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36505    fi
36506  fi
36507
36508  # Now join together the path and the arguments once again
36509  if test "x$arguments" != xEOL; then
36510    new_complete="$new_path ${arguments% *}"
36511  else
36512    new_complete="$new_path"
36513  fi
36514
36515  if test "x$complete" != "x$new_complete"; then
36516    MCS="$new_complete"
36517    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
36518$as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
36519  fi
36520
36521  elif test "x$OPENJDK_TARGET_OS" != xwindows; then
36522    # FIXME: we should unify this with the solaris case above.
36523
36524
36525  # Publish this variable in the help.
36526
36527
36528  if test "x$STRIP" = x; then
36529    # The variable is not set by user, try to locate tool using the code snippet
36530    if test -n "$ac_tool_prefix"; then
36531  for ac_prog in strip
36532  do
36533    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36534set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36535{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36536$as_echo_n "checking for $ac_word... " >&6; }
36537if ${ac_cv_prog_STRIP+:} false; then :
36538  $as_echo_n "(cached) " >&6
36539else
36540  if test -n "$STRIP"; then
36541  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36542else
36543as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36544for as_dir in $PATH
36545do
36546  IFS=$as_save_IFS
36547  test -z "$as_dir" && as_dir=.
36548    for ac_exec_ext in '' $ac_executable_extensions; do
36549  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36550    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36551    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36552    break 2
36553  fi
36554done
36555  done
36556IFS=$as_save_IFS
36557
36558fi
36559fi
36560STRIP=$ac_cv_prog_STRIP
36561if test -n "$STRIP"; then
36562  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36563$as_echo "$STRIP" >&6; }
36564else
36565  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36566$as_echo "no" >&6; }
36567fi
36568
36569
36570    test -n "$STRIP" && break
36571  done
36572fi
36573if test -z "$STRIP"; then
36574  ac_ct_STRIP=$STRIP
36575  for ac_prog in strip
36576do
36577  # Extract the first word of "$ac_prog", so it can be a program name with args.
36578set dummy $ac_prog; ac_word=$2
36579{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36580$as_echo_n "checking for $ac_word... " >&6; }
36581if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36582  $as_echo_n "(cached) " >&6
36583else
36584  if test -n "$ac_ct_STRIP"; then
36585  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36586else
36587as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36588for as_dir in $PATH
36589do
36590  IFS=$as_save_IFS
36591  test -z "$as_dir" && as_dir=.
36592    for ac_exec_ext in '' $ac_executable_extensions; do
36593  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36594    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36595    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36596    break 2
36597  fi
36598done
36599  done
36600IFS=$as_save_IFS
36601
36602fi
36603fi
36604ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36605if test -n "$ac_ct_STRIP"; then
36606  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36607$as_echo "$ac_ct_STRIP" >&6; }
36608else
36609  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36610$as_echo "no" >&6; }
36611fi
36612
36613
36614  test -n "$ac_ct_STRIP" && break
36615done
36616
36617  if test "x$ac_ct_STRIP" = x; then
36618    STRIP=""
36619  else
36620    case $cross_compiling:$ac_tool_warned in
36621yes:)
36622{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36623$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36624ac_tool_warned=yes ;;
36625esac
36626    STRIP=$ac_ct_STRIP
36627  fi
36628fi
36629
36630  else
36631    # The variable is set, but is it from the command line or the environment?
36632
36633    # Try to remove the string !STRIP! from our list.
36634    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
36635    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36636      # If it failed, the variable was not from the command line. Ignore it,
36637      # but warn the user (except for BASH, which is always set by the calling BASH).
36638      if test "xSTRIP" != xBASH; then
36639        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
36640$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
36641      fi
36642      # Try to locate tool using the code snippet
36643      if test -n "$ac_tool_prefix"; then
36644  for ac_prog in strip
36645  do
36646    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36647set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36648{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36649$as_echo_n "checking for $ac_word... " >&6; }
36650if ${ac_cv_prog_STRIP+:} false; then :
36651  $as_echo_n "(cached) " >&6
36652else
36653  if test -n "$STRIP"; then
36654  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36655else
36656as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36657for as_dir in $PATH
36658do
36659  IFS=$as_save_IFS
36660  test -z "$as_dir" && as_dir=.
36661    for ac_exec_ext in '' $ac_executable_extensions; do
36662  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36663    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36664    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36665    break 2
36666  fi
36667done
36668  done
36669IFS=$as_save_IFS
36670
36671fi
36672fi
36673STRIP=$ac_cv_prog_STRIP
36674if test -n "$STRIP"; then
36675  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36676$as_echo "$STRIP" >&6; }
36677else
36678  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36679$as_echo "no" >&6; }
36680fi
36681
36682
36683    test -n "$STRIP" && break
36684  done
36685fi
36686if test -z "$STRIP"; then
36687  ac_ct_STRIP=$STRIP
36688  for ac_prog in strip
36689do
36690  # Extract the first word of "$ac_prog", so it can be a program name with args.
36691set dummy $ac_prog; ac_word=$2
36692{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36693$as_echo_n "checking for $ac_word... " >&6; }
36694if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36695  $as_echo_n "(cached) " >&6
36696else
36697  if test -n "$ac_ct_STRIP"; then
36698  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36699else
36700as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36701for as_dir in $PATH
36702do
36703  IFS=$as_save_IFS
36704  test -z "$as_dir" && as_dir=.
36705    for ac_exec_ext in '' $ac_executable_extensions; do
36706  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36707    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36708    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36709    break 2
36710  fi
36711done
36712  done
36713IFS=$as_save_IFS
36714
36715fi
36716fi
36717ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36718if test -n "$ac_ct_STRIP"; then
36719  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36720$as_echo "$ac_ct_STRIP" >&6; }
36721else
36722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36723$as_echo "no" >&6; }
36724fi
36725
36726
36727  test -n "$ac_ct_STRIP" && break
36728done
36729
36730  if test "x$ac_ct_STRIP" = x; then
36731    STRIP=""
36732  else
36733    case $cross_compiling:$ac_tool_warned in
36734yes:)
36735{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36736$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36737ac_tool_warned=yes ;;
36738esac
36739    STRIP=$ac_ct_STRIP
36740  fi
36741fi
36742
36743    else
36744      # If it succeeded, then it was overridden by the user. We will use it
36745      # for the tool.
36746
36747      # First remove it from the list of overridden variables, so we can test
36748      # for unknown variables in the end.
36749      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36750
36751      # Check if the provided tool contains a complete path.
36752      tool_specified="$STRIP"
36753      tool_basename="${tool_specified##*/}"
36754      if test "x$tool_basename" = "x$tool_specified"; then
36755        # A command without a complete path is provided, search $PATH.
36756        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
36757$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
36758        # Extract the first word of "$tool_basename", so it can be a program name with args.
36759set dummy $tool_basename; ac_word=$2
36760{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36761$as_echo_n "checking for $ac_word... " >&6; }
36762if ${ac_cv_path_STRIP+:} false; then :
36763  $as_echo_n "(cached) " >&6
36764else
36765  case $STRIP in
36766  [\\/]* | ?:[\\/]*)
36767  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
36768  ;;
36769  *)
36770  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36771for as_dir in $PATH
36772do
36773  IFS=$as_save_IFS
36774  test -z "$as_dir" && as_dir=.
36775    for ac_exec_ext in '' $ac_executable_extensions; do
36776  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36777    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
36778    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36779    break 2
36780  fi
36781done
36782  done
36783IFS=$as_save_IFS
36784
36785  ;;
36786esac
36787fi
36788STRIP=$ac_cv_path_STRIP
36789if test -n "$STRIP"; then
36790  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36791$as_echo "$STRIP" >&6; }
36792else
36793  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36794$as_echo "no" >&6; }
36795fi
36796
36797
36798        if test "x$STRIP" = x; then
36799          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36800        fi
36801      else
36802        # Otherwise we believe it is a complete path. Use it as it is.
36803        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
36804$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
36805        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
36806$as_echo_n "checking for STRIP... " >&6; }
36807        if test ! -x "$tool_specified"; then
36808          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36809$as_echo "not found" >&6; }
36810          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
36811        fi
36812        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36813$as_echo "$tool_specified" >&6; }
36814      fi
36815    fi
36816  fi
36817
36818
36819
36820  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36821
36822  # First separate the path from the arguments. This will split at the first
36823  # space.
36824  complete="$STRIP"
36825  path="${complete%% *}"
36826  tmp="$complete EOL"
36827  arguments="${tmp#* }"
36828
36829  # Input might be given as Windows format, start by converting to
36830  # unix format.
36831  new_path=`$CYGPATH -u "$path"`
36832
36833  # Now try to locate executable using which
36834  new_path=`$WHICH "$new_path" 2> /dev/null`
36835  # bat and cmd files are not always considered executable in cygwin causing which
36836  # to not find them
36837  if test "x$new_path" = x \
36838      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36839      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36840    new_path=`$CYGPATH -u "$path"`
36841  fi
36842  if test "x$new_path" = x; then
36843    # Oops. Which didn't find the executable.
36844    # The splitting of arguments from the executable at a space might have been incorrect,
36845    # since paths with space are more likely in Windows. Give it another try with the whole
36846    # argument.
36847    path="$complete"
36848    arguments="EOL"
36849    new_path=`$CYGPATH -u "$path"`
36850    new_path=`$WHICH "$new_path" 2> /dev/null`
36851    # bat and cmd files are not always considered executable in cygwin causing which
36852    # to not find them
36853    if test "x$new_path" = x \
36854        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36855        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36856      new_path=`$CYGPATH -u "$path"`
36857    fi
36858    if test "x$new_path" = x; then
36859      # It's still not found. Now this is an unrecoverable error.
36860      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36861$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36862      has_space=`$ECHO "$complete" | $GREP " "`
36863      if test "x$has_space" != x; then
36864        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36865$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36866      fi
36867      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36868    fi
36869  fi
36870
36871  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36872  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36873  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36874  # "foo.exe" is OK but "foo" is an error.
36875  #
36876  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36877  # It is also a way to make sure we got the proper file name for the real test later on.
36878  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36879  if test "x$test_shortpath" = x; then
36880    # Short path failed, file does not exist as specified.
36881    # Try adding .exe or .cmd
36882    if test -f "${new_path}.exe"; then
36883      input_to_shortpath="${new_path}.exe"
36884    elif test -f "${new_path}.cmd"; then
36885      input_to_shortpath="${new_path}.cmd"
36886    else
36887      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
36888$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
36889      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36890$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36891      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36892    fi
36893  else
36894    input_to_shortpath="$new_path"
36895  fi
36896
36897  # Call helper function which possibly converts this using DOS-style short mode.
36898  # If so, the updated path is stored in $new_path.
36899  new_path="$input_to_shortpath"
36900
36901  input_path="$input_to_shortpath"
36902  # Check if we need to convert this using DOS-style short mode. If the path
36903  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36904  # take no chances and rewrite it.
36905  # Note: m4 eats our [], so we need to use [ and ] instead.
36906  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36907  if test "x$has_forbidden_chars" != x; then
36908    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36909    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36910    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36911    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36912      # Going to short mode and back again did indeed matter. Since short mode is
36913      # case insensitive, let's make it lowercase to improve readability.
36914      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36915      # Now convert it back to Unix-stile (cygpath)
36916      input_path=`$CYGPATH -u "$shortmode_path"`
36917      new_path="$input_path"
36918    fi
36919  fi
36920
36921  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36922  if test "x$test_cygdrive_prefix" = x; then
36923    # As a simple fix, exclude /usr/bin since it's not a real path.
36924    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36925      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36926      # a path prefixed by /cygdrive for fixpath to work.
36927      new_path="$CYGWIN_ROOT_PATH$input_path"
36928    fi
36929  fi
36930
36931  # remove trailing .exe if any
36932  new_path="${new_path/%.exe/}"
36933
36934  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36935
36936  # First separate the path from the arguments. This will split at the first
36937  # space.
36938  complete="$STRIP"
36939  path="${complete%% *}"
36940  tmp="$complete EOL"
36941  arguments="${tmp#* }"
36942
36943  # Input might be given as Windows format, start by converting to
36944  # unix format.
36945  new_path="$path"
36946
36947  windows_path="$new_path"
36948  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36949    unix_path=`$CYGPATH -u "$windows_path"`
36950    new_path="$unix_path"
36951  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36952    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36953    new_path="$unix_path"
36954  fi
36955
36956
36957  # Now try to locate executable using which
36958  new_path=`$WHICH "$new_path" 2> /dev/null`
36959
36960  if test "x$new_path" = x; then
36961    # Oops. Which didn't find the executable.
36962    # The splitting of arguments from the executable at a space might have been incorrect,
36963    # since paths with space are more likely in Windows. Give it another try with the whole
36964    # argument.
36965    path="$complete"
36966    arguments="EOL"
36967    new_path="$path"
36968
36969  windows_path="$new_path"
36970  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36971    unix_path=`$CYGPATH -u "$windows_path"`
36972    new_path="$unix_path"
36973  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36974    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36975    new_path="$unix_path"
36976  fi
36977
36978
36979    new_path=`$WHICH "$new_path" 2> /dev/null`
36980
36981    if test "x$new_path" = x; then
36982      # It's still not found. Now this is an unrecoverable error.
36983      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36984$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36985      has_space=`$ECHO "$complete" | $GREP " "`
36986      if test "x$has_space" != x; then
36987        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36988$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36989      fi
36990      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36991    fi
36992  fi
36993
36994  # Now new_path has a complete unix path to the binary
36995  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36996    # Keep paths in /bin as-is, but remove trailing .exe if any
36997    new_path="${new_path/%.exe/}"
36998    # Do not save /bin paths to all_fixpath_prefixes!
36999  else
37000    # Not in mixed or Windows style, start by that.
37001    new_path=`cmd //c echo $new_path`
37002
37003  input_path="$new_path"
37004  # Check if we need to convert this using DOS-style short mode. If the path
37005  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37006  # take no chances and rewrite it.
37007  # Note: m4 eats our [], so we need to use [ and ] instead.
37008  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37009  if test "x$has_forbidden_chars" != x; then
37010    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37011    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37012  fi
37013
37014    # Output is in $new_path
37015
37016  windows_path="$new_path"
37017  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37018    unix_path=`$CYGPATH -u "$windows_path"`
37019    new_path="$unix_path"
37020  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37021    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37022    new_path="$unix_path"
37023  fi
37024
37025    # remove trailing .exe if any
37026    new_path="${new_path/%.exe/}"
37027
37028    # Save the first 10 bytes of this path to the storage, so fixpath can work.
37029    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37030  fi
37031
37032  else
37033    # We're on a posix platform. Hooray! :)
37034    # First separate the path from the arguments. This will split at the first
37035    # space.
37036    complete="$STRIP"
37037    path="${complete%% *}"
37038    tmp="$complete EOL"
37039    arguments="${tmp#* }"
37040
37041    # Cannot rely on the command "which" here since it doesn't always work.
37042    is_absolute_path=`$ECHO "$path" | $GREP ^/`
37043    if test -z "$is_absolute_path"; then
37044      # Path to executable is not absolute. Find it.
37045      IFS_save="$IFS"
37046      IFS=:
37047      for p in $PATH; do
37048        if test -f "$p/$path" && test -x "$p/$path"; then
37049          new_path="$p/$path"
37050          break
37051        fi
37052      done
37053      IFS="$IFS_save"
37054    else
37055      # This is an absolute path, we can use it without further modifications.
37056      new_path="$path"
37057    fi
37058
37059    if test "x$new_path" = x; then
37060      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37061$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37062      has_space=`$ECHO "$complete" | $GREP " "`
37063      if test "x$has_space" != x; then
37064        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37065$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37066      fi
37067      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37068    fi
37069  fi
37070
37071  # Now join together the path and the arguments once again
37072  if test "x$arguments" != xEOL; then
37073    new_complete="$new_path ${arguments% *}"
37074  else
37075    new_complete="$new_path"
37076  fi
37077
37078  if test "x$complete" != "x$new_complete"; then
37079    STRIP="$new_complete"
37080    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
37081$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
37082  fi
37083
37084
37085
37086  # Publish this variable in the help.
37087
37088
37089  if test "x$NM" = x; then
37090    # The variable is not set by user, try to locate tool using the code snippet
37091    if test -n "$ac_tool_prefix"; then
37092  for ac_prog in nm
37093  do
37094    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37095set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37096{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37097$as_echo_n "checking for $ac_word... " >&6; }
37098if ${ac_cv_prog_NM+:} false; then :
37099  $as_echo_n "(cached) " >&6
37100else
37101  if test -n "$NM"; then
37102  ac_cv_prog_NM="$NM" # Let the user override the test.
37103else
37104as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37105for as_dir in $PATH
37106do
37107  IFS=$as_save_IFS
37108  test -z "$as_dir" && as_dir=.
37109    for ac_exec_ext in '' $ac_executable_extensions; do
37110  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37111    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37112    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37113    break 2
37114  fi
37115done
37116  done
37117IFS=$as_save_IFS
37118
37119fi
37120fi
37121NM=$ac_cv_prog_NM
37122if test -n "$NM"; then
37123  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37124$as_echo "$NM" >&6; }
37125else
37126  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37127$as_echo "no" >&6; }
37128fi
37129
37130
37131    test -n "$NM" && break
37132  done
37133fi
37134if test -z "$NM"; then
37135  ac_ct_NM=$NM
37136  for ac_prog in nm
37137do
37138  # Extract the first word of "$ac_prog", so it can be a program name with args.
37139set dummy $ac_prog; ac_word=$2
37140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37141$as_echo_n "checking for $ac_word... " >&6; }
37142if ${ac_cv_prog_ac_ct_NM+:} false; then :
37143  $as_echo_n "(cached) " >&6
37144else
37145  if test -n "$ac_ct_NM"; then
37146  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37147else
37148as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37149for as_dir in $PATH
37150do
37151  IFS=$as_save_IFS
37152  test -z "$as_dir" && as_dir=.
37153    for ac_exec_ext in '' $ac_executable_extensions; do
37154  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37155    ac_cv_prog_ac_ct_NM="$ac_prog"
37156    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37157    break 2
37158  fi
37159done
37160  done
37161IFS=$as_save_IFS
37162
37163fi
37164fi
37165ac_ct_NM=$ac_cv_prog_ac_ct_NM
37166if test -n "$ac_ct_NM"; then
37167  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37168$as_echo "$ac_ct_NM" >&6; }
37169else
37170  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37171$as_echo "no" >&6; }
37172fi
37173
37174
37175  test -n "$ac_ct_NM" && break
37176done
37177
37178  if test "x$ac_ct_NM" = x; then
37179    NM=""
37180  else
37181    case $cross_compiling:$ac_tool_warned in
37182yes:)
37183{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37184$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37185ac_tool_warned=yes ;;
37186esac
37187    NM=$ac_ct_NM
37188  fi
37189fi
37190
37191  else
37192    # The variable is set, but is it from the command line or the environment?
37193
37194    # Try to remove the string !NM! from our list.
37195    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
37196    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37197      # If it failed, the variable was not from the command line. Ignore it,
37198      # but warn the user (except for BASH, which is always set by the calling BASH).
37199      if test "xNM" != xBASH; then
37200        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
37201$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
37202      fi
37203      # Try to locate tool using the code snippet
37204      if test -n "$ac_tool_prefix"; then
37205  for ac_prog in nm
37206  do
37207    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37208set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37209{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37210$as_echo_n "checking for $ac_word... " >&6; }
37211if ${ac_cv_prog_NM+:} false; then :
37212  $as_echo_n "(cached) " >&6
37213else
37214  if test -n "$NM"; then
37215  ac_cv_prog_NM="$NM" # Let the user override the test.
37216else
37217as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37218for as_dir in $PATH
37219do
37220  IFS=$as_save_IFS
37221  test -z "$as_dir" && as_dir=.
37222    for ac_exec_ext in '' $ac_executable_extensions; do
37223  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37224    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37225    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37226    break 2
37227  fi
37228done
37229  done
37230IFS=$as_save_IFS
37231
37232fi
37233fi
37234NM=$ac_cv_prog_NM
37235if test -n "$NM"; then
37236  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37237$as_echo "$NM" >&6; }
37238else
37239  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37240$as_echo "no" >&6; }
37241fi
37242
37243
37244    test -n "$NM" && break
37245  done
37246fi
37247if test -z "$NM"; then
37248  ac_ct_NM=$NM
37249  for ac_prog in nm
37250do
37251  # Extract the first word of "$ac_prog", so it can be a program name with args.
37252set dummy $ac_prog; ac_word=$2
37253{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37254$as_echo_n "checking for $ac_word... " >&6; }
37255if ${ac_cv_prog_ac_ct_NM+:} false; then :
37256  $as_echo_n "(cached) " >&6
37257else
37258  if test -n "$ac_ct_NM"; then
37259  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37260else
37261as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37262for as_dir in $PATH
37263do
37264  IFS=$as_save_IFS
37265  test -z "$as_dir" && as_dir=.
37266    for ac_exec_ext in '' $ac_executable_extensions; do
37267  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37268    ac_cv_prog_ac_ct_NM="$ac_prog"
37269    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37270    break 2
37271  fi
37272done
37273  done
37274IFS=$as_save_IFS
37275
37276fi
37277fi
37278ac_ct_NM=$ac_cv_prog_ac_ct_NM
37279if test -n "$ac_ct_NM"; then
37280  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37281$as_echo "$ac_ct_NM" >&6; }
37282else
37283  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37284$as_echo "no" >&6; }
37285fi
37286
37287
37288  test -n "$ac_ct_NM" && break
37289done
37290
37291  if test "x$ac_ct_NM" = x; then
37292    NM=""
37293  else
37294    case $cross_compiling:$ac_tool_warned in
37295yes:)
37296{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37297$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37298ac_tool_warned=yes ;;
37299esac
37300    NM=$ac_ct_NM
37301  fi
37302fi
37303
37304    else
37305      # If it succeeded, then it was overridden by the user. We will use it
37306      # for the tool.
37307
37308      # First remove it from the list of overridden variables, so we can test
37309      # for unknown variables in the end.
37310      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37311
37312      # Check if the provided tool contains a complete path.
37313      tool_specified="$NM"
37314      tool_basename="${tool_specified##*/}"
37315      if test "x$tool_basename" = "x$tool_specified"; then
37316        # A command without a complete path is provided, search $PATH.
37317        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
37318$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
37319        # Extract the first word of "$tool_basename", so it can be a program name with args.
37320set dummy $tool_basename; ac_word=$2
37321{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37322$as_echo_n "checking for $ac_word... " >&6; }
37323if ${ac_cv_path_NM+:} false; then :
37324  $as_echo_n "(cached) " >&6
37325else
37326  case $NM in
37327  [\\/]* | ?:[\\/]*)
37328  ac_cv_path_NM="$NM" # Let the user override the test with a path.
37329  ;;
37330  *)
37331  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37332for as_dir in $PATH
37333do
37334  IFS=$as_save_IFS
37335  test -z "$as_dir" && as_dir=.
37336    for ac_exec_ext in '' $ac_executable_extensions; do
37337  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37338    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
37339    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37340    break 2
37341  fi
37342done
37343  done
37344IFS=$as_save_IFS
37345
37346  ;;
37347esac
37348fi
37349NM=$ac_cv_path_NM
37350if test -n "$NM"; then
37351  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37352$as_echo "$NM" >&6; }
37353else
37354  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37355$as_echo "no" >&6; }
37356fi
37357
37358
37359        if test "x$NM" = x; then
37360          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37361        fi
37362      else
37363        # Otherwise we believe it is a complete path. Use it as it is.
37364        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
37365$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
37366        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
37367$as_echo_n "checking for NM... " >&6; }
37368        if test ! -x "$tool_specified"; then
37369          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37370$as_echo "not found" >&6; }
37371          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
37372        fi
37373        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37374$as_echo "$tool_specified" >&6; }
37375      fi
37376    fi
37377  fi
37378
37379
37380
37381  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37382
37383  # First separate the path from the arguments. This will split at the first
37384  # space.
37385  complete="$NM"
37386  path="${complete%% *}"
37387  tmp="$complete EOL"
37388  arguments="${tmp#* }"
37389
37390  # Input might be given as Windows format, start by converting to
37391  # unix format.
37392  new_path=`$CYGPATH -u "$path"`
37393
37394  # Now try to locate executable using which
37395  new_path=`$WHICH "$new_path" 2> /dev/null`
37396  # bat and cmd files are not always considered executable in cygwin causing which
37397  # to not find them
37398  if test "x$new_path" = x \
37399      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37400      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37401    new_path=`$CYGPATH -u "$path"`
37402  fi
37403  if test "x$new_path" = x; then
37404    # Oops. Which didn't find the executable.
37405    # The splitting of arguments from the executable at a space might have been incorrect,
37406    # since paths with space are more likely in Windows. Give it another try with the whole
37407    # argument.
37408    path="$complete"
37409    arguments="EOL"
37410    new_path=`$CYGPATH -u "$path"`
37411    new_path=`$WHICH "$new_path" 2> /dev/null`
37412    # bat and cmd files are not always considered executable in cygwin causing which
37413    # to not find them
37414    if test "x$new_path" = x \
37415        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37416        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37417      new_path=`$CYGPATH -u "$path"`
37418    fi
37419    if test "x$new_path" = x; then
37420      # It's still not found. Now this is an unrecoverable error.
37421      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37422$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37423      has_space=`$ECHO "$complete" | $GREP " "`
37424      if test "x$has_space" != x; then
37425        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37426$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37427      fi
37428      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37429    fi
37430  fi
37431
37432  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37433  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37434  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37435  # "foo.exe" is OK but "foo" is an error.
37436  #
37437  # This test is therefore slightly more accurate than "test -f" to check for file presence.
37438  # It is also a way to make sure we got the proper file name for the real test later on.
37439  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37440  if test "x$test_shortpath" = x; then
37441    # Short path failed, file does not exist as specified.
37442    # Try adding .exe or .cmd
37443    if test -f "${new_path}.exe"; then
37444      input_to_shortpath="${new_path}.exe"
37445    elif test -f "${new_path}.cmd"; then
37446      input_to_shortpath="${new_path}.cmd"
37447    else
37448      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
37449$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
37450      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37451$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37452      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37453    fi
37454  else
37455    input_to_shortpath="$new_path"
37456  fi
37457
37458  # Call helper function which possibly converts this using DOS-style short mode.
37459  # If so, the updated path is stored in $new_path.
37460  new_path="$input_to_shortpath"
37461
37462  input_path="$input_to_shortpath"
37463  # Check if we need to convert this using DOS-style short mode. If the path
37464  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37465  # take no chances and rewrite it.
37466  # Note: m4 eats our [], so we need to use [ and ] instead.
37467  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37468  if test "x$has_forbidden_chars" != x; then
37469    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37470    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37471    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37472    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37473      # Going to short mode and back again did indeed matter. Since short mode is
37474      # case insensitive, let's make it lowercase to improve readability.
37475      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37476      # Now convert it back to Unix-stile (cygpath)
37477      input_path=`$CYGPATH -u "$shortmode_path"`
37478      new_path="$input_path"
37479    fi
37480  fi
37481
37482  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37483  if test "x$test_cygdrive_prefix" = x; then
37484    # As a simple fix, exclude /usr/bin since it's not a real path.
37485    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37486      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37487      # a path prefixed by /cygdrive for fixpath to work.
37488      new_path="$CYGWIN_ROOT_PATH$input_path"
37489    fi
37490  fi
37491
37492  # remove trailing .exe if any
37493  new_path="${new_path/%.exe/}"
37494
37495  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37496
37497  # First separate the path from the arguments. This will split at the first
37498  # space.
37499  complete="$NM"
37500  path="${complete%% *}"
37501  tmp="$complete EOL"
37502  arguments="${tmp#* }"
37503
37504  # Input might be given as Windows format, start by converting to
37505  # unix format.
37506  new_path="$path"
37507
37508  windows_path="$new_path"
37509  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37510    unix_path=`$CYGPATH -u "$windows_path"`
37511    new_path="$unix_path"
37512  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37513    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37514    new_path="$unix_path"
37515  fi
37516
37517
37518  # Now try to locate executable using which
37519  new_path=`$WHICH "$new_path" 2> /dev/null`
37520
37521  if test "x$new_path" = x; then
37522    # Oops. Which didn't find the executable.
37523    # The splitting of arguments from the executable at a space might have been incorrect,
37524    # since paths with space are more likely in Windows. Give it another try with the whole
37525    # argument.
37526    path="$complete"
37527    arguments="EOL"
37528    new_path="$path"
37529
37530  windows_path="$new_path"
37531  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37532    unix_path=`$CYGPATH -u "$windows_path"`
37533    new_path="$unix_path"
37534  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37535    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37536    new_path="$unix_path"
37537  fi
37538
37539
37540    new_path=`$WHICH "$new_path" 2> /dev/null`
37541
37542    if test "x$new_path" = x; then
37543      # It's still not found. Now this is an unrecoverable error.
37544      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37545$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37546      has_space=`$ECHO "$complete" | $GREP " "`
37547      if test "x$has_space" != x; then
37548        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37549$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37550      fi
37551      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37552    fi
37553  fi
37554
37555  # Now new_path has a complete unix path to the binary
37556  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37557    # Keep paths in /bin as-is, but remove trailing .exe if any
37558    new_path="${new_path/%.exe/}"
37559    # Do not save /bin paths to all_fixpath_prefixes!
37560  else
37561    # Not in mixed or Windows style, start by that.
37562    new_path=`cmd //c echo $new_path`
37563
37564  input_path="$new_path"
37565  # Check if we need to convert this using DOS-style short mode. If the path
37566  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37567  # take no chances and rewrite it.
37568  # Note: m4 eats our [], so we need to use [ and ] instead.
37569  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37570  if test "x$has_forbidden_chars" != x; then
37571    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37572    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37573  fi
37574
37575    # Output is in $new_path
37576
37577  windows_path="$new_path"
37578  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37579    unix_path=`$CYGPATH -u "$windows_path"`
37580    new_path="$unix_path"
37581  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37582    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37583    new_path="$unix_path"
37584  fi
37585
37586    # remove trailing .exe if any
37587    new_path="${new_path/%.exe/}"
37588
37589    # Save the first 10 bytes of this path to the storage, so fixpath can work.
37590    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37591  fi
37592
37593  else
37594    # We're on a posix platform. Hooray! :)
37595    # First separate the path from the arguments. This will split at the first
37596    # space.
37597    complete="$NM"
37598    path="${complete%% *}"
37599    tmp="$complete EOL"
37600    arguments="${tmp#* }"
37601
37602    # Cannot rely on the command "which" here since it doesn't always work.
37603    is_absolute_path=`$ECHO "$path" | $GREP ^/`
37604    if test -z "$is_absolute_path"; then
37605      # Path to executable is not absolute. Find it.
37606      IFS_save="$IFS"
37607      IFS=:
37608      for p in $PATH; do
37609        if test -f "$p/$path" && test -x "$p/$path"; then
37610          new_path="$p/$path"
37611          break
37612        fi
37613      done
37614      IFS="$IFS_save"
37615    else
37616      # This is an absolute path, we can use it without further modifications.
37617      new_path="$path"
37618    fi
37619
37620    if test "x$new_path" = x; then
37621      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37622$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37623      has_space=`$ECHO "$complete" | $GREP " "`
37624      if test "x$has_space" != x; then
37625        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37626$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37627      fi
37628      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37629    fi
37630  fi
37631
37632  # Now join together the path and the arguments once again
37633  if test "x$arguments" != xEOL; then
37634    new_complete="$new_path ${arguments% *}"
37635  else
37636    new_complete="$new_path"
37637  fi
37638
37639  if test "x$complete" != "x$new_complete"; then
37640    NM="$new_complete"
37641    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
37642$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
37643  fi
37644
37645    GNM="$NM"
37646
37647  fi
37648
37649  # objcopy is used for moving debug symbols to separate files when
37650  # full debug symbols are enabled.
37651  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
37652
37653
37654  # Publish this variable in the help.
37655
37656
37657  if test "x$OBJCOPY" = x; then
37658    # The variable is not set by user, try to locate tool using the code snippet
37659    if test -n "$ac_tool_prefix"; then
37660  for ac_prog in gobjcopy objcopy
37661  do
37662    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37663set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37664{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37665$as_echo_n "checking for $ac_word... " >&6; }
37666if ${ac_cv_prog_OBJCOPY+:} false; then :
37667  $as_echo_n "(cached) " >&6
37668else
37669  if test -n "$OBJCOPY"; then
37670  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37671else
37672as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37673for as_dir in $PATH
37674do
37675  IFS=$as_save_IFS
37676  test -z "$as_dir" && as_dir=.
37677    for ac_exec_ext in '' $ac_executable_extensions; do
37678  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37679    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37680    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37681    break 2
37682  fi
37683done
37684  done
37685IFS=$as_save_IFS
37686
37687fi
37688fi
37689OBJCOPY=$ac_cv_prog_OBJCOPY
37690if test -n "$OBJCOPY"; then
37691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37692$as_echo "$OBJCOPY" >&6; }
37693else
37694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37695$as_echo "no" >&6; }
37696fi
37697
37698
37699    test -n "$OBJCOPY" && break
37700  done
37701fi
37702if test -z "$OBJCOPY"; then
37703  ac_ct_OBJCOPY=$OBJCOPY
37704  for ac_prog in gobjcopy objcopy
37705do
37706  # Extract the first word of "$ac_prog", so it can be a program name with args.
37707set dummy $ac_prog; ac_word=$2
37708{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37709$as_echo_n "checking for $ac_word... " >&6; }
37710if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37711  $as_echo_n "(cached) " >&6
37712else
37713  if test -n "$ac_ct_OBJCOPY"; then
37714  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37715else
37716as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37717for as_dir in $PATH
37718do
37719  IFS=$as_save_IFS
37720  test -z "$as_dir" && as_dir=.
37721    for ac_exec_ext in '' $ac_executable_extensions; do
37722  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37723    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37724    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37725    break 2
37726  fi
37727done
37728  done
37729IFS=$as_save_IFS
37730
37731fi
37732fi
37733ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37734if test -n "$ac_ct_OBJCOPY"; then
37735  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37736$as_echo "$ac_ct_OBJCOPY" >&6; }
37737else
37738  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37739$as_echo "no" >&6; }
37740fi
37741
37742
37743  test -n "$ac_ct_OBJCOPY" && break
37744done
37745
37746  if test "x$ac_ct_OBJCOPY" = x; then
37747    OBJCOPY=""
37748  else
37749    case $cross_compiling:$ac_tool_warned in
37750yes:)
37751{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37752$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37753ac_tool_warned=yes ;;
37754esac
37755    OBJCOPY=$ac_ct_OBJCOPY
37756  fi
37757fi
37758
37759  else
37760    # The variable is set, but is it from the command line or the environment?
37761
37762    # Try to remove the string !OBJCOPY! from our list.
37763    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
37764    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37765      # If it failed, the variable was not from the command line. Ignore it,
37766      # but warn the user (except for BASH, which is always set by the calling BASH).
37767      if test "xOBJCOPY" != xBASH; then
37768        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
37769$as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
37770      fi
37771      # Try to locate tool using the code snippet
37772      if test -n "$ac_tool_prefix"; then
37773  for ac_prog in gobjcopy objcopy
37774  do
37775    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37776set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37777{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37778$as_echo_n "checking for $ac_word... " >&6; }
37779if ${ac_cv_prog_OBJCOPY+:} false; then :
37780  $as_echo_n "(cached) " >&6
37781else
37782  if test -n "$OBJCOPY"; then
37783  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37784else
37785as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37786for as_dir in $PATH
37787do
37788  IFS=$as_save_IFS
37789  test -z "$as_dir" && as_dir=.
37790    for ac_exec_ext in '' $ac_executable_extensions; do
37791  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37792    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37793    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37794    break 2
37795  fi
37796done
37797  done
37798IFS=$as_save_IFS
37799
37800fi
37801fi
37802OBJCOPY=$ac_cv_prog_OBJCOPY
37803if test -n "$OBJCOPY"; then
37804  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37805$as_echo "$OBJCOPY" >&6; }
37806else
37807  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37808$as_echo "no" >&6; }
37809fi
37810
37811
37812    test -n "$OBJCOPY" && break
37813  done
37814fi
37815if test -z "$OBJCOPY"; then
37816  ac_ct_OBJCOPY=$OBJCOPY
37817  for ac_prog in gobjcopy objcopy
37818do
37819  # Extract the first word of "$ac_prog", so it can be a program name with args.
37820set dummy $ac_prog; ac_word=$2
37821{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37822$as_echo_n "checking for $ac_word... " >&6; }
37823if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37824  $as_echo_n "(cached) " >&6
37825else
37826  if test -n "$ac_ct_OBJCOPY"; then
37827  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37828else
37829as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37830for as_dir in $PATH
37831do
37832  IFS=$as_save_IFS
37833  test -z "$as_dir" && as_dir=.
37834    for ac_exec_ext in '' $ac_executable_extensions; do
37835  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37836    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37837    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37838    break 2
37839  fi
37840done
37841  done
37842IFS=$as_save_IFS
37843
37844fi
37845fi
37846ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37847if test -n "$ac_ct_OBJCOPY"; then
37848  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37849$as_echo "$ac_ct_OBJCOPY" >&6; }
37850else
37851  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37852$as_echo "no" >&6; }
37853fi
37854
37855
37856  test -n "$ac_ct_OBJCOPY" && break
37857done
37858
37859  if test "x$ac_ct_OBJCOPY" = x; then
37860    OBJCOPY=""
37861  else
37862    case $cross_compiling:$ac_tool_warned in
37863yes:)
37864{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37865$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37866ac_tool_warned=yes ;;
37867esac
37868    OBJCOPY=$ac_ct_OBJCOPY
37869  fi
37870fi
37871
37872    else
37873      # If it succeeded, then it was overridden by the user. We will use it
37874      # for the tool.
37875
37876      # First remove it from the list of overridden variables, so we can test
37877      # for unknown variables in the end.
37878      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37879
37880      # Check if the provided tool contains a complete path.
37881      tool_specified="$OBJCOPY"
37882      tool_basename="${tool_specified##*/}"
37883      if test "x$tool_basename" = "x$tool_specified"; then
37884        # A command without a complete path is provided, search $PATH.
37885        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
37886$as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
37887        # Extract the first word of "$tool_basename", so it can be a program name with args.
37888set dummy $tool_basename; ac_word=$2
37889{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37890$as_echo_n "checking for $ac_word... " >&6; }
37891if ${ac_cv_path_OBJCOPY+:} false; then :
37892  $as_echo_n "(cached) " >&6
37893else
37894  case $OBJCOPY in
37895  [\\/]* | ?:[\\/]*)
37896  ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
37897  ;;
37898  *)
37899  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37900for as_dir in $PATH
37901do
37902  IFS=$as_save_IFS
37903  test -z "$as_dir" && as_dir=.
37904    for ac_exec_ext in '' $ac_executable_extensions; do
37905  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37906    ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
37907    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37908    break 2
37909  fi
37910done
37911  done
37912IFS=$as_save_IFS
37913
37914  ;;
37915esac
37916fi
37917OBJCOPY=$ac_cv_path_OBJCOPY
37918if test -n "$OBJCOPY"; then
37919  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37920$as_echo "$OBJCOPY" >&6; }
37921else
37922  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37923$as_echo "no" >&6; }
37924fi
37925
37926
37927        if test "x$OBJCOPY" = x; then
37928          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37929        fi
37930      else
37931        # Otherwise we believe it is a complete path. Use it as it is.
37932        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
37933$as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
37934        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
37935$as_echo_n "checking for OBJCOPY... " >&6; }
37936        if test ! -x "$tool_specified"; then
37937          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37938$as_echo "not found" >&6; }
37939          as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
37940        fi
37941        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37942$as_echo "$tool_specified" >&6; }
37943      fi
37944    fi
37945  fi
37946
37947
37948    # Only call fixup if objcopy was found.
37949    if test -n "$OBJCOPY"; then
37950
37951  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37952
37953  # First separate the path from the arguments. This will split at the first
37954  # space.
37955  complete="$OBJCOPY"
37956  path="${complete%% *}"
37957  tmp="$complete EOL"
37958  arguments="${tmp#* }"
37959
37960  # Input might be given as Windows format, start by converting to
37961  # unix format.
37962  new_path=`$CYGPATH -u "$path"`
37963
37964  # Now try to locate executable using which
37965  new_path=`$WHICH "$new_path" 2> /dev/null`
37966  # bat and cmd files are not always considered executable in cygwin causing which
37967  # to not find them
37968  if test "x$new_path" = x \
37969      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37970      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37971    new_path=`$CYGPATH -u "$path"`
37972  fi
37973  if test "x$new_path" = x; then
37974    # Oops. Which didn't find the executable.
37975    # The splitting of arguments from the executable at a space might have been incorrect,
37976    # since paths with space are more likely in Windows. Give it another try with the whole
37977    # argument.
37978    path="$complete"
37979    arguments="EOL"
37980    new_path=`$CYGPATH -u "$path"`
37981    new_path=`$WHICH "$new_path" 2> /dev/null`
37982    # bat and cmd files are not always considered executable in cygwin causing which
37983    # to not find them
37984    if test "x$new_path" = x \
37985        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37986        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37987      new_path=`$CYGPATH -u "$path"`
37988    fi
37989    if test "x$new_path" = x; then
37990      # It's still not found. Now this is an unrecoverable error.
37991      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37992$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37993      has_space=`$ECHO "$complete" | $GREP " "`
37994      if test "x$has_space" != x; then
37995        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37996$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37997      fi
37998      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37999    fi
38000  fi
38001
38002  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38003  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38004  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38005  # "foo.exe" is OK but "foo" is an error.
38006  #
38007  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38008  # It is also a way to make sure we got the proper file name for the real test later on.
38009  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38010  if test "x$test_shortpath" = x; then
38011    # Short path failed, file does not exist as specified.
38012    # Try adding .exe or .cmd
38013    if test -f "${new_path}.exe"; then
38014      input_to_shortpath="${new_path}.exe"
38015    elif test -f "${new_path}.cmd"; then
38016      input_to_shortpath="${new_path}.cmd"
38017    else
38018      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
38019$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
38020      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38021$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38022      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38023    fi
38024  else
38025    input_to_shortpath="$new_path"
38026  fi
38027
38028  # Call helper function which possibly converts this using DOS-style short mode.
38029  # If so, the updated path is stored in $new_path.
38030  new_path="$input_to_shortpath"
38031
38032  input_path="$input_to_shortpath"
38033  # Check if we need to convert this using DOS-style short mode. If the path
38034  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38035  # take no chances and rewrite it.
38036  # Note: m4 eats our [], so we need to use [ and ] instead.
38037  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38038  if test "x$has_forbidden_chars" != x; then
38039    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38040    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38041    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38042    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38043      # Going to short mode and back again did indeed matter. Since short mode is
38044      # case insensitive, let's make it lowercase to improve readability.
38045      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38046      # Now convert it back to Unix-stile (cygpath)
38047      input_path=`$CYGPATH -u "$shortmode_path"`
38048      new_path="$input_path"
38049    fi
38050  fi
38051
38052  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38053  if test "x$test_cygdrive_prefix" = x; then
38054    # As a simple fix, exclude /usr/bin since it's not a real path.
38055    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38056      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38057      # a path prefixed by /cygdrive for fixpath to work.
38058      new_path="$CYGWIN_ROOT_PATH$input_path"
38059    fi
38060  fi
38061
38062  # remove trailing .exe if any
38063  new_path="${new_path/%.exe/}"
38064
38065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38066
38067  # First separate the path from the arguments. This will split at the first
38068  # space.
38069  complete="$OBJCOPY"
38070  path="${complete%% *}"
38071  tmp="$complete EOL"
38072  arguments="${tmp#* }"
38073
38074  # Input might be given as Windows format, start by converting to
38075  # unix format.
38076  new_path="$path"
38077
38078  windows_path="$new_path"
38079  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38080    unix_path=`$CYGPATH -u "$windows_path"`
38081    new_path="$unix_path"
38082  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38083    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38084    new_path="$unix_path"
38085  fi
38086
38087
38088  # Now try to locate executable using which
38089  new_path=`$WHICH "$new_path" 2> /dev/null`
38090
38091  if test "x$new_path" = x; then
38092    # Oops. Which didn't find the executable.
38093    # The splitting of arguments from the executable at a space might have been incorrect,
38094    # since paths with space are more likely in Windows. Give it another try with the whole
38095    # argument.
38096    path="$complete"
38097    arguments="EOL"
38098    new_path="$path"
38099
38100  windows_path="$new_path"
38101  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38102    unix_path=`$CYGPATH -u "$windows_path"`
38103    new_path="$unix_path"
38104  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38105    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38106    new_path="$unix_path"
38107  fi
38108
38109
38110    new_path=`$WHICH "$new_path" 2> /dev/null`
38111
38112    if test "x$new_path" = x; then
38113      # It's still not found. Now this is an unrecoverable error.
38114      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38115$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38116      has_space=`$ECHO "$complete" | $GREP " "`
38117      if test "x$has_space" != x; then
38118        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38119$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38120      fi
38121      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38122    fi
38123  fi
38124
38125  # Now new_path has a complete unix path to the binary
38126  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38127    # Keep paths in /bin as-is, but remove trailing .exe if any
38128    new_path="${new_path/%.exe/}"
38129    # Do not save /bin paths to all_fixpath_prefixes!
38130  else
38131    # Not in mixed or Windows style, start by that.
38132    new_path=`cmd //c echo $new_path`
38133
38134  input_path="$new_path"
38135  # Check if we need to convert this using DOS-style short mode. If the path
38136  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38137  # take no chances and rewrite it.
38138  # Note: m4 eats our [], so we need to use [ and ] instead.
38139  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38140  if test "x$has_forbidden_chars" != x; then
38141    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38142    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38143  fi
38144
38145    # Output is in $new_path
38146
38147  windows_path="$new_path"
38148  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38149    unix_path=`$CYGPATH -u "$windows_path"`
38150    new_path="$unix_path"
38151  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38152    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38153    new_path="$unix_path"
38154  fi
38155
38156    # remove trailing .exe if any
38157    new_path="${new_path/%.exe/}"
38158
38159    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38160    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38161  fi
38162
38163  else
38164    # We're on a posix platform. Hooray! :)
38165    # First separate the path from the arguments. This will split at the first
38166    # space.
38167    complete="$OBJCOPY"
38168    path="${complete%% *}"
38169    tmp="$complete EOL"
38170    arguments="${tmp#* }"
38171
38172    # Cannot rely on the command "which" here since it doesn't always work.
38173    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38174    if test -z "$is_absolute_path"; then
38175      # Path to executable is not absolute. Find it.
38176      IFS_save="$IFS"
38177      IFS=:
38178      for p in $PATH; do
38179        if test -f "$p/$path" && test -x "$p/$path"; then
38180          new_path="$p/$path"
38181          break
38182        fi
38183      done
38184      IFS="$IFS_save"
38185    else
38186      # This is an absolute path, we can use it without further modifications.
38187      new_path="$path"
38188    fi
38189
38190    if test "x$new_path" = x; then
38191      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38192$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38193      has_space=`$ECHO "$complete" | $GREP " "`
38194      if test "x$has_space" != x; then
38195        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38196$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38197      fi
38198      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38199    fi
38200  fi
38201
38202  # Now join together the path and the arguments once again
38203  if test "x$arguments" != xEOL; then
38204    new_complete="$new_path ${arguments% *}"
38205  else
38206    new_complete="$new_path"
38207  fi
38208
38209  if test "x$complete" != "x$new_complete"; then
38210    OBJCOPY="$new_complete"
38211    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
38212$as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
38213  fi
38214
38215    fi
38216  fi
38217
38218
38219
38220  # Publish this variable in the help.
38221
38222
38223  if test "x$OBJDUMP" = x; then
38224    # The variable is not set by user, try to locate tool using the code snippet
38225    if test -n "$ac_tool_prefix"; then
38226  for ac_prog in gobjdump objdump
38227  do
38228    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38229set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38230{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38231$as_echo_n "checking for $ac_word... " >&6; }
38232if ${ac_cv_prog_OBJDUMP+:} false; then :
38233  $as_echo_n "(cached) " >&6
38234else
38235  if test -n "$OBJDUMP"; then
38236  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38237else
38238as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38239for as_dir in $PATH
38240do
38241  IFS=$as_save_IFS
38242  test -z "$as_dir" && as_dir=.
38243    for ac_exec_ext in '' $ac_executable_extensions; do
38244  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38245    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38246    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38247    break 2
38248  fi
38249done
38250  done
38251IFS=$as_save_IFS
38252
38253fi
38254fi
38255OBJDUMP=$ac_cv_prog_OBJDUMP
38256if test -n "$OBJDUMP"; then
38257  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38258$as_echo "$OBJDUMP" >&6; }
38259else
38260  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38261$as_echo "no" >&6; }
38262fi
38263
38264
38265    test -n "$OBJDUMP" && break
38266  done
38267fi
38268if test -z "$OBJDUMP"; then
38269  ac_ct_OBJDUMP=$OBJDUMP
38270  for ac_prog in gobjdump objdump
38271do
38272  # Extract the first word of "$ac_prog", so it can be a program name with args.
38273set dummy $ac_prog; ac_word=$2
38274{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38275$as_echo_n "checking for $ac_word... " >&6; }
38276if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38277  $as_echo_n "(cached) " >&6
38278else
38279  if test -n "$ac_ct_OBJDUMP"; then
38280  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38281else
38282as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38283for as_dir in $PATH
38284do
38285  IFS=$as_save_IFS
38286  test -z "$as_dir" && as_dir=.
38287    for ac_exec_ext in '' $ac_executable_extensions; do
38288  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38289    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38290    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38291    break 2
38292  fi
38293done
38294  done
38295IFS=$as_save_IFS
38296
38297fi
38298fi
38299ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38300if test -n "$ac_ct_OBJDUMP"; then
38301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38302$as_echo "$ac_ct_OBJDUMP" >&6; }
38303else
38304  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38305$as_echo "no" >&6; }
38306fi
38307
38308
38309  test -n "$ac_ct_OBJDUMP" && break
38310done
38311
38312  if test "x$ac_ct_OBJDUMP" = x; then
38313    OBJDUMP=""
38314  else
38315    case $cross_compiling:$ac_tool_warned in
38316yes:)
38317{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38318$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38319ac_tool_warned=yes ;;
38320esac
38321    OBJDUMP=$ac_ct_OBJDUMP
38322  fi
38323fi
38324
38325  else
38326    # The variable is set, but is it from the command line or the environment?
38327
38328    # Try to remove the string !OBJDUMP! from our list.
38329    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
38330    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38331      # If it failed, the variable was not from the command line. Ignore it,
38332      # but warn the user (except for BASH, which is always set by the calling BASH).
38333      if test "xOBJDUMP" != xBASH; then
38334        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
38335$as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
38336      fi
38337      # Try to locate tool using the code snippet
38338      if test -n "$ac_tool_prefix"; then
38339  for ac_prog in gobjdump objdump
38340  do
38341    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38342set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38343{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38344$as_echo_n "checking for $ac_word... " >&6; }
38345if ${ac_cv_prog_OBJDUMP+:} false; then :
38346  $as_echo_n "(cached) " >&6
38347else
38348  if test -n "$OBJDUMP"; then
38349  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38350else
38351as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38352for as_dir in $PATH
38353do
38354  IFS=$as_save_IFS
38355  test -z "$as_dir" && as_dir=.
38356    for ac_exec_ext in '' $ac_executable_extensions; do
38357  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38358    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38359    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38360    break 2
38361  fi
38362done
38363  done
38364IFS=$as_save_IFS
38365
38366fi
38367fi
38368OBJDUMP=$ac_cv_prog_OBJDUMP
38369if test -n "$OBJDUMP"; then
38370  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38371$as_echo "$OBJDUMP" >&6; }
38372else
38373  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38374$as_echo "no" >&6; }
38375fi
38376
38377
38378    test -n "$OBJDUMP" && break
38379  done
38380fi
38381if test -z "$OBJDUMP"; then
38382  ac_ct_OBJDUMP=$OBJDUMP
38383  for ac_prog in gobjdump objdump
38384do
38385  # Extract the first word of "$ac_prog", so it can be a program name with args.
38386set dummy $ac_prog; ac_word=$2
38387{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38388$as_echo_n "checking for $ac_word... " >&6; }
38389if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38390  $as_echo_n "(cached) " >&6
38391else
38392  if test -n "$ac_ct_OBJDUMP"; then
38393  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38394else
38395as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38396for as_dir in $PATH
38397do
38398  IFS=$as_save_IFS
38399  test -z "$as_dir" && as_dir=.
38400    for ac_exec_ext in '' $ac_executable_extensions; do
38401  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38402    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38403    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38404    break 2
38405  fi
38406done
38407  done
38408IFS=$as_save_IFS
38409
38410fi
38411fi
38412ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38413if test -n "$ac_ct_OBJDUMP"; then
38414  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38415$as_echo "$ac_ct_OBJDUMP" >&6; }
38416else
38417  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38418$as_echo "no" >&6; }
38419fi
38420
38421
38422  test -n "$ac_ct_OBJDUMP" && break
38423done
38424
38425  if test "x$ac_ct_OBJDUMP" = x; then
38426    OBJDUMP=""
38427  else
38428    case $cross_compiling:$ac_tool_warned in
38429yes:)
38430{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38431$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38432ac_tool_warned=yes ;;
38433esac
38434    OBJDUMP=$ac_ct_OBJDUMP
38435  fi
38436fi
38437
38438    else
38439      # If it succeeded, then it was overridden by the user. We will use it
38440      # for the tool.
38441
38442      # First remove it from the list of overridden variables, so we can test
38443      # for unknown variables in the end.
38444      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38445
38446      # Check if the provided tool contains a complete path.
38447      tool_specified="$OBJDUMP"
38448      tool_basename="${tool_specified##*/}"
38449      if test "x$tool_basename" = "x$tool_specified"; then
38450        # A command without a complete path is provided, search $PATH.
38451        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
38452$as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
38453        # Extract the first word of "$tool_basename", so it can be a program name with args.
38454set dummy $tool_basename; ac_word=$2
38455{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38456$as_echo_n "checking for $ac_word... " >&6; }
38457if ${ac_cv_path_OBJDUMP+:} false; then :
38458  $as_echo_n "(cached) " >&6
38459else
38460  case $OBJDUMP in
38461  [\\/]* | ?:[\\/]*)
38462  ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
38463  ;;
38464  *)
38465  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38466for as_dir in $PATH
38467do
38468  IFS=$as_save_IFS
38469  test -z "$as_dir" && as_dir=.
38470    for ac_exec_ext in '' $ac_executable_extensions; do
38471  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38472    ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
38473    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38474    break 2
38475  fi
38476done
38477  done
38478IFS=$as_save_IFS
38479
38480  ;;
38481esac
38482fi
38483OBJDUMP=$ac_cv_path_OBJDUMP
38484if test -n "$OBJDUMP"; then
38485  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38486$as_echo "$OBJDUMP" >&6; }
38487else
38488  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38489$as_echo "no" >&6; }
38490fi
38491
38492
38493        if test "x$OBJDUMP" = x; then
38494          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38495        fi
38496      else
38497        # Otherwise we believe it is a complete path. Use it as it is.
38498        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
38499$as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
38500        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
38501$as_echo_n "checking for OBJDUMP... " >&6; }
38502        if test ! -x "$tool_specified"; then
38503          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38504$as_echo "not found" >&6; }
38505          as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
38506        fi
38507        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38508$as_echo "$tool_specified" >&6; }
38509      fi
38510    fi
38511  fi
38512
38513
38514  if test "x$OBJDUMP" != x; then
38515    # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE
38516    # bails if argument is missing.
38517
38518  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38519
38520  # First separate the path from the arguments. This will split at the first
38521  # space.
38522  complete="$OBJDUMP"
38523  path="${complete%% *}"
38524  tmp="$complete EOL"
38525  arguments="${tmp#* }"
38526
38527  # Input might be given as Windows format, start by converting to
38528  # unix format.
38529  new_path=`$CYGPATH -u "$path"`
38530
38531  # Now try to locate executable using which
38532  new_path=`$WHICH "$new_path" 2> /dev/null`
38533  # bat and cmd files are not always considered executable in cygwin causing which
38534  # to not find them
38535  if test "x$new_path" = x \
38536      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38537      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38538    new_path=`$CYGPATH -u "$path"`
38539  fi
38540  if test "x$new_path" = x; then
38541    # Oops. Which didn't find the executable.
38542    # The splitting of arguments from the executable at a space might have been incorrect,
38543    # since paths with space are more likely in Windows. Give it another try with the whole
38544    # argument.
38545    path="$complete"
38546    arguments="EOL"
38547    new_path=`$CYGPATH -u "$path"`
38548    new_path=`$WHICH "$new_path" 2> /dev/null`
38549    # bat and cmd files are not always considered executable in cygwin causing which
38550    # to not find them
38551    if test "x$new_path" = x \
38552        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38553        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38554      new_path=`$CYGPATH -u "$path"`
38555    fi
38556    if test "x$new_path" = x; then
38557      # It's still not found. Now this is an unrecoverable error.
38558      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38559$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38560      has_space=`$ECHO "$complete" | $GREP " "`
38561      if test "x$has_space" != x; then
38562        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38563$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38564      fi
38565      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38566    fi
38567  fi
38568
38569  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38570  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38571  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38572  # "foo.exe" is OK but "foo" is an error.
38573  #
38574  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38575  # It is also a way to make sure we got the proper file name for the real test later on.
38576  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38577  if test "x$test_shortpath" = x; then
38578    # Short path failed, file does not exist as specified.
38579    # Try adding .exe or .cmd
38580    if test -f "${new_path}.exe"; then
38581      input_to_shortpath="${new_path}.exe"
38582    elif test -f "${new_path}.cmd"; then
38583      input_to_shortpath="${new_path}.cmd"
38584    else
38585      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
38586$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
38587      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38588$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38589      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38590    fi
38591  else
38592    input_to_shortpath="$new_path"
38593  fi
38594
38595  # Call helper function which possibly converts this using DOS-style short mode.
38596  # If so, the updated path is stored in $new_path.
38597  new_path="$input_to_shortpath"
38598
38599  input_path="$input_to_shortpath"
38600  # Check if we need to convert this using DOS-style short mode. If the path
38601  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38602  # take no chances and rewrite it.
38603  # Note: m4 eats our [], so we need to use [ and ] instead.
38604  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38605  if test "x$has_forbidden_chars" != x; then
38606    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38607    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38608    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38609    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38610      # Going to short mode and back again did indeed matter. Since short mode is
38611      # case insensitive, let's make it lowercase to improve readability.
38612      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38613      # Now convert it back to Unix-stile (cygpath)
38614      input_path=`$CYGPATH -u "$shortmode_path"`
38615      new_path="$input_path"
38616    fi
38617  fi
38618
38619  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38620  if test "x$test_cygdrive_prefix" = x; then
38621    # As a simple fix, exclude /usr/bin since it's not a real path.
38622    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38623      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38624      # a path prefixed by /cygdrive for fixpath to work.
38625      new_path="$CYGWIN_ROOT_PATH$input_path"
38626    fi
38627  fi
38628
38629  # remove trailing .exe if any
38630  new_path="${new_path/%.exe/}"
38631
38632  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38633
38634  # First separate the path from the arguments. This will split at the first
38635  # space.
38636  complete="$OBJDUMP"
38637  path="${complete%% *}"
38638  tmp="$complete EOL"
38639  arguments="${tmp#* }"
38640
38641  # Input might be given as Windows format, start by converting to
38642  # unix format.
38643  new_path="$path"
38644
38645  windows_path="$new_path"
38646  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38647    unix_path=`$CYGPATH -u "$windows_path"`
38648    new_path="$unix_path"
38649  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38650    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38651    new_path="$unix_path"
38652  fi
38653
38654
38655  # Now try to locate executable using which
38656  new_path=`$WHICH "$new_path" 2> /dev/null`
38657
38658  if test "x$new_path" = x; then
38659    # Oops. Which didn't find the executable.
38660    # The splitting of arguments from the executable at a space might have been incorrect,
38661    # since paths with space are more likely in Windows. Give it another try with the whole
38662    # argument.
38663    path="$complete"
38664    arguments="EOL"
38665    new_path="$path"
38666
38667  windows_path="$new_path"
38668  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38669    unix_path=`$CYGPATH -u "$windows_path"`
38670    new_path="$unix_path"
38671  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38672    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38673    new_path="$unix_path"
38674  fi
38675
38676
38677    new_path=`$WHICH "$new_path" 2> /dev/null`
38678
38679    if test "x$new_path" = x; then
38680      # It's still not found. Now this is an unrecoverable error.
38681      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38682$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38683      has_space=`$ECHO "$complete" | $GREP " "`
38684      if test "x$has_space" != x; then
38685        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38686$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38687      fi
38688      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38689    fi
38690  fi
38691
38692  # Now new_path has a complete unix path to the binary
38693  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38694    # Keep paths in /bin as-is, but remove trailing .exe if any
38695    new_path="${new_path/%.exe/}"
38696    # Do not save /bin paths to all_fixpath_prefixes!
38697  else
38698    # Not in mixed or Windows style, start by that.
38699    new_path=`cmd //c echo $new_path`
38700
38701  input_path="$new_path"
38702  # Check if we need to convert this using DOS-style short mode. If the path
38703  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38704  # take no chances and rewrite it.
38705  # Note: m4 eats our [], so we need to use [ and ] instead.
38706  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38707  if test "x$has_forbidden_chars" != x; then
38708    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38709    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38710  fi
38711
38712    # Output is in $new_path
38713
38714  windows_path="$new_path"
38715  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38716    unix_path=`$CYGPATH -u "$windows_path"`
38717    new_path="$unix_path"
38718  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38719    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38720    new_path="$unix_path"
38721  fi
38722
38723    # remove trailing .exe if any
38724    new_path="${new_path/%.exe/}"
38725
38726    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38727    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38728  fi
38729
38730  else
38731    # We're on a posix platform. Hooray! :)
38732    # First separate the path from the arguments. This will split at the first
38733    # space.
38734    complete="$OBJDUMP"
38735    path="${complete%% *}"
38736    tmp="$complete EOL"
38737    arguments="${tmp#* }"
38738
38739    # Cannot rely on the command "which" here since it doesn't always work.
38740    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38741    if test -z "$is_absolute_path"; then
38742      # Path to executable is not absolute. Find it.
38743      IFS_save="$IFS"
38744      IFS=:
38745      for p in $PATH; do
38746        if test -f "$p/$path" && test -x "$p/$path"; then
38747          new_path="$p/$path"
38748          break
38749        fi
38750      done
38751      IFS="$IFS_save"
38752    else
38753      # This is an absolute path, we can use it without further modifications.
38754      new_path="$path"
38755    fi
38756
38757    if test "x$new_path" = x; then
38758      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38759$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38760      has_space=`$ECHO "$complete" | $GREP " "`
38761      if test "x$has_space" != x; then
38762        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38763$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38764      fi
38765      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38766    fi
38767  fi
38768
38769  # Now join together the path and the arguments once again
38770  if test "x$arguments" != xEOL; then
38771    new_complete="$new_path ${arguments% *}"
38772  else
38773    new_complete="$new_path"
38774  fi
38775
38776  if test "x$complete" != "x$new_complete"; then
38777    OBJDUMP="$new_complete"
38778    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
38779$as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
38780  fi
38781
38782  fi
38783
38784
38785  # Restore old path.
38786  PATH="$OLD_PATH"
38787
38788  # Restore the flags to the user specified values.
38789  # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
38790  CFLAGS="$ORG_CFLAGS"
38791  CXXFLAGS="$ORG_CXXFLAGS"
38792  OBJCFLAGS="$ORG_OBJCFLAGS"
38793
38794
38795# Finally do some processing after the detection phase
38796
38797  if test "x$COMPILE_TYPE" = "xcross"; then
38798    # Now we need to find a C/C++ compiler that can build executables for the
38799    # build platform. We can't use the AC_PROG_CC macro, since it can only be
38800    # used once. Also, we need to do this without adding a tools dir to the
38801    # path, otherwise we might pick up cross-compilers which don't use standard
38802    # naming.
38803
38804    # FIXME: we should list the discovered compilers as an exclude pattern!
38805    # If we do that, we can do this detection before POST_DETECTION, and still
38806    # find the build compilers in the tools dir, if needed.
38807
38808
38809  # Publish this variable in the help.
38810
38811
38812  if test "x$BUILD_CC" = x; then
38813    # The variable is not set by user, try to locate tool using the code snippet
38814    for ac_prog in cl cc gcc
38815do
38816  # Extract the first word of "$ac_prog", so it can be a program name with args.
38817set dummy $ac_prog; ac_word=$2
38818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38819$as_echo_n "checking for $ac_word... " >&6; }
38820if ${ac_cv_path_BUILD_CC+:} false; then :
38821  $as_echo_n "(cached) " >&6
38822else
38823  case $BUILD_CC in
38824  [\\/]* | ?:[\\/]*)
38825  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38826  ;;
38827  *)
38828  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38829for as_dir in $PATH
38830do
38831  IFS=$as_save_IFS
38832  test -z "$as_dir" && as_dir=.
38833    for ac_exec_ext in '' $ac_executable_extensions; do
38834  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38835    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38836    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38837    break 2
38838  fi
38839done
38840  done
38841IFS=$as_save_IFS
38842
38843  ;;
38844esac
38845fi
38846BUILD_CC=$ac_cv_path_BUILD_CC
38847if test -n "$BUILD_CC"; then
38848  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38849$as_echo "$BUILD_CC" >&6; }
38850else
38851  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38852$as_echo "no" >&6; }
38853fi
38854
38855
38856  test -n "$BUILD_CC" && break
38857done
38858
38859  else
38860    # The variable is set, but is it from the command line or the environment?
38861
38862    # Try to remove the string !BUILD_CC! from our list.
38863    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
38864    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38865      # If it failed, the variable was not from the command line. Ignore it,
38866      # but warn the user (except for BASH, which is always set by the calling BASH).
38867      if test "xBUILD_CC" != xBASH; then
38868        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
38869$as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
38870      fi
38871      # Try to locate tool using the code snippet
38872      for ac_prog in cl cc gcc
38873do
38874  # Extract the first word of "$ac_prog", so it can be a program name with args.
38875set dummy $ac_prog; ac_word=$2
38876{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38877$as_echo_n "checking for $ac_word... " >&6; }
38878if ${ac_cv_path_BUILD_CC+:} false; then :
38879  $as_echo_n "(cached) " >&6
38880else
38881  case $BUILD_CC in
38882  [\\/]* | ?:[\\/]*)
38883  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38884  ;;
38885  *)
38886  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38887for as_dir in $PATH
38888do
38889  IFS=$as_save_IFS
38890  test -z "$as_dir" && as_dir=.
38891    for ac_exec_ext in '' $ac_executable_extensions; do
38892  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38893    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38894    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38895    break 2
38896  fi
38897done
38898  done
38899IFS=$as_save_IFS
38900
38901  ;;
38902esac
38903fi
38904BUILD_CC=$ac_cv_path_BUILD_CC
38905if test -n "$BUILD_CC"; then
38906  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38907$as_echo "$BUILD_CC" >&6; }
38908else
38909  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38910$as_echo "no" >&6; }
38911fi
38912
38913
38914  test -n "$BUILD_CC" && break
38915done
38916
38917    else
38918      # If it succeeded, then it was overridden by the user. We will use it
38919      # for the tool.
38920
38921      # First remove it from the list of overridden variables, so we can test
38922      # for unknown variables in the end.
38923      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38924
38925      # Check if the provided tool contains a complete path.
38926      tool_specified="$BUILD_CC"
38927      tool_basename="${tool_specified##*/}"
38928      if test "x$tool_basename" = "x$tool_specified"; then
38929        # A command without a complete path is provided, search $PATH.
38930        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
38931$as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
38932        # Extract the first word of "$tool_basename", so it can be a program name with args.
38933set dummy $tool_basename; ac_word=$2
38934{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38935$as_echo_n "checking for $ac_word... " >&6; }
38936if ${ac_cv_path_BUILD_CC+:} false; then :
38937  $as_echo_n "(cached) " >&6
38938else
38939  case $BUILD_CC in
38940  [\\/]* | ?:[\\/]*)
38941  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38942  ;;
38943  *)
38944  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38945for as_dir in $PATH
38946do
38947  IFS=$as_save_IFS
38948  test -z "$as_dir" && as_dir=.
38949    for ac_exec_ext in '' $ac_executable_extensions; do
38950  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38951    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38952    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38953    break 2
38954  fi
38955done
38956  done
38957IFS=$as_save_IFS
38958
38959  ;;
38960esac
38961fi
38962BUILD_CC=$ac_cv_path_BUILD_CC
38963if test -n "$BUILD_CC"; then
38964  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38965$as_echo "$BUILD_CC" >&6; }
38966else
38967  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38968$as_echo "no" >&6; }
38969fi
38970
38971
38972        if test "x$BUILD_CC" = x; then
38973          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38974        fi
38975      else
38976        # Otherwise we believe it is a complete path. Use it as it is.
38977        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
38978$as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
38979        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
38980$as_echo_n "checking for BUILD_CC... " >&6; }
38981        if test ! -x "$tool_specified"; then
38982          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38983$as_echo "not found" >&6; }
38984          as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
38985        fi
38986        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38987$as_echo "$tool_specified" >&6; }
38988      fi
38989    fi
38990  fi
38991
38992
38993
38994  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38995
38996  # First separate the path from the arguments. This will split at the first
38997  # space.
38998  complete="$BUILD_CC"
38999  path="${complete%% *}"
39000  tmp="$complete EOL"
39001  arguments="${tmp#* }"
39002
39003  # Input might be given as Windows format, start by converting to
39004  # unix format.
39005  new_path=`$CYGPATH -u "$path"`
39006
39007  # Now try to locate executable using which
39008  new_path=`$WHICH "$new_path" 2> /dev/null`
39009  # bat and cmd files are not always considered executable in cygwin causing which
39010  # to not find them
39011  if test "x$new_path" = x \
39012      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39013      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39014    new_path=`$CYGPATH -u "$path"`
39015  fi
39016  if test "x$new_path" = x; then
39017    # Oops. Which didn't find the executable.
39018    # The splitting of arguments from the executable at a space might have been incorrect,
39019    # since paths with space are more likely in Windows. Give it another try with the whole
39020    # argument.
39021    path="$complete"
39022    arguments="EOL"
39023    new_path=`$CYGPATH -u "$path"`
39024    new_path=`$WHICH "$new_path" 2> /dev/null`
39025    # bat and cmd files are not always considered executable in cygwin causing which
39026    # to not find them
39027    if test "x$new_path" = x \
39028        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39029        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39030      new_path=`$CYGPATH -u "$path"`
39031    fi
39032    if test "x$new_path" = x; then
39033      # It's still not found. Now this is an unrecoverable error.
39034      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39035$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39036      has_space=`$ECHO "$complete" | $GREP " "`
39037      if test "x$has_space" != x; then
39038        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39039$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39040      fi
39041      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39042    fi
39043  fi
39044
39045  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39046  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39047  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39048  # "foo.exe" is OK but "foo" is an error.
39049  #
39050  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39051  # It is also a way to make sure we got the proper file name for the real test later on.
39052  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39053  if test "x$test_shortpath" = x; then
39054    # Short path failed, file does not exist as specified.
39055    # Try adding .exe or .cmd
39056    if test -f "${new_path}.exe"; then
39057      input_to_shortpath="${new_path}.exe"
39058    elif test -f "${new_path}.cmd"; then
39059      input_to_shortpath="${new_path}.cmd"
39060    else
39061      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
39062$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
39063      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39064$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39065      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39066    fi
39067  else
39068    input_to_shortpath="$new_path"
39069  fi
39070
39071  # Call helper function which possibly converts this using DOS-style short mode.
39072  # If so, the updated path is stored in $new_path.
39073  new_path="$input_to_shortpath"
39074
39075  input_path="$input_to_shortpath"
39076  # Check if we need to convert this using DOS-style short mode. If the path
39077  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39078  # take no chances and rewrite it.
39079  # Note: m4 eats our [], so we need to use [ and ] instead.
39080  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39081  if test "x$has_forbidden_chars" != x; then
39082    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39083    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39084    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39085    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39086      # Going to short mode and back again did indeed matter. Since short mode is
39087      # case insensitive, let's make it lowercase to improve readability.
39088      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39089      # Now convert it back to Unix-stile (cygpath)
39090      input_path=`$CYGPATH -u "$shortmode_path"`
39091      new_path="$input_path"
39092    fi
39093  fi
39094
39095  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39096  if test "x$test_cygdrive_prefix" = x; then
39097    # As a simple fix, exclude /usr/bin since it's not a real path.
39098    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39099      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39100      # a path prefixed by /cygdrive for fixpath to work.
39101      new_path="$CYGWIN_ROOT_PATH$input_path"
39102    fi
39103  fi
39104
39105  # remove trailing .exe if any
39106  new_path="${new_path/%.exe/}"
39107
39108  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39109
39110  # First separate the path from the arguments. This will split at the first
39111  # space.
39112  complete="$BUILD_CC"
39113  path="${complete%% *}"
39114  tmp="$complete EOL"
39115  arguments="${tmp#* }"
39116
39117  # Input might be given as Windows format, start by converting to
39118  # unix format.
39119  new_path="$path"
39120
39121  windows_path="$new_path"
39122  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39123    unix_path=`$CYGPATH -u "$windows_path"`
39124    new_path="$unix_path"
39125  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39126    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39127    new_path="$unix_path"
39128  fi
39129
39130
39131  # Now try to locate executable using which
39132  new_path=`$WHICH "$new_path" 2> /dev/null`
39133
39134  if test "x$new_path" = x; then
39135    # Oops. Which didn't find the executable.
39136    # The splitting of arguments from the executable at a space might have been incorrect,
39137    # since paths with space are more likely in Windows. Give it another try with the whole
39138    # argument.
39139    path="$complete"
39140    arguments="EOL"
39141    new_path="$path"
39142
39143  windows_path="$new_path"
39144  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39145    unix_path=`$CYGPATH -u "$windows_path"`
39146    new_path="$unix_path"
39147  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39148    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39149    new_path="$unix_path"
39150  fi
39151
39152
39153    new_path=`$WHICH "$new_path" 2> /dev/null`
39154
39155    if test "x$new_path" = x; then
39156      # It's still not found. Now this is an unrecoverable error.
39157      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39158$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39159      has_space=`$ECHO "$complete" | $GREP " "`
39160      if test "x$has_space" != x; then
39161        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39162$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39163      fi
39164      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39165    fi
39166  fi
39167
39168  # Now new_path has a complete unix path to the binary
39169  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39170    # Keep paths in /bin as-is, but remove trailing .exe if any
39171    new_path="${new_path/%.exe/}"
39172    # Do not save /bin paths to all_fixpath_prefixes!
39173  else
39174    # Not in mixed or Windows style, start by that.
39175    new_path=`cmd //c echo $new_path`
39176
39177  input_path="$new_path"
39178  # Check if we need to convert this using DOS-style short mode. If the path
39179  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39180  # take no chances and rewrite it.
39181  # Note: m4 eats our [], so we need to use [ and ] instead.
39182  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39183  if test "x$has_forbidden_chars" != x; then
39184    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39185    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39186  fi
39187
39188    # Output is in $new_path
39189
39190  windows_path="$new_path"
39191  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39192    unix_path=`$CYGPATH -u "$windows_path"`
39193    new_path="$unix_path"
39194  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39195    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39196    new_path="$unix_path"
39197  fi
39198
39199    # remove trailing .exe if any
39200    new_path="${new_path/%.exe/}"
39201
39202    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39203    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39204  fi
39205
39206  else
39207    # We're on a posix platform. Hooray! :)
39208    # First separate the path from the arguments. This will split at the first
39209    # space.
39210    complete="$BUILD_CC"
39211    path="${complete%% *}"
39212    tmp="$complete EOL"
39213    arguments="${tmp#* }"
39214
39215    # Cannot rely on the command "which" here since it doesn't always work.
39216    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39217    if test -z "$is_absolute_path"; then
39218      # Path to executable is not absolute. Find it.
39219      IFS_save="$IFS"
39220      IFS=:
39221      for p in $PATH; do
39222        if test -f "$p/$path" && test -x "$p/$path"; then
39223          new_path="$p/$path"
39224          break
39225        fi
39226      done
39227      IFS="$IFS_save"
39228    else
39229      # This is an absolute path, we can use it without further modifications.
39230      new_path="$path"
39231    fi
39232
39233    if test "x$new_path" = x; then
39234      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39235$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39236      has_space=`$ECHO "$complete" | $GREP " "`
39237      if test "x$has_space" != x; then
39238        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39239$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39240      fi
39241      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39242    fi
39243  fi
39244
39245  # Now join together the path and the arguments once again
39246  if test "x$arguments" != xEOL; then
39247    new_complete="$new_path ${arguments% *}"
39248  else
39249    new_complete="$new_path"
39250  fi
39251
39252  if test "x$complete" != "x$new_complete"; then
39253    BUILD_CC="$new_complete"
39254    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
39255$as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
39256  fi
39257
39258
39259
39260  # Publish this variable in the help.
39261
39262
39263  if test "x$BUILD_CXX" = x; then
39264    # The variable is not set by user, try to locate tool using the code snippet
39265    for ac_prog in cl CC g++
39266do
39267  # Extract the first word of "$ac_prog", so it can be a program name with args.
39268set dummy $ac_prog; ac_word=$2
39269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39270$as_echo_n "checking for $ac_word... " >&6; }
39271if ${ac_cv_path_BUILD_CXX+:} false; then :
39272  $as_echo_n "(cached) " >&6
39273else
39274  case $BUILD_CXX in
39275  [\\/]* | ?:[\\/]*)
39276  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39277  ;;
39278  *)
39279  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39280for as_dir in $PATH
39281do
39282  IFS=$as_save_IFS
39283  test -z "$as_dir" && as_dir=.
39284    for ac_exec_ext in '' $ac_executable_extensions; do
39285  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39286    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39287    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39288    break 2
39289  fi
39290done
39291  done
39292IFS=$as_save_IFS
39293
39294  ;;
39295esac
39296fi
39297BUILD_CXX=$ac_cv_path_BUILD_CXX
39298if test -n "$BUILD_CXX"; then
39299  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39300$as_echo "$BUILD_CXX" >&6; }
39301else
39302  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39303$as_echo "no" >&6; }
39304fi
39305
39306
39307  test -n "$BUILD_CXX" && break
39308done
39309
39310  else
39311    # The variable is set, but is it from the command line or the environment?
39312
39313    # Try to remove the string !BUILD_CXX! from our list.
39314    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
39315    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39316      # If it failed, the variable was not from the command line. Ignore it,
39317      # but warn the user (except for BASH, which is always set by the calling BASH).
39318      if test "xBUILD_CXX" != xBASH; then
39319        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
39320$as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
39321      fi
39322      # Try to locate tool using the code snippet
39323      for ac_prog in cl CC g++
39324do
39325  # Extract the first word of "$ac_prog", so it can be a program name with args.
39326set dummy $ac_prog; ac_word=$2
39327{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39328$as_echo_n "checking for $ac_word... " >&6; }
39329if ${ac_cv_path_BUILD_CXX+:} false; then :
39330  $as_echo_n "(cached) " >&6
39331else
39332  case $BUILD_CXX in
39333  [\\/]* | ?:[\\/]*)
39334  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39335  ;;
39336  *)
39337  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39338for as_dir in $PATH
39339do
39340  IFS=$as_save_IFS
39341  test -z "$as_dir" && as_dir=.
39342    for ac_exec_ext in '' $ac_executable_extensions; do
39343  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39344    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39345    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39346    break 2
39347  fi
39348done
39349  done
39350IFS=$as_save_IFS
39351
39352  ;;
39353esac
39354fi
39355BUILD_CXX=$ac_cv_path_BUILD_CXX
39356if test -n "$BUILD_CXX"; then
39357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39358$as_echo "$BUILD_CXX" >&6; }
39359else
39360  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39361$as_echo "no" >&6; }
39362fi
39363
39364
39365  test -n "$BUILD_CXX" && break
39366done
39367
39368    else
39369      # If it succeeded, then it was overridden by the user. We will use it
39370      # for the tool.
39371
39372      # First remove it from the list of overridden variables, so we can test
39373      # for unknown variables in the end.
39374      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39375
39376      # Check if the provided tool contains a complete path.
39377      tool_specified="$BUILD_CXX"
39378      tool_basename="${tool_specified##*/}"
39379      if test "x$tool_basename" = "x$tool_specified"; then
39380        # A command without a complete path is provided, search $PATH.
39381        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
39382$as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
39383        # Extract the first word of "$tool_basename", so it can be a program name with args.
39384set dummy $tool_basename; ac_word=$2
39385{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39386$as_echo_n "checking for $ac_word... " >&6; }
39387if ${ac_cv_path_BUILD_CXX+:} false; then :
39388  $as_echo_n "(cached) " >&6
39389else
39390  case $BUILD_CXX in
39391  [\\/]* | ?:[\\/]*)
39392  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39393  ;;
39394  *)
39395  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39396for as_dir in $PATH
39397do
39398  IFS=$as_save_IFS
39399  test -z "$as_dir" && as_dir=.
39400    for ac_exec_ext in '' $ac_executable_extensions; do
39401  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39402    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39403    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39404    break 2
39405  fi
39406done
39407  done
39408IFS=$as_save_IFS
39409
39410  ;;
39411esac
39412fi
39413BUILD_CXX=$ac_cv_path_BUILD_CXX
39414if test -n "$BUILD_CXX"; then
39415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39416$as_echo "$BUILD_CXX" >&6; }
39417else
39418  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39419$as_echo "no" >&6; }
39420fi
39421
39422
39423        if test "x$BUILD_CXX" = x; then
39424          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39425        fi
39426      else
39427        # Otherwise we believe it is a complete path. Use it as it is.
39428        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
39429$as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
39430        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
39431$as_echo_n "checking for BUILD_CXX... " >&6; }
39432        if test ! -x "$tool_specified"; then
39433          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39434$as_echo "not found" >&6; }
39435          as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
39436        fi
39437        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39438$as_echo "$tool_specified" >&6; }
39439      fi
39440    fi
39441  fi
39442
39443
39444
39445  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39446
39447  # First separate the path from the arguments. This will split at the first
39448  # space.
39449  complete="$BUILD_CXX"
39450  path="${complete%% *}"
39451  tmp="$complete EOL"
39452  arguments="${tmp#* }"
39453
39454  # Input might be given as Windows format, start by converting to
39455  # unix format.
39456  new_path=`$CYGPATH -u "$path"`
39457
39458  # Now try to locate executable using which
39459  new_path=`$WHICH "$new_path" 2> /dev/null`
39460  # bat and cmd files are not always considered executable in cygwin causing which
39461  # to not find them
39462  if test "x$new_path" = x \
39463      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39464      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39465    new_path=`$CYGPATH -u "$path"`
39466  fi
39467  if test "x$new_path" = x; then
39468    # Oops. Which didn't find the executable.
39469    # The splitting of arguments from the executable at a space might have been incorrect,
39470    # since paths with space are more likely in Windows. Give it another try with the whole
39471    # argument.
39472    path="$complete"
39473    arguments="EOL"
39474    new_path=`$CYGPATH -u "$path"`
39475    new_path=`$WHICH "$new_path" 2> /dev/null`
39476    # bat and cmd files are not always considered executable in cygwin causing which
39477    # to not find them
39478    if test "x$new_path" = x \
39479        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39480        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39481      new_path=`$CYGPATH -u "$path"`
39482    fi
39483    if test "x$new_path" = x; then
39484      # It's still not found. Now this is an unrecoverable error.
39485      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39486$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39487      has_space=`$ECHO "$complete" | $GREP " "`
39488      if test "x$has_space" != x; then
39489        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39490$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39491      fi
39492      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39493    fi
39494  fi
39495
39496  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39497  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39498  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39499  # "foo.exe" is OK but "foo" is an error.
39500  #
39501  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39502  # It is also a way to make sure we got the proper file name for the real test later on.
39503  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39504  if test "x$test_shortpath" = x; then
39505    # Short path failed, file does not exist as specified.
39506    # Try adding .exe or .cmd
39507    if test -f "${new_path}.exe"; then
39508      input_to_shortpath="${new_path}.exe"
39509    elif test -f "${new_path}.cmd"; then
39510      input_to_shortpath="${new_path}.cmd"
39511    else
39512      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
39513$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
39514      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39515$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39516      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39517    fi
39518  else
39519    input_to_shortpath="$new_path"
39520  fi
39521
39522  # Call helper function which possibly converts this using DOS-style short mode.
39523  # If so, the updated path is stored in $new_path.
39524  new_path="$input_to_shortpath"
39525
39526  input_path="$input_to_shortpath"
39527  # Check if we need to convert this using DOS-style short mode. If the path
39528  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39529  # take no chances and rewrite it.
39530  # Note: m4 eats our [], so we need to use [ and ] instead.
39531  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39532  if test "x$has_forbidden_chars" != x; then
39533    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39534    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39535    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39536    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39537      # Going to short mode and back again did indeed matter. Since short mode is
39538      # case insensitive, let's make it lowercase to improve readability.
39539      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39540      # Now convert it back to Unix-stile (cygpath)
39541      input_path=`$CYGPATH -u "$shortmode_path"`
39542      new_path="$input_path"
39543    fi
39544  fi
39545
39546  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39547  if test "x$test_cygdrive_prefix" = x; then
39548    # As a simple fix, exclude /usr/bin since it's not a real path.
39549    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39550      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39551      # a path prefixed by /cygdrive for fixpath to work.
39552      new_path="$CYGWIN_ROOT_PATH$input_path"
39553    fi
39554  fi
39555
39556  # remove trailing .exe if any
39557  new_path="${new_path/%.exe/}"
39558
39559  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39560
39561  # First separate the path from the arguments. This will split at the first
39562  # space.
39563  complete="$BUILD_CXX"
39564  path="${complete%% *}"
39565  tmp="$complete EOL"
39566  arguments="${tmp#* }"
39567
39568  # Input might be given as Windows format, start by converting to
39569  # unix format.
39570  new_path="$path"
39571
39572  windows_path="$new_path"
39573  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39574    unix_path=`$CYGPATH -u "$windows_path"`
39575    new_path="$unix_path"
39576  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39577    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39578    new_path="$unix_path"
39579  fi
39580
39581
39582  # Now try to locate executable using which
39583  new_path=`$WHICH "$new_path" 2> /dev/null`
39584
39585  if test "x$new_path" = x; then
39586    # Oops. Which didn't find the executable.
39587    # The splitting of arguments from the executable at a space might have been incorrect,
39588    # since paths with space are more likely in Windows. Give it another try with the whole
39589    # argument.
39590    path="$complete"
39591    arguments="EOL"
39592    new_path="$path"
39593
39594  windows_path="$new_path"
39595  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39596    unix_path=`$CYGPATH -u "$windows_path"`
39597    new_path="$unix_path"
39598  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39599    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39600    new_path="$unix_path"
39601  fi
39602
39603
39604    new_path=`$WHICH "$new_path" 2> /dev/null`
39605
39606    if test "x$new_path" = x; then
39607      # It's still not found. Now this is an unrecoverable error.
39608      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39609$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39610      has_space=`$ECHO "$complete" | $GREP " "`
39611      if test "x$has_space" != x; then
39612        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39613$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39614      fi
39615      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39616    fi
39617  fi
39618
39619  # Now new_path has a complete unix path to the binary
39620  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39621    # Keep paths in /bin as-is, but remove trailing .exe if any
39622    new_path="${new_path/%.exe/}"
39623    # Do not save /bin paths to all_fixpath_prefixes!
39624  else
39625    # Not in mixed or Windows style, start by that.
39626    new_path=`cmd //c echo $new_path`
39627
39628  input_path="$new_path"
39629  # Check if we need to convert this using DOS-style short mode. If the path
39630  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39631  # take no chances and rewrite it.
39632  # Note: m4 eats our [], so we need to use [ and ] instead.
39633  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39634  if test "x$has_forbidden_chars" != x; then
39635    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39636    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39637  fi
39638
39639    # Output is in $new_path
39640
39641  windows_path="$new_path"
39642  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39643    unix_path=`$CYGPATH -u "$windows_path"`
39644    new_path="$unix_path"
39645  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39646    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39647    new_path="$unix_path"
39648  fi
39649
39650    # remove trailing .exe if any
39651    new_path="${new_path/%.exe/}"
39652
39653    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39654    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39655  fi
39656
39657  else
39658    # We're on a posix platform. Hooray! :)
39659    # First separate the path from the arguments. This will split at the first
39660    # space.
39661    complete="$BUILD_CXX"
39662    path="${complete%% *}"
39663    tmp="$complete EOL"
39664    arguments="${tmp#* }"
39665
39666    # Cannot rely on the command "which" here since it doesn't always work.
39667    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39668    if test -z "$is_absolute_path"; then
39669      # Path to executable is not absolute. Find it.
39670      IFS_save="$IFS"
39671      IFS=:
39672      for p in $PATH; do
39673        if test -f "$p/$path" && test -x "$p/$path"; then
39674          new_path="$p/$path"
39675          break
39676        fi
39677      done
39678      IFS="$IFS_save"
39679    else
39680      # This is an absolute path, we can use it without further modifications.
39681      new_path="$path"
39682    fi
39683
39684    if test "x$new_path" = x; then
39685      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39686$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39687      has_space=`$ECHO "$complete" | $GREP " "`
39688      if test "x$has_space" != x; then
39689        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39690$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39691      fi
39692      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39693    fi
39694  fi
39695
39696  # Now join together the path and the arguments once again
39697  if test "x$arguments" != xEOL; then
39698    new_complete="$new_path ${arguments% *}"
39699  else
39700    new_complete="$new_path"
39701  fi
39702
39703  if test "x$complete" != "x$new_complete"; then
39704    BUILD_CXX="$new_complete"
39705    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
39706$as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
39707  fi
39708
39709
39710
39711  # Publish this variable in the help.
39712
39713
39714  if test "x$BUILD_LD" = x; then
39715    # The variable is not set by user, try to locate tool using the code snippet
39716    for ac_prog in ld
39717do
39718  # Extract the first word of "$ac_prog", so it can be a program name with args.
39719set dummy $ac_prog; ac_word=$2
39720{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39721$as_echo_n "checking for $ac_word... " >&6; }
39722if ${ac_cv_path_BUILD_LD+:} false; then :
39723  $as_echo_n "(cached) " >&6
39724else
39725  case $BUILD_LD in
39726  [\\/]* | ?:[\\/]*)
39727  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39728  ;;
39729  *)
39730  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39731for as_dir in $PATH
39732do
39733  IFS=$as_save_IFS
39734  test -z "$as_dir" && as_dir=.
39735    for ac_exec_ext in '' $ac_executable_extensions; do
39736  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39737    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39738    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39739    break 2
39740  fi
39741done
39742  done
39743IFS=$as_save_IFS
39744
39745  ;;
39746esac
39747fi
39748BUILD_LD=$ac_cv_path_BUILD_LD
39749if test -n "$BUILD_LD"; then
39750  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39751$as_echo "$BUILD_LD" >&6; }
39752else
39753  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39754$as_echo "no" >&6; }
39755fi
39756
39757
39758  test -n "$BUILD_LD" && break
39759done
39760
39761  else
39762    # The variable is set, but is it from the command line or the environment?
39763
39764    # Try to remove the string !BUILD_LD! from our list.
39765    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
39766    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39767      # If it failed, the variable was not from the command line. Ignore it,
39768      # but warn the user (except for BASH, which is always set by the calling BASH).
39769      if test "xBUILD_LD" != xBASH; then
39770        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
39771$as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
39772      fi
39773      # Try to locate tool using the code snippet
39774      for ac_prog in ld
39775do
39776  # Extract the first word of "$ac_prog", so it can be a program name with args.
39777set dummy $ac_prog; ac_word=$2
39778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39779$as_echo_n "checking for $ac_word... " >&6; }
39780if ${ac_cv_path_BUILD_LD+:} false; then :
39781  $as_echo_n "(cached) " >&6
39782else
39783  case $BUILD_LD in
39784  [\\/]* | ?:[\\/]*)
39785  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39786  ;;
39787  *)
39788  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39789for as_dir in $PATH
39790do
39791  IFS=$as_save_IFS
39792  test -z "$as_dir" && as_dir=.
39793    for ac_exec_ext in '' $ac_executable_extensions; do
39794  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39795    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39796    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39797    break 2
39798  fi
39799done
39800  done
39801IFS=$as_save_IFS
39802
39803  ;;
39804esac
39805fi
39806BUILD_LD=$ac_cv_path_BUILD_LD
39807if test -n "$BUILD_LD"; then
39808  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39809$as_echo "$BUILD_LD" >&6; }
39810else
39811  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39812$as_echo "no" >&6; }
39813fi
39814
39815
39816  test -n "$BUILD_LD" && break
39817done
39818
39819    else
39820      # If it succeeded, then it was overridden by the user. We will use it
39821      # for the tool.
39822
39823      # First remove it from the list of overridden variables, so we can test
39824      # for unknown variables in the end.
39825      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39826
39827      # Check if the provided tool contains a complete path.
39828      tool_specified="$BUILD_LD"
39829      tool_basename="${tool_specified##*/}"
39830      if test "x$tool_basename" = "x$tool_specified"; then
39831        # A command without a complete path is provided, search $PATH.
39832        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
39833$as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
39834        # Extract the first word of "$tool_basename", so it can be a program name with args.
39835set dummy $tool_basename; ac_word=$2
39836{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39837$as_echo_n "checking for $ac_word... " >&6; }
39838if ${ac_cv_path_BUILD_LD+:} false; then :
39839  $as_echo_n "(cached) " >&6
39840else
39841  case $BUILD_LD in
39842  [\\/]* | ?:[\\/]*)
39843  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39844  ;;
39845  *)
39846  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39847for as_dir in $PATH
39848do
39849  IFS=$as_save_IFS
39850  test -z "$as_dir" && as_dir=.
39851    for ac_exec_ext in '' $ac_executable_extensions; do
39852  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39853    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39854    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39855    break 2
39856  fi
39857done
39858  done
39859IFS=$as_save_IFS
39860
39861  ;;
39862esac
39863fi
39864BUILD_LD=$ac_cv_path_BUILD_LD
39865if test -n "$BUILD_LD"; then
39866  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39867$as_echo "$BUILD_LD" >&6; }
39868else
39869  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39870$as_echo "no" >&6; }
39871fi
39872
39873
39874        if test "x$BUILD_LD" = x; then
39875          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39876        fi
39877      else
39878        # Otherwise we believe it is a complete path. Use it as it is.
39879        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
39880$as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
39881        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
39882$as_echo_n "checking for BUILD_LD... " >&6; }
39883        if test ! -x "$tool_specified"; then
39884          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39885$as_echo "not found" >&6; }
39886          as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
39887        fi
39888        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39889$as_echo "$tool_specified" >&6; }
39890      fi
39891    fi
39892  fi
39893
39894
39895
39896  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39897
39898  # First separate the path from the arguments. This will split at the first
39899  # space.
39900  complete="$BUILD_LD"
39901  path="${complete%% *}"
39902  tmp="$complete EOL"
39903  arguments="${tmp#* }"
39904
39905  # Input might be given as Windows format, start by converting to
39906  # unix format.
39907  new_path=`$CYGPATH -u "$path"`
39908
39909  # Now try to locate executable using which
39910  new_path=`$WHICH "$new_path" 2> /dev/null`
39911  # bat and cmd files are not always considered executable in cygwin causing which
39912  # to not find them
39913  if test "x$new_path" = x \
39914      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39915      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39916    new_path=`$CYGPATH -u "$path"`
39917  fi
39918  if test "x$new_path" = x; then
39919    # Oops. Which didn't find the executable.
39920    # The splitting of arguments from the executable at a space might have been incorrect,
39921    # since paths with space are more likely in Windows. Give it another try with the whole
39922    # argument.
39923    path="$complete"
39924    arguments="EOL"
39925    new_path=`$CYGPATH -u "$path"`
39926    new_path=`$WHICH "$new_path" 2> /dev/null`
39927    # bat and cmd files are not always considered executable in cygwin causing which
39928    # to not find them
39929    if test "x$new_path" = x \
39930        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39931        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39932      new_path=`$CYGPATH -u "$path"`
39933    fi
39934    if test "x$new_path" = x; then
39935      # It's still not found. Now this is an unrecoverable error.
39936      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39937$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39938      has_space=`$ECHO "$complete" | $GREP " "`
39939      if test "x$has_space" != x; then
39940        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39941$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39942      fi
39943      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39944    fi
39945  fi
39946
39947  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39948  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39949  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39950  # "foo.exe" is OK but "foo" is an error.
39951  #
39952  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39953  # It is also a way to make sure we got the proper file name for the real test later on.
39954  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39955  if test "x$test_shortpath" = x; then
39956    # Short path failed, file does not exist as specified.
39957    # Try adding .exe or .cmd
39958    if test -f "${new_path}.exe"; then
39959      input_to_shortpath="${new_path}.exe"
39960    elif test -f "${new_path}.cmd"; then
39961      input_to_shortpath="${new_path}.cmd"
39962    else
39963      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
39964$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
39965      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39966$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39967      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39968    fi
39969  else
39970    input_to_shortpath="$new_path"
39971  fi
39972
39973  # Call helper function which possibly converts this using DOS-style short mode.
39974  # If so, the updated path is stored in $new_path.
39975  new_path="$input_to_shortpath"
39976
39977  input_path="$input_to_shortpath"
39978  # Check if we need to convert this using DOS-style short mode. If the path
39979  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39980  # take no chances and rewrite it.
39981  # Note: m4 eats our [], so we need to use [ and ] instead.
39982  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39983  if test "x$has_forbidden_chars" != x; then
39984    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39985    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39986    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39987    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39988      # Going to short mode and back again did indeed matter. Since short mode is
39989      # case insensitive, let's make it lowercase to improve readability.
39990      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39991      # Now convert it back to Unix-stile (cygpath)
39992      input_path=`$CYGPATH -u "$shortmode_path"`
39993      new_path="$input_path"
39994    fi
39995  fi
39996
39997  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39998  if test "x$test_cygdrive_prefix" = x; then
39999    # As a simple fix, exclude /usr/bin since it's not a real path.
40000    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
40001      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40002      # a path prefixed by /cygdrive for fixpath to work.
40003      new_path="$CYGWIN_ROOT_PATH$input_path"
40004    fi
40005  fi
40006
40007  # remove trailing .exe if any
40008  new_path="${new_path/%.exe/}"
40009
40010  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40011
40012  # First separate the path from the arguments. This will split at the first
40013  # space.
40014  complete="$BUILD_LD"
40015  path="${complete%% *}"
40016  tmp="$complete EOL"
40017  arguments="${tmp#* }"
40018
40019  # Input might be given as Windows format, start by converting to
40020  # unix format.
40021  new_path="$path"
40022
40023  windows_path="$new_path"
40024  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40025    unix_path=`$CYGPATH -u "$windows_path"`
40026    new_path="$unix_path"
40027  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40028    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40029    new_path="$unix_path"
40030  fi
40031
40032
40033  # Now try to locate executable using which
40034  new_path=`$WHICH "$new_path" 2> /dev/null`
40035
40036  if test "x$new_path" = x; then
40037    # Oops. Which didn't find the executable.
40038    # The splitting of arguments from the executable at a space might have been incorrect,
40039    # since paths with space are more likely in Windows. Give it another try with the whole
40040    # argument.
40041    path="$complete"
40042    arguments="EOL"
40043    new_path="$path"
40044
40045  windows_path="$new_path"
40046  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40047    unix_path=`$CYGPATH -u "$windows_path"`
40048    new_path="$unix_path"
40049  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40050    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40051    new_path="$unix_path"
40052  fi
40053
40054
40055    new_path=`$WHICH "$new_path" 2> /dev/null`
40056
40057    if test "x$new_path" = x; then
40058      # It's still not found. Now this is an unrecoverable error.
40059      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40060$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40061      has_space=`$ECHO "$complete" | $GREP " "`
40062      if test "x$has_space" != x; then
40063        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40064$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40065      fi
40066      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40067    fi
40068  fi
40069
40070  # Now new_path has a complete unix path to the binary
40071  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
40072    # Keep paths in /bin as-is, but remove trailing .exe if any
40073    new_path="${new_path/%.exe/}"
40074    # Do not save /bin paths to all_fixpath_prefixes!
40075  else
40076    # Not in mixed or Windows style, start by that.
40077    new_path=`cmd //c echo $new_path`
40078
40079  input_path="$new_path"
40080  # Check if we need to convert this using DOS-style short mode. If the path
40081  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40082  # take no chances and rewrite it.
40083  # Note: m4 eats our [], so we need to use [ and ] instead.
40084  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40085  if test "x$has_forbidden_chars" != x; then
40086    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40087    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40088  fi
40089
40090    # Output is in $new_path
40091
40092  windows_path="$new_path"
40093  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40094    unix_path=`$CYGPATH -u "$windows_path"`
40095    new_path="$unix_path"
40096  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40097    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40098    new_path="$unix_path"
40099  fi
40100
40101    # remove trailing .exe if any
40102    new_path="${new_path/%.exe/}"
40103
40104    # Save the first 10 bytes of this path to the storage, so fixpath can work.
40105    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40106  fi
40107
40108  else
40109    # We're on a posix platform. Hooray! :)
40110    # First separate the path from the arguments. This will split at the first
40111    # space.
40112    complete="$BUILD_LD"
40113    path="${complete%% *}"
40114    tmp="$complete EOL"
40115    arguments="${tmp#* }"
40116
40117    # Cannot rely on the command "which" here since it doesn't always work.
40118    is_absolute_path=`$ECHO "$path" | $GREP ^/`
40119    if test -z "$is_absolute_path"; then
40120      # Path to executable is not absolute. Find it.
40121      IFS_save="$IFS"
40122      IFS=:
40123      for p in $PATH; do
40124        if test -f "$p/$path" && test -x "$p/$path"; then
40125          new_path="$p/$path"
40126          break
40127        fi
40128      done
40129      IFS="$IFS_save"
40130    else
40131      # This is an absolute path, we can use it without further modifications.
40132      new_path="$path"
40133    fi
40134
40135    if test "x$new_path" = x; then
40136      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40137$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40138      has_space=`$ECHO "$complete" | $GREP " "`
40139      if test "x$has_space" != x; then
40140        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40141$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40142      fi
40143      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40144    fi
40145  fi
40146
40147  # Now join together the path and the arguments once again
40148  if test "x$arguments" != xEOL; then
40149    new_complete="$new_path ${arguments% *}"
40150  else
40151    new_complete="$new_path"
40152  fi
40153
40154  if test "x$complete" != "x$new_complete"; then
40155    BUILD_LD="$new_complete"
40156    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
40157$as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
40158  fi
40159
40160  else
40161    # If we are not cross compiling, use the normal target compilers for
40162    # building the build platform executables.
40163    BUILD_CC="$CC"
40164    BUILD_CXX="$CXX"
40165    BUILD_LD="$LD"
40166  fi
40167
40168
40169
40170
40171
40172
40173  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40174    # For hotspot, we need these in Windows mixed path,
40175    # so rewrite them all. Need added .exe suffix.
40176    HOTSPOT_CXX="$CXX.exe"
40177    HOTSPOT_LD="$LD.exe"
40178    HOTSPOT_MT="$MT.exe"
40179    HOTSPOT_RC="$RC.exe"
40180
40181  unix_path="$HOTSPOT_CXX"
40182  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40183    windows_path=`$CYGPATH -m "$unix_path"`
40184    HOTSPOT_CXX="$windows_path"
40185  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40186    windows_path=`cmd //c echo $unix_path`
40187    HOTSPOT_CXX="$windows_path"
40188  fi
40189
40190
40191  unix_path="$HOTSPOT_LD"
40192  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40193    windows_path=`$CYGPATH -m "$unix_path"`
40194    HOTSPOT_LD="$windows_path"
40195  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40196    windows_path=`cmd //c echo $unix_path`
40197    HOTSPOT_LD="$windows_path"
40198  fi
40199
40200
40201  unix_path="$HOTSPOT_MT"
40202  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40203    windows_path=`$CYGPATH -m "$unix_path"`
40204    HOTSPOT_MT="$windows_path"
40205  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40206    windows_path=`cmd //c echo $unix_path`
40207    HOTSPOT_MT="$windows_path"
40208  fi
40209
40210
40211  unix_path="$HOTSPOT_RC"
40212  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40213    windows_path=`$CYGPATH -m "$unix_path"`
40214    HOTSPOT_RC="$windows_path"
40215  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40216    windows_path=`cmd //c echo $unix_path`
40217    HOTSPOT_RC="$windows_path"
40218  fi
40219
40220
40221
40222  else
40223    HOTSPOT_CXX="$CXX"
40224    HOTSPOT_LD="$LD"
40225  fi
40226
40227
40228
40229  if test  "x$TOOLCHAIN_TYPE" = xclang; then
40230    USE_CLANG=true
40231  fi
40232
40233
40234  # LDEXE is the linker to use, when creating executables. Not really used.
40235  # FIXME: These should just be removed!
40236  LDEXE="$LD"
40237  LDEXECXX="$LDCXX"
40238
40239
40240
40241
40242  # The package path is used only on macosx?
40243  # FIXME: clean this up, and/or move it elsewhere.
40244  PACKAGE_PATH=/opt/local
40245
40246
40247  # Check for extra potential brokenness.
40248  if test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40249    # On Windows, double-check that we got the right compiler.
40250    CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'`
40251    COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"`
40252    if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
40253      if test "x$COMPILER_CPU_TEST" != "x80x86"; then
40254        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
40255      fi
40256    elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
40257      if test "x$COMPILER_CPU_TEST" != "xx64"; then
40258        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
40259      fi
40260    fi
40261  fi
40262
40263  if test "x$TOOLCHAIN_TYPE" = xgcc; then
40264    # If this is a --hash-style=gnu system, use --hash-style=both, why?
40265    HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
40266    # This is later checked when setting flags.
40267  fi
40268
40269  # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed
40270  # in executable.'
40271  USING_BROKEN_SUSE_LD=no
40272  if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then
40273    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
40274$as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
40275    echo "SUNWprivate_1.1 { local: *; };" > version-script.map
40276    echo "int main() { }" > main.c
40277    if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
40278      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40279$as_echo "no" >&6; }
40280      USING_BROKEN_SUSE_LD=no
40281    else
40282      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40283$as_echo "yes" >&6; }
40284      USING_BROKEN_SUSE_LD=yes
40285    fi
40286    rm -rf version-script.map main.c a.out
40287  fi
40288
40289
40290
40291# Setup the JTReg Regression Test Harness.
40292
40293
40294# Check whether --with-jtreg was given.
40295if test "${with_jtreg+set}" = set; then :
40296  withval=$with_jtreg;
40297else
40298  with_jtreg=no
40299fi
40300
40301
40302  if test "x$with_jtreg" = xno; then
40303    # jtreg disabled
40304    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40305$as_echo_n "checking for jtreg... " >&6; }
40306    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40307$as_echo "no" >&6; }
40308  else
40309    if test "x$with_jtreg" != xyes; then
40310      # with path specified.
40311      JT_HOME="$with_jtreg"
40312    fi
40313
40314    if test "x$JT_HOME" != x; then
40315      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40316$as_echo_n "checking for jtreg... " >&6; }
40317
40318      # use JT_HOME enviroment var.
40319
40320  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40321
40322  # Input might be given as Windows format, start by converting to
40323  # unix format.
40324  path="$JT_HOME"
40325  new_path=`$CYGPATH -u "$path"`
40326
40327  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40328  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40329  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40330  # "foo.exe" is OK but "foo" is an error.
40331  #
40332  # This test is therefore slightly more accurate than "test -f" to check for file precense.
40333  # It is also a way to make sure we got the proper file name for the real test later on.
40334  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40335  if test "x$test_shortpath" = x; then
40336    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40337$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40338    as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
40339  fi
40340
40341  # Call helper function which possibly converts this using DOS-style short mode.
40342  # If so, the updated path is stored in $new_path.
40343
40344  input_path="$new_path"
40345  # Check if we need to convert this using DOS-style short mode. If the path
40346  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40347  # take no chances and rewrite it.
40348  # Note: m4 eats our [], so we need to use [ and ] instead.
40349  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40350  if test "x$has_forbidden_chars" != x; then
40351    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40352    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40353    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40354    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40355      # Going to short mode and back again did indeed matter. Since short mode is
40356      # case insensitive, let's make it lowercase to improve readability.
40357      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40358      # Now convert it back to Unix-stile (cygpath)
40359      input_path=`$CYGPATH -u "$shortmode_path"`
40360      new_path="$input_path"
40361    fi
40362  fi
40363
40364  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40365  if test "x$test_cygdrive_prefix" = x; then
40366    # As a simple fix, exclude /usr/bin since it's not a real path.
40367    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
40368      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40369      # a path prefixed by /cygdrive for fixpath to work.
40370      new_path="$CYGWIN_ROOT_PATH$input_path"
40371    fi
40372  fi
40373
40374
40375  if test "x$path" != "x$new_path"; then
40376    JT_HOME="$new_path"
40377    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40378$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40379  fi
40380
40381  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40382
40383  path="$JT_HOME"
40384  has_colon=`$ECHO $path | $GREP ^.:`
40385  new_path="$path"
40386  if test "x$has_colon" = x; then
40387    # Not in mixed or Windows style, start by that.
40388    new_path=`cmd //c echo $path`
40389  fi
40390
40391
40392  input_path="$new_path"
40393  # Check if we need to convert this using DOS-style short mode. If the path
40394  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40395  # take no chances and rewrite it.
40396  # Note: m4 eats our [], so we need to use [ and ] instead.
40397  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40398  if test "x$has_forbidden_chars" != x; then
40399    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40400    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40401  fi
40402
40403
40404  windows_path="$new_path"
40405  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40406    unix_path=`$CYGPATH -u "$windows_path"`
40407    new_path="$unix_path"
40408  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40409    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40410    new_path="$unix_path"
40411  fi
40412
40413  if test "x$path" != "x$new_path"; then
40414    JT_HOME="$new_path"
40415    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40416$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40417  fi
40418
40419  # Save the first 10 bytes of this path to the storage, so fixpath can work.
40420  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40421
40422  else
40423    # We're on a posix platform. Hooray! :)
40424    path="$JT_HOME"
40425    has_space=`$ECHO "$path" | $GREP " "`
40426    if test "x$has_space" != x; then
40427      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40428$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40429      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
40430    fi
40431
40432    # Use eval to expand a potential ~
40433    eval path="$path"
40434    if test ! -f "$path" && test ! -d "$path"; then
40435      as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
40436    fi
40437
40438    JT_HOME="`cd "$path"; $THEPWDCMD -L`"
40439  fi
40440
40441
40442      # jtreg win32 script works for everybody
40443      JTREGEXE="$JT_HOME/win32/bin/jtreg"
40444
40445      if test ! -f "$JTREGEXE"; then
40446        as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
40447      fi
40448
40449      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40450$as_echo "$JTREGEXE" >&6; }
40451    else
40452      # try to find jtreg on path
40453
40454
40455
40456  # Publish this variable in the help.
40457
40458
40459  if test "x$JTREGEXE" = x; then
40460    # The variable is not set by user, try to locate tool using the code snippet
40461    for ac_prog in jtreg
40462do
40463  # Extract the first word of "$ac_prog", so it can be a program name with args.
40464set dummy $ac_prog; ac_word=$2
40465{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40466$as_echo_n "checking for $ac_word... " >&6; }
40467if ${ac_cv_path_JTREGEXE+:} false; then :
40468  $as_echo_n "(cached) " >&6
40469else
40470  case $JTREGEXE in
40471  [\\/]* | ?:[\\/]*)
40472  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40473  ;;
40474  *)
40475  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40476for as_dir in $PATH
40477do
40478  IFS=$as_save_IFS
40479  test -z "$as_dir" && as_dir=.
40480    for ac_exec_ext in '' $ac_executable_extensions; do
40481  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40482    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40483    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40484    break 2
40485  fi
40486done
40487  done
40488IFS=$as_save_IFS
40489
40490  ;;
40491esac
40492fi
40493JTREGEXE=$ac_cv_path_JTREGEXE
40494if test -n "$JTREGEXE"; then
40495  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40496$as_echo "$JTREGEXE" >&6; }
40497else
40498  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40499$as_echo "no" >&6; }
40500fi
40501
40502
40503  test -n "$JTREGEXE" && break
40504done
40505
40506  else
40507    # The variable is set, but is it from the command line or the environment?
40508
40509    # Try to remove the string !JTREGEXE! from our list.
40510    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
40511    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40512      # If it failed, the variable was not from the command line. Ignore it,
40513      # but warn the user (except for BASH, which is always set by the calling BASH).
40514      if test "xJTREGEXE" != xBASH; then
40515        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
40516$as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
40517      fi
40518      # Try to locate tool using the code snippet
40519      for ac_prog in jtreg
40520do
40521  # Extract the first word of "$ac_prog", so it can be a program name with args.
40522set dummy $ac_prog; ac_word=$2
40523{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40524$as_echo_n "checking for $ac_word... " >&6; }
40525if ${ac_cv_path_JTREGEXE+:} false; then :
40526  $as_echo_n "(cached) " >&6
40527else
40528  case $JTREGEXE in
40529  [\\/]* | ?:[\\/]*)
40530  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40531  ;;
40532  *)
40533  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40534for as_dir in $PATH
40535do
40536  IFS=$as_save_IFS
40537  test -z "$as_dir" && as_dir=.
40538    for ac_exec_ext in '' $ac_executable_extensions; do
40539  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40540    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40541    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40542    break 2
40543  fi
40544done
40545  done
40546IFS=$as_save_IFS
40547
40548  ;;
40549esac
40550fi
40551JTREGEXE=$ac_cv_path_JTREGEXE
40552if test -n "$JTREGEXE"; then
40553  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40554$as_echo "$JTREGEXE" >&6; }
40555else
40556  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40557$as_echo "no" >&6; }
40558fi
40559
40560
40561  test -n "$JTREGEXE" && break
40562done
40563
40564    else
40565      # If it succeeded, then it was overridden by the user. We will use it
40566      # for the tool.
40567
40568      # First remove it from the list of overridden variables, so we can test
40569      # for unknown variables in the end.
40570      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40571
40572      # Check if the provided tool contains a complete path.
40573      tool_specified="$JTREGEXE"
40574      tool_basename="${tool_specified##*/}"
40575      if test "x$tool_basename" = "x$tool_specified"; then
40576        # A command without a complete path is provided, search $PATH.
40577        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
40578$as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
40579        # Extract the first word of "$tool_basename", so it can be a program name with args.
40580set dummy $tool_basename; ac_word=$2
40581{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40582$as_echo_n "checking for $ac_word... " >&6; }
40583if ${ac_cv_path_JTREGEXE+:} false; then :
40584  $as_echo_n "(cached) " >&6
40585else
40586  case $JTREGEXE in
40587  [\\/]* | ?:[\\/]*)
40588  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40589  ;;
40590  *)
40591  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40592for as_dir in $PATH
40593do
40594  IFS=$as_save_IFS
40595  test -z "$as_dir" && as_dir=.
40596    for ac_exec_ext in '' $ac_executable_extensions; do
40597  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40598    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40599    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40600    break 2
40601  fi
40602done
40603  done
40604IFS=$as_save_IFS
40605
40606  ;;
40607esac
40608fi
40609JTREGEXE=$ac_cv_path_JTREGEXE
40610if test -n "$JTREGEXE"; then
40611  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40612$as_echo "$JTREGEXE" >&6; }
40613else
40614  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40615$as_echo "no" >&6; }
40616fi
40617
40618
40619        if test "x$JTREGEXE" = x; then
40620          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40621        fi
40622      else
40623        # Otherwise we believe it is a complete path. Use it as it is.
40624        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
40625$as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
40626        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
40627$as_echo_n "checking for JTREGEXE... " >&6; }
40628        if test ! -x "$tool_specified"; then
40629          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40630$as_echo "not found" >&6; }
40631          as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
40632        fi
40633        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40634$as_echo "$tool_specified" >&6; }
40635      fi
40636    fi
40637  fi
40638
40639
40640
40641  if test "x$JTREGEXE" = x; then
40642    as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
40643  fi
40644
40645
40646      JT_HOME="`$DIRNAME $JTREGEXE`"
40647    fi
40648  fi
40649
40650
40651
40652
40653
40654
40655  # Option used to tell the compiler whether to create 32- or 64-bit executables
40656  if test "x$TOOLCHAIN_TYPE" = xxlc; then
40657    COMPILER_TARGET_BITS_FLAG="-q"
40658  else
40659    COMPILER_TARGET_BITS_FLAG="-m"
40660  fi
40661
40662
40663  # FIXME: figure out if we should select AR flags depending on OS or toolchain.
40664  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
40665    ARFLAGS="-r"
40666  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40667    ARFLAGS="-X64"
40668  elif test "x$OPENJDK_TARGET_OS" = xwindows; then
40669    # lib.exe is used as AR to create static libraries.
40670    ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
40671  else
40672    ARFLAGS=""
40673  fi
40674
40675
40676  ## Setup strip.
40677  # FIXME: should this really be per platform, or should it be per toolchain type?
40678  # strip is not provided by clang or solstudio; so guessing platform makes most sense.
40679  # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD.
40680  if test "x$OPENJDK_TARGET_OS" = xlinux; then
40681    STRIPFLAGS="-g"
40682  elif test "x$OPENJDK_TARGET_OS" = xsolaris; then
40683    STRIPFLAGS="-x"
40684  elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
40685    STRIPFLAGS="-S"
40686  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40687    STRIPFLAGS="-X32_64"
40688  fi
40689
40690  if test "x$OPENJDK_TARGET_OS" != xwindows; then
40691    POST_STRIP_CMD="$STRIP $STRIPFLAGS"
40692  fi
40693
40694
40695  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40696    # FIXME: break out into MCSFLAGS
40697    POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
40698  fi
40699
40700
40701  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40702    CC_OUT_OPTION=-Fo
40703    EXE_OUT_OPTION=-out:
40704    LD_OUT_OPTION=-out:
40705    AR_OUT_OPTION=-out:
40706  else
40707    # The option used to specify the target .o,.a or .so file.
40708    # When compiling, how to specify the to be created object file.
40709    CC_OUT_OPTION='-o$(SPACE)'
40710    # When linking, how to specify the to be created executable.
40711    EXE_OUT_OPTION='-o$(SPACE)'
40712    # When linking, how to specify the to be created dynamically linkable library.
40713    LD_OUT_OPTION='-o$(SPACE)'
40714    # When archiving, how to specify the to be create static archive for object files.
40715    AR_OUT_OPTION='rcs$(SPACE)'
40716  fi
40717
40718
40719
40720
40721
40722  # On Windows, we need to set RC flags.
40723  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40724    RC_FLAGS="-nologo -l 0x409 -r"
40725    if test "x$VARIANT" = xOPT; then
40726      RC_FLAGS="$RC_FLAGS -d NDEBUG"
40727    fi
40728
40729    # The version variables used to create RC_FLAGS may be overridden
40730    # in a custom configure script, or possibly the command line.
40731    # Let those variables be expanded at make time in spec.gmk.
40732    # The \$ are escaped to the shell, and the $(...) variables
40733    # are evaluated by make.
40734    RC_FLAGS="$RC_FLAGS \
40735        -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40736        -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40737        -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40738        -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40739        -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40740        -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40741        -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40742  fi
40743
40744
40745  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40746    # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40747    CCXXFLAGS="$CCXXFLAGS -nologo"
40748  fi
40749
40750  if test "x$SYSROOT" != "x"; then
40751    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
40752      if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40753        # Solaris Studio does not have a concept of sysroot. Instead we must
40754        # make sure the default include and lib dirs are appended to each
40755        # compile and link command line.
40756        SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
40757        SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
40758            -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
40759            -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
40760      fi
40761    elif test "x$TOOLCHAIN_TYPE" = xgcc; then
40762      SYSROOT_CFLAGS="--sysroot=\"$SYSROOT\""
40763      SYSROOT_LDFLAGS="--sysroot=\"$SYSROOT\""
40764    elif test "x$TOOLCHAIN_TYPE" = xclang; then
40765      SYSROOT_CFLAGS="-isysroot \"$SYSROOT\""
40766      SYSROOT_LDFLAGS="-isysroot \"$SYSROOT\""
40767    fi
40768    # Propagate the sysroot args to hotspot
40769    LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
40770    LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
40771    LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
40772  fi
40773
40774
40775
40776
40777# FIXME: Currently we must test this after toolchain but before flags. Fix!
40778
40779# Now we can test some aspects on the target using configure macros.
40780
40781
40782{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40783$as_echo_n "checking for ANSI C header files... " >&6; }
40784if ${ac_cv_header_stdc+:} false; then :
40785  $as_echo_n "(cached) " >&6
40786else
40787  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40788/* end confdefs.h.  */
40789#include <stdlib.h>
40790#include <stdarg.h>
40791#include <string.h>
40792#include <float.h>
40793
40794int
40795main ()
40796{
40797
40798  ;
40799  return 0;
40800}
40801_ACEOF
40802if ac_fn_cxx_try_compile "$LINENO"; then :
40803  ac_cv_header_stdc=yes
40804else
40805  ac_cv_header_stdc=no
40806fi
40807rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40808
40809if test $ac_cv_header_stdc = yes; then
40810  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
40811  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40812/* end confdefs.h.  */
40813#include <string.h>
40814
40815_ACEOF
40816if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40817  $EGREP "memchr" >/dev/null 2>&1; then :
40818
40819else
40820  ac_cv_header_stdc=no
40821fi
40822rm -f conftest*
40823
40824fi
40825
40826if test $ac_cv_header_stdc = yes; then
40827  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
40828  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40829/* end confdefs.h.  */
40830#include <stdlib.h>
40831
40832_ACEOF
40833if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40834  $EGREP "free" >/dev/null 2>&1; then :
40835
40836else
40837  ac_cv_header_stdc=no
40838fi
40839rm -f conftest*
40840
40841fi
40842
40843if test $ac_cv_header_stdc = yes; then
40844  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
40845  if test "$cross_compiling" = yes; then :
40846  :
40847else
40848  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40849/* end confdefs.h.  */
40850#include <ctype.h>
40851#include <stdlib.h>
40852#if ((' ' & 0x0FF) == 0x020)
40853# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
40854# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
40855#else
40856# define ISLOWER(c) \
40857		   (('a' <= (c) && (c) <= 'i') \
40858		     || ('j' <= (c) && (c) <= 'r') \
40859		     || ('s' <= (c) && (c) <= 'z'))
40860# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
40861#endif
40862
40863#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
40864int
40865main ()
40866{
40867  int i;
40868  for (i = 0; i < 256; i++)
40869    if (XOR (islower (i), ISLOWER (i))
40870	|| toupper (i) != TOUPPER (i))
40871      return 2;
40872  return 0;
40873}
40874_ACEOF
40875if ac_fn_cxx_try_run "$LINENO"; then :
40876
40877else
40878  ac_cv_header_stdc=no
40879fi
40880rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40881  conftest.$ac_objext conftest.beam conftest.$ac_ext
40882fi
40883
40884fi
40885fi
40886{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
40887$as_echo "$ac_cv_header_stdc" >&6; }
40888if test $ac_cv_header_stdc = yes; then
40889
40890$as_echo "#define STDC_HEADERS 1" >>confdefs.h
40891
40892fi
40893
40894# On IRIX 5.3, sys/types and inttypes.h are conflicting.
40895for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
40896		  inttypes.h stdint.h unistd.h
40897do :
40898  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
40899ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
40900"
40901if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
40902  cat >>confdefs.h <<_ACEOF
40903#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
40904_ACEOF
40905
40906fi
40907
40908done
40909
40910
40911
40912  ###############################################################################
40913  #
40914  # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
40915  # (The JVM can use 32 or 64 bit Java pointers but that decision
40916  # is made at runtime.)
40917  #
40918
40919  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
40920    # Always specify -m flag on Solaris
40921    # And -q on AIX because otherwise the compiler produces 32-bit objects by default
40922
40923  # When we add flags to the "official" CFLAGS etc, we need to
40924  # keep track of these additions in ADDED_CFLAGS etc. These
40925  # will later be checked to make sure only controlled additions
40926  # have been made to CFLAGS etc.
40927  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40928  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40929  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40930
40931  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40932  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40933  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40934
40935  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40936  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40937  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40938
40939  elif test "x$COMPILE_TYPE" = xreduced; then
40940    if test "x$OPENJDK_TARGET_OS" != xwindows; then
40941      # Specify -m if running reduced on other Posix platforms
40942
40943  # When we add flags to the "official" CFLAGS etc, we need to
40944  # keep track of these additions in ADDED_CFLAGS etc. These
40945  # will later be checked to make sure only controlled additions
40946  # have been made to CFLAGS etc.
40947  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40948  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40949  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40950
40951  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40952  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40953  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40954
40955  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40956  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40957  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40958
40959    fi
40960  fi
40961
40962  # Make compilation sanity check
40963  for ac_header in stdio.h
40964do :
40965  ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
40966if test "x$ac_cv_header_stdio_h" = xyes; then :
40967  cat >>confdefs.h <<_ACEOF
40968#define HAVE_STDIO_H 1
40969_ACEOF
40970
40971else
40972
40973    { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
40974$as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
40975    if test "x$COMPILE_TYPE" = xreduced; then
40976      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
40977$as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
40978    elif test "x$COMPILE_TYPE" = xcross; then
40979      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
40980$as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
40981    fi
40982    as_fn_error $? "Cannot continue." "$LINENO" 5
40983
40984fi
40985
40986done
40987
40988
40989  # The cast to long int works around a bug in the HP C Compiler
40990# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40991# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40992# This bug is HP SR number 8606223364.
40993{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40994$as_echo_n "checking size of int *... " >&6; }
40995if ${ac_cv_sizeof_int_p+:} false; then :
40996  $as_echo_n "(cached) " >&6
40997else
40998  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40999
41000else
41001  if test "$ac_cv_type_int_p" = yes; then
41002     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
41003$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
41004as_fn_error 77 "cannot compute sizeof (int *)
41005See \`config.log' for more details" "$LINENO" 5; }
41006   else
41007     ac_cv_sizeof_int_p=0
41008   fi
41009fi
41010
41011fi
41012{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
41013$as_echo "$ac_cv_sizeof_int_p" >&6; }
41014
41015
41016
41017cat >>confdefs.h <<_ACEOF
41018#define SIZEOF_INT_P $ac_cv_sizeof_int_p
41019_ACEOF
41020
41021
41022
41023  # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
41024  if test "x$ac_cv_sizeof_int_p" = x; then
41025    # The test failed, lets stick to the assumed value.
41026    { $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
41027$as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
41028  else
41029    TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
41030
41031    if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
41032      # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
41033      # Let's try to implicitely set the compilers target architecture and retry the test
41034      { $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
41035$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;}
41036      { $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
41037$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;}
41038
41039  # When we add flags to the "official" CFLAGS etc, we need to
41040  # keep track of these additions in ADDED_CFLAGS etc. These
41041  # will later be checked to make sure only controlled additions
41042  # have been made to CFLAGS etc.
41043  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41044  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41045  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41046
41047  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41048  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41049  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41050
41051  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41052  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41053  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41054
41055
41056      # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
41057      unset ac_cv_sizeof_int_p
41058      # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
41059      cat >>confdefs.h <<_ACEOF
41060#undef SIZEOF_INT_P
41061_ACEOF
41062
41063      # The cast to long int works around a bug in the HP C Compiler
41064# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
41065# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
41066# This bug is HP SR number 8606223364.
41067{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
41068$as_echo_n "checking size of int *... " >&6; }
41069if ${ac_cv_sizeof_int_p+:} false; then :
41070  $as_echo_n "(cached) " >&6
41071else
41072  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
41073
41074else
41075  if test "$ac_cv_type_int_p" = yes; then
41076     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
41077$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
41078as_fn_error 77 "cannot compute sizeof (int *)
41079See \`config.log' for more details" "$LINENO" 5; }
41080   else
41081     ac_cv_sizeof_int_p=0
41082   fi
41083fi
41084
41085fi
41086{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
41087$as_echo "$ac_cv_sizeof_int_p" >&6; }
41088
41089
41090
41091cat >>confdefs.h <<_ACEOF
41092#define SIZEOF_INT_P $ac_cv_sizeof_int_p
41093_ACEOF
41094
41095
41096
41097      TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
41098
41099      if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
41100        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
41101      fi
41102    fi
41103  fi
41104
41105  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
41106$as_echo_n "checking for target address size... " >&6; }
41107  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
41108$as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
41109
41110
41111  ###############################################################################
41112  #
41113  # Is the target little of big endian?
41114  #
41115   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
41116$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
41117if ${ac_cv_c_bigendian+:} false; then :
41118  $as_echo_n "(cached) " >&6
41119else
41120  ac_cv_c_bigendian=unknown
41121    # See if we're dealing with a universal compiler.
41122    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41123/* end confdefs.h.  */
41124#ifndef __APPLE_CC__
41125	       not a universal capable compiler
41126	     #endif
41127	     typedef int dummy;
41128
41129_ACEOF
41130if ac_fn_cxx_try_compile "$LINENO"; then :
41131
41132	# Check for potential -arch flags.  It is not universal unless
41133	# there are at least two -arch flags with different values.
41134	ac_arch=
41135	ac_prev=
41136	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
41137	 if test -n "$ac_prev"; then
41138	   case $ac_word in
41139	     i?86 | x86_64 | ppc | ppc64)
41140	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
41141		 ac_arch=$ac_word
41142	       else
41143		 ac_cv_c_bigendian=universal
41144		 break
41145	       fi
41146	       ;;
41147	   esac
41148	   ac_prev=
41149	 elif test "x$ac_word" = "x-arch"; then
41150	   ac_prev=arch
41151	 fi
41152       done
41153fi
41154rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41155    if test $ac_cv_c_bigendian = unknown; then
41156      # See if sys/param.h defines the BYTE_ORDER macro.
41157      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41158/* end confdefs.h.  */
41159#include <sys/types.h>
41160	     #include <sys/param.h>
41161
41162int
41163main ()
41164{
41165#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
41166		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
41167		     && LITTLE_ENDIAN)
41168	      bogus endian macros
41169	     #endif
41170
41171  ;
41172  return 0;
41173}
41174_ACEOF
41175if ac_fn_cxx_try_compile "$LINENO"; then :
41176  # It does; now see whether it defined to BIG_ENDIAN or not.
41177	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41178/* end confdefs.h.  */
41179#include <sys/types.h>
41180		#include <sys/param.h>
41181
41182int
41183main ()
41184{
41185#if BYTE_ORDER != BIG_ENDIAN
41186		 not big endian
41187		#endif
41188
41189  ;
41190  return 0;
41191}
41192_ACEOF
41193if ac_fn_cxx_try_compile "$LINENO"; then :
41194  ac_cv_c_bigendian=yes
41195else
41196  ac_cv_c_bigendian=no
41197fi
41198rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41199fi
41200rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41201    fi
41202    if test $ac_cv_c_bigendian = unknown; then
41203      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
41204      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41205/* end confdefs.h.  */
41206#include <limits.h>
41207
41208int
41209main ()
41210{
41211#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
41212	      bogus endian macros
41213	     #endif
41214
41215  ;
41216  return 0;
41217}
41218_ACEOF
41219if ac_fn_cxx_try_compile "$LINENO"; then :
41220  # It does; now see whether it defined to _BIG_ENDIAN or not.
41221	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41222/* end confdefs.h.  */
41223#include <limits.h>
41224
41225int
41226main ()
41227{
41228#ifndef _BIG_ENDIAN
41229		 not big endian
41230		#endif
41231
41232  ;
41233  return 0;
41234}
41235_ACEOF
41236if ac_fn_cxx_try_compile "$LINENO"; then :
41237  ac_cv_c_bigendian=yes
41238else
41239  ac_cv_c_bigendian=no
41240fi
41241rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41242fi
41243rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41244    fi
41245    if test $ac_cv_c_bigendian = unknown; then
41246      # Compile a test program.
41247      if test "$cross_compiling" = yes; then :
41248  # Try to guess by grepping values from an object file.
41249	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41250/* end confdefs.h.  */
41251short int ascii_mm[] =
41252		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
41253		short int ascii_ii[] =
41254		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
41255		int use_ascii (int i) {
41256		  return ascii_mm[i] + ascii_ii[i];
41257		}
41258		short int ebcdic_ii[] =
41259		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
41260		short int ebcdic_mm[] =
41261		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
41262		int use_ebcdic (int i) {
41263		  return ebcdic_mm[i] + ebcdic_ii[i];
41264		}
41265		extern int foo;
41266
41267int
41268main ()
41269{
41270return use_ascii (foo) == use_ebcdic (foo);
41271  ;
41272  return 0;
41273}
41274_ACEOF
41275if ac_fn_cxx_try_compile "$LINENO"; then :
41276  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
41277	      ac_cv_c_bigendian=yes
41278	    fi
41279	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
41280	      if test "$ac_cv_c_bigendian" = unknown; then
41281		ac_cv_c_bigendian=no
41282	      else
41283		# finding both strings is unlikely to happen, but who knows?
41284		ac_cv_c_bigendian=unknown
41285	      fi
41286	    fi
41287fi
41288rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41289else
41290  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41291/* end confdefs.h.  */
41292$ac_includes_default
41293int
41294main ()
41295{
41296
41297	     /* Are we little or big endian?  From Harbison&Steele.  */
41298	     union
41299	     {
41300	       long int l;
41301	       char c[sizeof (long int)];
41302	     } u;
41303	     u.l = 1;
41304	     return u.c[sizeof (long int) - 1] == 1;
41305
41306  ;
41307  return 0;
41308}
41309_ACEOF
41310if ac_fn_cxx_try_run "$LINENO"; then :
41311  ac_cv_c_bigendian=no
41312else
41313  ac_cv_c_bigendian=yes
41314fi
41315rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41316  conftest.$ac_objext conftest.beam conftest.$ac_ext
41317fi
41318
41319    fi
41320fi
41321{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
41322$as_echo "$ac_cv_c_bigendian" >&6; }
41323 case $ac_cv_c_bigendian in #(
41324   yes)
41325     ENDIAN="big";; #(
41326   no)
41327     ENDIAN="little" ;; #(
41328   universal)
41329     ENDIAN="universal_endianness"
41330     ;; #(
41331   *)
41332     ENDIAN="unknown" ;;
41333 esac
41334
41335
41336  if test "x$ENDIAN" = xuniversal_endianness; then
41337    as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
41338  fi
41339  if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
41340    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
41341  fi
41342
41343
41344# Configure flags for the tools
41345
41346  ###############################################################################
41347  #
41348  # How to compile shared libraries.
41349  #
41350
41351  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41352    PICFLAG="-fPIC"
41353    C_FLAG_REORDER=''
41354    CXX_FLAG_REORDER=''
41355
41356    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41357      # Linking is different on MacOSX
41358      SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41359      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41360      SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41361      SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41362      SET_SHARED_LIBRARY_MAPFILE=''
41363    else
41364      # Default works for linux, might work on other platforms as well.
41365      SHARED_LIBRARY_FLAGS='-shared'
41366      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41367      SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41368      SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41369      SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41370    fi
41371  elif test "x$TOOLCHAIN_TYPE" = xclang; then
41372    PICFLAG=''
41373    C_FLAG_REORDER=''
41374    CXX_FLAG_REORDER=''
41375
41376    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41377      # Linking is different on MacOSX
41378      SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41379      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41380      SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41381      SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41382      SET_SHARED_LIBRARY_MAPFILE=''
41383    else
41384      # Default works for linux, might work on other platforms as well.
41385      SHARED_LIBRARY_FLAGS='-shared'
41386      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41387      SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41388      SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41389      SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41390    fi
41391  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41392    PICFLAG="-KPIC"
41393    C_FLAG_REORDER='-xF'
41394    CXX_FLAG_REORDER='-xF'
41395    SHARED_LIBRARY_FLAGS="-G"
41396    SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1'
41397    SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41398    SET_SHARED_LIBRARY_NAME=''
41399    SET_SHARED_LIBRARY_MAPFILE='-M$1'
41400  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41401    PICFLAG="-qpic=large"
41402    C_FLAG_REORDER=''
41403    CXX_FLAG_REORDER=''
41404    SHARED_LIBRARY_FLAGS="-qmkshrobj"
41405    SET_EXECUTABLE_ORIGIN=""
41406    SET_SHARED_LIBRARY_ORIGIN=''
41407    SET_SHARED_LIBRARY_NAME=''
41408    SET_SHARED_LIBRARY_MAPFILE=''
41409  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41410    PICFLAG=""
41411    C_FLAG_REORDER=''
41412    CXX_FLAG_REORDER=''
41413    SHARED_LIBRARY_FLAGS="-LD"
41414    SET_EXECUTABLE_ORIGIN=''
41415    SET_SHARED_LIBRARY_ORIGIN=''
41416    SET_SHARED_LIBRARY_NAME=''
41417    SET_SHARED_LIBRARY_MAPFILE=''
41418  fi
41419
41420
41421
41422
41423
41424
41425
41426
41427
41428  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41429    CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
41430    CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
41431    CFLAGS_JDKLIB_EXTRA='-xstrconst'
41432  fi
41433  # The (cross) compiler is now configured, we can now test capabilities
41434  # of the target platform.
41435
41436
41437
41438  ###############################################################################
41439  #
41440  # Setup the opt flags for different compilers
41441  # and different operating systems.
41442  #
41443
41444  # FIXME: this was indirectly the old default, but just inherited.
41445  # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41446  #   C_FLAG_DEPS="-MMD -MF"
41447  # fi
41448
41449  # Generate make dependency files
41450  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41451    C_FLAG_DEPS="-MMD -MF"
41452  elif test "x$TOOLCHAIN_TYPE" = xclang; then
41453    C_FLAG_DEPS="-MMD -MF"
41454  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41455    C_FLAG_DEPS="-xMMD -xMF"
41456  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41457    C_FLAG_DEPS="-qmakedep=gcc -MF"
41458  fi
41459  CXX_FLAG_DEPS="$C_FLAG_DEPS"
41460
41461
41462
41463  # Debug symbols
41464  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41465    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
41466      CFLAGS_DEBUG_SYMBOLS="-g1"
41467      CXXFLAGS_DEBUG_SYMBOLS="-g1"
41468    else
41469      CFLAGS_DEBUG_SYMBOLS="-g"
41470      CXXFLAGS_DEBUG_SYMBOLS="-g"
41471    fi
41472  elif test "x$TOOLCHAIN_TYPE" = xclang; then
41473    CFLAGS_DEBUG_SYMBOLS="-g"
41474    CXXFLAGS_DEBUG_SYMBOLS="-g"
41475  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41476    CFLAGS_DEBUG_SYMBOLS="-g -xs"
41477    CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
41478  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41479    CFLAGS_DEBUG_SYMBOLS="-g"
41480    CXXFLAGS_DEBUG_SYMBOLS="-g"
41481  fi
41482
41483
41484
41485  # Optimization levels
41486  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41487    CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil"
41488
41489    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
41490      # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global?
41491      C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr"
41492      C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
41493      C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
41494      C_O_FLAG_NONE="-xregs=no%frameptr"
41495      CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
41496      CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
41497      CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
41498      CXX_O_FLAG_NONE="-xregs=no%frameptr"
41499      if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41500        C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
41501        CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
41502      fi
41503    elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41504      C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra"
41505      C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41506      C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41507      C_O_FLAG_NONE=""
41508      CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41509      CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41510      CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41511      CXX_O_FLAG_NONE=""
41512    fi
41513  else
41514    # The remaining toolchains share opt flags between CC and CXX;
41515    # setup for C and duplicate afterwards.
41516    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41517      if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41518        # On MacOSX we optimize for size, something
41519        # we should do for all platforms?
41520        C_O_FLAG_HIGHEST="-Os"
41521        C_O_FLAG_HI="-Os"
41522        C_O_FLAG_NORM="-Os"
41523        C_O_FLAG_NONE=""
41524      else
41525        C_O_FLAG_HIGHEST="-O3"
41526        C_O_FLAG_HI="-O3"
41527        C_O_FLAG_NORM="-O2"
41528        C_O_FLAG_NONE="-O0"
41529      fi
41530    elif test "x$TOOLCHAIN_TYPE" = xclang; then
41531      if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41532        # On MacOSX we optimize for size, something
41533        # we should do for all platforms?
41534        C_O_FLAG_HIGHEST="-Os"
41535        C_O_FLAG_HI="-Os"
41536        C_O_FLAG_NORM="-Os"
41537        C_O_FLAG_NONE=""
41538      else
41539        C_O_FLAG_HIGHEST="-O3"
41540        C_O_FLAG_HI="-O3"
41541        C_O_FLAG_NORM="-O2"
41542        C_O_FLAG_NONE="-O0"
41543      fi
41544    elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41545      C_O_FLAG_HIGHEST="-O3"
41546      C_O_FLAG_HI="-O3 -qstrict"
41547      C_O_FLAG_NORM="-O2"
41548      C_O_FLAG_NONE=""
41549    elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41550      C_O_FLAG_HIGHEST="-O2"
41551      C_O_FLAG_HI="-O1"
41552      C_O_FLAG_NORM="-O1"
41553      C_O_FLAG_NONE="-Od"
41554    fi
41555    CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
41556    CXX_O_FLAG_HI="$C_O_FLAG_HI"
41557    CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41558    CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41559  fi
41560
41561
41562
41563
41564
41565
41566
41567
41568
41569
41570
41571  # Special extras...
41572  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41573    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41574      CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41575      CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41576    fi
41577  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41578    LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
41579    CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41580    CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41581  fi
41582
41583  if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
41584    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
41585$as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
41586  fi
41587
41588  if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
41589    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
41590$as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
41591  fi
41592
41593  if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
41594    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
41595$as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
41596  fi
41597
41598
41599# Check whether --with-extra-cflags was given.
41600if test "${with_extra_cflags+set}" = set; then :
41601  withval=$with_extra_cflags;
41602fi
41603
41604
41605
41606# Check whether --with-extra-cxxflags was given.
41607if test "${with_extra_cxxflags+set}" = set; then :
41608  withval=$with_extra_cxxflags;
41609fi
41610
41611
41612
41613# Check whether --with-extra-ldflags was given.
41614if test "${with_extra_ldflags+set}" = set; then :
41615  withval=$with_extra_ldflags;
41616fi
41617
41618
41619  CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41620  CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41621  LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41622
41623  # Hotspot needs these set in their legacy form
41624  LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $with_extra_cflags"
41625  LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $with_extra_cxxflags"
41626  LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $with_extra_ldflags"
41627
41628
41629
41630
41631
41632  ###############################################################################
41633  #
41634  # Now setup the CFLAGS and LDFLAGS for the JDK build.
41635  # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41636  #
41637
41638  # Setup compiler/platform specific flags to CFLAGS_JDK,
41639  # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41640  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41641    # these options are used for both C and C++ compiles
41642    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41643        -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41644    case $OPENJDK_TARGET_CPU_ARCH in
41645      arm )
41646        # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
41647        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41648        ;;
41649      ppc )
41650        # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing
41651        ;;
41652      * )
41653        CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer"
41654        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41655        ;;
41656    esac
41657  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41658    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
41659    if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
41660      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
41661      CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
41662    fi
41663
41664    CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
41665    CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
41666  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41667    CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41668    CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41669  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41670    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
41671    -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
41672    -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
41673    -DWIN32 -DIAL"
41674    if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
41675      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64"
41676    else
41677      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86"
41678    fi
41679  fi
41680
41681  ###############################################################################
41682
41683  # Adjust flags according to debug level.
41684  case $DEBUG_LEVEL in
41685    fastdebug )
41686      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41687      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41688      C_O_FLAG_HI="$C_O_FLAG_NORM"
41689      C_O_FLAG_NORM="$C_O_FLAG_NORM"
41690      CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
41691      CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM"
41692      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41693      ;;
41694    slowdebug )
41695      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41696      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41697      C_O_FLAG_HI="$C_O_FLAG_NONE"
41698      C_O_FLAG_NORM="$C_O_FLAG_NONE"
41699      CXX_O_FLAG_HI="$CXX_O_FLAG_NONE"
41700      CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE"
41701      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41702      ;;
41703  esac
41704
41705  # Setup LP64
41706  CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41707
41708  # Set some common defines. These works for all compilers, but assume
41709  # -D is universally accepted.
41710
41711  # Setup endianness
41712  if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41713    # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41714    #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41715    #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41716    #   Note: -Dmacro         is the same as    #define macro 1
41717    #         -Dmacro=        is the same as    #define macro
41718    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41719      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41720    else
41721      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41722    fi
41723  else
41724    # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they
41725    # are defined in the system?
41726    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41727      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN="
41728    else
41729      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41730    fi
41731  fi
41732
41733  # Setup target OS define. Use OS target name but in upper case.
41734  OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41735  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41736
41737  # Setup target CPU
41738  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41739
41740  # Setup debug/release defines
41741  if test "x$DEBUG_LEVEL" = xrelease; then
41742    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41743    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41744      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41745    fi
41746  else
41747    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41748  fi
41749
41750  # Setup release name
41751  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
41752
41753
41754  # Set some additional per-OS defines.
41755  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41756    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
41757  elif test "x$OPENJDK_TARGET_OS" = xaix; then
41758    # FIXME: PPC64 should not be here.
41759    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DPPC64"
41760  elif test "x$OPENJDK_TARGET_OS" = xbsd; then
41761    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
41762  fi
41763
41764  # Additional macosx handling
41765  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41766    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41767      # FIXME: This needs to be exported in spec.gmk due to closed legacy code.
41768      # FIXME: clean this up, and/or move it elsewhere.
41769
41770      # Setting these parameters makes it an error to link to macosx APIs that are
41771      # newer than the given OS version and makes the linked binaries compatible
41772      # even if built on a newer version of the OS.
41773      # The expected format is X.Y.Z
41774      MACOSX_VERSION_MIN=10.7.0
41775
41776
41777      # The macro takes the version with no dots, ex: 1070
41778      # Let the flags variables get resolved in make for easier override on make
41779      # command line.
41780      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41781      LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41782    fi
41783  fi
41784
41785  # Setup some hard coded includes
41786  CCXXFLAGS_JDK="$CCXXFLAGS_JDK \
41787      -I${JDK_OUTPUTDIR}/include \
41788      -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \
41789      -I${JDK_TOPDIR}/src/share/javavm/export \
41790      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_EXPORT_DIR/javavm/export \
41791      -I${JDK_TOPDIR}/src/share/native/common \
41792      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common"
41793
41794  # The shared libraries are compiled using the picflag.
41795  CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
41796  CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
41797
41798  # Executable flags
41799  CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK"
41800  CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK"
41801
41802
41803
41804
41805
41806
41807  # Setup LDFLAGS et al.
41808  #
41809  # Now this is odd. The JDK native libraries have to link against libjvm.so
41810  # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
41811  # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
41812  # is identical for client and server? Yes. Which is picked at runtime (client or server)?
41813  # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
41814  # libraries will link to whatever is in memory. Yuck.
41815  #
41816  # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
41817  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41818    LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
41819    if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41820      LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
41821    fi
41822    # TODO: make -debug optional "--disable-full-debug-symbols"
41823    LDFLAGS_JDK="$LDFLAGS_JDK -debug"
41824    LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib"
41825    LDFLAGS_JDKLIB_SUFFIX=""
41826    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
41827      LDFLAGS_STACK_SIZE=1048576
41828    else
41829      LDFLAGS_STACK_SIZE=327680
41830    fi
41831    LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE"
41832  else
41833    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41834      # If this is a --hash-style=gnu system, use --hash-style=both, why?
41835      # We have previously set HAS_GNU_HASH if this is the case
41836      if test -n "$HAS_GNU_HASH"; then
41837        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both "
41838      fi
41839      if test "x$OPENJDK_TARGET_OS" = xlinux; then
41840        # And since we now know that the linker is gnu, then add -z defs, to forbid
41841        # undefined symbols in object files.
41842        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
41843        if test "x$DEBUG_LEVEL" = "xrelease"; then
41844          # When building release libraries, tell the linker optimize them.
41845          # Should this be supplied to the OSS linker as well?
41846          LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
41847        fi
41848      fi
41849    fi
41850
41851    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41852      LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
41853      LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
41854    fi
41855
41856    LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \
41857        -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
41858
41859    # On some platforms (mac) the linker warns about non existing -L dirs.
41860    # Add server first if available. Linking aginst client does not always produce the same results.
41861    # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
41862    # Default to server for other variants.
41863    if test "x$JVM_VARIANT_SERVER" = xtrue; then
41864      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41865    elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
41866      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
41867    elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
41868      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
41869    else
41870      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41871    fi
41872
41873    LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
41874    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41875      LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
41876    fi
41877
41878    LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
41879    if test "x$OPENJDK_TARGET_OS" = xlinux; then
41880      LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
41881    fi
41882  fi
41883
41884
41885
41886
41887
41888
41889
41890
41891  # Some Zero and Shark settings.
41892  # ZERO_ARCHFLAG tells the compiler which mode to build for
41893  case "${OPENJDK_TARGET_CPU}" in
41894    s390)
41895      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
41896      ;;
41897    *)
41898      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41899  esac
41900
41901  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
41902$as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
41903  supports=yes
41904
41905  saved_cflags="$CFLAGS"
41906  CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
41907  ac_ext=c
41908ac_cpp='$CPP $CPPFLAGS'
41909ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41910ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41911ac_compiler_gnu=$ac_cv_c_compiler_gnu
41912
41913  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41914/* end confdefs.h.  */
41915int i;
41916_ACEOF
41917if ac_fn_c_try_compile "$LINENO"; then :
41918
41919else
41920  supports=no
41921fi
41922rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41923  ac_ext=cpp
41924ac_cpp='$CXXCPP $CPPFLAGS'
41925ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41926ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41927ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41928
41929  CFLAGS="$saved_cflags"
41930
41931  saved_cxxflags="$CXXFLAGS"
41932  CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
41933  ac_ext=cpp
41934ac_cpp='$CXXCPP $CPPFLAGS'
41935ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41936ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41937ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41938
41939  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41940/* end confdefs.h.  */
41941int i;
41942_ACEOF
41943if ac_fn_cxx_try_compile "$LINENO"; then :
41944
41945else
41946  supports=no
41947fi
41948rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41949  ac_ext=cpp
41950ac_cpp='$CXXCPP $CPPFLAGS'
41951ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41952ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41953ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41954
41955  CXXFLAGS="$saved_cxxflags"
41956
41957  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41958$as_echo "$supports" >&6; }
41959  if test "x$supports" = "xyes" ; then
41960    :
41961  else
41962    ZERO_ARCHFLAG=""
41963  fi
41964
41965
41966
41967  # Check that the compiler supports -mX (or -qX on AIX) flags
41968  # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
41969
41970  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
41971$as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
41972  supports=yes
41973
41974  saved_cflags="$CFLAGS"
41975  CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41976  ac_ext=c
41977ac_cpp='$CPP $CPPFLAGS'
41978ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41979ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41980ac_compiler_gnu=$ac_cv_c_compiler_gnu
41981
41982  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41983/* end confdefs.h.  */
41984int i;
41985_ACEOF
41986if ac_fn_c_try_compile "$LINENO"; then :
41987
41988else
41989  supports=no
41990fi
41991rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41992  ac_ext=cpp
41993ac_cpp='$CXXCPP $CPPFLAGS'
41994ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41995ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41996ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41997
41998  CFLAGS="$saved_cflags"
41999
42000  saved_cxxflags="$CXXFLAGS"
42001  CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42002  ac_ext=cpp
42003ac_cpp='$CXXCPP $CPPFLAGS'
42004ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42005ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42006ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42007
42008  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42009/* end confdefs.h.  */
42010int i;
42011_ACEOF
42012if ac_fn_cxx_try_compile "$LINENO"; then :
42013
42014else
42015  supports=no
42016fi
42017rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42018  ac_ext=cpp
42019ac_cpp='$CXXCPP $CPPFLAGS'
42020ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42021ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42022ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42023
42024  CXXFLAGS="$saved_cxxflags"
42025
42026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
42027$as_echo "$supports" >&6; }
42028  if test "x$supports" = "xyes" ; then
42029    COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
42030  else
42031    COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
42032  fi
42033
42034
42035
42036  case "${TOOLCHAIN_TYPE}" in
42037    microsoft)
42038      CFLAGS_WARNINGS_ARE_ERRORS="/WX"
42039      ;;
42040    solstudio)
42041      CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all"
42042      ;;
42043    gcc)
42044      CFLAGS_WARNINGS_ARE_ERRORS="-Werror"
42045      ;;
42046    clang)
42047      CFLAGS_WARNINGS_ARE_ERRORS="-Werror"
42048      ;;
42049  esac
42050
42051
42052
42053# Setup debug symbols (need objcopy from the toolchain for that)
42054
42055  #
42056  # ENABLE_DEBUG_SYMBOLS
42057  # This must be done after the toolchain is setup, since we're looking at objcopy.
42058  #
42059  # Check whether --enable-debug-symbols was given.
42060if test "${enable_debug_symbols+set}" = set; then :
42061  enableval=$enable_debug_symbols;
42062fi
42063
42064
42065  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
42066$as_echo_n "checking if we should generate debug symbols... " >&6; }
42067
42068  if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
42069    # explicit enabling of enable-debug-symbols and can't find objcopy
42070    #   this is an error
42071    as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
42072  fi
42073
42074  if test "x$enable_debug_symbols" = "xyes"; then
42075    ENABLE_DEBUG_SYMBOLS=true
42076  elif test "x$enable_debug_symbols" = "xno"; then
42077    ENABLE_DEBUG_SYMBOLS=false
42078  else
42079    # Default is on if objcopy is found
42080    if test "x$OBJCOPY" != x; then
42081      ENABLE_DEBUG_SYMBOLS=true
42082    # MacOS X and Windows don't use objcopy but default is on for those OSes
42083    elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
42084      ENABLE_DEBUG_SYMBOLS=true
42085    else
42086      ENABLE_DEBUG_SYMBOLS=false
42087    fi
42088  fi
42089
42090  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
42091$as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
42092
42093  #
42094  # ZIP_DEBUGINFO_FILES
42095  #
42096  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
42097$as_echo_n "checking if we should zip debug-info files... " >&6; }
42098  # Check whether --enable-zip-debug-info was given.
42099if test "${enable_zip_debug_info+set}" = set; then :
42100  enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
42101else
42102  enable_zip_debug_info="yes"
42103fi
42104
42105  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
42106$as_echo "${enable_zip_debug_info}" >&6; }
42107
42108  if test "x${enable_zip_debug_info}" = "xno"; then
42109    ZIP_DEBUGINFO_FILES=false
42110  else
42111    ZIP_DEBUGINFO_FILES=true
42112  fi
42113
42114
42115
42116
42117
42118###############################################################################
42119#
42120# Check dependencies for external and internal libraries.
42121#
42122###############################################################################
42123
42124# After we have toolchain, we can compile fixpath. It's needed by the lib checks.
42125
42126  # When using cygwin or msys, we need a wrapper binary that renames
42127  # /cygdrive/c/ arguments into c:/ arguments and peeks into
42128  # @files and rewrites these too! This wrapper binary is
42129  # called fixpath.
42130  FIXPATH=
42131  if test "x$OPENJDK_BUILD_OS" = xwindows; then
42132    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
42133$as_echo_n "checking if fixpath can be created... " >&6; }
42134    FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
42135    FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
42136    if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
42137      FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
42138      FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
42139      # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
42140      FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
42141    elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
42142      FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
42143      FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
42144
42145      # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
42146      # @ was chosen as separator to minimize risk of other tools messing around with it
42147      all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
42148      fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
42149
42150      FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
42151    fi
42152    rm -f $OUTPUT_ROOT/fixpath*
42153    cd $OUTPUT_ROOT
42154    $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
42155    cd $CURDIR
42156
42157    if test ! -x $OUTPUT_ROOT/fixpath.exe; then
42158      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42159$as_echo "no" >&6; }
42160      cat $OUTPUT_ROOT/fixpath1.log
42161      as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
42162    fi
42163    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42164$as_echo "yes" >&6; }
42165    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
42166$as_echo_n "checking if fixpath.exe works... " >&6; }
42167    cd $OUTPUT_ROOT
42168    $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
42169    cd $CURDIR
42170    if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
42171      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42172$as_echo "no" >&6; }
42173      cat $OUTPUT_ROOT/fixpath2.log
42174      as_fn_error $? "fixpath did not work!" "$LINENO" 5
42175    fi
42176    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42177$as_echo "yes" >&6; }
42178    rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
42179  fi
42180
42181
42182
42183
42184
42185
42186  ###############################################################################
42187  #
42188  # OS specific settings that we never will need to probe.
42189  #
42190  if test "x$OPENJDK_TARGET_OS" = xlinux; then
42191    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
42192$as_echo_n "checking what is not needed on Linux?... " >&6; }
42193    PULSE_NOT_NEEDED=yes
42194    { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
42195$as_echo "pulse" >&6; }
42196  fi
42197
42198  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42199    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
42200$as_echo_n "checking what is not needed on Solaris?... " >&6; }
42201    ALSA_NOT_NEEDED=yes
42202    PULSE_NOT_NEEDED=yes
42203    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42204$as_echo "alsa pulse" >&6; }
42205  fi
42206
42207  if test "x$OPENJDK_TARGET_OS" = xaix; then
42208    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
42209$as_echo_n "checking what is not needed on AIX?... " >&6; }
42210    ALSA_NOT_NEEDED=yes
42211    PULSE_NOT_NEEDED=yes
42212    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42213$as_echo "alsa pulse" >&6; }
42214  fi
42215
42216
42217  if test "x$OPENJDK_TARGET_OS" = xwindows; then
42218    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
42219$as_echo_n "checking what is not needed on Windows?... " >&6; }
42220    CUPS_NOT_NEEDED=yes
42221    ALSA_NOT_NEEDED=yes
42222    PULSE_NOT_NEEDED=yes
42223    X11_NOT_NEEDED=yes
42224    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
42225$as_echo "alsa cups pulse x11" >&6; }
42226  fi
42227
42228  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42229    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
42230$as_echo_n "checking what is not needed on MacOSX?... " >&6; }
42231    ALSA_NOT_NEEDED=yes
42232    PULSE_NOT_NEEDED=yes
42233    X11_NOT_NEEDED=yes
42234    # If the java runtime framework is disabled, then we need X11.
42235    # This will be adjusted below.
42236    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
42237$as_echo "alsa pulse x11" >&6; }
42238  fi
42239
42240  if test "x$OPENJDK_TARGET_OS" = xbsd; then
42241    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
42242$as_echo_n "checking what is not needed on bsd?... " >&6; }
42243    ALSA_NOT_NEEDED=yes
42244    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
42245$as_echo "alsa" >&6; }
42246  fi
42247
42248  if test "x$OPENJDK" = "xfalse"; then
42249    FREETYPE_NOT_NEEDED=yes
42250  fi
42251
42252  if test "x$SUPPORT_HEADFUL" = xno; then
42253    X11_NOT_NEEDED=yes
42254  fi
42255
42256  ###############################################################################
42257  #
42258  # Check for MacOSX support for OpenJDK.
42259  #
42260
42261
42262  # Check whether --enable-macosx-runtime-support was given.
42263if test "${enable_macosx_runtime_support+set}" = set; then :
42264  enableval=$enable_macosx_runtime_support;
42265fi
42266
42267  if test "x$enable_macosx_runtime_support" != x; then
42268    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&5
42269$as_echo "$as_me: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&2;}
42270  fi
42271
42272
42273  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42274$as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42275  if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42276    { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42277$as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42278  else
42279    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42280$as_echo "no" >&6; }
42281  fi
42282
42283
42284
42285  ###############################################################################
42286  #
42287  # Check for X Windows
42288  #
42289
42290  # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42291  # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42292  # --x-libraries for the sysroot, if that seems to be correct.
42293  if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
42294    if test "x$SYSROOT" != "x"; then
42295      if test "x$x_includes" = xNONE; then
42296        if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then
42297          x_includes="$SYSROOT/usr/X11R6/include"
42298        elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then
42299          x_includes="$SYSROOT/usr/include"
42300        fi
42301      fi
42302      if test "x$x_libraries" = xNONE; then
42303        if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then
42304          x_libraries="$SYSROOT/usr/X11R6/lib"
42305        elif test "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42306          x_libraries="$SYSROOT/usr/lib64"
42307        elif test -f "$SYSROOT/usr/lib/libX11.so"; then
42308          x_libraries="$SYSROOT/usr/lib"
42309        fi
42310      fi
42311    fi
42312  fi
42313
42314  # Now let autoconf do it's magic
42315  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42316$as_echo_n "checking for X... " >&6; }
42317
42318
42319# Check whether --with-x was given.
42320if test "${with_x+set}" = set; then :
42321  withval=$with_x;
42322fi
42323
42324# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42325if test "x$with_x" = xno; then
42326  # The user explicitly disabled X.
42327  have_x=disabled
42328else
42329  case $x_includes,$x_libraries in #(
42330    *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
42331    *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
42332  $as_echo_n "(cached) " >&6
42333else
42334  # One or both of the vars are not set, and there is no cached value.
42335ac_x_includes=no ac_x_libraries=no
42336rm -f -r conftest.dir
42337if mkdir conftest.dir; then
42338  cd conftest.dir
42339  cat >Imakefile <<'_ACEOF'
42340incroot:
42341	@echo incroot='${INCROOT}'
42342usrlibdir:
42343	@echo usrlibdir='${USRLIBDIR}'
42344libdir:
42345	@echo libdir='${LIBDIR}'
42346_ACEOF
42347  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
42348    # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
42349    for ac_var in incroot usrlibdir libdir; do
42350      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
42351    done
42352    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
42353    for ac_extension in a so sl dylib la dll; do
42354      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
42355	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
42356	ac_im_usrlibdir=$ac_im_libdir; break
42357      fi
42358    done
42359    # Screen out bogus values from the imake configuration.  They are
42360    # bogus both because they are the default anyway, and because
42361    # using them would break gcc on systems where it needs fixed includes.
42362    case $ac_im_incroot in
42363	/usr/include) ac_x_includes= ;;
42364	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
42365    esac
42366    case $ac_im_usrlibdir in
42367	/usr/lib | /usr/lib64 | /lib | /lib64) ;;
42368	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
42369    esac
42370  fi
42371  cd ..
42372  rm -f -r conftest.dir
42373fi
42374
42375# Standard set of common directories for X headers.
42376# Check X11 before X11Rn because it is often a symlink to the current release.
42377ac_x_header_dirs='
42378/usr/X11/include
42379/usr/X11R7/include
42380/usr/X11R6/include
42381/usr/X11R5/include
42382/usr/X11R4/include
42383
42384/usr/include/X11
42385/usr/include/X11R7
42386/usr/include/X11R6
42387/usr/include/X11R5
42388/usr/include/X11R4
42389
42390/usr/local/X11/include
42391/usr/local/X11R7/include
42392/usr/local/X11R6/include
42393/usr/local/X11R5/include
42394/usr/local/X11R4/include
42395
42396/usr/local/include/X11
42397/usr/local/include/X11R7
42398/usr/local/include/X11R6
42399/usr/local/include/X11R5
42400/usr/local/include/X11R4
42401
42402/usr/X386/include
42403/usr/x386/include
42404/usr/XFree86/include/X11
42405
42406/usr/include
42407/usr/local/include
42408/usr/unsupported/include
42409/usr/athena/include
42410/usr/local/x11r5/include
42411/usr/lpp/Xamples/include
42412
42413/usr/openwin/include
42414/usr/openwin/share/include'
42415
42416if test "$ac_x_includes" = no; then
42417  # Guess where to find include files, by looking for Xlib.h.
42418  # First, try using that file with no special directory specified.
42419  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42420/* end confdefs.h.  */
42421#include <X11/Xlib.h>
42422_ACEOF
42423if ac_fn_cxx_try_cpp "$LINENO"; then :
42424  # We can compile using X headers with no special include directory.
42425ac_x_includes=
42426else
42427  for ac_dir in $ac_x_header_dirs; do
42428  if test -r "$ac_dir/X11/Xlib.h"; then
42429    ac_x_includes=$ac_dir
42430    break
42431  fi
42432done
42433fi
42434rm -f conftest.err conftest.i conftest.$ac_ext
42435fi # $ac_x_includes = no
42436
42437if test "$ac_x_libraries" = no; then
42438  # Check for the libraries.
42439  # See if we find them without any special options.
42440  # Don't add to $LIBS permanently.
42441  ac_save_LIBS=$LIBS
42442  LIBS="-lX11 $LIBS"
42443  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42444/* end confdefs.h.  */
42445#include <X11/Xlib.h>
42446int
42447main ()
42448{
42449XrmInitialize ()
42450  ;
42451  return 0;
42452}
42453_ACEOF
42454if ac_fn_cxx_try_link "$LINENO"; then :
42455  LIBS=$ac_save_LIBS
42456# We can link X programs with no special library path.
42457ac_x_libraries=
42458else
42459  LIBS=$ac_save_LIBS
42460for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
42461do
42462  # Don't even attempt the hair of trying to link an X program!
42463  for ac_extension in a so sl dylib la dll; do
42464    if test -r "$ac_dir/libX11.$ac_extension"; then
42465      ac_x_libraries=$ac_dir
42466      break 2
42467    fi
42468  done
42469done
42470fi
42471rm -f core conftest.err conftest.$ac_objext \
42472    conftest$ac_exeext conftest.$ac_ext
42473fi # $ac_x_libraries = no
42474
42475case $ac_x_includes,$ac_x_libraries in #(
42476  no,* | *,no | *\'*)
42477    # Didn't find X, or a directory has "'" in its name.
42478    ac_cv_have_x="have_x=no";; #(
42479  *)
42480    # Record where we found X for the cache.
42481    ac_cv_have_x="have_x=yes\
42482	ac_x_includes='$ac_x_includes'\
42483	ac_x_libraries='$ac_x_libraries'"
42484esac
42485fi
42486;; #(
42487    *) have_x=yes;;
42488  esac
42489  eval "$ac_cv_have_x"
42490fi # $with_x != no
42491
42492if test "$have_x" != yes; then
42493  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
42494$as_echo "$have_x" >&6; }
42495  no_x=yes
42496else
42497  # If each of the values was on the command line, it overrides each guess.
42498  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
42499  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
42500  # Update the cache value to reflect the command line values.
42501  ac_cv_have_x="have_x=yes\
42502	ac_x_includes='$x_includes'\
42503	ac_x_libraries='$x_libraries'"
42504  { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
42505$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
42506fi
42507
42508  if test "$no_x" = yes; then
42509  # Not all programs may use this symbol, but it does not hurt to define it.
42510
42511$as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
42512
42513  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
42514else
42515  if test -n "$x_includes"; then
42516    X_CFLAGS="$X_CFLAGS -I$x_includes"
42517  fi
42518
42519  # It would also be nice to do this for all -L options, not just this one.
42520  if test -n "$x_libraries"; then
42521    X_LIBS="$X_LIBS -L$x_libraries"
42522    # For Solaris; some versions of Sun CC require a space after -R and
42523    # others require no space.  Words are not sufficient . . . .
42524    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
42525$as_echo_n "checking whether -R must be followed by a space... " >&6; }
42526    ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
42527    ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
42528    ac_cxx_werror_flag=yes
42529    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42530/* end confdefs.h.  */
42531
42532int
42533main ()
42534{
42535
42536  ;
42537  return 0;
42538}
42539_ACEOF
42540if ac_fn_cxx_try_link "$LINENO"; then :
42541  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42542$as_echo "no" >&6; }
42543       X_LIBS="$X_LIBS -R$x_libraries"
42544else
42545  LIBS="$ac_xsave_LIBS -R $x_libraries"
42546       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42547/* end confdefs.h.  */
42548
42549int
42550main ()
42551{
42552
42553  ;
42554  return 0;
42555}
42556_ACEOF
42557if ac_fn_cxx_try_link "$LINENO"; then :
42558  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42559$as_echo "yes" >&6; }
42560	  X_LIBS="$X_LIBS -R $x_libraries"
42561else
42562  { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
42563$as_echo "neither works" >&6; }
42564fi
42565rm -f core conftest.err conftest.$ac_objext \
42566    conftest$ac_exeext conftest.$ac_ext
42567fi
42568rm -f core conftest.err conftest.$ac_objext \
42569    conftest$ac_exeext conftest.$ac_ext
42570    ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
42571    LIBS=$ac_xsave_LIBS
42572  fi
42573
42574  # Check for system-dependent libraries X programs must link with.
42575  # Do this before checking for the system-independent R6 libraries
42576  # (-lICE), since we may need -lsocket or whatever for X linking.
42577
42578  if test "$ISC" = yes; then
42579    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
42580  else
42581    # Martyn Johnson says this is needed for Ultrix, if the X
42582    # libraries were built with DECnet support.  And Karl Berry says
42583    # the Alpha needs dnet_stub (dnet does not exist).
42584    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
42585    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42586/* end confdefs.h.  */
42587
42588/* Override any GCC internal prototype to avoid an error.
42589   Use char because int might match the return type of a GCC
42590   builtin and then its argument prototype would still apply.  */
42591#ifdef __cplusplus
42592extern "C"
42593#endif
42594char XOpenDisplay ();
42595int
42596main ()
42597{
42598return XOpenDisplay ();
42599  ;
42600  return 0;
42601}
42602_ACEOF
42603if ac_fn_cxx_try_link "$LINENO"; then :
42604
42605else
42606  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
42607$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
42608if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
42609  $as_echo_n "(cached) " >&6
42610else
42611  ac_check_lib_save_LIBS=$LIBS
42612LIBS="-ldnet  $LIBS"
42613cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42614/* end confdefs.h.  */
42615
42616/* Override any GCC internal prototype to avoid an error.
42617   Use char because int might match the return type of a GCC
42618   builtin and then its argument prototype would still apply.  */
42619#ifdef __cplusplus
42620extern "C"
42621#endif
42622char dnet_ntoa ();
42623int
42624main ()
42625{
42626return dnet_ntoa ();
42627  ;
42628  return 0;
42629}
42630_ACEOF
42631if ac_fn_cxx_try_link "$LINENO"; then :
42632  ac_cv_lib_dnet_dnet_ntoa=yes
42633else
42634  ac_cv_lib_dnet_dnet_ntoa=no
42635fi
42636rm -f core conftest.err conftest.$ac_objext \
42637    conftest$ac_exeext conftest.$ac_ext
42638LIBS=$ac_check_lib_save_LIBS
42639fi
42640{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
42641$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
42642if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
42643  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
42644fi
42645
42646    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
42647      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
42648$as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
42649if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
42650  $as_echo_n "(cached) " >&6
42651else
42652  ac_check_lib_save_LIBS=$LIBS
42653LIBS="-ldnet_stub  $LIBS"
42654cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42655/* end confdefs.h.  */
42656
42657/* Override any GCC internal prototype to avoid an error.
42658   Use char because int might match the return type of a GCC
42659   builtin and then its argument prototype would still apply.  */
42660#ifdef __cplusplus
42661extern "C"
42662#endif
42663char dnet_ntoa ();
42664int
42665main ()
42666{
42667return dnet_ntoa ();
42668  ;
42669  return 0;
42670}
42671_ACEOF
42672if ac_fn_cxx_try_link "$LINENO"; then :
42673  ac_cv_lib_dnet_stub_dnet_ntoa=yes
42674else
42675  ac_cv_lib_dnet_stub_dnet_ntoa=no
42676fi
42677rm -f core conftest.err conftest.$ac_objext \
42678    conftest$ac_exeext conftest.$ac_ext
42679LIBS=$ac_check_lib_save_LIBS
42680fi
42681{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
42682$as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
42683if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
42684  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
42685fi
42686
42687    fi
42688fi
42689rm -f core conftest.err conftest.$ac_objext \
42690    conftest$ac_exeext conftest.$ac_ext
42691    LIBS="$ac_xsave_LIBS"
42692
42693    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
42694    # to get the SysV transport functions.
42695    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
42696    # needs -lnsl.
42697    # The nsl library prevents programs from opening the X display
42698    # on Irix 5.2, according to T.E. Dickey.
42699    # The functions gethostbyname, getservbyname, and inet_addr are
42700    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
42701    ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
42702if test "x$ac_cv_func_gethostbyname" = xyes; then :
42703
42704fi
42705
42706    if test $ac_cv_func_gethostbyname = no; then
42707      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
42708$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
42709if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
42710  $as_echo_n "(cached) " >&6
42711else
42712  ac_check_lib_save_LIBS=$LIBS
42713LIBS="-lnsl  $LIBS"
42714cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42715/* end confdefs.h.  */
42716
42717/* Override any GCC internal prototype to avoid an error.
42718   Use char because int might match the return type of a GCC
42719   builtin and then its argument prototype would still apply.  */
42720#ifdef __cplusplus
42721extern "C"
42722#endif
42723char gethostbyname ();
42724int
42725main ()
42726{
42727return gethostbyname ();
42728  ;
42729  return 0;
42730}
42731_ACEOF
42732if ac_fn_cxx_try_link "$LINENO"; then :
42733  ac_cv_lib_nsl_gethostbyname=yes
42734else
42735  ac_cv_lib_nsl_gethostbyname=no
42736fi
42737rm -f core conftest.err conftest.$ac_objext \
42738    conftest$ac_exeext conftest.$ac_ext
42739LIBS=$ac_check_lib_save_LIBS
42740fi
42741{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
42742$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
42743if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
42744  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
42745fi
42746
42747      if test $ac_cv_lib_nsl_gethostbyname = no; then
42748	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
42749$as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
42750if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
42751  $as_echo_n "(cached) " >&6
42752else
42753  ac_check_lib_save_LIBS=$LIBS
42754LIBS="-lbsd  $LIBS"
42755cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42756/* end confdefs.h.  */
42757
42758/* Override any GCC internal prototype to avoid an error.
42759   Use char because int might match the return type of a GCC
42760   builtin and then its argument prototype would still apply.  */
42761#ifdef __cplusplus
42762extern "C"
42763#endif
42764char gethostbyname ();
42765int
42766main ()
42767{
42768return gethostbyname ();
42769  ;
42770  return 0;
42771}
42772_ACEOF
42773if ac_fn_cxx_try_link "$LINENO"; then :
42774  ac_cv_lib_bsd_gethostbyname=yes
42775else
42776  ac_cv_lib_bsd_gethostbyname=no
42777fi
42778rm -f core conftest.err conftest.$ac_objext \
42779    conftest$ac_exeext conftest.$ac_ext
42780LIBS=$ac_check_lib_save_LIBS
42781fi
42782{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
42783$as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
42784if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
42785  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
42786fi
42787
42788      fi
42789    fi
42790
42791    # lieder@skyler.mavd.honeywell.com says without -lsocket,
42792    # socket/setsockopt and other routines are undefined under SCO ODT
42793    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
42794    # on later versions), says Simon Leinen: it contains gethostby*
42795    # variants that don't use the name server (or something).  -lsocket
42796    # must be given before -lnsl if both are needed.  We assume that
42797    # if connect needs -lnsl, so does gethostbyname.
42798    ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
42799if test "x$ac_cv_func_connect" = xyes; then :
42800
42801fi
42802
42803    if test $ac_cv_func_connect = no; then
42804      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
42805$as_echo_n "checking for connect in -lsocket... " >&6; }
42806if ${ac_cv_lib_socket_connect+:} false; then :
42807  $as_echo_n "(cached) " >&6
42808else
42809  ac_check_lib_save_LIBS=$LIBS
42810LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
42811cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42812/* end confdefs.h.  */
42813
42814/* Override any GCC internal prototype to avoid an error.
42815   Use char because int might match the return type of a GCC
42816   builtin and then its argument prototype would still apply.  */
42817#ifdef __cplusplus
42818extern "C"
42819#endif
42820char connect ();
42821int
42822main ()
42823{
42824return connect ();
42825  ;
42826  return 0;
42827}
42828_ACEOF
42829if ac_fn_cxx_try_link "$LINENO"; then :
42830  ac_cv_lib_socket_connect=yes
42831else
42832  ac_cv_lib_socket_connect=no
42833fi
42834rm -f core conftest.err conftest.$ac_objext \
42835    conftest$ac_exeext conftest.$ac_ext
42836LIBS=$ac_check_lib_save_LIBS
42837fi
42838{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
42839$as_echo "$ac_cv_lib_socket_connect" >&6; }
42840if test "x$ac_cv_lib_socket_connect" = xyes; then :
42841  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
42842fi
42843
42844    fi
42845
42846    # Guillermo Gomez says -lposix is necessary on A/UX.
42847    ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
42848if test "x$ac_cv_func_remove" = xyes; then :
42849
42850fi
42851
42852    if test $ac_cv_func_remove = no; then
42853      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
42854$as_echo_n "checking for remove in -lposix... " >&6; }
42855if ${ac_cv_lib_posix_remove+:} false; then :
42856  $as_echo_n "(cached) " >&6
42857else
42858  ac_check_lib_save_LIBS=$LIBS
42859LIBS="-lposix  $LIBS"
42860cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42861/* end confdefs.h.  */
42862
42863/* Override any GCC internal prototype to avoid an error.
42864   Use char because int might match the return type of a GCC
42865   builtin and then its argument prototype would still apply.  */
42866#ifdef __cplusplus
42867extern "C"
42868#endif
42869char remove ();
42870int
42871main ()
42872{
42873return remove ();
42874  ;
42875  return 0;
42876}
42877_ACEOF
42878if ac_fn_cxx_try_link "$LINENO"; then :
42879  ac_cv_lib_posix_remove=yes
42880else
42881  ac_cv_lib_posix_remove=no
42882fi
42883rm -f core conftest.err conftest.$ac_objext \
42884    conftest$ac_exeext conftest.$ac_ext
42885LIBS=$ac_check_lib_save_LIBS
42886fi
42887{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
42888$as_echo "$ac_cv_lib_posix_remove" >&6; }
42889if test "x$ac_cv_lib_posix_remove" = xyes; then :
42890  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
42891fi
42892
42893    fi
42894
42895    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
42896    ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
42897if test "x$ac_cv_func_shmat" = xyes; then :
42898
42899fi
42900
42901    if test $ac_cv_func_shmat = no; then
42902      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
42903$as_echo_n "checking for shmat in -lipc... " >&6; }
42904if ${ac_cv_lib_ipc_shmat+:} false; then :
42905  $as_echo_n "(cached) " >&6
42906else
42907  ac_check_lib_save_LIBS=$LIBS
42908LIBS="-lipc  $LIBS"
42909cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42910/* end confdefs.h.  */
42911
42912/* Override any GCC internal prototype to avoid an error.
42913   Use char because int might match the return type of a GCC
42914   builtin and then its argument prototype would still apply.  */
42915#ifdef __cplusplus
42916extern "C"
42917#endif
42918char shmat ();
42919int
42920main ()
42921{
42922return shmat ();
42923  ;
42924  return 0;
42925}
42926_ACEOF
42927if ac_fn_cxx_try_link "$LINENO"; then :
42928  ac_cv_lib_ipc_shmat=yes
42929else
42930  ac_cv_lib_ipc_shmat=no
42931fi
42932rm -f core conftest.err conftest.$ac_objext \
42933    conftest$ac_exeext conftest.$ac_ext
42934LIBS=$ac_check_lib_save_LIBS
42935fi
42936{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
42937$as_echo "$ac_cv_lib_ipc_shmat" >&6; }
42938if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
42939  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
42940fi
42941
42942    fi
42943  fi
42944
42945  # Check for libraries that X11R6 Xt/Xaw programs need.
42946  ac_save_LDFLAGS=$LDFLAGS
42947  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
42948  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
42949  # check for ICE first), but we must link in the order -lSM -lICE or
42950  # we get undefined symbols.  So assume we have SM if we have ICE.
42951  # These have to be linked with before -lX11, unlike the other
42952  # libraries we check for below, so use a different variable.
42953  # John Interrante, Karl Berry
42954  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
42955$as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
42956if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
42957  $as_echo_n "(cached) " >&6
42958else
42959  ac_check_lib_save_LIBS=$LIBS
42960LIBS="-lICE $X_EXTRA_LIBS $LIBS"
42961cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42962/* end confdefs.h.  */
42963
42964/* Override any GCC internal prototype to avoid an error.
42965   Use char because int might match the return type of a GCC
42966   builtin and then its argument prototype would still apply.  */
42967#ifdef __cplusplus
42968extern "C"
42969#endif
42970char IceConnectionNumber ();
42971int
42972main ()
42973{
42974return IceConnectionNumber ();
42975  ;
42976  return 0;
42977}
42978_ACEOF
42979if ac_fn_cxx_try_link "$LINENO"; then :
42980  ac_cv_lib_ICE_IceConnectionNumber=yes
42981else
42982  ac_cv_lib_ICE_IceConnectionNumber=no
42983fi
42984rm -f core conftest.err conftest.$ac_objext \
42985    conftest$ac_exeext conftest.$ac_ext
42986LIBS=$ac_check_lib_save_LIBS
42987fi
42988{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
42989$as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
42990if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
42991  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
42992fi
42993
42994  LDFLAGS=$ac_save_LDFLAGS
42995
42996fi
42997
42998
42999  # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
43000  # this doesn't make sense so we remove it.
43001  if test "x$COMPILE_TYPE" = xcross; then
43002    X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
43003  fi
43004
43005  if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then
43006
43007  # Print a helpful message on how to acquire the necessary build dependency.
43008  # x11 is the help tag: freetype, cups, pulse, alsa etc
43009  MISSING_DEPENDENCY=x11
43010
43011  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43012    cygwin_help $MISSING_DEPENDENCY
43013  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43014    msys_help $MISSING_DEPENDENCY
43015  else
43016    PKGHANDLER_COMMAND=
43017
43018    case $PKGHANDLER in
43019      apt-get)
43020        apt_help     $MISSING_DEPENDENCY ;;
43021      yum)
43022        yum_help     $MISSING_DEPENDENCY ;;
43023      port)
43024        port_help    $MISSING_DEPENDENCY ;;
43025      pkgutil)
43026        pkgutil_help $MISSING_DEPENDENCY ;;
43027      pkgadd)
43028        pkgadd_help  $MISSING_DEPENDENCY ;;
43029    esac
43030
43031    if test "x$PKGHANDLER_COMMAND" != x; then
43032      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43033    fi
43034  fi
43035
43036    as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
43037  fi
43038
43039  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
43040    OPENWIN_HOME="/usr/openwin"
43041    X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions"
43042    X_LIBS="-L$SYSROOT$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
43043        -L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \
43044        -R$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
43045        -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR"
43046  fi
43047
43048  #
43049  # Weird Sol10 something check...TODO change to try compile
43050  #
43051  if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
43052    if test "`uname -r`" = "5.10"; then
43053      if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
43054        X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
43055      fi
43056    fi
43057  fi
43058
43059  ac_ext=c
43060ac_cpp='$CPP $CPPFLAGS'
43061ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43062ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43063ac_compiler_gnu=$ac_cv_c_compiler_gnu
43064
43065  OLD_CFLAGS="$CFLAGS"
43066  CFLAGS="$CFLAGS $X_CFLAGS"
43067
43068  # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
43069  for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
43070do :
43071  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43072ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
43073        # include <X11/Xlib.h>
43074        # include <X11/Xutil.h>
43075
43076
43077"
43078if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43079  cat >>confdefs.h <<_ACEOF
43080#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43081_ACEOF
43082 X11_A_OK=yes
43083else
43084  X11_A_OK=no; break
43085fi
43086
43087done
43088
43089
43090  CFLAGS="$OLD_CFLAGS"
43091  ac_ext=cpp
43092ac_cpp='$CXXCPP $CPPFLAGS'
43093ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43094ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43095ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
43096
43097
43098  if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then
43099
43100  # Print a helpful message on how to acquire the necessary build dependency.
43101  # x11 is the help tag: freetype, cups, pulse, alsa etc
43102  MISSING_DEPENDENCY=x11
43103
43104  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43105    cygwin_help $MISSING_DEPENDENCY
43106  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43107    msys_help $MISSING_DEPENDENCY
43108  else
43109    PKGHANDLER_COMMAND=
43110
43111    case $PKGHANDLER in
43112      apt-get)
43113        apt_help     $MISSING_DEPENDENCY ;;
43114      yum)
43115        yum_help     $MISSING_DEPENDENCY ;;
43116      port)
43117        port_help    $MISSING_DEPENDENCY ;;
43118      pkgutil)
43119        pkgutil_help $MISSING_DEPENDENCY ;;
43120      pkgadd)
43121        pkgadd_help  $MISSING_DEPENDENCY ;;
43122    esac
43123
43124    if test "x$PKGHANDLER_COMMAND" != x; then
43125      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43126    fi
43127  fi
43128
43129    as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
43130  fi
43131
43132
43133
43134
43135
43136
43137  ###############################################################################
43138  #
43139  # The common unix printing system cups is used to print from java.
43140  #
43141
43142# Check whether --with-cups was given.
43143if test "${with_cups+set}" = set; then :
43144  withval=$with_cups;
43145fi
43146
43147
43148# Check whether --with-cups-include was given.
43149if test "${with_cups_include+set}" = set; then :
43150  withval=$with_cups_include;
43151fi
43152
43153
43154  if test "x$CUPS_NOT_NEEDED" = xyes; then
43155    if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
43156      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
43157$as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
43158    fi
43159    CUPS_CFLAGS=
43160  else
43161    CUPS_FOUND=no
43162
43163    if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
43164      as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
43165    fi
43166
43167    if test "x${with_cups}" != x; then
43168      CUPS_CFLAGS="-I${with_cups}/include"
43169      CUPS_FOUND=yes
43170    fi
43171    if test "x${with_cups_include}" != x; then
43172      CUPS_CFLAGS="-I${with_cups_include}"
43173      CUPS_FOUND=yes
43174    fi
43175    if test "x$CUPS_FOUND" = xno; then
43176
43177
43178  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43179    # Source the builddeps file again, to make sure it uses the latest variables!
43180    . $builddepsfile
43181    # Look for a target and build machine specific resource!
43182    eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43183    if test "x$resource" = x; then
43184      # Ok, lets instead look for a target specific resource
43185      eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
43186    fi
43187    if test "x$resource" = x; then
43188      # Ok, lets instead look for a build specific resource
43189      eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
43190    fi
43191    if test "x$resource" = x; then
43192      # Ok, lets instead look for a generic resource
43193      # (The cups comes from M4 and not the shell, thus no need for eval here.)
43194      resource=${builddep_cups}
43195    fi
43196    if test "x$resource" != x; then
43197      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
43198$as_echo "$as_me: Using builddeps $resource for cups" >&6;}
43199      # If the resource in the builddeps.conf file is an existing directory,
43200      # for example /java/linux/cups
43201      if test -d ${resource}; then
43202        depdir=${resource}
43203      else
43204
43205  # cups is for example mymodule
43206  # $resource is for example libs/general/libmymod_1_2_3.zip
43207  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43208  # $with_builddeps_dir is for example /localhome/builddeps
43209  # depdir is the name of the variable into which we store the depdir, eg MYMOD
43210  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43211  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43212  filename=`basename $resource`
43213  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43214  filebase=${filename%%.*}
43215  extension=${filename#*.}
43216  installdir=$with_builddeps_dir/$filebase
43217  if test ! -f $installdir/$filename.unpacked; then
43218    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
43219$as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43220    if test ! -d $installdir; then
43221      mkdir -p $installdir
43222    fi
43223    if test ! -d $installdir; then
43224      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43225    fi
43226    tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
43227    touch $tmpfile
43228    if test ! -f $tmpfile; then
43229      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43230    fi
43231
43232  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43233  # $tmpfile is the local file name for the downloaded file.
43234  VALID_TOOL=no
43235  if test "x$BDEPS_FTP" = xwget; then
43236    VALID_TOOL=yes
43237    wget -O $tmpfile $with_builddeps_server/$resource
43238  fi
43239  if test "x$BDEPS_FTP" = xlftp; then
43240    VALID_TOOL=yes
43241    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43242  fi
43243  if test "x$BDEPS_FTP" = xftp; then
43244    VALID_TOOL=yes
43245    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43246    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43247    FTPUSERPWD=${FTPSERVER%%@*}
43248    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43249      FTPUSER=${userpwd%%:*}
43250      FTPPWD=${userpwd#*@}
43251      FTPSERVER=${FTPSERVER#*@}
43252    else
43253      FTPUSER=ftp
43254      FTPPWD=ftp
43255    fi
43256    # the "pass" command does not work on some
43257    # ftp clients (read ftp.exe) but if it works,
43258    # passive mode is better!
43259    ( \
43260        echo "user $FTPUSER $FTPPWD"        ; \
43261        echo "pass"                         ; \
43262        echo "bin"                          ; \
43263        echo "get $FTPPATH $tmpfile"              ; \
43264    ) | ftp -in $FTPSERVER
43265  fi
43266  if test "x$VALID_TOOL" != xyes; then
43267    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43268  fi
43269
43270    mv $tmpfile $installdir/$filename
43271    if test ! -s $installdir/$filename; then
43272      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43273    fi
43274    case "$extension" in
43275      zip)  echo "Unzipping $installdir/$filename..."
43276        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43277        ;;
43278      tar.gz) echo "Untaring $installdir/$filename..."
43279        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43280        ;;
43281      tgz) echo "Untaring $installdir/$filename..."
43282        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43283        ;;
43284      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43285        ;;
43286    esac
43287  fi
43288  if test -f $installdir/$filename.unpacked; then
43289    depdir=$installdir
43290  fi
43291
43292      fi
43293      # Source the builddeps file again, because in the previous command, the depdir
43294      # was updated to point at the current build dependency install directory.
43295      . $builddepsfile
43296      # Now extract variables from the builddeps.conf files.
43297      theroot=${builddep_cups_ROOT}
43298      thecflags=${builddep_cups_CFLAGS}
43299      thelibs=${builddep_cups_LIBS}
43300      if test "x$depdir" = x; then
43301        as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
43302      fi
43303      CUPS=$depdir
43304      if test "x$theroot" != x; then
43305        CUPS="$theroot"
43306      fi
43307      if test "x$thecflags" != x; then
43308        CUPS_CFLAGS="$thecflags"
43309      fi
43310      if test "x$thelibs" != x; then
43311        CUPS_LIBS="$thelibs"
43312      fi
43313      CUPS_FOUND=yes
43314
43315    fi
43316
43317  fi
43318
43319    fi
43320    if test "x$CUPS_FOUND" = xno; then
43321      # Are the cups headers installed in the default /usr/include location?
43322      for ac_header in cups/cups.h cups/ppd.h
43323do :
43324  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43325ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
43326if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43327  cat >>confdefs.h <<_ACEOF
43328#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43329_ACEOF
43330
43331            CUPS_FOUND=yes
43332            CUPS_CFLAGS=
43333            DEFAULT_CUPS=yes
43334
43335
43336fi
43337
43338done
43339
43340    fi
43341    if test "x$CUPS_FOUND" = xno; then
43342      # Getting nervous now? Lets poke around for standard Solaris third-party
43343      # package installation locations.
43344      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43345$as_echo_n "checking for cups headers... " >&6; }
43346      if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then
43347        # An SFW package seems to be installed!
43348        CUPS_FOUND=yes
43349        CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include"
43350      elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then
43351        # A CSW package seems to be installed!
43352        CUPS_FOUND=yes
43353        CUPS_CFLAGS="-I$SYSROOT/opt/csw/include"
43354      fi
43355      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43356$as_echo "$CUPS_FOUND" >&6; }
43357    fi
43358    if test "x$CUPS_FOUND" = xno; then
43359
43360  # Print a helpful message on how to acquire the necessary build dependency.
43361  # cups is the help tag: freetype, cups, pulse, alsa etc
43362  MISSING_DEPENDENCY=cups
43363
43364  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43365    cygwin_help $MISSING_DEPENDENCY
43366  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43367    msys_help $MISSING_DEPENDENCY
43368  else
43369    PKGHANDLER_COMMAND=
43370
43371    case $PKGHANDLER in
43372      apt-get)
43373        apt_help     $MISSING_DEPENDENCY ;;
43374      yum)
43375        yum_help     $MISSING_DEPENDENCY ;;
43376      port)
43377        port_help    $MISSING_DEPENDENCY ;;
43378      pkgutil)
43379        pkgutil_help $MISSING_DEPENDENCY ;;
43380      pkgadd)
43381        pkgadd_help  $MISSING_DEPENDENCY ;;
43382    esac
43383
43384    if test "x$PKGHANDLER_COMMAND" != x; then
43385      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43386    fi
43387  fi
43388
43389      as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
43390    fi
43391  fi
43392
43393
43394
43395
43396
43397
43398  ###############################################################################
43399  #
43400  # The ubiquitous freetype library is used to render fonts.
43401  #
43402
43403# Check whether --with-freetype was given.
43404if test "${with_freetype+set}" = set; then :
43405  withval=$with_freetype;
43406fi
43407
43408
43409# Check whether --with-freetype-include was given.
43410if test "${with_freetype_include+set}" = set; then :
43411  withval=$with_freetype_include;
43412fi
43413
43414
43415# Check whether --with-freetype-lib was given.
43416if test "${with_freetype_lib+set}" = set; then :
43417  withval=$with_freetype_lib;
43418fi
43419
43420  # Check whether --enable-freetype-bundling was given.
43421if test "${enable_freetype_bundling+set}" = set; then :
43422  enableval=$enable_freetype_bundling;
43423fi
43424
43425
43426  FREETYPE_CFLAGS=
43427  FREETYPE_LIBS=
43428  FREETYPE_BUNDLE_LIB_PATH=
43429
43430  if test "x$FREETYPE_NOT_NEEDED" = xyes; then
43431    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43432      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
43433$as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
43434    fi
43435    if test "x$enable_freetype_bundling" != x; then
43436      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
43437$as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
43438    fi
43439  else
43440    # freetype is needed to build; go get it!
43441
43442    BUNDLE_FREETYPE="$enable_freetype_bundling"
43443
43444    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43445      # User has specified settings
43446
43447      if test "x$BUNDLE_FREETYPE" = x; then
43448        # If not specified, default is to bundle freetype
43449        BUNDLE_FREETYPE=yes
43450      fi
43451
43452      if test "x$with_freetype" != x; then
43453        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
43454        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
43455      fi
43456
43457      # Allow --with-freetype-lib and --with-freetype-include to override
43458      if test "x$with_freetype_include" != x; then
43459        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
43460      fi
43461      if test "x$with_freetype_lib" != x; then
43462        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
43463      fi
43464
43465      if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
43466        # Okay, we got it. Check that it works.
43467
43468  POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43469  POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43470  METHOD="--with-freetype"
43471
43472  # First check if the files exists.
43473  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43474    # We found an arbitrary include file. That's a good sign.
43475    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43476$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43477    FOUND_FREETYPE=yes
43478
43479    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43480    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43481      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43482$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43483      FOUND_FREETYPE=no
43484    else
43485      if test "x$OPENJDK_TARGET_OS" = xwindows; then
43486        # On Windows, we will need both .lib and .dll file.
43487        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43488          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43489$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43490          FOUND_FREETYPE=no
43491        fi
43492      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
43493        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43494        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43495      fi
43496    fi
43497  fi
43498
43499  if test "x$FOUND_FREETYPE" = xyes; then
43500
43501  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43502
43503  # Input might be given as Windows format, start by converting to
43504  # unix format.
43505  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43506  new_path=`$CYGPATH -u "$path"`
43507
43508  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43509  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43510  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43511  # "foo.exe" is OK but "foo" is an error.
43512  #
43513  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43514  # It is also a way to make sure we got the proper file name for the real test later on.
43515  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43516  if test "x$test_shortpath" = x; then
43517    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43518$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43519    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43520  fi
43521
43522  # Call helper function which possibly converts this using DOS-style short mode.
43523  # If so, the updated path is stored in $new_path.
43524
43525  input_path="$new_path"
43526  # Check if we need to convert this using DOS-style short mode. If the path
43527  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43528  # take no chances and rewrite it.
43529  # Note: m4 eats our [], so we need to use [ and ] instead.
43530  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43531  if test "x$has_forbidden_chars" != x; then
43532    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43533    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43534    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43535    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43536      # Going to short mode and back again did indeed matter. Since short mode is
43537      # case insensitive, let's make it lowercase to improve readability.
43538      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43539      # Now convert it back to Unix-stile (cygpath)
43540      input_path=`$CYGPATH -u "$shortmode_path"`
43541      new_path="$input_path"
43542    fi
43543  fi
43544
43545  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43546  if test "x$test_cygdrive_prefix" = x; then
43547    # As a simple fix, exclude /usr/bin since it's not a real path.
43548    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43549      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43550      # a path prefixed by /cygdrive for fixpath to work.
43551      new_path="$CYGWIN_ROOT_PATH$input_path"
43552    fi
43553  fi
43554
43555
43556  if test "x$path" != "x$new_path"; then
43557    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43558    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43559$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43560  fi
43561
43562  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43563
43564  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43565  has_colon=`$ECHO $path | $GREP ^.:`
43566  new_path="$path"
43567  if test "x$has_colon" = x; then
43568    # Not in mixed or Windows style, start by that.
43569    new_path=`cmd //c echo $path`
43570  fi
43571
43572
43573  input_path="$new_path"
43574  # Check if we need to convert this using DOS-style short mode. If the path
43575  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43576  # take no chances and rewrite it.
43577  # Note: m4 eats our [], so we need to use [ and ] instead.
43578  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43579  if test "x$has_forbidden_chars" != x; then
43580    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43581    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43582  fi
43583
43584
43585  windows_path="$new_path"
43586  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43587    unix_path=`$CYGPATH -u "$windows_path"`
43588    new_path="$unix_path"
43589  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43590    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43591    new_path="$unix_path"
43592  fi
43593
43594  if test "x$path" != "x$new_path"; then
43595    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43596    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43597$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43598  fi
43599
43600  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43601  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43602
43603  else
43604    # We're on a posix platform. Hooray! :)
43605    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43606    has_space=`$ECHO "$path" | $GREP " "`
43607    if test "x$has_space" != x; then
43608      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43609$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43610      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43611    fi
43612
43613    # Use eval to expand a potential ~
43614    eval path="$path"
43615    if test ! -f "$path" && test ! -d "$path"; then
43616      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43617    fi
43618
43619    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43620  fi
43621
43622
43623  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43624
43625  # Input might be given as Windows format, start by converting to
43626  # unix format.
43627  path="$POTENTIAL_FREETYPE_LIB_PATH"
43628  new_path=`$CYGPATH -u "$path"`
43629
43630  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43631  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43632  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43633  # "foo.exe" is OK but "foo" is an error.
43634  #
43635  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43636  # It is also a way to make sure we got the proper file name for the real test later on.
43637  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43638  if test "x$test_shortpath" = x; then
43639    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43640$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43641    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
43642  fi
43643
43644  # Call helper function which possibly converts this using DOS-style short mode.
43645  # If so, the updated path is stored in $new_path.
43646
43647  input_path="$new_path"
43648  # Check if we need to convert this using DOS-style short mode. If the path
43649  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43650  # take no chances and rewrite it.
43651  # Note: m4 eats our [], so we need to use [ and ] instead.
43652  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43653  if test "x$has_forbidden_chars" != x; then
43654    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43655    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43656    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43657    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43658      # Going to short mode and back again did indeed matter. Since short mode is
43659      # case insensitive, let's make it lowercase to improve readability.
43660      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43661      # Now convert it back to Unix-stile (cygpath)
43662      input_path=`$CYGPATH -u "$shortmode_path"`
43663      new_path="$input_path"
43664    fi
43665  fi
43666
43667  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43668  if test "x$test_cygdrive_prefix" = x; then
43669    # As a simple fix, exclude /usr/bin since it's not a real path.
43670    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43671      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43672      # a path prefixed by /cygdrive for fixpath to work.
43673      new_path="$CYGWIN_ROOT_PATH$input_path"
43674    fi
43675  fi
43676
43677
43678  if test "x$path" != "x$new_path"; then
43679    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43680    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43681$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43682  fi
43683
43684  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43685
43686  path="$POTENTIAL_FREETYPE_LIB_PATH"
43687  has_colon=`$ECHO $path | $GREP ^.:`
43688  new_path="$path"
43689  if test "x$has_colon" = x; then
43690    # Not in mixed or Windows style, start by that.
43691    new_path=`cmd //c echo $path`
43692  fi
43693
43694
43695  input_path="$new_path"
43696  # Check if we need to convert this using DOS-style short mode. If the path
43697  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43698  # take no chances and rewrite it.
43699  # Note: m4 eats our [], so we need to use [ and ] instead.
43700  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43701  if test "x$has_forbidden_chars" != x; then
43702    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43703    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43704  fi
43705
43706
43707  windows_path="$new_path"
43708  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43709    unix_path=`$CYGPATH -u "$windows_path"`
43710    new_path="$unix_path"
43711  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43712    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43713    new_path="$unix_path"
43714  fi
43715
43716  if test "x$path" != "x$new_path"; then
43717    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43718    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43719$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43720  fi
43721
43722  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43723  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43724
43725  else
43726    # We're on a posix platform. Hooray! :)
43727    path="$POTENTIAL_FREETYPE_LIB_PATH"
43728    has_space=`$ECHO "$path" | $GREP " "`
43729    if test "x$has_space" != x; then
43730      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43731$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43732      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43733    fi
43734
43735    # Use eval to expand a potential ~
43736    eval path="$path"
43737    if test ! -f "$path" && test ! -d "$path"; then
43738      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43739    fi
43740
43741    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
43742  fi
43743
43744
43745    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43746    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
43747$as_echo_n "checking for freetype includes... " >&6; }
43748    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
43749$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
43750    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43751    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
43752$as_echo_n "checking for freetype libraries... " >&6; }
43753    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
43754$as_echo "$FREETYPE_LIB_PATH" >&6; }
43755  fi
43756
43757        if test "x$FOUND_FREETYPE" != xyes; then
43758          as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
43759        fi
43760      else
43761        # User specified only one of lib or include. This is an error.
43762        if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
43763          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
43764$as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
43765          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43766        else
43767          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
43768$as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
43769          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43770        fi
43771      fi
43772    else
43773      # User did not specify settings, but we need freetype. Try to locate it.
43774
43775      if test "x$BUNDLE_FREETYPE" = x; then
43776        # If not specified, default is to bundle freetype only on windows
43777        if test "x$OPENJDK_TARGET_OS" = xwindows; then
43778          BUNDLE_FREETYPE=yes
43779        else
43780          BUNDLE_FREETYPE=no
43781        fi
43782      fi
43783
43784      if test "x$FOUND_FREETYPE" != xyes; then
43785        # Check builddeps
43786
43787
43788  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43789    # Source the builddeps file again, to make sure it uses the latest variables!
43790    . $builddepsfile
43791    # Look for a target and build machine specific resource!
43792    eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43793    if test "x$resource" = x; then
43794      # Ok, lets instead look for a target specific resource
43795      eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
43796    fi
43797    if test "x$resource" = x; then
43798      # Ok, lets instead look for a build specific resource
43799      eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
43800    fi
43801    if test "x$resource" = x; then
43802      # Ok, lets instead look for a generic resource
43803      # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
43804      resource=${builddep_freetype2}
43805    fi
43806    if test "x$resource" != x; then
43807      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
43808$as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
43809      # If the resource in the builddeps.conf file is an existing directory,
43810      # for example /java/linux/cups
43811      if test -d ${resource}; then
43812        depdir=${resource}
43813      else
43814
43815  # freetype2 is for example mymodule
43816  # $resource is for example libs/general/libmymod_1_2_3.zip
43817  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43818  # $with_builddeps_dir is for example /localhome/builddeps
43819  # depdir is the name of the variable into which we store the depdir, eg MYMOD
43820  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43821  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43822  filename=`basename $resource`
43823  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43824  filebase=${filename%%.*}
43825  extension=${filename#*.}
43826  installdir=$with_builddeps_dir/$filebase
43827  if test ! -f $installdir/$filename.unpacked; then
43828    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
43829$as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43830    if test ! -d $installdir; then
43831      mkdir -p $installdir
43832    fi
43833    if test ! -d $installdir; then
43834      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43835    fi
43836    tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
43837    touch $tmpfile
43838    if test ! -f $tmpfile; then
43839      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43840    fi
43841
43842  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43843  # $tmpfile is the local file name for the downloaded file.
43844  VALID_TOOL=no
43845  if test "x$BDEPS_FTP" = xwget; then
43846    VALID_TOOL=yes
43847    wget -O $tmpfile $with_builddeps_server/$resource
43848  fi
43849  if test "x$BDEPS_FTP" = xlftp; then
43850    VALID_TOOL=yes
43851    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43852  fi
43853  if test "x$BDEPS_FTP" = xftp; then
43854    VALID_TOOL=yes
43855    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43856    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43857    FTPUSERPWD=${FTPSERVER%%@*}
43858    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43859      FTPUSER=${userpwd%%:*}
43860      FTPPWD=${userpwd#*@}
43861      FTPSERVER=${FTPSERVER#*@}
43862    else
43863      FTPUSER=ftp
43864      FTPPWD=ftp
43865    fi
43866    # the "pass" command does not work on some
43867    # ftp clients (read ftp.exe) but if it works,
43868    # passive mode is better!
43869    ( \
43870        echo "user $FTPUSER $FTPPWD"        ; \
43871        echo "pass"                         ; \
43872        echo "bin"                          ; \
43873        echo "get $FTPPATH $tmpfile"              ; \
43874    ) | ftp -in $FTPSERVER
43875  fi
43876  if test "x$VALID_TOOL" != xyes; then
43877    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43878  fi
43879
43880    mv $tmpfile $installdir/$filename
43881    if test ! -s $installdir/$filename; then
43882      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43883    fi
43884    case "$extension" in
43885      zip)  echo "Unzipping $installdir/$filename..."
43886        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43887        ;;
43888      tar.gz) echo "Untaring $installdir/$filename..."
43889        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43890        ;;
43891      tgz) echo "Untaring $installdir/$filename..."
43892        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43893        ;;
43894      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43895        ;;
43896    esac
43897  fi
43898  if test -f $installdir/$filename.unpacked; then
43899    depdir=$installdir
43900  fi
43901
43902      fi
43903      # Source the builddeps file again, because in the previous command, the depdir
43904      # was updated to point at the current build dependency install directory.
43905      . $builddepsfile
43906      # Now extract variables from the builddeps.conf files.
43907      theroot=${builddep_freetype2_ROOT}
43908      thecflags=${builddep_freetype2_CFLAGS}
43909      thelibs=${builddep_freetype2_LIBS}
43910      if test "x$depdir" = x; then
43911        as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
43912      fi
43913      FREETYPE=$depdir
43914      if test "x$theroot" != x; then
43915        FREETYPE="$theroot"
43916      fi
43917      if test "x$thecflags" != x; then
43918        FREETYPE_CFLAGS="$thecflags"
43919      fi
43920      if test "x$thelibs" != x; then
43921        FREETYPE_LIBS="$thelibs"
43922      fi
43923      FOUND_FREETYPE=yes
43924      else FOUND_FREETYPE=no
43925
43926    fi
43927    else FOUND_FREETYPE=no
43928
43929  fi
43930
43931        # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43932        if test "x$FOUND_FREETYPE" = xyes; then
43933          if test "x$BUNDLE_FREETYPE" = xyes; then
43934            { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43935$as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43936            FOUND_FREETYPE=no
43937          else
43938            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43939$as_echo_n "checking for freetype... " >&6; }
43940            { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43941$as_echo "yes (using builddeps)" >&6; }
43942          fi
43943        fi
43944      fi
43945
43946      # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config.
43947      if test "x$SYSROOT" = x; then
43948        if test "x$FOUND_FREETYPE" != xyes; then
43949          # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43950          if test "x$PKG_CONFIG" != x; then
43951
43952pkg_failed=no
43953{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43954$as_echo_n "checking for FREETYPE... " >&6; }
43955
43956if test -n "$FREETYPE_CFLAGS"; then
43957    pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43958 elif test -n "$PKG_CONFIG"; then
43959    if test -n "$PKG_CONFIG" && \
43960    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43961  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43962  ac_status=$?
43963  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43964  test $ac_status = 0; }; then
43965  pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43966else
43967  pkg_failed=yes
43968fi
43969 else
43970    pkg_failed=untried
43971fi
43972if test -n "$FREETYPE_LIBS"; then
43973    pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
43974 elif test -n "$PKG_CONFIG"; then
43975    if test -n "$PKG_CONFIG" && \
43976    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43977  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43978  ac_status=$?
43979  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43980  test $ac_status = 0; }; then
43981  pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
43982else
43983  pkg_failed=yes
43984fi
43985 else
43986    pkg_failed=untried
43987fi
43988
43989
43990
43991if test $pkg_failed = yes; then
43992
43993if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
43994        _pkg_short_errors_supported=yes
43995else
43996        _pkg_short_errors_supported=no
43997fi
43998        if test $_pkg_short_errors_supported = yes; then
43999	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
44000        else
44001	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
44002        fi
44003	# Put the nasty error message in config.log where it belongs
44004	echo "$FREETYPE_PKG_ERRORS" >&5
44005
44006	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
44007$as_echo "no" >&6; }
44008                FOUND_FREETYPE=no
44009elif test $pkg_failed = untried; then
44010	FOUND_FREETYPE=no
44011else
44012	FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
44013	FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
44014        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
44015$as_echo "yes" >&6; }
44016	FOUND_FREETYPE=yes
44017fi
44018            if test "x$FOUND_FREETYPE" = xyes; then
44019              # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
44020              FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
44021              # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
44022              if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
44023                FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
44024              fi
44025              # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
44026              if test "x$BUNDLE_FREETYPE" = xyes; then
44027                { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
44028$as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
44029                FOUND_FREETYPE=no
44030              else
44031                { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
44032$as_echo_n "checking for freetype... " >&6; }
44033                { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
44034$as_echo "yes (using pkg-config)" >&6; }
44035              fi
44036            fi
44037          fi
44038        fi
44039      fi
44040
44041      if test "x$FOUND_FREETYPE" != xyes; then
44042        # Check in well-known locations
44043        if test "x$OPENJDK_TARGET_OS" = xwindows; then
44044          FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
44045
44046  windows_path="$FREETYPE_BASE_DIR"
44047  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44048    unix_path=`$CYGPATH -u "$windows_path"`
44049    FREETYPE_BASE_DIR="$unix_path"
44050  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44051    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44052    FREETYPE_BASE_DIR="$unix_path"
44053  fi
44054
44055
44056  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44057  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44058  METHOD="well-known location"
44059
44060  # First check if the files exists.
44061  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44062    # We found an arbitrary include file. That's a good sign.
44063    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44064$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44065    FOUND_FREETYPE=yes
44066
44067    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44068    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44069      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44070$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44071      FOUND_FREETYPE=no
44072    else
44073      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44074        # On Windows, we will need both .lib and .dll file.
44075        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44076          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44077$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44078          FOUND_FREETYPE=no
44079        fi
44080      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
44081        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44082        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44083      fi
44084    fi
44085  fi
44086
44087  if test "x$FOUND_FREETYPE" = xyes; then
44088
44089  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44090
44091  # Input might be given as Windows format, start by converting to
44092  # unix format.
44093  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44094  new_path=`$CYGPATH -u "$path"`
44095
44096  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44097  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44098  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44099  # "foo.exe" is OK but "foo" is an error.
44100  #
44101  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44102  # It is also a way to make sure we got the proper file name for the real test later on.
44103  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44104  if test "x$test_shortpath" = x; then
44105    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44106$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44107    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44108  fi
44109
44110  # Call helper function which possibly converts this using DOS-style short mode.
44111  # If so, the updated path is stored in $new_path.
44112
44113  input_path="$new_path"
44114  # Check if we need to convert this using DOS-style short mode. If the path
44115  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44116  # take no chances and rewrite it.
44117  # Note: m4 eats our [], so we need to use [ and ] instead.
44118  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44119  if test "x$has_forbidden_chars" != x; then
44120    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44121    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44122    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44123    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44124      # Going to short mode and back again did indeed matter. Since short mode is
44125      # case insensitive, let's make it lowercase to improve readability.
44126      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44127      # Now convert it back to Unix-stile (cygpath)
44128      input_path=`$CYGPATH -u "$shortmode_path"`
44129      new_path="$input_path"
44130    fi
44131  fi
44132
44133  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44134  if test "x$test_cygdrive_prefix" = x; then
44135    # As a simple fix, exclude /usr/bin since it's not a real path.
44136    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44137      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44138      # a path prefixed by /cygdrive for fixpath to work.
44139      new_path="$CYGWIN_ROOT_PATH$input_path"
44140    fi
44141  fi
44142
44143
44144  if test "x$path" != "x$new_path"; then
44145    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44146    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44147$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44148  fi
44149
44150  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44151
44152  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44153  has_colon=`$ECHO $path | $GREP ^.:`
44154  new_path="$path"
44155  if test "x$has_colon" = x; then
44156    # Not in mixed or Windows style, start by that.
44157    new_path=`cmd //c echo $path`
44158  fi
44159
44160
44161  input_path="$new_path"
44162  # Check if we need to convert this using DOS-style short mode. If the path
44163  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44164  # take no chances and rewrite it.
44165  # Note: m4 eats our [], so we need to use [ and ] instead.
44166  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44167  if test "x$has_forbidden_chars" != x; then
44168    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44169    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44170  fi
44171
44172
44173  windows_path="$new_path"
44174  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44175    unix_path=`$CYGPATH -u "$windows_path"`
44176    new_path="$unix_path"
44177  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44178    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44179    new_path="$unix_path"
44180  fi
44181
44182  if test "x$path" != "x$new_path"; then
44183    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44184    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44185$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44186  fi
44187
44188  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44189  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44190
44191  else
44192    # We're on a posix platform. Hooray! :)
44193    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44194    has_space=`$ECHO "$path" | $GREP " "`
44195    if test "x$has_space" != x; then
44196      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44197$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44198      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44199    fi
44200
44201    # Use eval to expand a potential ~
44202    eval path="$path"
44203    if test ! -f "$path" && test ! -d "$path"; then
44204      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44205    fi
44206
44207    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44208  fi
44209
44210
44211  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44212
44213  # Input might be given as Windows format, start by converting to
44214  # unix format.
44215  path="$POTENTIAL_FREETYPE_LIB_PATH"
44216  new_path=`$CYGPATH -u "$path"`
44217
44218  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44219  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44220  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44221  # "foo.exe" is OK but "foo" is an error.
44222  #
44223  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44224  # It is also a way to make sure we got the proper file name for the real test later on.
44225  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44226  if test "x$test_shortpath" = x; then
44227    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44228$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44229    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44230  fi
44231
44232  # Call helper function which possibly converts this using DOS-style short mode.
44233  # If so, the updated path is stored in $new_path.
44234
44235  input_path="$new_path"
44236  # Check if we need to convert this using DOS-style short mode. If the path
44237  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44238  # take no chances and rewrite it.
44239  # Note: m4 eats our [], so we need to use [ and ] instead.
44240  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44241  if test "x$has_forbidden_chars" != x; then
44242    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44243    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44244    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44245    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44246      # Going to short mode and back again did indeed matter. Since short mode is
44247      # case insensitive, let's make it lowercase to improve readability.
44248      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44249      # Now convert it back to Unix-stile (cygpath)
44250      input_path=`$CYGPATH -u "$shortmode_path"`
44251      new_path="$input_path"
44252    fi
44253  fi
44254
44255  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44256  if test "x$test_cygdrive_prefix" = x; then
44257    # As a simple fix, exclude /usr/bin since it's not a real path.
44258    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44259      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44260      # a path prefixed by /cygdrive for fixpath to work.
44261      new_path="$CYGWIN_ROOT_PATH$input_path"
44262    fi
44263  fi
44264
44265
44266  if test "x$path" != "x$new_path"; then
44267    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44268    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44269$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44270  fi
44271
44272  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44273
44274  path="$POTENTIAL_FREETYPE_LIB_PATH"
44275  has_colon=`$ECHO $path | $GREP ^.:`
44276  new_path="$path"
44277  if test "x$has_colon" = x; then
44278    # Not in mixed or Windows style, start by that.
44279    new_path=`cmd //c echo $path`
44280  fi
44281
44282
44283  input_path="$new_path"
44284  # Check if we need to convert this using DOS-style short mode. If the path
44285  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44286  # take no chances and rewrite it.
44287  # Note: m4 eats our [], so we need to use [ and ] instead.
44288  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44289  if test "x$has_forbidden_chars" != x; then
44290    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44291    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44292  fi
44293
44294
44295  windows_path="$new_path"
44296  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44297    unix_path=`$CYGPATH -u "$windows_path"`
44298    new_path="$unix_path"
44299  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44300    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44301    new_path="$unix_path"
44302  fi
44303
44304  if test "x$path" != "x$new_path"; then
44305    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44306    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44307$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44308  fi
44309
44310  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44311  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44312
44313  else
44314    # We're on a posix platform. Hooray! :)
44315    path="$POTENTIAL_FREETYPE_LIB_PATH"
44316    has_space=`$ECHO "$path" | $GREP " "`
44317    if test "x$has_space" != x; then
44318      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44319$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44320      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44321    fi
44322
44323    # Use eval to expand a potential ~
44324    eval path="$path"
44325    if test ! -f "$path" && test ! -d "$path"; then
44326      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44327    fi
44328
44329    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44330  fi
44331
44332
44333    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44334    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44335$as_echo_n "checking for freetype includes... " >&6; }
44336    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44337$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44338    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44339    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44340$as_echo_n "checking for freetype libraries... " >&6; }
44341    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44342$as_echo "$FREETYPE_LIB_PATH" >&6; }
44343  fi
44344
44345          if test "x$FOUND_FREETYPE" != xyes; then
44346            FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
44347
44348  windows_path="$FREETYPE_BASE_DIR"
44349  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44350    unix_path=`$CYGPATH -u "$windows_path"`
44351    FREETYPE_BASE_DIR="$unix_path"
44352  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44353    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44354    FREETYPE_BASE_DIR="$unix_path"
44355  fi
44356
44357
44358  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44359  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44360  METHOD="well-known location"
44361
44362  # First check if the files exists.
44363  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44364    # We found an arbitrary include file. That's a good sign.
44365    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44366$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44367    FOUND_FREETYPE=yes
44368
44369    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44370    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44371      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44372$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44373      FOUND_FREETYPE=no
44374    else
44375      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44376        # On Windows, we will need both .lib and .dll file.
44377        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44378          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44379$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44380          FOUND_FREETYPE=no
44381        fi
44382      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
44383        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44384        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44385      fi
44386    fi
44387  fi
44388
44389  if test "x$FOUND_FREETYPE" = xyes; then
44390
44391  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44392
44393  # Input might be given as Windows format, start by converting to
44394  # unix format.
44395  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44396  new_path=`$CYGPATH -u "$path"`
44397
44398  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44399  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44400  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44401  # "foo.exe" is OK but "foo" is an error.
44402  #
44403  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44404  # It is also a way to make sure we got the proper file name for the real test later on.
44405  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44406  if test "x$test_shortpath" = x; then
44407    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44408$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44409    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44410  fi
44411
44412  # Call helper function which possibly converts this using DOS-style short mode.
44413  # If so, the updated path is stored in $new_path.
44414
44415  input_path="$new_path"
44416  # Check if we need to convert this using DOS-style short mode. If the path
44417  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44418  # take no chances and rewrite it.
44419  # Note: m4 eats our [], so we need to use [ and ] instead.
44420  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44421  if test "x$has_forbidden_chars" != x; then
44422    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44423    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44424    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44425    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44426      # Going to short mode and back again did indeed matter. Since short mode is
44427      # case insensitive, let's make it lowercase to improve readability.
44428      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44429      # Now convert it back to Unix-stile (cygpath)
44430      input_path=`$CYGPATH -u "$shortmode_path"`
44431      new_path="$input_path"
44432    fi
44433  fi
44434
44435  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44436  if test "x$test_cygdrive_prefix" = x; then
44437    # As a simple fix, exclude /usr/bin since it's not a real path.
44438    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44439      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44440      # a path prefixed by /cygdrive for fixpath to work.
44441      new_path="$CYGWIN_ROOT_PATH$input_path"
44442    fi
44443  fi
44444
44445
44446  if test "x$path" != "x$new_path"; then
44447    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44448    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44449$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44450  fi
44451
44452  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44453
44454  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44455  has_colon=`$ECHO $path | $GREP ^.:`
44456  new_path="$path"
44457  if test "x$has_colon" = x; then
44458    # Not in mixed or Windows style, start by that.
44459    new_path=`cmd //c echo $path`
44460  fi
44461
44462
44463  input_path="$new_path"
44464  # Check if we need to convert this using DOS-style short mode. If the path
44465  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44466  # take no chances and rewrite it.
44467  # Note: m4 eats our [], so we need to use [ and ] instead.
44468  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44469  if test "x$has_forbidden_chars" != x; then
44470    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44471    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44472  fi
44473
44474
44475  windows_path="$new_path"
44476  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44477    unix_path=`$CYGPATH -u "$windows_path"`
44478    new_path="$unix_path"
44479  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44480    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44481    new_path="$unix_path"
44482  fi
44483
44484  if test "x$path" != "x$new_path"; then
44485    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44486    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44487$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44488  fi
44489
44490  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44491  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44492
44493  else
44494    # We're on a posix platform. Hooray! :)
44495    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44496    has_space=`$ECHO "$path" | $GREP " "`
44497    if test "x$has_space" != x; then
44498      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44499$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44500      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44501    fi
44502
44503    # Use eval to expand a potential ~
44504    eval path="$path"
44505    if test ! -f "$path" && test ! -d "$path"; then
44506      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44507    fi
44508
44509    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44510  fi
44511
44512
44513  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44514
44515  # Input might be given as Windows format, start by converting to
44516  # unix format.
44517  path="$POTENTIAL_FREETYPE_LIB_PATH"
44518  new_path=`$CYGPATH -u "$path"`
44519
44520  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44521  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44522  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44523  # "foo.exe" is OK but "foo" is an error.
44524  #
44525  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44526  # It is also a way to make sure we got the proper file name for the real test later on.
44527  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44528  if test "x$test_shortpath" = x; then
44529    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44530$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44531    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44532  fi
44533
44534  # Call helper function which possibly converts this using DOS-style short mode.
44535  # If so, the updated path is stored in $new_path.
44536
44537  input_path="$new_path"
44538  # Check if we need to convert this using DOS-style short mode. If the path
44539  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44540  # take no chances and rewrite it.
44541  # Note: m4 eats our [], so we need to use [ and ] instead.
44542  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44543  if test "x$has_forbidden_chars" != x; then
44544    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44545    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44546    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44547    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44548      # Going to short mode and back again did indeed matter. Since short mode is
44549      # case insensitive, let's make it lowercase to improve readability.
44550      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44551      # Now convert it back to Unix-stile (cygpath)
44552      input_path=`$CYGPATH -u "$shortmode_path"`
44553      new_path="$input_path"
44554    fi
44555  fi
44556
44557  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44558  if test "x$test_cygdrive_prefix" = x; then
44559    # As a simple fix, exclude /usr/bin since it's not a real path.
44560    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44561      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44562      # a path prefixed by /cygdrive for fixpath to work.
44563      new_path="$CYGWIN_ROOT_PATH$input_path"
44564    fi
44565  fi
44566
44567
44568  if test "x$path" != "x$new_path"; then
44569    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44570    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44571$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44572  fi
44573
44574  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44575
44576  path="$POTENTIAL_FREETYPE_LIB_PATH"
44577  has_colon=`$ECHO $path | $GREP ^.:`
44578  new_path="$path"
44579  if test "x$has_colon" = x; then
44580    # Not in mixed or Windows style, start by that.
44581    new_path=`cmd //c echo $path`
44582  fi
44583
44584
44585  input_path="$new_path"
44586  # Check if we need to convert this using DOS-style short mode. If the path
44587  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44588  # take no chances and rewrite it.
44589  # Note: m4 eats our [], so we need to use [ and ] instead.
44590  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44591  if test "x$has_forbidden_chars" != x; then
44592    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44593    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44594  fi
44595
44596
44597  windows_path="$new_path"
44598  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44599    unix_path=`$CYGPATH -u "$windows_path"`
44600    new_path="$unix_path"
44601  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44602    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44603    new_path="$unix_path"
44604  fi
44605
44606  if test "x$path" != "x$new_path"; then
44607    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44608    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44609$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44610  fi
44611
44612  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44613  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44614
44615  else
44616    # We're on a posix platform. Hooray! :)
44617    path="$POTENTIAL_FREETYPE_LIB_PATH"
44618    has_space=`$ECHO "$path" | $GREP " "`
44619    if test "x$has_space" != x; then
44620      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44621$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44622      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44623    fi
44624
44625    # Use eval to expand a potential ~
44626    eval path="$path"
44627    if test ! -f "$path" && test ! -d "$path"; then
44628      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44629    fi
44630
44631    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44632  fi
44633
44634
44635    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44636    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44637$as_echo_n "checking for freetype includes... " >&6; }
44638    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44639$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44640    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44641    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44642$as_echo_n "checking for freetype libraries... " >&6; }
44643    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44644$as_echo "$FREETYPE_LIB_PATH" >&6; }
44645  fi
44646
44647          fi
44648        else
44649          FREETYPE_BASE_DIR="$SYSROOT/usr"
44650
44651  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44652  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44653  METHOD="well-known location"
44654
44655  # First check if the files exists.
44656  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44657    # We found an arbitrary include file. That's a good sign.
44658    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44659$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44660    FOUND_FREETYPE=yes
44661
44662    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44663    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44664      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44665$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44666      FOUND_FREETYPE=no
44667    else
44668      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44669        # On Windows, we will need both .lib and .dll file.
44670        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44671          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44672$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44673          FOUND_FREETYPE=no
44674        fi
44675      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
44676        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44677        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44678      fi
44679    fi
44680  fi
44681
44682  if test "x$FOUND_FREETYPE" = xyes; then
44683
44684  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44685
44686  # Input might be given as Windows format, start by converting to
44687  # unix format.
44688  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44689  new_path=`$CYGPATH -u "$path"`
44690
44691  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44692  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44693  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44694  # "foo.exe" is OK but "foo" is an error.
44695  #
44696  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44697  # It is also a way to make sure we got the proper file name for the real test later on.
44698  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44699  if test "x$test_shortpath" = x; then
44700    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44701$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44702    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44703  fi
44704
44705  # Call helper function which possibly converts this using DOS-style short mode.
44706  # If so, the updated path is stored in $new_path.
44707
44708  input_path="$new_path"
44709  # Check if we need to convert this using DOS-style short mode. If the path
44710  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44711  # take no chances and rewrite it.
44712  # Note: m4 eats our [], so we need to use [ and ] instead.
44713  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44714  if test "x$has_forbidden_chars" != x; then
44715    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44716    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44717    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44718    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44719      # Going to short mode and back again did indeed matter. Since short mode is
44720      # case insensitive, let's make it lowercase to improve readability.
44721      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44722      # Now convert it back to Unix-stile (cygpath)
44723      input_path=`$CYGPATH -u "$shortmode_path"`
44724      new_path="$input_path"
44725    fi
44726  fi
44727
44728  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44729  if test "x$test_cygdrive_prefix" = x; then
44730    # As a simple fix, exclude /usr/bin since it's not a real path.
44731    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44732      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44733      # a path prefixed by /cygdrive for fixpath to work.
44734      new_path="$CYGWIN_ROOT_PATH$input_path"
44735    fi
44736  fi
44737
44738
44739  if test "x$path" != "x$new_path"; then
44740    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44741    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44742$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44743  fi
44744
44745  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44746
44747  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44748  has_colon=`$ECHO $path | $GREP ^.:`
44749  new_path="$path"
44750  if test "x$has_colon" = x; then
44751    # Not in mixed or Windows style, start by that.
44752    new_path=`cmd //c echo $path`
44753  fi
44754
44755
44756  input_path="$new_path"
44757  # Check if we need to convert this using DOS-style short mode. If the path
44758  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44759  # take no chances and rewrite it.
44760  # Note: m4 eats our [], so we need to use [ and ] instead.
44761  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44762  if test "x$has_forbidden_chars" != x; then
44763    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44764    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44765  fi
44766
44767
44768  windows_path="$new_path"
44769  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44770    unix_path=`$CYGPATH -u "$windows_path"`
44771    new_path="$unix_path"
44772  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44773    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44774    new_path="$unix_path"
44775  fi
44776
44777  if test "x$path" != "x$new_path"; then
44778    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44779    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44780$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44781  fi
44782
44783  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44784  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44785
44786  else
44787    # We're on a posix platform. Hooray! :)
44788    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44789    has_space=`$ECHO "$path" | $GREP " "`
44790    if test "x$has_space" != x; then
44791      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44792$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44793      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44794    fi
44795
44796    # Use eval to expand a potential ~
44797    eval path="$path"
44798    if test ! -f "$path" && test ! -d "$path"; then
44799      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44800    fi
44801
44802    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44803  fi
44804
44805
44806  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44807
44808  # Input might be given as Windows format, start by converting to
44809  # unix format.
44810  path="$POTENTIAL_FREETYPE_LIB_PATH"
44811  new_path=`$CYGPATH -u "$path"`
44812
44813  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44814  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44815  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44816  # "foo.exe" is OK but "foo" is an error.
44817  #
44818  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44819  # It is also a way to make sure we got the proper file name for the real test later on.
44820  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44821  if test "x$test_shortpath" = x; then
44822    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44823$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44824    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44825  fi
44826
44827  # Call helper function which possibly converts this using DOS-style short mode.
44828  # If so, the updated path is stored in $new_path.
44829
44830  input_path="$new_path"
44831  # Check if we need to convert this using DOS-style short mode. If the path
44832  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44833  # take no chances and rewrite it.
44834  # Note: m4 eats our [], so we need to use [ and ] instead.
44835  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44836  if test "x$has_forbidden_chars" != x; then
44837    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44838    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44839    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44840    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44841      # Going to short mode and back again did indeed matter. Since short mode is
44842      # case insensitive, let's make it lowercase to improve readability.
44843      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44844      # Now convert it back to Unix-stile (cygpath)
44845      input_path=`$CYGPATH -u "$shortmode_path"`
44846      new_path="$input_path"
44847    fi
44848  fi
44849
44850  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44851  if test "x$test_cygdrive_prefix" = x; then
44852    # As a simple fix, exclude /usr/bin since it's not a real path.
44853    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44854      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44855      # a path prefixed by /cygdrive for fixpath to work.
44856      new_path="$CYGWIN_ROOT_PATH$input_path"
44857    fi
44858  fi
44859
44860
44861  if test "x$path" != "x$new_path"; then
44862    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44863    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44864$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44865  fi
44866
44867  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44868
44869  path="$POTENTIAL_FREETYPE_LIB_PATH"
44870  has_colon=`$ECHO $path | $GREP ^.:`
44871  new_path="$path"
44872  if test "x$has_colon" = x; then
44873    # Not in mixed or Windows style, start by that.
44874    new_path=`cmd //c echo $path`
44875  fi
44876
44877
44878  input_path="$new_path"
44879  # Check if we need to convert this using DOS-style short mode. If the path
44880  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44881  # take no chances and rewrite it.
44882  # Note: m4 eats our [], so we need to use [ and ] instead.
44883  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44884  if test "x$has_forbidden_chars" != x; then
44885    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44886    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44887  fi
44888
44889
44890  windows_path="$new_path"
44891  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44892    unix_path=`$CYGPATH -u "$windows_path"`
44893    new_path="$unix_path"
44894  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44895    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44896    new_path="$unix_path"
44897  fi
44898
44899  if test "x$path" != "x$new_path"; then
44900    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44901    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44902$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44903  fi
44904
44905  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44906  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44907
44908  else
44909    # We're on a posix platform. Hooray! :)
44910    path="$POTENTIAL_FREETYPE_LIB_PATH"
44911    has_space=`$ECHO "$path" | $GREP " "`
44912    if test "x$has_space" != x; then
44913      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44914$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44915      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44916    fi
44917
44918    # Use eval to expand a potential ~
44919    eval path="$path"
44920    if test ! -f "$path" && test ! -d "$path"; then
44921      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44922    fi
44923
44924    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44925  fi
44926
44927
44928    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44929    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44930$as_echo_n "checking for freetype includes... " >&6; }
44931    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44932$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44933    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44934    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44935$as_echo_n "checking for freetype libraries... " >&6; }
44936    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44937$as_echo "$FREETYPE_LIB_PATH" >&6; }
44938  fi
44939
44940
44941          if test "x$FOUND_FREETYPE" != xyes; then
44942            FREETYPE_BASE_DIR="$SYSROOT/usr/X11"
44943
44944  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44945  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44946  METHOD="well-known location"
44947
44948  # First check if the files exists.
44949  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44950    # We found an arbitrary include file. That's a good sign.
44951    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44952$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44953    FOUND_FREETYPE=yes
44954
44955    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44956    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44957      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44958$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44959      FOUND_FREETYPE=no
44960    else
44961      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44962        # On Windows, we will need both .lib and .dll file.
44963        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44964          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44965$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44966          FOUND_FREETYPE=no
44967        fi
44968      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
44969        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44970        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44971      fi
44972    fi
44973  fi
44974
44975  if test "x$FOUND_FREETYPE" = xyes; then
44976
44977  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44978
44979  # Input might be given as Windows format, start by converting to
44980  # unix format.
44981  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44982  new_path=`$CYGPATH -u "$path"`
44983
44984  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44985  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44986  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44987  # "foo.exe" is OK but "foo" is an error.
44988  #
44989  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44990  # It is also a way to make sure we got the proper file name for the real test later on.
44991  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44992  if test "x$test_shortpath" = x; then
44993    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44994$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44995    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44996  fi
44997
44998  # Call helper function which possibly converts this using DOS-style short mode.
44999  # If so, the updated path is stored in $new_path.
45000
45001  input_path="$new_path"
45002  # Check if we need to convert this using DOS-style short mode. If the path
45003  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45004  # take no chances and rewrite it.
45005  # Note: m4 eats our [], so we need to use [ and ] instead.
45006  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45007  if test "x$has_forbidden_chars" != x; then
45008    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45009    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45010    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45011    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45012      # Going to short mode and back again did indeed matter. Since short mode is
45013      # case insensitive, let's make it lowercase to improve readability.
45014      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45015      # Now convert it back to Unix-stile (cygpath)
45016      input_path=`$CYGPATH -u "$shortmode_path"`
45017      new_path="$input_path"
45018    fi
45019  fi
45020
45021  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45022  if test "x$test_cygdrive_prefix" = x; then
45023    # As a simple fix, exclude /usr/bin since it's not a real path.
45024    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45025      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45026      # a path prefixed by /cygdrive for fixpath to work.
45027      new_path="$CYGWIN_ROOT_PATH$input_path"
45028    fi
45029  fi
45030
45031
45032  if test "x$path" != "x$new_path"; then
45033    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45034    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45035$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45036  fi
45037
45038  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45039
45040  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45041  has_colon=`$ECHO $path | $GREP ^.:`
45042  new_path="$path"
45043  if test "x$has_colon" = x; then
45044    # Not in mixed or Windows style, start by that.
45045    new_path=`cmd //c echo $path`
45046  fi
45047
45048
45049  input_path="$new_path"
45050  # Check if we need to convert this using DOS-style short mode. If the path
45051  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45052  # take no chances and rewrite it.
45053  # Note: m4 eats our [], so we need to use [ and ] instead.
45054  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45055  if test "x$has_forbidden_chars" != x; then
45056    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45057    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45058  fi
45059
45060
45061  windows_path="$new_path"
45062  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45063    unix_path=`$CYGPATH -u "$windows_path"`
45064    new_path="$unix_path"
45065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45066    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45067    new_path="$unix_path"
45068  fi
45069
45070  if test "x$path" != "x$new_path"; then
45071    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45072    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45073$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45074  fi
45075
45076  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45077  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45078
45079  else
45080    # We're on a posix platform. Hooray! :)
45081    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45082    has_space=`$ECHO "$path" | $GREP " "`
45083    if test "x$has_space" != x; then
45084      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45085$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45086      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45087    fi
45088
45089    # Use eval to expand a potential ~
45090    eval path="$path"
45091    if test ! -f "$path" && test ! -d "$path"; then
45092      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45093    fi
45094
45095    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45096  fi
45097
45098
45099  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45100
45101  # Input might be given as Windows format, start by converting to
45102  # unix format.
45103  path="$POTENTIAL_FREETYPE_LIB_PATH"
45104  new_path=`$CYGPATH -u "$path"`
45105
45106  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45107  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45108  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45109  # "foo.exe" is OK but "foo" is an error.
45110  #
45111  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45112  # It is also a way to make sure we got the proper file name for the real test later on.
45113  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45114  if test "x$test_shortpath" = x; then
45115    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45116$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45117    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45118  fi
45119
45120  # Call helper function which possibly converts this using DOS-style short mode.
45121  # If so, the updated path is stored in $new_path.
45122
45123  input_path="$new_path"
45124  # Check if we need to convert this using DOS-style short mode. If the path
45125  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45126  # take no chances and rewrite it.
45127  # Note: m4 eats our [], so we need to use [ and ] instead.
45128  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45129  if test "x$has_forbidden_chars" != x; then
45130    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45131    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45132    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45133    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45134      # Going to short mode and back again did indeed matter. Since short mode is
45135      # case insensitive, let's make it lowercase to improve readability.
45136      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45137      # Now convert it back to Unix-stile (cygpath)
45138      input_path=`$CYGPATH -u "$shortmode_path"`
45139      new_path="$input_path"
45140    fi
45141  fi
45142
45143  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45144  if test "x$test_cygdrive_prefix" = x; then
45145    # As a simple fix, exclude /usr/bin since it's not a real path.
45146    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45147      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45148      # a path prefixed by /cygdrive for fixpath to work.
45149      new_path="$CYGWIN_ROOT_PATH$input_path"
45150    fi
45151  fi
45152
45153
45154  if test "x$path" != "x$new_path"; then
45155    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45156    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45157$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45158  fi
45159
45160  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45161
45162  path="$POTENTIAL_FREETYPE_LIB_PATH"
45163  has_colon=`$ECHO $path | $GREP ^.:`
45164  new_path="$path"
45165  if test "x$has_colon" = x; then
45166    # Not in mixed or Windows style, start by that.
45167    new_path=`cmd //c echo $path`
45168  fi
45169
45170
45171  input_path="$new_path"
45172  # Check if we need to convert this using DOS-style short mode. If the path
45173  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45174  # take no chances and rewrite it.
45175  # Note: m4 eats our [], so we need to use [ and ] instead.
45176  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45177  if test "x$has_forbidden_chars" != x; then
45178    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45179    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45180  fi
45181
45182
45183  windows_path="$new_path"
45184  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45185    unix_path=`$CYGPATH -u "$windows_path"`
45186    new_path="$unix_path"
45187  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45188    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45189    new_path="$unix_path"
45190  fi
45191
45192  if test "x$path" != "x$new_path"; then
45193    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45194    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45195$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45196  fi
45197
45198  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45199  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45200
45201  else
45202    # We're on a posix platform. Hooray! :)
45203    path="$POTENTIAL_FREETYPE_LIB_PATH"
45204    has_space=`$ECHO "$path" | $GREP " "`
45205    if test "x$has_space" != x; then
45206      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45207$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45208      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45209    fi
45210
45211    # Use eval to expand a potential ~
45212    eval path="$path"
45213    if test ! -f "$path" && test ! -d "$path"; then
45214      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45215    fi
45216
45217    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45218  fi
45219
45220
45221    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45222    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45223$as_echo_n "checking for freetype includes... " >&6; }
45224    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45225$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45226    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45227    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45228$as_echo_n "checking for freetype libraries... " >&6; }
45229    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45230$as_echo "$FREETYPE_LIB_PATH" >&6; }
45231  fi
45232
45233          fi
45234
45235          if test "x$FOUND_FREETYPE" != xyes; then
45236            FREETYPE_BASE_DIR="$SYSROOT/usr/sfw"
45237
45238  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45239  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
45240  METHOD="well-known location"
45241
45242  # First check if the files exists.
45243  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45244    # We found an arbitrary include file. That's a good sign.
45245    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45246$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45247    FOUND_FREETYPE=yes
45248
45249    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45250    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45251      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45252$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45253      FOUND_FREETYPE=no
45254    else
45255      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45256        # On Windows, we will need both .lib and .dll file.
45257        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45258          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45259$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45260          FOUND_FREETYPE=no
45261        fi
45262      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
45263        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45264        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45265      fi
45266    fi
45267  fi
45268
45269  if test "x$FOUND_FREETYPE" = xyes; then
45270
45271  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45272
45273  # Input might be given as Windows format, start by converting to
45274  # unix format.
45275  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45276  new_path=`$CYGPATH -u "$path"`
45277
45278  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45279  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45280  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45281  # "foo.exe" is OK but "foo" is an error.
45282  #
45283  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45284  # It is also a way to make sure we got the proper file name for the real test later on.
45285  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45286  if test "x$test_shortpath" = x; then
45287    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45288$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45289    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45290  fi
45291
45292  # Call helper function which possibly converts this using DOS-style short mode.
45293  # If so, the updated path is stored in $new_path.
45294
45295  input_path="$new_path"
45296  # Check if we need to convert this using DOS-style short mode. If the path
45297  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45298  # take no chances and rewrite it.
45299  # Note: m4 eats our [], so we need to use [ and ] instead.
45300  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45301  if test "x$has_forbidden_chars" != x; then
45302    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45303    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45304    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45305    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45306      # Going to short mode and back again did indeed matter. Since short mode is
45307      # case insensitive, let's make it lowercase to improve readability.
45308      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45309      # Now convert it back to Unix-stile (cygpath)
45310      input_path=`$CYGPATH -u "$shortmode_path"`
45311      new_path="$input_path"
45312    fi
45313  fi
45314
45315  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45316  if test "x$test_cygdrive_prefix" = x; then
45317    # As a simple fix, exclude /usr/bin since it's not a real path.
45318    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45319      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45320      # a path prefixed by /cygdrive for fixpath to work.
45321      new_path="$CYGWIN_ROOT_PATH$input_path"
45322    fi
45323  fi
45324
45325
45326  if test "x$path" != "x$new_path"; then
45327    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45328    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45329$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45330  fi
45331
45332  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45333
45334  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45335  has_colon=`$ECHO $path | $GREP ^.:`
45336  new_path="$path"
45337  if test "x$has_colon" = x; then
45338    # Not in mixed or Windows style, start by that.
45339    new_path=`cmd //c echo $path`
45340  fi
45341
45342
45343  input_path="$new_path"
45344  # Check if we need to convert this using DOS-style short mode. If the path
45345  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45346  # take no chances and rewrite it.
45347  # Note: m4 eats our [], so we need to use [ and ] instead.
45348  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45349  if test "x$has_forbidden_chars" != x; then
45350    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45351    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45352  fi
45353
45354
45355  windows_path="$new_path"
45356  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45357    unix_path=`$CYGPATH -u "$windows_path"`
45358    new_path="$unix_path"
45359  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45360    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45361    new_path="$unix_path"
45362  fi
45363
45364  if test "x$path" != "x$new_path"; then
45365    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45366    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45367$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45368  fi
45369
45370  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45371  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45372
45373  else
45374    # We're on a posix platform. Hooray! :)
45375    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45376    has_space=`$ECHO "$path" | $GREP " "`
45377    if test "x$has_space" != x; then
45378      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45379$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45380      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45381    fi
45382
45383    # Use eval to expand a potential ~
45384    eval path="$path"
45385    if test ! -f "$path" && test ! -d "$path"; then
45386      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45387    fi
45388
45389    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45390  fi
45391
45392
45393  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45394
45395  # Input might be given as Windows format, start by converting to
45396  # unix format.
45397  path="$POTENTIAL_FREETYPE_LIB_PATH"
45398  new_path=`$CYGPATH -u "$path"`
45399
45400  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45401  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45402  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45403  # "foo.exe" is OK but "foo" is an error.
45404  #
45405  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45406  # It is also a way to make sure we got the proper file name for the real test later on.
45407  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45408  if test "x$test_shortpath" = x; then
45409    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45410$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45411    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45412  fi
45413
45414  # Call helper function which possibly converts this using DOS-style short mode.
45415  # If so, the updated path is stored in $new_path.
45416
45417  input_path="$new_path"
45418  # Check if we need to convert this using DOS-style short mode. If the path
45419  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45420  # take no chances and rewrite it.
45421  # Note: m4 eats our [], so we need to use [ and ] instead.
45422  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45423  if test "x$has_forbidden_chars" != x; then
45424    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45425    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45426    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45427    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45428      # Going to short mode and back again did indeed matter. Since short mode is
45429      # case insensitive, let's make it lowercase to improve readability.
45430      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45431      # Now convert it back to Unix-stile (cygpath)
45432      input_path=`$CYGPATH -u "$shortmode_path"`
45433      new_path="$input_path"
45434    fi
45435  fi
45436
45437  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45438  if test "x$test_cygdrive_prefix" = x; then
45439    # As a simple fix, exclude /usr/bin since it's not a real path.
45440    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45441      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45442      # a path prefixed by /cygdrive for fixpath to work.
45443      new_path="$CYGWIN_ROOT_PATH$input_path"
45444    fi
45445  fi
45446
45447
45448  if test "x$path" != "x$new_path"; then
45449    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45450    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45451$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45452  fi
45453
45454  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45455
45456  path="$POTENTIAL_FREETYPE_LIB_PATH"
45457  has_colon=`$ECHO $path | $GREP ^.:`
45458  new_path="$path"
45459  if test "x$has_colon" = x; then
45460    # Not in mixed or Windows style, start by that.
45461    new_path=`cmd //c echo $path`
45462  fi
45463
45464
45465  input_path="$new_path"
45466  # Check if we need to convert this using DOS-style short mode. If the path
45467  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45468  # take no chances and rewrite it.
45469  # Note: m4 eats our [], so we need to use [ and ] instead.
45470  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45471  if test "x$has_forbidden_chars" != x; then
45472    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45473    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45474  fi
45475
45476
45477  windows_path="$new_path"
45478  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45479    unix_path=`$CYGPATH -u "$windows_path"`
45480    new_path="$unix_path"
45481  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45482    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45483    new_path="$unix_path"
45484  fi
45485
45486  if test "x$path" != "x$new_path"; then
45487    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45488    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45489$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45490  fi
45491
45492  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45493  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45494
45495  else
45496    # We're on a posix platform. Hooray! :)
45497    path="$POTENTIAL_FREETYPE_LIB_PATH"
45498    has_space=`$ECHO "$path" | $GREP " "`
45499    if test "x$has_space" != x; then
45500      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45501$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45502      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45503    fi
45504
45505    # Use eval to expand a potential ~
45506    eval path="$path"
45507    if test ! -f "$path" && test ! -d "$path"; then
45508      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45509    fi
45510
45511    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45512  fi
45513
45514
45515    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45516    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45517$as_echo_n "checking for freetype includes... " >&6; }
45518    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45519$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45520    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45521    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45522$as_echo_n "checking for freetype libraries... " >&6; }
45523    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45524$as_echo "$FREETYPE_LIB_PATH" >&6; }
45525  fi
45526
45527          fi
45528
45529          if test "x$FOUND_FREETYPE" != xyes; then
45530            FREETYPE_BASE_DIR="$SYSROOT/usr"
45531            if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45532
45533  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45534  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45535  METHOD="well-known location"
45536
45537  # First check if the files exists.
45538  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45539    # We found an arbitrary include file. That's a good sign.
45540    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45541$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45542    FOUND_FREETYPE=yes
45543
45544    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45545    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45546      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45547$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45548      FOUND_FREETYPE=no
45549    else
45550      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45551        # On Windows, we will need both .lib and .dll file.
45552        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45553          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45554$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45555          FOUND_FREETYPE=no
45556        fi
45557      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
45558        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45559        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45560      fi
45561    fi
45562  fi
45563
45564  if test "x$FOUND_FREETYPE" = xyes; then
45565
45566  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45567
45568  # Input might be given as Windows format, start by converting to
45569  # unix format.
45570  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45571  new_path=`$CYGPATH -u "$path"`
45572
45573  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45574  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45575  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45576  # "foo.exe" is OK but "foo" is an error.
45577  #
45578  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45579  # It is also a way to make sure we got the proper file name for the real test later on.
45580  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45581  if test "x$test_shortpath" = x; then
45582    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45583$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45584    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45585  fi
45586
45587  # Call helper function which possibly converts this using DOS-style short mode.
45588  # If so, the updated path is stored in $new_path.
45589
45590  input_path="$new_path"
45591  # Check if we need to convert this using DOS-style short mode. If the path
45592  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45593  # take no chances and rewrite it.
45594  # Note: m4 eats our [], so we need to use [ and ] instead.
45595  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45596  if test "x$has_forbidden_chars" != x; then
45597    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45598    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45599    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45600    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45601      # Going to short mode and back again did indeed matter. Since short mode is
45602      # case insensitive, let's make it lowercase to improve readability.
45603      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45604      # Now convert it back to Unix-stile (cygpath)
45605      input_path=`$CYGPATH -u "$shortmode_path"`
45606      new_path="$input_path"
45607    fi
45608  fi
45609
45610  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45611  if test "x$test_cygdrive_prefix" = x; then
45612    # As a simple fix, exclude /usr/bin since it's not a real path.
45613    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45614      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45615      # a path prefixed by /cygdrive for fixpath to work.
45616      new_path="$CYGWIN_ROOT_PATH$input_path"
45617    fi
45618  fi
45619
45620
45621  if test "x$path" != "x$new_path"; then
45622    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45623    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45624$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45625  fi
45626
45627  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45628
45629  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45630  has_colon=`$ECHO $path | $GREP ^.:`
45631  new_path="$path"
45632  if test "x$has_colon" = x; then
45633    # Not in mixed or Windows style, start by that.
45634    new_path=`cmd //c echo $path`
45635  fi
45636
45637
45638  input_path="$new_path"
45639  # Check if we need to convert this using DOS-style short mode. If the path
45640  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45641  # take no chances and rewrite it.
45642  # Note: m4 eats our [], so we need to use [ and ] instead.
45643  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45644  if test "x$has_forbidden_chars" != x; then
45645    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45646    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45647  fi
45648
45649
45650  windows_path="$new_path"
45651  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45652    unix_path=`$CYGPATH -u "$windows_path"`
45653    new_path="$unix_path"
45654  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45655    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45656    new_path="$unix_path"
45657  fi
45658
45659  if test "x$path" != "x$new_path"; then
45660    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45661    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45662$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45663  fi
45664
45665  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45666  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45667
45668  else
45669    # We're on a posix platform. Hooray! :)
45670    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45671    has_space=`$ECHO "$path" | $GREP " "`
45672    if test "x$has_space" != x; then
45673      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45674$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45675      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45676    fi
45677
45678    # Use eval to expand a potential ~
45679    eval path="$path"
45680    if test ! -f "$path" && test ! -d "$path"; then
45681      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45682    fi
45683
45684    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45685  fi
45686
45687
45688  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45689
45690  # Input might be given as Windows format, start by converting to
45691  # unix format.
45692  path="$POTENTIAL_FREETYPE_LIB_PATH"
45693  new_path=`$CYGPATH -u "$path"`
45694
45695  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45696  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45697  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45698  # "foo.exe" is OK but "foo" is an error.
45699  #
45700  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45701  # It is also a way to make sure we got the proper file name for the real test later on.
45702  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45703  if test "x$test_shortpath" = x; then
45704    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45705$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45706    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45707  fi
45708
45709  # Call helper function which possibly converts this using DOS-style short mode.
45710  # If so, the updated path is stored in $new_path.
45711
45712  input_path="$new_path"
45713  # Check if we need to convert this using DOS-style short mode. If the path
45714  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45715  # take no chances and rewrite it.
45716  # Note: m4 eats our [], so we need to use [ and ] instead.
45717  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45718  if test "x$has_forbidden_chars" != x; then
45719    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45720    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45721    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45722    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45723      # Going to short mode and back again did indeed matter. Since short mode is
45724      # case insensitive, let's make it lowercase to improve readability.
45725      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45726      # Now convert it back to Unix-stile (cygpath)
45727      input_path=`$CYGPATH -u "$shortmode_path"`
45728      new_path="$input_path"
45729    fi
45730  fi
45731
45732  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45733  if test "x$test_cygdrive_prefix" = x; then
45734    # As a simple fix, exclude /usr/bin since it's not a real path.
45735    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45736      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45737      # a path prefixed by /cygdrive for fixpath to work.
45738      new_path="$CYGWIN_ROOT_PATH$input_path"
45739    fi
45740  fi
45741
45742
45743  if test "x$path" != "x$new_path"; then
45744    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45745    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45746$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45747  fi
45748
45749  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45750
45751  path="$POTENTIAL_FREETYPE_LIB_PATH"
45752  has_colon=`$ECHO $path | $GREP ^.:`
45753  new_path="$path"
45754  if test "x$has_colon" = x; then
45755    # Not in mixed or Windows style, start by that.
45756    new_path=`cmd //c echo $path`
45757  fi
45758
45759
45760  input_path="$new_path"
45761  # Check if we need to convert this using DOS-style short mode. If the path
45762  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45763  # take no chances and rewrite it.
45764  # Note: m4 eats our [], so we need to use [ and ] instead.
45765  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45766  if test "x$has_forbidden_chars" != x; then
45767    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45768    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45769  fi
45770
45771
45772  windows_path="$new_path"
45773  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45774    unix_path=`$CYGPATH -u "$windows_path"`
45775    new_path="$unix_path"
45776  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45777    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45778    new_path="$unix_path"
45779  fi
45780
45781  if test "x$path" != "x$new_path"; then
45782    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45783    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45784$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45785  fi
45786
45787  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45788  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45789
45790  else
45791    # We're on a posix platform. Hooray! :)
45792    path="$POTENTIAL_FREETYPE_LIB_PATH"
45793    has_space=`$ECHO "$path" | $GREP " "`
45794    if test "x$has_space" != x; then
45795      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45796$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45797      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45798    fi
45799
45800    # Use eval to expand a potential ~
45801    eval path="$path"
45802    if test ! -f "$path" && test ! -d "$path"; then
45803      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45804    fi
45805
45806    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45807  fi
45808
45809
45810    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45811    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45812$as_echo_n "checking for freetype includes... " >&6; }
45813    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45814$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45815    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45816    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45817$as_echo_n "checking for freetype libraries... " >&6; }
45818    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45819$as_echo "$FREETYPE_LIB_PATH" >&6; }
45820  fi
45821
45822            else
45823
45824  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45825  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
45826  METHOD="well-known location"
45827
45828  # First check if the files exists.
45829  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45830    # We found an arbitrary include file. That's a good sign.
45831    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45832$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45833    FOUND_FREETYPE=yes
45834
45835    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45836    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45837      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45838$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45839      FOUND_FREETYPE=no
45840    else
45841      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45842        # On Windows, we will need both .lib and .dll file.
45843        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45844          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45845$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45846          FOUND_FREETYPE=no
45847        fi
45848      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
45849        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45850        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45851      fi
45852    fi
45853  fi
45854
45855  if test "x$FOUND_FREETYPE" = xyes; then
45856
45857  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45858
45859  # Input might be given as Windows format, start by converting to
45860  # unix format.
45861  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45862  new_path=`$CYGPATH -u "$path"`
45863
45864  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45865  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45866  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45867  # "foo.exe" is OK but "foo" is an error.
45868  #
45869  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45870  # It is also a way to make sure we got the proper file name for the real test later on.
45871  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45872  if test "x$test_shortpath" = x; then
45873    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45874$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45875    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45876  fi
45877
45878  # Call helper function which possibly converts this using DOS-style short mode.
45879  # If so, the updated path is stored in $new_path.
45880
45881  input_path="$new_path"
45882  # Check if we need to convert this using DOS-style short mode. If the path
45883  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45884  # take no chances and rewrite it.
45885  # Note: m4 eats our [], so we need to use [ and ] instead.
45886  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45887  if test "x$has_forbidden_chars" != x; then
45888    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45889    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45890    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45891    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45892      # Going to short mode and back again did indeed matter. Since short mode is
45893      # case insensitive, let's make it lowercase to improve readability.
45894      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45895      # Now convert it back to Unix-stile (cygpath)
45896      input_path=`$CYGPATH -u "$shortmode_path"`
45897      new_path="$input_path"
45898    fi
45899  fi
45900
45901  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45902  if test "x$test_cygdrive_prefix" = x; then
45903    # As a simple fix, exclude /usr/bin since it's not a real path.
45904    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45905      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45906      # a path prefixed by /cygdrive for fixpath to work.
45907      new_path="$CYGWIN_ROOT_PATH$input_path"
45908    fi
45909  fi
45910
45911
45912  if test "x$path" != "x$new_path"; then
45913    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45914    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45915$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45916  fi
45917
45918  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45919
45920  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45921  has_colon=`$ECHO $path | $GREP ^.:`
45922  new_path="$path"
45923  if test "x$has_colon" = x; then
45924    # Not in mixed or Windows style, start by that.
45925    new_path=`cmd //c echo $path`
45926  fi
45927
45928
45929  input_path="$new_path"
45930  # Check if we need to convert this using DOS-style short mode. If the path
45931  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45932  # take no chances and rewrite it.
45933  # Note: m4 eats our [], so we need to use [ and ] instead.
45934  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45935  if test "x$has_forbidden_chars" != x; then
45936    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45937    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45938  fi
45939
45940
45941  windows_path="$new_path"
45942  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45943    unix_path=`$CYGPATH -u "$windows_path"`
45944    new_path="$unix_path"
45945  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45946    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45947    new_path="$unix_path"
45948  fi
45949
45950  if test "x$path" != "x$new_path"; then
45951    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45952    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45953$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45954  fi
45955
45956  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45957  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45958
45959  else
45960    # We're on a posix platform. Hooray! :)
45961    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45962    has_space=`$ECHO "$path" | $GREP " "`
45963    if test "x$has_space" != x; then
45964      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45965$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45966      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45967    fi
45968
45969    # Use eval to expand a potential ~
45970    eval path="$path"
45971    if test ! -f "$path" && test ! -d "$path"; then
45972      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45973    fi
45974
45975    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45976  fi
45977
45978
45979  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45980
45981  # Input might be given as Windows format, start by converting to
45982  # unix format.
45983  path="$POTENTIAL_FREETYPE_LIB_PATH"
45984  new_path=`$CYGPATH -u "$path"`
45985
45986  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45987  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45988  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45989  # "foo.exe" is OK but "foo" is an error.
45990  #
45991  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45992  # It is also a way to make sure we got the proper file name for the real test later on.
45993  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45994  if test "x$test_shortpath" = x; then
45995    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45996$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45997    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45998  fi
45999
46000  # Call helper function which possibly converts this using DOS-style short mode.
46001  # If so, the updated path is stored in $new_path.
46002
46003  input_path="$new_path"
46004  # Check if we need to convert this using DOS-style short mode. If the path
46005  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46006  # take no chances and rewrite it.
46007  # Note: m4 eats our [], so we need to use [ and ] instead.
46008  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46009  if test "x$has_forbidden_chars" != x; then
46010    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46011    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46012    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46013    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46014      # Going to short mode and back again did indeed matter. Since short mode is
46015      # case insensitive, let's make it lowercase to improve readability.
46016      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46017      # Now convert it back to Unix-stile (cygpath)
46018      input_path=`$CYGPATH -u "$shortmode_path"`
46019      new_path="$input_path"
46020    fi
46021  fi
46022
46023  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46024  if test "x$test_cygdrive_prefix" = x; then
46025    # As a simple fix, exclude /usr/bin since it's not a real path.
46026    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46027      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46028      # a path prefixed by /cygdrive for fixpath to work.
46029      new_path="$CYGWIN_ROOT_PATH$input_path"
46030    fi
46031  fi
46032
46033
46034  if test "x$path" != "x$new_path"; then
46035    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46036    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46037$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46038  fi
46039
46040  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46041
46042  path="$POTENTIAL_FREETYPE_LIB_PATH"
46043  has_colon=`$ECHO $path | $GREP ^.:`
46044  new_path="$path"
46045  if test "x$has_colon" = x; then
46046    # Not in mixed or Windows style, start by that.
46047    new_path=`cmd //c echo $path`
46048  fi
46049
46050
46051  input_path="$new_path"
46052  # Check if we need to convert this using DOS-style short mode. If the path
46053  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46054  # take no chances and rewrite it.
46055  # Note: m4 eats our [], so we need to use [ and ] instead.
46056  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46057  if test "x$has_forbidden_chars" != x; then
46058    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46059    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46060  fi
46061
46062
46063  windows_path="$new_path"
46064  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46065    unix_path=`$CYGPATH -u "$windows_path"`
46066    new_path="$unix_path"
46067  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46068    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46069    new_path="$unix_path"
46070  fi
46071
46072  if test "x$path" != "x$new_path"; then
46073    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46074    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46075$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46076  fi
46077
46078  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46079  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46080
46081  else
46082    # We're on a posix platform. Hooray! :)
46083    path="$POTENTIAL_FREETYPE_LIB_PATH"
46084    has_space=`$ECHO "$path" | $GREP " "`
46085    if test "x$has_space" != x; then
46086      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46087$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46088      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46089    fi
46090
46091    # Use eval to expand a potential ~
46092    eval path="$path"
46093    if test ! -f "$path" && test ! -d "$path"; then
46094      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46095    fi
46096
46097    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46098  fi
46099
46100
46101    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46102    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46103$as_echo_n "checking for freetype includes... " >&6; }
46104    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46105$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46106    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46107    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46108$as_echo_n "checking for freetype libraries... " >&6; }
46109    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46110$as_echo "$FREETYPE_LIB_PATH" >&6; }
46111  fi
46112
46113              if test "x$FOUND_FREETYPE" != xyes; then
46114
46115  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
46116  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
46117  METHOD="well-known location"
46118
46119  # First check if the files exists.
46120  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46121    # We found an arbitrary include file. That's a good sign.
46122    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
46123$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
46124    FOUND_FREETYPE=yes
46125
46126    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
46127    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
46128      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
46129$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
46130      FOUND_FREETYPE=no
46131    else
46132      if test "x$OPENJDK_TARGET_OS" = xwindows; then
46133        # On Windows, we will need both .lib and .dll file.
46134        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
46135          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
46136$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
46137          FOUND_FREETYPE=no
46138        fi
46139      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
46140        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
46141        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
46142      fi
46143    fi
46144  fi
46145
46146  if test "x$FOUND_FREETYPE" = xyes; then
46147
46148  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46149
46150  # Input might be given as Windows format, start by converting to
46151  # unix format.
46152  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46153  new_path=`$CYGPATH -u "$path"`
46154
46155  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46156  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46157  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46158  # "foo.exe" is OK but "foo" is an error.
46159  #
46160  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46161  # It is also a way to make sure we got the proper file name for the real test later on.
46162  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46163  if test "x$test_shortpath" = x; then
46164    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46165$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46166    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
46167  fi
46168
46169  # Call helper function which possibly converts this using DOS-style short mode.
46170  # If so, the updated path is stored in $new_path.
46171
46172  input_path="$new_path"
46173  # Check if we need to convert this using DOS-style short mode. If the path
46174  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46175  # take no chances and rewrite it.
46176  # Note: m4 eats our [], so we need to use [ and ] instead.
46177  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46178  if test "x$has_forbidden_chars" != x; then
46179    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46180    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46181    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46182    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46183      # Going to short mode and back again did indeed matter. Since short mode is
46184      # case insensitive, let's make it lowercase to improve readability.
46185      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46186      # Now convert it back to Unix-stile (cygpath)
46187      input_path=`$CYGPATH -u "$shortmode_path"`
46188      new_path="$input_path"
46189    fi
46190  fi
46191
46192  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46193  if test "x$test_cygdrive_prefix" = x; then
46194    # As a simple fix, exclude /usr/bin since it's not a real path.
46195    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46196      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46197      # a path prefixed by /cygdrive for fixpath to work.
46198      new_path="$CYGWIN_ROOT_PATH$input_path"
46199    fi
46200  fi
46201
46202
46203  if test "x$path" != "x$new_path"; then
46204    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46205    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46206$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46207  fi
46208
46209  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46210
46211  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46212  has_colon=`$ECHO $path | $GREP ^.:`
46213  new_path="$path"
46214  if test "x$has_colon" = x; then
46215    # Not in mixed or Windows style, start by that.
46216    new_path=`cmd //c echo $path`
46217  fi
46218
46219
46220  input_path="$new_path"
46221  # Check if we need to convert this using DOS-style short mode. If the path
46222  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46223  # take no chances and rewrite it.
46224  # Note: m4 eats our [], so we need to use [ and ] instead.
46225  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46226  if test "x$has_forbidden_chars" != x; then
46227    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46228    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46229  fi
46230
46231
46232  windows_path="$new_path"
46233  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46234    unix_path=`$CYGPATH -u "$windows_path"`
46235    new_path="$unix_path"
46236  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46237    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46238    new_path="$unix_path"
46239  fi
46240
46241  if test "x$path" != "x$new_path"; then
46242    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46243    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46244$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46245  fi
46246
46247  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46248  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46249
46250  else
46251    # We're on a posix platform. Hooray! :)
46252    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46253    has_space=`$ECHO "$path" | $GREP " "`
46254    if test "x$has_space" != x; then
46255      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46256$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46257      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46258    fi
46259
46260    # Use eval to expand a potential ~
46261    eval path="$path"
46262    if test ! -f "$path" && test ! -d "$path"; then
46263      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46264    fi
46265
46266    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46267  fi
46268
46269
46270  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46271
46272  # Input might be given as Windows format, start by converting to
46273  # unix format.
46274  path="$POTENTIAL_FREETYPE_LIB_PATH"
46275  new_path=`$CYGPATH -u "$path"`
46276
46277  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46278  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46279  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46280  # "foo.exe" is OK but "foo" is an error.
46281  #
46282  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46283  # It is also a way to make sure we got the proper file name for the real test later on.
46284  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46285  if test "x$test_shortpath" = x; then
46286    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46287$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46288    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
46289  fi
46290
46291  # Call helper function which possibly converts this using DOS-style short mode.
46292  # If so, the updated path is stored in $new_path.
46293
46294  input_path="$new_path"
46295  # Check if we need to convert this using DOS-style short mode. If the path
46296  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46297  # take no chances and rewrite it.
46298  # Note: m4 eats our [], so we need to use [ and ] instead.
46299  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46300  if test "x$has_forbidden_chars" != x; then
46301    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46302    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46303    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46304    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46305      # Going to short mode and back again did indeed matter. Since short mode is
46306      # case insensitive, let's make it lowercase to improve readability.
46307      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46308      # Now convert it back to Unix-stile (cygpath)
46309      input_path=`$CYGPATH -u "$shortmode_path"`
46310      new_path="$input_path"
46311    fi
46312  fi
46313
46314  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46315  if test "x$test_cygdrive_prefix" = x; then
46316    # As a simple fix, exclude /usr/bin since it's not a real path.
46317    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46318      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46319      # a path prefixed by /cygdrive for fixpath to work.
46320      new_path="$CYGWIN_ROOT_PATH$input_path"
46321    fi
46322  fi
46323
46324
46325  if test "x$path" != "x$new_path"; then
46326    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46327    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46328$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46329  fi
46330
46331  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46332
46333  path="$POTENTIAL_FREETYPE_LIB_PATH"
46334  has_colon=`$ECHO $path | $GREP ^.:`
46335  new_path="$path"
46336  if test "x$has_colon" = x; then
46337    # Not in mixed or Windows style, start by that.
46338    new_path=`cmd //c echo $path`
46339  fi
46340
46341
46342  input_path="$new_path"
46343  # Check if we need to convert this using DOS-style short mode. If the path
46344  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46345  # take no chances and rewrite it.
46346  # Note: m4 eats our [], so we need to use [ and ] instead.
46347  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46348  if test "x$has_forbidden_chars" != x; then
46349    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46350    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46351  fi
46352
46353
46354  windows_path="$new_path"
46355  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46356    unix_path=`$CYGPATH -u "$windows_path"`
46357    new_path="$unix_path"
46358  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46359    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46360    new_path="$unix_path"
46361  fi
46362
46363  if test "x$path" != "x$new_path"; then
46364    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46365    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46366$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46367  fi
46368
46369  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46370  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46371
46372  else
46373    # We're on a posix platform. Hooray! :)
46374    path="$POTENTIAL_FREETYPE_LIB_PATH"
46375    has_space=`$ECHO "$path" | $GREP " "`
46376    if test "x$has_space" != x; then
46377      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46378$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46379      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46380    fi
46381
46382    # Use eval to expand a potential ~
46383    eval path="$path"
46384    if test ! -f "$path" && test ! -d "$path"; then
46385      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46386    fi
46387
46388    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46389  fi
46390
46391
46392    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46393    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46394$as_echo_n "checking for freetype includes... " >&6; }
46395    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46396$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46397    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46398    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46399$as_echo_n "checking for freetype libraries... " >&6; }
46400    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46401$as_echo "$FREETYPE_LIB_PATH" >&6; }
46402  fi
46403
46404              fi
46405            fi
46406          fi
46407        fi
46408      fi # end check in well-known locations
46409
46410      if test "x$FOUND_FREETYPE" != xyes; then
46411
46412  # Print a helpful message on how to acquire the necessary build dependency.
46413  # freetype is the help tag: freetype, cups, pulse, alsa etc
46414  MISSING_DEPENDENCY=freetype
46415
46416  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46417    cygwin_help $MISSING_DEPENDENCY
46418  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46419    msys_help $MISSING_DEPENDENCY
46420  else
46421    PKGHANDLER_COMMAND=
46422
46423    case $PKGHANDLER in
46424      apt-get)
46425        apt_help     $MISSING_DEPENDENCY ;;
46426      yum)
46427        yum_help     $MISSING_DEPENDENCY ;;
46428      port)
46429        port_help    $MISSING_DEPENDENCY ;;
46430      pkgutil)
46431        pkgutil_help $MISSING_DEPENDENCY ;;
46432      pkgadd)
46433        pkgadd_help  $MISSING_DEPENDENCY ;;
46434    esac
46435
46436    if test "x$PKGHANDLER_COMMAND" != x; then
46437      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46438    fi
46439  fi
46440
46441        as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
46442      fi
46443    fi # end user specified settings
46444
46445    # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
46446    if test "x$FREETYPE_CFLAGS" = x; then
46447
46448  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46449
46450  # Input might be given as Windows format, start by converting to
46451  # unix format.
46452  path="$FREETYPE_INCLUDE_PATH"
46453  new_path=`$CYGPATH -u "$path"`
46454
46455  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46456  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46457  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46458  # "foo.exe" is OK but "foo" is an error.
46459  #
46460  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46461  # It is also a way to make sure we got the proper file name for the real test later on.
46462  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46463  if test "x$test_shortpath" = x; then
46464    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46465$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46466    as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
46467  fi
46468
46469  # Call helper function which possibly converts this using DOS-style short mode.
46470  # If so, the updated path is stored in $new_path.
46471
46472  input_path="$new_path"
46473  # Check if we need to convert this using DOS-style short mode. If the path
46474  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46475  # take no chances and rewrite it.
46476  # Note: m4 eats our [], so we need to use [ and ] instead.
46477  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46478  if test "x$has_forbidden_chars" != x; then
46479    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46480    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46481    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46482    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46483      # Going to short mode and back again did indeed matter. Since short mode is
46484      # case insensitive, let's make it lowercase to improve readability.
46485      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46486      # Now convert it back to Unix-stile (cygpath)
46487      input_path=`$CYGPATH -u "$shortmode_path"`
46488      new_path="$input_path"
46489    fi
46490  fi
46491
46492  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46493  if test "x$test_cygdrive_prefix" = x; then
46494    # As a simple fix, exclude /usr/bin since it's not a real path.
46495    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46496      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46497      # a path prefixed by /cygdrive for fixpath to work.
46498      new_path="$CYGWIN_ROOT_PATH$input_path"
46499    fi
46500  fi
46501
46502
46503  if test "x$path" != "x$new_path"; then
46504    FREETYPE_INCLUDE_PATH="$new_path"
46505    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46506$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46507  fi
46508
46509  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46510
46511  path="$FREETYPE_INCLUDE_PATH"
46512  has_colon=`$ECHO $path | $GREP ^.:`
46513  new_path="$path"
46514  if test "x$has_colon" = x; then
46515    # Not in mixed or Windows style, start by that.
46516    new_path=`cmd //c echo $path`
46517  fi
46518
46519
46520  input_path="$new_path"
46521  # Check if we need to convert this using DOS-style short mode. If the path
46522  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46523  # take no chances and rewrite it.
46524  # Note: m4 eats our [], so we need to use [ and ] instead.
46525  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46526  if test "x$has_forbidden_chars" != x; then
46527    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46528    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46529  fi
46530
46531
46532  windows_path="$new_path"
46533  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46534    unix_path=`$CYGPATH -u "$windows_path"`
46535    new_path="$unix_path"
46536  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46537    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46538    new_path="$unix_path"
46539  fi
46540
46541  if test "x$path" != "x$new_path"; then
46542    FREETYPE_INCLUDE_PATH="$new_path"
46543    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46544$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46545  fi
46546
46547  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46548  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46549
46550  else
46551    # We're on a posix platform. Hooray! :)
46552    path="$FREETYPE_INCLUDE_PATH"
46553    has_space=`$ECHO "$path" | $GREP " "`
46554    if test "x$has_space" != x; then
46555      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46556$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46557      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46558    fi
46559
46560    # Use eval to expand a potential ~
46561    eval path="$path"
46562    if test ! -f "$path" && test ! -d "$path"; then
46563      as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46564    fi
46565
46566    FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46567  fi
46568
46569      if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
46570        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
46571      else
46572        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
46573      fi
46574    fi
46575
46576    if test "x$FREETYPE_LIBS" = x; then
46577
46578  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46579
46580  # Input might be given as Windows format, start by converting to
46581  # unix format.
46582  path="$FREETYPE_LIB_PATH"
46583  new_path=`$CYGPATH -u "$path"`
46584
46585  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46586  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46587  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46588  # "foo.exe" is OK but "foo" is an error.
46589  #
46590  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46591  # It is also a way to make sure we got the proper file name for the real test later on.
46592  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46593  if test "x$test_shortpath" = x; then
46594    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46595$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46596    as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
46597  fi
46598
46599  # Call helper function which possibly converts this using DOS-style short mode.
46600  # If so, the updated path is stored in $new_path.
46601
46602  input_path="$new_path"
46603  # Check if we need to convert this using DOS-style short mode. If the path
46604  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46605  # take no chances and rewrite it.
46606  # Note: m4 eats our [], so we need to use [ and ] instead.
46607  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46608  if test "x$has_forbidden_chars" != x; then
46609    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46610    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46611    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46612    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46613      # Going to short mode and back again did indeed matter. Since short mode is
46614      # case insensitive, let's make it lowercase to improve readability.
46615      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46616      # Now convert it back to Unix-stile (cygpath)
46617      input_path=`$CYGPATH -u "$shortmode_path"`
46618      new_path="$input_path"
46619    fi
46620  fi
46621
46622  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46623  if test "x$test_cygdrive_prefix" = x; then
46624    # As a simple fix, exclude /usr/bin since it's not a real path.
46625    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46626      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46627      # a path prefixed by /cygdrive for fixpath to work.
46628      new_path="$CYGWIN_ROOT_PATH$input_path"
46629    fi
46630  fi
46631
46632
46633  if test "x$path" != "x$new_path"; then
46634    FREETYPE_LIB_PATH="$new_path"
46635    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46636$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46637  fi
46638
46639  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46640
46641  path="$FREETYPE_LIB_PATH"
46642  has_colon=`$ECHO $path | $GREP ^.:`
46643  new_path="$path"
46644  if test "x$has_colon" = x; then
46645    # Not in mixed or Windows style, start by that.
46646    new_path=`cmd //c echo $path`
46647  fi
46648
46649
46650  input_path="$new_path"
46651  # Check if we need to convert this using DOS-style short mode. If the path
46652  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46653  # take no chances and rewrite it.
46654  # Note: m4 eats our [], so we need to use [ and ] instead.
46655  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46656  if test "x$has_forbidden_chars" != x; then
46657    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46658    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46659  fi
46660
46661
46662  windows_path="$new_path"
46663  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46664    unix_path=`$CYGPATH -u "$windows_path"`
46665    new_path="$unix_path"
46666  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46667    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46668    new_path="$unix_path"
46669  fi
46670
46671  if test "x$path" != "x$new_path"; then
46672    FREETYPE_LIB_PATH="$new_path"
46673    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46674$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46675  fi
46676
46677  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46678  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46679
46680  else
46681    # We're on a posix platform. Hooray! :)
46682    path="$FREETYPE_LIB_PATH"
46683    has_space=`$ECHO "$path" | $GREP " "`
46684    if test "x$has_space" != x; then
46685      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46686$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46687      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46688    fi
46689
46690    # Use eval to expand a potential ~
46691    eval path="$path"
46692    if test ! -f "$path" && test ! -d "$path"; then
46693      as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46694    fi
46695
46696    FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46697  fi
46698
46699      if test "x$OPENJDK_TARGET_OS" = xwindows; then
46700        FREETYPE_LIBS="$FREETYPE_LIB_PATH/freetype.lib"
46701      else
46702        FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -lfreetype"
46703      fi
46704    fi
46705
46706    # Try to compile it
46707    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
46708$as_echo_n "checking if we can compile and link with freetype... " >&6; }
46709    ac_ext=cpp
46710ac_cpp='$CXXCPP $CPPFLAGS'
46711ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46712ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46713ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46714
46715    PREV_CXXCFLAGS="$CXXFLAGS"
46716    PREV_LIBS="$LIBS"
46717    PREV_CXX="$CXX"
46718    CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
46719    LIBS="$LIBS $FREETYPE_LIBS"
46720    CXX="$FIXPATH $CXX"
46721    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46722/* end confdefs.h.  */
46723
46724          #include<ft2build.h>
46725          #include FT_FREETYPE_H
46726          int main () {
46727            FT_Init_FreeType(NULL);
46728            return 0;
46729          }
46730
46731_ACEOF
46732if ac_fn_cxx_try_link "$LINENO"; then :
46733
46734          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46735$as_echo "yes" >&6; }
46736
46737else
46738
46739          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46740$as_echo "no" >&6; }
46741          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
46742$as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
46743          { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
46744$as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
46745
46746
46747  # Print a helpful message on how to acquire the necessary build dependency.
46748  # freetype is the help tag: freetype, cups, pulse, alsa etc
46749  MISSING_DEPENDENCY=freetype
46750
46751  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46752    cygwin_help $MISSING_DEPENDENCY
46753  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46754    msys_help $MISSING_DEPENDENCY
46755  else
46756    PKGHANDLER_COMMAND=
46757
46758    case $PKGHANDLER in
46759      apt-get)
46760        apt_help     $MISSING_DEPENDENCY ;;
46761      yum)
46762        yum_help     $MISSING_DEPENDENCY ;;
46763      port)
46764        port_help    $MISSING_DEPENDENCY ;;
46765      pkgutil)
46766        pkgutil_help $MISSING_DEPENDENCY ;;
46767      pkgadd)
46768        pkgadd_help  $MISSING_DEPENDENCY ;;
46769    esac
46770
46771    if test "x$PKGHANDLER_COMMAND" != x; then
46772      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46773    fi
46774  fi
46775
46776
46777          as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
46778
46779
46780fi
46781rm -f core conftest.err conftest.$ac_objext \
46782    conftest$ac_exeext conftest.$ac_ext
46783    CXXCFLAGS="$PREV_CXXFLAGS"
46784    LIBS="$PREV_LIBS"
46785    CXX="$PREV_CXX"
46786    ac_ext=cpp
46787ac_cpp='$CXXCPP $CPPFLAGS'
46788ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46789ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46790ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46791
46792
46793    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
46794$as_echo_n "checking if we should bundle freetype... " >&6; }
46795    if test "x$BUNDLE_FREETYPE" = xyes; then
46796      FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
46797    fi
46798    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
46799$as_echo "$BUNDLE_FREETYPE" >&6; }
46800
46801  fi # end freetype needed
46802
46803
46804
46805
46806
46807
46808
46809  ###############################################################################
46810  #
46811  # Check for alsa headers and libraries. Used on Linux/GNU systems.
46812  #
46813
46814# Check whether --with-alsa was given.
46815if test "${with_alsa+set}" = set; then :
46816  withval=$with_alsa;
46817fi
46818
46819
46820# Check whether --with-alsa-include was given.
46821if test "${with_alsa_include+set}" = set; then :
46822  withval=$with_alsa_include;
46823fi
46824
46825
46826# Check whether --with-alsa-lib was given.
46827if test "${with_alsa_lib+set}" = set; then :
46828  withval=$with_alsa_lib;
46829fi
46830
46831
46832  if test "x$ALSA_NOT_NEEDED" = xyes; then
46833    if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
46834      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
46835$as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
46836    fi
46837    ALSA_CFLAGS=
46838    ALSA_LIBS=
46839  else
46840    ALSA_FOUND=no
46841
46842    if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
46843      as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
46844    fi
46845
46846    if test "x${with_alsa}" != x; then
46847      ALSA_LIBS="-L${with_alsa}/lib -lasound"
46848      ALSA_CFLAGS="-I${with_alsa}/include"
46849      ALSA_FOUND=yes
46850    fi
46851    if test "x${with_alsa_include}" != x; then
46852      ALSA_CFLAGS="-I${with_alsa_include}"
46853      ALSA_FOUND=yes
46854    fi
46855    if test "x${with_alsa_lib}" != x; then
46856      ALSA_LIBS="-L${with_alsa_lib} -lasound"
46857      ALSA_FOUND=yes
46858    fi
46859    if test "x$ALSA_FOUND" = xno; then
46860
46861
46862  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
46863    # Source the builddeps file again, to make sure it uses the latest variables!
46864    . $builddepsfile
46865    # Look for a target and build machine specific resource!
46866    eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
46867    if test "x$resource" = x; then
46868      # Ok, lets instead look for a target specific resource
46869      eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
46870    fi
46871    if test "x$resource" = x; then
46872      # Ok, lets instead look for a build specific resource
46873      eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
46874    fi
46875    if test "x$resource" = x; then
46876      # Ok, lets instead look for a generic resource
46877      # (The alsa comes from M4 and not the shell, thus no need for eval here.)
46878      resource=${builddep_alsa}
46879    fi
46880    if test "x$resource" != x; then
46881      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
46882$as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
46883      # If the resource in the builddeps.conf file is an existing directory,
46884      # for example /java/linux/cups
46885      if test -d ${resource}; then
46886        depdir=${resource}
46887      else
46888
46889  # alsa is for example mymodule
46890  # $resource is for example libs/general/libmymod_1_2_3.zip
46891  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
46892  # $with_builddeps_dir is for example /localhome/builddeps
46893  # depdir is the name of the variable into which we store the depdir, eg MYMOD
46894  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
46895  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
46896  filename=`basename $resource`
46897  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
46898  filebase=${filename%%.*}
46899  extension=${filename#*.}
46900  installdir=$with_builddeps_dir/$filebase
46901  if test ! -f $installdir/$filename.unpacked; then
46902    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
46903$as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
46904    if test ! -d $installdir; then
46905      mkdir -p $installdir
46906    fi
46907    if test ! -d $installdir; then
46908      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
46909    fi
46910    tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
46911    touch $tmpfile
46912    if test ! -f $tmpfile; then
46913      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
46914    fi
46915
46916  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
46917  # $tmpfile is the local file name for the downloaded file.
46918  VALID_TOOL=no
46919  if test "x$BDEPS_FTP" = xwget; then
46920    VALID_TOOL=yes
46921    wget -O $tmpfile $with_builddeps_server/$resource
46922  fi
46923  if test "x$BDEPS_FTP" = xlftp; then
46924    VALID_TOOL=yes
46925    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
46926  fi
46927  if test "x$BDEPS_FTP" = xftp; then
46928    VALID_TOOL=yes
46929    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
46930    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
46931    FTPUSERPWD=${FTPSERVER%%@*}
46932    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
46933      FTPUSER=${userpwd%%:*}
46934      FTPPWD=${userpwd#*@}
46935      FTPSERVER=${FTPSERVER#*@}
46936    else
46937      FTPUSER=ftp
46938      FTPPWD=ftp
46939    fi
46940    # the "pass" command does not work on some
46941    # ftp clients (read ftp.exe) but if it works,
46942    # passive mode is better!
46943    ( \
46944        echo "user $FTPUSER $FTPPWD"        ; \
46945        echo "pass"                         ; \
46946        echo "bin"                          ; \
46947        echo "get $FTPPATH $tmpfile"              ; \
46948    ) | ftp -in $FTPSERVER
46949  fi
46950  if test "x$VALID_TOOL" != xyes; then
46951    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
46952  fi
46953
46954    mv $tmpfile $installdir/$filename
46955    if test ! -s $installdir/$filename; then
46956      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
46957    fi
46958    case "$extension" in
46959      zip)  echo "Unzipping $installdir/$filename..."
46960        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
46961        ;;
46962      tar.gz) echo "Untaring $installdir/$filename..."
46963        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46964        ;;
46965      tgz) echo "Untaring $installdir/$filename..."
46966        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46967        ;;
46968      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
46969        ;;
46970    esac
46971  fi
46972  if test -f $installdir/$filename.unpacked; then
46973    depdir=$installdir
46974  fi
46975
46976      fi
46977      # Source the builddeps file again, because in the previous command, the depdir
46978      # was updated to point at the current build dependency install directory.
46979      . $builddepsfile
46980      # Now extract variables from the builddeps.conf files.
46981      theroot=${builddep_alsa_ROOT}
46982      thecflags=${builddep_alsa_CFLAGS}
46983      thelibs=${builddep_alsa_LIBS}
46984      if test "x$depdir" = x; then
46985        as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
46986      fi
46987      ALSA=$depdir
46988      if test "x$theroot" != x; then
46989        ALSA="$theroot"
46990      fi
46991      if test "x$thecflags" != x; then
46992        ALSA_CFLAGS="$thecflags"
46993      fi
46994      if test "x$thelibs" != x; then
46995        ALSA_LIBS="$thelibs"
46996      fi
46997      ALSA_FOUND=yes
46998      else ALSA_FOUND=no
46999
47000    fi
47001    else ALSA_FOUND=no
47002
47003  fi
47004
47005    fi
47006    # Do not try pkg-config if we have a sysroot set.
47007    if test "x$SYSROOT" = x; then
47008      if test "x$ALSA_FOUND" = xno; then
47009
47010pkg_failed=no
47011{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
47012$as_echo_n "checking for ALSA... " >&6; }
47013
47014if test -n "$ALSA_CFLAGS"; then
47015    pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
47016 elif test -n "$PKG_CONFIG"; then
47017    if test -n "$PKG_CONFIG" && \
47018    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
47019  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
47020  ac_status=$?
47021  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47022  test $ac_status = 0; }; then
47023  pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
47024else
47025  pkg_failed=yes
47026fi
47027 else
47028    pkg_failed=untried
47029fi
47030if test -n "$ALSA_LIBS"; then
47031    pkg_cv_ALSA_LIBS="$ALSA_LIBS"
47032 elif test -n "$PKG_CONFIG"; then
47033    if test -n "$PKG_CONFIG" && \
47034    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
47035  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
47036  ac_status=$?
47037  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47038  test $ac_status = 0; }; then
47039  pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
47040else
47041  pkg_failed=yes
47042fi
47043 else
47044    pkg_failed=untried
47045fi
47046
47047
47048
47049if test $pkg_failed = yes; then
47050
47051if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47052        _pkg_short_errors_supported=yes
47053else
47054        _pkg_short_errors_supported=no
47055fi
47056        if test $_pkg_short_errors_supported = yes; then
47057	        ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
47058        else
47059	        ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
47060        fi
47061	# Put the nasty error message in config.log where it belongs
47062	echo "$ALSA_PKG_ERRORS" >&5
47063
47064	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47065$as_echo "no" >&6; }
47066                ALSA_FOUND=no
47067elif test $pkg_failed = untried; then
47068	ALSA_FOUND=no
47069else
47070	ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
47071	ALSA_LIBS=$pkg_cv_ALSA_LIBS
47072        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47073$as_echo "yes" >&6; }
47074	ALSA_FOUND=yes
47075fi
47076      fi
47077    fi
47078    if test "x$ALSA_FOUND" = xno; then
47079      for ac_header in alsa/asoundlib.h
47080do :
47081  ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
47082if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
47083  cat >>confdefs.h <<_ACEOF
47084#define HAVE_ALSA_ASOUNDLIB_H 1
47085_ACEOF
47086
47087            ALSA_FOUND=yes
47088            ALSA_CFLAGS=-Iignoreme
47089            ALSA_LIBS=-lasound
47090            DEFAULT_ALSA=yes
47091
47092else
47093  ALSA_FOUND=no
47094fi
47095
47096done
47097
47098    fi
47099    if test "x$ALSA_FOUND" = xno; then
47100
47101  # Print a helpful message on how to acquire the necessary build dependency.
47102  # alsa is the help tag: freetype, cups, pulse, alsa etc
47103  MISSING_DEPENDENCY=alsa
47104
47105  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47106    cygwin_help $MISSING_DEPENDENCY
47107  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47108    msys_help $MISSING_DEPENDENCY
47109  else
47110    PKGHANDLER_COMMAND=
47111
47112    case $PKGHANDLER in
47113      apt-get)
47114        apt_help     $MISSING_DEPENDENCY ;;
47115      yum)
47116        yum_help     $MISSING_DEPENDENCY ;;
47117      port)
47118        port_help    $MISSING_DEPENDENCY ;;
47119      pkgutil)
47120        pkgutil_help $MISSING_DEPENDENCY ;;
47121      pkgadd)
47122        pkgadd_help  $MISSING_DEPENDENCY ;;
47123    esac
47124
47125    if test "x$PKGHANDLER_COMMAND" != x; then
47126      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
47127    fi
47128  fi
47129
47130      as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
47131    fi
47132  fi
47133
47134
47135
47136
47137
47138
47139  ###############################################################################
47140  #
47141  # Check for the jpeg library
47142  #
47143
47144  USE_EXTERNAL_LIBJPEG=true
47145  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5
47146$as_echo_n "checking for main in -ljpeg... " >&6; }
47147if ${ac_cv_lib_jpeg_main+:} false; then :
47148  $as_echo_n "(cached) " >&6
47149else
47150  ac_check_lib_save_LIBS=$LIBS
47151LIBS="-ljpeg  $LIBS"
47152cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47153/* end confdefs.h.  */
47154
47155
47156int
47157main ()
47158{
47159return main ();
47160  ;
47161  return 0;
47162}
47163_ACEOF
47164if ac_fn_cxx_try_link "$LINENO"; then :
47165  ac_cv_lib_jpeg_main=yes
47166else
47167  ac_cv_lib_jpeg_main=no
47168fi
47169rm -f core conftest.err conftest.$ac_objext \
47170    conftest$ac_exeext conftest.$ac_ext
47171LIBS=$ac_check_lib_save_LIBS
47172fi
47173{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5
47174$as_echo "$ac_cv_lib_jpeg_main" >&6; }
47175if test "x$ac_cv_lib_jpeg_main" = xyes; then :
47176  cat >>confdefs.h <<_ACEOF
47177#define HAVE_LIBJPEG 1
47178_ACEOF
47179
47180  LIBS="-ljpeg $LIBS"
47181
47182else
47183   USE_EXTERNAL_LIBJPEG=false
47184      { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5
47185$as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;}
47186
47187fi
47188
47189
47190
47191  ###############################################################################
47192  #
47193  # Check for the gif library
47194  #
47195
47196
47197# Check whether --with-giflib was given.
47198if test "${with_giflib+set}" = set; then :
47199  withval=$with_giflib;
47200fi
47201
47202
47203
47204  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
47205$as_echo_n "checking for which giflib to use... " >&6; }
47206
47207  # default is bundled
47208  DEFAULT_GIFLIB=bundled
47209
47210  #
47211  # if user didn't specify, use DEFAULT_GIFLIB
47212  #
47213  if test "x${with_giflib}" = "x"; then
47214    with_giflib=${DEFAULT_GIFLIB}
47215  fi
47216
47217  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
47218$as_echo "${with_giflib}" >&6; }
47219
47220  if test "x${with_giflib}" = "xbundled"; then
47221    USE_EXTERNAL_LIBGIF=false
47222  elif test "x${with_giflib}" = "xsystem"; then
47223    ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
47224if test "x$ac_cv_header_gif_lib_h" = xyes; then :
47225
47226else
47227   as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
47228fi
47229
47230
47231    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
47232$as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
47233if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
47234  $as_echo_n "(cached) " >&6
47235else
47236  ac_check_lib_save_LIBS=$LIBS
47237LIBS="-lgif  $LIBS"
47238cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47239/* end confdefs.h.  */
47240
47241/* Override any GCC internal prototype to avoid an error.
47242   Use char because int might match the return type of a GCC
47243   builtin and then its argument prototype would still apply.  */
47244#ifdef __cplusplus
47245extern "C"
47246#endif
47247char DGifGetCode ();
47248int
47249main ()
47250{
47251return DGifGetCode ();
47252  ;
47253  return 0;
47254}
47255_ACEOF
47256if ac_fn_cxx_try_link "$LINENO"; then :
47257  ac_cv_lib_gif_DGifGetCode=yes
47258else
47259  ac_cv_lib_gif_DGifGetCode=no
47260fi
47261rm -f core conftest.err conftest.$ac_objext \
47262    conftest$ac_exeext conftest.$ac_ext
47263LIBS=$ac_check_lib_save_LIBS
47264fi
47265{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
47266$as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
47267if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
47268  cat >>confdefs.h <<_ACEOF
47269#define HAVE_LIBGIF 1
47270_ACEOF
47271
47272  LIBS="-lgif $LIBS"
47273
47274else
47275   as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
47276fi
47277
47278
47279    USE_EXTERNAL_LIBGIF=true
47280  else
47281    as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
47282  fi
47283
47284
47285  ###############################################################################
47286  #
47287  # Check for the png library
47288  #
47289
47290
47291# Check whether --with-libpng was given.
47292if test "${with_libpng+set}" = set; then :
47293  withval=$with_libpng;
47294fi
47295
47296
47297
47298  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5
47299$as_echo_n "checking for which libpng to use... " >&6; }
47300
47301  # default is bundled
47302  DEFAULT_LIBPNG=bundled
47303
47304  #
47305  # if user didn't specify, use DEFAULT_LIBPNG
47306  #
47307  if test "x${with_libpng}" = "x"; then
47308      with_libpng=${DEFAULT_LIBPNG}
47309  fi
47310
47311  if test "x${with_libpng}" = "xbundled"; then
47312      USE_EXTERNAL_LIBPNG=false
47313      { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
47314$as_echo "bundled" >&6; }
47315  elif test "x${with_libpng}" = "xsystem"; then
47316
47317pkg_failed=no
47318{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5
47319$as_echo_n "checking for PNG... " >&6; }
47320
47321if test -n "$PNG_CFLAGS"; then
47322    pkg_cv_PNG_CFLAGS="$PNG_CFLAGS"
47323 elif test -n "$PKG_CONFIG"; then
47324    if test -n "$PKG_CONFIG" && \
47325    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
47326  ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
47327  ac_status=$?
47328  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47329  test $ac_status = 0; }; then
47330  pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null`
47331else
47332  pkg_failed=yes
47333fi
47334 else
47335    pkg_failed=untried
47336fi
47337if test -n "$PNG_LIBS"; then
47338    pkg_cv_PNG_LIBS="$PNG_LIBS"
47339 elif test -n "$PKG_CONFIG"; then
47340    if test -n "$PKG_CONFIG" && \
47341    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
47342  ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
47343  ac_status=$?
47344  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47345  test $ac_status = 0; }; then
47346  pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null`
47347else
47348  pkg_failed=yes
47349fi
47350 else
47351    pkg_failed=untried
47352fi
47353
47354
47355
47356if test $pkg_failed = yes; then
47357
47358if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47359        _pkg_short_errors_supported=yes
47360else
47361        _pkg_short_errors_supported=no
47362fi
47363        if test $_pkg_short_errors_supported = yes; then
47364	        PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1`
47365        else
47366	        PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1`
47367        fi
47368	# Put the nasty error message in config.log where it belongs
47369	echo "$PNG_PKG_ERRORS" >&5
47370
47371	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47372$as_echo "no" >&6; }
47373                 LIBPNG_FOUND=no
47374elif test $pkg_failed = untried; then
47375	 LIBPNG_FOUND=no
47376else
47377	PNG_CFLAGS=$pkg_cv_PNG_CFLAGS
47378	PNG_LIBS=$pkg_cv_PNG_LIBS
47379        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47380$as_echo "yes" >&6; }
47381	 LIBPNG_FOUND=yes
47382fi
47383      if test "x${LIBPNG_FOUND}" = "xyes"; then
47384          USE_EXTERNAL_LIBPNG=true
47385          { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
47386$as_echo "system" >&6; }
47387      else
47388          { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
47389$as_echo "system not found" >&6; }
47390          as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5
47391      fi
47392  else
47393      as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5
47394  fi
47395
47396
47397  ###############################################################################
47398  #
47399  # Check for the zlib library
47400  #
47401
47402
47403# Check whether --with-zlib was given.
47404if test "${with_zlib+set}" = set; then :
47405  withval=$with_zlib;
47406fi
47407
47408
47409  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
47410$as_echo_n "checking for compress in -lz... " >&6; }
47411if ${ac_cv_lib_z_compress+:} false; then :
47412  $as_echo_n "(cached) " >&6
47413else
47414  ac_check_lib_save_LIBS=$LIBS
47415LIBS="-lz  $LIBS"
47416cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47417/* end confdefs.h.  */
47418
47419/* Override any GCC internal prototype to avoid an error.
47420   Use char because int might match the return type of a GCC
47421   builtin and then its argument prototype would still apply.  */
47422#ifdef __cplusplus
47423extern "C"
47424#endif
47425char compress ();
47426int
47427main ()
47428{
47429return compress ();
47430  ;
47431  return 0;
47432}
47433_ACEOF
47434if ac_fn_cxx_try_link "$LINENO"; then :
47435  ac_cv_lib_z_compress=yes
47436else
47437  ac_cv_lib_z_compress=no
47438fi
47439rm -f core conftest.err conftest.$ac_objext \
47440    conftest$ac_exeext conftest.$ac_ext
47441LIBS=$ac_check_lib_save_LIBS
47442fi
47443{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
47444$as_echo "$ac_cv_lib_z_compress" >&6; }
47445if test "x$ac_cv_lib_z_compress" = xyes; then :
47446   ZLIB_FOUND=yes
47447else
47448   ZLIB_FOUND=no
47449fi
47450
47451
47452  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
47453$as_echo_n "checking for which zlib to use... " >&6; }
47454
47455  DEFAULT_ZLIB=bundled
47456  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
47457    #
47458    # On macosx default is system...on others default is
47459    #
47460    DEFAULT_ZLIB=system
47461  fi
47462
47463  if test "x${ZLIB_FOUND}" != "xyes"; then
47464    #
47465    # If we don't find any system...set default to bundled
47466    #
47467    DEFAULT_ZLIB=bundled
47468  fi
47469
47470  #
47471  # If user didn't specify, use DEFAULT_ZLIB
47472  #
47473  if test "x${with_zlib}" = "x"; then
47474    with_zlib=${DEFAULT_ZLIB}
47475  fi
47476
47477  if test "x${with_zlib}" = "xbundled"; then
47478    USE_EXTERNAL_LIBZ=false
47479    { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
47480$as_echo "bundled" >&6; }
47481  elif test "x${with_zlib}" = "xsystem"; then
47482    if test "x${ZLIB_FOUND}" = "xyes"; then
47483      USE_EXTERNAL_LIBZ=true
47484      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
47485$as_echo "system" >&6; }
47486    else
47487      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
47488$as_echo "system not found" >&6; }
47489      as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
47490    fi
47491  else
47492    as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
47493  fi
47494
47495
47496
47497  ###############################################################################
47498  LIBZIP_CAN_USE_MMAP=true
47499
47500
47501
47502  ###############################################################################
47503  #
47504  # Check if altzone exists in time.h
47505  #
47506
47507  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47508/* end confdefs.h.  */
47509#include <time.h>
47510int
47511main ()
47512{
47513return (int)altzone;
47514  ;
47515  return 0;
47516}
47517_ACEOF
47518if ac_fn_cxx_try_link "$LINENO"; then :
47519  has_altzone=yes
47520else
47521  has_altzone=no
47522fi
47523rm -f core conftest.err conftest.$ac_objext \
47524    conftest$ac_exeext conftest.$ac_ext
47525  if test "x$has_altzone" = xyes; then
47526
47527$as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
47528
47529  fi
47530
47531  ###############################################################################
47532  #
47533  # Check the maths library
47534  #
47535
47536  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
47537$as_echo_n "checking for cos in -lm... " >&6; }
47538if ${ac_cv_lib_m_cos+:} false; then :
47539  $as_echo_n "(cached) " >&6
47540else
47541  ac_check_lib_save_LIBS=$LIBS
47542LIBS="-lm  $LIBS"
47543cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47544/* end confdefs.h.  */
47545
47546/* Override any GCC internal prototype to avoid an error.
47547   Use char because int might match the return type of a GCC
47548   builtin and then its argument prototype would still apply.  */
47549#ifdef __cplusplus
47550extern "C"
47551#endif
47552char cos ();
47553int
47554main ()
47555{
47556return cos ();
47557  ;
47558  return 0;
47559}
47560_ACEOF
47561if ac_fn_cxx_try_link "$LINENO"; then :
47562  ac_cv_lib_m_cos=yes
47563else
47564  ac_cv_lib_m_cos=no
47565fi
47566rm -f core conftest.err conftest.$ac_objext \
47567    conftest$ac_exeext conftest.$ac_ext
47568LIBS=$ac_check_lib_save_LIBS
47569fi
47570{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
47571$as_echo "$ac_cv_lib_m_cos" >&6; }
47572if test "x$ac_cv_lib_m_cos" = xyes; then :
47573  cat >>confdefs.h <<_ACEOF
47574#define HAVE_LIBM 1
47575_ACEOF
47576
47577  LIBS="-lm $LIBS"
47578
47579else
47580
47581        { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
47582$as_echo "$as_me: Maths library was not found" >&6;}
47583
47584
47585fi
47586
47587
47588
47589  ###############################################################################
47590  #
47591  # Check for libdl.so
47592
47593  save_LIBS="$LIBS"
47594  LIBS=""
47595  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
47596$as_echo_n "checking for dlopen in -ldl... " >&6; }
47597if ${ac_cv_lib_dl_dlopen+:} false; then :
47598  $as_echo_n "(cached) " >&6
47599else
47600  ac_check_lib_save_LIBS=$LIBS
47601LIBS="-ldl  $LIBS"
47602cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47603/* end confdefs.h.  */
47604
47605/* Override any GCC internal prototype to avoid an error.
47606   Use char because int might match the return type of a GCC
47607   builtin and then its argument prototype would still apply.  */
47608#ifdef __cplusplus
47609extern "C"
47610#endif
47611char dlopen ();
47612int
47613main ()
47614{
47615return dlopen ();
47616  ;
47617  return 0;
47618}
47619_ACEOF
47620if ac_fn_cxx_try_link "$LINENO"; then :
47621  ac_cv_lib_dl_dlopen=yes
47622else
47623  ac_cv_lib_dl_dlopen=no
47624fi
47625rm -f core conftest.err conftest.$ac_objext \
47626    conftest$ac_exeext conftest.$ac_ext
47627LIBS=$ac_check_lib_save_LIBS
47628fi
47629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
47630$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
47631if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
47632  cat >>confdefs.h <<_ACEOF
47633#define HAVE_LIBDL 1
47634_ACEOF
47635
47636  LIBS="-ldl $LIBS"
47637
47638fi
47639
47640  LIBDL="$LIBS"
47641
47642  LIBS="$save_LIBS"
47643
47644
47645  ###############################################################################
47646  #
47647  # statically link libstdc++ before C++ ABI is stablized on Linux unless
47648  # dynamic build is configured on command line.
47649  #
47650
47651# Check whether --with-stdc++lib was given.
47652if test "${with_stdc__lib+set}" = set; then :
47653  withval=$with_stdc__lib;
47654        if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
47655                && test "x$with_stdc__lib" != xdefault; then
47656          as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
47657        fi
47658
47659else
47660  with_stdc__lib=default
47661
47662fi
47663
47664
47665  if test "x$OPENJDK_TARGET_OS" = xlinux; then
47666    # Test if -lstdc++ works.
47667    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
47668$as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
47669    ac_ext=cpp
47670ac_cpp='$CXXCPP $CPPFLAGS'
47671ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47672ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47673ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47674
47675    OLD_CXXFLAGS="$CXXFLAGS"
47676    CXXFLAGS="$CXXFLAGS -lstdc++"
47677    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47678/* end confdefs.h.  */
47679
47680int
47681main ()
47682{
47683return 0;
47684  ;
47685  return 0;
47686}
47687_ACEOF
47688if ac_fn_cxx_try_link "$LINENO"; then :
47689  has_dynamic_libstdcxx=yes
47690else
47691  has_dynamic_libstdcxx=no
47692fi
47693rm -f core conftest.err conftest.$ac_objext \
47694    conftest$ac_exeext conftest.$ac_ext
47695    CXXFLAGS="$OLD_CXXFLAGS"
47696    ac_ext=cpp
47697ac_cpp='$CXXCPP $CPPFLAGS'
47698ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47699ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47700ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47701
47702    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
47703$as_echo "$has_dynamic_libstdcxx" >&6; }
47704
47705    # Test if stdc++ can be linked statically.
47706    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
47707$as_echo_n "checking if static link of stdc++ is possible... " >&6; }
47708    STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
47709    ac_ext=cpp
47710ac_cpp='$CXXCPP $CPPFLAGS'
47711ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47712ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47713ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47714
47715    OLD_LIBS="$LIBS"
47716    OLD_CXX="$CXX"
47717    LIBS="$STATIC_STDCXX_FLAGS"
47718    CXX="$CC"
47719    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47720/* end confdefs.h.  */
47721
47722int
47723main ()
47724{
47725return 0;
47726  ;
47727  return 0;
47728}
47729_ACEOF
47730if ac_fn_cxx_try_link "$LINENO"; then :
47731  has_static_libstdcxx=yes
47732else
47733  has_static_libstdcxx=no
47734fi
47735rm -f core conftest.err conftest.$ac_objext \
47736    conftest$ac_exeext conftest.$ac_ext
47737    LIBS="$OLD_LIBS"
47738    CXX="$OLD_CXX"
47739    ac_ext=cpp
47740ac_cpp='$CXXCPP $CPPFLAGS'
47741ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47742ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47743ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47744
47745    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
47746$as_echo "$has_static_libstdcxx" >&6; }
47747
47748    if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
47749      as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
47750    fi
47751
47752    if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
47753      as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
47754    fi
47755
47756    if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
47757      as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
47758    fi
47759
47760    { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
47761$as_echo_n "checking how to link with libstdc++... " >&6; }
47762    # If dynamic was requested, it's available since it would fail above otherwise.
47763    # If dynamic wasn't requested, go with static unless it isn't available.
47764    if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47765      LIBCXX="$LIBCXX -lstdc++"
47766      LDCXX="$CXX"
47767      STATIC_CXX_SETTING="STATIC_CXX=false"
47768      { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
47769$as_echo "dynamic" >&6; }
47770    else
47771      LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
47772      LDCXX="$CC"
47773      STATIC_CXX_SETTING="STATIC_CXX=true"
47774      { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
47775$as_echo "static" >&6; }
47776    fi
47777  fi
47778
47779
47780  if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47781    # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
47782
47783pkg_failed=no
47784{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
47785$as_echo_n "checking for LIBFFI... " >&6; }
47786
47787if test -n "$LIBFFI_CFLAGS"; then
47788    pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
47789 elif test -n "$PKG_CONFIG"; then
47790    if test -n "$PKG_CONFIG" && \
47791    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47792  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47793  ac_status=$?
47794  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47795  test $ac_status = 0; }; then
47796  pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
47797else
47798  pkg_failed=yes
47799fi
47800 else
47801    pkg_failed=untried
47802fi
47803if test -n "$LIBFFI_LIBS"; then
47804    pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
47805 elif test -n "$PKG_CONFIG"; then
47806    if test -n "$PKG_CONFIG" && \
47807    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47808  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47809  ac_status=$?
47810  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47811  test $ac_status = 0; }; then
47812  pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
47813else
47814  pkg_failed=yes
47815fi
47816 else
47817    pkg_failed=untried
47818fi
47819
47820
47821
47822if test $pkg_failed = yes; then
47823
47824if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47825        _pkg_short_errors_supported=yes
47826else
47827        _pkg_short_errors_supported=no
47828fi
47829        if test $_pkg_short_errors_supported = yes; then
47830	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
47831        else
47832	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
47833        fi
47834	# Put the nasty error message in config.log where it belongs
47835	echo "$LIBFFI_PKG_ERRORS" >&5
47836
47837	as_fn_error $? "Package requirements (libffi) were not met:
47838
47839$LIBFFI_PKG_ERRORS
47840
47841Consider adjusting the PKG_CONFIG_PATH environment variable if you
47842installed software in a non-standard prefix.
47843
47844Alternatively, you may set the environment variables LIBFFI_CFLAGS
47845and LIBFFI_LIBS to avoid the need to call pkg-config.
47846See the pkg-config man page for more details.
47847" "$LINENO" 5
47848elif test $pkg_failed = untried; then
47849	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47850$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
47851as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
47852is in your PATH or set the PKG_CONFIG environment variable to the full
47853path to pkg-config.
47854
47855Alternatively, you may set the environment variables LIBFFI_CFLAGS
47856and LIBFFI_LIBS to avoid the need to call pkg-config.
47857See the pkg-config man page for more details.
47858
47859To get pkg-config, see <http://pkg-config.freedesktop.org/>.
47860See \`config.log' for more details" "$LINENO" 5; }
47861else
47862	LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
47863	LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
47864        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47865$as_echo "yes" >&6; }
47866	:
47867fi
47868
47869  fi
47870
47871  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47872    # Extract the first word of "llvm-config", so it can be a program name with args.
47873set dummy llvm-config; ac_word=$2
47874{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47875$as_echo_n "checking for $ac_word... " >&6; }
47876if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
47877  $as_echo_n "(cached) " >&6
47878else
47879  if test -n "$LLVM_CONFIG"; then
47880  ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
47881else
47882as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47883for as_dir in $PATH
47884do
47885  IFS=$as_save_IFS
47886  test -z "$as_dir" && as_dir=.
47887    for ac_exec_ext in '' $ac_executable_extensions; do
47888  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47889    ac_cv_prog_LLVM_CONFIG="llvm-config"
47890    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47891    break 2
47892  fi
47893done
47894  done
47895IFS=$as_save_IFS
47896
47897fi
47898fi
47899LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
47900if test -n "$LLVM_CONFIG"; then
47901  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
47902$as_echo "$LLVM_CONFIG" >&6; }
47903else
47904  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47905$as_echo "no" >&6; }
47906fi
47907
47908
47909
47910    if test "x$LLVM_CONFIG" != xllvm-config; then
47911      as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
47912    fi
47913
47914    llvm_components="jit mcjit engine nativecodegen native"
47915    unset LLVM_CFLAGS
47916    for flag in $("$LLVM_CONFIG" --cxxflags); do
47917      if echo "${flag}" | grep -q '^-[ID]'; then
47918        if test "${flag}" != "-D_DEBUG" ; then
47919          if test "${LLVM_CFLAGS}" != "" ; then
47920            LLVM_CFLAGS="${LLVM_CFLAGS} "
47921          fi
47922          LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
47923        fi
47924      fi
47925    done
47926    llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
47927    LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
47928
47929    unset LLVM_LDFLAGS
47930    for flag in $("${LLVM_CONFIG}" --ldflags); do
47931      if echo "${flag}" | grep -q '^-L'; then
47932        if test "${LLVM_LDFLAGS}" != ""; then
47933          LLVM_LDFLAGS="${LLVM_LDFLAGS} "
47934        fi
47935        LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
47936      fi
47937    done
47938
47939    unset LLVM_LIBS
47940    for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47941      if echo "${flag}" | grep -q '^-l'; then
47942        if test "${LLVM_LIBS}" != ""; then
47943          LLVM_LIBS="${LLVM_LIBS} "
47944        fi
47945        LLVM_LIBS="${LLVM_LIBS}${flag}"
47946      fi
47947    done
47948
47949
47950
47951
47952  fi
47953
47954  # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47955  if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47956    LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47957  fi
47958
47959  # TODO better (platform agnostic) test
47960  if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47961    LIBCXX="-lstdc++"
47962  fi
47963
47964
47965
47966
47967  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47968
47969
47970# Check whether --with-msvcr-dll was given.
47971if test "${with_msvcr_dll+set}" = set; then :
47972  withval=$with_msvcr_dll;
47973fi
47974
47975
47976  if test "x$with_msvcr_dll" != x; then
47977    # If given explicitely by user, do not probe. If not present, fail directly.
47978
47979  POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
47980  METHOD="--with-msvcr-dll"
47981  if test -e "$POSSIBLE_MSVCR_DLL"; then
47982    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47983$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47984
47985    # Need to check if the found msvcr is correct architecture
47986    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47987$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47988    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47989    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47990      CORRECT_MSVCR_ARCH=386
47991    else
47992      CORRECT_MSVCR_ARCH=x86-64
47993    fi
47994    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47995      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47996$as_echo "ok" >&6; }
47997      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47998      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47999$as_echo_n "checking for msvcr100.dll... " >&6; }
48000      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48001$as_echo "$MSVCR_DLL" >&6; }
48002    else
48003      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48004$as_echo "incorrect, ignoring" >&6; }
48005      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48006$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48007    fi
48008  fi
48009
48010    if test "x$MSVCR_DLL" = x; then
48011      as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
48012    fi
48013  fi
48014
48015  if test "x$MSVCR_DLL" = x; then
48016    # Probe: Using well-known location from Visual Studio 10.0
48017    if test "x$VCINSTALLDIR" != x; then
48018      CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
48019
48020  windows_path="$CYGWIN_VC_INSTALL_DIR"
48021  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48022    unix_path=`$CYGPATH -u "$windows_path"`
48023    CYGWIN_VC_INSTALL_DIR="$unix_path"
48024  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48025    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48026    CYGWIN_VC_INSTALL_DIR="$unix_path"
48027  fi
48028
48029      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
48030        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
48031      else
48032        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
48033      fi
48034
48035  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48036  METHOD="well-known location in VCINSTALLDIR"
48037  if test -e "$POSSIBLE_MSVCR_DLL"; then
48038    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
48039$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
48040
48041    # Need to check if the found msvcr is correct architecture
48042    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
48043$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
48044    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
48045    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
48046      CORRECT_MSVCR_ARCH=386
48047    else
48048      CORRECT_MSVCR_ARCH=x86-64
48049    fi
48050    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
48051      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
48052$as_echo "ok" >&6; }
48053      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48054      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48055$as_echo_n "checking for msvcr100.dll... " >&6; }
48056      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48057$as_echo "$MSVCR_DLL" >&6; }
48058    else
48059      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48060$as_echo "incorrect, ignoring" >&6; }
48061      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48062$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48063    fi
48064  fi
48065
48066    fi
48067  fi
48068
48069  if test "x$MSVCR_DLL" = x; then
48070    # Probe: Check in the Boot JDK directory.
48071    POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
48072
48073  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48074  METHOD="well-known location in Boot JDK"
48075  if test -e "$POSSIBLE_MSVCR_DLL"; then
48076    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
48077$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
48078
48079    # Need to check if the found msvcr is correct architecture
48080    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
48081$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
48082    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
48083    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
48084      CORRECT_MSVCR_ARCH=386
48085    else
48086      CORRECT_MSVCR_ARCH=x86-64
48087    fi
48088    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
48089      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
48090$as_echo "ok" >&6; }
48091      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48092      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48093$as_echo_n "checking for msvcr100.dll... " >&6; }
48094      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48095$as_echo "$MSVCR_DLL" >&6; }
48096    else
48097      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48098$as_echo "incorrect, ignoring" >&6; }
48099      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48100$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48101    fi
48102  fi
48103
48104  fi
48105
48106  if test "x$MSVCR_DLL" = x; then
48107    # Probe: Look in the Windows system32 directory
48108    CYGWIN_SYSTEMROOT="$SYSTEMROOT"
48109
48110  windows_path="$CYGWIN_SYSTEMROOT"
48111  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48112    unix_path=`$CYGPATH -u "$windows_path"`
48113    CYGWIN_SYSTEMROOT="$unix_path"
48114  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48115    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48116    CYGWIN_SYSTEMROOT="$unix_path"
48117  fi
48118
48119    POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
48120
48121  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48122  METHOD="well-known location in SYSTEMROOT"
48123  if test -e "$POSSIBLE_MSVCR_DLL"; then
48124    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
48125$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
48126
48127    # Need to check if the found msvcr is correct architecture
48128    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
48129$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
48130    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
48131    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
48132      CORRECT_MSVCR_ARCH=386
48133    else
48134      CORRECT_MSVCR_ARCH=x86-64
48135    fi
48136    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
48137      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
48138$as_echo "ok" >&6; }
48139      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48140      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48141$as_echo_n "checking for msvcr100.dll... " >&6; }
48142      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48143$as_echo "$MSVCR_DLL" >&6; }
48144    else
48145      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48146$as_echo "incorrect, ignoring" >&6; }
48147      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48148$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48149    fi
48150  fi
48151
48152  fi
48153
48154  if test "x$MSVCR_DLL" = x; then
48155    # Probe: If Visual Studio Express is installed, there is usually one with the debugger
48156    if test "x$VS100COMNTOOLS" != x; then
48157      CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
48158
48159  windows_path="$CYGWIN_VS_TOOLS_DIR"
48160  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48161    unix_path=`$CYGPATH -u "$windows_path"`
48162    CYGWIN_VS_TOOLS_DIR="$unix_path"
48163  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48164    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48165    CYGWIN_VS_TOOLS_DIR="$unix_path"
48166  fi
48167
48168      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
48169        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
48170      else
48171        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
48172      fi
48173
48174  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48175  METHOD="search of VS100COMNTOOLS"
48176  if test -e "$POSSIBLE_MSVCR_DLL"; then
48177    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
48178$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
48179
48180    # Need to check if the found msvcr is correct architecture
48181    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
48182$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
48183    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
48184    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
48185      CORRECT_MSVCR_ARCH=386
48186    else
48187      CORRECT_MSVCR_ARCH=x86-64
48188    fi
48189    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
48190      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
48191$as_echo "ok" >&6; }
48192      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48193      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48194$as_echo_n "checking for msvcr100.dll... " >&6; }
48195      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48196$as_echo "$MSVCR_DLL" >&6; }
48197    else
48198      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48199$as_echo "incorrect, ignoring" >&6; }
48200      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48201$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48202    fi
48203  fi
48204
48205    fi
48206  fi
48207
48208  if test "x$MSVCR_DLL" = x; then
48209    # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
48210    # (This was the original behaviour; kept since it might turn up something)
48211    if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
48212      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
48213        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
48214      else
48215        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
48216        if test "x$POSSIBLE_MSVCR_DLL" = x; then
48217          # We're grasping at straws now...
48218          POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
48219        fi
48220      fi
48221
48222
48223  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48224  METHOD="search of VCINSTALLDIR"
48225  if test -e "$POSSIBLE_MSVCR_DLL"; then
48226    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
48227$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
48228
48229    # Need to check if the found msvcr is correct architecture
48230    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
48231$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
48232    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
48233    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
48234      CORRECT_MSVCR_ARCH=386
48235    else
48236      CORRECT_MSVCR_ARCH=x86-64
48237    fi
48238    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
48239      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
48240$as_echo "ok" >&6; }
48241      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
48242      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48243$as_echo_n "checking for msvcr100.dll... " >&6; }
48244      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
48245$as_echo "$MSVCR_DLL" >&6; }
48246    else
48247      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
48248$as_echo "incorrect, ignoring" >&6; }
48249      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
48250$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
48251    fi
48252  fi
48253
48254    fi
48255  fi
48256
48257  if test "x$MSVCR_DLL" = x; then
48258    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
48259$as_echo_n "checking for msvcr100.dll... " >&6; }
48260    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48261$as_echo "no" >&6; }
48262    as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
48263  fi
48264
48265
48266  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48267
48268  # Input might be given as Windows format, start by converting to
48269  # unix format.
48270  path="$MSVCR_DLL"
48271  new_path=`$CYGPATH -u "$path"`
48272
48273  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
48274  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
48275  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
48276  # "foo.exe" is OK but "foo" is an error.
48277  #
48278  # This test is therefore slightly more accurate than "test -f" to check for file precense.
48279  # It is also a way to make sure we got the proper file name for the real test later on.
48280  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
48281  if test "x$test_shortpath" = x; then
48282    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
48283$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
48284    as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
48285  fi
48286
48287  # Call helper function which possibly converts this using DOS-style short mode.
48288  # If so, the updated path is stored in $new_path.
48289
48290  input_path="$new_path"
48291  # Check if we need to convert this using DOS-style short mode. If the path
48292  # contains just simple characters, use it. Otherwise (spaces, weird characters),
48293  # take no chances and rewrite it.
48294  # Note: m4 eats our [], so we need to use [ and ] instead.
48295  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
48296  if test "x$has_forbidden_chars" != x; then
48297    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48298    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
48299    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
48300    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
48301      # Going to short mode and back again did indeed matter. Since short mode is
48302      # case insensitive, let's make it lowercase to improve readability.
48303      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48304      # Now convert it back to Unix-stile (cygpath)
48305      input_path=`$CYGPATH -u "$shortmode_path"`
48306      new_path="$input_path"
48307    fi
48308  fi
48309
48310  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
48311  if test "x$test_cygdrive_prefix" = x; then
48312    # As a simple fix, exclude /usr/bin since it's not a real path.
48313    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
48314      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
48315      # a path prefixed by /cygdrive for fixpath to work.
48316      new_path="$CYGWIN_ROOT_PATH$input_path"
48317    fi
48318  fi
48319
48320
48321  if test "x$path" != "x$new_path"; then
48322    MSVCR_DLL="$new_path"
48323    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
48324$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
48325  fi
48326
48327  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48328
48329  path="$MSVCR_DLL"
48330  has_colon=`$ECHO $path | $GREP ^.:`
48331  new_path="$path"
48332  if test "x$has_colon" = x; then
48333    # Not in mixed or Windows style, start by that.
48334    new_path=`cmd //c echo $path`
48335  fi
48336
48337
48338  input_path="$new_path"
48339  # Check if we need to convert this using DOS-style short mode. If the path
48340  # contains just simple characters, use it. Otherwise (spaces, weird characters),
48341  # take no chances and rewrite it.
48342  # Note: m4 eats our [], so we need to use [ and ] instead.
48343  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
48344  if test "x$has_forbidden_chars" != x; then
48345    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48346    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48347  fi
48348
48349
48350  windows_path="$new_path"
48351  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48352    unix_path=`$CYGPATH -u "$windows_path"`
48353    new_path="$unix_path"
48354  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48355    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48356    new_path="$unix_path"
48357  fi
48358
48359  if test "x$path" != "x$new_path"; then
48360    MSVCR_DLL="$new_path"
48361    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
48362$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
48363  fi
48364
48365  # Save the first 10 bytes of this path to the storage, so fixpath can work.
48366  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
48367
48368  else
48369    # We're on a posix platform. Hooray! :)
48370    path="$MSVCR_DLL"
48371    has_space=`$ECHO "$path" | $GREP " "`
48372    if test "x$has_space" != x; then
48373      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
48374$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
48375      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
48376    fi
48377
48378    # Use eval to expand a potential ~
48379    eval path="$path"
48380    if test ! -f "$path" && test ! -d "$path"; then
48381      as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
48382    fi
48383
48384    MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
48385  fi
48386
48387
48388
48389
48390# Check whether --with-dxsdk was given.
48391if test "${with_dxsdk+set}" = set; then :
48392  withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
48393$as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
48394fi
48395
48396
48397
48398
48399# Check whether --with-dxsdk-lib was given.
48400if test "${with_dxsdk_lib+set}" = set; then :
48401  withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
48402$as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
48403fi
48404
48405
48406
48407
48408# Check whether --with-dxsdk-include was given.
48409if test "${with_dxsdk_include+set}" = set; then :
48410  withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
48411$as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
48412fi
48413
48414
48415  fi
48416
48417
48418
48419###############################################################################
48420#
48421# We need to do some final tweaking, when everything else is done.
48422#
48423###############################################################################
48424
48425
48426  HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
48427
48428
48429  # The name of the Service Agent jar.
48430  SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
48431  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
48432    SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
48433  fi
48434
48435
48436
48437    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
48438$as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
48439
48440    if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then
48441      ENABLE_INTREE_EC=yes
48442      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48443$as_echo "yes" >&6; }
48444    else
48445      ENABLE_INTREE_EC=no
48446      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48447$as_echo "no" >&6; }
48448    fi
48449
48450
48451
48452
48453###############################################################################
48454#
48455# Configure parts of the build that only affect the build performance,
48456# not the result.
48457#
48458###############################################################################
48459
48460
48461  # How many cores do we have on this build system?
48462
48463# Check whether --with-num-cores was given.
48464if test "${with_num_cores+set}" = set; then :
48465  withval=$with_num_cores;
48466fi
48467
48468  if test "x$with_num_cores" = x; then
48469    # The number of cores were not specified, try to probe them.
48470
48471  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
48472$as_echo_n "checking for number of cores... " >&6; }
48473  NUM_CORES=1
48474  FOUND_CORES=no
48475
48476  if test -f /proc/cpuinfo; then
48477    # Looks like a Linux (or cygwin) system
48478    NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
48479    FOUND_CORES=yes
48480  elif test -x /usr/sbin/psrinfo; then
48481    # Looks like a Solaris system
48482    NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
48483    FOUND_CORES=yes
48484  elif test -x /usr/sbin/system_profiler; then
48485    # Looks like a MacOSX system
48486    NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
48487    FOUND_CORES=yes
48488  elif test "x$OPENJDK_BUILD_OS" = xaix ; then
48489    NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
48490    FOUND_CORES=yes
48491  elif test -n "$NUMBER_OF_PROCESSORS"; then
48492    # On windows, look in the env
48493    NUM_CORES=$NUMBER_OF_PROCESSORS
48494    FOUND_CORES=yes
48495  fi
48496
48497  if test "x$FOUND_CORES" = xyes; then
48498    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
48499$as_echo "$NUM_CORES" >&6; }
48500  else
48501    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
48502$as_echo "could not detect number of cores, defaulting to 1" >&6; }
48503    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
48504$as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
48505  fi
48506
48507  else
48508    NUM_CORES=$with_num_cores
48509  fi
48510
48511
48512
48513  # How much memory do we have on this build system?
48514
48515# Check whether --with-memory-size was given.
48516if test "${with_memory_size+set}" = set; then :
48517  withval=$with_memory_size;
48518fi
48519
48520  if test "x$with_memory_size" = x; then
48521    # The memory size was not specified, try to probe it.
48522
48523  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
48524$as_echo_n "checking for memory size... " >&6; }
48525  # Default to 1024 MB
48526  MEMORY_SIZE=1024
48527  FOUND_MEM=no
48528
48529  if test -f /proc/meminfo; then
48530    # Looks like a Linux (or cygwin) system
48531    MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
48532    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
48533    FOUND_MEM=yes
48534  elif test -x /usr/sbin/prtconf; then
48535    # Looks like a Solaris or AIX system
48536    MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
48537    FOUND_MEM=yes
48538  elif test -x /usr/sbin/system_profiler; then
48539    # Looks like a MacOSX system
48540    MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
48541    MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
48542    FOUND_MEM=yes
48543  elif test "x$OPENJDK_BUILD_OS" = xwindows; then
48544    # Windows, but without cygwin
48545    MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
48546    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
48547    FOUND_MEM=yes
48548  fi
48549
48550  if test "x$FOUND_MEM" = xyes; then
48551    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
48552$as_echo "$MEMORY_SIZE MB" >&6; }
48553  else
48554    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5
48555$as_echo "could not detect memory size, defaulting to 1024 MB" >&6; }
48556    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
48557$as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
48558  fi
48559
48560  else
48561    MEMORY_SIZE=$with_memory_size
48562  fi
48563
48564
48565
48566  # Provide a decent default number of parallel jobs for make depending on
48567  # number of cores, amount of memory and machine architecture.
48568
48569# Check whether --with-jobs was given.
48570if test "${with_jobs+set}" = set; then :
48571  withval=$with_jobs;
48572fi
48573
48574  if test "x$with_jobs" = x; then
48575    # Number of jobs was not specified, calculate.
48576    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
48577$as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
48578    # Approximate memory in GB, rounding up a bit.
48579    memory_gb=`expr $MEMORY_SIZE / 1100`
48580    # Pick the lowest of memory in gb and number of cores.
48581    if test "$memory_gb" -lt "$NUM_CORES"; then
48582      JOBS="$memory_gb"
48583    else
48584      JOBS="$NUM_CORES"
48585      # On bigger machines, leave some room for other processes to run
48586      if test "$JOBS" -gt "4"; then
48587        JOBS=`expr $JOBS '*' 90 / 100`
48588      fi
48589    fi
48590    # Cap number of jobs to 16
48591    if test "$JOBS" -gt "16"; then
48592      JOBS=16
48593    fi
48594    if test "$JOBS" -eq "0"; then
48595      JOBS=1
48596    fi
48597    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
48598$as_echo "$JOBS" >&6; }
48599  else
48600    JOBS=$with_jobs
48601  fi
48602
48603
48604
48605# Setup smart javac (after cores and memory have been setup)
48606
48607
48608# Check whether --with-sjavac-server-java was given.
48609if test "${with_sjavac_server_java+set}" = set; then :
48610  withval=$with_sjavac_server_java;
48611fi
48612
48613
48614  if test "x$with_sjavac_server_java" != x; then
48615    SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
48616    FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
48617    if test "x$FOUND_VERSION" = x; then
48618      as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
48619    fi
48620  else
48621    SJAVAC_SERVER_JAVA=""
48622    # Hotspot specific options.
48623
48624  $ECHO "Check if jvm arg is ok: -verbosegc" >&5
48625  $ECHO "Command: $JAVA -verbosegc -version" >&5
48626  OUTPUT=`$JAVA -verbosegc -version 2>&1`
48627  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48628  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48629  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48630    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc"
48631    JVM_ARG_OK=true
48632  else
48633    $ECHO "Arg failed:" >&5
48634    $ECHO "$OUTPUT" >&5
48635    JVM_ARG_OK=false
48636  fi
48637
48638    # JRockit specific options.
48639
48640  $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5
48641  $ECHO "Command: $JAVA -Xverbose:gc -version" >&5
48642  OUTPUT=`$JAVA -Xverbose:gc -version 2>&1`
48643  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48644  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48645  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48646    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc"
48647    JVM_ARG_OK=true
48648  else
48649    $ECHO "Arg failed:" >&5
48650    $ECHO "$OUTPUT" >&5
48651    JVM_ARG_OK=false
48652  fi
48653
48654    SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA"
48655  fi
48656
48657
48658  if test "$MEMORY_SIZE" -gt "2500"; then
48659
48660  $ECHO "Check if jvm arg is ok: -d64" >&5
48661  $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
48662  OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
48663  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48664  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48665  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48666    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64"
48667    JVM_ARG_OK=true
48668  else
48669    $ECHO "Arg failed:" >&5
48670    $ECHO "$OUTPUT" >&5
48671    JVM_ARG_OK=false
48672  fi
48673
48674    if test "$JVM_ARG_OK" = true; then
48675      JVM_64BIT=true
48676      JVM_ARG_OK=false
48677    fi
48678  fi
48679
48680  if test "$JVM_64BIT" = true; then
48681    if test "$MEMORY_SIZE" -gt "17000"; then
48682
48683  $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5
48684  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5
48685  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1`
48686  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48687  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48688  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48689    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G"
48690    JVM_ARG_OK=true
48691  else
48692    $ECHO "Arg failed:" >&5
48693    $ECHO "$OUTPUT" >&5
48694    JVM_ARG_OK=false
48695  fi
48696
48697    fi
48698    if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then
48699
48700  $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5
48701  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5
48702  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1`
48703  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48704  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48705  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48706    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G"
48707    JVM_ARG_OK=true
48708  else
48709    $ECHO "Arg failed:" >&5
48710    $ECHO "$OUTPUT" >&5
48711    JVM_ARG_OK=false
48712  fi
48713
48714    fi
48715    if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then
48716
48717  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5
48718  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5
48719  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1`
48720  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48721  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48722  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48723    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G"
48724    JVM_ARG_OK=true
48725  else
48726    $ECHO "Arg failed:" >&5
48727    $ECHO "$OUTPUT" >&5
48728    JVM_ARG_OK=false
48729  fi
48730
48731    fi
48732    if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then
48733
48734  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5
48735  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5
48736  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1`
48737  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48738  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48739  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48740    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M"
48741    JVM_ARG_OK=true
48742  else
48743    $ECHO "Arg failed:" >&5
48744    $ECHO "$OUTPUT" >&5
48745    JVM_ARG_OK=false
48746  fi
48747
48748    fi
48749  fi
48750  if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then
48751
48752  $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5
48753  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5
48754  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1`
48755  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48756  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48757  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48758    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M"
48759    JVM_ARG_OK=true
48760  else
48761    $ECHO "Arg failed:" >&5
48762    $ECHO "$OUTPUT" >&5
48763    JVM_ARG_OK=false
48764  fi
48765
48766  fi
48767  if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then
48768
48769  $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5
48770  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5
48771  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1`
48772  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48773  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48774  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48775    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M"
48776    JVM_ARG_OK=true
48777  else
48778    $ECHO "Arg failed:" >&5
48779    $ECHO "$OUTPUT" >&5
48780    JVM_ARG_OK=false
48781  fi
48782
48783  fi
48784  if test "$JVM_ARG_OK" = false; then
48785
48786  $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5
48787  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5
48788  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1`
48789  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48790  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48791  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48792    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M"
48793    JVM_ARG_OK=true
48794  else
48795    $ECHO "Arg failed:" >&5
48796    $ECHO "$OUTPUT" >&5
48797    JVM_ARG_OK=false
48798  fi
48799
48800  fi
48801
48802  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
48803$as_echo_n "checking whether to use sjavac... " >&6; }
48804  # Check whether --enable-sjavac was given.
48805if test "${enable_sjavac+set}" = set; then :
48806  enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
48807else
48808  ENABLE_SJAVAC='no'
48809fi
48810
48811  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
48812$as_echo "$ENABLE_SJAVAC" >&6; }
48813
48814
48815  if test "x$ENABLE_SJAVAC" = xyes; then
48816    SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
48817  else
48818    SJAVAC_SERVER_DIR=
48819  fi
48820
48821
48822
48823# Can the C/C++ compiler use precompiled headers?
48824
48825
48826  ###############################################################################
48827  #
48828  # Can the C/C++ compiler use precompiled headers?
48829  #
48830  # Check whether --enable-precompiled-headers was given.
48831if test "${enable_precompiled_headers+set}" = set; then :
48832  enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
48833else
48834  ENABLE_PRECOMPH=yes
48835fi
48836
48837
48838  USE_PRECOMPILED_HEADER=1
48839  if test "x$ENABLE_PRECOMPH" = xno; then
48840    USE_PRECOMPILED_HEADER=0
48841  fi
48842
48843  if test "x$ENABLE_PRECOMPH" = xyes; then
48844    # Check that the compiler actually supports precomp headers.
48845    if test "x$TOOLCHAIN_TYPE" = xgcc; then
48846      { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
48847$as_echo_n "checking that precompiled headers work... " >&6; }
48848      echo "int alfa();" > conftest.h
48849      $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
48850      if test ! -f conftest.hpp.gch; then
48851        USE_PRECOMPILED_HEADER=0
48852        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48853$as_echo "no" >&6; }
48854      else
48855        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48856$as_echo "yes" >&6; }
48857      fi
48858      rm -f conftest.h conftest.hpp.gch
48859    fi
48860  fi
48861
48862
48863
48864
48865# Setup use of ccache, if available
48866
48867  # Check whether --enable-ccache was given.
48868if test "${enable_ccache+set}" = set; then :
48869  enableval=$enable_ccache;
48870fi
48871
48872
48873  CCACHE=
48874  { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48875$as_echo_n "checking is ccache enabled... " >&6; }
48876  ENABLE_CCACHE=$enable_ccache
48877  if test "x$enable_ccache" = xyes; then
48878    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48879$as_echo "yes" >&6; }
48880    OLD_PATH="$PATH"
48881    if test "x$TOOLCHAIN_PATH" != x; then
48882      PATH=$TOOLCHAIN_PATH:$PATH
48883    fi
48884
48885
48886
48887  # Publish this variable in the help.
48888
48889
48890  if test "x$CCACHE" = x; then
48891    # The variable is not set by user, try to locate tool using the code snippet
48892    for ac_prog in ccache
48893do
48894  # Extract the first word of "$ac_prog", so it can be a program name with args.
48895set dummy $ac_prog; ac_word=$2
48896{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48897$as_echo_n "checking for $ac_word... " >&6; }
48898if ${ac_cv_path_CCACHE+:} false; then :
48899  $as_echo_n "(cached) " >&6
48900else
48901  case $CCACHE in
48902  [\\/]* | ?:[\\/]*)
48903  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48904  ;;
48905  *)
48906  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48907for as_dir in $PATH
48908do
48909  IFS=$as_save_IFS
48910  test -z "$as_dir" && as_dir=.
48911    for ac_exec_ext in '' $ac_executable_extensions; do
48912  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48913    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48914    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48915    break 2
48916  fi
48917done
48918  done
48919IFS=$as_save_IFS
48920
48921  ;;
48922esac
48923fi
48924CCACHE=$ac_cv_path_CCACHE
48925if test -n "$CCACHE"; then
48926  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48927$as_echo "$CCACHE" >&6; }
48928else
48929  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48930$as_echo "no" >&6; }
48931fi
48932
48933
48934  test -n "$CCACHE" && break
48935done
48936
48937  else
48938    # The variable is set, but is it from the command line or the environment?
48939
48940    # Try to remove the string !CCACHE! from our list.
48941    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
48942    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
48943      # If it failed, the variable was not from the command line. Ignore it,
48944      # but warn the user (except for BASH, which is always set by the calling BASH).
48945      if test "xCCACHE" != xBASH; then
48946        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
48947$as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
48948      fi
48949      # Try to locate tool using the code snippet
48950      for ac_prog in ccache
48951do
48952  # Extract the first word of "$ac_prog", so it can be a program name with args.
48953set dummy $ac_prog; ac_word=$2
48954{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48955$as_echo_n "checking for $ac_word... " >&6; }
48956if ${ac_cv_path_CCACHE+:} false; then :
48957  $as_echo_n "(cached) " >&6
48958else
48959  case $CCACHE in
48960  [\\/]* | ?:[\\/]*)
48961  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48962  ;;
48963  *)
48964  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48965for as_dir in $PATH
48966do
48967  IFS=$as_save_IFS
48968  test -z "$as_dir" && as_dir=.
48969    for ac_exec_ext in '' $ac_executable_extensions; do
48970  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48971    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48972    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48973    break 2
48974  fi
48975done
48976  done
48977IFS=$as_save_IFS
48978
48979  ;;
48980esac
48981fi
48982CCACHE=$ac_cv_path_CCACHE
48983if test -n "$CCACHE"; then
48984  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48985$as_echo "$CCACHE" >&6; }
48986else
48987  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48988$as_echo "no" >&6; }
48989fi
48990
48991
48992  test -n "$CCACHE" && break
48993done
48994
48995    else
48996      # If it succeeded, then it was overridden by the user. We will use it
48997      # for the tool.
48998
48999      # First remove it from the list of overridden variables, so we can test
49000      # for unknown variables in the end.
49001      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
49002
49003      # Check if the provided tool contains a complete path.
49004      tool_specified="$CCACHE"
49005      tool_basename="${tool_specified##*/}"
49006      if test "x$tool_basename" = "x$tool_specified"; then
49007        # A command without a complete path is provided, search $PATH.
49008        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
49009$as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
49010        # Extract the first word of "$tool_basename", so it can be a program name with args.
49011set dummy $tool_basename; ac_word=$2
49012{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49013$as_echo_n "checking for $ac_word... " >&6; }
49014if ${ac_cv_path_CCACHE+:} false; then :
49015  $as_echo_n "(cached) " >&6
49016else
49017  case $CCACHE in
49018  [\\/]* | ?:[\\/]*)
49019  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
49020  ;;
49021  *)
49022  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49023for as_dir in $PATH
49024do
49025  IFS=$as_save_IFS
49026  test -z "$as_dir" && as_dir=.
49027    for ac_exec_ext in '' $ac_executable_extensions; do
49028  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49029    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
49030    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49031    break 2
49032  fi
49033done
49034  done
49035IFS=$as_save_IFS
49036
49037  ;;
49038esac
49039fi
49040CCACHE=$ac_cv_path_CCACHE
49041if test -n "$CCACHE"; then
49042  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
49043$as_echo "$CCACHE" >&6; }
49044else
49045  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49046$as_echo "no" >&6; }
49047fi
49048
49049
49050        if test "x$CCACHE" = x; then
49051          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
49052        fi
49053      else
49054        # Otherwise we believe it is a complete path. Use it as it is.
49055        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
49056$as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
49057        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
49058$as_echo_n "checking for CCACHE... " >&6; }
49059        if test ! -x "$tool_specified"; then
49060          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
49061$as_echo "not found" >&6; }
49062          as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
49063        fi
49064        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
49065$as_echo "$tool_specified" >&6; }
49066      fi
49067    fi
49068  fi
49069
49070
49071
49072  if test "x$CCACHE" = x; then
49073    as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
49074  fi
49075
49076
49077    CCACHE_STATUS="enabled"
49078    PATH="$OLD_PATH"
49079  elif test "x$enable_ccache" = xno; then
49080    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
49081$as_echo "no, explicitly disabled" >&6; }
49082  elif test "x$enable_ccache" = x; then
49083    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49084$as_echo "no" >&6; }
49085  else
49086    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
49087$as_echo "unknown" >&6; }
49088    as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
49089  fi
49090
49091
49092
49093# Check whether --with-ccache-dir was given.
49094if test "${with_ccache_dir+set}" = set; then :
49095  withval=$with_ccache_dir;
49096fi
49097
49098
49099  if test "x$with_ccache_dir" != x; then
49100    # When using a non home ccache directory, assume the use is to share ccache files
49101    # with other users. Thus change the umask.
49102    SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
49103    if test "x$CCACHE" = x; then
49104      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
49105$as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
49106    fi
49107  fi
49108
49109  if test "x$CCACHE" != x; then
49110
49111  if test "x$CCACHE" != x; then
49112    # Only use ccache if it is 3.1.4 or later, which supports
49113    # precompiled headers.
49114    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
49115$as_echo_n "checking if ccache supports precompiled headers... " >&6; }
49116    HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
49117    if test "x$HAS_GOOD_CCACHE" = x; then
49118      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
49119$as_echo "no, disabling ccache" >&6; }
49120      CCACHE=
49121      CCACHE_STATUS="disabled"
49122    else
49123      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49124$as_echo "yes" >&6; }
49125      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
49126$as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
49127      PUSHED_FLAGS="$CXXFLAGS"
49128      CXXFLAGS="-fpch-preprocess $CXXFLAGS"
49129      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49130/* end confdefs.h.  */
49131
49132int
49133main ()
49134{
49135
49136  ;
49137  return 0;
49138}
49139_ACEOF
49140if ac_fn_cxx_try_compile "$LINENO"; then :
49141  CC_KNOWS_CCACHE_TRICK=yes
49142else
49143  CC_KNOWS_CCACHE_TRICK=no
49144fi
49145rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
49146      CXXFLAGS="$PUSHED_FLAGS"
49147      if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
49148        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49149$as_echo "yes" >&6; }
49150      else
49151        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
49152$as_echo "no, disabling ccaching of precompiled headers" >&6; }
49153        CCACHE=
49154        CCACHE_STATUS="disabled"
49155      fi
49156    fi
49157  fi
49158
49159  if test "x$CCACHE" != x; then
49160    CCACHE_SLOPPINESS=time_macros
49161    CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
49162    CCACHE_FLAGS=-fpch-preprocess
49163
49164    if test "x$SET_CCACHE_DIR" != x; then
49165      mkdir -p $CCACHE_DIR > /dev/null 2>&1
49166      chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
49167    fi
49168  fi
49169
49170  fi
49171
49172
49173###############################################################################
49174#
49175# And now the finish...
49176#
49177###############################################################################
49178
49179# Check for some common pitfalls
49180
49181  if test x"$OPENJDK_BUILD_OS" = xwindows; then
49182    file_to_test="$SRC_ROOT/LICENSE"
49183    if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
49184      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
49185    fi
49186  fi
49187
49188
49189  # Did user specify any unknown variables?
49190
49191  if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
49192    # Replace the separating ! with spaces before presenting for end user.
49193    unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
49194    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
49195$as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
49196  fi
49197
49198
49199  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
49200$as_echo_n "checking if build directory is on local disk... " >&6; }
49201
49202  # df -l lists only local disks; if the given directory is not found then
49203  # a non-zero exit code is given
49204  if test "x$DF" = x; then
49205    if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
49206      # msys does not have df; use Windows "net use" instead.
49207      IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
49208      if test "x$IS_NETWORK_DISK" = x; then
49209        OUTPUT_DIR_IS_LOCAL="yes"
49210      else
49211        OUTPUT_DIR_IS_LOCAL="no"
49212      fi
49213    else
49214      # No df here, say it's local
49215      OUTPUT_DIR_IS_LOCAL="yes"
49216    fi
49217  else
49218    if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
49219      OUTPUT_DIR_IS_LOCAL="yes"
49220    else
49221      OUTPUT_DIR_IS_LOCAL="no"
49222    fi
49223  fi
49224
49225  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
49226$as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
49227
49228
49229
49230  # Check if the user has any old-style ALT_ variables set.
49231  FOUND_ALT_VARIABLES=`env | grep ^ALT_`
49232
49233  # Before generating output files, test if they exist. If they do, this is a reconfigure.
49234  # Since we can't properly handle the dependencies for this, warn the user about the situation
49235  if test -e $OUTPUT_ROOT/spec.gmk; then
49236    IS_RECONFIGURE=yes
49237  else
49238    IS_RECONFIGURE=no
49239  fi
49240
49241
49242# At the end, call the custom hook. (Dummy macro if no custom sources available)
49243
49244
49245# We're messing a bit with internal autoconf variables to put the config.status
49246# in the output directory instead of the current directory.
49247CONFIG_STATUS="$OUTPUT_ROOT/config.status"
49248
49249# Create the actual output files. Now the main work of configure is done.
49250cat >confcache <<\_ACEOF
49251# This file is a shell script that caches the results of configure
49252# tests run on this system so they can be shared between configure
49253# scripts and configure runs, see configure's option --config-cache.
49254# It is not useful on other systems.  If it contains results you don't
49255# want to keep, you may remove or edit it.
49256#
49257# config.status only pays attention to the cache file if you give it
49258# the --recheck option to rerun configure.
49259#
49260# `ac_cv_env_foo' variables (set or unset) will be overridden when
49261# loading this file, other *unset* `ac_cv_foo' will be assigned the
49262# following values.
49263
49264_ACEOF
49265
49266# The following way of writing the cache mishandles newlines in values,
49267# but we know of no workaround that is simple, portable, and efficient.
49268# So, we kill variables containing newlines.
49269# Ultrix sh set writes to stderr and can't be redirected directly,
49270# and sets the high bit in the cache file unless we assign to the vars.
49271(
49272  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
49273    eval ac_val=\$$ac_var
49274    case $ac_val in #(
49275    *${as_nl}*)
49276      case $ac_var in #(
49277      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
49278$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
49279      esac
49280      case $ac_var in #(
49281      _ | IFS | as_nl) ;; #(
49282      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
49283      *) { eval $ac_var=; unset $ac_var;} ;;
49284      esac ;;
49285    esac
49286  done
49287
49288  (set) 2>&1 |
49289    case $as_nl`(ac_space=' '; set) 2>&1` in #(
49290    *${as_nl}ac_space=\ *)
49291      # `set' does not quote correctly, so add quotes: double-quote
49292      # substitution turns \\\\ into \\, and sed turns \\ into \.
49293      sed -n \
49294	"s/'/'\\\\''/g;
49295	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
49296      ;; #(
49297    *)
49298      # `set' quotes correctly as required by POSIX, so do not add quotes.
49299      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
49300      ;;
49301    esac |
49302    sort
49303) |
49304  sed '
49305     /^ac_cv_env_/b end
49306     t clear
49307     :clear
49308     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
49309     t end
49310     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
49311     :end' >>confcache
49312if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
49313  if test -w "$cache_file"; then
49314    if test "x$cache_file" != "x/dev/null"; then
49315      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
49316$as_echo "$as_me: updating cache $cache_file" >&6;}
49317      if test ! -f "$cache_file" || test -h "$cache_file"; then
49318	cat confcache >"$cache_file"
49319      else
49320        case $cache_file in #(
49321        */* | ?:*)
49322	  mv -f confcache "$cache_file"$$ &&
49323	  mv -f "$cache_file"$$ "$cache_file" ;; #(
49324        *)
49325	  mv -f confcache "$cache_file" ;;
49326	esac
49327      fi
49328    fi
49329  else
49330    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
49331$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
49332  fi
49333fi
49334rm -f confcache
49335
49336test "x$prefix" = xNONE && prefix=$ac_default_prefix
49337# Let make expand exec_prefix.
49338test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
49339
49340DEFS=-DHAVE_CONFIG_H
49341
49342ac_libobjs=
49343ac_ltlibobjs=
49344U=
49345for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
49346  # 1. Remove the extension, and $U if already installed.
49347  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
49348  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
49349  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
49350  #    will be set to the directory where LIBOBJS objects are built.
49351  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
49352  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
49353done
49354LIBOBJS=$ac_libobjs
49355
49356LTLIBOBJS=$ac_ltlibobjs
49357
49358
49359
49360: "${CONFIG_STATUS=./config.status}"
49361ac_write_fail=0
49362ac_clean_files_save=$ac_clean_files
49363ac_clean_files="$ac_clean_files $CONFIG_STATUS"
49364{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
49365$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
49366as_write_fail=0
49367cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
49368#! $SHELL
49369# Generated by $as_me.
49370# Run this file to recreate the current configuration.
49371# Compiler output produced by configure, useful for debugging
49372# configure, is in config.log if it exists.
49373
49374debug=false
49375ac_cs_recheck=false
49376ac_cs_silent=false
49377
49378SHELL=\${CONFIG_SHELL-$SHELL}
49379export SHELL
49380_ASEOF
49381cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
49382## -------------------- ##
49383## M4sh Initialization. ##
49384## -------------------- ##
49385
49386# Be more Bourne compatible
49387DUALCASE=1; export DUALCASE # for MKS sh
49388if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
49389  emulate sh
49390  NULLCMD=:
49391  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
49392  # is contrary to our usage.  Disable this feature.
49393  alias -g '${1+"$@"}'='"$@"'
49394  setopt NO_GLOB_SUBST
49395else
49396  case `(set -o) 2>/dev/null` in #(
49397  *posix*) :
49398    set -o posix ;; #(
49399  *) :
49400     ;;
49401esac
49402fi
49403
49404
49405as_nl='
49406'
49407export as_nl
49408# Printing a long string crashes Solaris 7 /usr/bin/printf.
49409as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
49410as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
49411as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
49412# Prefer a ksh shell builtin over an external printf program on Solaris,
49413# but without wasting forks for bash or zsh.
49414if test -z "$BASH_VERSION$ZSH_VERSION" \
49415    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
49416  as_echo='print -r --'
49417  as_echo_n='print -rn --'
49418elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
49419  as_echo='printf %s\n'
49420  as_echo_n='printf %s'
49421else
49422  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
49423    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
49424    as_echo_n='/usr/ucb/echo -n'
49425  else
49426    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
49427    as_echo_n_body='eval
49428      arg=$1;
49429      case $arg in #(
49430      *"$as_nl"*)
49431	expr "X$arg" : "X\\(.*\\)$as_nl";
49432	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
49433      esac;
49434      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
49435    '
49436    export as_echo_n_body
49437    as_echo_n='sh -c $as_echo_n_body as_echo'
49438  fi
49439  export as_echo_body
49440  as_echo='sh -c $as_echo_body as_echo'
49441fi
49442
49443# The user is always right.
49444if test "${PATH_SEPARATOR+set}" != set; then
49445  PATH_SEPARATOR=:
49446  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
49447    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
49448      PATH_SEPARATOR=';'
49449  }
49450fi
49451
49452
49453# IFS
49454# We need space, tab and new line, in precisely that order.  Quoting is
49455# there to prevent editors from complaining about space-tab.
49456# (If _AS_PATH_WALK were called with IFS unset, it would disable word
49457# splitting by setting IFS to empty value.)
49458IFS=" ""	$as_nl"
49459
49460# Find who we are.  Look in the path if we contain no directory separator.
49461as_myself=
49462case $0 in #((
49463  *[\\/]* ) as_myself=$0 ;;
49464  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49465for as_dir in $PATH
49466do
49467  IFS=$as_save_IFS
49468  test -z "$as_dir" && as_dir=.
49469    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
49470  done
49471IFS=$as_save_IFS
49472
49473     ;;
49474esac
49475# We did not find ourselves, most probably we were run as `sh COMMAND'
49476# in which case we are not to be found in the path.
49477if test "x$as_myself" = x; then
49478  as_myself=$0
49479fi
49480if test ! -f "$as_myself"; then
49481  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
49482  exit 1
49483fi
49484
49485# Unset variables that we do not need and which cause bugs (e.g. in
49486# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
49487# suppresses any "Segmentation fault" message there.  '((' could
49488# trigger a bug in pdksh 5.2.14.
49489for as_var in BASH_ENV ENV MAIL MAILPATH
49490do eval test x\${$as_var+set} = xset \
49491  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
49492done
49493PS1='$ '
49494PS2='> '
49495PS4='+ '
49496
49497# NLS nuisances.
49498LC_ALL=C
49499export LC_ALL
49500LANGUAGE=C
49501export LANGUAGE
49502
49503# CDPATH.
49504(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
49505
49506
49507# as_fn_error STATUS ERROR [LINENO LOG_FD]
49508# ----------------------------------------
49509# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
49510# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
49511# script with STATUS, using 1 if that was 0.
49512as_fn_error ()
49513{
49514  as_status=$1; test $as_status -eq 0 && as_status=1
49515  if test "$4"; then
49516    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
49517    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
49518  fi
49519  $as_echo "$as_me: error: $2" >&2
49520  as_fn_exit $as_status
49521} # as_fn_error
49522
49523
49524# as_fn_set_status STATUS
49525# -----------------------
49526# Set $? to STATUS, without forking.
49527as_fn_set_status ()
49528{
49529  return $1
49530} # as_fn_set_status
49531
49532# as_fn_exit STATUS
49533# -----------------
49534# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
49535as_fn_exit ()
49536{
49537  set +e
49538  as_fn_set_status $1
49539  exit $1
49540} # as_fn_exit
49541
49542# as_fn_unset VAR
49543# ---------------
49544# Portably unset VAR.
49545as_fn_unset ()
49546{
49547  { eval $1=; unset $1;}
49548}
49549as_unset=as_fn_unset
49550# as_fn_append VAR VALUE
49551# ----------------------
49552# Append the text in VALUE to the end of the definition contained in VAR. Take
49553# advantage of any shell optimizations that allow amortized linear growth over
49554# repeated appends, instead of the typical quadratic growth present in naive
49555# implementations.
49556if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
49557  eval 'as_fn_append ()
49558  {
49559    eval $1+=\$2
49560  }'
49561else
49562  as_fn_append ()
49563  {
49564    eval $1=\$$1\$2
49565  }
49566fi # as_fn_append
49567
49568# as_fn_arith ARG...
49569# ------------------
49570# Perform arithmetic evaluation on the ARGs, and store the result in the
49571# global $as_val. Take advantage of shells that can avoid forks. The arguments
49572# must be portable across $(()) and expr.
49573if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
49574  eval 'as_fn_arith ()
49575  {
49576    as_val=$(( $* ))
49577  }'
49578else
49579  as_fn_arith ()
49580  {
49581    as_val=`expr "$@" || test $? -eq 1`
49582  }
49583fi # as_fn_arith
49584
49585
49586if expr a : '\(a\)' >/dev/null 2>&1 &&
49587   test "X`expr 00001 : '.*\(...\)'`" = X001; then
49588  as_expr=expr
49589else
49590  as_expr=false
49591fi
49592
49593if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
49594  as_basename=basename
49595else
49596  as_basename=false
49597fi
49598
49599if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
49600  as_dirname=dirname
49601else
49602  as_dirname=false
49603fi
49604
49605as_me=`$as_basename -- "$0" ||
49606$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
49607	 X"$0" : 'X\(//\)$' \| \
49608	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
49609$as_echo X/"$0" |
49610    sed '/^.*\/\([^/][^/]*\)\/*$/{
49611	    s//\1/
49612	    q
49613	  }
49614	  /^X\/\(\/\/\)$/{
49615	    s//\1/
49616	    q
49617	  }
49618	  /^X\/\(\/\).*/{
49619	    s//\1/
49620	    q
49621	  }
49622	  s/.*/./; q'`
49623
49624# Avoid depending upon Character Ranges.
49625as_cr_letters='abcdefghijklmnopqrstuvwxyz'
49626as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
49627as_cr_Letters=$as_cr_letters$as_cr_LETTERS
49628as_cr_digits='0123456789'
49629as_cr_alnum=$as_cr_Letters$as_cr_digits
49630
49631ECHO_C= ECHO_N= ECHO_T=
49632case `echo -n x` in #(((((
49633-n*)
49634  case `echo 'xy\c'` in
49635  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
49636  xy)  ECHO_C='\c';;
49637  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
49638       ECHO_T='	';;
49639  esac;;
49640*)
49641  ECHO_N='-n';;
49642esac
49643
49644rm -f conf$$ conf$$.exe conf$$.file
49645if test -d conf$$.dir; then
49646  rm -f conf$$.dir/conf$$.file
49647else
49648  rm -f conf$$.dir
49649  mkdir conf$$.dir 2>/dev/null
49650fi
49651if (echo >conf$$.file) 2>/dev/null; then
49652  if ln -s conf$$.file conf$$ 2>/dev/null; then
49653    as_ln_s='ln -s'
49654    # ... but there are two gotchas:
49655    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
49656    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
49657    # In both cases, we have to default to `cp -pR'.
49658    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
49659      as_ln_s='cp -pR'
49660  elif ln conf$$.file conf$$ 2>/dev/null; then
49661    as_ln_s=ln
49662  else
49663    as_ln_s='cp -pR'
49664  fi
49665else
49666  as_ln_s='cp -pR'
49667fi
49668rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
49669rmdir conf$$.dir 2>/dev/null
49670
49671
49672# as_fn_mkdir_p
49673# -------------
49674# Create "$as_dir" as a directory, including parents if necessary.
49675as_fn_mkdir_p ()
49676{
49677
49678  case $as_dir in #(
49679  -*) as_dir=./$as_dir;;
49680  esac
49681  test -d "$as_dir" || eval $as_mkdir_p || {
49682    as_dirs=
49683    while :; do
49684      case $as_dir in #(
49685      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
49686      *) as_qdir=$as_dir;;
49687      esac
49688      as_dirs="'$as_qdir' $as_dirs"
49689      as_dir=`$as_dirname -- "$as_dir" ||
49690$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49691	 X"$as_dir" : 'X\(//\)[^/]' \| \
49692	 X"$as_dir" : 'X\(//\)$' \| \
49693	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
49694$as_echo X"$as_dir" |
49695    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49696	    s//\1/
49697	    q
49698	  }
49699	  /^X\(\/\/\)[^/].*/{
49700	    s//\1/
49701	    q
49702	  }
49703	  /^X\(\/\/\)$/{
49704	    s//\1/
49705	    q
49706	  }
49707	  /^X\(\/\).*/{
49708	    s//\1/
49709	    q
49710	  }
49711	  s/.*/./; q'`
49712      test -d "$as_dir" && break
49713    done
49714    test -z "$as_dirs" || eval "mkdir $as_dirs"
49715  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
49716
49717
49718} # as_fn_mkdir_p
49719if mkdir -p . 2>/dev/null; then
49720  as_mkdir_p='mkdir -p "$as_dir"'
49721else
49722  test -d ./-p && rmdir ./-p
49723  as_mkdir_p=false
49724fi
49725
49726
49727# as_fn_executable_p FILE
49728# -----------------------
49729# Test if FILE is an executable regular file.
49730as_fn_executable_p ()
49731{
49732  test -f "$1" && test -x "$1"
49733} # as_fn_executable_p
49734as_test_x='test -x'
49735as_executable_p=as_fn_executable_p
49736
49737# Sed expression to map a string onto a valid CPP name.
49738as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
49739
49740# Sed expression to map a string onto a valid variable name.
49741as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
49742
49743
49744exec 6>&1
49745## ----------------------------------- ##
49746## Main body of $CONFIG_STATUS script. ##
49747## ----------------------------------- ##
49748_ASEOF
49749test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
49750
49751cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49752# Save the log message, to keep $0 and so on meaningful, and to
49753# report actual input values of CONFIG_FILES etc. instead of their
49754# values after options handling.
49755ac_log="
49756This file was extended by OpenJDK $as_me jdk9, which was
49757generated by GNU Autoconf 2.69.  Invocation command line was
49758
49759  CONFIG_FILES    = $CONFIG_FILES
49760  CONFIG_HEADERS  = $CONFIG_HEADERS
49761  CONFIG_LINKS    = $CONFIG_LINKS
49762  CONFIG_COMMANDS = $CONFIG_COMMANDS
49763  $ $0 $@
49764
49765on `(hostname || uname -n) 2>/dev/null | sed 1q`
49766"
49767
49768_ACEOF
49769
49770case $ac_config_files in *"
49771"*) set x $ac_config_files; shift; ac_config_files=$*;;
49772esac
49773
49774case $ac_config_headers in *"
49775"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
49776esac
49777
49778
49779cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49780# Files that config.status was made for.
49781config_files="$ac_config_files"
49782config_headers="$ac_config_headers"
49783
49784_ACEOF
49785
49786cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49787ac_cs_usage="\
49788\`$as_me' instantiates files and other configuration actions
49789from templates according to the current configuration.  Unless the files
49790and actions are specified as TAGs, all are instantiated by default.
49791
49792Usage: $0 [OPTION]... [TAG]...
49793
49794  -h, --help       print this help, then exit
49795  -V, --version    print version number and configuration settings, then exit
49796      --config     print configuration, then exit
49797  -q, --quiet, --silent
49798                   do not print progress messages
49799  -d, --debug      don't remove temporary files
49800      --recheck    update $as_me by reconfiguring in the same conditions
49801      --file=FILE[:TEMPLATE]
49802                   instantiate the configuration file FILE
49803      --header=FILE[:TEMPLATE]
49804                   instantiate the configuration header FILE
49805
49806Configuration files:
49807$config_files
49808
49809Configuration headers:
49810$config_headers
49811
49812Report bugs to <build-dev@openjdk.java.net>.
49813OpenJDK home page: <http://openjdk.java.net>."
49814
49815_ACEOF
49816cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49817ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
49818ac_cs_version="\\
49819OpenJDK config.status jdk9
49820configured by $0, generated by GNU Autoconf 2.69,
49821  with options \\"\$ac_cs_config\\"
49822
49823Copyright (C) 2012 Free Software Foundation, Inc.
49824This config.status script is free software; the Free Software Foundation
49825gives unlimited permission to copy, distribute and modify it."
49826
49827ac_pwd='$ac_pwd'
49828srcdir='$srcdir'
49829AWK='$AWK'
49830test -n "\$AWK" || AWK=awk
49831_ACEOF
49832
49833cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49834# The default lists apply if the user does not specify any file.
49835ac_need_defaults=:
49836while test $# != 0
49837do
49838  case $1 in
49839  --*=?*)
49840    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49841    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
49842    ac_shift=:
49843    ;;
49844  --*=)
49845    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49846    ac_optarg=
49847    ac_shift=:
49848    ;;
49849  *)
49850    ac_option=$1
49851    ac_optarg=$2
49852    ac_shift=shift
49853    ;;
49854  esac
49855
49856  case $ac_option in
49857  # Handling of the options.
49858  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
49859    ac_cs_recheck=: ;;
49860  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
49861    $as_echo "$ac_cs_version"; exit ;;
49862  --config | --confi | --conf | --con | --co | --c )
49863    $as_echo "$ac_cs_config"; exit ;;
49864  --debug | --debu | --deb | --de | --d | -d )
49865    debug=: ;;
49866  --file | --fil | --fi | --f )
49867    $ac_shift
49868    case $ac_optarg in
49869    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49870    '') as_fn_error $? "missing file argument" ;;
49871    esac
49872    as_fn_append CONFIG_FILES " '$ac_optarg'"
49873    ac_need_defaults=false;;
49874  --header | --heade | --head | --hea )
49875    $ac_shift
49876    case $ac_optarg in
49877    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49878    esac
49879    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
49880    ac_need_defaults=false;;
49881  --he | --h)
49882    # Conflict between --help and --header
49883    as_fn_error $? "ambiguous option: \`$1'
49884Try \`$0 --help' for more information.";;
49885  --help | --hel | -h )
49886    $as_echo "$ac_cs_usage"; exit ;;
49887  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
49888  | -silent | --silent | --silen | --sile | --sil | --si | --s)
49889    ac_cs_silent=: ;;
49890
49891  # This is an error.
49892  -*) as_fn_error $? "unrecognized option: \`$1'
49893Try \`$0 --help' for more information." ;;
49894
49895  *) as_fn_append ac_config_targets " $1"
49896     ac_need_defaults=false ;;
49897
49898  esac
49899  shift
49900done
49901
49902ac_configure_extra_args=
49903
49904if $ac_cs_silent; then
49905  exec 6>/dev/null
49906  ac_configure_extra_args="$ac_configure_extra_args --silent"
49907fi
49908
49909_ACEOF
49910cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49911if \$ac_cs_recheck; then
49912  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
49913  shift
49914  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
49915  CONFIG_SHELL='$SHELL'
49916  export CONFIG_SHELL
49917  exec "\$@"
49918fi
49919
49920_ACEOF
49921cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49922exec 5>>config.log
49923{
49924  echo
49925  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
49926## Running $as_me. ##
49927_ASBOX
49928  $as_echo "$ac_log"
49929} >&5
49930
49931_ACEOF
49932cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49933_ACEOF
49934
49935cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49936
49937# Handling of arguments.
49938for ac_config_target in $ac_config_targets
49939do
49940  case $ac_config_target in
49941    "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;;
49942    "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
49943    "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
49944    "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
49945    "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
49946    "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;;
49947    "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
49948
49949  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
49950  esac
49951done
49952
49953
49954# If the user did not use the arguments to specify the items to instantiate,
49955# then the envvar interface is used.  Set only those that are not.
49956# We use the long form for the default assignment because of an extremely
49957# bizarre bug on SunOS 4.1.3.
49958if $ac_need_defaults; then
49959  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
49960  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
49961fi
49962
49963# Have a temporary directory for convenience.  Make it in the build tree
49964# simply because there is no reason against having it here, and in addition,
49965# creating and moving files from /tmp can sometimes cause problems.
49966# Hook for its removal unless debugging.
49967# Note that there is a small window in which the directory will not be cleaned:
49968# after its creation but before its name has been assigned to `$tmp'.
49969$debug ||
49970{
49971  tmp= ac_tmp=
49972  trap 'exit_status=$?
49973  : "${ac_tmp:=$tmp}"
49974  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
49975' 0
49976  trap 'as_fn_exit 1' 1 2 13 15
49977}
49978# Create a (secure) tmp directory for tmp files.
49979
49980{
49981  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
49982  test -d "$tmp"
49983}  ||
49984{
49985  tmp=./conf$$-$RANDOM
49986  (umask 077 && mkdir "$tmp")
49987} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
49988ac_tmp=$tmp
49989
49990# Set up the scripts for CONFIG_FILES section.
49991# No need to generate them if there are no CONFIG_FILES.
49992# This happens for instance with `./config.status config.h'.
49993if test -n "$CONFIG_FILES"; then
49994
49995
49996ac_cr=`echo X | tr X '\015'`
49997# On cygwin, bash can eat \r inside `` if the user requested igncr.
49998# But we know of no other shell where ac_cr would be empty at this
49999# point, so we can use a bashism as a fallback.
50000if test "x$ac_cr" = x; then
50001  eval ac_cr=\$\'\\r\'
50002fi
50003ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
50004if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
50005  ac_cs_awk_cr='\\r'
50006else
50007  ac_cs_awk_cr=$ac_cr
50008fi
50009
50010echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
50011_ACEOF
50012
50013
50014{
50015  echo "cat >conf$$subs.awk <<_ACEOF" &&
50016  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
50017  echo "_ACEOF"
50018} >conf$$subs.sh ||
50019  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
50020ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
50021ac_delim='%!_!# '
50022for ac_last_try in false false false false false :; do
50023  . ./conf$$subs.sh ||
50024    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
50025
50026  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
50027  if test $ac_delim_n = $ac_delim_num; then
50028    break
50029  elif $ac_last_try; then
50030    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
50031  else
50032    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
50033  fi
50034done
50035rm -f conf$$subs.sh
50036
50037cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
50038cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
50039_ACEOF
50040sed -n '
50041h
50042s/^/S["/; s/!.*/"]=/
50043p
50044g
50045s/^[^!]*!//
50046:repl
50047t repl
50048s/'"$ac_delim"'$//
50049t delim
50050:nl
50051h
50052s/\(.\{148\}\)..*/\1/
50053t more1
50054s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
50055p
50056n
50057b repl
50058:more1
50059s/["\\]/\\&/g; s/^/"/; s/$/"\\/
50060p
50061g
50062s/.\{148\}//
50063t nl
50064:delim
50065h
50066s/\(.\{148\}\)..*/\1/
50067t more2
50068s/["\\]/\\&/g; s/^/"/; s/$/"/
50069p
50070b
50071:more2
50072s/["\\]/\\&/g; s/^/"/; s/$/"\\/
50073p
50074g
50075s/.\{148\}//
50076t delim
50077' <conf$$subs.awk | sed '
50078/^[^""]/{
50079  N
50080  s/\n//
50081}
50082' >>$CONFIG_STATUS || ac_write_fail=1
50083rm -f conf$$subs.awk
50084cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
50085_ACAWK
50086cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
50087  for (key in S) S_is_set[key] = 1
50088  FS = ""
50089
50090}
50091{
50092  line = $ 0
50093  nfields = split(line, field, "@")
50094  substed = 0
50095  len = length(field[1])
50096  for (i = 2; i < nfields; i++) {
50097    key = field[i]
50098    keylen = length(key)
50099    if (S_is_set[key]) {
50100      value = S[key]
50101      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
50102      len += length(value) + length(field[++i])
50103      substed = 1
50104    } else
50105      len += 1 + keylen
50106  }
50107
50108  print line
50109}
50110
50111_ACAWK
50112_ACEOF
50113cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
50114if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
50115  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
50116else
50117  cat
50118fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
50119  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
50120_ACEOF
50121
50122# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
50123# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
50124# trailing colons and then remove the whole line if VPATH becomes empty
50125# (actually we leave an empty line to preserve line numbers).
50126if test "x$srcdir" = x.; then
50127  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
50128h
50129s///
50130s/^/:/
50131s/[	 ]*$/:/
50132s/:\$(srcdir):/:/g
50133s/:\${srcdir}:/:/g
50134s/:@srcdir@:/:/g
50135s/^:*//
50136s/:*$//
50137x
50138s/\(=[	 ]*\).*/\1/
50139G
50140s/\n//
50141s/^[^=]*=[	 ]*$//
50142}'
50143fi
50144
50145cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
50146fi # test -n "$CONFIG_FILES"
50147
50148# Set up the scripts for CONFIG_HEADERS section.
50149# No need to generate them if there are no CONFIG_HEADERS.
50150# This happens for instance with `./config.status Makefile'.
50151if test -n "$CONFIG_HEADERS"; then
50152cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
50153BEGIN {
50154_ACEOF
50155
50156# Transform confdefs.h into an awk script `defines.awk', embedded as
50157# here-document in config.status, that substitutes the proper values into
50158# config.h.in to produce config.h.
50159
50160# Create a delimiter string that does not exist in confdefs.h, to ease
50161# handling of long lines.
50162ac_delim='%!_!# '
50163for ac_last_try in false false :; do
50164  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
50165  if test -z "$ac_tt"; then
50166    break
50167  elif $ac_last_try; then
50168    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
50169  else
50170    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
50171  fi
50172done
50173
50174# For the awk script, D is an array of macro values keyed by name,
50175# likewise P contains macro parameters if any.  Preserve backslash
50176# newline sequences.
50177
50178ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
50179sed -n '
50180s/.\{148\}/&'"$ac_delim"'/g
50181t rset
50182:rset
50183s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
50184t def
50185d
50186:def
50187s/\\$//
50188t bsnl
50189s/["\\]/\\&/g
50190s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
50191D["\1"]=" \3"/p
50192s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
50193d
50194:bsnl
50195s/["\\]/\\&/g
50196s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
50197D["\1"]=" \3\\\\\\n"\\/p
50198t cont
50199s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
50200t cont
50201d
50202:cont
50203n
50204s/.\{148\}/&'"$ac_delim"'/g
50205t clear
50206:clear
50207s/\\$//
50208t bsnlc
50209s/["\\]/\\&/g; s/^/"/; s/$/"/p
50210d
50211:bsnlc
50212s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
50213b cont
50214' <confdefs.h | sed '
50215s/'"$ac_delim"'/"\\\
50216"/g' >>$CONFIG_STATUS || ac_write_fail=1
50217
50218cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
50219  for (key in D) D_is_set[key] = 1
50220  FS = ""
50221}
50222/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
50223  line = \$ 0
50224  split(line, arg, " ")
50225  if (arg[1] == "#") {
50226    defundef = arg[2]
50227    mac1 = arg[3]
50228  } else {
50229    defundef = substr(arg[1], 2)
50230    mac1 = arg[2]
50231  }
50232  split(mac1, mac2, "(") #)
50233  macro = mac2[1]
50234  prefix = substr(line, 1, index(line, defundef) - 1)
50235  if (D_is_set[macro]) {
50236    # Preserve the white space surrounding the "#".
50237    print prefix "define", macro P[macro] D[macro]
50238    next
50239  } else {
50240    # Replace #undef with comments.  This is necessary, for example,
50241    # in the case of _POSIX_SOURCE, which is predefined and required
50242    # on some systems where configure will not decide to define it.
50243    if (defundef == "undef") {
50244      print "/*", prefix defundef, macro, "*/"
50245      next
50246    }
50247  }
50248}
50249{ print }
50250_ACAWK
50251_ACEOF
50252cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
50253  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
50254fi # test -n "$CONFIG_HEADERS"
50255
50256
50257eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
50258shift
50259for ac_tag
50260do
50261  case $ac_tag in
50262  :[FHLC]) ac_mode=$ac_tag; continue;;
50263  esac
50264  case $ac_mode$ac_tag in
50265  :[FHL]*:*);;
50266  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
50267  :[FH]-) ac_tag=-:-;;
50268  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
50269  esac
50270  ac_save_IFS=$IFS
50271  IFS=:
50272  set x $ac_tag
50273  IFS=$ac_save_IFS
50274  shift
50275  ac_file=$1
50276  shift
50277
50278  case $ac_mode in
50279  :L) ac_source=$1;;
50280  :[FH])
50281    ac_file_inputs=
50282    for ac_f
50283    do
50284      case $ac_f in
50285      -) ac_f="$ac_tmp/stdin";;
50286      *) # Look for the file first in the build tree, then in the source tree
50287	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
50288	 # because $ac_f cannot contain `:'.
50289	 test -f "$ac_f" ||
50290	   case $ac_f in
50291	   [\\/$]*) false;;
50292	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
50293	   esac ||
50294	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
50295      esac
50296      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
50297      as_fn_append ac_file_inputs " '$ac_f'"
50298    done
50299
50300    # Let's still pretend it is `configure' which instantiates (i.e., don't
50301    # use $as_me), people would be surprised to read:
50302    #    /* config.h.  Generated by config.status.  */
50303    configure_input='Generated from '`
50304	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
50305	`' by configure.'
50306    if test x"$ac_file" != x-; then
50307      configure_input="$ac_file.  $configure_input"
50308      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
50309$as_echo "$as_me: creating $ac_file" >&6;}
50310    fi
50311    # Neutralize special characters interpreted by sed in replacement strings.
50312    case $configure_input in #(
50313    *\&* | *\|* | *\\* )
50314       ac_sed_conf_input=`$as_echo "$configure_input" |
50315       sed 's/[\\\\&|]/\\\\&/g'`;; #(
50316    *) ac_sed_conf_input=$configure_input;;
50317    esac
50318
50319    case $ac_tag in
50320    *:-:* | *:-) cat >"$ac_tmp/stdin" \
50321      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
50322    esac
50323    ;;
50324  esac
50325
50326  ac_dir=`$as_dirname -- "$ac_file" ||
50327$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
50328	 X"$ac_file" : 'X\(//\)[^/]' \| \
50329	 X"$ac_file" : 'X\(//\)$' \| \
50330	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
50331$as_echo X"$ac_file" |
50332    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
50333	    s//\1/
50334	    q
50335	  }
50336	  /^X\(\/\/\)[^/].*/{
50337	    s//\1/
50338	    q
50339	  }
50340	  /^X\(\/\/\)$/{
50341	    s//\1/
50342	    q
50343	  }
50344	  /^X\(\/\).*/{
50345	    s//\1/
50346	    q
50347	  }
50348	  s/.*/./; q'`
50349  as_dir="$ac_dir"; as_fn_mkdir_p
50350  ac_builddir=.
50351
50352case "$ac_dir" in
50353.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
50354*)
50355  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
50356  # A ".." for each directory in $ac_dir_suffix.
50357  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
50358  case $ac_top_builddir_sub in
50359  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
50360  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
50361  esac ;;
50362esac
50363ac_abs_top_builddir=$ac_pwd
50364ac_abs_builddir=$ac_pwd$ac_dir_suffix
50365# for backward compatibility:
50366ac_top_builddir=$ac_top_build_prefix
50367
50368case $srcdir in
50369  .)  # We are building in place.
50370    ac_srcdir=.
50371    ac_top_srcdir=$ac_top_builddir_sub
50372    ac_abs_top_srcdir=$ac_pwd ;;
50373  [\\/]* | ?:[\\/]* )  # Absolute name.
50374    ac_srcdir=$srcdir$ac_dir_suffix;
50375    ac_top_srcdir=$srcdir
50376    ac_abs_top_srcdir=$srcdir ;;
50377  *) # Relative name.
50378    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
50379    ac_top_srcdir=$ac_top_build_prefix$srcdir
50380    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
50381esac
50382ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
50383
50384
50385  case $ac_mode in
50386  :F)
50387  #
50388  # CONFIG_FILE
50389  #
50390
50391_ACEOF
50392
50393cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
50394# If the template does not know about datarootdir, expand it.
50395# FIXME: This hack should be removed a few years after 2.60.
50396ac_datarootdir_hack=; ac_datarootdir_seen=
50397ac_sed_dataroot='
50398/datarootdir/ {
50399  p
50400  q
50401}
50402/@datadir@/p
50403/@docdir@/p
50404/@infodir@/p
50405/@localedir@/p
50406/@mandir@/p'
50407case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
50408*datarootdir*) ac_datarootdir_seen=yes;;
50409*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
50410  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
50411$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
50412_ACEOF
50413cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
50414  ac_datarootdir_hack='
50415  s&@datadir@&$datadir&g
50416  s&@docdir@&$docdir&g
50417  s&@infodir@&$infodir&g
50418  s&@localedir@&$localedir&g
50419  s&@mandir@&$mandir&g
50420  s&\\\${datarootdir}&$datarootdir&g' ;;
50421esac
50422_ACEOF
50423
50424# Neutralize VPATH when `$srcdir' = `.'.
50425# Shell code in configure.ac might set extrasub.
50426# FIXME: do we really want to maintain this feature?
50427cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
50428ac_sed_extra="$ac_vpsub
50429$extrasub
50430_ACEOF
50431cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
50432:t
50433/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
50434s|@configure_input@|$ac_sed_conf_input|;t t
50435s&@top_builddir@&$ac_top_builddir_sub&;t t
50436s&@top_build_prefix@&$ac_top_build_prefix&;t t
50437s&@srcdir@&$ac_srcdir&;t t
50438s&@abs_srcdir@&$ac_abs_srcdir&;t t
50439s&@top_srcdir@&$ac_top_srcdir&;t t
50440s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
50441s&@builddir@&$ac_builddir&;t t
50442s&@abs_builddir@&$ac_abs_builddir&;t t
50443s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
50444$ac_datarootdir_hack
50445"
50446eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
50447  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
50448
50449test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
50450  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
50451  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
50452      "$ac_tmp/out"`; test -z "$ac_out"; } &&
50453  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
50454which seems to be undefined.  Please make sure it is defined" >&5
50455$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
50456which seems to be undefined.  Please make sure it is defined" >&2;}
50457
50458  rm -f "$ac_tmp/stdin"
50459  case $ac_file in
50460  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
50461  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
50462  esac \
50463  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
50464 ;;
50465  :H)
50466  #
50467  # CONFIG_HEADER
50468  #
50469  if test x"$ac_file" != x-; then
50470    {
50471      $as_echo "/* $configure_input  */" \
50472      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
50473    } >"$ac_tmp/config.h" \
50474      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
50475    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
50476      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
50477$as_echo "$as_me: $ac_file is unchanged" >&6;}
50478    else
50479      rm -f "$ac_file"
50480      mv "$ac_tmp/config.h" "$ac_file" \
50481	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
50482    fi
50483  else
50484    $as_echo "/* $configure_input  */" \
50485      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
50486      || as_fn_error $? "could not create -" "$LINENO" 5
50487  fi
50488 ;;
50489
50490
50491  esac
50492
50493done # for ac_tag
50494
50495
50496as_fn_exit 0
50497_ACEOF
50498ac_clean_files=$ac_clean_files_save
50499
50500test $ac_write_fail = 0 ||
50501  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
50502
50503
50504# configure is writing to config.log, and then calls config.status.
50505# config.status does its own redirection, appending to config.log.
50506# Unfortunately, on DOS this fails, as config.log is still kept open
50507# by configure, so config.status won't be able to write to it; its
50508# output is simply discarded.  So we exec the FD to /dev/null,
50509# effectively closing config.log, so it can be properly (re)opened and
50510# appended to by config.status.  When coming back to configure, we
50511# need to make the FD available again.
50512if test "$no_create" != yes; then
50513  ac_cs_success=:
50514  ac_config_status_args=
50515  test "$silent" = yes &&
50516    ac_config_status_args="$ac_config_status_args --quiet"
50517  exec 5>/dev/null
50518  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
50519  exec 5>>config.log
50520  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
50521  # would make configure fail if this is the last instruction.
50522  $ac_cs_success || as_fn_exit 1
50523fi
50524if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
50525  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
50526$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
50527fi
50528
50529
50530# Try to move the config.log file to the output directory.
50531if test -e ./config.log; then
50532  $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
50533fi
50534
50535# Make the compare script executable
50536$CHMOD +x $OUTPUT_ROOT/compare.sh
50537
50538# Finally output some useful information to the user
50539
50540  # Finally output some useful information to the user
50541
50542  printf "\n"
50543  printf "====================================================\n"
50544  if test "x$no_create" != "xyes"; then
50545    if test "x$IS_RECONFIGURE" != "xyes"; then
50546      printf "A new configuration has been successfully created in\n %s\n" "$OUTPUT_ROOT"
50547    else
50548      printf "The existing configuration has been successfully updated in\n %s\n" "$OUTPUT_ROOT"
50549    fi
50550  else
50551    if test "x$IS_RECONFIGURE" != "xyes"; then
50552      printf "A configuration has been successfully checked but not created\n"
50553    else
50554      printf "The existing configuration has been successfully checked in\n %s\n" "$OUTPUT_ROOT"
50555    fi
50556  fi
50557  if test "x$CONFIGURE_COMMAND_LINE" != x; then
50558    printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
50559  else
50560    printf "using default settings.\n"
50561  fi
50562
50563  printf "\n"
50564  printf "Configuration summary:\n"
50565  printf "* Debug level:    $DEBUG_LEVEL\n"
50566  printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n"
50567  printf "* JDK variant:    $JDK_VARIANT\n"
50568  printf "* JVM variants:   $with_jvm_variants\n"
50569  printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
50570
50571  printf "\n"
50572  printf "Tools summary:\n"
50573  if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
50574    printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
50575  fi
50576  printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
50577  printf "* Toolchain:      $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)\n"
50578  printf "* C Compiler:     Version $CC_VERSION_NUMBER (at $CC)\n"
50579  printf "* C++ Compiler:   Version $CXX_VERSION_NUMBER (at $CXX)\n"
50580
50581  printf "\n"
50582  printf "Build performance summary:\n"
50583  printf "* Cores to use:   $JOBS\n"
50584  printf "* Memory limit:   $MEMORY_SIZE MB\n"
50585  if test "x$CCACHE_STATUS" != "x"; then
50586    printf "* ccache status:  $CCACHE_STATUS\n"
50587  fi
50588  printf "\n"
50589
50590  if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
50591    printf "NOTE: You have requested to build more than one version of the JVM, which\n"
50592    printf "will result in longer build times.\n"
50593    printf "\n"
50594  fi
50595
50596  if test "x$FOUND_ALT_VARIABLES" != "x"; then
50597    printf "WARNING: You have old-style ALT_ environment variables set.\n"
50598    printf "These are not respected, and will be ignored. It is recommended\n"
50599    printf "that you clean your environment. The following variables are set:\n"
50600    printf "$FOUND_ALT_VARIABLES\n"
50601    printf "\n"
50602  fi
50603
50604  if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
50605    printf "WARNING: Your build output directory is not on a local disk.\n"
50606    printf "This will severely degrade build performance!\n"
50607    printf "It is recommended that you create an output directory on a local disk,\n"
50608    printf "and run the configure script again from that directory.\n"
50609    printf "\n"
50610  fi
50611
50612  if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
50613    printf "WARNING: The result of this configuration has overridden an older\n"
50614    printf "configuration. You *should* run 'make clean' to make sure you get a\n"
50615    printf "proper build. Failure to do so might result in strange build problems.\n"
50616    printf "\n"
50617  fi
50618
50619  if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
50620    printf "WARNING: The result of this configuration was not saved.\n"
50621    printf "You should run without '--no-create | -n' to create the configuration.\n"
50622    printf "\n"
50623  fi
50624
50625