generated-configure.sh revision 979:e7872d8abd12
1#!/bin/bash
2#
3# ##########################################################
4# ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ###
5# ##########################################################
6#
7#! /bin/sh
8# Guess values for system-dependent variables and create Makefiles.
9# Generated by GNU Autoconf 2.69 for OpenJDK jdk8.
10#
11# Report bugs to <build-dev@openjdk.java.net>.
12#
13#
14# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
15#
16#
17# This configure script is free software; the Free Software Foundation
18# gives unlimited permission to copy, distribute and modify it.
19## -------------------- ##
20## M4sh Initialization. ##
21## -------------------- ##
22
23# Be more Bourne compatible
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='jdk8'
590PACKAGE_STRING='OpenJDK jdk8'
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_LIBGIF
657USE_EXTERNAL_LIBJPEG
658ALSA_LIBS
659ALSA_CFLAGS
660FREETYPE_BUNDLE_LIB_PATH
661FREETYPE_LIBS
662FREETYPE_CFLAGS
663CUPS_CFLAGS
664OPENWIN_HOME
665X_EXTRA_LIBS
666X_LIBS
667X_PRE_LIBS
668X_CFLAGS
669XMKMF
670FIXPATH
671ZIP_DEBUGINFO_FILES
672ENABLE_DEBUG_SYMBOLS
673COMPILER_SUPPORTS_TARGET_BITS_FLAG
674ZERO_ARCHFLAG
675LDFLAGS_CXX_JDK
676LDFLAGS_JDKEXE_SUFFIX
677LDFLAGS_JDKLIB_SUFFIX
678LDFLAGS_JDKEXE
679LDFLAGS_JDKLIB
680CXXFLAGS_JDKEXE
681CXXFLAGS_JDKLIB
682CFLAGS_JDKEXE
683CFLAGS_JDKLIB
684MACOSX_VERSION_MIN
685LEGACY_EXTRA_LDFLAGS
686LEGACY_EXTRA_CXXFLAGS
687LEGACY_EXTRA_CFLAGS
688CXX_O_FLAG_NONE
689CXX_O_FLAG_NORM
690CXX_O_FLAG_HI
691CXX_O_FLAG_HIGHEST
692C_O_FLAG_NONE
693C_O_FLAG_NORM
694C_O_FLAG_HI
695C_O_FLAG_HIGHEST
696CXXFLAGS_DEBUG_SYMBOLS
697CFLAGS_DEBUG_SYMBOLS
698CXX_FLAG_DEPS
699C_FLAG_DEPS
700SET_SHARED_LIBRARY_MAPFILE
701SET_SHARED_LIBRARY_NAME
702SET_SHARED_LIBRARY_ORIGIN
703SET_EXECUTABLE_ORIGIN
704SHARED_LIBRARY_FLAGS
705CXX_FLAG_REORDER
706C_FLAG_REORDER
707RC_FLAGS
708AR_OUT_OPTION
709LD_OUT_OPTION
710EXE_OUT_OPTION
711CC_OUT_OPTION
712POST_MCS_CMD
713POST_STRIP_CMD
714ARFLAGS
715COMPILER_TARGET_BITS_FLAG
716JT_HOME
717JTREGEXE
718USING_BROKEN_SUSE_LD
719PACKAGE_PATH
720LDEXECXX
721LDEXE
722USE_CLANG
723HOTSPOT_LD
724HOTSPOT_CXX
725HOTSPOT_RC
726HOTSPOT_MT
727BUILD_LD
728BUILD_CXX
729BUILD_CC
730ac_ct_OBJDUMP
731OBJDUMP
732ac_ct_OBJCOPY
733OBJCOPY
734ac_ct_NM
735ac_ct_STRIP
736MCS
737GNM
738NM
739STRIP
740DUMPBIN
741RC
742MT
743LIPO
744ac_ct_OBJC
745OBJCFLAGS
746OBJC
747ac_ct_AR
748AR
749AS
750LDCXX
751LD
752CXXCPP
753CPP
754ac_ct_CXX
755CXXFLAGS
756CXX
757ac_ct_PROPER_COMPILER_CXX
758PROPER_COMPILER_CXX
759TOOLS_DIR_CXX
760POTENTIAL_CXX
761OBJEXT
762EXEEXT
763ac_ct_CC
764CPPFLAGS
765LDFLAGS
766CFLAGS
767CC
768ac_ct_PROPER_COMPILER_CC
769PROPER_COMPILER_CC
770TOOLS_DIR_CC
771POTENTIAL_CC
772VS_PATH
773VS_LIB
774VS_INCLUDE
775CYGWIN_LINK
776EXE_SUFFIX
777OBJ_SUFFIX
778STATIC_LIBRARY
779SHARED_LIBRARY
780STATIC_LIBRARY_SUFFIX
781SHARED_LIBRARY_SUFFIX
782LIBRARY_PREFIX
783TOOLCHAIN_TYPE
784BUILD_HOTSPOT
785HOTSPOT_DIST
786BUILD_OUTPUT
787OVERRIDE_SRC_ROOT
788ADD_SRC_ROOT
789JDK_TOPDIR
790NASHORN_TOPDIR
791HOTSPOT_TOPDIR
792JAXWS_TOPDIR
793JAXP_TOPDIR
794CORBA_TOPDIR
795LANGTOOLS_TOPDIR
796BOOT_JDK_JVMARGS
797JAVAC_FLAGS
798BOOT_JDK_SOURCETARGET
799JARSIGNER
800NATIVE2ASCII
801JAR
802JAVAH
803JAVAC
804JAVA
805BOOT_JDK
806BOOT_TOOLSJAR
807BOOT_RTJAR
808JAVA_CHECK
809JAVAC_CHECK
810COOKED_BUILD_NUMBER
811JDK_VERSION
812COPYRIGHT_YEAR
813MACOSX_BUNDLE_ID_BASE
814MACOSX_BUNDLE_NAME_BASE
815COMPANY_NAME
816JDK_RC_PLATFORM_NAME
817PRODUCT_SUFFIX
818PRODUCT_NAME
819LAUNCHER_NAME
820MILESTONE
821JDK_BUILD_NUMBER
822JDK_UPDATE_VERSION
823JDK_MICRO_VERSION
824JDK_MINOR_VERSION
825JDK_MAJOR_VERSION
826USER_RELEASE_SUFFIX
827COMPRESS_JARS
828RMICONNECTOR_IIOP
829UNLIMITED_CRYPTO
830CACERTS_FILE
831TEST_IN_BUILD
832BUILD_HEADLESS
833SUPPORT_HEADFUL
834SUPPORT_HEADLESS
835BDEPS_FTP
836BDEPS_UNZIP
837OS_VERSION_MICRO
838OS_VERSION_MINOR
839OS_VERSION_MAJOR
840PKG_CONFIG
841CODESIGN
842XATTR
843DSYMUTIL
844IS_GNU_TIME
845TIME
846STAT
847HG
848READELF
849OTOOL
850LDD
851ZIP
852UNZIP
853FIND_DELETE
854MAKE
855CHECK_TOOLSDIR_MAKE
856CHECK_TOOLSDIR_GMAKE
857CHECK_MAKE
858CHECK_GMAKE
859PKGHANDLER
860OUTPUT_ROOT
861CONF_NAME
862SPEC
863BUILD_VARIANT_RELEASE
864DEBUG_CLASSFILES
865FASTDEBUG
866VARIANT
867DEBUG_LEVEL
868MACOSX_UNIVERSAL
869INCLUDE_SA
870JVM_VARIANT_CORE
871JVM_VARIANT_ZEROSHARK
872JVM_VARIANT_ZERO
873JVM_VARIANT_KERNEL
874JVM_VARIANT_MINIMAL1
875JVM_VARIANT_CLIENT
876JVM_VARIANT_SERVER
877JVM_VARIANTS
878JVM_INTERPRETER
879JDK_VARIANT
880SET_OPENJDK
881BUILD_LOG_WRAPPER
882BUILD_LOG_PREVIOUS
883BUILD_LOG
884SYS_ROOT
885PATH_SEP
886TOPDIR
887ZERO_ARCHDEF
888DEFINE_CROSS_COMPILE_ARCH
889LP64
890OPENJDK_TARGET_OS_EXPORT_DIR
891OPENJDK_TARGET_OS_API_DIR
892OPENJDK_TARGET_CPU_JLI_CFLAGS
893OPENJDK_TARGET_CPU_OSARCH
894OPENJDK_TARGET_CPU_ISADIR
895OPENJDK_TARGET_CPU_LIBDIR
896OPENJDK_TARGET_CPU_LEGACY_LIB
897OPENJDK_TARGET_CPU_LEGACY
898REQUIRED_OS_VERSION
899REQUIRED_OS_NAME
900COMPILE_TYPE
901OPENJDK_TARGET_CPU_ENDIAN
902OPENJDK_TARGET_CPU_BITS
903OPENJDK_TARGET_CPU_ARCH
904OPENJDK_TARGET_CPU
905OPENJDK_TARGET_OS_API
906OPENJDK_TARGET_OS
907OPENJDK_BUILD_CPU_ENDIAN
908OPENJDK_BUILD_CPU_BITS
909OPENJDK_BUILD_CPU_ARCH
910OPENJDK_BUILD_CPU
911OPENJDK_BUILD_OS_API
912OPENJDK_BUILD_OS
913OPENJDK_BUILD_AUTOCONF_NAME
914OPENJDK_TARGET_AUTOCONF_NAME
915target_os
916target_vendor
917target_cpu
918target
919host_os
920host_vendor
921host_cpu
922host
923build_os
924build_vendor
925build_cpu
926build
927SETFILE
928DF
929READLINK
930CYGPATH
931SED
932FGREP
933EGREP
934GREP
935AWK
936XARGS
937WHICH
938WC
939UNIQ
940UNAME
941TR
942TOUCH
943TEE
944TAR
945TAIL
946SORT
947SH
948RM
949PRINTF
950NAWK
951MV
952MKTEMP
953MKDIR
954LS
955LN
956HEAD
957FIND
958FILE
959EXPR
960ECHO
961DIRNAME
962DIFF
963DATE
964CUT
965CPIO
966CP
967COMM
968CMP
969CHMOD
970CAT
971BASH
972BASENAME
973DATE_WHEN_CONFIGURED
974CONFIGURE_COMMAND_LINE
975target_alias
976host_alias
977build_alias
978LIBS
979ECHO_T
980ECHO_N
981ECHO_C
982DEFS
983mandir
984localedir
985libdir
986psdir
987pdfdir
988dvidir
989htmldir
990infodir
991docdir
992oldincludedir
993includedir
994localstatedir
995sharedstatedir
996sysconfdir
997datadir
998datarootdir
999libexecdir
1000sbindir
1001bindir
1002program_transform_name
1003prefix
1004exec_prefix
1005PACKAGE_URL
1006PACKAGE_BUGREPORT
1007PACKAGE_STRING
1008PACKAGE_VERSION
1009PACKAGE_TARNAME
1010PACKAGE_NAME
1011PATH_SEPARATOR
1012SHELL'
1013ac_subst_files=''
1014ac_user_opts='
1015enable_option_checking
1016with_target_bits
1017with_sys_root
1018with_tools_dir
1019with_devkit
1020enable_openjdk_only
1021with_custom_make_dir
1022with_jdk_variant
1023with_jvm_interpreter
1024with_jvm_variants
1025enable_debug
1026with_debug_level
1027with_conf_name
1028with_builddeps_conf
1029with_builddeps_server
1030with_builddeps_dir
1031with_builddeps_group
1032enable_headful
1033enable_hotspot_test_in_build
1034with_cacerts_file
1035enable_unlimited_crypto
1036enable_rmiconnector_iiop
1037with_milestone
1038with_update_version
1039with_user_release_suffix
1040with_build_number
1041with_boot_jdk
1042with_boot_jdk_jvmargs
1043with_add_source_root
1044with_override_source_root
1045with_adds_and_overrides
1046with_override_langtools
1047with_override_corba
1048with_override_jaxp
1049with_override_jaxws
1050with_override_hotspot
1051with_override_nashorn
1052with_override_jdk
1053with_import_hotspot
1054with_toolchain_type
1055with_jtreg
1056with_extra_cflags
1057with_extra_cxxflags
1058with_extra_ldflags
1059enable_debug_symbols
1060enable_zip_debug_info
1061enable_macosx_runtime_support
1062with_x
1063with_cups
1064with_cups_include
1065with_freetype
1066with_freetype_include
1067with_freetype_lib
1068enable_freetype_bundling
1069with_alsa
1070with_alsa_include
1071with_alsa_lib
1072with_giflib
1073with_zlib
1074with_stdc__lib
1075with_msvcr_dll
1076with_dxsdk
1077with_dxsdk_lib
1078with_dxsdk_include
1079with_num_cores
1080with_memory_size
1081with_jobs
1082with_sjavac_server_java
1083enable_sjavac
1084enable_precompiled_headers
1085enable_ccache
1086with_ccache_dir
1087'
1088      ac_precious_vars='build_alias
1089host_alias
1090target_alias
1091BASENAME
1092BASH
1093CAT
1094CHMOD
1095CMP
1096COMM
1097CP
1098CPIO
1099CUT
1100DATE
1101DIFF
1102DIRNAME
1103ECHO
1104EXPR
1105FILE
1106FIND
1107HEAD
1108LN
1109LS
1110MKDIR
1111MKTEMP
1112MV
1113NAWK
1114PRINTF
1115RM
1116SH
1117SORT
1118TAIL
1119TAR
1120TEE
1121TOUCH
1122TR
1123UNAME
1124UNIQ
1125WC
1126WHICH
1127XARGS
1128AWK
1129GREP
1130EGREP
1131FGREP
1132SED
1133CYGPATH
1134READLINK
1135DF
1136SETFILE
1137UNZIP
1138ZIP
1139LDD
1140OTOOL
1141READELF
1142HG
1143STAT
1144TIME
1145DSYMUTIL
1146XATTR
1147CODESIGN
1148PKG_CONFIG
1149JAVA
1150JAVAC
1151JAVAH
1152JAR
1153NATIVE2ASCII
1154JARSIGNER
1155CC
1156CFLAGS
1157LDFLAGS
1158LIBS
1159CPPFLAGS
1160CXX
1161CXXFLAGS
1162CCC
1163CPP
1164CXXCPP
1165AS
1166AR
1167OBJC
1168OBJCFLAGS
1169LIPO
1170STRIP
1171NM
1172GNM
1173MCS
1174OBJCOPY
1175OBJDUMP
1176BUILD_CC
1177BUILD_CXX
1178BUILD_LD
1179JTREGEXE
1180XMKMF
1181FREETYPE_CFLAGS
1182FREETYPE_LIBS
1183ALSA_CFLAGS
1184ALSA_LIBS
1185LIBFFI_CFLAGS
1186LIBFFI_LIBS
1187CCACHE'
1188
1189
1190# Initialize some variables set by options.
1191ac_init_help=
1192ac_init_version=false
1193ac_unrecognized_opts=
1194ac_unrecognized_sep=
1195# The variables have the same names as the options, with
1196# dashes changed to underlines.
1197cache_file=/dev/null
1198exec_prefix=NONE
1199no_create=
1200no_recursion=
1201prefix=NONE
1202program_prefix=NONE
1203program_suffix=NONE
1204program_transform_name=s,x,x,
1205silent=
1206site=
1207srcdir=
1208verbose=
1209x_includes=NONE
1210x_libraries=NONE
1211
1212# Installation directory options.
1213# These are left unexpanded so users can "make install exec_prefix=/foo"
1214# and all the variables that are supposed to be based on exec_prefix
1215# by default will actually change.
1216# Use braces instead of parens because sh, perl, etc. also accept them.
1217# (The list follows the same order as the GNU Coding Standards.)
1218bindir='${exec_prefix}/bin'
1219sbindir='${exec_prefix}/sbin'
1220libexecdir='${exec_prefix}/libexec'
1221datarootdir='${prefix}/share'
1222datadir='${datarootdir}'
1223sysconfdir='${prefix}/etc'
1224sharedstatedir='${prefix}/com'
1225localstatedir='${prefix}/var'
1226includedir='${prefix}/include'
1227oldincludedir='/usr/include'
1228docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1229infodir='${datarootdir}/info'
1230htmldir='${docdir}'
1231dvidir='${docdir}'
1232pdfdir='${docdir}'
1233psdir='${docdir}'
1234libdir='${exec_prefix}/lib'
1235localedir='${datarootdir}/locale'
1236mandir='${datarootdir}/man'
1237
1238ac_prev=
1239ac_dashdash=
1240for ac_option
1241do
1242  # If the previous option needs an argument, assign it.
1243  if test -n "$ac_prev"; then
1244    eval $ac_prev=\$ac_option
1245    ac_prev=
1246    continue
1247  fi
1248
1249  case $ac_option in
1250  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1251  *=)   ac_optarg= ;;
1252  *)    ac_optarg=yes ;;
1253  esac
1254
1255  # Accept the important Cygnus configure options, so we can diagnose typos.
1256
1257  case $ac_dashdash$ac_option in
1258  --)
1259    ac_dashdash=yes ;;
1260
1261  -bindir | --bindir | --bindi | --bind | --bin | --bi)
1262    ac_prev=bindir ;;
1263  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1264    bindir=$ac_optarg ;;
1265
1266  -build | --build | --buil | --bui | --bu)
1267    ac_prev=build_alias ;;
1268  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1269    build_alias=$ac_optarg ;;
1270
1271  -cache-file | --cache-file | --cache-fil | --cache-fi \
1272  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1273    ac_prev=cache_file ;;
1274  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1275  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1276    cache_file=$ac_optarg ;;
1277
1278  --config-cache | -C)
1279    cache_file=config.cache ;;
1280
1281  -datadir | --datadir | --datadi | --datad)
1282    ac_prev=datadir ;;
1283  -datadir=* | --datadir=* | --datadi=* | --datad=*)
1284    datadir=$ac_optarg ;;
1285
1286  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1287  | --dataroo | --dataro | --datar)
1288    ac_prev=datarootdir ;;
1289  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1290  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1291    datarootdir=$ac_optarg ;;
1292
1293  -disable-* | --disable-*)
1294    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1295    # Reject names that are not valid shell variable names.
1296    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1297      as_fn_error $? "invalid feature name: $ac_useropt"
1298    ac_useropt_orig=$ac_useropt
1299    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1300    case $ac_user_opts in
1301      *"
1302"enable_$ac_useropt"
1303"*) ;;
1304      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1305	 ac_unrecognized_sep=', ';;
1306    esac
1307    eval enable_$ac_useropt=no ;;
1308
1309  -docdir | --docdir | --docdi | --doc | --do)
1310    ac_prev=docdir ;;
1311  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1312    docdir=$ac_optarg ;;
1313
1314  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1315    ac_prev=dvidir ;;
1316  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1317    dvidir=$ac_optarg ;;
1318
1319  -enable-* | --enable-*)
1320    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1321    # Reject names that are not valid shell variable names.
1322    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1323      as_fn_error $? "invalid feature name: $ac_useropt"
1324    ac_useropt_orig=$ac_useropt
1325    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1326    case $ac_user_opts in
1327      *"
1328"enable_$ac_useropt"
1329"*) ;;
1330      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1331	 ac_unrecognized_sep=', ';;
1332    esac
1333    eval enable_$ac_useropt=\$ac_optarg ;;
1334
1335  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1336  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1337  | --exec | --exe | --ex)
1338    ac_prev=exec_prefix ;;
1339  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1340  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1341  | --exec=* | --exe=* | --ex=*)
1342    exec_prefix=$ac_optarg ;;
1343
1344  -gas | --gas | --ga | --g)
1345    # Obsolete; use --with-gas.
1346    with_gas=yes ;;
1347
1348  -help | --help | --hel | --he | -h)
1349    ac_init_help=long ;;
1350  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1351    ac_init_help=recursive ;;
1352  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1353    ac_init_help=short ;;
1354
1355  -host | --host | --hos | --ho)
1356    ac_prev=host_alias ;;
1357  -host=* | --host=* | --hos=* | --ho=*)
1358    host_alias=$ac_optarg ;;
1359
1360  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1361    ac_prev=htmldir ;;
1362  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1363  | --ht=*)
1364    htmldir=$ac_optarg ;;
1365
1366  -includedir | --includedir | --includedi | --included | --include \
1367  | --includ | --inclu | --incl | --inc)
1368    ac_prev=includedir ;;
1369  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1370  | --includ=* | --inclu=* | --incl=* | --inc=*)
1371    includedir=$ac_optarg ;;
1372
1373  -infodir | --infodir | --infodi | --infod | --info | --inf)
1374    ac_prev=infodir ;;
1375  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1376    infodir=$ac_optarg ;;
1377
1378  -libdir | --libdir | --libdi | --libd)
1379    ac_prev=libdir ;;
1380  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1381    libdir=$ac_optarg ;;
1382
1383  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1384  | --libexe | --libex | --libe)
1385    ac_prev=libexecdir ;;
1386  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1387  | --libexe=* | --libex=* | --libe=*)
1388    libexecdir=$ac_optarg ;;
1389
1390  -localedir | --localedir | --localedi | --localed | --locale)
1391    ac_prev=localedir ;;
1392  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1393    localedir=$ac_optarg ;;
1394
1395  -localstatedir | --localstatedir | --localstatedi | --localstated \
1396  | --localstate | --localstat | --localsta | --localst | --locals)
1397    ac_prev=localstatedir ;;
1398  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1399  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1400    localstatedir=$ac_optarg ;;
1401
1402  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1403    ac_prev=mandir ;;
1404  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1405    mandir=$ac_optarg ;;
1406
1407  -nfp | --nfp | --nf)
1408    # Obsolete; use --without-fp.
1409    with_fp=no ;;
1410
1411  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1412  | --no-cr | --no-c | -n)
1413    no_create=yes ;;
1414
1415  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1416  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1417    no_recursion=yes ;;
1418
1419  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1420  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1421  | --oldin | --oldi | --old | --ol | --o)
1422    ac_prev=oldincludedir ;;
1423  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1424  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1425  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1426    oldincludedir=$ac_optarg ;;
1427
1428  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1429    ac_prev=prefix ;;
1430  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1431    prefix=$ac_optarg ;;
1432
1433  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1434  | --program-pre | --program-pr | --program-p)
1435    ac_prev=program_prefix ;;
1436  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1437  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1438    program_prefix=$ac_optarg ;;
1439
1440  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1441  | --program-suf | --program-su | --program-s)
1442    ac_prev=program_suffix ;;
1443  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1444  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1445    program_suffix=$ac_optarg ;;
1446
1447  -program-transform-name | --program-transform-name \
1448  | --program-transform-nam | --program-transform-na \
1449  | --program-transform-n | --program-transform- \
1450  | --program-transform | --program-transfor \
1451  | --program-transfo | --program-transf \
1452  | --program-trans | --program-tran \
1453  | --progr-tra | --program-tr | --program-t)
1454    ac_prev=program_transform_name ;;
1455  -program-transform-name=* | --program-transform-name=* \
1456  | --program-transform-nam=* | --program-transform-na=* \
1457  | --program-transform-n=* | --program-transform-=* \
1458  | --program-transform=* | --program-transfor=* \
1459  | --program-transfo=* | --program-transf=* \
1460  | --program-trans=* | --program-tran=* \
1461  | --progr-tra=* | --program-tr=* | --program-t=*)
1462    program_transform_name=$ac_optarg ;;
1463
1464  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1465    ac_prev=pdfdir ;;
1466  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1467    pdfdir=$ac_optarg ;;
1468
1469  -psdir | --psdir | --psdi | --psd | --ps)
1470    ac_prev=psdir ;;
1471  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1472    psdir=$ac_optarg ;;
1473
1474  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1475  | -silent | --silent | --silen | --sile | --sil)
1476    silent=yes ;;
1477
1478  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1479    ac_prev=sbindir ;;
1480  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1481  | --sbi=* | --sb=*)
1482    sbindir=$ac_optarg ;;
1483
1484  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1485  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1486  | --sharedst | --shareds | --shared | --share | --shar \
1487  | --sha | --sh)
1488    ac_prev=sharedstatedir ;;
1489  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1490  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1491  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1492  | --sha=* | --sh=*)
1493    sharedstatedir=$ac_optarg ;;
1494
1495  -site | --site | --sit)
1496    ac_prev=site ;;
1497  -site=* | --site=* | --sit=*)
1498    site=$ac_optarg ;;
1499
1500  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1501    ac_prev=srcdir ;;
1502  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1503    srcdir=$ac_optarg ;;
1504
1505  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1506  | --syscon | --sysco | --sysc | --sys | --sy)
1507    ac_prev=sysconfdir ;;
1508  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1509  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1510    sysconfdir=$ac_optarg ;;
1511
1512  -target | --target | --targe | --targ | --tar | --ta | --t)
1513    ac_prev=target_alias ;;
1514  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1515    target_alias=$ac_optarg ;;
1516
1517  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1518    verbose=yes ;;
1519
1520  -version | --version | --versio | --versi | --vers | -V)
1521    ac_init_version=: ;;
1522
1523  -with-* | --with-*)
1524    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1525    # Reject names that are not valid shell variable names.
1526    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1527      as_fn_error $? "invalid package name: $ac_useropt"
1528    ac_useropt_orig=$ac_useropt
1529    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1530    case $ac_user_opts in
1531      *"
1532"with_$ac_useropt"
1533"*) ;;
1534      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1535	 ac_unrecognized_sep=', ';;
1536    esac
1537    eval with_$ac_useropt=\$ac_optarg ;;
1538
1539  -without-* | --without-*)
1540    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1541    # Reject names that are not valid shell variable names.
1542    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1543      as_fn_error $? "invalid package name: $ac_useropt"
1544    ac_useropt_orig=$ac_useropt
1545    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1546    case $ac_user_opts in
1547      *"
1548"with_$ac_useropt"
1549"*) ;;
1550      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1551	 ac_unrecognized_sep=', ';;
1552    esac
1553    eval with_$ac_useropt=no ;;
1554
1555  --x)
1556    # Obsolete; use --with-x.
1557    with_x=yes ;;
1558
1559  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1560  | --x-incl | --x-inc | --x-in | --x-i)
1561    ac_prev=x_includes ;;
1562  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1563  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1564    x_includes=$ac_optarg ;;
1565
1566  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1567  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1568    ac_prev=x_libraries ;;
1569  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1570  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1571    x_libraries=$ac_optarg ;;
1572
1573  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1574Try \`$0 --help' for more information"
1575    ;;
1576
1577  *=*)
1578    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1579    # Reject names that are not valid shell variable names.
1580    case $ac_envvar in #(
1581      '' | [0-9]* | *[!_$as_cr_alnum]* )
1582      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1583    esac
1584    eval $ac_envvar=\$ac_optarg
1585    export $ac_envvar ;;
1586
1587  *)
1588    # FIXME: should be removed in autoconf 3.0.
1589    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1590    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1591      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1592    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1593    ;;
1594
1595  esac
1596done
1597
1598if test -n "$ac_prev"; then
1599  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1600  as_fn_error $? "missing argument to $ac_option"
1601fi
1602
1603if test -n "$ac_unrecognized_opts"; then
1604  case $enable_option_checking in
1605    no) ;;
1606    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1607    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1608  esac
1609fi
1610
1611# Check all directory arguments for consistency.
1612for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1613		datadir sysconfdir sharedstatedir localstatedir includedir \
1614		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1615		libdir localedir mandir
1616do
1617  eval ac_val=\$$ac_var
1618  # Remove trailing slashes.
1619  case $ac_val in
1620    */ )
1621      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1622      eval $ac_var=\$ac_val;;
1623  esac
1624  # Be sure to have absolute directory names.
1625  case $ac_val in
1626    [\\/$]* | ?:[\\/]* )  continue;;
1627    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1628  esac
1629  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1630done
1631
1632# There might be people who depend on the old broken behavior: `$host'
1633# used to hold the argument of --host etc.
1634# FIXME: To remove some day.
1635build=$build_alias
1636host=$host_alias
1637target=$target_alias
1638
1639# FIXME: To remove some day.
1640if test "x$host_alias" != x; then
1641  if test "x$build_alias" = x; then
1642    cross_compiling=maybe
1643  elif test "x$build_alias" != "x$host_alias"; then
1644    cross_compiling=yes
1645  fi
1646fi
1647
1648ac_tool_prefix=
1649test -n "$host_alias" && ac_tool_prefix=$host_alias-
1650
1651test "$silent" = yes && exec 6>/dev/null
1652
1653
1654ac_pwd=`pwd` && test -n "$ac_pwd" &&
1655ac_ls_di=`ls -di .` &&
1656ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1657  as_fn_error $? "working directory cannot be determined"
1658test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1659  as_fn_error $? "pwd does not report name of working directory"
1660
1661
1662# Find the source files, if location was not specified.
1663if test -z "$srcdir"; then
1664  ac_srcdir_defaulted=yes
1665  # Try the directory containing this script, then the parent directory.
1666  ac_confdir=`$as_dirname -- "$as_myself" ||
1667$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1668	 X"$as_myself" : 'X\(//\)[^/]' \| \
1669	 X"$as_myself" : 'X\(//\)$' \| \
1670	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1671$as_echo X"$as_myself" |
1672    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1673	    s//\1/
1674	    q
1675	  }
1676	  /^X\(\/\/\)[^/].*/{
1677	    s//\1/
1678	    q
1679	  }
1680	  /^X\(\/\/\)$/{
1681	    s//\1/
1682	    q
1683	  }
1684	  /^X\(\/\).*/{
1685	    s//\1/
1686	    q
1687	  }
1688	  s/.*/./; q'`
1689  srcdir=$ac_confdir
1690  if test ! -r "$srcdir/$ac_unique_file"; then
1691    srcdir=..
1692  fi
1693else
1694  ac_srcdir_defaulted=no
1695fi
1696if test ! -r "$srcdir/$ac_unique_file"; then
1697  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1698  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1699fi
1700ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1701ac_abs_confdir=`(
1702	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1703	pwd)`
1704# When building in place, set srcdir=.
1705if test "$ac_abs_confdir" = "$ac_pwd"; then
1706  srcdir=.
1707fi
1708# Remove unnecessary trailing slashes from srcdir.
1709# Double slashes in file names in object file debugging info
1710# mess up M-x gdb in Emacs.
1711case $srcdir in
1712*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1713esac
1714for ac_var in $ac_precious_vars; do
1715  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1716  eval ac_env_${ac_var}_value=\$${ac_var}
1717  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1718  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1719done
1720
1721#
1722# Report the --help message.
1723#
1724if test "$ac_init_help" = "long"; then
1725  # Omit some internal or obsolete options to make the list less imposing.
1726  # This message is too long to be a string in the A/UX 3.1 sh.
1727  cat <<_ACEOF
1728\`configure' configures OpenJDK jdk8 to adapt to many kinds of systems.
1729
1730Usage: $0 [OPTION]... [VAR=VALUE]...
1731
1732To assign environment variables (e.g., CC, CFLAGS...), specify them as
1733VAR=VALUE.  See below for descriptions of some of the useful variables.
1734
1735Defaults for the options are specified in brackets.
1736
1737Configuration:
1738  -h, --help              display this help and exit
1739      --help=short        display options specific to this package
1740      --help=recursive    display the short help of all the included packages
1741  -V, --version           display version information and exit
1742  -q, --quiet, --silent   do not print \`checking ...' messages
1743      --cache-file=FILE   cache test results in FILE [disabled]
1744  -C, --config-cache      alias for \`--cache-file=config.cache'
1745  -n, --no-create         do not create output files
1746      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1747
1748Installation directories:
1749  --prefix=PREFIX         install architecture-independent files in PREFIX
1750                          [$ac_default_prefix]
1751  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1752                          [PREFIX]
1753
1754By default, \`make install' will install all the files in
1755\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1756an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1757for instance \`--prefix=\$HOME'.
1758
1759For better control, use the options below.
1760
1761Fine tuning of the installation directories:
1762  --bindir=DIR            user executables [EPREFIX/bin]
1763  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1764  --libexecdir=DIR        program executables [EPREFIX/libexec]
1765  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1766  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1767  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1768  --libdir=DIR            object code libraries [EPREFIX/lib]
1769  --includedir=DIR        C header files [PREFIX/include]
1770  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1771  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1772  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1773  --infodir=DIR           info documentation [DATAROOTDIR/info]
1774  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1775  --mandir=DIR            man documentation [DATAROOTDIR/man]
1776  --docdir=DIR            documentation root [DATAROOTDIR/doc/openjdk]
1777  --htmldir=DIR           html documentation [DOCDIR]
1778  --dvidir=DIR            dvi documentation [DOCDIR]
1779  --pdfdir=DIR            pdf documentation [DOCDIR]
1780  --psdir=DIR             ps documentation [DOCDIR]
1781_ACEOF
1782
1783  cat <<\_ACEOF
1784
1785X features:
1786  --x-includes=DIR    X include files are in DIR
1787  --x-libraries=DIR   X library files are in DIR
1788
1789System types:
1790  --build=BUILD     configure for building on BUILD [guessed]
1791  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1792  --target=TARGET   configure for building compilers for TARGET [HOST]
1793_ACEOF
1794fi
1795
1796if test -n "$ac_init_help"; then
1797  case $ac_init_help in
1798     short | recursive ) echo "Configuration of OpenJDK jdk8:";;
1799   esac
1800  cat <<\_ACEOF
1801
1802Optional Features:
1803  --disable-option-checking  ignore unrecognized --enable/--with options
1804  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1805  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1806  --enable-openjdk-only   suppress building custom source even if present
1807                          [disabled]
1808  --enable-debug          set the debug level to fastdebug (shorthand for
1809                          --with-debug-level=fastdebug) [disabled]
1810  --disable-headful       disable building headful support (graphical UI
1811                          support) [enabled]
1812  --enable-hotspot-test-in-build
1813                          run the Queens test after Hotspot build [disabled]
1814  --enable-unlimited-crypto
1815                          Enable unlimited crypto policy [disabled]
1816  --enable-rmiconnector-iiop
1817                          enable the JMX RMIConnector iiop transport
1818                          [disabled]
1819  --disable-debug-symbols disable generation of debug symbols [enabled]
1820  --disable-zip-debug-info
1821                          disable zipping of debug-info files [enabled]
1822  --enable-macosx-runtime-support
1823                          Deprecated. Option is kept for backwards
1824                          compatibility and is ignored
1825  --disable-freetype-bundling
1826                          disable bundling of the freetype library with the
1827                          build result [enabled on Windows or when using
1828                          --with-freetype, disabled otherwise]
1829  --enable-sjavac         use sjavac to do fast incremental compiles
1830                          [disabled]
1831  --disable-precompiled-headers
1832                          disable using precompiled headers when compiling C++
1833                          [enabled]
1834  --enable-ccache         enable using ccache to speed up recompilations
1835                          [disabled]
1836
1837Optional Packages:
1838  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1839  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1840  --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1841                          support it), e.g. --with-target-bits=32 [guessed]
1842  --with-sys-root         pass this sys-root to the compilers and tools (for
1843                          cross-compiling)
1844  --with-tools-dir        search this directory for compilers and tools (for
1845                          cross-compiling)
1846  --with-devkit           use this directory as base for tools-dir and
1847                          sys-root (for cross-compiling)
1848  --with-custom-make-dir  Deprecated. Option is kept for backwards
1849                          compatibility and is ignored
1850  --with-jdk-variant      JDK variant to build (normal) [normal]
1851  --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1852  --with-jvm-variants     JVM variants (separated by commas) to build (server,
1853                          client, minimal1, kernel, zero, zeroshark, core)
1854                          [server]
1855  --with-debug-level      set the debug level (release, fastdebug, slowdebug)
1856                          [release]
1857  --with-conf-name        use this as the name of the configuration [generated
1858                          from important configuration options]
1859  --with-builddeps-conf   use this configuration file for the builddeps
1860  --with-builddeps-server download and use build dependencies from this server
1861                          url
1862  --with-builddeps-dir    store downloaded build dependencies here
1863                          [/localhome/builddeps]
1864  --with-builddeps-group  chgrp the downloaded build dependencies to this
1865                          group
1866  --with-cacerts-file     specify alternative cacerts file
1867  --with-milestone        Set milestone value for build [internal]
1868  --with-update-version   Set update version value for build [b00]
1869  --with-user-release-suffix
1870                          Add a custom string to the version string if build
1871                          number is not set.[username_builddateb00]
1872  --with-build-number     Set build number value for build [b00]
1873  --with-boot-jdk         path to Boot JDK (used to bootstrap build) [probed]
1874  --with-boot-jdk-jvmargs specify JVM arguments to be passed to all
1875                          invocations of the Boot JDK, overriding the default
1876                          values, e.g --with-boot-jdk-jvmargs="-Xmx8G
1877                          -enableassertions"
1878  --with-add-source-root  for each and every source directory, look in this
1879                          additional source root for the same directory; if it
1880                          exists and have files in it, include it in the build
1881  --with-override-source-root
1882                          for each and every source directory, look in this
1883                          override source root for the same directory; if it
1884                          exists, use that directory instead and ignore the
1885                          directory in the original source root
1886  --with-adds-and-overrides
1887                          use the subdirs 'adds' and 'overrides' in the
1888                          specified directory as add-source-root and
1889                          override-source-root
1890  --with-override-langtools
1891                          use this langtools dir for the build
1892  --with-override-corba   use this corba dir for the build
1893  --with-override-jaxp    use this jaxp dir for the build
1894  --with-override-jaxws   use this jaxws dir for the build
1895  --with-override-hotspot use this hotspot dir for the build
1896  --with-override-nashorn use this nashorn dir for the build
1897  --with-override-jdk     use this jdk dir for the build
1898  --with-import-hotspot   import hotspot binaries from this jdk image or
1899                          hotspot build dist dir instead of building from
1900                          source
1901  --with-toolchain-type   the toolchain type (or family) to use, use '--help'
1902                          to show possible values [platform dependent]
1903  --with-jtreg            Regression Test Harness [probed]
1904  --with-extra-cflags     extra flags to be used when compiling jdk c-files
1905  --with-extra-cxxflags   extra flags to be used when compiling jdk c++-files
1906  --with-extra-ldflags    extra flags to be used when linking jdk
1907  --with-x                use the X Window System
1908  --with-cups             specify prefix directory for the cups package
1909                          (expecting the headers under PATH/include)
1910  --with-cups-include     specify directory for the cups include files
1911  --with-freetype         specify prefix directory for the freetype package
1912                          (expecting the libraries under PATH/lib and the
1913                          headers under PATH/include)
1914  --with-freetype-include specify directory for the freetype include files
1915  --with-freetype-lib     specify directory for the freetype library
1916  --with-alsa             specify prefix directory for the alsa package
1917                          (expecting the libraries under PATH/lib and the
1918                          headers under PATH/include)
1919  --with-alsa-include     specify directory for the alsa include files
1920  --with-alsa-lib         specify directory for the alsa library
1921  --with-giflib           use giflib from build system or OpenJDK source
1922                          (system, bundled) [bundled]
1923  --with-zlib             use zlib from build system or OpenJDK source
1924                          (system, bundled) [bundled]
1925  --with-stdc++lib=<static>,<dynamic>,<default>
1926                          force linking of the C++ runtime on Linux to either
1927                          static or dynamic, default is static with dynamic as
1928                          fallback
1929  --with-msvcr-dll        copy this msvcr100.dll into the built JDK (Windows
1930                          only) [probed]
1931  --with-dxsdk            Deprecated. Option is kept for backwards
1932                          compatibility and is ignored
1933  --with-dxsdk-lib        Deprecated. Option is kept for backwards
1934                          compatibility and is ignored
1935  --with-dxsdk-include    Deprecated. Option is kept for backwards
1936                          compatibility and is ignored
1937  --with-num-cores        number of cores in the build system, e.g.
1938                          --with-num-cores=8 [probed]
1939  --with-memory-size      memory (in MB) available in the build system, e.g.
1940                          --with-memory-size=1024 [probed]
1941  --with-jobs             number of parallel jobs to let make run [calculated
1942                          based on cores and memory]
1943  --with-sjavac-server-java
1944                          use this java binary for running the sjavac
1945                          background server [Boot JDK java]
1946  --with-ccache-dir       where to store ccache files [~/.ccache]
1947
1948Some influential environment variables:
1949  BASENAME    Override default value for BASENAME
1950  BASH        Override default value for BASH
1951  CAT         Override default value for CAT
1952  CHMOD       Override default value for CHMOD
1953  CMP         Override default value for CMP
1954  COMM        Override default value for COMM
1955  CP          Override default value for CP
1956  CPIO        Override default value for CPIO
1957  CUT         Override default value for CUT
1958  DATE        Override default value for DATE
1959  DIFF        Override default value for DIFF
1960  DIRNAME     Override default value for DIRNAME
1961  ECHO        Override default value for ECHO
1962  EXPR        Override default value for EXPR
1963  FILE        Override default value for FILE
1964  FIND        Override default value for FIND
1965  HEAD        Override default value for HEAD
1966  LN          Override default value for LN
1967  LS          Override default value for LS
1968  MKDIR       Override default value for MKDIR
1969  MKTEMP      Override default value for MKTEMP
1970  MV          Override default value for MV
1971  NAWK        Override default value for NAWK
1972  PRINTF      Override default value for PRINTF
1973  RM          Override default value for RM
1974  SH          Override default value for SH
1975  SORT        Override default value for SORT
1976  TAIL        Override default value for TAIL
1977  TAR         Override default value for TAR
1978  TEE         Override default value for TEE
1979  TOUCH       Override default value for TOUCH
1980  TR          Override default value for TR
1981  UNAME       Override default value for UNAME
1982  UNIQ        Override default value for UNIQ
1983  WC          Override default value for WC
1984  WHICH       Override default value for WHICH
1985  XARGS       Override default value for XARGS
1986  AWK         Override default value for AWK
1987  GREP        Override default value for GREP
1988  EGREP       Override default value for EGREP
1989  FGREP       Override default value for FGREP
1990  SED         Override default value for SED
1991  CYGPATH     Override default value for CYGPATH
1992  READLINK    Override default value for READLINK
1993  DF          Override default value for DF
1994  SETFILE     Override default value for SETFILE
1995  UNZIP       Override default value for UNZIP
1996  ZIP         Override default value for ZIP
1997  LDD         Override default value for LDD
1998  OTOOL       Override default value for OTOOL
1999  READELF     Override default value for READELF
2000  HG          Override default value for HG
2001  STAT        Override default value for STAT
2002  TIME        Override default value for TIME
2003  DSYMUTIL    Override default value for DSYMUTIL
2004  XATTR       Override default value for XATTR
2005  CODESIGN    Override default value for CODESIGN
2006  PKG_CONFIG  path to pkg-config utility
2007  JAVA        Override default value for JAVA
2008  JAVAC       Override default value for JAVAC
2009  JAVAH       Override default value for JAVAH
2010  JAR         Override default value for JAR
2011  NATIVE2ASCII
2012              Override default value for NATIVE2ASCII
2013  JARSIGNER   Override default value for JARSIGNER
2014  CC          C compiler command
2015  CFLAGS      C compiler flags
2016  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2017              nonstandard directory <lib dir>
2018  LIBS        libraries to pass to the linker, e.g. -l<library>
2019  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2020              you have headers in a nonstandard directory <include dir>
2021  CXX         C++ compiler command
2022  CXXFLAGS    C++ compiler flags
2023  CPP         C preprocessor
2024  CXXCPP      C++ preprocessor
2025  AS          Override default value for AS
2026  AR          Override default value for AR
2027  OBJC        Objective C compiler command
2028  OBJCFLAGS   Objective C compiler flags
2029  LIPO        Override default value for LIPO
2030  STRIP       Override default value for STRIP
2031  NM          Override default value for NM
2032  GNM         Override default value for GNM
2033  MCS         Override default value for MCS
2034  OBJCOPY     Override default value for OBJCOPY
2035  OBJDUMP     Override default value for OBJDUMP
2036  BUILD_CC    Override default value for BUILD_CC
2037  BUILD_CXX   Override default value for BUILD_CXX
2038  BUILD_LD    Override default value for BUILD_LD
2039  JTREGEXE    Override default value for JTREGEXE
2040  XMKMF       Path to xmkmf, Makefile generator for X Window System
2041  FREETYPE_CFLAGS
2042              C compiler flags for FREETYPE, overriding pkg-config
2043  FREETYPE_LIBS
2044              linker flags for FREETYPE, overriding pkg-config
2045  ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
2046  ALSA_LIBS   linker flags for ALSA, overriding pkg-config
2047  LIBFFI_CFLAGS
2048              C compiler flags for LIBFFI, overriding pkg-config
2049  LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config
2050  CCACHE      Override default value for CCACHE
2051
2052Use these variables to override the choices made by `configure' or to help
2053it to find libraries and programs with nonstandard names/locations.
2054
2055Report bugs to <build-dev@openjdk.java.net>.
2056OpenJDK home page: <http://openjdk.java.net>.
2057_ACEOF
2058ac_status=$?
2059fi
2060
2061if test "$ac_init_help" = "recursive"; then
2062  # If there are subdirs, report their specific --help.
2063  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2064    test -d "$ac_dir" ||
2065      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2066      continue
2067    ac_builddir=.
2068
2069case "$ac_dir" in
2070.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2071*)
2072  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2073  # A ".." for each directory in $ac_dir_suffix.
2074  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2075  case $ac_top_builddir_sub in
2076  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2077  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2078  esac ;;
2079esac
2080ac_abs_top_builddir=$ac_pwd
2081ac_abs_builddir=$ac_pwd$ac_dir_suffix
2082# for backward compatibility:
2083ac_top_builddir=$ac_top_build_prefix
2084
2085case $srcdir in
2086  .)  # We are building in place.
2087    ac_srcdir=.
2088    ac_top_srcdir=$ac_top_builddir_sub
2089    ac_abs_top_srcdir=$ac_pwd ;;
2090  [\\/]* | ?:[\\/]* )  # Absolute name.
2091    ac_srcdir=$srcdir$ac_dir_suffix;
2092    ac_top_srcdir=$srcdir
2093    ac_abs_top_srcdir=$srcdir ;;
2094  *) # Relative name.
2095    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2096    ac_top_srcdir=$ac_top_build_prefix$srcdir
2097    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2098esac
2099ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2100
2101    cd "$ac_dir" || { ac_status=$?; continue; }
2102    # Check for guested configure.
2103    if test -f "$ac_srcdir/configure.gnu"; then
2104      echo &&
2105      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2106    elif test -f "$ac_srcdir/configure"; then
2107      echo &&
2108      $SHELL "$ac_srcdir/configure" --help=recursive
2109    else
2110      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2111    fi || ac_status=$?
2112    cd "$ac_pwd" || { ac_status=$?; break; }
2113  done
2114fi
2115
2116test -n "$ac_init_help" && exit $ac_status
2117if $ac_init_version; then
2118  cat <<\_ACEOF
2119OpenJDK configure jdk8
2120generated by GNU Autoconf 2.69
2121
2122Copyright (C) 2012 Free Software Foundation, Inc.
2123This configure script is free software; the Free Software Foundation
2124gives unlimited permission to copy, distribute and modify it.
2125_ACEOF
2126  exit
2127fi
2128
2129## ------------------------ ##
2130## Autoconf initialization. ##
2131## ------------------------ ##
2132
2133# ac_fn_c_try_compile LINENO
2134# --------------------------
2135# Try to compile conftest.$ac_ext, and return whether this succeeded.
2136ac_fn_c_try_compile ()
2137{
2138  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2139  rm -f conftest.$ac_objext
2140  if { { ac_try="$ac_compile"
2141case "(($ac_try" in
2142  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2143  *) ac_try_echo=$ac_try;;
2144esac
2145eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2146$as_echo "$ac_try_echo"; } >&5
2147  (eval "$ac_compile") 2>conftest.err
2148  ac_status=$?
2149  if test -s conftest.err; then
2150    grep -v '^ *+' conftest.err >conftest.er1
2151    cat conftest.er1 >&5
2152    mv -f conftest.er1 conftest.err
2153  fi
2154  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2155  test $ac_status = 0; } && {
2156	 test -z "$ac_c_werror_flag" ||
2157	 test ! -s conftest.err
2158       } && test -s conftest.$ac_objext; then :
2159  ac_retval=0
2160else
2161  $as_echo "$as_me: failed program was:" >&5
2162sed 's/^/| /' conftest.$ac_ext >&5
2163
2164	ac_retval=1
2165fi
2166  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2167  as_fn_set_status $ac_retval
2168
2169} # ac_fn_c_try_compile
2170
2171# ac_fn_cxx_try_compile LINENO
2172# ----------------------------
2173# Try to compile conftest.$ac_ext, and return whether this succeeded.
2174ac_fn_cxx_try_compile ()
2175{
2176  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2177  rm -f conftest.$ac_objext
2178  if { { ac_try="$ac_compile"
2179case "(($ac_try" in
2180  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2181  *) ac_try_echo=$ac_try;;
2182esac
2183eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2184$as_echo "$ac_try_echo"; } >&5
2185  (eval "$ac_compile") 2>conftest.err
2186  ac_status=$?
2187  if test -s conftest.err; then
2188    grep -v '^ *+' conftest.err >conftest.er1
2189    cat conftest.er1 >&5
2190    mv -f conftest.er1 conftest.err
2191  fi
2192  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2193  test $ac_status = 0; } && {
2194	 test -z "$ac_cxx_werror_flag" ||
2195	 test ! -s conftest.err
2196       } && test -s conftest.$ac_objext; then :
2197  ac_retval=0
2198else
2199  $as_echo "$as_me: failed program was:" >&5
2200sed 's/^/| /' conftest.$ac_ext >&5
2201
2202	ac_retval=1
2203fi
2204  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2205  as_fn_set_status $ac_retval
2206
2207} # ac_fn_cxx_try_compile
2208
2209# ac_fn_c_try_cpp LINENO
2210# ----------------------
2211# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2212ac_fn_c_try_cpp ()
2213{
2214  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2215  if { { ac_try="$ac_cpp conftest.$ac_ext"
2216case "(($ac_try" in
2217  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2218  *) ac_try_echo=$ac_try;;
2219esac
2220eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2221$as_echo "$ac_try_echo"; } >&5
2222  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2223  ac_status=$?
2224  if test -s conftest.err; then
2225    grep -v '^ *+' conftest.err >conftest.er1
2226    cat conftest.er1 >&5
2227    mv -f conftest.er1 conftest.err
2228  fi
2229  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2230  test $ac_status = 0; } > conftest.i && {
2231	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2232	 test ! -s conftest.err
2233       }; then :
2234  ac_retval=0
2235else
2236  $as_echo "$as_me: failed program was:" >&5
2237sed 's/^/| /' conftest.$ac_ext >&5
2238
2239    ac_retval=1
2240fi
2241  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2242  as_fn_set_status $ac_retval
2243
2244} # ac_fn_c_try_cpp
2245
2246# ac_fn_cxx_try_cpp LINENO
2247# ------------------------
2248# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2249ac_fn_cxx_try_cpp ()
2250{
2251  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2252  if { { ac_try="$ac_cpp conftest.$ac_ext"
2253case "(($ac_try" in
2254  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2255  *) ac_try_echo=$ac_try;;
2256esac
2257eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2258$as_echo "$ac_try_echo"; } >&5
2259  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2260  ac_status=$?
2261  if test -s conftest.err; then
2262    grep -v '^ *+' conftest.err >conftest.er1
2263    cat conftest.er1 >&5
2264    mv -f conftest.er1 conftest.err
2265  fi
2266  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2267  test $ac_status = 0; } > conftest.i && {
2268	 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2269	 test ! -s conftest.err
2270       }; then :
2271  ac_retval=0
2272else
2273  $as_echo "$as_me: failed program was:" >&5
2274sed 's/^/| /' conftest.$ac_ext >&5
2275
2276    ac_retval=1
2277fi
2278  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2279  as_fn_set_status $ac_retval
2280
2281} # ac_fn_cxx_try_cpp
2282
2283# ac_fn_objc_try_compile LINENO
2284# -----------------------------
2285# Try to compile conftest.$ac_ext, and return whether this succeeded.
2286ac_fn_objc_try_compile ()
2287{
2288  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2289  rm -f conftest.$ac_objext
2290  if { { ac_try="$ac_compile"
2291case "(($ac_try" in
2292  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2293  *) ac_try_echo=$ac_try;;
2294esac
2295eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2296$as_echo "$ac_try_echo"; } >&5
2297  (eval "$ac_compile") 2>conftest.err
2298  ac_status=$?
2299  if test -s conftest.err; then
2300    grep -v '^ *+' conftest.err >conftest.er1
2301    cat conftest.er1 >&5
2302    mv -f conftest.er1 conftest.err
2303  fi
2304  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2305  test $ac_status = 0; } && {
2306	 test -z "$ac_objc_werror_flag" ||
2307	 test ! -s conftest.err
2308       } && test -s conftest.$ac_objext; then :
2309  ac_retval=0
2310else
2311  $as_echo "$as_me: failed program was:" >&5
2312sed 's/^/| /' conftest.$ac_ext >&5
2313
2314	ac_retval=1
2315fi
2316  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2317  as_fn_set_status $ac_retval
2318
2319} # ac_fn_objc_try_compile
2320
2321# ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
2322# ---------------------------------------------------------
2323# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2324# the include files in INCLUDES and setting the cache variable VAR
2325# accordingly.
2326ac_fn_cxx_check_header_mongrel ()
2327{
2328  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2329  if eval \${$3+:} false; then :
2330  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2331$as_echo_n "checking for $2... " >&6; }
2332if eval \${$3+:} false; then :
2333  $as_echo_n "(cached) " >&6
2334fi
2335eval ac_res=\$$3
2336	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2337$as_echo "$ac_res" >&6; }
2338else
2339  # Is the header compilable?
2340{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2341$as_echo_n "checking $2 usability... " >&6; }
2342cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2343/* end confdefs.h.  */
2344$4
2345#include <$2>
2346_ACEOF
2347if ac_fn_cxx_try_compile "$LINENO"; then :
2348  ac_header_compiler=yes
2349else
2350  ac_header_compiler=no
2351fi
2352rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2353{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2354$as_echo "$ac_header_compiler" >&6; }
2355
2356# Is the header present?
2357{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2358$as_echo_n "checking $2 presence... " >&6; }
2359cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2360/* end confdefs.h.  */
2361#include <$2>
2362_ACEOF
2363if ac_fn_cxx_try_cpp "$LINENO"; then :
2364  ac_header_preproc=yes
2365else
2366  ac_header_preproc=no
2367fi
2368rm -f conftest.err conftest.i conftest.$ac_ext
2369{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2370$as_echo "$ac_header_preproc" >&6; }
2371
2372# So?  What about this header?
2373case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
2374  yes:no: )
2375    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2376$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2377    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2378$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2379    ;;
2380  no:yes:* )
2381    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2382$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2383    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2384$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2385    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2386$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2387    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2388$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2389    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2390$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2391( $as_echo "## ----------------------------------------- ##
2392## Report this to build-dev@openjdk.java.net ##
2393## ----------------------------------------- ##"
2394     ) | sed "s/^/$as_me: WARNING:     /" >&2
2395    ;;
2396esac
2397  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2398$as_echo_n "checking for $2... " >&6; }
2399if eval \${$3+:} false; then :
2400  $as_echo_n "(cached) " >&6
2401else
2402  eval "$3=\$ac_header_compiler"
2403fi
2404eval ac_res=\$$3
2405	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2406$as_echo "$ac_res" >&6; }
2407fi
2408  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2409
2410} # ac_fn_cxx_check_header_mongrel
2411
2412# ac_fn_cxx_try_run LINENO
2413# ------------------------
2414# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2415# that executables *can* be run.
2416ac_fn_cxx_try_run ()
2417{
2418  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2419  if { { ac_try="$ac_link"
2420case "(($ac_try" in
2421  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2422  *) ac_try_echo=$ac_try;;
2423esac
2424eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2425$as_echo "$ac_try_echo"; } >&5
2426  (eval "$ac_link") 2>&5
2427  ac_status=$?
2428  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2429  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2430  { { case "(($ac_try" in
2431  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2432  *) ac_try_echo=$ac_try;;
2433esac
2434eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2435$as_echo "$ac_try_echo"; } >&5
2436  (eval "$ac_try") 2>&5
2437  ac_status=$?
2438  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2439  test $ac_status = 0; }; }; then :
2440  ac_retval=0
2441else
2442  $as_echo "$as_me: program exited with status $ac_status" >&5
2443       $as_echo "$as_me: failed program was:" >&5
2444sed 's/^/| /' conftest.$ac_ext >&5
2445
2446       ac_retval=$ac_status
2447fi
2448  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2449  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2450  as_fn_set_status $ac_retval
2451
2452} # ac_fn_cxx_try_run
2453
2454# ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
2455# ---------------------------------------------------------
2456# Tests whether HEADER exists and can be compiled using the include files in
2457# INCLUDES, setting the cache variable VAR accordingly.
2458ac_fn_cxx_check_header_compile ()
2459{
2460  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2461  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2462$as_echo_n "checking for $2... " >&6; }
2463if eval \${$3+:} false; then :
2464  $as_echo_n "(cached) " >&6
2465else
2466  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2467/* end confdefs.h.  */
2468$4
2469#include <$2>
2470_ACEOF
2471if ac_fn_cxx_try_compile "$LINENO"; then :
2472  eval "$3=yes"
2473else
2474  eval "$3=no"
2475fi
2476rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2477fi
2478eval ac_res=\$$3
2479	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2480$as_echo "$ac_res" >&6; }
2481  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2482
2483} # ac_fn_cxx_check_header_compile
2484
2485# ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES
2486# ----------------------------------------------
2487# Tries to find the compile-time value of EXPR in a program that includes
2488# INCLUDES, setting VAR accordingly. Returns whether the value could be
2489# computed
2490ac_fn_cxx_compute_int ()
2491{
2492  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2493  if test "$cross_compiling" = yes; then
2494    # Depending upon the size, compute the lo and hi bounds.
2495cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2496/* end confdefs.h.  */
2497$4
2498int
2499main ()
2500{
2501static int test_array [1 - 2 * !(($2) >= 0)];
2502test_array [0] = 0;
2503return test_array [0];
2504
2505  ;
2506  return 0;
2507}
2508_ACEOF
2509if ac_fn_cxx_try_compile "$LINENO"; then :
2510  ac_lo=0 ac_mid=0
2511  while :; do
2512    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2513/* end confdefs.h.  */
2514$4
2515int
2516main ()
2517{
2518static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2519test_array [0] = 0;
2520return test_array [0];
2521
2522  ;
2523  return 0;
2524}
2525_ACEOF
2526if ac_fn_cxx_try_compile "$LINENO"; then :
2527  ac_hi=$ac_mid; break
2528else
2529  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2530			if test $ac_lo -le $ac_mid; then
2531			  ac_lo= ac_hi=
2532			  break
2533			fi
2534			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2535fi
2536rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2537  done
2538else
2539  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2540/* end confdefs.h.  */
2541$4
2542int
2543main ()
2544{
2545static int test_array [1 - 2 * !(($2) < 0)];
2546test_array [0] = 0;
2547return test_array [0];
2548
2549  ;
2550  return 0;
2551}
2552_ACEOF
2553if ac_fn_cxx_try_compile "$LINENO"; then :
2554  ac_hi=-1 ac_mid=-1
2555  while :; do
2556    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2557/* end confdefs.h.  */
2558$4
2559int
2560main ()
2561{
2562static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2563test_array [0] = 0;
2564return test_array [0];
2565
2566  ;
2567  return 0;
2568}
2569_ACEOF
2570if ac_fn_cxx_try_compile "$LINENO"; then :
2571  ac_lo=$ac_mid; break
2572else
2573  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2574			if test $ac_mid -le $ac_hi; then
2575			  ac_lo= ac_hi=
2576			  break
2577			fi
2578			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2579fi
2580rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2581  done
2582else
2583  ac_lo= ac_hi=
2584fi
2585rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2586fi
2587rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2588# Binary search between lo and hi bounds.
2589while test "x$ac_lo" != "x$ac_hi"; do
2590  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2591  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2592/* end confdefs.h.  */
2593$4
2594int
2595main ()
2596{
2597static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2598test_array [0] = 0;
2599return test_array [0];
2600
2601  ;
2602  return 0;
2603}
2604_ACEOF
2605if ac_fn_cxx_try_compile "$LINENO"; then :
2606  ac_hi=$ac_mid
2607else
2608  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2609fi
2610rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2611done
2612case $ac_lo in #((
2613?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2614'') ac_retval=1 ;;
2615esac
2616  else
2617    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2618/* end confdefs.h.  */
2619$4
2620static long int longval () { return $2; }
2621static unsigned long int ulongval () { return $2; }
2622#include <stdio.h>
2623#include <stdlib.h>
2624int
2625main ()
2626{
2627
2628  FILE *f = fopen ("conftest.val", "w");
2629  if (! f)
2630    return 1;
2631  if (($2) < 0)
2632    {
2633      long int i = longval ();
2634      if (i != ($2))
2635	return 1;
2636      fprintf (f, "%ld", i);
2637    }
2638  else
2639    {
2640      unsigned long int i = ulongval ();
2641      if (i != ($2))
2642	return 1;
2643      fprintf (f, "%lu", i);
2644    }
2645  /* Do not output a trailing newline, as this causes \r\n confusion
2646     on some platforms.  */
2647  return ferror (f) || fclose (f) != 0;
2648
2649  ;
2650  return 0;
2651}
2652_ACEOF
2653if ac_fn_cxx_try_run "$LINENO"; then :
2654  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2655else
2656  ac_retval=1
2657fi
2658rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2659  conftest.$ac_objext conftest.beam conftest.$ac_ext
2660rm -f conftest.val
2661
2662  fi
2663  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2664  as_fn_set_status $ac_retval
2665
2666} # ac_fn_cxx_compute_int
2667
2668# ac_fn_cxx_try_link LINENO
2669# -------------------------
2670# Try to link conftest.$ac_ext, and return whether this succeeded.
2671ac_fn_cxx_try_link ()
2672{
2673  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2674  rm -f conftest.$ac_objext conftest$ac_exeext
2675  if { { ac_try="$ac_link"
2676case "(($ac_try" in
2677  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2678  *) ac_try_echo=$ac_try;;
2679esac
2680eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2681$as_echo "$ac_try_echo"; } >&5
2682  (eval "$ac_link") 2>conftest.err
2683  ac_status=$?
2684  if test -s conftest.err; then
2685    grep -v '^ *+' conftest.err >conftest.er1
2686    cat conftest.er1 >&5
2687    mv -f conftest.er1 conftest.err
2688  fi
2689  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2690  test $ac_status = 0; } && {
2691	 test -z "$ac_cxx_werror_flag" ||
2692	 test ! -s conftest.err
2693       } && test -s conftest$ac_exeext && {
2694	 test "$cross_compiling" = yes ||
2695	 test -x conftest$ac_exeext
2696       }; then :
2697  ac_retval=0
2698else
2699  $as_echo "$as_me: failed program was:" >&5
2700sed 's/^/| /' conftest.$ac_ext >&5
2701
2702	ac_retval=1
2703fi
2704  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2705  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2706  # interfere with the next link command; also delete a directory that is
2707  # left behind by Apple's compiler.  We do this before executing the actions.
2708  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2709  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2710  as_fn_set_status $ac_retval
2711
2712} # ac_fn_cxx_try_link
2713
2714# ac_fn_cxx_check_func LINENO FUNC VAR
2715# ------------------------------------
2716# Tests whether FUNC exists, setting the cache variable VAR accordingly
2717ac_fn_cxx_check_func ()
2718{
2719  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2720  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2721$as_echo_n "checking for $2... " >&6; }
2722if eval \${$3+:} false; then :
2723  $as_echo_n "(cached) " >&6
2724else
2725  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2726/* end confdefs.h.  */
2727/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2728   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2729#define $2 innocuous_$2
2730
2731/* System header to define __stub macros and hopefully few prototypes,
2732    which can conflict with char $2 (); below.
2733    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2734    <limits.h> exists even on freestanding compilers.  */
2735
2736#ifdef __STDC__
2737# include <limits.h>
2738#else
2739# include <assert.h>
2740#endif
2741
2742#undef $2
2743
2744/* Override any GCC internal prototype to avoid an error.
2745   Use char because int might match the return type of a GCC
2746   builtin and then its argument prototype would still apply.  */
2747#ifdef __cplusplus
2748extern "C"
2749#endif
2750char $2 ();
2751/* The GNU C library defines this for functions which it implements
2752    to always fail with ENOSYS.  Some functions are actually named
2753    something starting with __ and the normal name is an alias.  */
2754#if defined __stub_$2 || defined __stub___$2
2755choke me
2756#endif
2757
2758int
2759main ()
2760{
2761return $2 ();
2762  ;
2763  return 0;
2764}
2765_ACEOF
2766if ac_fn_cxx_try_link "$LINENO"; then :
2767  eval "$3=yes"
2768else
2769  eval "$3=no"
2770fi
2771rm -f core conftest.err conftest.$ac_objext \
2772    conftest$ac_exeext conftest.$ac_ext
2773fi
2774eval ac_res=\$$3
2775	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2776$as_echo "$ac_res" >&6; }
2777  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2778
2779} # ac_fn_cxx_check_func
2780
2781# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2782# -------------------------------------------------------
2783# Tests whether HEADER exists and can be compiled using the include files in
2784# INCLUDES, setting the cache variable VAR accordingly.
2785ac_fn_c_check_header_compile ()
2786{
2787  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2788  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2789$as_echo_n "checking for $2... " >&6; }
2790if eval \${$3+:} false; then :
2791  $as_echo_n "(cached) " >&6
2792else
2793  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2794/* end confdefs.h.  */
2795$4
2796#include <$2>
2797_ACEOF
2798if ac_fn_c_try_compile "$LINENO"; then :
2799  eval "$3=yes"
2800else
2801  eval "$3=no"
2802fi
2803rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2804fi
2805eval ac_res=\$$3
2806	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2807$as_echo "$ac_res" >&6; }
2808  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2809
2810} # ac_fn_c_check_header_compile
2811cat >config.log <<_ACEOF
2812This file contains any messages produced by compilers while
2813running configure, to aid debugging if configure makes a mistake.
2814
2815It was created by OpenJDK $as_me jdk8, which was
2816generated by GNU Autoconf 2.69.  Invocation command line was
2817
2818  $ $0 $@
2819
2820_ACEOF
2821exec 5>>config.log
2822{
2823cat <<_ASUNAME
2824## --------- ##
2825## Platform. ##
2826## --------- ##
2827
2828hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2829uname -m = `(uname -m) 2>/dev/null || echo unknown`
2830uname -r = `(uname -r) 2>/dev/null || echo unknown`
2831uname -s = `(uname -s) 2>/dev/null || echo unknown`
2832uname -v = `(uname -v) 2>/dev/null || echo unknown`
2833
2834/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2835/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2836
2837/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2838/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2839/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2840/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2841/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2842/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2843/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2844
2845_ASUNAME
2846
2847as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2848for as_dir in $PATH
2849do
2850  IFS=$as_save_IFS
2851  test -z "$as_dir" && as_dir=.
2852    $as_echo "PATH: $as_dir"
2853  done
2854IFS=$as_save_IFS
2855
2856} >&5
2857
2858cat >&5 <<_ACEOF
2859
2860
2861## ----------- ##
2862## Core tests. ##
2863## ----------- ##
2864
2865_ACEOF
2866
2867
2868# Keep a trace of the command line.
2869# Strip out --no-create and --no-recursion so they do not pile up.
2870# Strip out --silent because we don't want to record it for future runs.
2871# Also quote any args containing shell meta-characters.
2872# Make two passes to allow for proper duplicate-argument suppression.
2873ac_configure_args=
2874ac_configure_args0=
2875ac_configure_args1=
2876ac_must_keep_next=false
2877for ac_pass in 1 2
2878do
2879  for ac_arg
2880  do
2881    case $ac_arg in
2882    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2883    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2884    | -silent | --silent | --silen | --sile | --sil)
2885      continue ;;
2886    *\'*)
2887      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2888    esac
2889    case $ac_pass in
2890    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2891    2)
2892      as_fn_append ac_configure_args1 " '$ac_arg'"
2893      if test $ac_must_keep_next = true; then
2894	ac_must_keep_next=false # Got value, back to normal.
2895      else
2896	case $ac_arg in
2897	  *=* | --config-cache | -C | -disable-* | --disable-* \
2898	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2899	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2900	  | -with-* | --with-* | -without-* | --without-* | --x)
2901	    case "$ac_configure_args0 " in
2902	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2903	    esac
2904	    ;;
2905	  -* ) ac_must_keep_next=true ;;
2906	esac
2907      fi
2908      as_fn_append ac_configure_args " '$ac_arg'"
2909      ;;
2910    esac
2911  done
2912done
2913{ ac_configure_args0=; unset ac_configure_args0;}
2914{ ac_configure_args1=; unset ac_configure_args1;}
2915
2916# When interrupted or exit'd, cleanup temporary files, and complete
2917# config.log.  We remove comments because anyway the quotes in there
2918# would cause problems or look ugly.
2919# WARNING: Use '\'' to represent an apostrophe within the trap.
2920# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2921trap 'exit_status=$?
2922  # Save into config.log some information that might help in debugging.
2923  {
2924    echo
2925
2926    $as_echo "## ---------------- ##
2927## Cache variables. ##
2928## ---------------- ##"
2929    echo
2930    # The following way of writing the cache mishandles newlines in values,
2931(
2932  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2933    eval ac_val=\$$ac_var
2934    case $ac_val in #(
2935    *${as_nl}*)
2936      case $ac_var in #(
2937      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2938$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2939      esac
2940      case $ac_var in #(
2941      _ | IFS | as_nl) ;; #(
2942      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2943      *) { eval $ac_var=; unset $ac_var;} ;;
2944      esac ;;
2945    esac
2946  done
2947  (set) 2>&1 |
2948    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2949    *${as_nl}ac_space=\ *)
2950      sed -n \
2951	"s/'\''/'\''\\\\'\'''\''/g;
2952	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2953      ;; #(
2954    *)
2955      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2956      ;;
2957    esac |
2958    sort
2959)
2960    echo
2961
2962    $as_echo "## ----------------- ##
2963## Output variables. ##
2964## ----------------- ##"
2965    echo
2966    for ac_var in $ac_subst_vars
2967    do
2968      eval ac_val=\$$ac_var
2969      case $ac_val in
2970      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2971      esac
2972      $as_echo "$ac_var='\''$ac_val'\''"
2973    done | sort
2974    echo
2975
2976    if test -n "$ac_subst_files"; then
2977      $as_echo "## ------------------- ##
2978## File substitutions. ##
2979## ------------------- ##"
2980      echo
2981      for ac_var in $ac_subst_files
2982      do
2983	eval ac_val=\$$ac_var
2984	case $ac_val in
2985	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2986	esac
2987	$as_echo "$ac_var='\''$ac_val'\''"
2988      done | sort
2989      echo
2990    fi
2991
2992    if test -s confdefs.h; then
2993      $as_echo "## ----------- ##
2994## confdefs.h. ##
2995## ----------- ##"
2996      echo
2997      cat confdefs.h
2998      echo
2999    fi
3000    test "$ac_signal" != 0 &&
3001      $as_echo "$as_me: caught signal $ac_signal"
3002    $as_echo "$as_me: exit $exit_status"
3003  } >&5
3004  rm -f core *.core core.conftest.* &&
3005    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3006    exit $exit_status
3007' 0
3008for ac_signal in 1 2 13 15; do
3009  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3010done
3011ac_signal=0
3012
3013# confdefs.h avoids OS command line length limits that DEFS can exceed.
3014rm -f -r conftest* confdefs.h
3015
3016$as_echo "/* confdefs.h */" > confdefs.h
3017
3018# Predefined preprocessor variables.
3019
3020cat >>confdefs.h <<_ACEOF
3021#define PACKAGE_NAME "$PACKAGE_NAME"
3022_ACEOF
3023
3024cat >>confdefs.h <<_ACEOF
3025#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3026_ACEOF
3027
3028cat >>confdefs.h <<_ACEOF
3029#define PACKAGE_VERSION "$PACKAGE_VERSION"
3030_ACEOF
3031
3032cat >>confdefs.h <<_ACEOF
3033#define PACKAGE_STRING "$PACKAGE_STRING"
3034_ACEOF
3035
3036cat >>confdefs.h <<_ACEOF
3037#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3038_ACEOF
3039
3040cat >>confdefs.h <<_ACEOF
3041#define PACKAGE_URL "$PACKAGE_URL"
3042_ACEOF
3043
3044
3045# Let the site file select an alternate cache file if it wants to.
3046# Prefer an explicitly selected file to automatically selected ones.
3047ac_site_file1=NONE
3048ac_site_file2=NONE
3049if test -n "$CONFIG_SITE"; then
3050  # We do not want a PATH search for config.site.
3051  case $CONFIG_SITE in #((
3052    -*)  ac_site_file1=./$CONFIG_SITE;;
3053    */*) ac_site_file1=$CONFIG_SITE;;
3054    *)   ac_site_file1=./$CONFIG_SITE;;
3055  esac
3056elif test "x$prefix" != xNONE; then
3057  ac_site_file1=$prefix/share/config.site
3058  ac_site_file2=$prefix/etc/config.site
3059else
3060  ac_site_file1=$ac_default_prefix/share/config.site
3061  ac_site_file2=$ac_default_prefix/etc/config.site
3062fi
3063for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3064do
3065  test "x$ac_site_file" = xNONE && continue
3066  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3067    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3068$as_echo "$as_me: loading site script $ac_site_file" >&6;}
3069    sed 's/^/| /' "$ac_site_file" >&5
3070    . "$ac_site_file" \
3071      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3072$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3073as_fn_error $? "failed to load site script $ac_site_file
3074See \`config.log' for more details" "$LINENO" 5; }
3075  fi
3076done
3077
3078if test -r "$cache_file"; then
3079  # Some versions of bash will fail to source /dev/null (special files
3080  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3081  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3082    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3083$as_echo "$as_me: loading cache $cache_file" >&6;}
3084    case $cache_file in
3085      [\\/]* | ?:[\\/]* ) . "$cache_file";;
3086      *)                      . "./$cache_file";;
3087    esac
3088  fi
3089else
3090  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3091$as_echo "$as_me: creating cache $cache_file" >&6;}
3092  >$cache_file
3093fi
3094
3095# Check that the precious variables saved in the cache have kept the same
3096# value.
3097ac_cache_corrupted=false
3098for ac_var in $ac_precious_vars; do
3099  eval ac_old_set=\$ac_cv_env_${ac_var}_set
3100  eval ac_new_set=\$ac_env_${ac_var}_set
3101  eval ac_old_val=\$ac_cv_env_${ac_var}_value
3102  eval ac_new_val=\$ac_env_${ac_var}_value
3103  case $ac_old_set,$ac_new_set in
3104    set,)
3105      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3106$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3107      ac_cache_corrupted=: ;;
3108    ,set)
3109      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3110$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3111      ac_cache_corrupted=: ;;
3112    ,);;
3113    *)
3114      if test "x$ac_old_val" != "x$ac_new_val"; then
3115	# differences in whitespace do not lead to failure.
3116	ac_old_val_w=`echo x $ac_old_val`
3117	ac_new_val_w=`echo x $ac_new_val`
3118	if test "$ac_old_val_w" != "$ac_new_val_w"; then
3119	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3120$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3121	  ac_cache_corrupted=:
3122	else
3123	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3124$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3125	  eval $ac_var=\$ac_old_val
3126	fi
3127	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
3128$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
3129	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
3130$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
3131      fi;;
3132  esac
3133  # Pass precious variables to config.status.
3134  if test "$ac_new_set" = set; then
3135    case $ac_new_val in
3136    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3137    *) ac_arg=$ac_var=$ac_new_val ;;
3138    esac
3139    case " $ac_configure_args " in
3140      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
3141      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3142    esac
3143  fi
3144done
3145if $ac_cache_corrupted; then
3146  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3147$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3148  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3149$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3150  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3151fi
3152## -------------------- ##
3153## Main body of script. ##
3154## -------------------- ##
3155
3156ac_ext=c
3157ac_cpp='$CPP $CPPFLAGS'
3158ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3159ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3160ac_compiler_gnu=$ac_cv_c_compiler_gnu
3161
3162
3163
3164ac_aux_dir=
3165for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do
3166  if test -f "$ac_dir/install-sh"; then
3167    ac_aux_dir=$ac_dir
3168    ac_install_sh="$ac_aux_dir/install-sh -c"
3169    break
3170  elif test -f "$ac_dir/install.sh"; then
3171    ac_aux_dir=$ac_dir
3172    ac_install_sh="$ac_aux_dir/install.sh -c"
3173    break
3174  elif test -f "$ac_dir/shtool"; then
3175    ac_aux_dir=$ac_dir
3176    ac_install_sh="$ac_aux_dir/shtool install -c"
3177    break
3178  fi
3179done
3180if test -z "$ac_aux_dir"; then
3181  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
3182fi
3183
3184# These three variables are undocumented and unsupported,
3185# and are intended to be withdrawn in a future Autoconf release.
3186# They can cause serious problems if a builder's source tree is in a directory
3187# whose full name contains unusual characters.
3188ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3189ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3190ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3191
3192
3193# pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
3194
3195#
3196# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
3197# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3198#
3199# This code is free software; you can redistribute it and/or modify it
3200# under the terms of the GNU General Public License version 2 only, as
3201# published by the Free Software Foundation.  Oracle designates this
3202# particular file as subject to the "Classpath" exception as provided
3203# by Oracle in the LICENSE file that accompanied this code.
3204#
3205# This code is distributed in the hope that it will be useful, but WITHOUT
3206# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3207# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3208# version 2 for more details (a copy is included in the LICENSE file that
3209# accompanied this code).
3210#
3211# You should have received a copy of the GNU General Public License version
3212# 2 along with this work; if not, write to the Free Software Foundation,
3213# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3214#
3215# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3216# or visit www.oracle.com if you need additional information or have any
3217# questions.
3218#
3219
3220#
3221# Copyright �� 2004 Scott James Remnant <scott@netsplit.com>.
3222#
3223# This program is free software; you can redistribute it and/or modify
3224# it under the terms of the GNU General Public License as published by
3225# the Free Software Foundation; either version 2 of the License, or
3226# (at your option) any later version.
3227#
3228# This program is distributed in the hope that it will be useful, but
3229# WITHOUT ANY WARRANTY; without even the implied warranty of
3230# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
3231# General Public License for more details.
3232#
3233# You should have received a copy of the GNU General Public License
3234# along with this program; if not, write to the Free Software
3235# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
3236#
3237# As a special exception to the GNU General Public License, if you
3238# distribute this file as part of a program that contains a
3239# configuration script generated by Autoconf, you may include it under
3240# the same distribution terms that you use for the rest of that program.
3241
3242# PKG_PROG_PKG_CONFIG([MIN-VERSION])
3243# ----------------------------------
3244# PKG_PROG_PKG_CONFIG
3245
3246# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
3247#
3248# Check to see whether a particular set of modules exists.  Similar
3249# to PKG_CHECK_MODULES(), but does not set variables or print errors.
3250#
3251#
3252# Similar to PKG_CHECK_MODULES, make sure that the first instance of
3253# this or PKG_CHECK_MODULES is called, or make sure to call
3254# PKG_CHECK_EXISTS manually
3255# --------------------------------------------------------------
3256
3257
3258
3259# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
3260# ---------------------------------------------
3261# _PKG_CONFIG
3262
3263# _PKG_SHORT_ERRORS_SUPPORTED
3264# -----------------------------
3265# _PKG_SHORT_ERRORS_SUPPORTED
3266
3267
3268# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
3269# [ACTION-IF-NOT-FOUND])
3270#
3271#
3272# Note that if there is a possibility the first call to
3273# PKG_CHECK_MODULES might not happen, you should be sure to include an
3274# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
3275#
3276#
3277# --------------------------------------------------------------
3278# PKG_CHECK_MODULES
3279
3280
3281# Include these first...
3282#
3283# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3284# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3285#
3286# This code is free software; you can redistribute it and/or modify it
3287# under the terms of the GNU General Public License version 2 only, as
3288# published by the Free Software Foundation.  Oracle designates this
3289# particular file as subject to the "Classpath" exception as provided
3290# by Oracle in the LICENSE file that accompanied this code.
3291#
3292# This code is distributed in the hope that it will be useful, but WITHOUT
3293# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3294# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3295# version 2 for more details (a copy is included in the LICENSE file that
3296# accompanied this code).
3297#
3298# You should have received a copy of the GNU General Public License version
3299# 2 along with this work; if not, write to the Free Software Foundation,
3300# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3301#
3302# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3303# or visit www.oracle.com if you need additional information or have any
3304# questions.
3305#
3306
3307# Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3308# If so, then append $1 to $2 \
3309# Also set JVM_ARG_OK to true/false depending on outcome.
3310
3311
3312# Appends a string to a path variable, only adding the : when needed.
3313
3314
3315# This will make sure the given variable points to a full and proper
3316# path. This means:
3317# 1) There will be no spaces in the path. On posix platforms,
3318#    spaces in the path will result in an error. On Windows,
3319#    the path will be rewritten using short-style to be space-free.
3320# 2) The path will be absolute, and it will be in unix-style (on
3321#     cygwin).
3322# $1: The name of the variable to fix
3323
3324
3325# This will make sure the given variable points to a executable
3326# with a full and proper path. This means:
3327# 1) There will be no spaces in the path. On posix platforms,
3328#    spaces in the path will result in an error. On Windows,
3329#    the path will be rewritten using short-style to be space-free.
3330# 2) The path will be absolute, and it will be in unix-style (on
3331#     cygwin).
3332# Any arguments given to the executable is preserved.
3333# If the input variable does not have a directory specification, then
3334# it need to be in the PATH.
3335# $1: The name of the variable to fix
3336
3337
3338
3339
3340# Register a --with argument but mark it as deprecated
3341# $1: The name of the with argument to deprecate, not including --with-
3342
3343
3344# Register a --enable argument but mark it as deprecated
3345# $1: The name of the with argument to deprecate, not including --enable-
3346# $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -)
3347
3348
3349
3350
3351# Test that variable $1 denoting a program is not empty. If empty, exit with an error.
3352# $1: variable to check
3353
3354
3355# Check that there are no unprocessed overridden variables left.
3356# If so, they are an incorrect argument and we will exit with an error.
3357
3358
3359# Setup a tool for the given variable. If correctly specified by the user,
3360# use that value, otherwise search for the tool using the supplied code snippet.
3361# $1: variable to set
3362# $2: code snippet to call to look for the tool
3363
3364
3365# Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool
3366# $1: variable to set
3367# $2: executable name (or list of names) to look for
3368
3369
3370# Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool
3371# $1: variable to set
3372# $2: executable name (or list of names) to look for
3373
3374
3375# Like BASIC_PATH_PROGS but fails if no tool was found.
3376# $1: variable to set
3377# $2: executable name (or list of names) to look for
3378
3379
3380# Like BASIC_SETUP_TOOL but fails if no tool was found.
3381# $1: variable to set
3382# $2: autoconf macro to call to look for the special tool
3383
3384
3385# Setup the most fundamental tools that relies on not much else to set up,
3386# but is used by much of the early bootstrap code.
3387
3388
3389# Setup basic configuration paths, and platform-specific stuff related to PATHs.
3390
3391
3392
3393
3394
3395
3396
3397#%%% Simple tools %%%
3398
3399# Check if we have found a usable version of make
3400# $1: the path to a potential make binary (or empty)
3401# $2: the description on how we found this
3402
3403
3404# Goes looking for a usable version of GNU make.
3405
3406
3407
3408
3409
3410
3411# Check if build directory is on local disk. If not possible to determine,
3412# we prefer to claim it's local.
3413# Argument 1: directory to test
3414# Argument 2: what to do if it is on local disk
3415# Argument 3: what to do otherwise (remote disk or failure)
3416
3417
3418# Check that source files have basic read permissions set. This might
3419# not be the case in cygwin in certain conditions.
3420
3421
3422
3423
3424#
3425# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3426# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3427#
3428# This code is free software; you can redistribute it and/or modify it
3429# under the terms of the GNU General Public License version 2 only, as
3430# published by the Free Software Foundation.  Oracle designates this
3431# particular file as subject to the "Classpath" exception as provided
3432# by Oracle in the LICENSE file that accompanied this code.
3433#
3434# This code is distributed in the hope that it will be useful, but WITHOUT
3435# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3436# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3437# version 2 for more details (a copy is included in the LICENSE file that
3438# accompanied this code).
3439#
3440# You should have received a copy of the GNU General Public License version
3441# 2 along with this work; if not, write to the Free Software Foundation,
3442# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3443#
3444# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3445# or visit www.oracle.com if you need additional information or have any
3446# questions.
3447#
3448
3449
3450
3451
3452
3453# Helper function which possibly converts a path using DOS-style short mode.
3454# If so, the updated path is stored in $new_path.
3455# $1: The path to check
3456
3457
3458# Helper function which possibly converts a path using DOS-style short mode.
3459# If so, the updated path is stored in $new_path.
3460# $1: The path to check
3461
3462
3463# FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted
3464# and could probably be heavily simplified. However, all changes in this
3465# area tend to need lot of testing in different scenarios, and in lack of
3466# proper unit testing, cleaning this up has not been deemed worth the effort
3467# at the moment.
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477# Setup basic configuration paths, and platform-specific stuff related to PATHs.
3478
3479
3480
3481
3482#
3483# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3484# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3485#
3486# This code is free software; you can redistribute it and/or modify it
3487# under the terms of the GNU General Public License version 2 only, as
3488# published by the Free Software Foundation.  Oracle designates this
3489# particular file as subject to the "Classpath" exception as provided
3490# by Oracle in the LICENSE file that accompanied this code.
3491#
3492# This code is distributed in the hope that it will be useful, but WITHOUT
3493# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3494# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3495# version 2 for more details (a copy is included in the LICENSE file that
3496# accompanied this code).
3497#
3498# You should have received a copy of the GNU General Public License version
3499# 2 along with this work; if not, write to the Free Software Foundation,
3500# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3501#
3502# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3503# or visit www.oracle.com if you need additional information or have any
3504# questions.
3505#
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517# ... then the rest
3518#
3519# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3520# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3521#
3522# This code is free software; you can redistribute it and/or modify it
3523# under the terms of the GNU General Public License version 2 only, as
3524# published by the Free Software Foundation.  Oracle designates this
3525# particular file as subject to the "Classpath" exception as provided
3526# by Oracle in the LICENSE file that accompanied this code.
3527#
3528# This code is distributed in the hope that it will be useful, but WITHOUT
3529# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3530# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3531# version 2 for more details (a copy is included in the LICENSE file that
3532# accompanied this code).
3533#
3534# You should have received a copy of the GNU General Public License version
3535# 2 along with this work; if not, write to the Free Software Foundation,
3536# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3537#
3538# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3539# or visit www.oracle.com if you need additional information or have any
3540# questions.
3541#
3542
3543########################################################################
3544# This file handles detection of the Boot JDK. The Boot JDK detection
3545# process has been developed as a response to solve a complex real-world
3546# problem. Initially, it was simple, but it has grown as platform after
3547# platform, idiosyncracy after idiosyncracy has been supported.
3548#
3549# The basic idea is this:
3550# 1) You need an acceptable *) JDK to use as a Boot JDK
3551# 2) There are several ways to locate a JDK, that are mostly platform
3552#    dependent **)
3553# 3) You can have multiple JDKs installed
3554# 4) If possible, configure should try to dig out an acceptable JDK
3555#    automatically, without having to resort to command-line options
3556#
3557# *)  acceptable means e.g. JDK7 for building JDK8, a complete JDK (with
3558#     javac) and not a JRE, etc.
3559#
3560# **) On Windows we typically use a well-known path.
3561#     On MacOSX we typically use the tool java_home.
3562#     On Linux we typically find javac in the $PATH, and then follow a
3563#     chain of symlinks that often ends up in a real JDK.
3564#
3565# This leads to the code where we check in different ways to locate a
3566# JDK, and if one is found, check if it is acceptable. If not, we print
3567# our reasons for rejecting it (useful when debugging non-working
3568# configure situations) and continue checking the next one.
3569########################################################################
3570
3571# Execute the check given as argument, and verify the result
3572# If the Boot JDK was previously found, do nothing
3573# $1 A command line (typically autoconf macro) to execute
3574
3575
3576# Test: Is bootjdk explicitely set by command line arguments?
3577
3578
3579# Test: Is bootjdk available from builddeps?
3580
3581
3582# Test: Is $JAVA_HOME set?
3583
3584
3585# Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
3586
3587
3588# Test: Is there a /usr/libexec/java_home? (Typically on MacOSX)
3589# $1: Argument to the java_home binary (optional)
3590
3591
3592# Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
3593
3594
3595# Look for a jdk in the given path. If there are multiple, try to select the newest.
3596# If found, set BOOT_JDK and BOOT_JDK_FOUND.
3597# $1 = Path to directory containing jdk installations.
3598# $2 = String to append to the found JDK directory to get the proper JDK home
3599
3600
3601# Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given
3602# environmental variable as base for where to look.
3603# $1 Name of an environmal variable, assumed to point to the Program Files directory.
3604
3605
3606# Test: Is there a JDK installed in default, well-known locations?
3607
3608
3609# Check that a command-line tool in the Boot JDK is correct
3610# $1 = name of variable to assign
3611# $2 = name of binary
3612
3613
3614###############################################################################
3615#
3616# We need a Boot JDK to bootstrap the build.
3617#
3618
3619
3620
3621
3622
3623#
3624# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3625# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3626#
3627# This code is free software; you can redistribute it and/or modify it
3628# under the terms of the GNU General Public License version 2 only, as
3629# published by the Free Software Foundation.  Oracle designates this
3630# particular file as subject to the "Classpath" exception as provided
3631# by Oracle in the LICENSE file that accompanied this code.
3632#
3633# This code is distributed in the hope that it will be useful, but WITHOUT
3634# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3635# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3636# version 2 for more details (a copy is included in the LICENSE file that
3637# accompanied this code).
3638#
3639# You should have received a copy of the GNU General Public License version
3640# 2 along with this work; if not, write to the Free Software Foundation,
3641# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3642#
3643# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3644# or visit www.oracle.com if you need additional information or have any
3645# questions.
3646#
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667#
3668# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3669# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3670#
3671# This code is free software; you can redistribute it and/or modify it
3672# under the terms of the GNU General Public License version 2 only, as
3673# published by the Free Software Foundation.  Oracle designates this
3674# particular file as subject to the "Classpath" exception as provided
3675# by Oracle in the LICENSE file that accompanied this code.
3676#
3677# This code is distributed in the hope that it will be useful, but WITHOUT
3678# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3679# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3680# version 2 for more details (a copy is included in the LICENSE file that
3681# accompanied this code).
3682#
3683# You should have received a copy of the GNU General Public License version
3684# 2 along with this work; if not, write to the Free Software Foundation,
3685# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3686#
3687# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3688# or visit www.oracle.com if you need additional information or have any
3689# questions.
3690#
3691
3692
3693
3694
3695
3696# Documentation on common flags used for solstudio in HIGHEST.
3697#
3698# WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
3699#          done with care, there are some assumptions below that need to
3700#          be understood about the use of pointers, and IEEE behavior.
3701#
3702# -fns: Use non-standard floating point mode (not IEEE 754)
3703# -fsimple: Do some simplification of floating point arithmetic (not IEEE 754)
3704# -fsingle: Use single precision floating point with 'float'
3705# -xalias_level=basic: Assume memory references via basic pointer types do not alias
3706#   (Source with excessing pointer casting and data access with mixed
3707#    pointer types are not recommended)
3708# -xbuiltin=%all: Use intrinsic or inline versions for math/std functions
3709#   (If you expect perfect errno behavior, do not use this)
3710# -xdepend: Loop data dependency optimizations (need -xO3 or higher)
3711# -xrestrict: Pointer parameters to functions do not overlap
3712#   (Similar to -xalias_level=basic usage, but less obvious sometimes.
3713#    If you pass in multiple pointers to the same data, do not use this)
3714# -xlibmil: Inline some library routines
3715#   (If you expect perfect errno behavior, do not use this)
3716# -xlibmopt: Use optimized math routines (CURRENTLY DISABLED)
3717#   (If you expect perfect errno behavior, do not use this)
3718#  Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
3719
3720    # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore.
3721    # Bug?
3722    #if test "x$OPENJDK_TARGET_CPU" = xsparc; then
3723    #  CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s"
3724    #  CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s"
3725    #fi
3726
3727
3728
3729
3730
3731
3732# FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
3733#                                   [RUN-IF-FALSE])
3734# ------------------------------------------------------------
3735# Check that the c and c++ compilers support an argument
3736
3737
3738
3739
3740#
3741# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3742# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3743#
3744# This code is free software; you can redistribute it and/or modify it
3745# under the terms of the GNU General Public License version 2 only, as
3746# published by the Free Software Foundation.  Oracle designates this
3747# particular file as subject to the "Classpath" exception as provided
3748# by Oracle in the LICENSE file that accompanied this code.
3749#
3750# This code is distributed in the hope that it will be useful, but WITHOUT
3751# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3752# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3753# version 2 for more details (a copy is included in the LICENSE file that
3754# accompanied this code).
3755#
3756# You should have received a copy of the GNU General Public License version
3757# 2 along with this work; if not, write to the Free Software Foundation,
3758# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3759#
3760# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3761# or visit www.oracle.com if you need additional information or have any
3762# questions.
3763#
3764
3765
3766
3767
3768
3769cygwin_help() {
3770  case $1 in
3771    unzip)
3772      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )"
3773      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3774      ;;
3775    zip)
3776      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )"
3777      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3778      ;;
3779    make)
3780      PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )"
3781      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3782      ;;
3783    freetype)
3784      if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
3785        HELP_MSG="To install freetype, run:
3786wget \"http://gnuwin32.sourceforge.net/downlinks/freetype.php\" -O /tmp/freetype-setup.exe
3787chmod +x /tmp/freetype-setup.exe
3788/tmp/freetype-setup.exe
3789Follow GUI prompts, and install to default directory \"C:\Program Files (x86)\GnuWin32\".
3790After installation, locate lib/libfreetype.dll.a and make a copy with the name freetype.dll."
3791      else
3792        HELP_MSG="You need to build a 64-bit version of freetype.
3793This is not readily available.
3794You can find source code and build instructions on
3795http://www.freetype.org/
3796If you put the resulting build in \"C:\Program Files\GnuWin32\", it will be found automatically."
3797      fi
3798      ;;
3799  esac
3800}
3801
3802msys_help() {
3803  PKGHANDLER_COMMAND=""
3804}
3805
3806apt_help() {
3807  case $1 in
3808    devkit)
3809      PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;;
3810    openjdk)
3811      PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;;
3812    alsa)
3813      PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;;
3814    cups)
3815      PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;;
3816    freetype)
3817      PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;;
3818    pulse)
3819      PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;;
3820    x11)
3821      PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
3822    ccache)
3823      PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
3824  esac
3825}
3826
3827yum_help() {
3828  case $1 in
3829    devkit)
3830      PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;;
3831    openjdk)
3832      PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;;
3833    alsa)
3834      PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;;
3835    cups)
3836      PKGHANDLER_COMMAND="sudo yum install cups-devel" ;;
3837    freetype)
3838      PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;;
3839    pulse)
3840      PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;;
3841    x11)
3842      PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
3843    ccache)
3844      PKGHANDLER_COMMAND="sudo yum install ccache" ;;
3845  esac
3846}
3847
3848port_help() {
3849  PKGHANDLER_COMMAND=""
3850}
3851
3852pkgutil_help() {
3853  PKGHANDLER_COMMAND=""
3854}
3855
3856pkgadd_help() {
3857  PKGHANDLER_COMMAND=""
3858}
3859
3860# This function will check if we're called from the "configure" wrapper while
3861# printing --help. If so, we will print out additional information that can
3862# only be extracted within the autoconf script, and then exit. This must be
3863# called at the very beginning in configure.ac.
3864
3865
3866
3867
3868#
3869# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3870# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3871#
3872# This code is free software; you can redistribute it and/or modify it
3873# under the terms of the GNU General Public License version 2 only, as
3874# published by the Free Software Foundation.  Oracle designates this
3875# particular file as subject to the "Classpath" exception as provided
3876# by Oracle in the LICENSE file that accompanied this code.
3877#
3878# This code is distributed in the hope that it will be useful, but WITHOUT
3879# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3880# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3881# version 2 for more details (a copy is included in the LICENSE file that
3882# accompanied this code).
3883#
3884# You should have received a copy of the GNU General Public License version
3885# 2 along with this work; if not, write to the Free Software Foundation,
3886# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3887#
3888# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3889# or visit www.oracle.com if you need additional information or have any
3890# questions.
3891#
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902###############################################################################
3903#
3904# Should we build only OpenJDK even if closed sources are present?
3905#
3906
3907
3908
3909
3910###############################################################################
3911#
3912# Setup version numbers
3913#
3914
3915
3916
3917
3918
3919
3920#
3921# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3922# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3923#
3924# This code is free software; you can redistribute it and/or modify it
3925# under the terms of the GNU General Public License version 2 only, as
3926# published by the Free Software Foundation.  Oracle designates this
3927# particular file as subject to the "Classpath" exception as provided
3928# by Oracle in the LICENSE file that accompanied this code.
3929#
3930# This code is distributed in the hope that it will be useful, but WITHOUT
3931# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3932# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3933# version 2 for more details (a copy is included in the LICENSE file that
3934# accompanied this code).
3935#
3936# You should have received a copy of the GNU General Public License version
3937# 2 along with this work; if not, write to the Free Software Foundation,
3938# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3939#
3940# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3941# or visit www.oracle.com if you need additional information or have any
3942# questions.
3943#
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963#
3964# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3965# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3966#
3967# This code is free software; you can redistribute it and/or modify it
3968# under the terms of the GNU General Public License version 2 only, as
3969# published by the Free Software Foundation.  Oracle designates this
3970# particular file as subject to the "Classpath" exception as provided
3971# by Oracle in the LICENSE file that accompanied this code.
3972#
3973# This code is distributed in the hope that it will be useful, but WITHOUT
3974# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3975# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3976# version 2 for more details (a copy is included in the LICENSE file that
3977# accompanied this code).
3978#
3979# You should have received a copy of the GNU General Public License version
3980# 2 along with this work; if not, write to the Free Software Foundation,
3981# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3982#
3983# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3984# or visit www.oracle.com if you need additional information or have any
3985# questions.
3986#
3987
3988# Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3989# Converts autoconf style CPU name to OpenJDK style, into
3990# VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN.
3991
3992
3993# Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3994# Converts autoconf style OS name to OpenJDK style, into
3995# VAR_OS and VAR_OS_API.
3996
3997
3998# Expects $host_os $host_cpu $build_os and $build_cpu
3999# and $with_target_bits to have been setup!
4000#
4001# Translate the standard triplet(quadruplet) definition
4002# of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU,
4003# OPENJDK_BUILD_OS, etc.
4004
4005
4006# Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour
4007# accordingly. Must be done after setting up build and target system, but before
4008# doing anything else with these values.
4009
4010
4011# Setup the legacy variables, for controlling the old makefiles.
4012#
4013
4014
4015
4016
4017#%%% Build and target systems %%%
4018
4019
4020
4021
4022# Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS.
4023# Add -mX to various FLAGS variables.
4024
4025
4026
4027
4028
4029
4030#
4031# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4032# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4033#
4034# This code is free software; you can redistribute it and/or modify it
4035# under the terms of the GNU General Public License version 2 only, as
4036# published by the Free Software Foundation.  Oracle designates this
4037# particular file as subject to the "Classpath" exception as provided
4038# by Oracle in the LICENSE file that accompanied this code.
4039#
4040# This code is distributed in the hope that it will be useful, but WITHOUT
4041# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4042# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4043# version 2 for more details (a copy is included in the LICENSE file that
4044# accompanied this code).
4045#
4046# You should have received a copy of the GNU General Public License version
4047# 2 along with this work; if not, write to the Free Software Foundation,
4048# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4049#
4050# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4051# or visit www.oracle.com if you need additional information or have any
4052# questions.
4053#
4054
4055
4056
4057
4058
4059
4060
4061
4062#
4063# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
4064# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4065#
4066# This code is free software; you can redistribute it and/or modify it
4067# under the terms of the GNU General Public License version 2 only, as
4068# published by the Free Software Foundation.  Oracle designates this
4069# particular file as subject to the "Classpath" exception as provided
4070# by Oracle in the LICENSE file that accompanied this code.
4071#
4072# This code is distributed in the hope that it will be useful, but WITHOUT
4073# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4074# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4075# version 2 for more details (a copy is included in the LICENSE file that
4076# accompanied this code).
4077#
4078# You should have received a copy of the GNU General Public License version
4079# 2 along with this work; if not, write to the Free Software Foundation,
4080# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4081#
4082# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4083# or visit www.oracle.com if you need additional information or have any
4084# questions.
4085#
4086
4087########################################################################
4088# This file is responsible for detecting, verifying and setting up the
4089# toolchain, i.e. the compiler, linker and related utilities. It will setup
4090# proper paths to the binaries, but it will not setup any flags.
4091#
4092# The binaries used is determined by the toolchain type, which is the family of
4093# compilers and related tools that are used.
4094########################################################################
4095
4096
4097# All valid toolchains, regardless of platform (used by help.m4)
4098VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft"
4099
4100# These toolchains are valid on different platforms
4101VALID_TOOLCHAINS_linux="gcc clang"
4102VALID_TOOLCHAINS_solaris="solstudio"
4103VALID_TOOLCHAINS_macosx="gcc clang"
4104VALID_TOOLCHAINS_aix="xlc"
4105VALID_TOOLCHAINS_windows="microsoft"
4106
4107# Toolchain descriptions
4108TOOLCHAIN_DESCRIPTION_clang="clang/LLVM"
4109TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection"
4110TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio"
4111TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio"
4112TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
4113
4114# Setup a number of variables describing how native output files are
4115# named on this platform/toolchain.
4116
4117
4118# Determine which toolchain type to use, and make sure it is valid for this
4119# platform. Setup various information about the selected toolchain.
4120
4121
4122# Before we start detecting the toolchain executables, we might need some
4123# special setup, e.g. additional paths etc.
4124
4125
4126# Restore path, etc
4127
4128
4129# Check if a compiler is of the toolchain type we expect, and save the version
4130# information from it. If the compiler does not match the expected type,
4131# this function will abort using AC_MSG_ERROR. If it matches, the version will
4132# be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and
4133# the full version string in CC_VERSION_STRING/CXX_VERSION_STRING.
4134#
4135# $1 = compiler to test (CC or CXX)
4136# $2 = human readable name of compiler (C or C++)
4137
4138
4139# Try to locate the given C or C++ compiler in the path, or otherwise.
4140#
4141# $1 = compiler to test (CC or CXX)
4142# $2 = human readable name of compiler (C or C++)
4143# $3 = list of compiler names to search for
4144
4145
4146# Detect the core components of the toolchain, i.e. the compilers (CC and CXX),
4147# preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the
4148# archiver (AR). Verify that the compilers are correct according to the
4149# toolchain type.
4150
4151
4152# Setup additional tools that is considered a part of the toolchain, but not the
4153# core part. Many of these are highly platform-specific and do not exist,
4154# and/or are not needed on all platforms.
4155
4156
4157# Setup the build tools (i.e, the compiler and linker used to build programs
4158# that should be run on the build platform, not the target platform, as a build
4159# helper). Since the non-cross-compile case uses the normal, target compilers
4160# for this, we can only do this after these have been setup.
4161
4162
4163# Setup legacy variables that are still needed as alternative ways to refer to
4164# parts of the toolchain.
4165
4166
4167# Do some additional checks on the detected tools.
4168
4169
4170# Setup the JTReg Regression Test Harness.
4171
4172
4173#
4174# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4175# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4176#
4177# This code is free software; you can redistribute it and/or modify it
4178# under the terms of the GNU General Public License version 2 only, as
4179# published by the Free Software Foundation.  Oracle designates this
4180# particular file as subject to the "Classpath" exception as provided
4181# by Oracle in the LICENSE file that accompanied this code.
4182#
4183# This code is distributed in the hope that it will be useful, but WITHOUT
4184# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4185# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4186# version 2 for more details (a copy is included in the LICENSE file that
4187# accompanied this code).
4188#
4189# You should have received a copy of the GNU General Public License version
4190# 2 along with this work; if not, write to the Free Software Foundation,
4191# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4192#
4193# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4194# or visit www.oracle.com if you need additional information or have any
4195# questions.
4196#
4197
4198
4199
4200
4201
4202
4203
4204# Check if the VS env variables were setup prior to running configure.
4205# If not, then find vcvarsall.bat and run it automatically, and integrate
4206# the set env variables into the spec file.
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217# This line needs to be here, verbatim, after all includes and the dummy hook
4218# definitions. It is replaced with custom functionality when building
4219# custom sources.
4220#CUSTOM_AUTOCONF_INCLUDE
4221
4222# Do not change or remove the following line, it is needed for consistency checks:
4223DATE_WHEN_GENERATED=1393416124
4224
4225###############################################################################
4226#
4227# Initialization / Boot-strapping
4228#
4229# The bootstrapping process needs to solve the "chicken or the egg" problem,
4230# thus it jumps back and forth, each time gaining something needed later on.
4231#
4232###############################################################################
4233
4234# If we are requested to print additional help, do that and then exit.
4235# This must be the very first call.
4236
4237  if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4238    $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4239    $PRINTF "Which are valid to use depends on the build platform.\n"
4240    for toolchain in $VALID_TOOLCHAINS_all; do
4241      # Use indirect variable referencing
4242      toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4243      TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
4244      $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
4245    done
4246
4247    # And now exit directly
4248    exit 0
4249  fi
4250
4251
4252# Basic initialization that must happen first of all in the normal process.
4253
4254  # Save the original command line. This is passed to us by the wrapper configure script.
4255
4256  DATE_WHEN_CONFIGURED=`LANG=C date`
4257
4258  { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5
4259$as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;}
4260  { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5
4261$as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;}
4262
4263
4264  # Start with tools that do not need have cross compilation support
4265  # and can be expected to be found in the default PATH. These tools are
4266  # used by configure. Nor are these tools expected to be found in the
4267  # devkit from the builddeps server either, since they are
4268  # needed to download the devkit.
4269
4270  # First are all the simple required tools.
4271
4272
4273
4274  # Publish this variable in the help.
4275
4276
4277  if test "x$BASENAME" = x; then
4278    # The variable is not set by user, try to locate tool using the code snippet
4279    for ac_prog in basename
4280do
4281  # Extract the first word of "$ac_prog", so it can be a program name with args.
4282set dummy $ac_prog; ac_word=$2
4283{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4284$as_echo_n "checking for $ac_word... " >&6; }
4285if ${ac_cv_path_BASENAME+:} false; then :
4286  $as_echo_n "(cached) " >&6
4287else
4288  case $BASENAME in
4289  [\\/]* | ?:[\\/]*)
4290  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4291  ;;
4292  *)
4293  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4294for as_dir in $PATH
4295do
4296  IFS=$as_save_IFS
4297  test -z "$as_dir" && as_dir=.
4298    for ac_exec_ext in '' $ac_executable_extensions; do
4299  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4300    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4301    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4302    break 2
4303  fi
4304done
4305  done
4306IFS=$as_save_IFS
4307
4308  ;;
4309esac
4310fi
4311BASENAME=$ac_cv_path_BASENAME
4312if test -n "$BASENAME"; then
4313  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4314$as_echo "$BASENAME" >&6; }
4315else
4316  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4317$as_echo "no" >&6; }
4318fi
4319
4320
4321  test -n "$BASENAME" && break
4322done
4323
4324  else
4325    # The variable is set, but is it from the command line or the environment?
4326
4327    # Try to remove the string !BASENAME! from our list.
4328    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/}
4329    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4330      # If it failed, the variable was not from the command line. Ignore it,
4331      # but warn the user (except for BASH, which is always set by the calling BASH).
4332      if test "xBASENAME" != xBASH; then
4333        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5
4334$as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;}
4335      fi
4336      # Try to locate tool using the code snippet
4337      for ac_prog in basename
4338do
4339  # Extract the first word of "$ac_prog", so it can be a program name with args.
4340set dummy $ac_prog; ac_word=$2
4341{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4342$as_echo_n "checking for $ac_word... " >&6; }
4343if ${ac_cv_path_BASENAME+:} false; then :
4344  $as_echo_n "(cached) " >&6
4345else
4346  case $BASENAME in
4347  [\\/]* | ?:[\\/]*)
4348  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4349  ;;
4350  *)
4351  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4352for as_dir in $PATH
4353do
4354  IFS=$as_save_IFS
4355  test -z "$as_dir" && as_dir=.
4356    for ac_exec_ext in '' $ac_executable_extensions; do
4357  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4358    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4359    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4360    break 2
4361  fi
4362done
4363  done
4364IFS=$as_save_IFS
4365
4366  ;;
4367esac
4368fi
4369BASENAME=$ac_cv_path_BASENAME
4370if test -n "$BASENAME"; then
4371  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4372$as_echo "$BASENAME" >&6; }
4373else
4374  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4375$as_echo "no" >&6; }
4376fi
4377
4378
4379  test -n "$BASENAME" && break
4380done
4381
4382    else
4383      # If it succeeded, then it was overridden by the user. We will use it
4384      # for the tool.
4385
4386      # First remove it from the list of overridden variables, so we can test
4387      # for unknown variables in the end.
4388      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4389
4390      # Check if the provided tool contains a complete path.
4391      tool_specified="$BASENAME"
4392      tool_basename="${tool_specified##*/}"
4393      if test "x$tool_basename" = "x$tool_specified"; then
4394        # A command without a complete path is provided, search $PATH.
4395        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5
4396$as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;}
4397        # Extract the first word of "$tool_basename", so it can be a program name with args.
4398set dummy $tool_basename; ac_word=$2
4399{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4400$as_echo_n "checking for $ac_word... " >&6; }
4401if ${ac_cv_path_BASENAME+:} false; then :
4402  $as_echo_n "(cached) " >&6
4403else
4404  case $BASENAME in
4405  [\\/]* | ?:[\\/]*)
4406  ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4407  ;;
4408  *)
4409  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4410for as_dir in $PATH
4411do
4412  IFS=$as_save_IFS
4413  test -z "$as_dir" && as_dir=.
4414    for ac_exec_ext in '' $ac_executable_extensions; do
4415  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4416    ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4417    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4418    break 2
4419  fi
4420done
4421  done
4422IFS=$as_save_IFS
4423
4424  ;;
4425esac
4426fi
4427BASENAME=$ac_cv_path_BASENAME
4428if test -n "$BASENAME"; then
4429  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4430$as_echo "$BASENAME" >&6; }
4431else
4432  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4433$as_echo "no" >&6; }
4434fi
4435
4436
4437        if test "x$BASENAME" = x; then
4438          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4439        fi
4440      else
4441        # Otherwise we believe it is a complete path. Use it as it is.
4442        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5
4443$as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;}
4444        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5
4445$as_echo_n "checking for BASENAME... " >&6; }
4446        if test ! -x "$tool_specified"; then
4447          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4448$as_echo "not found" >&6; }
4449          as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5
4450        fi
4451        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4452$as_echo "$tool_specified" >&6; }
4453      fi
4454    fi
4455  fi
4456
4457
4458
4459  if test "x$BASENAME" = x; then
4460    as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5
4461  fi
4462
4463
4464
4465
4466
4467  # Publish this variable in the help.
4468
4469
4470  if test "x$BASH" = x; then
4471    # The variable is not set by user, try to locate tool using the code snippet
4472    for ac_prog in bash
4473do
4474  # Extract the first word of "$ac_prog", so it can be a program name with args.
4475set dummy $ac_prog; ac_word=$2
4476{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4477$as_echo_n "checking for $ac_word... " >&6; }
4478if ${ac_cv_path_BASH+:} false; then :
4479  $as_echo_n "(cached) " >&6
4480else
4481  case $BASH in
4482  [\\/]* | ?:[\\/]*)
4483  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4484  ;;
4485  *)
4486  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4487for as_dir in $PATH
4488do
4489  IFS=$as_save_IFS
4490  test -z "$as_dir" && as_dir=.
4491    for ac_exec_ext in '' $ac_executable_extensions; do
4492  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4493    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4494    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4495    break 2
4496  fi
4497done
4498  done
4499IFS=$as_save_IFS
4500
4501  ;;
4502esac
4503fi
4504BASH=$ac_cv_path_BASH
4505if test -n "$BASH"; then
4506  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4507$as_echo "$BASH" >&6; }
4508else
4509  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4510$as_echo "no" >&6; }
4511fi
4512
4513
4514  test -n "$BASH" && break
4515done
4516
4517  else
4518    # The variable is set, but is it from the command line or the environment?
4519
4520    # Try to remove the string !BASH! from our list.
4521    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/}
4522    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4523      # If it failed, the variable was not from the command line. Ignore it,
4524      # but warn the user (except for BASH, which is always set by the calling BASH).
4525      if test "xBASH" != xBASH; then
4526        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5
4527$as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;}
4528      fi
4529      # Try to locate tool using the code snippet
4530      for ac_prog in bash
4531do
4532  # Extract the first word of "$ac_prog", so it can be a program name with args.
4533set dummy $ac_prog; ac_word=$2
4534{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4535$as_echo_n "checking for $ac_word... " >&6; }
4536if ${ac_cv_path_BASH+:} false; then :
4537  $as_echo_n "(cached) " >&6
4538else
4539  case $BASH in
4540  [\\/]* | ?:[\\/]*)
4541  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4542  ;;
4543  *)
4544  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4545for as_dir in $PATH
4546do
4547  IFS=$as_save_IFS
4548  test -z "$as_dir" && as_dir=.
4549    for ac_exec_ext in '' $ac_executable_extensions; do
4550  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4551    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4552    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4553    break 2
4554  fi
4555done
4556  done
4557IFS=$as_save_IFS
4558
4559  ;;
4560esac
4561fi
4562BASH=$ac_cv_path_BASH
4563if test -n "$BASH"; then
4564  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4565$as_echo "$BASH" >&6; }
4566else
4567  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4568$as_echo "no" >&6; }
4569fi
4570
4571
4572  test -n "$BASH" && break
4573done
4574
4575    else
4576      # If it succeeded, then it was overridden by the user. We will use it
4577      # for the tool.
4578
4579      # First remove it from the list of overridden variables, so we can test
4580      # for unknown variables in the end.
4581      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4582
4583      # Check if the provided tool contains a complete path.
4584      tool_specified="$BASH"
4585      tool_basename="${tool_specified##*/}"
4586      if test "x$tool_basename" = "x$tool_specified"; then
4587        # A command without a complete path is provided, search $PATH.
4588        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5
4589$as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;}
4590        # Extract the first word of "$tool_basename", so it can be a program name with args.
4591set dummy $tool_basename; ac_word=$2
4592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4593$as_echo_n "checking for $ac_word... " >&6; }
4594if ${ac_cv_path_BASH+:} false; then :
4595  $as_echo_n "(cached) " >&6
4596else
4597  case $BASH in
4598  [\\/]* | ?:[\\/]*)
4599  ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4600  ;;
4601  *)
4602  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4603for as_dir in $PATH
4604do
4605  IFS=$as_save_IFS
4606  test -z "$as_dir" && as_dir=.
4607    for ac_exec_ext in '' $ac_executable_extensions; do
4608  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4609    ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4610    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4611    break 2
4612  fi
4613done
4614  done
4615IFS=$as_save_IFS
4616
4617  ;;
4618esac
4619fi
4620BASH=$ac_cv_path_BASH
4621if test -n "$BASH"; then
4622  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4623$as_echo "$BASH" >&6; }
4624else
4625  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4626$as_echo "no" >&6; }
4627fi
4628
4629
4630        if test "x$BASH" = x; then
4631          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4632        fi
4633      else
4634        # Otherwise we believe it is a complete path. Use it as it is.
4635        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5
4636$as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;}
4637        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5
4638$as_echo_n "checking for BASH... " >&6; }
4639        if test ! -x "$tool_specified"; then
4640          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4641$as_echo "not found" >&6; }
4642          as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5
4643        fi
4644        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4645$as_echo "$tool_specified" >&6; }
4646      fi
4647    fi
4648  fi
4649
4650
4651
4652  if test "x$BASH" = x; then
4653    as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5
4654  fi
4655
4656
4657
4658
4659
4660  # Publish this variable in the help.
4661
4662
4663  if test "x$CAT" = x; then
4664    # The variable is not set by user, try to locate tool using the code snippet
4665    for ac_prog in cat
4666do
4667  # Extract the first word of "$ac_prog", so it can be a program name with args.
4668set dummy $ac_prog; ac_word=$2
4669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4670$as_echo_n "checking for $ac_word... " >&6; }
4671if ${ac_cv_path_CAT+:} false; then :
4672  $as_echo_n "(cached) " >&6
4673else
4674  case $CAT in
4675  [\\/]* | ?:[\\/]*)
4676  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4677  ;;
4678  *)
4679  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4680for as_dir in $PATH
4681do
4682  IFS=$as_save_IFS
4683  test -z "$as_dir" && as_dir=.
4684    for ac_exec_ext in '' $ac_executable_extensions; do
4685  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4686    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4687    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4688    break 2
4689  fi
4690done
4691  done
4692IFS=$as_save_IFS
4693
4694  ;;
4695esac
4696fi
4697CAT=$ac_cv_path_CAT
4698if test -n "$CAT"; then
4699  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4700$as_echo "$CAT" >&6; }
4701else
4702  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4703$as_echo "no" >&6; }
4704fi
4705
4706
4707  test -n "$CAT" && break
4708done
4709
4710  else
4711    # The variable is set, but is it from the command line or the environment?
4712
4713    # Try to remove the string !CAT! from our list.
4714    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/}
4715    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4716      # If it failed, the variable was not from the command line. Ignore it,
4717      # but warn the user (except for BASH, which is always set by the calling BASH).
4718      if test "xCAT" != xBASH; then
4719        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5
4720$as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;}
4721      fi
4722      # Try to locate tool using the code snippet
4723      for ac_prog in cat
4724do
4725  # Extract the first word of "$ac_prog", so it can be a program name with args.
4726set dummy $ac_prog; ac_word=$2
4727{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4728$as_echo_n "checking for $ac_word... " >&6; }
4729if ${ac_cv_path_CAT+:} false; then :
4730  $as_echo_n "(cached) " >&6
4731else
4732  case $CAT in
4733  [\\/]* | ?:[\\/]*)
4734  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4735  ;;
4736  *)
4737  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4738for as_dir in $PATH
4739do
4740  IFS=$as_save_IFS
4741  test -z "$as_dir" && as_dir=.
4742    for ac_exec_ext in '' $ac_executable_extensions; do
4743  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4744    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4745    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4746    break 2
4747  fi
4748done
4749  done
4750IFS=$as_save_IFS
4751
4752  ;;
4753esac
4754fi
4755CAT=$ac_cv_path_CAT
4756if test -n "$CAT"; then
4757  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4758$as_echo "$CAT" >&6; }
4759else
4760  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4761$as_echo "no" >&6; }
4762fi
4763
4764
4765  test -n "$CAT" && break
4766done
4767
4768    else
4769      # If it succeeded, then it was overridden by the user. We will use it
4770      # for the tool.
4771
4772      # First remove it from the list of overridden variables, so we can test
4773      # for unknown variables in the end.
4774      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4775
4776      # Check if the provided tool contains a complete path.
4777      tool_specified="$CAT"
4778      tool_basename="${tool_specified##*/}"
4779      if test "x$tool_basename" = "x$tool_specified"; then
4780        # A command without a complete path is provided, search $PATH.
4781        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5
4782$as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;}
4783        # Extract the first word of "$tool_basename", so it can be a program name with args.
4784set dummy $tool_basename; ac_word=$2
4785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4786$as_echo_n "checking for $ac_word... " >&6; }
4787if ${ac_cv_path_CAT+:} false; then :
4788  $as_echo_n "(cached) " >&6
4789else
4790  case $CAT in
4791  [\\/]* | ?:[\\/]*)
4792  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4793  ;;
4794  *)
4795  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4796for as_dir in $PATH
4797do
4798  IFS=$as_save_IFS
4799  test -z "$as_dir" && as_dir=.
4800    for ac_exec_ext in '' $ac_executable_extensions; do
4801  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4802    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4803    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4804    break 2
4805  fi
4806done
4807  done
4808IFS=$as_save_IFS
4809
4810  ;;
4811esac
4812fi
4813CAT=$ac_cv_path_CAT
4814if test -n "$CAT"; then
4815  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4816$as_echo "$CAT" >&6; }
4817else
4818  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4819$as_echo "no" >&6; }
4820fi
4821
4822
4823        if test "x$CAT" = x; then
4824          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4825        fi
4826      else
4827        # Otherwise we believe it is a complete path. Use it as it is.
4828        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5
4829$as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;}
4830        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5
4831$as_echo_n "checking for CAT... " >&6; }
4832        if test ! -x "$tool_specified"; then
4833          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4834$as_echo "not found" >&6; }
4835          as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5
4836        fi
4837        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4838$as_echo "$tool_specified" >&6; }
4839      fi
4840    fi
4841  fi
4842
4843
4844
4845  if test "x$CAT" = x; then
4846    as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5
4847  fi
4848
4849
4850
4851
4852
4853  # Publish this variable in the help.
4854
4855
4856  if test "x$CHMOD" = x; then
4857    # The variable is not set by user, try to locate tool using the code snippet
4858    for ac_prog in chmod
4859do
4860  # Extract the first word of "$ac_prog", so it can be a program name with args.
4861set dummy $ac_prog; ac_word=$2
4862{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4863$as_echo_n "checking for $ac_word... " >&6; }
4864if ${ac_cv_path_CHMOD+:} false; then :
4865  $as_echo_n "(cached) " >&6
4866else
4867  case $CHMOD in
4868  [\\/]* | ?:[\\/]*)
4869  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4870  ;;
4871  *)
4872  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4873for as_dir in $PATH
4874do
4875  IFS=$as_save_IFS
4876  test -z "$as_dir" && as_dir=.
4877    for ac_exec_ext in '' $ac_executable_extensions; do
4878  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4879    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4880    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4881    break 2
4882  fi
4883done
4884  done
4885IFS=$as_save_IFS
4886
4887  ;;
4888esac
4889fi
4890CHMOD=$ac_cv_path_CHMOD
4891if test -n "$CHMOD"; then
4892  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4893$as_echo "$CHMOD" >&6; }
4894else
4895  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4896$as_echo "no" >&6; }
4897fi
4898
4899
4900  test -n "$CHMOD" && break
4901done
4902
4903  else
4904    # The variable is set, but is it from the command line or the environment?
4905
4906    # Try to remove the string !CHMOD! from our list.
4907    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/}
4908    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4909      # If it failed, the variable was not from the command line. Ignore it,
4910      # but warn the user (except for BASH, which is always set by the calling BASH).
4911      if test "xCHMOD" != xBASH; then
4912        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5
4913$as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;}
4914      fi
4915      # Try to locate tool using the code snippet
4916      for ac_prog in chmod
4917do
4918  # Extract the first word of "$ac_prog", so it can be a program name with args.
4919set dummy $ac_prog; ac_word=$2
4920{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4921$as_echo_n "checking for $ac_word... " >&6; }
4922if ${ac_cv_path_CHMOD+:} false; then :
4923  $as_echo_n "(cached) " >&6
4924else
4925  case $CHMOD in
4926  [\\/]* | ?:[\\/]*)
4927  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4928  ;;
4929  *)
4930  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4931for as_dir in $PATH
4932do
4933  IFS=$as_save_IFS
4934  test -z "$as_dir" && as_dir=.
4935    for ac_exec_ext in '' $ac_executable_extensions; do
4936  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4937    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4938    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4939    break 2
4940  fi
4941done
4942  done
4943IFS=$as_save_IFS
4944
4945  ;;
4946esac
4947fi
4948CHMOD=$ac_cv_path_CHMOD
4949if test -n "$CHMOD"; then
4950  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4951$as_echo "$CHMOD" >&6; }
4952else
4953  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4954$as_echo "no" >&6; }
4955fi
4956
4957
4958  test -n "$CHMOD" && break
4959done
4960
4961    else
4962      # If it succeeded, then it was overridden by the user. We will use it
4963      # for the tool.
4964
4965      # First remove it from the list of overridden variables, so we can test
4966      # for unknown variables in the end.
4967      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4968
4969      # Check if the provided tool contains a complete path.
4970      tool_specified="$CHMOD"
4971      tool_basename="${tool_specified##*/}"
4972      if test "x$tool_basename" = "x$tool_specified"; then
4973        # A command without a complete path is provided, search $PATH.
4974        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5
4975$as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;}
4976        # Extract the first word of "$tool_basename", so it can be a program name with args.
4977set dummy $tool_basename; ac_word=$2
4978{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4979$as_echo_n "checking for $ac_word... " >&6; }
4980if ${ac_cv_path_CHMOD+:} false; then :
4981  $as_echo_n "(cached) " >&6
4982else
4983  case $CHMOD in
4984  [\\/]* | ?:[\\/]*)
4985  ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4986  ;;
4987  *)
4988  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4989for as_dir in $PATH
4990do
4991  IFS=$as_save_IFS
4992  test -z "$as_dir" && as_dir=.
4993    for ac_exec_ext in '' $ac_executable_extensions; do
4994  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4995    ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4996    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4997    break 2
4998  fi
4999done
5000  done
5001IFS=$as_save_IFS
5002
5003  ;;
5004esac
5005fi
5006CHMOD=$ac_cv_path_CHMOD
5007if test -n "$CHMOD"; then
5008  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5009$as_echo "$CHMOD" >&6; }
5010else
5011  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5012$as_echo "no" >&6; }
5013fi
5014
5015
5016        if test "x$CHMOD" = x; then
5017          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5018        fi
5019      else
5020        # Otherwise we believe it is a complete path. Use it as it is.
5021        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5
5022$as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;}
5023        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5
5024$as_echo_n "checking for CHMOD... " >&6; }
5025        if test ! -x "$tool_specified"; then
5026          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5027$as_echo "not found" >&6; }
5028          as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5
5029        fi
5030        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5031$as_echo "$tool_specified" >&6; }
5032      fi
5033    fi
5034  fi
5035
5036
5037
5038  if test "x$CHMOD" = x; then
5039    as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5
5040  fi
5041
5042
5043
5044
5045
5046  # Publish this variable in the help.
5047
5048
5049  if test "x$CMP" = x; then
5050    # The variable is not set by user, try to locate tool using the code snippet
5051    for ac_prog in cmp
5052do
5053  # Extract the first word of "$ac_prog", so it can be a program name with args.
5054set dummy $ac_prog; ac_word=$2
5055{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5056$as_echo_n "checking for $ac_word... " >&6; }
5057if ${ac_cv_path_CMP+:} false; then :
5058  $as_echo_n "(cached) " >&6
5059else
5060  case $CMP in
5061  [\\/]* | ?:[\\/]*)
5062  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5063  ;;
5064  *)
5065  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5066for as_dir in $PATH
5067do
5068  IFS=$as_save_IFS
5069  test -z "$as_dir" && as_dir=.
5070    for ac_exec_ext in '' $ac_executable_extensions; do
5071  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5072    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5073    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5074    break 2
5075  fi
5076done
5077  done
5078IFS=$as_save_IFS
5079
5080  ;;
5081esac
5082fi
5083CMP=$ac_cv_path_CMP
5084if test -n "$CMP"; then
5085  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5086$as_echo "$CMP" >&6; }
5087else
5088  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5089$as_echo "no" >&6; }
5090fi
5091
5092
5093  test -n "$CMP" && break
5094done
5095
5096  else
5097    # The variable is set, but is it from the command line or the environment?
5098
5099    # Try to remove the string !CMP! from our list.
5100    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/}
5101    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5102      # If it failed, the variable was not from the command line. Ignore it,
5103      # but warn the user (except for BASH, which is always set by the calling BASH).
5104      if test "xCMP" != xBASH; then
5105        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5
5106$as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;}
5107      fi
5108      # Try to locate tool using the code snippet
5109      for ac_prog in cmp
5110do
5111  # Extract the first word of "$ac_prog", so it can be a program name with args.
5112set dummy $ac_prog; ac_word=$2
5113{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5114$as_echo_n "checking for $ac_word... " >&6; }
5115if ${ac_cv_path_CMP+:} false; then :
5116  $as_echo_n "(cached) " >&6
5117else
5118  case $CMP in
5119  [\\/]* | ?:[\\/]*)
5120  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5121  ;;
5122  *)
5123  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5124for as_dir in $PATH
5125do
5126  IFS=$as_save_IFS
5127  test -z "$as_dir" && as_dir=.
5128    for ac_exec_ext in '' $ac_executable_extensions; do
5129  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5130    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5131    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5132    break 2
5133  fi
5134done
5135  done
5136IFS=$as_save_IFS
5137
5138  ;;
5139esac
5140fi
5141CMP=$ac_cv_path_CMP
5142if test -n "$CMP"; then
5143  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5144$as_echo "$CMP" >&6; }
5145else
5146  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5147$as_echo "no" >&6; }
5148fi
5149
5150
5151  test -n "$CMP" && break
5152done
5153
5154    else
5155      # If it succeeded, then it was overridden by the user. We will use it
5156      # for the tool.
5157
5158      # First remove it from the list of overridden variables, so we can test
5159      # for unknown variables in the end.
5160      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5161
5162      # Check if the provided tool contains a complete path.
5163      tool_specified="$CMP"
5164      tool_basename="${tool_specified##*/}"
5165      if test "x$tool_basename" = "x$tool_specified"; then
5166        # A command without a complete path is provided, search $PATH.
5167        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5
5168$as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;}
5169        # Extract the first word of "$tool_basename", so it can be a program name with args.
5170set dummy $tool_basename; ac_word=$2
5171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5172$as_echo_n "checking for $ac_word... " >&6; }
5173if ${ac_cv_path_CMP+:} false; then :
5174  $as_echo_n "(cached) " >&6
5175else
5176  case $CMP in
5177  [\\/]* | ?:[\\/]*)
5178  ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5179  ;;
5180  *)
5181  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5182for as_dir in $PATH
5183do
5184  IFS=$as_save_IFS
5185  test -z "$as_dir" && as_dir=.
5186    for ac_exec_ext in '' $ac_executable_extensions; do
5187  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5188    ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5189    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5190    break 2
5191  fi
5192done
5193  done
5194IFS=$as_save_IFS
5195
5196  ;;
5197esac
5198fi
5199CMP=$ac_cv_path_CMP
5200if test -n "$CMP"; then
5201  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5202$as_echo "$CMP" >&6; }
5203else
5204  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5205$as_echo "no" >&6; }
5206fi
5207
5208
5209        if test "x$CMP" = x; then
5210          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5211        fi
5212      else
5213        # Otherwise we believe it is a complete path. Use it as it is.
5214        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5
5215$as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;}
5216        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5
5217$as_echo_n "checking for CMP... " >&6; }
5218        if test ! -x "$tool_specified"; then
5219          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5220$as_echo "not found" >&6; }
5221          as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5
5222        fi
5223        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5224$as_echo "$tool_specified" >&6; }
5225      fi
5226    fi
5227  fi
5228
5229
5230
5231  if test "x$CMP" = x; then
5232    as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5
5233  fi
5234
5235
5236
5237
5238
5239  # Publish this variable in the help.
5240
5241
5242  if test "x$COMM" = x; then
5243    # The variable is not set by user, try to locate tool using the code snippet
5244    for ac_prog in comm
5245do
5246  # Extract the first word of "$ac_prog", so it can be a program name with args.
5247set dummy $ac_prog; ac_word=$2
5248{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5249$as_echo_n "checking for $ac_word... " >&6; }
5250if ${ac_cv_path_COMM+:} false; then :
5251  $as_echo_n "(cached) " >&6
5252else
5253  case $COMM in
5254  [\\/]* | ?:[\\/]*)
5255  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5256  ;;
5257  *)
5258  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5259for as_dir in $PATH
5260do
5261  IFS=$as_save_IFS
5262  test -z "$as_dir" && as_dir=.
5263    for ac_exec_ext in '' $ac_executable_extensions; do
5264  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5265    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5266    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5267    break 2
5268  fi
5269done
5270  done
5271IFS=$as_save_IFS
5272
5273  ;;
5274esac
5275fi
5276COMM=$ac_cv_path_COMM
5277if test -n "$COMM"; then
5278  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5279$as_echo "$COMM" >&6; }
5280else
5281  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5282$as_echo "no" >&6; }
5283fi
5284
5285
5286  test -n "$COMM" && break
5287done
5288
5289  else
5290    # The variable is set, but is it from the command line or the environment?
5291
5292    # Try to remove the string !COMM! from our list.
5293    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
5294    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5295      # If it failed, the variable was not from the command line. Ignore it,
5296      # but warn the user (except for BASH, which is always set by the calling BASH).
5297      if test "xCOMM" != xBASH; then
5298        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
5299$as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
5300      fi
5301      # Try to locate tool using the code snippet
5302      for ac_prog in comm
5303do
5304  # Extract the first word of "$ac_prog", so it can be a program name with args.
5305set dummy $ac_prog; ac_word=$2
5306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5307$as_echo_n "checking for $ac_word... " >&6; }
5308if ${ac_cv_path_COMM+:} false; then :
5309  $as_echo_n "(cached) " >&6
5310else
5311  case $COMM in
5312  [\\/]* | ?:[\\/]*)
5313  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5314  ;;
5315  *)
5316  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5317for as_dir in $PATH
5318do
5319  IFS=$as_save_IFS
5320  test -z "$as_dir" && as_dir=.
5321    for ac_exec_ext in '' $ac_executable_extensions; do
5322  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5323    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5324    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5325    break 2
5326  fi
5327done
5328  done
5329IFS=$as_save_IFS
5330
5331  ;;
5332esac
5333fi
5334COMM=$ac_cv_path_COMM
5335if test -n "$COMM"; then
5336  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5337$as_echo "$COMM" >&6; }
5338else
5339  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5340$as_echo "no" >&6; }
5341fi
5342
5343
5344  test -n "$COMM" && break
5345done
5346
5347    else
5348      # If it succeeded, then it was overridden by the user. We will use it
5349      # for the tool.
5350
5351      # First remove it from the list of overridden variables, so we can test
5352      # for unknown variables in the end.
5353      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5354
5355      # Check if the provided tool contains a complete path.
5356      tool_specified="$COMM"
5357      tool_basename="${tool_specified##*/}"
5358      if test "x$tool_basename" = "x$tool_specified"; then
5359        # A command without a complete path is provided, search $PATH.
5360        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
5361$as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
5362        # Extract the first word of "$tool_basename", so it can be a program name with args.
5363set dummy $tool_basename; ac_word=$2
5364{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5365$as_echo_n "checking for $ac_word... " >&6; }
5366if ${ac_cv_path_COMM+:} false; then :
5367  $as_echo_n "(cached) " >&6
5368else
5369  case $COMM in
5370  [\\/]* | ?:[\\/]*)
5371  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5372  ;;
5373  *)
5374  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5375for as_dir in $PATH
5376do
5377  IFS=$as_save_IFS
5378  test -z "$as_dir" && as_dir=.
5379    for ac_exec_ext in '' $ac_executable_extensions; do
5380  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5381    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5382    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5383    break 2
5384  fi
5385done
5386  done
5387IFS=$as_save_IFS
5388
5389  ;;
5390esac
5391fi
5392COMM=$ac_cv_path_COMM
5393if test -n "$COMM"; then
5394  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5395$as_echo "$COMM" >&6; }
5396else
5397  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5398$as_echo "no" >&6; }
5399fi
5400
5401
5402        if test "x$COMM" = x; then
5403          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5404        fi
5405      else
5406        # Otherwise we believe it is a complete path. Use it as it is.
5407        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
5408$as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
5409        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
5410$as_echo_n "checking for COMM... " >&6; }
5411        if test ! -x "$tool_specified"; then
5412          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5413$as_echo "not found" >&6; }
5414          as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
5415        fi
5416        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5417$as_echo "$tool_specified" >&6; }
5418      fi
5419    fi
5420  fi
5421
5422
5423
5424  if test "x$COMM" = x; then
5425    as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
5426  fi
5427
5428
5429
5430
5431
5432  # Publish this variable in the help.
5433
5434
5435  if test "x$CP" = x; then
5436    # The variable is not set by user, try to locate tool using the code snippet
5437    for ac_prog in cp
5438do
5439  # Extract the first word of "$ac_prog", so it can be a program name with args.
5440set dummy $ac_prog; ac_word=$2
5441{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5442$as_echo_n "checking for $ac_word... " >&6; }
5443if ${ac_cv_path_CP+:} false; then :
5444  $as_echo_n "(cached) " >&6
5445else
5446  case $CP in
5447  [\\/]* | ?:[\\/]*)
5448  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5449  ;;
5450  *)
5451  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5452for as_dir in $PATH
5453do
5454  IFS=$as_save_IFS
5455  test -z "$as_dir" && as_dir=.
5456    for ac_exec_ext in '' $ac_executable_extensions; do
5457  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5458    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5459    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5460    break 2
5461  fi
5462done
5463  done
5464IFS=$as_save_IFS
5465
5466  ;;
5467esac
5468fi
5469CP=$ac_cv_path_CP
5470if test -n "$CP"; then
5471  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5472$as_echo "$CP" >&6; }
5473else
5474  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5475$as_echo "no" >&6; }
5476fi
5477
5478
5479  test -n "$CP" && break
5480done
5481
5482  else
5483    # The variable is set, but is it from the command line or the environment?
5484
5485    # Try to remove the string !CP! from our list.
5486    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/}
5487    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5488      # If it failed, the variable was not from the command line. Ignore it,
5489      # but warn the user (except for BASH, which is always set by the calling BASH).
5490      if test "xCP" != xBASH; then
5491        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5
5492$as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;}
5493      fi
5494      # Try to locate tool using the code snippet
5495      for ac_prog in cp
5496do
5497  # Extract the first word of "$ac_prog", so it can be a program name with args.
5498set dummy $ac_prog; ac_word=$2
5499{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5500$as_echo_n "checking for $ac_word... " >&6; }
5501if ${ac_cv_path_CP+:} false; then :
5502  $as_echo_n "(cached) " >&6
5503else
5504  case $CP in
5505  [\\/]* | ?:[\\/]*)
5506  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5507  ;;
5508  *)
5509  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5510for as_dir in $PATH
5511do
5512  IFS=$as_save_IFS
5513  test -z "$as_dir" && as_dir=.
5514    for ac_exec_ext in '' $ac_executable_extensions; do
5515  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5516    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5517    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5518    break 2
5519  fi
5520done
5521  done
5522IFS=$as_save_IFS
5523
5524  ;;
5525esac
5526fi
5527CP=$ac_cv_path_CP
5528if test -n "$CP"; then
5529  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5530$as_echo "$CP" >&6; }
5531else
5532  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5533$as_echo "no" >&6; }
5534fi
5535
5536
5537  test -n "$CP" && break
5538done
5539
5540    else
5541      # If it succeeded, then it was overridden by the user. We will use it
5542      # for the tool.
5543
5544      # First remove it from the list of overridden variables, so we can test
5545      # for unknown variables in the end.
5546      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5547
5548      # Check if the provided tool contains a complete path.
5549      tool_specified="$CP"
5550      tool_basename="${tool_specified##*/}"
5551      if test "x$tool_basename" = "x$tool_specified"; then
5552        # A command without a complete path is provided, search $PATH.
5553        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5
5554$as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;}
5555        # Extract the first word of "$tool_basename", so it can be a program name with args.
5556set dummy $tool_basename; ac_word=$2
5557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5558$as_echo_n "checking for $ac_word... " >&6; }
5559if ${ac_cv_path_CP+:} false; then :
5560  $as_echo_n "(cached) " >&6
5561else
5562  case $CP in
5563  [\\/]* | ?:[\\/]*)
5564  ac_cv_path_CP="$CP" # Let the user override the test with a path.
5565  ;;
5566  *)
5567  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5568for as_dir in $PATH
5569do
5570  IFS=$as_save_IFS
5571  test -z "$as_dir" && as_dir=.
5572    for ac_exec_ext in '' $ac_executable_extensions; do
5573  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5574    ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5575    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5576    break 2
5577  fi
5578done
5579  done
5580IFS=$as_save_IFS
5581
5582  ;;
5583esac
5584fi
5585CP=$ac_cv_path_CP
5586if test -n "$CP"; then
5587  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5588$as_echo "$CP" >&6; }
5589else
5590  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5591$as_echo "no" >&6; }
5592fi
5593
5594
5595        if test "x$CP" = x; then
5596          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5597        fi
5598      else
5599        # Otherwise we believe it is a complete path. Use it as it is.
5600        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5
5601$as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;}
5602        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5
5603$as_echo_n "checking for CP... " >&6; }
5604        if test ! -x "$tool_specified"; then
5605          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5606$as_echo "not found" >&6; }
5607          as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5
5608        fi
5609        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5610$as_echo "$tool_specified" >&6; }
5611      fi
5612    fi
5613  fi
5614
5615
5616
5617  if test "x$CP" = x; then
5618    as_fn_error $? "Could not find required tool for CP" "$LINENO" 5
5619  fi
5620
5621
5622
5623
5624
5625  # Publish this variable in the help.
5626
5627
5628  if test "x$CPIO" = x; then
5629    # The variable is not set by user, try to locate tool using the code snippet
5630    for ac_prog in cpio
5631do
5632  # Extract the first word of "$ac_prog", so it can be a program name with args.
5633set dummy $ac_prog; ac_word=$2
5634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5635$as_echo_n "checking for $ac_word... " >&6; }
5636if ${ac_cv_path_CPIO+:} false; then :
5637  $as_echo_n "(cached) " >&6
5638else
5639  case $CPIO in
5640  [\\/]* | ?:[\\/]*)
5641  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5642  ;;
5643  *)
5644  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5645for as_dir in $PATH
5646do
5647  IFS=$as_save_IFS
5648  test -z "$as_dir" && as_dir=.
5649    for ac_exec_ext in '' $ac_executable_extensions; do
5650  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5651    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5652    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5653    break 2
5654  fi
5655done
5656  done
5657IFS=$as_save_IFS
5658
5659  ;;
5660esac
5661fi
5662CPIO=$ac_cv_path_CPIO
5663if test -n "$CPIO"; then
5664  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5665$as_echo "$CPIO" >&6; }
5666else
5667  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5668$as_echo "no" >&6; }
5669fi
5670
5671
5672  test -n "$CPIO" && break
5673done
5674
5675  else
5676    # The variable is set, but is it from the command line or the environment?
5677
5678    # Try to remove the string !CPIO! from our list.
5679    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/}
5680    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5681      # If it failed, the variable was not from the command line. Ignore it,
5682      # but warn the user (except for BASH, which is always set by the calling BASH).
5683      if test "xCPIO" != xBASH; then
5684        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5
5685$as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;}
5686      fi
5687      # Try to locate tool using the code snippet
5688      for ac_prog in cpio
5689do
5690  # Extract the first word of "$ac_prog", so it can be a program name with args.
5691set dummy $ac_prog; ac_word=$2
5692{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5693$as_echo_n "checking for $ac_word... " >&6; }
5694if ${ac_cv_path_CPIO+:} false; then :
5695  $as_echo_n "(cached) " >&6
5696else
5697  case $CPIO in
5698  [\\/]* | ?:[\\/]*)
5699  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5700  ;;
5701  *)
5702  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5703for as_dir in $PATH
5704do
5705  IFS=$as_save_IFS
5706  test -z "$as_dir" && as_dir=.
5707    for ac_exec_ext in '' $ac_executable_extensions; do
5708  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5709    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5710    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5711    break 2
5712  fi
5713done
5714  done
5715IFS=$as_save_IFS
5716
5717  ;;
5718esac
5719fi
5720CPIO=$ac_cv_path_CPIO
5721if test -n "$CPIO"; then
5722  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5723$as_echo "$CPIO" >&6; }
5724else
5725  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5726$as_echo "no" >&6; }
5727fi
5728
5729
5730  test -n "$CPIO" && break
5731done
5732
5733    else
5734      # If it succeeded, then it was overridden by the user. We will use it
5735      # for the tool.
5736
5737      # First remove it from the list of overridden variables, so we can test
5738      # for unknown variables in the end.
5739      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5740
5741      # Check if the provided tool contains a complete path.
5742      tool_specified="$CPIO"
5743      tool_basename="${tool_specified##*/}"
5744      if test "x$tool_basename" = "x$tool_specified"; then
5745        # A command without a complete path is provided, search $PATH.
5746        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5
5747$as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;}
5748        # Extract the first word of "$tool_basename", so it can be a program name with args.
5749set dummy $tool_basename; ac_word=$2
5750{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5751$as_echo_n "checking for $ac_word... " >&6; }
5752if ${ac_cv_path_CPIO+:} false; then :
5753  $as_echo_n "(cached) " >&6
5754else
5755  case $CPIO in
5756  [\\/]* | ?:[\\/]*)
5757  ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5758  ;;
5759  *)
5760  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5761for as_dir in $PATH
5762do
5763  IFS=$as_save_IFS
5764  test -z "$as_dir" && as_dir=.
5765    for ac_exec_ext in '' $ac_executable_extensions; do
5766  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5767    ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5768    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5769    break 2
5770  fi
5771done
5772  done
5773IFS=$as_save_IFS
5774
5775  ;;
5776esac
5777fi
5778CPIO=$ac_cv_path_CPIO
5779if test -n "$CPIO"; then
5780  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5781$as_echo "$CPIO" >&6; }
5782else
5783  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5784$as_echo "no" >&6; }
5785fi
5786
5787
5788        if test "x$CPIO" = x; then
5789          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5790        fi
5791      else
5792        # Otherwise we believe it is a complete path. Use it as it is.
5793        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5
5794$as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;}
5795        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5
5796$as_echo_n "checking for CPIO... " >&6; }
5797        if test ! -x "$tool_specified"; then
5798          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5799$as_echo "not found" >&6; }
5800          as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5
5801        fi
5802        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5803$as_echo "$tool_specified" >&6; }
5804      fi
5805    fi
5806  fi
5807
5808
5809
5810  if test "x$CPIO" = x; then
5811    as_fn_error $? "Could not find required tool for CPIO" "$LINENO" 5
5812  fi
5813
5814
5815
5816
5817
5818  # Publish this variable in the help.
5819
5820
5821  if test "x$CUT" = x; then
5822    # The variable is not set by user, try to locate tool using the code snippet
5823    for ac_prog in cut
5824do
5825  # Extract the first word of "$ac_prog", so it can be a program name with args.
5826set dummy $ac_prog; ac_word=$2
5827{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5828$as_echo_n "checking for $ac_word... " >&6; }
5829if ${ac_cv_path_CUT+:} false; then :
5830  $as_echo_n "(cached) " >&6
5831else
5832  case $CUT in
5833  [\\/]* | ?:[\\/]*)
5834  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5835  ;;
5836  *)
5837  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5838for as_dir in $PATH
5839do
5840  IFS=$as_save_IFS
5841  test -z "$as_dir" && as_dir=.
5842    for ac_exec_ext in '' $ac_executable_extensions; do
5843  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5844    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5845    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5846    break 2
5847  fi
5848done
5849  done
5850IFS=$as_save_IFS
5851
5852  ;;
5853esac
5854fi
5855CUT=$ac_cv_path_CUT
5856if test -n "$CUT"; then
5857  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5858$as_echo "$CUT" >&6; }
5859else
5860  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5861$as_echo "no" >&6; }
5862fi
5863
5864
5865  test -n "$CUT" && break
5866done
5867
5868  else
5869    # The variable is set, but is it from the command line or the environment?
5870
5871    # Try to remove the string !CUT! from our list.
5872    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/}
5873    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5874      # If it failed, the variable was not from the command line. Ignore it,
5875      # but warn the user (except for BASH, which is always set by the calling BASH).
5876      if test "xCUT" != xBASH; then
5877        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5
5878$as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;}
5879      fi
5880      # Try to locate tool using the code snippet
5881      for ac_prog in cut
5882do
5883  # Extract the first word of "$ac_prog", so it can be a program name with args.
5884set dummy $ac_prog; ac_word=$2
5885{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5886$as_echo_n "checking for $ac_word... " >&6; }
5887if ${ac_cv_path_CUT+:} false; then :
5888  $as_echo_n "(cached) " >&6
5889else
5890  case $CUT in
5891  [\\/]* | ?:[\\/]*)
5892  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5893  ;;
5894  *)
5895  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5896for as_dir in $PATH
5897do
5898  IFS=$as_save_IFS
5899  test -z "$as_dir" && as_dir=.
5900    for ac_exec_ext in '' $ac_executable_extensions; do
5901  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5902    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5903    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5904    break 2
5905  fi
5906done
5907  done
5908IFS=$as_save_IFS
5909
5910  ;;
5911esac
5912fi
5913CUT=$ac_cv_path_CUT
5914if test -n "$CUT"; then
5915  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5916$as_echo "$CUT" >&6; }
5917else
5918  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5919$as_echo "no" >&6; }
5920fi
5921
5922
5923  test -n "$CUT" && break
5924done
5925
5926    else
5927      # If it succeeded, then it was overridden by the user. We will use it
5928      # for the tool.
5929
5930      # First remove it from the list of overridden variables, so we can test
5931      # for unknown variables in the end.
5932      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5933
5934      # Check if the provided tool contains a complete path.
5935      tool_specified="$CUT"
5936      tool_basename="${tool_specified##*/}"
5937      if test "x$tool_basename" = "x$tool_specified"; then
5938        # A command without a complete path is provided, search $PATH.
5939        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5
5940$as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;}
5941        # Extract the first word of "$tool_basename", so it can be a program name with args.
5942set dummy $tool_basename; ac_word=$2
5943{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5944$as_echo_n "checking for $ac_word... " >&6; }
5945if ${ac_cv_path_CUT+:} false; then :
5946  $as_echo_n "(cached) " >&6
5947else
5948  case $CUT in
5949  [\\/]* | ?:[\\/]*)
5950  ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5951  ;;
5952  *)
5953  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5954for as_dir in $PATH
5955do
5956  IFS=$as_save_IFS
5957  test -z "$as_dir" && as_dir=.
5958    for ac_exec_ext in '' $ac_executable_extensions; do
5959  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5960    ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5961    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5962    break 2
5963  fi
5964done
5965  done
5966IFS=$as_save_IFS
5967
5968  ;;
5969esac
5970fi
5971CUT=$ac_cv_path_CUT
5972if test -n "$CUT"; then
5973  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5974$as_echo "$CUT" >&6; }
5975else
5976  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5977$as_echo "no" >&6; }
5978fi
5979
5980
5981        if test "x$CUT" = x; then
5982          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5983        fi
5984      else
5985        # Otherwise we believe it is a complete path. Use it as it is.
5986        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5
5987$as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;}
5988        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5
5989$as_echo_n "checking for CUT... " >&6; }
5990        if test ! -x "$tool_specified"; then
5991          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5992$as_echo "not found" >&6; }
5993          as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5
5994        fi
5995        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5996$as_echo "$tool_specified" >&6; }
5997      fi
5998    fi
5999  fi
6000
6001
6002
6003  if test "x$CUT" = x; then
6004    as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5
6005  fi
6006
6007
6008
6009
6010
6011  # Publish this variable in the help.
6012
6013
6014  if test "x$DATE" = x; then
6015    # The variable is not set by user, try to locate tool using the code snippet
6016    for ac_prog in date
6017do
6018  # Extract the first word of "$ac_prog", so it can be a program name with args.
6019set dummy $ac_prog; ac_word=$2
6020{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6021$as_echo_n "checking for $ac_word... " >&6; }
6022if ${ac_cv_path_DATE+:} false; then :
6023  $as_echo_n "(cached) " >&6
6024else
6025  case $DATE in
6026  [\\/]* | ?:[\\/]*)
6027  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6028  ;;
6029  *)
6030  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6031for as_dir in $PATH
6032do
6033  IFS=$as_save_IFS
6034  test -z "$as_dir" && as_dir=.
6035    for ac_exec_ext in '' $ac_executable_extensions; do
6036  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6037    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6038    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6039    break 2
6040  fi
6041done
6042  done
6043IFS=$as_save_IFS
6044
6045  ;;
6046esac
6047fi
6048DATE=$ac_cv_path_DATE
6049if test -n "$DATE"; then
6050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6051$as_echo "$DATE" >&6; }
6052else
6053  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6054$as_echo "no" >&6; }
6055fi
6056
6057
6058  test -n "$DATE" && break
6059done
6060
6061  else
6062    # The variable is set, but is it from the command line or the environment?
6063
6064    # Try to remove the string !DATE! from our list.
6065    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/}
6066    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6067      # If it failed, the variable was not from the command line. Ignore it,
6068      # but warn the user (except for BASH, which is always set by the calling BASH).
6069      if test "xDATE" != xBASH; then
6070        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5
6071$as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;}
6072      fi
6073      # Try to locate tool using the code snippet
6074      for ac_prog in date
6075do
6076  # Extract the first word of "$ac_prog", so it can be a program name with args.
6077set dummy $ac_prog; ac_word=$2
6078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6079$as_echo_n "checking for $ac_word... " >&6; }
6080if ${ac_cv_path_DATE+:} false; then :
6081  $as_echo_n "(cached) " >&6
6082else
6083  case $DATE in
6084  [\\/]* | ?:[\\/]*)
6085  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6086  ;;
6087  *)
6088  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6089for as_dir in $PATH
6090do
6091  IFS=$as_save_IFS
6092  test -z "$as_dir" && as_dir=.
6093    for ac_exec_ext in '' $ac_executable_extensions; do
6094  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6095    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6096    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6097    break 2
6098  fi
6099done
6100  done
6101IFS=$as_save_IFS
6102
6103  ;;
6104esac
6105fi
6106DATE=$ac_cv_path_DATE
6107if test -n "$DATE"; then
6108  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6109$as_echo "$DATE" >&6; }
6110else
6111  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6112$as_echo "no" >&6; }
6113fi
6114
6115
6116  test -n "$DATE" && break
6117done
6118
6119    else
6120      # If it succeeded, then it was overridden by the user. We will use it
6121      # for the tool.
6122
6123      # First remove it from the list of overridden variables, so we can test
6124      # for unknown variables in the end.
6125      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6126
6127      # Check if the provided tool contains a complete path.
6128      tool_specified="$DATE"
6129      tool_basename="${tool_specified##*/}"
6130      if test "x$tool_basename" = "x$tool_specified"; then
6131        # A command without a complete path is provided, search $PATH.
6132        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5
6133$as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;}
6134        # Extract the first word of "$tool_basename", so it can be a program name with args.
6135set dummy $tool_basename; ac_word=$2
6136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6137$as_echo_n "checking for $ac_word... " >&6; }
6138if ${ac_cv_path_DATE+:} false; then :
6139  $as_echo_n "(cached) " >&6
6140else
6141  case $DATE in
6142  [\\/]* | ?:[\\/]*)
6143  ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6144  ;;
6145  *)
6146  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6147for as_dir in $PATH
6148do
6149  IFS=$as_save_IFS
6150  test -z "$as_dir" && as_dir=.
6151    for ac_exec_ext in '' $ac_executable_extensions; do
6152  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6153    ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6154    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6155    break 2
6156  fi
6157done
6158  done
6159IFS=$as_save_IFS
6160
6161  ;;
6162esac
6163fi
6164DATE=$ac_cv_path_DATE
6165if test -n "$DATE"; then
6166  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6167$as_echo "$DATE" >&6; }
6168else
6169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6170$as_echo "no" >&6; }
6171fi
6172
6173
6174        if test "x$DATE" = x; then
6175          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6176        fi
6177      else
6178        # Otherwise we believe it is a complete path. Use it as it is.
6179        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5
6180$as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;}
6181        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5
6182$as_echo_n "checking for DATE... " >&6; }
6183        if test ! -x "$tool_specified"; then
6184          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6185$as_echo "not found" >&6; }
6186          as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5
6187        fi
6188        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6189$as_echo "$tool_specified" >&6; }
6190      fi
6191    fi
6192  fi
6193
6194
6195
6196  if test "x$DATE" = x; then
6197    as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5
6198  fi
6199
6200
6201
6202
6203
6204  # Publish this variable in the help.
6205
6206
6207  if test "x$DIFF" = x; then
6208    # The variable is not set by user, try to locate tool using the code snippet
6209    for ac_prog in gdiff diff
6210do
6211  # Extract the first word of "$ac_prog", so it can be a program name with args.
6212set dummy $ac_prog; ac_word=$2
6213{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6214$as_echo_n "checking for $ac_word... " >&6; }
6215if ${ac_cv_path_DIFF+:} false; then :
6216  $as_echo_n "(cached) " >&6
6217else
6218  case $DIFF in
6219  [\\/]* | ?:[\\/]*)
6220  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6221  ;;
6222  *)
6223  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6224for as_dir in $PATH
6225do
6226  IFS=$as_save_IFS
6227  test -z "$as_dir" && as_dir=.
6228    for ac_exec_ext in '' $ac_executable_extensions; do
6229  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6230    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6231    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6232    break 2
6233  fi
6234done
6235  done
6236IFS=$as_save_IFS
6237
6238  ;;
6239esac
6240fi
6241DIFF=$ac_cv_path_DIFF
6242if test -n "$DIFF"; then
6243  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6244$as_echo "$DIFF" >&6; }
6245else
6246  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6247$as_echo "no" >&6; }
6248fi
6249
6250
6251  test -n "$DIFF" && break
6252done
6253
6254  else
6255    # The variable is set, but is it from the command line or the environment?
6256
6257    # Try to remove the string !DIFF! from our list.
6258    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/}
6259    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6260      # If it failed, the variable was not from the command line. Ignore it,
6261      # but warn the user (except for BASH, which is always set by the calling BASH).
6262      if test "xDIFF" != xBASH; then
6263        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5
6264$as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;}
6265      fi
6266      # Try to locate tool using the code snippet
6267      for ac_prog in gdiff diff
6268do
6269  # Extract the first word of "$ac_prog", so it can be a program name with args.
6270set dummy $ac_prog; ac_word=$2
6271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6272$as_echo_n "checking for $ac_word... " >&6; }
6273if ${ac_cv_path_DIFF+:} false; then :
6274  $as_echo_n "(cached) " >&6
6275else
6276  case $DIFF in
6277  [\\/]* | ?:[\\/]*)
6278  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6279  ;;
6280  *)
6281  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6282for as_dir in $PATH
6283do
6284  IFS=$as_save_IFS
6285  test -z "$as_dir" && as_dir=.
6286    for ac_exec_ext in '' $ac_executable_extensions; do
6287  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6288    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6289    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6290    break 2
6291  fi
6292done
6293  done
6294IFS=$as_save_IFS
6295
6296  ;;
6297esac
6298fi
6299DIFF=$ac_cv_path_DIFF
6300if test -n "$DIFF"; then
6301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6302$as_echo "$DIFF" >&6; }
6303else
6304  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6305$as_echo "no" >&6; }
6306fi
6307
6308
6309  test -n "$DIFF" && break
6310done
6311
6312    else
6313      # If it succeeded, then it was overridden by the user. We will use it
6314      # for the tool.
6315
6316      # First remove it from the list of overridden variables, so we can test
6317      # for unknown variables in the end.
6318      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6319
6320      # Check if the provided tool contains a complete path.
6321      tool_specified="$DIFF"
6322      tool_basename="${tool_specified##*/}"
6323      if test "x$tool_basename" = "x$tool_specified"; then
6324        # A command without a complete path is provided, search $PATH.
6325        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5
6326$as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;}
6327        # Extract the first word of "$tool_basename", so it can be a program name with args.
6328set dummy $tool_basename; ac_word=$2
6329{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6330$as_echo_n "checking for $ac_word... " >&6; }
6331if ${ac_cv_path_DIFF+:} false; then :
6332  $as_echo_n "(cached) " >&6
6333else
6334  case $DIFF in
6335  [\\/]* | ?:[\\/]*)
6336  ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6337  ;;
6338  *)
6339  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6340for as_dir in $PATH
6341do
6342  IFS=$as_save_IFS
6343  test -z "$as_dir" && as_dir=.
6344    for ac_exec_ext in '' $ac_executable_extensions; do
6345  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6346    ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6347    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6348    break 2
6349  fi
6350done
6351  done
6352IFS=$as_save_IFS
6353
6354  ;;
6355esac
6356fi
6357DIFF=$ac_cv_path_DIFF
6358if test -n "$DIFF"; then
6359  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6360$as_echo "$DIFF" >&6; }
6361else
6362  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6363$as_echo "no" >&6; }
6364fi
6365
6366
6367        if test "x$DIFF" = x; then
6368          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6369        fi
6370      else
6371        # Otherwise we believe it is a complete path. Use it as it is.
6372        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5
6373$as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;}
6374        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5
6375$as_echo_n "checking for DIFF... " >&6; }
6376        if test ! -x "$tool_specified"; then
6377          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6378$as_echo "not found" >&6; }
6379          as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5
6380        fi
6381        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6382$as_echo "$tool_specified" >&6; }
6383      fi
6384    fi
6385  fi
6386
6387
6388
6389  if test "x$DIFF" = x; then
6390    as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5
6391  fi
6392
6393
6394
6395
6396
6397  # Publish this variable in the help.
6398
6399
6400  if test "x$DIRNAME" = x; then
6401    # The variable is not set by user, try to locate tool using the code snippet
6402    for ac_prog in dirname
6403do
6404  # Extract the first word of "$ac_prog", so it can be a program name with args.
6405set dummy $ac_prog; ac_word=$2
6406{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6407$as_echo_n "checking for $ac_word... " >&6; }
6408if ${ac_cv_path_DIRNAME+:} false; then :
6409  $as_echo_n "(cached) " >&6
6410else
6411  case $DIRNAME in
6412  [\\/]* | ?:[\\/]*)
6413  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6414  ;;
6415  *)
6416  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6417for as_dir in $PATH
6418do
6419  IFS=$as_save_IFS
6420  test -z "$as_dir" && as_dir=.
6421    for ac_exec_ext in '' $ac_executable_extensions; do
6422  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6423    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6424    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6425    break 2
6426  fi
6427done
6428  done
6429IFS=$as_save_IFS
6430
6431  ;;
6432esac
6433fi
6434DIRNAME=$ac_cv_path_DIRNAME
6435if test -n "$DIRNAME"; then
6436  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6437$as_echo "$DIRNAME" >&6; }
6438else
6439  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6440$as_echo "no" >&6; }
6441fi
6442
6443
6444  test -n "$DIRNAME" && break
6445done
6446
6447  else
6448    # The variable is set, but is it from the command line or the environment?
6449
6450    # Try to remove the string !DIRNAME! from our list.
6451    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/}
6452    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6453      # If it failed, the variable was not from the command line. Ignore it,
6454      # but warn the user (except for BASH, which is always set by the calling BASH).
6455      if test "xDIRNAME" != xBASH; then
6456        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5
6457$as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;}
6458      fi
6459      # Try to locate tool using the code snippet
6460      for ac_prog in dirname
6461do
6462  # Extract the first word of "$ac_prog", so it can be a program name with args.
6463set dummy $ac_prog; ac_word=$2
6464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6465$as_echo_n "checking for $ac_word... " >&6; }
6466if ${ac_cv_path_DIRNAME+:} false; then :
6467  $as_echo_n "(cached) " >&6
6468else
6469  case $DIRNAME in
6470  [\\/]* | ?:[\\/]*)
6471  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6472  ;;
6473  *)
6474  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6475for as_dir in $PATH
6476do
6477  IFS=$as_save_IFS
6478  test -z "$as_dir" && as_dir=.
6479    for ac_exec_ext in '' $ac_executable_extensions; do
6480  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6481    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6482    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6483    break 2
6484  fi
6485done
6486  done
6487IFS=$as_save_IFS
6488
6489  ;;
6490esac
6491fi
6492DIRNAME=$ac_cv_path_DIRNAME
6493if test -n "$DIRNAME"; then
6494  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6495$as_echo "$DIRNAME" >&6; }
6496else
6497  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6498$as_echo "no" >&6; }
6499fi
6500
6501
6502  test -n "$DIRNAME" && break
6503done
6504
6505    else
6506      # If it succeeded, then it was overridden by the user. We will use it
6507      # for the tool.
6508
6509      # First remove it from the list of overridden variables, so we can test
6510      # for unknown variables in the end.
6511      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6512
6513      # Check if the provided tool contains a complete path.
6514      tool_specified="$DIRNAME"
6515      tool_basename="${tool_specified##*/}"
6516      if test "x$tool_basename" = "x$tool_specified"; then
6517        # A command without a complete path is provided, search $PATH.
6518        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5
6519$as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;}
6520        # Extract the first word of "$tool_basename", so it can be a program name with args.
6521set dummy $tool_basename; ac_word=$2
6522{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6523$as_echo_n "checking for $ac_word... " >&6; }
6524if ${ac_cv_path_DIRNAME+:} false; then :
6525  $as_echo_n "(cached) " >&6
6526else
6527  case $DIRNAME in
6528  [\\/]* | ?:[\\/]*)
6529  ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6530  ;;
6531  *)
6532  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6533for as_dir in $PATH
6534do
6535  IFS=$as_save_IFS
6536  test -z "$as_dir" && as_dir=.
6537    for ac_exec_ext in '' $ac_executable_extensions; do
6538  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6539    ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6540    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6541    break 2
6542  fi
6543done
6544  done
6545IFS=$as_save_IFS
6546
6547  ;;
6548esac
6549fi
6550DIRNAME=$ac_cv_path_DIRNAME
6551if test -n "$DIRNAME"; then
6552  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6553$as_echo "$DIRNAME" >&6; }
6554else
6555  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6556$as_echo "no" >&6; }
6557fi
6558
6559
6560        if test "x$DIRNAME" = x; then
6561          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6562        fi
6563      else
6564        # Otherwise we believe it is a complete path. Use it as it is.
6565        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5
6566$as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;}
6567        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5
6568$as_echo_n "checking for DIRNAME... " >&6; }
6569        if test ! -x "$tool_specified"; then
6570          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6571$as_echo "not found" >&6; }
6572          as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
6573        fi
6574        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6575$as_echo "$tool_specified" >&6; }
6576      fi
6577    fi
6578  fi
6579
6580
6581
6582  if test "x$DIRNAME" = x; then
6583    as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5
6584  fi
6585
6586
6587
6588
6589
6590  # Publish this variable in the help.
6591
6592
6593  if test "x$ECHO" = x; then
6594    # The variable is not set by user, try to locate tool using the code snippet
6595    for ac_prog in echo
6596do
6597  # Extract the first word of "$ac_prog", so it can be a program name with args.
6598set dummy $ac_prog; ac_word=$2
6599{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6600$as_echo_n "checking for $ac_word... " >&6; }
6601if ${ac_cv_path_ECHO+:} false; then :
6602  $as_echo_n "(cached) " >&6
6603else
6604  case $ECHO in
6605  [\\/]* | ?:[\\/]*)
6606  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6607  ;;
6608  *)
6609  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6610for as_dir in $PATH
6611do
6612  IFS=$as_save_IFS
6613  test -z "$as_dir" && as_dir=.
6614    for ac_exec_ext in '' $ac_executable_extensions; do
6615  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6616    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6617    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6618    break 2
6619  fi
6620done
6621  done
6622IFS=$as_save_IFS
6623
6624  ;;
6625esac
6626fi
6627ECHO=$ac_cv_path_ECHO
6628if test -n "$ECHO"; then
6629  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6630$as_echo "$ECHO" >&6; }
6631else
6632  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6633$as_echo "no" >&6; }
6634fi
6635
6636
6637  test -n "$ECHO" && break
6638done
6639
6640  else
6641    # The variable is set, but is it from the command line or the environment?
6642
6643    # Try to remove the string !ECHO! from our list.
6644    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/}
6645    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6646      # If it failed, the variable was not from the command line. Ignore it,
6647      # but warn the user (except for BASH, which is always set by the calling BASH).
6648      if test "xECHO" != xBASH; then
6649        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5
6650$as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;}
6651      fi
6652      # Try to locate tool using the code snippet
6653      for ac_prog in echo
6654do
6655  # Extract the first word of "$ac_prog", so it can be a program name with args.
6656set dummy $ac_prog; ac_word=$2
6657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6658$as_echo_n "checking for $ac_word... " >&6; }
6659if ${ac_cv_path_ECHO+:} false; then :
6660  $as_echo_n "(cached) " >&6
6661else
6662  case $ECHO in
6663  [\\/]* | ?:[\\/]*)
6664  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6665  ;;
6666  *)
6667  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6668for as_dir in $PATH
6669do
6670  IFS=$as_save_IFS
6671  test -z "$as_dir" && as_dir=.
6672    for ac_exec_ext in '' $ac_executable_extensions; do
6673  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6674    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6675    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6676    break 2
6677  fi
6678done
6679  done
6680IFS=$as_save_IFS
6681
6682  ;;
6683esac
6684fi
6685ECHO=$ac_cv_path_ECHO
6686if test -n "$ECHO"; then
6687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6688$as_echo "$ECHO" >&6; }
6689else
6690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6691$as_echo "no" >&6; }
6692fi
6693
6694
6695  test -n "$ECHO" && break
6696done
6697
6698    else
6699      # If it succeeded, then it was overridden by the user. We will use it
6700      # for the tool.
6701
6702      # First remove it from the list of overridden variables, so we can test
6703      # for unknown variables in the end.
6704      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6705
6706      # Check if the provided tool contains a complete path.
6707      tool_specified="$ECHO"
6708      tool_basename="${tool_specified##*/}"
6709      if test "x$tool_basename" = "x$tool_specified"; then
6710        # A command without a complete path is provided, search $PATH.
6711        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5
6712$as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;}
6713        # Extract the first word of "$tool_basename", so it can be a program name with args.
6714set dummy $tool_basename; ac_word=$2
6715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6716$as_echo_n "checking for $ac_word... " >&6; }
6717if ${ac_cv_path_ECHO+:} false; then :
6718  $as_echo_n "(cached) " >&6
6719else
6720  case $ECHO in
6721  [\\/]* | ?:[\\/]*)
6722  ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6723  ;;
6724  *)
6725  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6726for as_dir in $PATH
6727do
6728  IFS=$as_save_IFS
6729  test -z "$as_dir" && as_dir=.
6730    for ac_exec_ext in '' $ac_executable_extensions; do
6731  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6732    ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6733    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6734    break 2
6735  fi
6736done
6737  done
6738IFS=$as_save_IFS
6739
6740  ;;
6741esac
6742fi
6743ECHO=$ac_cv_path_ECHO
6744if test -n "$ECHO"; then
6745  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6746$as_echo "$ECHO" >&6; }
6747else
6748  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6749$as_echo "no" >&6; }
6750fi
6751
6752
6753        if test "x$ECHO" = x; then
6754          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6755        fi
6756      else
6757        # Otherwise we believe it is a complete path. Use it as it is.
6758        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5
6759$as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;}
6760        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5
6761$as_echo_n "checking for ECHO... " >&6; }
6762        if test ! -x "$tool_specified"; then
6763          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6764$as_echo "not found" >&6; }
6765          as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5
6766        fi
6767        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6768$as_echo "$tool_specified" >&6; }
6769      fi
6770    fi
6771  fi
6772
6773
6774
6775  if test "x$ECHO" = x; then
6776    as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5
6777  fi
6778
6779
6780
6781
6782
6783  # Publish this variable in the help.
6784
6785
6786  if test "x$EXPR" = x; then
6787    # The variable is not set by user, try to locate tool using the code snippet
6788    for ac_prog in expr
6789do
6790  # Extract the first word of "$ac_prog", so it can be a program name with args.
6791set dummy $ac_prog; ac_word=$2
6792{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6793$as_echo_n "checking for $ac_word... " >&6; }
6794if ${ac_cv_path_EXPR+:} false; then :
6795  $as_echo_n "(cached) " >&6
6796else
6797  case $EXPR in
6798  [\\/]* | ?:[\\/]*)
6799  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6800  ;;
6801  *)
6802  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6803for as_dir in $PATH
6804do
6805  IFS=$as_save_IFS
6806  test -z "$as_dir" && as_dir=.
6807    for ac_exec_ext in '' $ac_executable_extensions; do
6808  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6809    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6810    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6811    break 2
6812  fi
6813done
6814  done
6815IFS=$as_save_IFS
6816
6817  ;;
6818esac
6819fi
6820EXPR=$ac_cv_path_EXPR
6821if test -n "$EXPR"; then
6822  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6823$as_echo "$EXPR" >&6; }
6824else
6825  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6826$as_echo "no" >&6; }
6827fi
6828
6829
6830  test -n "$EXPR" && break
6831done
6832
6833  else
6834    # The variable is set, but is it from the command line or the environment?
6835
6836    # Try to remove the string !EXPR! from our list.
6837    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/}
6838    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6839      # If it failed, the variable was not from the command line. Ignore it,
6840      # but warn the user (except for BASH, which is always set by the calling BASH).
6841      if test "xEXPR" != xBASH; then
6842        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5
6843$as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;}
6844      fi
6845      # Try to locate tool using the code snippet
6846      for ac_prog in expr
6847do
6848  # Extract the first word of "$ac_prog", so it can be a program name with args.
6849set dummy $ac_prog; ac_word=$2
6850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6851$as_echo_n "checking for $ac_word... " >&6; }
6852if ${ac_cv_path_EXPR+:} false; then :
6853  $as_echo_n "(cached) " >&6
6854else
6855  case $EXPR in
6856  [\\/]* | ?:[\\/]*)
6857  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6858  ;;
6859  *)
6860  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6861for as_dir in $PATH
6862do
6863  IFS=$as_save_IFS
6864  test -z "$as_dir" && as_dir=.
6865    for ac_exec_ext in '' $ac_executable_extensions; do
6866  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6867    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6868    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6869    break 2
6870  fi
6871done
6872  done
6873IFS=$as_save_IFS
6874
6875  ;;
6876esac
6877fi
6878EXPR=$ac_cv_path_EXPR
6879if test -n "$EXPR"; then
6880  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6881$as_echo "$EXPR" >&6; }
6882else
6883  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6884$as_echo "no" >&6; }
6885fi
6886
6887
6888  test -n "$EXPR" && break
6889done
6890
6891    else
6892      # If it succeeded, then it was overridden by the user. We will use it
6893      # for the tool.
6894
6895      # First remove it from the list of overridden variables, so we can test
6896      # for unknown variables in the end.
6897      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6898
6899      # Check if the provided tool contains a complete path.
6900      tool_specified="$EXPR"
6901      tool_basename="${tool_specified##*/}"
6902      if test "x$tool_basename" = "x$tool_specified"; then
6903        # A command without a complete path is provided, search $PATH.
6904        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5
6905$as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;}
6906        # Extract the first word of "$tool_basename", so it can be a program name with args.
6907set dummy $tool_basename; ac_word=$2
6908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6909$as_echo_n "checking for $ac_word... " >&6; }
6910if ${ac_cv_path_EXPR+:} false; then :
6911  $as_echo_n "(cached) " >&6
6912else
6913  case $EXPR in
6914  [\\/]* | ?:[\\/]*)
6915  ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6916  ;;
6917  *)
6918  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6919for as_dir in $PATH
6920do
6921  IFS=$as_save_IFS
6922  test -z "$as_dir" && as_dir=.
6923    for ac_exec_ext in '' $ac_executable_extensions; do
6924  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6925    ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6926    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6927    break 2
6928  fi
6929done
6930  done
6931IFS=$as_save_IFS
6932
6933  ;;
6934esac
6935fi
6936EXPR=$ac_cv_path_EXPR
6937if test -n "$EXPR"; then
6938  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6939$as_echo "$EXPR" >&6; }
6940else
6941  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6942$as_echo "no" >&6; }
6943fi
6944
6945
6946        if test "x$EXPR" = x; then
6947          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6948        fi
6949      else
6950        # Otherwise we believe it is a complete path. Use it as it is.
6951        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5
6952$as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;}
6953        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5
6954$as_echo_n "checking for EXPR... " >&6; }
6955        if test ! -x "$tool_specified"; then
6956          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6957$as_echo "not found" >&6; }
6958          as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5
6959        fi
6960        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6961$as_echo "$tool_specified" >&6; }
6962      fi
6963    fi
6964  fi
6965
6966
6967
6968  if test "x$EXPR" = x; then
6969    as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5
6970  fi
6971
6972
6973
6974
6975
6976  # Publish this variable in the help.
6977
6978
6979  if test "x$FILE" = x; then
6980    # The variable is not set by user, try to locate tool using the code snippet
6981    for ac_prog in file
6982do
6983  # Extract the first word of "$ac_prog", so it can be a program name with args.
6984set dummy $ac_prog; ac_word=$2
6985{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6986$as_echo_n "checking for $ac_word... " >&6; }
6987if ${ac_cv_path_FILE+:} false; then :
6988  $as_echo_n "(cached) " >&6
6989else
6990  case $FILE in
6991  [\\/]* | ?:[\\/]*)
6992  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6993  ;;
6994  *)
6995  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6996for as_dir in $PATH
6997do
6998  IFS=$as_save_IFS
6999  test -z "$as_dir" && as_dir=.
7000    for ac_exec_ext in '' $ac_executable_extensions; do
7001  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7002    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7003    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7004    break 2
7005  fi
7006done
7007  done
7008IFS=$as_save_IFS
7009
7010  ;;
7011esac
7012fi
7013FILE=$ac_cv_path_FILE
7014if test -n "$FILE"; then
7015  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7016$as_echo "$FILE" >&6; }
7017else
7018  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7019$as_echo "no" >&6; }
7020fi
7021
7022
7023  test -n "$FILE" && break
7024done
7025
7026  else
7027    # The variable is set, but is it from the command line or the environment?
7028
7029    # Try to remove the string !FILE! from our list.
7030    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/}
7031    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7032      # If it failed, the variable was not from the command line. Ignore it,
7033      # but warn the user (except for BASH, which is always set by the calling BASH).
7034      if test "xFILE" != xBASH; then
7035        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5
7036$as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;}
7037      fi
7038      # Try to locate tool using the code snippet
7039      for ac_prog in file
7040do
7041  # Extract the first word of "$ac_prog", so it can be a program name with args.
7042set dummy $ac_prog; ac_word=$2
7043{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7044$as_echo_n "checking for $ac_word... " >&6; }
7045if ${ac_cv_path_FILE+:} false; then :
7046  $as_echo_n "(cached) " >&6
7047else
7048  case $FILE in
7049  [\\/]* | ?:[\\/]*)
7050  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7051  ;;
7052  *)
7053  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7054for as_dir in $PATH
7055do
7056  IFS=$as_save_IFS
7057  test -z "$as_dir" && as_dir=.
7058    for ac_exec_ext in '' $ac_executable_extensions; do
7059  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7060    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7061    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7062    break 2
7063  fi
7064done
7065  done
7066IFS=$as_save_IFS
7067
7068  ;;
7069esac
7070fi
7071FILE=$ac_cv_path_FILE
7072if test -n "$FILE"; then
7073  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7074$as_echo "$FILE" >&6; }
7075else
7076  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7077$as_echo "no" >&6; }
7078fi
7079
7080
7081  test -n "$FILE" && break
7082done
7083
7084    else
7085      # If it succeeded, then it was overridden by the user. We will use it
7086      # for the tool.
7087
7088      # First remove it from the list of overridden variables, so we can test
7089      # for unknown variables in the end.
7090      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7091
7092      # Check if the provided tool contains a complete path.
7093      tool_specified="$FILE"
7094      tool_basename="${tool_specified##*/}"
7095      if test "x$tool_basename" = "x$tool_specified"; then
7096        # A command without a complete path is provided, search $PATH.
7097        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5
7098$as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;}
7099        # Extract the first word of "$tool_basename", so it can be a program name with args.
7100set dummy $tool_basename; ac_word=$2
7101{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7102$as_echo_n "checking for $ac_word... " >&6; }
7103if ${ac_cv_path_FILE+:} false; then :
7104  $as_echo_n "(cached) " >&6
7105else
7106  case $FILE in
7107  [\\/]* | ?:[\\/]*)
7108  ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7109  ;;
7110  *)
7111  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7112for as_dir in $PATH
7113do
7114  IFS=$as_save_IFS
7115  test -z "$as_dir" && as_dir=.
7116    for ac_exec_ext in '' $ac_executable_extensions; do
7117  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7118    ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7119    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7120    break 2
7121  fi
7122done
7123  done
7124IFS=$as_save_IFS
7125
7126  ;;
7127esac
7128fi
7129FILE=$ac_cv_path_FILE
7130if test -n "$FILE"; then
7131  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7132$as_echo "$FILE" >&6; }
7133else
7134  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7135$as_echo "no" >&6; }
7136fi
7137
7138
7139        if test "x$FILE" = x; then
7140          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7141        fi
7142      else
7143        # Otherwise we believe it is a complete path. Use it as it is.
7144        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5
7145$as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;}
7146        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5
7147$as_echo_n "checking for FILE... " >&6; }
7148        if test ! -x "$tool_specified"; then
7149          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7150$as_echo "not found" >&6; }
7151          as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5
7152        fi
7153        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7154$as_echo "$tool_specified" >&6; }
7155      fi
7156    fi
7157  fi
7158
7159
7160
7161  if test "x$FILE" = x; then
7162    as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5
7163  fi
7164
7165
7166
7167
7168
7169  # Publish this variable in the help.
7170
7171
7172  if test "x$FIND" = x; then
7173    # The variable is not set by user, try to locate tool using the code snippet
7174    for ac_prog in find
7175do
7176  # Extract the first word of "$ac_prog", so it can be a program name with args.
7177set dummy $ac_prog; ac_word=$2
7178{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7179$as_echo_n "checking for $ac_word... " >&6; }
7180if ${ac_cv_path_FIND+:} false; then :
7181  $as_echo_n "(cached) " >&6
7182else
7183  case $FIND in
7184  [\\/]* | ?:[\\/]*)
7185  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7186  ;;
7187  *)
7188  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7189for as_dir in $PATH
7190do
7191  IFS=$as_save_IFS
7192  test -z "$as_dir" && as_dir=.
7193    for ac_exec_ext in '' $ac_executable_extensions; do
7194  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7195    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7196    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7197    break 2
7198  fi
7199done
7200  done
7201IFS=$as_save_IFS
7202
7203  ;;
7204esac
7205fi
7206FIND=$ac_cv_path_FIND
7207if test -n "$FIND"; then
7208  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7209$as_echo "$FIND" >&6; }
7210else
7211  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7212$as_echo "no" >&6; }
7213fi
7214
7215
7216  test -n "$FIND" && break
7217done
7218
7219  else
7220    # The variable is set, but is it from the command line or the environment?
7221
7222    # Try to remove the string !FIND! from our list.
7223    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/}
7224    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7225      # If it failed, the variable was not from the command line. Ignore it,
7226      # but warn the user (except for BASH, which is always set by the calling BASH).
7227      if test "xFIND" != xBASH; then
7228        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5
7229$as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;}
7230      fi
7231      # Try to locate tool using the code snippet
7232      for ac_prog in find
7233do
7234  # Extract the first word of "$ac_prog", so it can be a program name with args.
7235set dummy $ac_prog; ac_word=$2
7236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7237$as_echo_n "checking for $ac_word... " >&6; }
7238if ${ac_cv_path_FIND+:} false; then :
7239  $as_echo_n "(cached) " >&6
7240else
7241  case $FIND in
7242  [\\/]* | ?:[\\/]*)
7243  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7244  ;;
7245  *)
7246  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7247for as_dir in $PATH
7248do
7249  IFS=$as_save_IFS
7250  test -z "$as_dir" && as_dir=.
7251    for ac_exec_ext in '' $ac_executable_extensions; do
7252  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7253    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7254    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7255    break 2
7256  fi
7257done
7258  done
7259IFS=$as_save_IFS
7260
7261  ;;
7262esac
7263fi
7264FIND=$ac_cv_path_FIND
7265if test -n "$FIND"; then
7266  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7267$as_echo "$FIND" >&6; }
7268else
7269  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7270$as_echo "no" >&6; }
7271fi
7272
7273
7274  test -n "$FIND" && break
7275done
7276
7277    else
7278      # If it succeeded, then it was overridden by the user. We will use it
7279      # for the tool.
7280
7281      # First remove it from the list of overridden variables, so we can test
7282      # for unknown variables in the end.
7283      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7284
7285      # Check if the provided tool contains a complete path.
7286      tool_specified="$FIND"
7287      tool_basename="${tool_specified##*/}"
7288      if test "x$tool_basename" = "x$tool_specified"; then
7289        # A command without a complete path is provided, search $PATH.
7290        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5
7291$as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;}
7292        # Extract the first word of "$tool_basename", so it can be a program name with args.
7293set dummy $tool_basename; ac_word=$2
7294{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7295$as_echo_n "checking for $ac_word... " >&6; }
7296if ${ac_cv_path_FIND+:} false; then :
7297  $as_echo_n "(cached) " >&6
7298else
7299  case $FIND in
7300  [\\/]* | ?:[\\/]*)
7301  ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7302  ;;
7303  *)
7304  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7305for as_dir in $PATH
7306do
7307  IFS=$as_save_IFS
7308  test -z "$as_dir" && as_dir=.
7309    for ac_exec_ext in '' $ac_executable_extensions; do
7310  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7311    ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7312    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7313    break 2
7314  fi
7315done
7316  done
7317IFS=$as_save_IFS
7318
7319  ;;
7320esac
7321fi
7322FIND=$ac_cv_path_FIND
7323if test -n "$FIND"; then
7324  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7325$as_echo "$FIND" >&6; }
7326else
7327  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7328$as_echo "no" >&6; }
7329fi
7330
7331
7332        if test "x$FIND" = x; then
7333          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7334        fi
7335      else
7336        # Otherwise we believe it is a complete path. Use it as it is.
7337        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5
7338$as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;}
7339        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5
7340$as_echo_n "checking for FIND... " >&6; }
7341        if test ! -x "$tool_specified"; then
7342          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7343$as_echo "not found" >&6; }
7344          as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5
7345        fi
7346        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7347$as_echo "$tool_specified" >&6; }
7348      fi
7349    fi
7350  fi
7351
7352
7353
7354  if test "x$FIND" = x; then
7355    as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5
7356  fi
7357
7358
7359
7360
7361
7362  # Publish this variable in the help.
7363
7364
7365  if test "x$HEAD" = x; then
7366    # The variable is not set by user, try to locate tool using the code snippet
7367    for ac_prog in head
7368do
7369  # Extract the first word of "$ac_prog", so it can be a program name with args.
7370set dummy $ac_prog; ac_word=$2
7371{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7372$as_echo_n "checking for $ac_word... " >&6; }
7373if ${ac_cv_path_HEAD+:} false; then :
7374  $as_echo_n "(cached) " >&6
7375else
7376  case $HEAD in
7377  [\\/]* | ?:[\\/]*)
7378  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7379  ;;
7380  *)
7381  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7382for as_dir in $PATH
7383do
7384  IFS=$as_save_IFS
7385  test -z "$as_dir" && as_dir=.
7386    for ac_exec_ext in '' $ac_executable_extensions; do
7387  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7388    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7389    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7390    break 2
7391  fi
7392done
7393  done
7394IFS=$as_save_IFS
7395
7396  ;;
7397esac
7398fi
7399HEAD=$ac_cv_path_HEAD
7400if test -n "$HEAD"; then
7401  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7402$as_echo "$HEAD" >&6; }
7403else
7404  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7405$as_echo "no" >&6; }
7406fi
7407
7408
7409  test -n "$HEAD" && break
7410done
7411
7412  else
7413    # The variable is set, but is it from the command line or the environment?
7414
7415    # Try to remove the string !HEAD! from our list.
7416    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/}
7417    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7418      # If it failed, the variable was not from the command line. Ignore it,
7419      # but warn the user (except for BASH, which is always set by the calling BASH).
7420      if test "xHEAD" != xBASH; then
7421        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5
7422$as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;}
7423      fi
7424      # Try to locate tool using the code snippet
7425      for ac_prog in head
7426do
7427  # Extract the first word of "$ac_prog", so it can be a program name with args.
7428set dummy $ac_prog; ac_word=$2
7429{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7430$as_echo_n "checking for $ac_word... " >&6; }
7431if ${ac_cv_path_HEAD+:} false; then :
7432  $as_echo_n "(cached) " >&6
7433else
7434  case $HEAD in
7435  [\\/]* | ?:[\\/]*)
7436  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7437  ;;
7438  *)
7439  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7440for as_dir in $PATH
7441do
7442  IFS=$as_save_IFS
7443  test -z "$as_dir" && as_dir=.
7444    for ac_exec_ext in '' $ac_executable_extensions; do
7445  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7446    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7447    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7448    break 2
7449  fi
7450done
7451  done
7452IFS=$as_save_IFS
7453
7454  ;;
7455esac
7456fi
7457HEAD=$ac_cv_path_HEAD
7458if test -n "$HEAD"; then
7459  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7460$as_echo "$HEAD" >&6; }
7461else
7462  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7463$as_echo "no" >&6; }
7464fi
7465
7466
7467  test -n "$HEAD" && break
7468done
7469
7470    else
7471      # If it succeeded, then it was overridden by the user. We will use it
7472      # for the tool.
7473
7474      # First remove it from the list of overridden variables, so we can test
7475      # for unknown variables in the end.
7476      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7477
7478      # Check if the provided tool contains a complete path.
7479      tool_specified="$HEAD"
7480      tool_basename="${tool_specified##*/}"
7481      if test "x$tool_basename" = "x$tool_specified"; then
7482        # A command without a complete path is provided, search $PATH.
7483        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5
7484$as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;}
7485        # Extract the first word of "$tool_basename", so it can be a program name with args.
7486set dummy $tool_basename; ac_word=$2
7487{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7488$as_echo_n "checking for $ac_word... " >&6; }
7489if ${ac_cv_path_HEAD+:} false; then :
7490  $as_echo_n "(cached) " >&6
7491else
7492  case $HEAD in
7493  [\\/]* | ?:[\\/]*)
7494  ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7495  ;;
7496  *)
7497  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7498for as_dir in $PATH
7499do
7500  IFS=$as_save_IFS
7501  test -z "$as_dir" && as_dir=.
7502    for ac_exec_ext in '' $ac_executable_extensions; do
7503  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7504    ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7505    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7506    break 2
7507  fi
7508done
7509  done
7510IFS=$as_save_IFS
7511
7512  ;;
7513esac
7514fi
7515HEAD=$ac_cv_path_HEAD
7516if test -n "$HEAD"; then
7517  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7518$as_echo "$HEAD" >&6; }
7519else
7520  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7521$as_echo "no" >&6; }
7522fi
7523
7524
7525        if test "x$HEAD" = x; then
7526          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7527        fi
7528      else
7529        # Otherwise we believe it is a complete path. Use it as it is.
7530        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5
7531$as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;}
7532        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5
7533$as_echo_n "checking for HEAD... " >&6; }
7534        if test ! -x "$tool_specified"; then
7535          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7536$as_echo "not found" >&6; }
7537          as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5
7538        fi
7539        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7540$as_echo "$tool_specified" >&6; }
7541      fi
7542    fi
7543  fi
7544
7545
7546
7547  if test "x$HEAD" = x; then
7548    as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5
7549  fi
7550
7551
7552
7553
7554
7555  # Publish this variable in the help.
7556
7557
7558  if test "x$LN" = x; then
7559    # The variable is not set by user, try to locate tool using the code snippet
7560    for ac_prog in ln
7561do
7562  # Extract the first word of "$ac_prog", so it can be a program name with args.
7563set dummy $ac_prog; ac_word=$2
7564{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7565$as_echo_n "checking for $ac_word... " >&6; }
7566if ${ac_cv_path_LN+:} false; then :
7567  $as_echo_n "(cached) " >&6
7568else
7569  case $LN in
7570  [\\/]* | ?:[\\/]*)
7571  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7572  ;;
7573  *)
7574  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7575for as_dir in $PATH
7576do
7577  IFS=$as_save_IFS
7578  test -z "$as_dir" && as_dir=.
7579    for ac_exec_ext in '' $ac_executable_extensions; do
7580  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7581    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7582    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7583    break 2
7584  fi
7585done
7586  done
7587IFS=$as_save_IFS
7588
7589  ;;
7590esac
7591fi
7592LN=$ac_cv_path_LN
7593if test -n "$LN"; then
7594  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7595$as_echo "$LN" >&6; }
7596else
7597  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7598$as_echo "no" >&6; }
7599fi
7600
7601
7602  test -n "$LN" && break
7603done
7604
7605  else
7606    # The variable is set, but is it from the command line or the environment?
7607
7608    # Try to remove the string !LN! from our list.
7609    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/}
7610    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7611      # If it failed, the variable was not from the command line. Ignore it,
7612      # but warn the user (except for BASH, which is always set by the calling BASH).
7613      if test "xLN" != xBASH; then
7614        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5
7615$as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;}
7616      fi
7617      # Try to locate tool using the code snippet
7618      for ac_prog in ln
7619do
7620  # Extract the first word of "$ac_prog", so it can be a program name with args.
7621set dummy $ac_prog; ac_word=$2
7622{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7623$as_echo_n "checking for $ac_word... " >&6; }
7624if ${ac_cv_path_LN+:} false; then :
7625  $as_echo_n "(cached) " >&6
7626else
7627  case $LN in
7628  [\\/]* | ?:[\\/]*)
7629  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7630  ;;
7631  *)
7632  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7633for as_dir in $PATH
7634do
7635  IFS=$as_save_IFS
7636  test -z "$as_dir" && as_dir=.
7637    for ac_exec_ext in '' $ac_executable_extensions; do
7638  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7639    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7640    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7641    break 2
7642  fi
7643done
7644  done
7645IFS=$as_save_IFS
7646
7647  ;;
7648esac
7649fi
7650LN=$ac_cv_path_LN
7651if test -n "$LN"; then
7652  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7653$as_echo "$LN" >&6; }
7654else
7655  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7656$as_echo "no" >&6; }
7657fi
7658
7659
7660  test -n "$LN" && break
7661done
7662
7663    else
7664      # If it succeeded, then it was overridden by the user. We will use it
7665      # for the tool.
7666
7667      # First remove it from the list of overridden variables, so we can test
7668      # for unknown variables in the end.
7669      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7670
7671      # Check if the provided tool contains a complete path.
7672      tool_specified="$LN"
7673      tool_basename="${tool_specified##*/}"
7674      if test "x$tool_basename" = "x$tool_specified"; then
7675        # A command without a complete path is provided, search $PATH.
7676        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5
7677$as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;}
7678        # Extract the first word of "$tool_basename", so it can be a program name with args.
7679set dummy $tool_basename; ac_word=$2
7680{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7681$as_echo_n "checking for $ac_word... " >&6; }
7682if ${ac_cv_path_LN+:} false; then :
7683  $as_echo_n "(cached) " >&6
7684else
7685  case $LN in
7686  [\\/]* | ?:[\\/]*)
7687  ac_cv_path_LN="$LN" # Let the user override the test with a path.
7688  ;;
7689  *)
7690  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7691for as_dir in $PATH
7692do
7693  IFS=$as_save_IFS
7694  test -z "$as_dir" && as_dir=.
7695    for ac_exec_ext in '' $ac_executable_extensions; do
7696  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7697    ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7698    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7699    break 2
7700  fi
7701done
7702  done
7703IFS=$as_save_IFS
7704
7705  ;;
7706esac
7707fi
7708LN=$ac_cv_path_LN
7709if test -n "$LN"; then
7710  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7711$as_echo "$LN" >&6; }
7712else
7713  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7714$as_echo "no" >&6; }
7715fi
7716
7717
7718        if test "x$LN" = x; then
7719          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7720        fi
7721      else
7722        # Otherwise we believe it is a complete path. Use it as it is.
7723        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5
7724$as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;}
7725        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5
7726$as_echo_n "checking for LN... " >&6; }
7727        if test ! -x "$tool_specified"; then
7728          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7729$as_echo "not found" >&6; }
7730          as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5
7731        fi
7732        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7733$as_echo "$tool_specified" >&6; }
7734      fi
7735    fi
7736  fi
7737
7738
7739
7740  if test "x$LN" = x; then
7741    as_fn_error $? "Could not find required tool for LN" "$LINENO" 5
7742  fi
7743
7744
7745
7746
7747
7748  # Publish this variable in the help.
7749
7750
7751  if test "x$LS" = x; then
7752    # The variable is not set by user, try to locate tool using the code snippet
7753    for ac_prog in ls
7754do
7755  # Extract the first word of "$ac_prog", so it can be a program name with args.
7756set dummy $ac_prog; ac_word=$2
7757{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7758$as_echo_n "checking for $ac_word... " >&6; }
7759if ${ac_cv_path_LS+:} false; then :
7760  $as_echo_n "(cached) " >&6
7761else
7762  case $LS in
7763  [\\/]* | ?:[\\/]*)
7764  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7765  ;;
7766  *)
7767  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7768for as_dir in $PATH
7769do
7770  IFS=$as_save_IFS
7771  test -z "$as_dir" && as_dir=.
7772    for ac_exec_ext in '' $ac_executable_extensions; do
7773  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7774    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7775    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7776    break 2
7777  fi
7778done
7779  done
7780IFS=$as_save_IFS
7781
7782  ;;
7783esac
7784fi
7785LS=$ac_cv_path_LS
7786if test -n "$LS"; then
7787  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7788$as_echo "$LS" >&6; }
7789else
7790  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7791$as_echo "no" >&6; }
7792fi
7793
7794
7795  test -n "$LS" && break
7796done
7797
7798  else
7799    # The variable is set, but is it from the command line or the environment?
7800
7801    # Try to remove the string !LS! from our list.
7802    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/}
7803    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7804      # If it failed, the variable was not from the command line. Ignore it,
7805      # but warn the user (except for BASH, which is always set by the calling BASH).
7806      if test "xLS" != xBASH; then
7807        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5
7808$as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;}
7809      fi
7810      # Try to locate tool using the code snippet
7811      for ac_prog in ls
7812do
7813  # Extract the first word of "$ac_prog", so it can be a program name with args.
7814set dummy $ac_prog; ac_word=$2
7815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7816$as_echo_n "checking for $ac_word... " >&6; }
7817if ${ac_cv_path_LS+:} false; then :
7818  $as_echo_n "(cached) " >&6
7819else
7820  case $LS in
7821  [\\/]* | ?:[\\/]*)
7822  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7823  ;;
7824  *)
7825  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7826for as_dir in $PATH
7827do
7828  IFS=$as_save_IFS
7829  test -z "$as_dir" && as_dir=.
7830    for ac_exec_ext in '' $ac_executable_extensions; do
7831  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7832    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7833    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7834    break 2
7835  fi
7836done
7837  done
7838IFS=$as_save_IFS
7839
7840  ;;
7841esac
7842fi
7843LS=$ac_cv_path_LS
7844if test -n "$LS"; then
7845  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7846$as_echo "$LS" >&6; }
7847else
7848  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7849$as_echo "no" >&6; }
7850fi
7851
7852
7853  test -n "$LS" && break
7854done
7855
7856    else
7857      # If it succeeded, then it was overridden by the user. We will use it
7858      # for the tool.
7859
7860      # First remove it from the list of overridden variables, so we can test
7861      # for unknown variables in the end.
7862      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7863
7864      # Check if the provided tool contains a complete path.
7865      tool_specified="$LS"
7866      tool_basename="${tool_specified##*/}"
7867      if test "x$tool_basename" = "x$tool_specified"; then
7868        # A command without a complete path is provided, search $PATH.
7869        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5
7870$as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;}
7871        # Extract the first word of "$tool_basename", so it can be a program name with args.
7872set dummy $tool_basename; ac_word=$2
7873{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7874$as_echo_n "checking for $ac_word... " >&6; }
7875if ${ac_cv_path_LS+:} false; then :
7876  $as_echo_n "(cached) " >&6
7877else
7878  case $LS in
7879  [\\/]* | ?:[\\/]*)
7880  ac_cv_path_LS="$LS" # Let the user override the test with a path.
7881  ;;
7882  *)
7883  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7884for as_dir in $PATH
7885do
7886  IFS=$as_save_IFS
7887  test -z "$as_dir" && as_dir=.
7888    for ac_exec_ext in '' $ac_executable_extensions; do
7889  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7890    ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7891    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7892    break 2
7893  fi
7894done
7895  done
7896IFS=$as_save_IFS
7897
7898  ;;
7899esac
7900fi
7901LS=$ac_cv_path_LS
7902if test -n "$LS"; then
7903  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7904$as_echo "$LS" >&6; }
7905else
7906  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7907$as_echo "no" >&6; }
7908fi
7909
7910
7911        if test "x$LS" = x; then
7912          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7913        fi
7914      else
7915        # Otherwise we believe it is a complete path. Use it as it is.
7916        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5
7917$as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;}
7918        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5
7919$as_echo_n "checking for LS... " >&6; }
7920        if test ! -x "$tool_specified"; then
7921          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7922$as_echo "not found" >&6; }
7923          as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5
7924        fi
7925        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7926$as_echo "$tool_specified" >&6; }
7927      fi
7928    fi
7929  fi
7930
7931
7932
7933  if test "x$LS" = x; then
7934    as_fn_error $? "Could not find required tool for LS" "$LINENO" 5
7935  fi
7936
7937
7938
7939
7940
7941  # Publish this variable in the help.
7942
7943
7944  if test "x$MKDIR" = x; then
7945    # The variable is not set by user, try to locate tool using the code snippet
7946    for ac_prog in mkdir
7947do
7948  # Extract the first word of "$ac_prog", so it can be a program name with args.
7949set dummy $ac_prog; ac_word=$2
7950{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7951$as_echo_n "checking for $ac_word... " >&6; }
7952if ${ac_cv_path_MKDIR+:} false; then :
7953  $as_echo_n "(cached) " >&6
7954else
7955  case $MKDIR in
7956  [\\/]* | ?:[\\/]*)
7957  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7958  ;;
7959  *)
7960  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7961for as_dir in $PATH
7962do
7963  IFS=$as_save_IFS
7964  test -z "$as_dir" && as_dir=.
7965    for ac_exec_ext in '' $ac_executable_extensions; do
7966  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7967    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7968    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7969    break 2
7970  fi
7971done
7972  done
7973IFS=$as_save_IFS
7974
7975  ;;
7976esac
7977fi
7978MKDIR=$ac_cv_path_MKDIR
7979if test -n "$MKDIR"; then
7980  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7981$as_echo "$MKDIR" >&6; }
7982else
7983  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7984$as_echo "no" >&6; }
7985fi
7986
7987
7988  test -n "$MKDIR" && break
7989done
7990
7991  else
7992    # The variable is set, but is it from the command line or the environment?
7993
7994    # Try to remove the string !MKDIR! from our list.
7995    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/}
7996    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7997      # If it failed, the variable was not from the command line. Ignore it,
7998      # but warn the user (except for BASH, which is always set by the calling BASH).
7999      if test "xMKDIR" != xBASH; then
8000        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5
8001$as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;}
8002      fi
8003      # Try to locate tool using the code snippet
8004      for ac_prog in mkdir
8005do
8006  # Extract the first word of "$ac_prog", so it can be a program name with args.
8007set dummy $ac_prog; ac_word=$2
8008{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8009$as_echo_n "checking for $ac_word... " >&6; }
8010if ${ac_cv_path_MKDIR+:} false; then :
8011  $as_echo_n "(cached) " >&6
8012else
8013  case $MKDIR in
8014  [\\/]* | ?:[\\/]*)
8015  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8016  ;;
8017  *)
8018  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8019for as_dir in $PATH
8020do
8021  IFS=$as_save_IFS
8022  test -z "$as_dir" && as_dir=.
8023    for ac_exec_ext in '' $ac_executable_extensions; do
8024  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8025    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8026    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8027    break 2
8028  fi
8029done
8030  done
8031IFS=$as_save_IFS
8032
8033  ;;
8034esac
8035fi
8036MKDIR=$ac_cv_path_MKDIR
8037if test -n "$MKDIR"; then
8038  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8039$as_echo "$MKDIR" >&6; }
8040else
8041  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8042$as_echo "no" >&6; }
8043fi
8044
8045
8046  test -n "$MKDIR" && break
8047done
8048
8049    else
8050      # If it succeeded, then it was overridden by the user. We will use it
8051      # for the tool.
8052
8053      # First remove it from the list of overridden variables, so we can test
8054      # for unknown variables in the end.
8055      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8056
8057      # Check if the provided tool contains a complete path.
8058      tool_specified="$MKDIR"
8059      tool_basename="${tool_specified##*/}"
8060      if test "x$tool_basename" = "x$tool_specified"; then
8061        # A command without a complete path is provided, search $PATH.
8062        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5
8063$as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;}
8064        # Extract the first word of "$tool_basename", so it can be a program name with args.
8065set dummy $tool_basename; ac_word=$2
8066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8067$as_echo_n "checking for $ac_word... " >&6; }
8068if ${ac_cv_path_MKDIR+:} false; then :
8069  $as_echo_n "(cached) " >&6
8070else
8071  case $MKDIR in
8072  [\\/]* | ?:[\\/]*)
8073  ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
8074  ;;
8075  *)
8076  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8077for as_dir in $PATH
8078do
8079  IFS=$as_save_IFS
8080  test -z "$as_dir" && as_dir=.
8081    for ac_exec_ext in '' $ac_executable_extensions; do
8082  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8083    ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8084    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8085    break 2
8086  fi
8087done
8088  done
8089IFS=$as_save_IFS
8090
8091  ;;
8092esac
8093fi
8094MKDIR=$ac_cv_path_MKDIR
8095if test -n "$MKDIR"; then
8096  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8097$as_echo "$MKDIR" >&6; }
8098else
8099  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8100$as_echo "no" >&6; }
8101fi
8102
8103
8104        if test "x$MKDIR" = x; then
8105          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8106        fi
8107      else
8108        # Otherwise we believe it is a complete path. Use it as it is.
8109        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5
8110$as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;}
8111        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5
8112$as_echo_n "checking for MKDIR... " >&6; }
8113        if test ! -x "$tool_specified"; then
8114          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8115$as_echo "not found" >&6; }
8116          as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5
8117        fi
8118        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8119$as_echo "$tool_specified" >&6; }
8120      fi
8121    fi
8122  fi
8123
8124
8125
8126  if test "x$MKDIR" = x; then
8127    as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5
8128  fi
8129
8130
8131
8132
8133
8134  # Publish this variable in the help.
8135
8136
8137  if test "x$MKTEMP" = x; then
8138    # The variable is not set by user, try to locate tool using the code snippet
8139    for ac_prog in mktemp
8140do
8141  # Extract the first word of "$ac_prog", so it can be a program name with args.
8142set dummy $ac_prog; ac_word=$2
8143{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8144$as_echo_n "checking for $ac_word... " >&6; }
8145if ${ac_cv_path_MKTEMP+:} false; then :
8146  $as_echo_n "(cached) " >&6
8147else
8148  case $MKTEMP in
8149  [\\/]* | ?:[\\/]*)
8150  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8151  ;;
8152  *)
8153  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8154for as_dir in $PATH
8155do
8156  IFS=$as_save_IFS
8157  test -z "$as_dir" && as_dir=.
8158    for ac_exec_ext in '' $ac_executable_extensions; do
8159  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8160    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8161    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8162    break 2
8163  fi
8164done
8165  done
8166IFS=$as_save_IFS
8167
8168  ;;
8169esac
8170fi
8171MKTEMP=$ac_cv_path_MKTEMP
8172if test -n "$MKTEMP"; then
8173  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8174$as_echo "$MKTEMP" >&6; }
8175else
8176  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8177$as_echo "no" >&6; }
8178fi
8179
8180
8181  test -n "$MKTEMP" && break
8182done
8183
8184  else
8185    # The variable is set, but is it from the command line or the environment?
8186
8187    # Try to remove the string !MKTEMP! from our list.
8188    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/}
8189    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8190      # If it failed, the variable was not from the command line. Ignore it,
8191      # but warn the user (except for BASH, which is always set by the calling BASH).
8192      if test "xMKTEMP" != xBASH; then
8193        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5
8194$as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;}
8195      fi
8196      # Try to locate tool using the code snippet
8197      for ac_prog in mktemp
8198do
8199  # Extract the first word of "$ac_prog", so it can be a program name with args.
8200set dummy $ac_prog; ac_word=$2
8201{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8202$as_echo_n "checking for $ac_word... " >&6; }
8203if ${ac_cv_path_MKTEMP+:} false; then :
8204  $as_echo_n "(cached) " >&6
8205else
8206  case $MKTEMP in
8207  [\\/]* | ?:[\\/]*)
8208  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8209  ;;
8210  *)
8211  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8212for as_dir in $PATH
8213do
8214  IFS=$as_save_IFS
8215  test -z "$as_dir" && as_dir=.
8216    for ac_exec_ext in '' $ac_executable_extensions; do
8217  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8218    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8219    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8220    break 2
8221  fi
8222done
8223  done
8224IFS=$as_save_IFS
8225
8226  ;;
8227esac
8228fi
8229MKTEMP=$ac_cv_path_MKTEMP
8230if test -n "$MKTEMP"; then
8231  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8232$as_echo "$MKTEMP" >&6; }
8233else
8234  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8235$as_echo "no" >&6; }
8236fi
8237
8238
8239  test -n "$MKTEMP" && break
8240done
8241
8242    else
8243      # If it succeeded, then it was overridden by the user. We will use it
8244      # for the tool.
8245
8246      # First remove it from the list of overridden variables, so we can test
8247      # for unknown variables in the end.
8248      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8249
8250      # Check if the provided tool contains a complete path.
8251      tool_specified="$MKTEMP"
8252      tool_basename="${tool_specified##*/}"
8253      if test "x$tool_basename" = "x$tool_specified"; then
8254        # A command without a complete path is provided, search $PATH.
8255        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5
8256$as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;}
8257        # Extract the first word of "$tool_basename", so it can be a program name with args.
8258set dummy $tool_basename; ac_word=$2
8259{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8260$as_echo_n "checking for $ac_word... " >&6; }
8261if ${ac_cv_path_MKTEMP+:} false; then :
8262  $as_echo_n "(cached) " >&6
8263else
8264  case $MKTEMP in
8265  [\\/]* | ?:[\\/]*)
8266  ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8267  ;;
8268  *)
8269  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8270for as_dir in $PATH
8271do
8272  IFS=$as_save_IFS
8273  test -z "$as_dir" && as_dir=.
8274    for ac_exec_ext in '' $ac_executable_extensions; do
8275  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8276    ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8277    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8278    break 2
8279  fi
8280done
8281  done
8282IFS=$as_save_IFS
8283
8284  ;;
8285esac
8286fi
8287MKTEMP=$ac_cv_path_MKTEMP
8288if test -n "$MKTEMP"; then
8289  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8290$as_echo "$MKTEMP" >&6; }
8291else
8292  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8293$as_echo "no" >&6; }
8294fi
8295
8296
8297        if test "x$MKTEMP" = x; then
8298          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8299        fi
8300      else
8301        # Otherwise we believe it is a complete path. Use it as it is.
8302        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5
8303$as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;}
8304        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5
8305$as_echo_n "checking for MKTEMP... " >&6; }
8306        if test ! -x "$tool_specified"; then
8307          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8308$as_echo "not found" >&6; }
8309          as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5
8310        fi
8311        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8312$as_echo "$tool_specified" >&6; }
8313      fi
8314    fi
8315  fi
8316
8317
8318
8319  if test "x$MKTEMP" = x; then
8320    as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5
8321  fi
8322
8323
8324
8325
8326
8327  # Publish this variable in the help.
8328
8329
8330  if test "x$MV" = x; then
8331    # The variable is not set by user, try to locate tool using the code snippet
8332    for ac_prog in mv
8333do
8334  # Extract the first word of "$ac_prog", so it can be a program name with args.
8335set dummy $ac_prog; ac_word=$2
8336{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8337$as_echo_n "checking for $ac_word... " >&6; }
8338if ${ac_cv_path_MV+:} false; then :
8339  $as_echo_n "(cached) " >&6
8340else
8341  case $MV in
8342  [\\/]* | ?:[\\/]*)
8343  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8344  ;;
8345  *)
8346  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8347for as_dir in $PATH
8348do
8349  IFS=$as_save_IFS
8350  test -z "$as_dir" && as_dir=.
8351    for ac_exec_ext in '' $ac_executable_extensions; do
8352  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8353    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8354    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8355    break 2
8356  fi
8357done
8358  done
8359IFS=$as_save_IFS
8360
8361  ;;
8362esac
8363fi
8364MV=$ac_cv_path_MV
8365if test -n "$MV"; then
8366  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8367$as_echo "$MV" >&6; }
8368else
8369  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8370$as_echo "no" >&6; }
8371fi
8372
8373
8374  test -n "$MV" && break
8375done
8376
8377  else
8378    # The variable is set, but is it from the command line or the environment?
8379
8380    # Try to remove the string !MV! from our list.
8381    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/}
8382    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8383      # If it failed, the variable was not from the command line. Ignore it,
8384      # but warn the user (except for BASH, which is always set by the calling BASH).
8385      if test "xMV" != xBASH; then
8386        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5
8387$as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;}
8388      fi
8389      # Try to locate tool using the code snippet
8390      for ac_prog in mv
8391do
8392  # Extract the first word of "$ac_prog", so it can be a program name with args.
8393set dummy $ac_prog; ac_word=$2
8394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8395$as_echo_n "checking for $ac_word... " >&6; }
8396if ${ac_cv_path_MV+:} false; then :
8397  $as_echo_n "(cached) " >&6
8398else
8399  case $MV in
8400  [\\/]* | ?:[\\/]*)
8401  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8402  ;;
8403  *)
8404  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8405for as_dir in $PATH
8406do
8407  IFS=$as_save_IFS
8408  test -z "$as_dir" && as_dir=.
8409    for ac_exec_ext in '' $ac_executable_extensions; do
8410  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8411    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8412    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8413    break 2
8414  fi
8415done
8416  done
8417IFS=$as_save_IFS
8418
8419  ;;
8420esac
8421fi
8422MV=$ac_cv_path_MV
8423if test -n "$MV"; then
8424  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8425$as_echo "$MV" >&6; }
8426else
8427  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8428$as_echo "no" >&6; }
8429fi
8430
8431
8432  test -n "$MV" && break
8433done
8434
8435    else
8436      # If it succeeded, then it was overridden by the user. We will use it
8437      # for the tool.
8438
8439      # First remove it from the list of overridden variables, so we can test
8440      # for unknown variables in the end.
8441      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8442
8443      # Check if the provided tool contains a complete path.
8444      tool_specified="$MV"
8445      tool_basename="${tool_specified##*/}"
8446      if test "x$tool_basename" = "x$tool_specified"; then
8447        # A command without a complete path is provided, search $PATH.
8448        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5
8449$as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;}
8450        # Extract the first word of "$tool_basename", so it can be a program name with args.
8451set dummy $tool_basename; ac_word=$2
8452{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8453$as_echo_n "checking for $ac_word... " >&6; }
8454if ${ac_cv_path_MV+:} false; then :
8455  $as_echo_n "(cached) " >&6
8456else
8457  case $MV in
8458  [\\/]* | ?:[\\/]*)
8459  ac_cv_path_MV="$MV" # Let the user override the test with a path.
8460  ;;
8461  *)
8462  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8463for as_dir in $PATH
8464do
8465  IFS=$as_save_IFS
8466  test -z "$as_dir" && as_dir=.
8467    for ac_exec_ext in '' $ac_executable_extensions; do
8468  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8469    ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8470    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8471    break 2
8472  fi
8473done
8474  done
8475IFS=$as_save_IFS
8476
8477  ;;
8478esac
8479fi
8480MV=$ac_cv_path_MV
8481if test -n "$MV"; then
8482  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8483$as_echo "$MV" >&6; }
8484else
8485  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8486$as_echo "no" >&6; }
8487fi
8488
8489
8490        if test "x$MV" = x; then
8491          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8492        fi
8493      else
8494        # Otherwise we believe it is a complete path. Use it as it is.
8495        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5
8496$as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;}
8497        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5
8498$as_echo_n "checking for MV... " >&6; }
8499        if test ! -x "$tool_specified"; then
8500          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8501$as_echo "not found" >&6; }
8502          as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5
8503        fi
8504        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8505$as_echo "$tool_specified" >&6; }
8506      fi
8507    fi
8508  fi
8509
8510
8511
8512  if test "x$MV" = x; then
8513    as_fn_error $? "Could not find required tool for MV" "$LINENO" 5
8514  fi
8515
8516
8517
8518
8519
8520  # Publish this variable in the help.
8521
8522
8523  if test "x$NAWK" = x; then
8524    # The variable is not set by user, try to locate tool using the code snippet
8525    for ac_prog in nawk gawk awk
8526do
8527  # Extract the first word of "$ac_prog", so it can be a program name with args.
8528set dummy $ac_prog; ac_word=$2
8529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8530$as_echo_n "checking for $ac_word... " >&6; }
8531if ${ac_cv_path_NAWK+:} false; then :
8532  $as_echo_n "(cached) " >&6
8533else
8534  case $NAWK in
8535  [\\/]* | ?:[\\/]*)
8536  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8537  ;;
8538  *)
8539  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8540for as_dir in $PATH
8541do
8542  IFS=$as_save_IFS
8543  test -z "$as_dir" && as_dir=.
8544    for ac_exec_ext in '' $ac_executable_extensions; do
8545  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8546    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8547    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8548    break 2
8549  fi
8550done
8551  done
8552IFS=$as_save_IFS
8553
8554  ;;
8555esac
8556fi
8557NAWK=$ac_cv_path_NAWK
8558if test -n "$NAWK"; then
8559  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8560$as_echo "$NAWK" >&6; }
8561else
8562  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8563$as_echo "no" >&6; }
8564fi
8565
8566
8567  test -n "$NAWK" && break
8568done
8569
8570  else
8571    # The variable is set, but is it from the command line or the environment?
8572
8573    # Try to remove the string !NAWK! from our list.
8574    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/}
8575    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8576      # If it failed, the variable was not from the command line. Ignore it,
8577      # but warn the user (except for BASH, which is always set by the calling BASH).
8578      if test "xNAWK" != xBASH; then
8579        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5
8580$as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;}
8581      fi
8582      # Try to locate tool using the code snippet
8583      for ac_prog in nawk gawk awk
8584do
8585  # Extract the first word of "$ac_prog", so it can be a program name with args.
8586set dummy $ac_prog; ac_word=$2
8587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8588$as_echo_n "checking for $ac_word... " >&6; }
8589if ${ac_cv_path_NAWK+:} false; then :
8590  $as_echo_n "(cached) " >&6
8591else
8592  case $NAWK in
8593  [\\/]* | ?:[\\/]*)
8594  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8595  ;;
8596  *)
8597  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8598for as_dir in $PATH
8599do
8600  IFS=$as_save_IFS
8601  test -z "$as_dir" && as_dir=.
8602    for ac_exec_ext in '' $ac_executable_extensions; do
8603  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8604    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8605    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8606    break 2
8607  fi
8608done
8609  done
8610IFS=$as_save_IFS
8611
8612  ;;
8613esac
8614fi
8615NAWK=$ac_cv_path_NAWK
8616if test -n "$NAWK"; then
8617  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8618$as_echo "$NAWK" >&6; }
8619else
8620  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8621$as_echo "no" >&6; }
8622fi
8623
8624
8625  test -n "$NAWK" && break
8626done
8627
8628    else
8629      # If it succeeded, then it was overridden by the user. We will use it
8630      # for the tool.
8631
8632      # First remove it from the list of overridden variables, so we can test
8633      # for unknown variables in the end.
8634      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8635
8636      # Check if the provided tool contains a complete path.
8637      tool_specified="$NAWK"
8638      tool_basename="${tool_specified##*/}"
8639      if test "x$tool_basename" = "x$tool_specified"; then
8640        # A command without a complete path is provided, search $PATH.
8641        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5
8642$as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;}
8643        # Extract the first word of "$tool_basename", so it can be a program name with args.
8644set dummy $tool_basename; ac_word=$2
8645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8646$as_echo_n "checking for $ac_word... " >&6; }
8647if ${ac_cv_path_NAWK+:} false; then :
8648  $as_echo_n "(cached) " >&6
8649else
8650  case $NAWK in
8651  [\\/]* | ?:[\\/]*)
8652  ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8653  ;;
8654  *)
8655  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8656for as_dir in $PATH
8657do
8658  IFS=$as_save_IFS
8659  test -z "$as_dir" && as_dir=.
8660    for ac_exec_ext in '' $ac_executable_extensions; do
8661  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8662    ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8663    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8664    break 2
8665  fi
8666done
8667  done
8668IFS=$as_save_IFS
8669
8670  ;;
8671esac
8672fi
8673NAWK=$ac_cv_path_NAWK
8674if test -n "$NAWK"; then
8675  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8676$as_echo "$NAWK" >&6; }
8677else
8678  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8679$as_echo "no" >&6; }
8680fi
8681
8682
8683        if test "x$NAWK" = x; then
8684          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8685        fi
8686      else
8687        # Otherwise we believe it is a complete path. Use it as it is.
8688        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5
8689$as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;}
8690        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5
8691$as_echo_n "checking for NAWK... " >&6; }
8692        if test ! -x "$tool_specified"; then
8693          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8694$as_echo "not found" >&6; }
8695          as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5
8696        fi
8697        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8698$as_echo "$tool_specified" >&6; }
8699      fi
8700    fi
8701  fi
8702
8703
8704
8705  if test "x$NAWK" = x; then
8706    as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5
8707  fi
8708
8709
8710
8711
8712
8713  # Publish this variable in the help.
8714
8715
8716  if test "x$PRINTF" = x; then
8717    # The variable is not set by user, try to locate tool using the code snippet
8718    for ac_prog in printf
8719do
8720  # Extract the first word of "$ac_prog", so it can be a program name with args.
8721set dummy $ac_prog; ac_word=$2
8722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8723$as_echo_n "checking for $ac_word... " >&6; }
8724if ${ac_cv_path_PRINTF+:} false; then :
8725  $as_echo_n "(cached) " >&6
8726else
8727  case $PRINTF in
8728  [\\/]* | ?:[\\/]*)
8729  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8730  ;;
8731  *)
8732  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8733for as_dir in $PATH
8734do
8735  IFS=$as_save_IFS
8736  test -z "$as_dir" && as_dir=.
8737    for ac_exec_ext in '' $ac_executable_extensions; do
8738  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8739    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8740    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8741    break 2
8742  fi
8743done
8744  done
8745IFS=$as_save_IFS
8746
8747  ;;
8748esac
8749fi
8750PRINTF=$ac_cv_path_PRINTF
8751if test -n "$PRINTF"; then
8752  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8753$as_echo "$PRINTF" >&6; }
8754else
8755  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8756$as_echo "no" >&6; }
8757fi
8758
8759
8760  test -n "$PRINTF" && break
8761done
8762
8763  else
8764    # The variable is set, but is it from the command line or the environment?
8765
8766    # Try to remove the string !PRINTF! from our list.
8767    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/}
8768    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8769      # If it failed, the variable was not from the command line. Ignore it,
8770      # but warn the user (except for BASH, which is always set by the calling BASH).
8771      if test "xPRINTF" != xBASH; then
8772        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5
8773$as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;}
8774      fi
8775      # Try to locate tool using the code snippet
8776      for ac_prog in printf
8777do
8778  # Extract the first word of "$ac_prog", so it can be a program name with args.
8779set dummy $ac_prog; ac_word=$2
8780{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8781$as_echo_n "checking for $ac_word... " >&6; }
8782if ${ac_cv_path_PRINTF+:} false; then :
8783  $as_echo_n "(cached) " >&6
8784else
8785  case $PRINTF in
8786  [\\/]* | ?:[\\/]*)
8787  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8788  ;;
8789  *)
8790  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8791for as_dir in $PATH
8792do
8793  IFS=$as_save_IFS
8794  test -z "$as_dir" && as_dir=.
8795    for ac_exec_ext in '' $ac_executable_extensions; do
8796  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8797    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8798    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8799    break 2
8800  fi
8801done
8802  done
8803IFS=$as_save_IFS
8804
8805  ;;
8806esac
8807fi
8808PRINTF=$ac_cv_path_PRINTF
8809if test -n "$PRINTF"; then
8810  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8811$as_echo "$PRINTF" >&6; }
8812else
8813  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8814$as_echo "no" >&6; }
8815fi
8816
8817
8818  test -n "$PRINTF" && break
8819done
8820
8821    else
8822      # If it succeeded, then it was overridden by the user. We will use it
8823      # for the tool.
8824
8825      # First remove it from the list of overridden variables, so we can test
8826      # for unknown variables in the end.
8827      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8828
8829      # Check if the provided tool contains a complete path.
8830      tool_specified="$PRINTF"
8831      tool_basename="${tool_specified##*/}"
8832      if test "x$tool_basename" = "x$tool_specified"; then
8833        # A command without a complete path is provided, search $PATH.
8834        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5
8835$as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;}
8836        # Extract the first word of "$tool_basename", so it can be a program name with args.
8837set dummy $tool_basename; ac_word=$2
8838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8839$as_echo_n "checking for $ac_word... " >&6; }
8840if ${ac_cv_path_PRINTF+:} false; then :
8841  $as_echo_n "(cached) " >&6
8842else
8843  case $PRINTF in
8844  [\\/]* | ?:[\\/]*)
8845  ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8846  ;;
8847  *)
8848  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8849for as_dir in $PATH
8850do
8851  IFS=$as_save_IFS
8852  test -z "$as_dir" && as_dir=.
8853    for ac_exec_ext in '' $ac_executable_extensions; do
8854  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8855    ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8856    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8857    break 2
8858  fi
8859done
8860  done
8861IFS=$as_save_IFS
8862
8863  ;;
8864esac
8865fi
8866PRINTF=$ac_cv_path_PRINTF
8867if test -n "$PRINTF"; then
8868  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8869$as_echo "$PRINTF" >&6; }
8870else
8871  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8872$as_echo "no" >&6; }
8873fi
8874
8875
8876        if test "x$PRINTF" = x; then
8877          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8878        fi
8879      else
8880        # Otherwise we believe it is a complete path. Use it as it is.
8881        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5
8882$as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;}
8883        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5
8884$as_echo_n "checking for PRINTF... " >&6; }
8885        if test ! -x "$tool_specified"; then
8886          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8887$as_echo "not found" >&6; }
8888          as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5
8889        fi
8890        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8891$as_echo "$tool_specified" >&6; }
8892      fi
8893    fi
8894  fi
8895
8896
8897
8898  if test "x$PRINTF" = x; then
8899    as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5
8900  fi
8901
8902
8903
8904
8905
8906  # Publish this variable in the help.
8907
8908
8909  if test "x$RM" = x; then
8910    # The variable is not set by user, try to locate tool using the code snippet
8911    for ac_prog in rm
8912do
8913  # Extract the first word of "$ac_prog", so it can be a program name with args.
8914set dummy $ac_prog; ac_word=$2
8915{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8916$as_echo_n "checking for $ac_word... " >&6; }
8917if ${ac_cv_path_RM+:} false; then :
8918  $as_echo_n "(cached) " >&6
8919else
8920  case $RM in
8921  [\\/]* | ?:[\\/]*)
8922  ac_cv_path_RM="$RM" # Let the user override the test with a path.
8923  ;;
8924  *)
8925  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8926for as_dir in $PATH
8927do
8928  IFS=$as_save_IFS
8929  test -z "$as_dir" && as_dir=.
8930    for ac_exec_ext in '' $ac_executable_extensions; do
8931  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8932    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8933    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8934    break 2
8935  fi
8936done
8937  done
8938IFS=$as_save_IFS
8939
8940  ;;
8941esac
8942fi
8943RM=$ac_cv_path_RM
8944if test -n "$RM"; then
8945  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8946$as_echo "$RM" >&6; }
8947else
8948  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8949$as_echo "no" >&6; }
8950fi
8951
8952
8953  test -n "$RM" && break
8954done
8955
8956  else
8957    # The variable is set, but is it from the command line or the environment?
8958
8959    # Try to remove the string !RM! from our list.
8960    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/}
8961    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8962      # If it failed, the variable was not from the command line. Ignore it,
8963      # but warn the user (except for BASH, which is always set by the calling BASH).
8964      if test "xRM" != xBASH; then
8965        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5
8966$as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;}
8967      fi
8968      # Try to locate tool using the code snippet
8969      for ac_prog in rm
8970do
8971  # Extract the first word of "$ac_prog", so it can be a program name with args.
8972set dummy $ac_prog; ac_word=$2
8973{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8974$as_echo_n "checking for $ac_word... " >&6; }
8975if ${ac_cv_path_RM+:} false; then :
8976  $as_echo_n "(cached) " >&6
8977else
8978  case $RM in
8979  [\\/]* | ?:[\\/]*)
8980  ac_cv_path_RM="$RM" # Let the user override the test with a path.
8981  ;;
8982  *)
8983  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8984for as_dir in $PATH
8985do
8986  IFS=$as_save_IFS
8987  test -z "$as_dir" && as_dir=.
8988    for ac_exec_ext in '' $ac_executable_extensions; do
8989  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8990    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8991    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8992    break 2
8993  fi
8994done
8995  done
8996IFS=$as_save_IFS
8997
8998  ;;
8999esac
9000fi
9001RM=$ac_cv_path_RM
9002if test -n "$RM"; then
9003  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9004$as_echo "$RM" >&6; }
9005else
9006  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9007$as_echo "no" >&6; }
9008fi
9009
9010
9011  test -n "$RM" && break
9012done
9013
9014    else
9015      # If it succeeded, then it was overridden by the user. We will use it
9016      # for the tool.
9017
9018      # First remove it from the list of overridden variables, so we can test
9019      # for unknown variables in the end.
9020      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9021
9022      # Check if the provided tool contains a complete path.
9023      tool_specified="$RM"
9024      tool_basename="${tool_specified##*/}"
9025      if test "x$tool_basename" = "x$tool_specified"; then
9026        # A command without a complete path is provided, search $PATH.
9027        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5
9028$as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;}
9029        # Extract the first word of "$tool_basename", so it can be a program name with args.
9030set dummy $tool_basename; ac_word=$2
9031{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9032$as_echo_n "checking for $ac_word... " >&6; }
9033if ${ac_cv_path_RM+:} false; then :
9034  $as_echo_n "(cached) " >&6
9035else
9036  case $RM in
9037  [\\/]* | ?:[\\/]*)
9038  ac_cv_path_RM="$RM" # Let the user override the test with a path.
9039  ;;
9040  *)
9041  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9042for as_dir in $PATH
9043do
9044  IFS=$as_save_IFS
9045  test -z "$as_dir" && as_dir=.
9046    for ac_exec_ext in '' $ac_executable_extensions; do
9047  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9048    ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
9049    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9050    break 2
9051  fi
9052done
9053  done
9054IFS=$as_save_IFS
9055
9056  ;;
9057esac
9058fi
9059RM=$ac_cv_path_RM
9060if test -n "$RM"; then
9061  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
9062$as_echo "$RM" >&6; }
9063else
9064  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9065$as_echo "no" >&6; }
9066fi
9067
9068
9069        if test "x$RM" = x; then
9070          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9071        fi
9072      else
9073        # Otherwise we believe it is a complete path. Use it as it is.
9074        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5
9075$as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;}
9076        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5
9077$as_echo_n "checking for RM... " >&6; }
9078        if test ! -x "$tool_specified"; then
9079          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9080$as_echo "not found" >&6; }
9081          as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5
9082        fi
9083        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9084$as_echo "$tool_specified" >&6; }
9085      fi
9086    fi
9087  fi
9088
9089
9090
9091  if test "x$RM" = x; then
9092    as_fn_error $? "Could not find required tool for RM" "$LINENO" 5
9093  fi
9094
9095
9096
9097
9098
9099  # Publish this variable in the help.
9100
9101
9102  if test "x$SH" = x; then
9103    # The variable is not set by user, try to locate tool using the code snippet
9104    for ac_prog in sh
9105do
9106  # Extract the first word of "$ac_prog", so it can be a program name with args.
9107set dummy $ac_prog; ac_word=$2
9108{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9109$as_echo_n "checking for $ac_word... " >&6; }
9110if ${ac_cv_path_SH+:} false; then :
9111  $as_echo_n "(cached) " >&6
9112else
9113  case $SH in
9114  [\\/]* | ?:[\\/]*)
9115  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9116  ;;
9117  *)
9118  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9119for as_dir in $PATH
9120do
9121  IFS=$as_save_IFS
9122  test -z "$as_dir" && as_dir=.
9123    for ac_exec_ext in '' $ac_executable_extensions; do
9124  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9125    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9126    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9127    break 2
9128  fi
9129done
9130  done
9131IFS=$as_save_IFS
9132
9133  ;;
9134esac
9135fi
9136SH=$ac_cv_path_SH
9137if test -n "$SH"; then
9138  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9139$as_echo "$SH" >&6; }
9140else
9141  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9142$as_echo "no" >&6; }
9143fi
9144
9145
9146  test -n "$SH" && break
9147done
9148
9149  else
9150    # The variable is set, but is it from the command line or the environment?
9151
9152    # Try to remove the string !SH! from our list.
9153    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/}
9154    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9155      # If it failed, the variable was not from the command line. Ignore it,
9156      # but warn the user (except for BASH, which is always set by the calling BASH).
9157      if test "xSH" != xBASH; then
9158        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5
9159$as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;}
9160      fi
9161      # Try to locate tool using the code snippet
9162      for ac_prog in sh
9163do
9164  # Extract the first word of "$ac_prog", so it can be a program name with args.
9165set dummy $ac_prog; ac_word=$2
9166{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9167$as_echo_n "checking for $ac_word... " >&6; }
9168if ${ac_cv_path_SH+:} false; then :
9169  $as_echo_n "(cached) " >&6
9170else
9171  case $SH in
9172  [\\/]* | ?:[\\/]*)
9173  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9174  ;;
9175  *)
9176  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9177for as_dir in $PATH
9178do
9179  IFS=$as_save_IFS
9180  test -z "$as_dir" && as_dir=.
9181    for ac_exec_ext in '' $ac_executable_extensions; do
9182  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9183    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9184    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9185    break 2
9186  fi
9187done
9188  done
9189IFS=$as_save_IFS
9190
9191  ;;
9192esac
9193fi
9194SH=$ac_cv_path_SH
9195if test -n "$SH"; then
9196  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9197$as_echo "$SH" >&6; }
9198else
9199  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9200$as_echo "no" >&6; }
9201fi
9202
9203
9204  test -n "$SH" && break
9205done
9206
9207    else
9208      # If it succeeded, then it was overridden by the user. We will use it
9209      # for the tool.
9210
9211      # First remove it from the list of overridden variables, so we can test
9212      # for unknown variables in the end.
9213      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9214
9215      # Check if the provided tool contains a complete path.
9216      tool_specified="$SH"
9217      tool_basename="${tool_specified##*/}"
9218      if test "x$tool_basename" = "x$tool_specified"; then
9219        # A command without a complete path is provided, search $PATH.
9220        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5
9221$as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;}
9222        # Extract the first word of "$tool_basename", so it can be a program name with args.
9223set dummy $tool_basename; ac_word=$2
9224{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9225$as_echo_n "checking for $ac_word... " >&6; }
9226if ${ac_cv_path_SH+:} false; then :
9227  $as_echo_n "(cached) " >&6
9228else
9229  case $SH in
9230  [\\/]* | ?:[\\/]*)
9231  ac_cv_path_SH="$SH" # Let the user override the test with a path.
9232  ;;
9233  *)
9234  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9235for as_dir in $PATH
9236do
9237  IFS=$as_save_IFS
9238  test -z "$as_dir" && as_dir=.
9239    for ac_exec_ext in '' $ac_executable_extensions; do
9240  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9241    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9242    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9243    break 2
9244  fi
9245done
9246  done
9247IFS=$as_save_IFS
9248
9249  ;;
9250esac
9251fi
9252SH=$ac_cv_path_SH
9253if test -n "$SH"; then
9254  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9255$as_echo "$SH" >&6; }
9256else
9257  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9258$as_echo "no" >&6; }
9259fi
9260
9261
9262        if test "x$SH" = x; then
9263          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9264        fi
9265      else
9266        # Otherwise we believe it is a complete path. Use it as it is.
9267        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5
9268$as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;}
9269        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5
9270$as_echo_n "checking for SH... " >&6; }
9271        if test ! -x "$tool_specified"; then
9272          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9273$as_echo "not found" >&6; }
9274          as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5
9275        fi
9276        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9277$as_echo "$tool_specified" >&6; }
9278      fi
9279    fi
9280  fi
9281
9282
9283
9284  if test "x$SH" = x; then
9285    as_fn_error $? "Could not find required tool for SH" "$LINENO" 5
9286  fi
9287
9288
9289
9290
9291
9292  # Publish this variable in the help.
9293
9294
9295  if test "x$SORT" = x; then
9296    # The variable is not set by user, try to locate tool using the code snippet
9297    for ac_prog in sort
9298do
9299  # Extract the first word of "$ac_prog", so it can be a program name with args.
9300set dummy $ac_prog; ac_word=$2
9301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9302$as_echo_n "checking for $ac_word... " >&6; }
9303if ${ac_cv_path_SORT+:} false; then :
9304  $as_echo_n "(cached) " >&6
9305else
9306  case $SORT in
9307  [\\/]* | ?:[\\/]*)
9308  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9309  ;;
9310  *)
9311  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9312for as_dir in $PATH
9313do
9314  IFS=$as_save_IFS
9315  test -z "$as_dir" && as_dir=.
9316    for ac_exec_ext in '' $ac_executable_extensions; do
9317  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9318    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9319    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9320    break 2
9321  fi
9322done
9323  done
9324IFS=$as_save_IFS
9325
9326  ;;
9327esac
9328fi
9329SORT=$ac_cv_path_SORT
9330if test -n "$SORT"; then
9331  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9332$as_echo "$SORT" >&6; }
9333else
9334  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9335$as_echo "no" >&6; }
9336fi
9337
9338
9339  test -n "$SORT" && break
9340done
9341
9342  else
9343    # The variable is set, but is it from the command line or the environment?
9344
9345    # Try to remove the string !SORT! from our list.
9346    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/}
9347    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9348      # If it failed, the variable was not from the command line. Ignore it,
9349      # but warn the user (except for BASH, which is always set by the calling BASH).
9350      if test "xSORT" != xBASH; then
9351        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5
9352$as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;}
9353      fi
9354      # Try to locate tool using the code snippet
9355      for ac_prog in sort
9356do
9357  # Extract the first word of "$ac_prog", so it can be a program name with args.
9358set dummy $ac_prog; ac_word=$2
9359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9360$as_echo_n "checking for $ac_word... " >&6; }
9361if ${ac_cv_path_SORT+:} false; then :
9362  $as_echo_n "(cached) " >&6
9363else
9364  case $SORT in
9365  [\\/]* | ?:[\\/]*)
9366  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9367  ;;
9368  *)
9369  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9370for as_dir in $PATH
9371do
9372  IFS=$as_save_IFS
9373  test -z "$as_dir" && as_dir=.
9374    for ac_exec_ext in '' $ac_executable_extensions; do
9375  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9376    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9377    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9378    break 2
9379  fi
9380done
9381  done
9382IFS=$as_save_IFS
9383
9384  ;;
9385esac
9386fi
9387SORT=$ac_cv_path_SORT
9388if test -n "$SORT"; then
9389  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9390$as_echo "$SORT" >&6; }
9391else
9392  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9393$as_echo "no" >&6; }
9394fi
9395
9396
9397  test -n "$SORT" && break
9398done
9399
9400    else
9401      # If it succeeded, then it was overridden by the user. We will use it
9402      # for the tool.
9403
9404      # First remove it from the list of overridden variables, so we can test
9405      # for unknown variables in the end.
9406      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9407
9408      # Check if the provided tool contains a complete path.
9409      tool_specified="$SORT"
9410      tool_basename="${tool_specified##*/}"
9411      if test "x$tool_basename" = "x$tool_specified"; then
9412        # A command without a complete path is provided, search $PATH.
9413        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5
9414$as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;}
9415        # Extract the first word of "$tool_basename", so it can be a program name with args.
9416set dummy $tool_basename; ac_word=$2
9417{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9418$as_echo_n "checking for $ac_word... " >&6; }
9419if ${ac_cv_path_SORT+:} false; then :
9420  $as_echo_n "(cached) " >&6
9421else
9422  case $SORT in
9423  [\\/]* | ?:[\\/]*)
9424  ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9425  ;;
9426  *)
9427  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9428for as_dir in $PATH
9429do
9430  IFS=$as_save_IFS
9431  test -z "$as_dir" && as_dir=.
9432    for ac_exec_ext in '' $ac_executable_extensions; do
9433  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9434    ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9435    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9436    break 2
9437  fi
9438done
9439  done
9440IFS=$as_save_IFS
9441
9442  ;;
9443esac
9444fi
9445SORT=$ac_cv_path_SORT
9446if test -n "$SORT"; then
9447  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9448$as_echo "$SORT" >&6; }
9449else
9450  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9451$as_echo "no" >&6; }
9452fi
9453
9454
9455        if test "x$SORT" = x; then
9456          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9457        fi
9458      else
9459        # Otherwise we believe it is a complete path. Use it as it is.
9460        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5
9461$as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;}
9462        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5
9463$as_echo_n "checking for SORT... " >&6; }
9464        if test ! -x "$tool_specified"; then
9465          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9466$as_echo "not found" >&6; }
9467          as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5
9468        fi
9469        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9470$as_echo "$tool_specified" >&6; }
9471      fi
9472    fi
9473  fi
9474
9475
9476
9477  if test "x$SORT" = x; then
9478    as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5
9479  fi
9480
9481
9482
9483
9484
9485  # Publish this variable in the help.
9486
9487
9488  if test "x$TAIL" = x; then
9489    # The variable is not set by user, try to locate tool using the code snippet
9490    for ac_prog in tail
9491do
9492  # Extract the first word of "$ac_prog", so it can be a program name with args.
9493set dummy $ac_prog; ac_word=$2
9494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9495$as_echo_n "checking for $ac_word... " >&6; }
9496if ${ac_cv_path_TAIL+:} false; then :
9497  $as_echo_n "(cached) " >&6
9498else
9499  case $TAIL in
9500  [\\/]* | ?:[\\/]*)
9501  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9502  ;;
9503  *)
9504  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9505for as_dir in $PATH
9506do
9507  IFS=$as_save_IFS
9508  test -z "$as_dir" && as_dir=.
9509    for ac_exec_ext in '' $ac_executable_extensions; do
9510  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9511    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9512    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9513    break 2
9514  fi
9515done
9516  done
9517IFS=$as_save_IFS
9518
9519  ;;
9520esac
9521fi
9522TAIL=$ac_cv_path_TAIL
9523if test -n "$TAIL"; then
9524  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9525$as_echo "$TAIL" >&6; }
9526else
9527  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9528$as_echo "no" >&6; }
9529fi
9530
9531
9532  test -n "$TAIL" && break
9533done
9534
9535  else
9536    # The variable is set, but is it from the command line or the environment?
9537
9538    # Try to remove the string !TAIL! from our list.
9539    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/}
9540    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9541      # If it failed, the variable was not from the command line. Ignore it,
9542      # but warn the user (except for BASH, which is always set by the calling BASH).
9543      if test "xTAIL" != xBASH; then
9544        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5
9545$as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;}
9546      fi
9547      # Try to locate tool using the code snippet
9548      for ac_prog in tail
9549do
9550  # Extract the first word of "$ac_prog", so it can be a program name with args.
9551set dummy $ac_prog; ac_word=$2
9552{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9553$as_echo_n "checking for $ac_word... " >&6; }
9554if ${ac_cv_path_TAIL+:} false; then :
9555  $as_echo_n "(cached) " >&6
9556else
9557  case $TAIL in
9558  [\\/]* | ?:[\\/]*)
9559  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9560  ;;
9561  *)
9562  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9563for as_dir in $PATH
9564do
9565  IFS=$as_save_IFS
9566  test -z "$as_dir" && as_dir=.
9567    for ac_exec_ext in '' $ac_executable_extensions; do
9568  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9569    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9570    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9571    break 2
9572  fi
9573done
9574  done
9575IFS=$as_save_IFS
9576
9577  ;;
9578esac
9579fi
9580TAIL=$ac_cv_path_TAIL
9581if test -n "$TAIL"; then
9582  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9583$as_echo "$TAIL" >&6; }
9584else
9585  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9586$as_echo "no" >&6; }
9587fi
9588
9589
9590  test -n "$TAIL" && break
9591done
9592
9593    else
9594      # If it succeeded, then it was overridden by the user. We will use it
9595      # for the tool.
9596
9597      # First remove it from the list of overridden variables, so we can test
9598      # for unknown variables in the end.
9599      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9600
9601      # Check if the provided tool contains a complete path.
9602      tool_specified="$TAIL"
9603      tool_basename="${tool_specified##*/}"
9604      if test "x$tool_basename" = "x$tool_specified"; then
9605        # A command without a complete path is provided, search $PATH.
9606        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5
9607$as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;}
9608        # Extract the first word of "$tool_basename", so it can be a program name with args.
9609set dummy $tool_basename; ac_word=$2
9610{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9611$as_echo_n "checking for $ac_word... " >&6; }
9612if ${ac_cv_path_TAIL+:} false; then :
9613  $as_echo_n "(cached) " >&6
9614else
9615  case $TAIL in
9616  [\\/]* | ?:[\\/]*)
9617  ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9618  ;;
9619  *)
9620  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9621for as_dir in $PATH
9622do
9623  IFS=$as_save_IFS
9624  test -z "$as_dir" && as_dir=.
9625    for ac_exec_ext in '' $ac_executable_extensions; do
9626  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9627    ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9628    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9629    break 2
9630  fi
9631done
9632  done
9633IFS=$as_save_IFS
9634
9635  ;;
9636esac
9637fi
9638TAIL=$ac_cv_path_TAIL
9639if test -n "$TAIL"; then
9640  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9641$as_echo "$TAIL" >&6; }
9642else
9643  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9644$as_echo "no" >&6; }
9645fi
9646
9647
9648        if test "x$TAIL" = x; then
9649          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9650        fi
9651      else
9652        # Otherwise we believe it is a complete path. Use it as it is.
9653        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5
9654$as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;}
9655        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5
9656$as_echo_n "checking for TAIL... " >&6; }
9657        if test ! -x "$tool_specified"; then
9658          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9659$as_echo "not found" >&6; }
9660          as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5
9661        fi
9662        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9663$as_echo "$tool_specified" >&6; }
9664      fi
9665    fi
9666  fi
9667
9668
9669
9670  if test "x$TAIL" = x; then
9671    as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5
9672  fi
9673
9674
9675
9676
9677
9678  # Publish this variable in the help.
9679
9680
9681  if test "x$TAR" = x; then
9682    # The variable is not set by user, try to locate tool using the code snippet
9683    for ac_prog in tar
9684do
9685  # Extract the first word of "$ac_prog", so it can be a program name with args.
9686set dummy $ac_prog; ac_word=$2
9687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9688$as_echo_n "checking for $ac_word... " >&6; }
9689if ${ac_cv_path_TAR+:} false; then :
9690  $as_echo_n "(cached) " >&6
9691else
9692  case $TAR in
9693  [\\/]* | ?:[\\/]*)
9694  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9695  ;;
9696  *)
9697  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9698for as_dir in $PATH
9699do
9700  IFS=$as_save_IFS
9701  test -z "$as_dir" && as_dir=.
9702    for ac_exec_ext in '' $ac_executable_extensions; do
9703  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9704    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9705    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9706    break 2
9707  fi
9708done
9709  done
9710IFS=$as_save_IFS
9711
9712  ;;
9713esac
9714fi
9715TAR=$ac_cv_path_TAR
9716if test -n "$TAR"; then
9717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9718$as_echo "$TAR" >&6; }
9719else
9720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9721$as_echo "no" >&6; }
9722fi
9723
9724
9725  test -n "$TAR" && break
9726done
9727
9728  else
9729    # The variable is set, but is it from the command line or the environment?
9730
9731    # Try to remove the string !TAR! from our list.
9732    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/}
9733    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9734      # If it failed, the variable was not from the command line. Ignore it,
9735      # but warn the user (except for BASH, which is always set by the calling BASH).
9736      if test "xTAR" != xBASH; then
9737        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5
9738$as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;}
9739      fi
9740      # Try to locate tool using the code snippet
9741      for ac_prog in tar
9742do
9743  # Extract the first word of "$ac_prog", so it can be a program name with args.
9744set dummy $ac_prog; ac_word=$2
9745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9746$as_echo_n "checking for $ac_word... " >&6; }
9747if ${ac_cv_path_TAR+:} false; then :
9748  $as_echo_n "(cached) " >&6
9749else
9750  case $TAR in
9751  [\\/]* | ?:[\\/]*)
9752  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9753  ;;
9754  *)
9755  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9756for as_dir in $PATH
9757do
9758  IFS=$as_save_IFS
9759  test -z "$as_dir" && as_dir=.
9760    for ac_exec_ext in '' $ac_executable_extensions; do
9761  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9762    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9763    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9764    break 2
9765  fi
9766done
9767  done
9768IFS=$as_save_IFS
9769
9770  ;;
9771esac
9772fi
9773TAR=$ac_cv_path_TAR
9774if test -n "$TAR"; then
9775  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9776$as_echo "$TAR" >&6; }
9777else
9778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9779$as_echo "no" >&6; }
9780fi
9781
9782
9783  test -n "$TAR" && break
9784done
9785
9786    else
9787      # If it succeeded, then it was overridden by the user. We will use it
9788      # for the tool.
9789
9790      # First remove it from the list of overridden variables, so we can test
9791      # for unknown variables in the end.
9792      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9793
9794      # Check if the provided tool contains a complete path.
9795      tool_specified="$TAR"
9796      tool_basename="${tool_specified##*/}"
9797      if test "x$tool_basename" = "x$tool_specified"; then
9798        # A command without a complete path is provided, search $PATH.
9799        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5
9800$as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;}
9801        # Extract the first word of "$tool_basename", so it can be a program name with args.
9802set dummy $tool_basename; ac_word=$2
9803{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9804$as_echo_n "checking for $ac_word... " >&6; }
9805if ${ac_cv_path_TAR+:} false; then :
9806  $as_echo_n "(cached) " >&6
9807else
9808  case $TAR in
9809  [\\/]* | ?:[\\/]*)
9810  ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9811  ;;
9812  *)
9813  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9814for as_dir in $PATH
9815do
9816  IFS=$as_save_IFS
9817  test -z "$as_dir" && as_dir=.
9818    for ac_exec_ext in '' $ac_executable_extensions; do
9819  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9820    ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9821    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9822    break 2
9823  fi
9824done
9825  done
9826IFS=$as_save_IFS
9827
9828  ;;
9829esac
9830fi
9831TAR=$ac_cv_path_TAR
9832if test -n "$TAR"; then
9833  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9834$as_echo "$TAR" >&6; }
9835else
9836  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9837$as_echo "no" >&6; }
9838fi
9839
9840
9841        if test "x$TAR" = x; then
9842          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9843        fi
9844      else
9845        # Otherwise we believe it is a complete path. Use it as it is.
9846        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5
9847$as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;}
9848        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9849$as_echo_n "checking for TAR... " >&6; }
9850        if test ! -x "$tool_specified"; then
9851          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9852$as_echo "not found" >&6; }
9853          as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5
9854        fi
9855        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9856$as_echo "$tool_specified" >&6; }
9857      fi
9858    fi
9859  fi
9860
9861
9862
9863  if test "x$TAR" = x; then
9864    as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5
9865  fi
9866
9867
9868
9869
9870
9871  # Publish this variable in the help.
9872
9873
9874  if test "x$TEE" = x; then
9875    # The variable is not set by user, try to locate tool using the code snippet
9876    for ac_prog in tee
9877do
9878  # Extract the first word of "$ac_prog", so it can be a program name with args.
9879set dummy $ac_prog; ac_word=$2
9880{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9881$as_echo_n "checking for $ac_word... " >&6; }
9882if ${ac_cv_path_TEE+:} false; then :
9883  $as_echo_n "(cached) " >&6
9884else
9885  case $TEE in
9886  [\\/]* | ?:[\\/]*)
9887  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9888  ;;
9889  *)
9890  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9891for as_dir in $PATH
9892do
9893  IFS=$as_save_IFS
9894  test -z "$as_dir" && as_dir=.
9895    for ac_exec_ext in '' $ac_executable_extensions; do
9896  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9897    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9898    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9899    break 2
9900  fi
9901done
9902  done
9903IFS=$as_save_IFS
9904
9905  ;;
9906esac
9907fi
9908TEE=$ac_cv_path_TEE
9909if test -n "$TEE"; then
9910  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9911$as_echo "$TEE" >&6; }
9912else
9913  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9914$as_echo "no" >&6; }
9915fi
9916
9917
9918  test -n "$TEE" && break
9919done
9920
9921  else
9922    # The variable is set, but is it from the command line or the environment?
9923
9924    # Try to remove the string !TEE! from our list.
9925    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/}
9926    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9927      # If it failed, the variable was not from the command line. Ignore it,
9928      # but warn the user (except for BASH, which is always set by the calling BASH).
9929      if test "xTEE" != xBASH; then
9930        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5
9931$as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;}
9932      fi
9933      # Try to locate tool using the code snippet
9934      for ac_prog in tee
9935do
9936  # Extract the first word of "$ac_prog", so it can be a program name with args.
9937set dummy $ac_prog; ac_word=$2
9938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9939$as_echo_n "checking for $ac_word... " >&6; }
9940if ${ac_cv_path_TEE+:} false; then :
9941  $as_echo_n "(cached) " >&6
9942else
9943  case $TEE in
9944  [\\/]* | ?:[\\/]*)
9945  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9946  ;;
9947  *)
9948  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9949for as_dir in $PATH
9950do
9951  IFS=$as_save_IFS
9952  test -z "$as_dir" && as_dir=.
9953    for ac_exec_ext in '' $ac_executable_extensions; do
9954  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9955    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9956    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9957    break 2
9958  fi
9959done
9960  done
9961IFS=$as_save_IFS
9962
9963  ;;
9964esac
9965fi
9966TEE=$ac_cv_path_TEE
9967if test -n "$TEE"; then
9968  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9969$as_echo "$TEE" >&6; }
9970else
9971  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9972$as_echo "no" >&6; }
9973fi
9974
9975
9976  test -n "$TEE" && break
9977done
9978
9979    else
9980      # If it succeeded, then it was overridden by the user. We will use it
9981      # for the tool.
9982
9983      # First remove it from the list of overridden variables, so we can test
9984      # for unknown variables in the end.
9985      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9986
9987      # Check if the provided tool contains a complete path.
9988      tool_specified="$TEE"
9989      tool_basename="${tool_specified##*/}"
9990      if test "x$tool_basename" = "x$tool_specified"; then
9991        # A command without a complete path is provided, search $PATH.
9992        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5
9993$as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;}
9994        # Extract the first word of "$tool_basename", so it can be a program name with args.
9995set dummy $tool_basename; ac_word=$2
9996{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9997$as_echo_n "checking for $ac_word... " >&6; }
9998if ${ac_cv_path_TEE+:} false; then :
9999  $as_echo_n "(cached) " >&6
10000else
10001  case $TEE in
10002  [\\/]* | ?:[\\/]*)
10003  ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
10004  ;;
10005  *)
10006  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10007for as_dir in $PATH
10008do
10009  IFS=$as_save_IFS
10010  test -z "$as_dir" && as_dir=.
10011    for ac_exec_ext in '' $ac_executable_extensions; do
10012  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10013    ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
10014    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10015    break 2
10016  fi
10017done
10018  done
10019IFS=$as_save_IFS
10020
10021  ;;
10022esac
10023fi
10024TEE=$ac_cv_path_TEE
10025if test -n "$TEE"; then
10026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
10027$as_echo "$TEE" >&6; }
10028else
10029  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10030$as_echo "no" >&6; }
10031fi
10032
10033
10034        if test "x$TEE" = x; then
10035          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10036        fi
10037      else
10038        # Otherwise we believe it is a complete path. Use it as it is.
10039        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5
10040$as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;}
10041        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5
10042$as_echo_n "checking for TEE... " >&6; }
10043        if test ! -x "$tool_specified"; then
10044          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10045$as_echo "not found" >&6; }
10046          as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5
10047        fi
10048        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10049$as_echo "$tool_specified" >&6; }
10050      fi
10051    fi
10052  fi
10053
10054
10055
10056  if test "x$TEE" = x; then
10057    as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5
10058  fi
10059
10060
10061
10062
10063
10064  # Publish this variable in the help.
10065
10066
10067  if test "x$TOUCH" = x; then
10068    # The variable is not set by user, try to locate tool using the code snippet
10069    for ac_prog in touch
10070do
10071  # Extract the first word of "$ac_prog", so it can be a program name with args.
10072set dummy $ac_prog; ac_word=$2
10073{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10074$as_echo_n "checking for $ac_word... " >&6; }
10075if ${ac_cv_path_TOUCH+:} false; then :
10076  $as_echo_n "(cached) " >&6
10077else
10078  case $TOUCH in
10079  [\\/]* | ?:[\\/]*)
10080  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10081  ;;
10082  *)
10083  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10084for as_dir in $PATH
10085do
10086  IFS=$as_save_IFS
10087  test -z "$as_dir" && as_dir=.
10088    for ac_exec_ext in '' $ac_executable_extensions; do
10089  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10090    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10091    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10092    break 2
10093  fi
10094done
10095  done
10096IFS=$as_save_IFS
10097
10098  ;;
10099esac
10100fi
10101TOUCH=$ac_cv_path_TOUCH
10102if test -n "$TOUCH"; then
10103  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10104$as_echo "$TOUCH" >&6; }
10105else
10106  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10107$as_echo "no" >&6; }
10108fi
10109
10110
10111  test -n "$TOUCH" && break
10112done
10113
10114  else
10115    # The variable is set, but is it from the command line or the environment?
10116
10117    # Try to remove the string !TOUCH! from our list.
10118    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/}
10119    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10120      # If it failed, the variable was not from the command line. Ignore it,
10121      # but warn the user (except for BASH, which is always set by the calling BASH).
10122      if test "xTOUCH" != xBASH; then
10123        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5
10124$as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;}
10125      fi
10126      # Try to locate tool using the code snippet
10127      for ac_prog in touch
10128do
10129  # Extract the first word of "$ac_prog", so it can be a program name with args.
10130set dummy $ac_prog; ac_word=$2
10131{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10132$as_echo_n "checking for $ac_word... " >&6; }
10133if ${ac_cv_path_TOUCH+:} false; then :
10134  $as_echo_n "(cached) " >&6
10135else
10136  case $TOUCH in
10137  [\\/]* | ?:[\\/]*)
10138  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10139  ;;
10140  *)
10141  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10142for as_dir in $PATH
10143do
10144  IFS=$as_save_IFS
10145  test -z "$as_dir" && as_dir=.
10146    for ac_exec_ext in '' $ac_executable_extensions; do
10147  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10148    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10149    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10150    break 2
10151  fi
10152done
10153  done
10154IFS=$as_save_IFS
10155
10156  ;;
10157esac
10158fi
10159TOUCH=$ac_cv_path_TOUCH
10160if test -n "$TOUCH"; then
10161  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10162$as_echo "$TOUCH" >&6; }
10163else
10164  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10165$as_echo "no" >&6; }
10166fi
10167
10168
10169  test -n "$TOUCH" && break
10170done
10171
10172    else
10173      # If it succeeded, then it was overridden by the user. We will use it
10174      # for the tool.
10175
10176      # First remove it from the list of overridden variables, so we can test
10177      # for unknown variables in the end.
10178      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10179
10180      # Check if the provided tool contains a complete path.
10181      tool_specified="$TOUCH"
10182      tool_basename="${tool_specified##*/}"
10183      if test "x$tool_basename" = "x$tool_specified"; then
10184        # A command without a complete path is provided, search $PATH.
10185        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5
10186$as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;}
10187        # Extract the first word of "$tool_basename", so it can be a program name with args.
10188set dummy $tool_basename; ac_word=$2
10189{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10190$as_echo_n "checking for $ac_word... " >&6; }
10191if ${ac_cv_path_TOUCH+:} false; then :
10192  $as_echo_n "(cached) " >&6
10193else
10194  case $TOUCH in
10195  [\\/]* | ?:[\\/]*)
10196  ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10197  ;;
10198  *)
10199  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10200for as_dir in $PATH
10201do
10202  IFS=$as_save_IFS
10203  test -z "$as_dir" && as_dir=.
10204    for ac_exec_ext in '' $ac_executable_extensions; do
10205  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10206    ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10207    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10208    break 2
10209  fi
10210done
10211  done
10212IFS=$as_save_IFS
10213
10214  ;;
10215esac
10216fi
10217TOUCH=$ac_cv_path_TOUCH
10218if test -n "$TOUCH"; then
10219  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10220$as_echo "$TOUCH" >&6; }
10221else
10222  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10223$as_echo "no" >&6; }
10224fi
10225
10226
10227        if test "x$TOUCH" = x; then
10228          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10229        fi
10230      else
10231        # Otherwise we believe it is a complete path. Use it as it is.
10232        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5
10233$as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;}
10234        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5
10235$as_echo_n "checking for TOUCH... " >&6; }
10236        if test ! -x "$tool_specified"; then
10237          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10238$as_echo "not found" >&6; }
10239          as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5
10240        fi
10241        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10242$as_echo "$tool_specified" >&6; }
10243      fi
10244    fi
10245  fi
10246
10247
10248
10249  if test "x$TOUCH" = x; then
10250    as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5
10251  fi
10252
10253
10254
10255
10256
10257  # Publish this variable in the help.
10258
10259
10260  if test "x$TR" = x; then
10261    # The variable is not set by user, try to locate tool using the code snippet
10262    for ac_prog in tr
10263do
10264  # Extract the first word of "$ac_prog", so it can be a program name with args.
10265set dummy $ac_prog; ac_word=$2
10266{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10267$as_echo_n "checking for $ac_word... " >&6; }
10268if ${ac_cv_path_TR+:} false; then :
10269  $as_echo_n "(cached) " >&6
10270else
10271  case $TR in
10272  [\\/]* | ?:[\\/]*)
10273  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10274  ;;
10275  *)
10276  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10277for as_dir in $PATH
10278do
10279  IFS=$as_save_IFS
10280  test -z "$as_dir" && as_dir=.
10281    for ac_exec_ext in '' $ac_executable_extensions; do
10282  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10283    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10284    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10285    break 2
10286  fi
10287done
10288  done
10289IFS=$as_save_IFS
10290
10291  ;;
10292esac
10293fi
10294TR=$ac_cv_path_TR
10295if test -n "$TR"; then
10296  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10297$as_echo "$TR" >&6; }
10298else
10299  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10300$as_echo "no" >&6; }
10301fi
10302
10303
10304  test -n "$TR" && break
10305done
10306
10307  else
10308    # The variable is set, but is it from the command line or the environment?
10309
10310    # Try to remove the string !TR! from our list.
10311    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/}
10312    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10313      # If it failed, the variable was not from the command line. Ignore it,
10314      # but warn the user (except for BASH, which is always set by the calling BASH).
10315      if test "xTR" != xBASH; then
10316        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5
10317$as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;}
10318      fi
10319      # Try to locate tool using the code snippet
10320      for ac_prog in tr
10321do
10322  # Extract the first word of "$ac_prog", so it can be a program name with args.
10323set dummy $ac_prog; ac_word=$2
10324{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10325$as_echo_n "checking for $ac_word... " >&6; }
10326if ${ac_cv_path_TR+:} false; then :
10327  $as_echo_n "(cached) " >&6
10328else
10329  case $TR in
10330  [\\/]* | ?:[\\/]*)
10331  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10332  ;;
10333  *)
10334  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10335for as_dir in $PATH
10336do
10337  IFS=$as_save_IFS
10338  test -z "$as_dir" && as_dir=.
10339    for ac_exec_ext in '' $ac_executable_extensions; do
10340  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10341    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10342    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10343    break 2
10344  fi
10345done
10346  done
10347IFS=$as_save_IFS
10348
10349  ;;
10350esac
10351fi
10352TR=$ac_cv_path_TR
10353if test -n "$TR"; then
10354  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10355$as_echo "$TR" >&6; }
10356else
10357  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10358$as_echo "no" >&6; }
10359fi
10360
10361
10362  test -n "$TR" && break
10363done
10364
10365    else
10366      # If it succeeded, then it was overridden by the user. We will use it
10367      # for the tool.
10368
10369      # First remove it from the list of overridden variables, so we can test
10370      # for unknown variables in the end.
10371      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10372
10373      # Check if the provided tool contains a complete path.
10374      tool_specified="$TR"
10375      tool_basename="${tool_specified##*/}"
10376      if test "x$tool_basename" = "x$tool_specified"; then
10377        # A command without a complete path is provided, search $PATH.
10378        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5
10379$as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;}
10380        # Extract the first word of "$tool_basename", so it can be a program name with args.
10381set dummy $tool_basename; ac_word=$2
10382{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10383$as_echo_n "checking for $ac_word... " >&6; }
10384if ${ac_cv_path_TR+:} false; then :
10385  $as_echo_n "(cached) " >&6
10386else
10387  case $TR in
10388  [\\/]* | ?:[\\/]*)
10389  ac_cv_path_TR="$TR" # Let the user override the test with a path.
10390  ;;
10391  *)
10392  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10393for as_dir in $PATH
10394do
10395  IFS=$as_save_IFS
10396  test -z "$as_dir" && as_dir=.
10397    for ac_exec_ext in '' $ac_executable_extensions; do
10398  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10399    ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10400    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10401    break 2
10402  fi
10403done
10404  done
10405IFS=$as_save_IFS
10406
10407  ;;
10408esac
10409fi
10410TR=$ac_cv_path_TR
10411if test -n "$TR"; then
10412  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10413$as_echo "$TR" >&6; }
10414else
10415  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10416$as_echo "no" >&6; }
10417fi
10418
10419
10420        if test "x$TR" = x; then
10421          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10422        fi
10423      else
10424        # Otherwise we believe it is a complete path. Use it as it is.
10425        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5
10426$as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;}
10427        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5
10428$as_echo_n "checking for TR... " >&6; }
10429        if test ! -x "$tool_specified"; then
10430          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10431$as_echo "not found" >&6; }
10432          as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5
10433        fi
10434        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10435$as_echo "$tool_specified" >&6; }
10436      fi
10437    fi
10438  fi
10439
10440
10441
10442  if test "x$TR" = x; then
10443    as_fn_error $? "Could not find required tool for TR" "$LINENO" 5
10444  fi
10445
10446
10447
10448
10449
10450  # Publish this variable in the help.
10451
10452
10453  if test "x$UNAME" = x; then
10454    # The variable is not set by user, try to locate tool using the code snippet
10455    for ac_prog in uname
10456do
10457  # Extract the first word of "$ac_prog", so it can be a program name with args.
10458set dummy $ac_prog; ac_word=$2
10459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10460$as_echo_n "checking for $ac_word... " >&6; }
10461if ${ac_cv_path_UNAME+:} false; then :
10462  $as_echo_n "(cached) " >&6
10463else
10464  case $UNAME in
10465  [\\/]* | ?:[\\/]*)
10466  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10467  ;;
10468  *)
10469  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10470for as_dir in $PATH
10471do
10472  IFS=$as_save_IFS
10473  test -z "$as_dir" && as_dir=.
10474    for ac_exec_ext in '' $ac_executable_extensions; do
10475  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10476    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10477    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10478    break 2
10479  fi
10480done
10481  done
10482IFS=$as_save_IFS
10483
10484  ;;
10485esac
10486fi
10487UNAME=$ac_cv_path_UNAME
10488if test -n "$UNAME"; then
10489  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10490$as_echo "$UNAME" >&6; }
10491else
10492  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10493$as_echo "no" >&6; }
10494fi
10495
10496
10497  test -n "$UNAME" && break
10498done
10499
10500  else
10501    # The variable is set, but is it from the command line or the environment?
10502
10503    # Try to remove the string !UNAME! from our list.
10504    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/}
10505    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10506      # If it failed, the variable was not from the command line. Ignore it,
10507      # but warn the user (except for BASH, which is always set by the calling BASH).
10508      if test "xUNAME" != xBASH; then
10509        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5
10510$as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;}
10511      fi
10512      # Try to locate tool using the code snippet
10513      for ac_prog in uname
10514do
10515  # Extract the first word of "$ac_prog", so it can be a program name with args.
10516set dummy $ac_prog; ac_word=$2
10517{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10518$as_echo_n "checking for $ac_word... " >&6; }
10519if ${ac_cv_path_UNAME+:} false; then :
10520  $as_echo_n "(cached) " >&6
10521else
10522  case $UNAME in
10523  [\\/]* | ?:[\\/]*)
10524  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10525  ;;
10526  *)
10527  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10528for as_dir in $PATH
10529do
10530  IFS=$as_save_IFS
10531  test -z "$as_dir" && as_dir=.
10532    for ac_exec_ext in '' $ac_executable_extensions; do
10533  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10534    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10535    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10536    break 2
10537  fi
10538done
10539  done
10540IFS=$as_save_IFS
10541
10542  ;;
10543esac
10544fi
10545UNAME=$ac_cv_path_UNAME
10546if test -n "$UNAME"; then
10547  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10548$as_echo "$UNAME" >&6; }
10549else
10550  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10551$as_echo "no" >&6; }
10552fi
10553
10554
10555  test -n "$UNAME" && break
10556done
10557
10558    else
10559      # If it succeeded, then it was overridden by the user. We will use it
10560      # for the tool.
10561
10562      # First remove it from the list of overridden variables, so we can test
10563      # for unknown variables in the end.
10564      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10565
10566      # Check if the provided tool contains a complete path.
10567      tool_specified="$UNAME"
10568      tool_basename="${tool_specified##*/}"
10569      if test "x$tool_basename" = "x$tool_specified"; then
10570        # A command without a complete path is provided, search $PATH.
10571        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5
10572$as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;}
10573        # Extract the first word of "$tool_basename", so it can be a program name with args.
10574set dummy $tool_basename; ac_word=$2
10575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10576$as_echo_n "checking for $ac_word... " >&6; }
10577if ${ac_cv_path_UNAME+:} false; then :
10578  $as_echo_n "(cached) " >&6
10579else
10580  case $UNAME in
10581  [\\/]* | ?:[\\/]*)
10582  ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10583  ;;
10584  *)
10585  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10586for as_dir in $PATH
10587do
10588  IFS=$as_save_IFS
10589  test -z "$as_dir" && as_dir=.
10590    for ac_exec_ext in '' $ac_executable_extensions; do
10591  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10592    ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10593    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10594    break 2
10595  fi
10596done
10597  done
10598IFS=$as_save_IFS
10599
10600  ;;
10601esac
10602fi
10603UNAME=$ac_cv_path_UNAME
10604if test -n "$UNAME"; then
10605  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10606$as_echo "$UNAME" >&6; }
10607else
10608  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10609$as_echo "no" >&6; }
10610fi
10611
10612
10613        if test "x$UNAME" = x; then
10614          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10615        fi
10616      else
10617        # Otherwise we believe it is a complete path. Use it as it is.
10618        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5
10619$as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;}
10620        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5
10621$as_echo_n "checking for UNAME... " >&6; }
10622        if test ! -x "$tool_specified"; then
10623          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10624$as_echo "not found" >&6; }
10625          as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
10626        fi
10627        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10628$as_echo "$tool_specified" >&6; }
10629      fi
10630    fi
10631  fi
10632
10633
10634
10635  if test "x$UNAME" = x; then
10636    as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5
10637  fi
10638
10639
10640
10641
10642
10643  # Publish this variable in the help.
10644
10645
10646  if test "x$UNIQ" = x; then
10647    # The variable is not set by user, try to locate tool using the code snippet
10648    for ac_prog in uniq
10649do
10650  # Extract the first word of "$ac_prog", so it can be a program name with args.
10651set dummy $ac_prog; ac_word=$2
10652{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10653$as_echo_n "checking for $ac_word... " >&6; }
10654if ${ac_cv_path_UNIQ+:} false; then :
10655  $as_echo_n "(cached) " >&6
10656else
10657  case $UNIQ in
10658  [\\/]* | ?:[\\/]*)
10659  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10660  ;;
10661  *)
10662  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10663for as_dir in $PATH
10664do
10665  IFS=$as_save_IFS
10666  test -z "$as_dir" && as_dir=.
10667    for ac_exec_ext in '' $ac_executable_extensions; do
10668  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10669    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10670    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10671    break 2
10672  fi
10673done
10674  done
10675IFS=$as_save_IFS
10676
10677  ;;
10678esac
10679fi
10680UNIQ=$ac_cv_path_UNIQ
10681if test -n "$UNIQ"; then
10682  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10683$as_echo "$UNIQ" >&6; }
10684else
10685  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10686$as_echo "no" >&6; }
10687fi
10688
10689
10690  test -n "$UNIQ" && break
10691done
10692
10693  else
10694    # The variable is set, but is it from the command line or the environment?
10695
10696    # Try to remove the string !UNIQ! from our list.
10697    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/}
10698    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10699      # If it failed, the variable was not from the command line. Ignore it,
10700      # but warn the user (except for BASH, which is always set by the calling BASH).
10701      if test "xUNIQ" != xBASH; then
10702        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5
10703$as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;}
10704      fi
10705      # Try to locate tool using the code snippet
10706      for ac_prog in uniq
10707do
10708  # Extract the first word of "$ac_prog", so it can be a program name with args.
10709set dummy $ac_prog; ac_word=$2
10710{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10711$as_echo_n "checking for $ac_word... " >&6; }
10712if ${ac_cv_path_UNIQ+:} false; then :
10713  $as_echo_n "(cached) " >&6
10714else
10715  case $UNIQ in
10716  [\\/]* | ?:[\\/]*)
10717  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10718  ;;
10719  *)
10720  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10721for as_dir in $PATH
10722do
10723  IFS=$as_save_IFS
10724  test -z "$as_dir" && as_dir=.
10725    for ac_exec_ext in '' $ac_executable_extensions; do
10726  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10727    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10728    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10729    break 2
10730  fi
10731done
10732  done
10733IFS=$as_save_IFS
10734
10735  ;;
10736esac
10737fi
10738UNIQ=$ac_cv_path_UNIQ
10739if test -n "$UNIQ"; then
10740  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10741$as_echo "$UNIQ" >&6; }
10742else
10743  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10744$as_echo "no" >&6; }
10745fi
10746
10747
10748  test -n "$UNIQ" && break
10749done
10750
10751    else
10752      # If it succeeded, then it was overridden by the user. We will use it
10753      # for the tool.
10754
10755      # First remove it from the list of overridden variables, so we can test
10756      # for unknown variables in the end.
10757      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10758
10759      # Check if the provided tool contains a complete path.
10760      tool_specified="$UNIQ"
10761      tool_basename="${tool_specified##*/}"
10762      if test "x$tool_basename" = "x$tool_specified"; then
10763        # A command without a complete path is provided, search $PATH.
10764        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5
10765$as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;}
10766        # Extract the first word of "$tool_basename", so it can be a program name with args.
10767set dummy $tool_basename; ac_word=$2
10768{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10769$as_echo_n "checking for $ac_word... " >&6; }
10770if ${ac_cv_path_UNIQ+:} false; then :
10771  $as_echo_n "(cached) " >&6
10772else
10773  case $UNIQ in
10774  [\\/]* | ?:[\\/]*)
10775  ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10776  ;;
10777  *)
10778  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10779for as_dir in $PATH
10780do
10781  IFS=$as_save_IFS
10782  test -z "$as_dir" && as_dir=.
10783    for ac_exec_ext in '' $ac_executable_extensions; do
10784  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10785    ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10786    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10787    break 2
10788  fi
10789done
10790  done
10791IFS=$as_save_IFS
10792
10793  ;;
10794esac
10795fi
10796UNIQ=$ac_cv_path_UNIQ
10797if test -n "$UNIQ"; then
10798  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10799$as_echo "$UNIQ" >&6; }
10800else
10801  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10802$as_echo "no" >&6; }
10803fi
10804
10805
10806        if test "x$UNIQ" = x; then
10807          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10808        fi
10809      else
10810        # Otherwise we believe it is a complete path. Use it as it is.
10811        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5
10812$as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;}
10813        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5
10814$as_echo_n "checking for UNIQ... " >&6; }
10815        if test ! -x "$tool_specified"; then
10816          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10817$as_echo "not found" >&6; }
10818          as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5
10819        fi
10820        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10821$as_echo "$tool_specified" >&6; }
10822      fi
10823    fi
10824  fi
10825
10826
10827
10828  if test "x$UNIQ" = x; then
10829    as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5
10830  fi
10831
10832
10833
10834
10835
10836  # Publish this variable in the help.
10837
10838
10839  if test "x$WC" = x; then
10840    # The variable is not set by user, try to locate tool using the code snippet
10841    for ac_prog in wc
10842do
10843  # Extract the first word of "$ac_prog", so it can be a program name with args.
10844set dummy $ac_prog; ac_word=$2
10845{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10846$as_echo_n "checking for $ac_word... " >&6; }
10847if ${ac_cv_path_WC+:} false; then :
10848  $as_echo_n "(cached) " >&6
10849else
10850  case $WC in
10851  [\\/]* | ?:[\\/]*)
10852  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10853  ;;
10854  *)
10855  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10856for as_dir in $PATH
10857do
10858  IFS=$as_save_IFS
10859  test -z "$as_dir" && as_dir=.
10860    for ac_exec_ext in '' $ac_executable_extensions; do
10861  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10862    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10863    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10864    break 2
10865  fi
10866done
10867  done
10868IFS=$as_save_IFS
10869
10870  ;;
10871esac
10872fi
10873WC=$ac_cv_path_WC
10874if test -n "$WC"; then
10875  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10876$as_echo "$WC" >&6; }
10877else
10878  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10879$as_echo "no" >&6; }
10880fi
10881
10882
10883  test -n "$WC" && break
10884done
10885
10886  else
10887    # The variable is set, but is it from the command line or the environment?
10888
10889    # Try to remove the string !WC! from our list.
10890    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/}
10891    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10892      # If it failed, the variable was not from the command line. Ignore it,
10893      # but warn the user (except for BASH, which is always set by the calling BASH).
10894      if test "xWC" != xBASH; then
10895        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5
10896$as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;}
10897      fi
10898      # Try to locate tool using the code snippet
10899      for ac_prog in wc
10900do
10901  # Extract the first word of "$ac_prog", so it can be a program name with args.
10902set dummy $ac_prog; ac_word=$2
10903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10904$as_echo_n "checking for $ac_word... " >&6; }
10905if ${ac_cv_path_WC+:} false; then :
10906  $as_echo_n "(cached) " >&6
10907else
10908  case $WC in
10909  [\\/]* | ?:[\\/]*)
10910  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10911  ;;
10912  *)
10913  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10914for as_dir in $PATH
10915do
10916  IFS=$as_save_IFS
10917  test -z "$as_dir" && as_dir=.
10918    for ac_exec_ext in '' $ac_executable_extensions; do
10919  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10920    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10921    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10922    break 2
10923  fi
10924done
10925  done
10926IFS=$as_save_IFS
10927
10928  ;;
10929esac
10930fi
10931WC=$ac_cv_path_WC
10932if test -n "$WC"; then
10933  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10934$as_echo "$WC" >&6; }
10935else
10936  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10937$as_echo "no" >&6; }
10938fi
10939
10940
10941  test -n "$WC" && break
10942done
10943
10944    else
10945      # If it succeeded, then it was overridden by the user. We will use it
10946      # for the tool.
10947
10948      # First remove it from the list of overridden variables, so we can test
10949      # for unknown variables in the end.
10950      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10951
10952      # Check if the provided tool contains a complete path.
10953      tool_specified="$WC"
10954      tool_basename="${tool_specified##*/}"
10955      if test "x$tool_basename" = "x$tool_specified"; then
10956        # A command without a complete path is provided, search $PATH.
10957        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5
10958$as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;}
10959        # Extract the first word of "$tool_basename", so it can be a program name with args.
10960set dummy $tool_basename; ac_word=$2
10961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10962$as_echo_n "checking for $ac_word... " >&6; }
10963if ${ac_cv_path_WC+:} false; then :
10964  $as_echo_n "(cached) " >&6
10965else
10966  case $WC in
10967  [\\/]* | ?:[\\/]*)
10968  ac_cv_path_WC="$WC" # Let the user override the test with a path.
10969  ;;
10970  *)
10971  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10972for as_dir in $PATH
10973do
10974  IFS=$as_save_IFS
10975  test -z "$as_dir" && as_dir=.
10976    for ac_exec_ext in '' $ac_executable_extensions; do
10977  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10978    ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10979    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10980    break 2
10981  fi
10982done
10983  done
10984IFS=$as_save_IFS
10985
10986  ;;
10987esac
10988fi
10989WC=$ac_cv_path_WC
10990if test -n "$WC"; then
10991  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10992$as_echo "$WC" >&6; }
10993else
10994  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10995$as_echo "no" >&6; }
10996fi
10997
10998
10999        if test "x$WC" = x; then
11000          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11001        fi
11002      else
11003        # Otherwise we believe it is a complete path. Use it as it is.
11004        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5
11005$as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;}
11006        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5
11007$as_echo_n "checking for WC... " >&6; }
11008        if test ! -x "$tool_specified"; then
11009          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11010$as_echo "not found" >&6; }
11011          as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5
11012        fi
11013        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11014$as_echo "$tool_specified" >&6; }
11015      fi
11016    fi
11017  fi
11018
11019
11020
11021  if test "x$WC" = x; then
11022    as_fn_error $? "Could not find required tool for WC" "$LINENO" 5
11023  fi
11024
11025
11026
11027
11028
11029  # Publish this variable in the help.
11030
11031
11032  if test "x$WHICH" = x; then
11033    # The variable is not set by user, try to locate tool using the code snippet
11034    for ac_prog in which
11035do
11036  # Extract the first word of "$ac_prog", so it can be a program name with args.
11037set dummy $ac_prog; ac_word=$2
11038{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11039$as_echo_n "checking for $ac_word... " >&6; }
11040if ${ac_cv_path_WHICH+:} false; then :
11041  $as_echo_n "(cached) " >&6
11042else
11043  case $WHICH in
11044  [\\/]* | ?:[\\/]*)
11045  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11046  ;;
11047  *)
11048  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11049for as_dir in $PATH
11050do
11051  IFS=$as_save_IFS
11052  test -z "$as_dir" && as_dir=.
11053    for ac_exec_ext in '' $ac_executable_extensions; do
11054  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11055    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11056    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11057    break 2
11058  fi
11059done
11060  done
11061IFS=$as_save_IFS
11062
11063  ;;
11064esac
11065fi
11066WHICH=$ac_cv_path_WHICH
11067if test -n "$WHICH"; then
11068  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11069$as_echo "$WHICH" >&6; }
11070else
11071  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11072$as_echo "no" >&6; }
11073fi
11074
11075
11076  test -n "$WHICH" && break
11077done
11078
11079  else
11080    # The variable is set, but is it from the command line or the environment?
11081
11082    # Try to remove the string !WHICH! from our list.
11083    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/}
11084    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11085      # If it failed, the variable was not from the command line. Ignore it,
11086      # but warn the user (except for BASH, which is always set by the calling BASH).
11087      if test "xWHICH" != xBASH; then
11088        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5
11089$as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;}
11090      fi
11091      # Try to locate tool using the code snippet
11092      for ac_prog in which
11093do
11094  # Extract the first word of "$ac_prog", so it can be a program name with args.
11095set dummy $ac_prog; ac_word=$2
11096{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11097$as_echo_n "checking for $ac_word... " >&6; }
11098if ${ac_cv_path_WHICH+:} false; then :
11099  $as_echo_n "(cached) " >&6
11100else
11101  case $WHICH in
11102  [\\/]* | ?:[\\/]*)
11103  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11104  ;;
11105  *)
11106  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11107for as_dir in $PATH
11108do
11109  IFS=$as_save_IFS
11110  test -z "$as_dir" && as_dir=.
11111    for ac_exec_ext in '' $ac_executable_extensions; do
11112  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11113    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11114    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11115    break 2
11116  fi
11117done
11118  done
11119IFS=$as_save_IFS
11120
11121  ;;
11122esac
11123fi
11124WHICH=$ac_cv_path_WHICH
11125if test -n "$WHICH"; then
11126  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11127$as_echo "$WHICH" >&6; }
11128else
11129  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11130$as_echo "no" >&6; }
11131fi
11132
11133
11134  test -n "$WHICH" && break
11135done
11136
11137    else
11138      # If it succeeded, then it was overridden by the user. We will use it
11139      # for the tool.
11140
11141      # First remove it from the list of overridden variables, so we can test
11142      # for unknown variables in the end.
11143      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11144
11145      # Check if the provided tool contains a complete path.
11146      tool_specified="$WHICH"
11147      tool_basename="${tool_specified##*/}"
11148      if test "x$tool_basename" = "x$tool_specified"; then
11149        # A command without a complete path is provided, search $PATH.
11150        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5
11151$as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;}
11152        # Extract the first word of "$tool_basename", so it can be a program name with args.
11153set dummy $tool_basename; ac_word=$2
11154{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11155$as_echo_n "checking for $ac_word... " >&6; }
11156if ${ac_cv_path_WHICH+:} false; then :
11157  $as_echo_n "(cached) " >&6
11158else
11159  case $WHICH in
11160  [\\/]* | ?:[\\/]*)
11161  ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11162  ;;
11163  *)
11164  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11165for as_dir in $PATH
11166do
11167  IFS=$as_save_IFS
11168  test -z "$as_dir" && as_dir=.
11169    for ac_exec_ext in '' $ac_executable_extensions; do
11170  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11171    ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11172    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11173    break 2
11174  fi
11175done
11176  done
11177IFS=$as_save_IFS
11178
11179  ;;
11180esac
11181fi
11182WHICH=$ac_cv_path_WHICH
11183if test -n "$WHICH"; then
11184  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11185$as_echo "$WHICH" >&6; }
11186else
11187  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11188$as_echo "no" >&6; }
11189fi
11190
11191
11192        if test "x$WHICH" = x; then
11193          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11194        fi
11195      else
11196        # Otherwise we believe it is a complete path. Use it as it is.
11197        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5
11198$as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;}
11199        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5
11200$as_echo_n "checking for WHICH... " >&6; }
11201        if test ! -x "$tool_specified"; then
11202          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11203$as_echo "not found" >&6; }
11204          as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5
11205        fi
11206        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11207$as_echo "$tool_specified" >&6; }
11208      fi
11209    fi
11210  fi
11211
11212
11213
11214  if test "x$WHICH" = x; then
11215    as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5
11216  fi
11217
11218
11219
11220
11221
11222  # Publish this variable in the help.
11223
11224
11225  if test "x$XARGS" = x; then
11226    # The variable is not set by user, try to locate tool using the code snippet
11227    for ac_prog in xargs
11228do
11229  # Extract the first word of "$ac_prog", so it can be a program name with args.
11230set dummy $ac_prog; ac_word=$2
11231{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11232$as_echo_n "checking for $ac_word... " >&6; }
11233if ${ac_cv_path_XARGS+:} false; then :
11234  $as_echo_n "(cached) " >&6
11235else
11236  case $XARGS in
11237  [\\/]* | ?:[\\/]*)
11238  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11239  ;;
11240  *)
11241  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11242for as_dir in $PATH
11243do
11244  IFS=$as_save_IFS
11245  test -z "$as_dir" && as_dir=.
11246    for ac_exec_ext in '' $ac_executable_extensions; do
11247  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11248    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11249    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11250    break 2
11251  fi
11252done
11253  done
11254IFS=$as_save_IFS
11255
11256  ;;
11257esac
11258fi
11259XARGS=$ac_cv_path_XARGS
11260if test -n "$XARGS"; then
11261  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11262$as_echo "$XARGS" >&6; }
11263else
11264  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11265$as_echo "no" >&6; }
11266fi
11267
11268
11269  test -n "$XARGS" && break
11270done
11271
11272  else
11273    # The variable is set, but is it from the command line or the environment?
11274
11275    # Try to remove the string !XARGS! from our list.
11276    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/}
11277    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11278      # If it failed, the variable was not from the command line. Ignore it,
11279      # but warn the user (except for BASH, which is always set by the calling BASH).
11280      if test "xXARGS" != xBASH; then
11281        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5
11282$as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;}
11283      fi
11284      # Try to locate tool using the code snippet
11285      for ac_prog in xargs
11286do
11287  # Extract the first word of "$ac_prog", so it can be a program name with args.
11288set dummy $ac_prog; ac_word=$2
11289{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11290$as_echo_n "checking for $ac_word... " >&6; }
11291if ${ac_cv_path_XARGS+:} false; then :
11292  $as_echo_n "(cached) " >&6
11293else
11294  case $XARGS in
11295  [\\/]* | ?:[\\/]*)
11296  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11297  ;;
11298  *)
11299  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11300for as_dir in $PATH
11301do
11302  IFS=$as_save_IFS
11303  test -z "$as_dir" && as_dir=.
11304    for ac_exec_ext in '' $ac_executable_extensions; do
11305  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11306    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11307    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11308    break 2
11309  fi
11310done
11311  done
11312IFS=$as_save_IFS
11313
11314  ;;
11315esac
11316fi
11317XARGS=$ac_cv_path_XARGS
11318if test -n "$XARGS"; then
11319  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11320$as_echo "$XARGS" >&6; }
11321else
11322  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11323$as_echo "no" >&6; }
11324fi
11325
11326
11327  test -n "$XARGS" && break
11328done
11329
11330    else
11331      # If it succeeded, then it was overridden by the user. We will use it
11332      # for the tool.
11333
11334      # First remove it from the list of overridden variables, so we can test
11335      # for unknown variables in the end.
11336      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11337
11338      # Check if the provided tool contains a complete path.
11339      tool_specified="$XARGS"
11340      tool_basename="${tool_specified##*/}"
11341      if test "x$tool_basename" = "x$tool_specified"; then
11342        # A command without a complete path is provided, search $PATH.
11343        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5
11344$as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;}
11345        # Extract the first word of "$tool_basename", so it can be a program name with args.
11346set dummy $tool_basename; ac_word=$2
11347{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11348$as_echo_n "checking for $ac_word... " >&6; }
11349if ${ac_cv_path_XARGS+:} false; then :
11350  $as_echo_n "(cached) " >&6
11351else
11352  case $XARGS in
11353  [\\/]* | ?:[\\/]*)
11354  ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11355  ;;
11356  *)
11357  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11358for as_dir in $PATH
11359do
11360  IFS=$as_save_IFS
11361  test -z "$as_dir" && as_dir=.
11362    for ac_exec_ext in '' $ac_executable_extensions; do
11363  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11364    ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11365    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11366    break 2
11367  fi
11368done
11369  done
11370IFS=$as_save_IFS
11371
11372  ;;
11373esac
11374fi
11375XARGS=$ac_cv_path_XARGS
11376if test -n "$XARGS"; then
11377  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11378$as_echo "$XARGS" >&6; }
11379else
11380  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11381$as_echo "no" >&6; }
11382fi
11383
11384
11385        if test "x$XARGS" = x; then
11386          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11387        fi
11388      else
11389        # Otherwise we believe it is a complete path. Use it as it is.
11390        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5
11391$as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;}
11392        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5
11393$as_echo_n "checking for XARGS... " >&6; }
11394        if test ! -x "$tool_specified"; then
11395          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11396$as_echo "not found" >&6; }
11397          as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5
11398        fi
11399        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11400$as_echo "$tool_specified" >&6; }
11401      fi
11402    fi
11403  fi
11404
11405
11406
11407  if test "x$XARGS" = x; then
11408    as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5
11409  fi
11410
11411
11412
11413  # Then required tools that require some special treatment.
11414
11415
11416  # Publish this variable in the help.
11417
11418
11419  if test "x$AWK" = x; then
11420    # The variable is not set by user, try to locate tool using the code snippet
11421    for ac_prog in gawk mawk nawk awk
11422do
11423  # Extract the first word of "$ac_prog", so it can be a program name with args.
11424set dummy $ac_prog; ac_word=$2
11425{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11426$as_echo_n "checking for $ac_word... " >&6; }
11427if ${ac_cv_prog_AWK+:} false; then :
11428  $as_echo_n "(cached) " >&6
11429else
11430  if test -n "$AWK"; then
11431  ac_cv_prog_AWK="$AWK" # Let the user override the test.
11432else
11433as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11434for as_dir in $PATH
11435do
11436  IFS=$as_save_IFS
11437  test -z "$as_dir" && as_dir=.
11438    for ac_exec_ext in '' $ac_executable_extensions; do
11439  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11440    ac_cv_prog_AWK="$ac_prog"
11441    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11442    break 2
11443  fi
11444done
11445  done
11446IFS=$as_save_IFS
11447
11448fi
11449fi
11450AWK=$ac_cv_prog_AWK
11451if test -n "$AWK"; then
11452  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11453$as_echo "$AWK" >&6; }
11454else
11455  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11456$as_echo "no" >&6; }
11457fi
11458
11459
11460  test -n "$AWK" && break
11461done
11462
11463  else
11464    # The variable is set, but is it from the command line or the environment?
11465
11466    # Try to remove the string !AWK! from our list.
11467    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/}
11468    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11469      # If it failed, the variable was not from the command line. Ignore it,
11470      # but warn the user (except for BASH, which is always set by the calling BASH).
11471      if test "xAWK" != xBASH; then
11472        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5
11473$as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;}
11474      fi
11475      # Try to locate tool using the code snippet
11476      for ac_prog in gawk mawk nawk awk
11477do
11478  # Extract the first word of "$ac_prog", so it can be a program name with args.
11479set dummy $ac_prog; ac_word=$2
11480{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11481$as_echo_n "checking for $ac_word... " >&6; }
11482if ${ac_cv_prog_AWK+:} false; then :
11483  $as_echo_n "(cached) " >&6
11484else
11485  if test -n "$AWK"; then
11486  ac_cv_prog_AWK="$AWK" # Let the user override the test.
11487else
11488as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11489for as_dir in $PATH
11490do
11491  IFS=$as_save_IFS
11492  test -z "$as_dir" && as_dir=.
11493    for ac_exec_ext in '' $ac_executable_extensions; do
11494  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11495    ac_cv_prog_AWK="$ac_prog"
11496    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11497    break 2
11498  fi
11499done
11500  done
11501IFS=$as_save_IFS
11502
11503fi
11504fi
11505AWK=$ac_cv_prog_AWK
11506if test -n "$AWK"; then
11507  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11508$as_echo "$AWK" >&6; }
11509else
11510  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11511$as_echo "no" >&6; }
11512fi
11513
11514
11515  test -n "$AWK" && break
11516done
11517
11518    else
11519      # If it succeeded, then it was overridden by the user. We will use it
11520      # for the tool.
11521
11522      # First remove it from the list of overridden variables, so we can test
11523      # for unknown variables in the end.
11524      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11525
11526      # Check if the provided tool contains a complete path.
11527      tool_specified="$AWK"
11528      tool_basename="${tool_specified##*/}"
11529      if test "x$tool_basename" = "x$tool_specified"; then
11530        # A command without a complete path is provided, search $PATH.
11531        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5
11532$as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;}
11533        # Extract the first word of "$tool_basename", so it can be a program name with args.
11534set dummy $tool_basename; ac_word=$2
11535{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11536$as_echo_n "checking for $ac_word... " >&6; }
11537if ${ac_cv_path_AWK+:} false; then :
11538  $as_echo_n "(cached) " >&6
11539else
11540  case $AWK in
11541  [\\/]* | ?:[\\/]*)
11542  ac_cv_path_AWK="$AWK" # Let the user override the test with a path.
11543  ;;
11544  *)
11545  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11546for as_dir in $PATH
11547do
11548  IFS=$as_save_IFS
11549  test -z "$as_dir" && as_dir=.
11550    for ac_exec_ext in '' $ac_executable_extensions; do
11551  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11552    ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext"
11553    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11554    break 2
11555  fi
11556done
11557  done
11558IFS=$as_save_IFS
11559
11560  ;;
11561esac
11562fi
11563AWK=$ac_cv_path_AWK
11564if test -n "$AWK"; then
11565  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11566$as_echo "$AWK" >&6; }
11567else
11568  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11569$as_echo "no" >&6; }
11570fi
11571
11572
11573        if test "x$AWK" = x; then
11574          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11575        fi
11576      else
11577        # Otherwise we believe it is a complete path. Use it as it is.
11578        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5
11579$as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;}
11580        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5
11581$as_echo_n "checking for AWK... " >&6; }
11582        if test ! -x "$tool_specified"; then
11583          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11584$as_echo "not found" >&6; }
11585          as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5
11586        fi
11587        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11588$as_echo "$tool_specified" >&6; }
11589      fi
11590    fi
11591  fi
11592
11593
11594  if test "x$AWK" = x; then
11595    as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5
11596  fi
11597
11598
11599
11600
11601  # Publish this variable in the help.
11602
11603
11604  if test "x$GREP" = x; then
11605    # The variable is not set by user, try to locate tool using the code snippet
11606    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11607$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11608if ${ac_cv_path_GREP+:} false; then :
11609  $as_echo_n "(cached) " >&6
11610else
11611  if test -z "$GREP"; then
11612  ac_path_GREP_found=false
11613  # Loop through the user's path and test for each of PROGNAME-LIST
11614  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11615for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11616do
11617  IFS=$as_save_IFS
11618  test -z "$as_dir" && as_dir=.
11619    for ac_prog in grep ggrep; do
11620    for ac_exec_ext in '' $ac_executable_extensions; do
11621      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11622      as_fn_executable_p "$ac_path_GREP" || continue
11623# Check for GNU ac_path_GREP and select it if it is found.
11624  # Check for GNU $ac_path_GREP
11625case `"$ac_path_GREP" --version 2>&1` in
11626*GNU*)
11627  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11628*)
11629  ac_count=0
11630  $as_echo_n 0123456789 >"conftest.in"
11631  while :
11632  do
11633    cat "conftest.in" "conftest.in" >"conftest.tmp"
11634    mv "conftest.tmp" "conftest.in"
11635    cp "conftest.in" "conftest.nl"
11636    $as_echo 'GREP' >> "conftest.nl"
11637    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11638    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11639    as_fn_arith $ac_count + 1 && ac_count=$as_val
11640    if test $ac_count -gt ${ac_path_GREP_max-0}; then
11641      # Best one so far, save it but keep looking for a better one
11642      ac_cv_path_GREP="$ac_path_GREP"
11643      ac_path_GREP_max=$ac_count
11644    fi
11645    # 10*(2^10) chars as input seems more than enough
11646    test $ac_count -gt 10 && break
11647  done
11648  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11649esac
11650
11651      $ac_path_GREP_found && break 3
11652    done
11653  done
11654  done
11655IFS=$as_save_IFS
11656  if test -z "$ac_cv_path_GREP"; then
11657    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11658  fi
11659else
11660  ac_cv_path_GREP=$GREP
11661fi
11662
11663fi
11664{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11665$as_echo "$ac_cv_path_GREP" >&6; }
11666 GREP="$ac_cv_path_GREP"
11667
11668
11669  else
11670    # The variable is set, but is it from the command line or the environment?
11671
11672    # Try to remove the string !GREP! from our list.
11673    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/}
11674    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11675      # If it failed, the variable was not from the command line. Ignore it,
11676      # but warn the user (except for BASH, which is always set by the calling BASH).
11677      if test "xGREP" != xBASH; then
11678        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5
11679$as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;}
11680      fi
11681      # Try to locate tool using the code snippet
11682      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11683$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11684if ${ac_cv_path_GREP+:} false; then :
11685  $as_echo_n "(cached) " >&6
11686else
11687  if test -z "$GREP"; then
11688  ac_path_GREP_found=false
11689  # Loop through the user's path and test for each of PROGNAME-LIST
11690  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11691for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11692do
11693  IFS=$as_save_IFS
11694  test -z "$as_dir" && as_dir=.
11695    for ac_prog in grep ggrep; do
11696    for ac_exec_ext in '' $ac_executable_extensions; do
11697      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11698      as_fn_executable_p "$ac_path_GREP" || continue
11699# Check for GNU ac_path_GREP and select it if it is found.
11700  # Check for GNU $ac_path_GREP
11701case `"$ac_path_GREP" --version 2>&1` in
11702*GNU*)
11703  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11704*)
11705  ac_count=0
11706  $as_echo_n 0123456789 >"conftest.in"
11707  while :
11708  do
11709    cat "conftest.in" "conftest.in" >"conftest.tmp"
11710    mv "conftest.tmp" "conftest.in"
11711    cp "conftest.in" "conftest.nl"
11712    $as_echo 'GREP' >> "conftest.nl"
11713    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11714    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11715    as_fn_arith $ac_count + 1 && ac_count=$as_val
11716    if test $ac_count -gt ${ac_path_GREP_max-0}; then
11717      # Best one so far, save it but keep looking for a better one
11718      ac_cv_path_GREP="$ac_path_GREP"
11719      ac_path_GREP_max=$ac_count
11720    fi
11721    # 10*(2^10) chars as input seems more than enough
11722    test $ac_count -gt 10 && break
11723  done
11724  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11725esac
11726
11727      $ac_path_GREP_found && break 3
11728    done
11729  done
11730  done
11731IFS=$as_save_IFS
11732  if test -z "$ac_cv_path_GREP"; then
11733    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11734  fi
11735else
11736  ac_cv_path_GREP=$GREP
11737fi
11738
11739fi
11740{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11741$as_echo "$ac_cv_path_GREP" >&6; }
11742 GREP="$ac_cv_path_GREP"
11743
11744
11745    else
11746      # If it succeeded, then it was overridden by the user. We will use it
11747      # for the tool.
11748
11749      # First remove it from the list of overridden variables, so we can test
11750      # for unknown variables in the end.
11751      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11752
11753      # Check if the provided tool contains a complete path.
11754      tool_specified="$GREP"
11755      tool_basename="${tool_specified##*/}"
11756      if test "x$tool_basename" = "x$tool_specified"; then
11757        # A command without a complete path is provided, search $PATH.
11758        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5
11759$as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;}
11760        # Extract the first word of "$tool_basename", so it can be a program name with args.
11761set dummy $tool_basename; ac_word=$2
11762{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11763$as_echo_n "checking for $ac_word... " >&6; }
11764if ${ac_cv_path_GREP+:} false; then :
11765  $as_echo_n "(cached) " >&6
11766else
11767  case $GREP in
11768  [\\/]* | ?:[\\/]*)
11769  ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
11770  ;;
11771  *)
11772  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11773for as_dir in $PATH
11774do
11775  IFS=$as_save_IFS
11776  test -z "$as_dir" && as_dir=.
11777    for ac_exec_ext in '' $ac_executable_extensions; do
11778  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11779    ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
11780    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11781    break 2
11782  fi
11783done
11784  done
11785IFS=$as_save_IFS
11786
11787  ;;
11788esac
11789fi
11790GREP=$ac_cv_path_GREP
11791if test -n "$GREP"; then
11792  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
11793$as_echo "$GREP" >&6; }
11794else
11795  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11796$as_echo "no" >&6; }
11797fi
11798
11799
11800        if test "x$GREP" = x; then
11801          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11802        fi
11803      else
11804        # Otherwise we believe it is a complete path. Use it as it is.
11805        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5
11806$as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;}
11807        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5
11808$as_echo_n "checking for GREP... " >&6; }
11809        if test ! -x "$tool_specified"; then
11810          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11811$as_echo "not found" >&6; }
11812          as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11813        fi
11814        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11815$as_echo "$tool_specified" >&6; }
11816      fi
11817    fi
11818  fi
11819
11820
11821  if test "x$GREP" = x; then
11822    as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5
11823  fi
11824
11825
11826
11827
11828  # Publish this variable in the help.
11829
11830
11831  if test "x$EGREP" = x; then
11832    # The variable is not set by user, try to locate tool using the code snippet
11833    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11834$as_echo_n "checking for egrep... " >&6; }
11835if ${ac_cv_path_EGREP+:} false; then :
11836  $as_echo_n "(cached) " >&6
11837else
11838  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11839   then ac_cv_path_EGREP="$GREP -E"
11840   else
11841     if test -z "$EGREP"; then
11842  ac_path_EGREP_found=false
11843  # Loop through the user's path and test for each of PROGNAME-LIST
11844  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11845for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11846do
11847  IFS=$as_save_IFS
11848  test -z "$as_dir" && as_dir=.
11849    for ac_prog in egrep; do
11850    for ac_exec_ext in '' $ac_executable_extensions; do
11851      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11852      as_fn_executable_p "$ac_path_EGREP" || continue
11853# Check for GNU ac_path_EGREP and select it if it is found.
11854  # Check for GNU $ac_path_EGREP
11855case `"$ac_path_EGREP" --version 2>&1` in
11856*GNU*)
11857  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11858*)
11859  ac_count=0
11860  $as_echo_n 0123456789 >"conftest.in"
11861  while :
11862  do
11863    cat "conftest.in" "conftest.in" >"conftest.tmp"
11864    mv "conftest.tmp" "conftest.in"
11865    cp "conftest.in" "conftest.nl"
11866    $as_echo 'EGREP' >> "conftest.nl"
11867    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11868    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11869    as_fn_arith $ac_count + 1 && ac_count=$as_val
11870    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11871      # Best one so far, save it but keep looking for a better one
11872      ac_cv_path_EGREP="$ac_path_EGREP"
11873      ac_path_EGREP_max=$ac_count
11874    fi
11875    # 10*(2^10) chars as input seems more than enough
11876    test $ac_count -gt 10 && break
11877  done
11878  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11879esac
11880
11881      $ac_path_EGREP_found && break 3
11882    done
11883  done
11884  done
11885IFS=$as_save_IFS
11886  if test -z "$ac_cv_path_EGREP"; then
11887    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11888  fi
11889else
11890  ac_cv_path_EGREP=$EGREP
11891fi
11892
11893   fi
11894fi
11895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11896$as_echo "$ac_cv_path_EGREP" >&6; }
11897 EGREP="$ac_cv_path_EGREP"
11898
11899
11900  else
11901    # The variable is set, but is it from the command line or the environment?
11902
11903    # Try to remove the string !EGREP! from our list.
11904    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/}
11905    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11906      # If it failed, the variable was not from the command line. Ignore it,
11907      # but warn the user (except for BASH, which is always set by the calling BASH).
11908      if test "xEGREP" != xBASH; then
11909        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5
11910$as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;}
11911      fi
11912      # Try to locate tool using the code snippet
11913      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11914$as_echo_n "checking for egrep... " >&6; }
11915if ${ac_cv_path_EGREP+:} false; then :
11916  $as_echo_n "(cached) " >&6
11917else
11918  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11919   then ac_cv_path_EGREP="$GREP -E"
11920   else
11921     if test -z "$EGREP"; then
11922  ac_path_EGREP_found=false
11923  # Loop through the user's path and test for each of PROGNAME-LIST
11924  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11925for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11926do
11927  IFS=$as_save_IFS
11928  test -z "$as_dir" && as_dir=.
11929    for ac_prog in egrep; do
11930    for ac_exec_ext in '' $ac_executable_extensions; do
11931      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11932      as_fn_executable_p "$ac_path_EGREP" || continue
11933# Check for GNU ac_path_EGREP and select it if it is found.
11934  # Check for GNU $ac_path_EGREP
11935case `"$ac_path_EGREP" --version 2>&1` in
11936*GNU*)
11937  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11938*)
11939  ac_count=0
11940  $as_echo_n 0123456789 >"conftest.in"
11941  while :
11942  do
11943    cat "conftest.in" "conftest.in" >"conftest.tmp"
11944    mv "conftest.tmp" "conftest.in"
11945    cp "conftest.in" "conftest.nl"
11946    $as_echo 'EGREP' >> "conftest.nl"
11947    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11948    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11949    as_fn_arith $ac_count + 1 && ac_count=$as_val
11950    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11951      # Best one so far, save it but keep looking for a better one
11952      ac_cv_path_EGREP="$ac_path_EGREP"
11953      ac_path_EGREP_max=$ac_count
11954    fi
11955    # 10*(2^10) chars as input seems more than enough
11956    test $ac_count -gt 10 && break
11957  done
11958  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11959esac
11960
11961      $ac_path_EGREP_found && break 3
11962    done
11963  done
11964  done
11965IFS=$as_save_IFS
11966  if test -z "$ac_cv_path_EGREP"; then
11967    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11968  fi
11969else
11970  ac_cv_path_EGREP=$EGREP
11971fi
11972
11973   fi
11974fi
11975{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11976$as_echo "$ac_cv_path_EGREP" >&6; }
11977 EGREP="$ac_cv_path_EGREP"
11978
11979
11980    else
11981      # If it succeeded, then it was overridden by the user. We will use it
11982      # for the tool.
11983
11984      # First remove it from the list of overridden variables, so we can test
11985      # for unknown variables in the end.
11986      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11987
11988      # Check if the provided tool contains a complete path.
11989      tool_specified="$EGREP"
11990      tool_basename="${tool_specified##*/}"
11991      if test "x$tool_basename" = "x$tool_specified"; then
11992        # A command without a complete path is provided, search $PATH.
11993        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5
11994$as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;}
11995        # Extract the first word of "$tool_basename", so it can be a program name with args.
11996set dummy $tool_basename; ac_word=$2
11997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11998$as_echo_n "checking for $ac_word... " >&6; }
11999if ${ac_cv_path_EGREP+:} false; then :
12000  $as_echo_n "(cached) " >&6
12001else
12002  case $EGREP in
12003  [\\/]* | ?:[\\/]*)
12004  ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
12005  ;;
12006  *)
12007  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12008for as_dir in $PATH
12009do
12010  IFS=$as_save_IFS
12011  test -z "$as_dir" && as_dir=.
12012    for ac_exec_ext in '' $ac_executable_extensions; do
12013  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12014    ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
12015    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12016    break 2
12017  fi
12018done
12019  done
12020IFS=$as_save_IFS
12021
12022  ;;
12023esac
12024fi
12025EGREP=$ac_cv_path_EGREP
12026if test -n "$EGREP"; then
12027  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
12028$as_echo "$EGREP" >&6; }
12029else
12030  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12031$as_echo "no" >&6; }
12032fi
12033
12034
12035        if test "x$EGREP" = x; then
12036          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12037        fi
12038      else
12039        # Otherwise we believe it is a complete path. Use it as it is.
12040        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5
12041$as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;}
12042        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5
12043$as_echo_n "checking for EGREP... " >&6; }
12044        if test ! -x "$tool_specified"; then
12045          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12046$as_echo "not found" >&6; }
12047          as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12048        fi
12049        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12050$as_echo "$tool_specified" >&6; }
12051      fi
12052    fi
12053  fi
12054
12055
12056  if test "x$EGREP" = x; then
12057    as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5
12058  fi
12059
12060
12061
12062
12063  # Publish this variable in the help.
12064
12065
12066  if test "x$FGREP" = x; then
12067    # The variable is not set by user, try to locate tool using the code snippet
12068    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12069$as_echo_n "checking for fgrep... " >&6; }
12070if ${ac_cv_path_FGREP+:} false; then :
12071  $as_echo_n "(cached) " >&6
12072else
12073  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12074   then ac_cv_path_FGREP="$GREP -F"
12075   else
12076     if test -z "$FGREP"; then
12077  ac_path_FGREP_found=false
12078  # Loop through the user's path and test for each of PROGNAME-LIST
12079  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12080for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12081do
12082  IFS=$as_save_IFS
12083  test -z "$as_dir" && as_dir=.
12084    for ac_prog in fgrep; do
12085    for ac_exec_ext in '' $ac_executable_extensions; do
12086      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12087      as_fn_executable_p "$ac_path_FGREP" || continue
12088# Check for GNU ac_path_FGREP and select it if it is found.
12089  # Check for GNU $ac_path_FGREP
12090case `"$ac_path_FGREP" --version 2>&1` in
12091*GNU*)
12092  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12093*)
12094  ac_count=0
12095  $as_echo_n 0123456789 >"conftest.in"
12096  while :
12097  do
12098    cat "conftest.in" "conftest.in" >"conftest.tmp"
12099    mv "conftest.tmp" "conftest.in"
12100    cp "conftest.in" "conftest.nl"
12101    $as_echo 'FGREP' >> "conftest.nl"
12102    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12103    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12104    as_fn_arith $ac_count + 1 && ac_count=$as_val
12105    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12106      # Best one so far, save it but keep looking for a better one
12107      ac_cv_path_FGREP="$ac_path_FGREP"
12108      ac_path_FGREP_max=$ac_count
12109    fi
12110    # 10*(2^10) chars as input seems more than enough
12111    test $ac_count -gt 10 && break
12112  done
12113  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12114esac
12115
12116      $ac_path_FGREP_found && break 3
12117    done
12118  done
12119  done
12120IFS=$as_save_IFS
12121  if test -z "$ac_cv_path_FGREP"; then
12122    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12123  fi
12124else
12125  ac_cv_path_FGREP=$FGREP
12126fi
12127
12128   fi
12129fi
12130{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12131$as_echo "$ac_cv_path_FGREP" >&6; }
12132 FGREP="$ac_cv_path_FGREP"
12133
12134
12135  else
12136    # The variable is set, but is it from the command line or the environment?
12137
12138    # Try to remove the string !FGREP! from our list.
12139    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/}
12140    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12141      # If it failed, the variable was not from the command line. Ignore it,
12142      # but warn the user (except for BASH, which is always set by the calling BASH).
12143      if test "xFGREP" != xBASH; then
12144        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5
12145$as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;}
12146      fi
12147      # Try to locate tool using the code snippet
12148      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12149$as_echo_n "checking for fgrep... " >&6; }
12150if ${ac_cv_path_FGREP+:} false; then :
12151  $as_echo_n "(cached) " >&6
12152else
12153  if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12154   then ac_cv_path_FGREP="$GREP -F"
12155   else
12156     if test -z "$FGREP"; then
12157  ac_path_FGREP_found=false
12158  # Loop through the user's path and test for each of PROGNAME-LIST
12159  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12160for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12161do
12162  IFS=$as_save_IFS
12163  test -z "$as_dir" && as_dir=.
12164    for ac_prog in fgrep; do
12165    for ac_exec_ext in '' $ac_executable_extensions; do
12166      ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12167      as_fn_executable_p "$ac_path_FGREP" || continue
12168# Check for GNU ac_path_FGREP and select it if it is found.
12169  # Check for GNU $ac_path_FGREP
12170case `"$ac_path_FGREP" --version 2>&1` in
12171*GNU*)
12172  ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12173*)
12174  ac_count=0
12175  $as_echo_n 0123456789 >"conftest.in"
12176  while :
12177  do
12178    cat "conftest.in" "conftest.in" >"conftest.tmp"
12179    mv "conftest.tmp" "conftest.in"
12180    cp "conftest.in" "conftest.nl"
12181    $as_echo 'FGREP' >> "conftest.nl"
12182    "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12183    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12184    as_fn_arith $ac_count + 1 && ac_count=$as_val
12185    if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12186      # Best one so far, save it but keep looking for a better one
12187      ac_cv_path_FGREP="$ac_path_FGREP"
12188      ac_path_FGREP_max=$ac_count
12189    fi
12190    # 10*(2^10) chars as input seems more than enough
12191    test $ac_count -gt 10 && break
12192  done
12193  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12194esac
12195
12196      $ac_path_FGREP_found && break 3
12197    done
12198  done
12199  done
12200IFS=$as_save_IFS
12201  if test -z "$ac_cv_path_FGREP"; then
12202    as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12203  fi
12204else
12205  ac_cv_path_FGREP=$FGREP
12206fi
12207
12208   fi
12209fi
12210{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12211$as_echo "$ac_cv_path_FGREP" >&6; }
12212 FGREP="$ac_cv_path_FGREP"
12213
12214
12215    else
12216      # If it succeeded, then it was overridden by the user. We will use it
12217      # for the tool.
12218
12219      # First remove it from the list of overridden variables, so we can test
12220      # for unknown variables in the end.
12221      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12222
12223      # Check if the provided tool contains a complete path.
12224      tool_specified="$FGREP"
12225      tool_basename="${tool_specified##*/}"
12226      if test "x$tool_basename" = "x$tool_specified"; then
12227        # A command without a complete path is provided, search $PATH.
12228        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5
12229$as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;}
12230        # Extract the first word of "$tool_basename", so it can be a program name with args.
12231set dummy $tool_basename; ac_word=$2
12232{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12233$as_echo_n "checking for $ac_word... " >&6; }
12234if ${ac_cv_path_FGREP+:} false; then :
12235  $as_echo_n "(cached) " >&6
12236else
12237  case $FGREP in
12238  [\\/]* | ?:[\\/]*)
12239  ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
12240  ;;
12241  *)
12242  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12243for as_dir in $PATH
12244do
12245  IFS=$as_save_IFS
12246  test -z "$as_dir" && as_dir=.
12247    for ac_exec_ext in '' $ac_executable_extensions; do
12248  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12249    ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext"
12250    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12251    break 2
12252  fi
12253done
12254  done
12255IFS=$as_save_IFS
12256
12257  ;;
12258esac
12259fi
12260FGREP=$ac_cv_path_FGREP
12261if test -n "$FGREP"; then
12262  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5
12263$as_echo "$FGREP" >&6; }
12264else
12265  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12266$as_echo "no" >&6; }
12267fi
12268
12269
12270        if test "x$FGREP" = x; then
12271          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12272        fi
12273      else
12274        # Otherwise we believe it is a complete path. Use it as it is.
12275        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5
12276$as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;}
12277        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5
12278$as_echo_n "checking for FGREP... " >&6; }
12279        if test ! -x "$tool_specified"; then
12280          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12281$as_echo "not found" >&6; }
12282          as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12283        fi
12284        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12285$as_echo "$tool_specified" >&6; }
12286      fi
12287    fi
12288  fi
12289
12290
12291  if test "x$FGREP" = x; then
12292    as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5
12293  fi
12294
12295
12296
12297
12298  # Publish this variable in the help.
12299
12300
12301  if test "x$SED" = x; then
12302    # The variable is not set by user, try to locate tool using the code snippet
12303    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12304$as_echo_n "checking for a sed that does not truncate output... " >&6; }
12305if ${ac_cv_path_SED+:} false; then :
12306  $as_echo_n "(cached) " >&6
12307else
12308            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12309     for ac_i in 1 2 3 4 5 6 7; do
12310       ac_script="$ac_script$as_nl$ac_script"
12311     done
12312     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12313     { ac_script=; unset ac_script;}
12314     if test -z "$SED"; then
12315  ac_path_SED_found=false
12316  # Loop through the user's path and test for each of PROGNAME-LIST
12317  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12318for as_dir in $PATH
12319do
12320  IFS=$as_save_IFS
12321  test -z "$as_dir" && as_dir=.
12322    for ac_prog in sed gsed; do
12323    for ac_exec_ext in '' $ac_executable_extensions; do
12324      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12325      as_fn_executable_p "$ac_path_SED" || continue
12326# Check for GNU ac_path_SED and select it if it is found.
12327  # Check for GNU $ac_path_SED
12328case `"$ac_path_SED" --version 2>&1` in
12329*GNU*)
12330  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12331*)
12332  ac_count=0
12333  $as_echo_n 0123456789 >"conftest.in"
12334  while :
12335  do
12336    cat "conftest.in" "conftest.in" >"conftest.tmp"
12337    mv "conftest.tmp" "conftest.in"
12338    cp "conftest.in" "conftest.nl"
12339    $as_echo '' >> "conftest.nl"
12340    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12341    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12342    as_fn_arith $ac_count + 1 && ac_count=$as_val
12343    if test $ac_count -gt ${ac_path_SED_max-0}; then
12344      # Best one so far, save it but keep looking for a better one
12345      ac_cv_path_SED="$ac_path_SED"
12346      ac_path_SED_max=$ac_count
12347    fi
12348    # 10*(2^10) chars as input seems more than enough
12349    test $ac_count -gt 10 && break
12350  done
12351  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12352esac
12353
12354      $ac_path_SED_found && break 3
12355    done
12356  done
12357  done
12358IFS=$as_save_IFS
12359  if test -z "$ac_cv_path_SED"; then
12360    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12361  fi
12362else
12363  ac_cv_path_SED=$SED
12364fi
12365
12366fi
12367{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12368$as_echo "$ac_cv_path_SED" >&6; }
12369 SED="$ac_cv_path_SED"
12370  rm -f conftest.sed
12371
12372  else
12373    # The variable is set, but is it from the command line or the environment?
12374
12375    # Try to remove the string !SED! from our list.
12376    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/}
12377    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12378      # If it failed, the variable was not from the command line. Ignore it,
12379      # but warn the user (except for BASH, which is always set by the calling BASH).
12380      if test "xSED" != xBASH; then
12381        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5
12382$as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;}
12383      fi
12384      # Try to locate tool using the code snippet
12385      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12386$as_echo_n "checking for a sed that does not truncate output... " >&6; }
12387if ${ac_cv_path_SED+:} false; then :
12388  $as_echo_n "(cached) " >&6
12389else
12390            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12391     for ac_i in 1 2 3 4 5 6 7; do
12392       ac_script="$ac_script$as_nl$ac_script"
12393     done
12394     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12395     { ac_script=; unset ac_script;}
12396     if test -z "$SED"; then
12397  ac_path_SED_found=false
12398  # Loop through the user's path and test for each of PROGNAME-LIST
12399  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12400for as_dir in $PATH
12401do
12402  IFS=$as_save_IFS
12403  test -z "$as_dir" && as_dir=.
12404    for ac_prog in sed gsed; do
12405    for ac_exec_ext in '' $ac_executable_extensions; do
12406      ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12407      as_fn_executable_p "$ac_path_SED" || continue
12408# Check for GNU ac_path_SED and select it if it is found.
12409  # Check for GNU $ac_path_SED
12410case `"$ac_path_SED" --version 2>&1` in
12411*GNU*)
12412  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12413*)
12414  ac_count=0
12415  $as_echo_n 0123456789 >"conftest.in"
12416  while :
12417  do
12418    cat "conftest.in" "conftest.in" >"conftest.tmp"
12419    mv "conftest.tmp" "conftest.in"
12420    cp "conftest.in" "conftest.nl"
12421    $as_echo '' >> "conftest.nl"
12422    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12423    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12424    as_fn_arith $ac_count + 1 && ac_count=$as_val
12425    if test $ac_count -gt ${ac_path_SED_max-0}; then
12426      # Best one so far, save it but keep looking for a better one
12427      ac_cv_path_SED="$ac_path_SED"
12428      ac_path_SED_max=$ac_count
12429    fi
12430    # 10*(2^10) chars as input seems more than enough
12431    test $ac_count -gt 10 && break
12432  done
12433  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12434esac
12435
12436      $ac_path_SED_found && break 3
12437    done
12438  done
12439  done
12440IFS=$as_save_IFS
12441  if test -z "$ac_cv_path_SED"; then
12442    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12443  fi
12444else
12445  ac_cv_path_SED=$SED
12446fi
12447
12448fi
12449{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12450$as_echo "$ac_cv_path_SED" >&6; }
12451 SED="$ac_cv_path_SED"
12452  rm -f conftest.sed
12453
12454    else
12455      # If it succeeded, then it was overridden by the user. We will use it
12456      # for the tool.
12457
12458      # First remove it from the list of overridden variables, so we can test
12459      # for unknown variables in the end.
12460      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12461
12462      # Check if the provided tool contains a complete path.
12463      tool_specified="$SED"
12464      tool_basename="${tool_specified##*/}"
12465      if test "x$tool_basename" = "x$tool_specified"; then
12466        # A command without a complete path is provided, search $PATH.
12467        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5
12468$as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;}
12469        # Extract the first word of "$tool_basename", so it can be a program name with args.
12470set dummy $tool_basename; ac_word=$2
12471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12472$as_echo_n "checking for $ac_word... " >&6; }
12473if ${ac_cv_path_SED+:} false; then :
12474  $as_echo_n "(cached) " >&6
12475else
12476  case $SED in
12477  [\\/]* | ?:[\\/]*)
12478  ac_cv_path_SED="$SED" # Let the user override the test with a path.
12479  ;;
12480  *)
12481  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12482for as_dir in $PATH
12483do
12484  IFS=$as_save_IFS
12485  test -z "$as_dir" && as_dir=.
12486    for ac_exec_ext in '' $ac_executable_extensions; do
12487  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12488    ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
12489    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12490    break 2
12491  fi
12492done
12493  done
12494IFS=$as_save_IFS
12495
12496  ;;
12497esac
12498fi
12499SED=$ac_cv_path_SED
12500if test -n "$SED"; then
12501  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
12502$as_echo "$SED" >&6; }
12503else
12504  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12505$as_echo "no" >&6; }
12506fi
12507
12508
12509        if test "x$SED" = x; then
12510          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12511        fi
12512      else
12513        # Otherwise we believe it is a complete path. Use it as it is.
12514        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5
12515$as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;}
12516        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5
12517$as_echo_n "checking for SED... " >&6; }
12518        if test ! -x "$tool_specified"; then
12519          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12520$as_echo "not found" >&6; }
12521          as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5
12522        fi
12523        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12524$as_echo "$tool_specified" >&6; }
12525      fi
12526    fi
12527  fi
12528
12529
12530  if test "x$SED" = x; then
12531    as_fn_error $? "Could not find required tool for SED" "$LINENO" 5
12532  fi
12533
12534
12535
12536  # Always force rm.
12537  RM="$RM -f"
12538
12539  # pwd behaves differently on various platforms and some don't support the -L flag.
12540  # Always use the bash builtin pwd to get uniform behavior.
12541  THEPWDCMD=pwd
12542
12543  # These are not required on all platforms
12544
12545
12546  # Publish this variable in the help.
12547
12548
12549  if test "x$CYGPATH" = x; then
12550    # The variable is not set by user, try to locate tool using the code snippet
12551    for ac_prog in cygpath
12552do
12553  # Extract the first word of "$ac_prog", so it can be a program name with args.
12554set dummy $ac_prog; ac_word=$2
12555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12556$as_echo_n "checking for $ac_word... " >&6; }
12557if ${ac_cv_path_CYGPATH+:} false; then :
12558  $as_echo_n "(cached) " >&6
12559else
12560  case $CYGPATH in
12561  [\\/]* | ?:[\\/]*)
12562  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12563  ;;
12564  *)
12565  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12566for as_dir in $PATH
12567do
12568  IFS=$as_save_IFS
12569  test -z "$as_dir" && as_dir=.
12570    for ac_exec_ext in '' $ac_executable_extensions; do
12571  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12572    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12573    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12574    break 2
12575  fi
12576done
12577  done
12578IFS=$as_save_IFS
12579
12580  ;;
12581esac
12582fi
12583CYGPATH=$ac_cv_path_CYGPATH
12584if test -n "$CYGPATH"; then
12585  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12586$as_echo "$CYGPATH" >&6; }
12587else
12588  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12589$as_echo "no" >&6; }
12590fi
12591
12592
12593  test -n "$CYGPATH" && break
12594done
12595
12596  else
12597    # The variable is set, but is it from the command line or the environment?
12598
12599    # Try to remove the string !CYGPATH! from our list.
12600    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/}
12601    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12602      # If it failed, the variable was not from the command line. Ignore it,
12603      # but warn the user (except for BASH, which is always set by the calling BASH).
12604      if test "xCYGPATH" != xBASH; then
12605        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5
12606$as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;}
12607      fi
12608      # Try to locate tool using the code snippet
12609      for ac_prog in cygpath
12610do
12611  # Extract the first word of "$ac_prog", so it can be a program name with args.
12612set dummy $ac_prog; ac_word=$2
12613{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12614$as_echo_n "checking for $ac_word... " >&6; }
12615if ${ac_cv_path_CYGPATH+:} false; then :
12616  $as_echo_n "(cached) " >&6
12617else
12618  case $CYGPATH in
12619  [\\/]* | ?:[\\/]*)
12620  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12621  ;;
12622  *)
12623  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12624for as_dir in $PATH
12625do
12626  IFS=$as_save_IFS
12627  test -z "$as_dir" && as_dir=.
12628    for ac_exec_ext in '' $ac_executable_extensions; do
12629  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12630    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12631    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12632    break 2
12633  fi
12634done
12635  done
12636IFS=$as_save_IFS
12637
12638  ;;
12639esac
12640fi
12641CYGPATH=$ac_cv_path_CYGPATH
12642if test -n "$CYGPATH"; then
12643  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12644$as_echo "$CYGPATH" >&6; }
12645else
12646  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12647$as_echo "no" >&6; }
12648fi
12649
12650
12651  test -n "$CYGPATH" && break
12652done
12653
12654    else
12655      # If it succeeded, then it was overridden by the user. We will use it
12656      # for the tool.
12657
12658      # First remove it from the list of overridden variables, so we can test
12659      # for unknown variables in the end.
12660      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12661
12662      # Check if the provided tool contains a complete path.
12663      tool_specified="$CYGPATH"
12664      tool_basename="${tool_specified##*/}"
12665      if test "x$tool_basename" = "x$tool_specified"; then
12666        # A command without a complete path is provided, search $PATH.
12667        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5
12668$as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;}
12669        # Extract the first word of "$tool_basename", so it can be a program name with args.
12670set dummy $tool_basename; ac_word=$2
12671{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12672$as_echo_n "checking for $ac_word... " >&6; }
12673if ${ac_cv_path_CYGPATH+:} false; then :
12674  $as_echo_n "(cached) " >&6
12675else
12676  case $CYGPATH in
12677  [\\/]* | ?:[\\/]*)
12678  ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12679  ;;
12680  *)
12681  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12682for as_dir in $PATH
12683do
12684  IFS=$as_save_IFS
12685  test -z "$as_dir" && as_dir=.
12686    for ac_exec_ext in '' $ac_executable_extensions; do
12687  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12688    ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12689    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12690    break 2
12691  fi
12692done
12693  done
12694IFS=$as_save_IFS
12695
12696  ;;
12697esac
12698fi
12699CYGPATH=$ac_cv_path_CYGPATH
12700if test -n "$CYGPATH"; then
12701  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12702$as_echo "$CYGPATH" >&6; }
12703else
12704  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12705$as_echo "no" >&6; }
12706fi
12707
12708
12709        if test "x$CYGPATH" = x; then
12710          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12711        fi
12712      else
12713        # Otherwise we believe it is a complete path. Use it as it is.
12714        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5
12715$as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;}
12716        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5
12717$as_echo_n "checking for CYGPATH... " >&6; }
12718        if test ! -x "$tool_specified"; then
12719          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12720$as_echo "not found" >&6; }
12721          as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5
12722        fi
12723        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12724$as_echo "$tool_specified" >&6; }
12725      fi
12726    fi
12727  fi
12728
12729
12730
12731
12732  # Publish this variable in the help.
12733
12734
12735  if test "x$READLINK" = x; then
12736    # The variable is not set by user, try to locate tool using the code snippet
12737    for ac_prog in greadlink readlink
12738do
12739  # Extract the first word of "$ac_prog", so it can be a program name with args.
12740set dummy $ac_prog; ac_word=$2
12741{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12742$as_echo_n "checking for $ac_word... " >&6; }
12743if ${ac_cv_path_READLINK+:} false; then :
12744  $as_echo_n "(cached) " >&6
12745else
12746  case $READLINK in
12747  [\\/]* | ?:[\\/]*)
12748  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12749  ;;
12750  *)
12751  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12752for as_dir in $PATH
12753do
12754  IFS=$as_save_IFS
12755  test -z "$as_dir" && as_dir=.
12756    for ac_exec_ext in '' $ac_executable_extensions; do
12757  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12758    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12759    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12760    break 2
12761  fi
12762done
12763  done
12764IFS=$as_save_IFS
12765
12766  ;;
12767esac
12768fi
12769READLINK=$ac_cv_path_READLINK
12770if test -n "$READLINK"; then
12771  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12772$as_echo "$READLINK" >&6; }
12773else
12774  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12775$as_echo "no" >&6; }
12776fi
12777
12778
12779  test -n "$READLINK" && break
12780done
12781
12782  else
12783    # The variable is set, but is it from the command line or the environment?
12784
12785    # Try to remove the string !READLINK! from our list.
12786    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/}
12787    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12788      # If it failed, the variable was not from the command line. Ignore it,
12789      # but warn the user (except for BASH, which is always set by the calling BASH).
12790      if test "xREADLINK" != xBASH; then
12791        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5
12792$as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;}
12793      fi
12794      # Try to locate tool using the code snippet
12795      for ac_prog in greadlink readlink
12796do
12797  # Extract the first word of "$ac_prog", so it can be a program name with args.
12798set dummy $ac_prog; ac_word=$2
12799{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12800$as_echo_n "checking for $ac_word... " >&6; }
12801if ${ac_cv_path_READLINK+:} false; then :
12802  $as_echo_n "(cached) " >&6
12803else
12804  case $READLINK in
12805  [\\/]* | ?:[\\/]*)
12806  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12807  ;;
12808  *)
12809  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12810for as_dir in $PATH
12811do
12812  IFS=$as_save_IFS
12813  test -z "$as_dir" && as_dir=.
12814    for ac_exec_ext in '' $ac_executable_extensions; do
12815  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12816    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12817    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12818    break 2
12819  fi
12820done
12821  done
12822IFS=$as_save_IFS
12823
12824  ;;
12825esac
12826fi
12827READLINK=$ac_cv_path_READLINK
12828if test -n "$READLINK"; then
12829  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12830$as_echo "$READLINK" >&6; }
12831else
12832  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12833$as_echo "no" >&6; }
12834fi
12835
12836
12837  test -n "$READLINK" && break
12838done
12839
12840    else
12841      # If it succeeded, then it was overridden by the user. We will use it
12842      # for the tool.
12843
12844      # First remove it from the list of overridden variables, so we can test
12845      # for unknown variables in the end.
12846      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12847
12848      # Check if the provided tool contains a complete path.
12849      tool_specified="$READLINK"
12850      tool_basename="${tool_specified##*/}"
12851      if test "x$tool_basename" = "x$tool_specified"; then
12852        # A command without a complete path is provided, search $PATH.
12853        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5
12854$as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;}
12855        # Extract the first word of "$tool_basename", so it can be a program name with args.
12856set dummy $tool_basename; ac_word=$2
12857{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12858$as_echo_n "checking for $ac_word... " >&6; }
12859if ${ac_cv_path_READLINK+:} false; then :
12860  $as_echo_n "(cached) " >&6
12861else
12862  case $READLINK in
12863  [\\/]* | ?:[\\/]*)
12864  ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12865  ;;
12866  *)
12867  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12868for as_dir in $PATH
12869do
12870  IFS=$as_save_IFS
12871  test -z "$as_dir" && as_dir=.
12872    for ac_exec_ext in '' $ac_executable_extensions; do
12873  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12874    ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12875    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12876    break 2
12877  fi
12878done
12879  done
12880IFS=$as_save_IFS
12881
12882  ;;
12883esac
12884fi
12885READLINK=$ac_cv_path_READLINK
12886if test -n "$READLINK"; then
12887  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12888$as_echo "$READLINK" >&6; }
12889else
12890  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12891$as_echo "no" >&6; }
12892fi
12893
12894
12895        if test "x$READLINK" = x; then
12896          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12897        fi
12898      else
12899        # Otherwise we believe it is a complete path. Use it as it is.
12900        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5
12901$as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;}
12902        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5
12903$as_echo_n "checking for READLINK... " >&6; }
12904        if test ! -x "$tool_specified"; then
12905          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12906$as_echo "not found" >&6; }
12907          as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5
12908        fi
12909        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12910$as_echo "$tool_specified" >&6; }
12911      fi
12912    fi
12913  fi
12914
12915
12916
12917
12918  # Publish this variable in the help.
12919
12920
12921  if test "x$DF" = x; then
12922    # The variable is not set by user, try to locate tool using the code snippet
12923    for ac_prog in df
12924do
12925  # Extract the first word of "$ac_prog", so it can be a program name with args.
12926set dummy $ac_prog; ac_word=$2
12927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12928$as_echo_n "checking for $ac_word... " >&6; }
12929if ${ac_cv_path_DF+:} false; then :
12930  $as_echo_n "(cached) " >&6
12931else
12932  case $DF in
12933  [\\/]* | ?:[\\/]*)
12934  ac_cv_path_DF="$DF" # Let the user override the test with a path.
12935  ;;
12936  *)
12937  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12938for as_dir in $PATH
12939do
12940  IFS=$as_save_IFS
12941  test -z "$as_dir" && as_dir=.
12942    for ac_exec_ext in '' $ac_executable_extensions; do
12943  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12944    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12945    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12946    break 2
12947  fi
12948done
12949  done
12950IFS=$as_save_IFS
12951
12952  ;;
12953esac
12954fi
12955DF=$ac_cv_path_DF
12956if test -n "$DF"; then
12957  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12958$as_echo "$DF" >&6; }
12959else
12960  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12961$as_echo "no" >&6; }
12962fi
12963
12964
12965  test -n "$DF" && break
12966done
12967
12968  else
12969    # The variable is set, but is it from the command line or the environment?
12970
12971    # Try to remove the string !DF! from our list.
12972    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/}
12973    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12974      # If it failed, the variable was not from the command line. Ignore it,
12975      # but warn the user (except for BASH, which is always set by the calling BASH).
12976      if test "xDF" != xBASH; then
12977        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5
12978$as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;}
12979      fi
12980      # Try to locate tool using the code snippet
12981      for ac_prog in df
12982do
12983  # Extract the first word of "$ac_prog", so it can be a program name with args.
12984set dummy $ac_prog; ac_word=$2
12985{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12986$as_echo_n "checking for $ac_word... " >&6; }
12987if ${ac_cv_path_DF+:} false; then :
12988  $as_echo_n "(cached) " >&6
12989else
12990  case $DF in
12991  [\\/]* | ?:[\\/]*)
12992  ac_cv_path_DF="$DF" # Let the user override the test with a path.
12993  ;;
12994  *)
12995  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12996for as_dir in $PATH
12997do
12998  IFS=$as_save_IFS
12999  test -z "$as_dir" && as_dir=.
13000    for ac_exec_ext in '' $ac_executable_extensions; do
13001  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13002    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13003    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13004    break 2
13005  fi
13006done
13007  done
13008IFS=$as_save_IFS
13009
13010  ;;
13011esac
13012fi
13013DF=$ac_cv_path_DF
13014if test -n "$DF"; then
13015  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13016$as_echo "$DF" >&6; }
13017else
13018  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13019$as_echo "no" >&6; }
13020fi
13021
13022
13023  test -n "$DF" && break
13024done
13025
13026    else
13027      # If it succeeded, then it was overridden by the user. We will use it
13028      # for the tool.
13029
13030      # First remove it from the list of overridden variables, so we can test
13031      # for unknown variables in the end.
13032      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13033
13034      # Check if the provided tool contains a complete path.
13035      tool_specified="$DF"
13036      tool_basename="${tool_specified##*/}"
13037      if test "x$tool_basename" = "x$tool_specified"; then
13038        # A command without a complete path is provided, search $PATH.
13039        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5
13040$as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;}
13041        # Extract the first word of "$tool_basename", so it can be a program name with args.
13042set dummy $tool_basename; ac_word=$2
13043{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13044$as_echo_n "checking for $ac_word... " >&6; }
13045if ${ac_cv_path_DF+:} false; then :
13046  $as_echo_n "(cached) " >&6
13047else
13048  case $DF in
13049  [\\/]* | ?:[\\/]*)
13050  ac_cv_path_DF="$DF" # Let the user override the test with a path.
13051  ;;
13052  *)
13053  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13054for as_dir in $PATH
13055do
13056  IFS=$as_save_IFS
13057  test -z "$as_dir" && as_dir=.
13058    for ac_exec_ext in '' $ac_executable_extensions; do
13059  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13060    ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
13061    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13062    break 2
13063  fi
13064done
13065  done
13066IFS=$as_save_IFS
13067
13068  ;;
13069esac
13070fi
13071DF=$ac_cv_path_DF
13072if test -n "$DF"; then
13073  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
13074$as_echo "$DF" >&6; }
13075else
13076  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13077$as_echo "no" >&6; }
13078fi
13079
13080
13081        if test "x$DF" = x; then
13082          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13083        fi
13084      else
13085        # Otherwise we believe it is a complete path. Use it as it is.
13086        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5
13087$as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;}
13088        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5
13089$as_echo_n "checking for DF... " >&6; }
13090        if test ! -x "$tool_specified"; then
13091          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13092$as_echo "not found" >&6; }
13093          as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5
13094        fi
13095        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13096$as_echo "$tool_specified" >&6; }
13097      fi
13098    fi
13099  fi
13100
13101
13102
13103
13104  # Publish this variable in the help.
13105
13106
13107  if test "x$SETFILE" = x; then
13108    # The variable is not set by user, try to locate tool using the code snippet
13109    for ac_prog in SetFile
13110do
13111  # Extract the first word of "$ac_prog", so it can be a program name with args.
13112set dummy $ac_prog; ac_word=$2
13113{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13114$as_echo_n "checking for $ac_word... " >&6; }
13115if ${ac_cv_path_SETFILE+:} false; then :
13116  $as_echo_n "(cached) " >&6
13117else
13118  case $SETFILE in
13119  [\\/]* | ?:[\\/]*)
13120  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13121  ;;
13122  *)
13123  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13124for as_dir in $PATH
13125do
13126  IFS=$as_save_IFS
13127  test -z "$as_dir" && as_dir=.
13128    for ac_exec_ext in '' $ac_executable_extensions; do
13129  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13130    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13131    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13132    break 2
13133  fi
13134done
13135  done
13136IFS=$as_save_IFS
13137
13138  ;;
13139esac
13140fi
13141SETFILE=$ac_cv_path_SETFILE
13142if test -n "$SETFILE"; then
13143  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13144$as_echo "$SETFILE" >&6; }
13145else
13146  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13147$as_echo "no" >&6; }
13148fi
13149
13150
13151  test -n "$SETFILE" && break
13152done
13153
13154  else
13155    # The variable is set, but is it from the command line or the environment?
13156
13157    # Try to remove the string !SETFILE! from our list.
13158    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/}
13159    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13160      # If it failed, the variable was not from the command line. Ignore it,
13161      # but warn the user (except for BASH, which is always set by the calling BASH).
13162      if test "xSETFILE" != xBASH; then
13163        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5
13164$as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;}
13165      fi
13166      # Try to locate tool using the code snippet
13167      for ac_prog in SetFile
13168do
13169  # Extract the first word of "$ac_prog", so it can be a program name with args.
13170set dummy $ac_prog; ac_word=$2
13171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13172$as_echo_n "checking for $ac_word... " >&6; }
13173if ${ac_cv_path_SETFILE+:} false; then :
13174  $as_echo_n "(cached) " >&6
13175else
13176  case $SETFILE in
13177  [\\/]* | ?:[\\/]*)
13178  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13179  ;;
13180  *)
13181  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13182for as_dir in $PATH
13183do
13184  IFS=$as_save_IFS
13185  test -z "$as_dir" && as_dir=.
13186    for ac_exec_ext in '' $ac_executable_extensions; do
13187  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13188    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13189    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13190    break 2
13191  fi
13192done
13193  done
13194IFS=$as_save_IFS
13195
13196  ;;
13197esac
13198fi
13199SETFILE=$ac_cv_path_SETFILE
13200if test -n "$SETFILE"; then
13201  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13202$as_echo "$SETFILE" >&6; }
13203else
13204  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13205$as_echo "no" >&6; }
13206fi
13207
13208
13209  test -n "$SETFILE" && break
13210done
13211
13212    else
13213      # If it succeeded, then it was overridden by the user. We will use it
13214      # for the tool.
13215
13216      # First remove it from the list of overridden variables, so we can test
13217      # for unknown variables in the end.
13218      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13219
13220      # Check if the provided tool contains a complete path.
13221      tool_specified="$SETFILE"
13222      tool_basename="${tool_specified##*/}"
13223      if test "x$tool_basename" = "x$tool_specified"; then
13224        # A command without a complete path is provided, search $PATH.
13225        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5
13226$as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;}
13227        # Extract the first word of "$tool_basename", so it can be a program name with args.
13228set dummy $tool_basename; ac_word=$2
13229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13230$as_echo_n "checking for $ac_word... " >&6; }
13231if ${ac_cv_path_SETFILE+:} false; then :
13232  $as_echo_n "(cached) " >&6
13233else
13234  case $SETFILE in
13235  [\\/]* | ?:[\\/]*)
13236  ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13237  ;;
13238  *)
13239  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13240for as_dir in $PATH
13241do
13242  IFS=$as_save_IFS
13243  test -z "$as_dir" && as_dir=.
13244    for ac_exec_ext in '' $ac_executable_extensions; do
13245  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13246    ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13247    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13248    break 2
13249  fi
13250done
13251  done
13252IFS=$as_save_IFS
13253
13254  ;;
13255esac
13256fi
13257SETFILE=$ac_cv_path_SETFILE
13258if test -n "$SETFILE"; then
13259  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13260$as_echo "$SETFILE" >&6; }
13261else
13262  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13263$as_echo "no" >&6; }
13264fi
13265
13266
13267        if test "x$SETFILE" = x; then
13268          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13269        fi
13270      else
13271        # Otherwise we believe it is a complete path. Use it as it is.
13272        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5
13273$as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;}
13274        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5
13275$as_echo_n "checking for SETFILE... " >&6; }
13276        if test ! -x "$tool_specified"; then
13277          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13278$as_echo "not found" >&6; }
13279          as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5
13280        fi
13281        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13282$as_echo "$tool_specified" >&6; }
13283      fi
13284    fi
13285  fi
13286
13287
13288
13289
13290# Now we can determine OpenJDK build and target platforms. This is required to
13291# have early on.
13292# Make sure we can run config.sub.
13293$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
13294  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
13295
13296{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
13297$as_echo_n "checking build system type... " >&6; }
13298if ${ac_cv_build+:} false; then :
13299  $as_echo_n "(cached) " >&6
13300else
13301  ac_build_alias=$build_alias
13302test "x$ac_build_alias" = x &&
13303  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
13304test "x$ac_build_alias" = x &&
13305  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
13306ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
13307  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
13308
13309fi
13310{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
13311$as_echo "$ac_cv_build" >&6; }
13312case $ac_cv_build in
13313*-*-*) ;;
13314*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
13315esac
13316build=$ac_cv_build
13317ac_save_IFS=$IFS; IFS='-'
13318set x $ac_cv_build
13319shift
13320build_cpu=$1
13321build_vendor=$2
13322shift; shift
13323# Remember, the first character of IFS is used to create $*,
13324# except with old shells:
13325build_os=$*
13326IFS=$ac_save_IFS
13327case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
13328
13329
13330{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
13331$as_echo_n "checking host system type... " >&6; }
13332if ${ac_cv_host+:} false; then :
13333  $as_echo_n "(cached) " >&6
13334else
13335  if test "x$host_alias" = x; then
13336  ac_cv_host=$ac_cv_build
13337else
13338  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
13339    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
13340fi
13341
13342fi
13343{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
13344$as_echo "$ac_cv_host" >&6; }
13345case $ac_cv_host in
13346*-*-*) ;;
13347*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
13348esac
13349host=$ac_cv_host
13350ac_save_IFS=$IFS; IFS='-'
13351set x $ac_cv_host
13352shift
13353host_cpu=$1
13354host_vendor=$2
13355shift; shift
13356# Remember, the first character of IFS is used to create $*,
13357# except with old shells:
13358host_os=$*
13359IFS=$ac_save_IFS
13360case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
13361
13362
13363{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
13364$as_echo_n "checking target system type... " >&6; }
13365if ${ac_cv_target+:} false; then :
13366  $as_echo_n "(cached) " >&6
13367else
13368  if test "x$target_alias" = x; then
13369  ac_cv_target=$ac_cv_host
13370else
13371  ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
13372    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
13373fi
13374
13375fi
13376{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
13377$as_echo "$ac_cv_target" >&6; }
13378case $ac_cv_target in
13379*-*-*) ;;
13380*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
13381esac
13382target=$ac_cv_target
13383ac_save_IFS=$IFS; IFS='-'
13384set x $ac_cv_target
13385shift
13386target_cpu=$1
13387target_vendor=$2
13388shift; shift
13389# Remember, the first character of IFS is used to create $*,
13390# except with old shells:
13391target_os=$*
13392IFS=$ac_save_IFS
13393case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
13394
13395
13396# The aliases save the names the user supplied, while $host etc.
13397# will get canonicalized.
13398test -n "$target_alias" &&
13399  test "$program_prefix$program_suffix$program_transform_name" = \
13400    NONENONEs,x,x, &&
13401  program_prefix=${target_alias}-
13402
13403  # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target"
13404  # is confusing; it assumes you are cross-compiling a cross-compiler (!)  and "target" is thus the target of the
13405  # product you're building. The target of this build is called "host". Since this is confusing to most people, we
13406  # have not adopted that system, but use "target" as the platform we are building for. In some places though we need
13407  # to use the configure naming style.
13408
13409
13410
13411
13412
13413  # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME
13414  # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME
13415  # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build,
13416  # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME.
13417  OPENJDK_TARGET_AUTOCONF_NAME="$host"
13418  OPENJDK_BUILD_AUTOCONF_NAME="$build"
13419
13420
13421
13422  # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13423
13424  case "$build_os" in
13425    *linux*)
13426      VAR_OS=linux
13427      VAR_OS_API=posix
13428      VAR_OS_ENV=linux
13429      ;;
13430    *solaris*)
13431      VAR_OS=solaris
13432      VAR_OS_API=posix
13433      VAR_OS_ENV=solaris
13434      ;;
13435    *darwin*)
13436      VAR_OS=macosx
13437      VAR_OS_API=posix
13438      VAR_OS_ENV=macosx
13439      ;;
13440    *bsd*)
13441      VAR_OS=bsd
13442      VAR_OS_API=posix
13443      VAR_OS_ENV=bsd
13444      ;;
13445    *cygwin*)
13446      VAR_OS=windows
13447      VAR_OS_API=winapi
13448      VAR_OS_ENV=windows.cygwin
13449      ;;
13450    *mingw*)
13451      VAR_OS=windows
13452      VAR_OS_API=winapi
13453      VAR_OS_ENV=windows.msys
13454      ;;
13455    *aix*)
13456      VAR_OS=aix
13457      VAR_OS_API=posix
13458      VAR_OS_ENV=aix
13459      ;;
13460    *)
13461      as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
13462      ;;
13463  esac
13464
13465
13466  # First argument is the cpu name from the trip/quad
13467  case "$build_cpu" in
13468    x86_64)
13469      VAR_CPU=x86_64
13470      VAR_CPU_ARCH=x86
13471      VAR_CPU_BITS=64
13472      VAR_CPU_ENDIAN=little
13473      ;;
13474    i?86)
13475      VAR_CPU=x86
13476      VAR_CPU_ARCH=x86
13477      VAR_CPU_BITS=32
13478      VAR_CPU_ENDIAN=little
13479      ;;
13480    arm*)
13481      VAR_CPU=arm
13482      VAR_CPU_ARCH=arm
13483      VAR_CPU_BITS=32
13484      VAR_CPU_ENDIAN=little
13485      ;;
13486    powerpc)
13487      VAR_CPU=ppc
13488      VAR_CPU_ARCH=ppc
13489      VAR_CPU_BITS=32
13490      VAR_CPU_ENDIAN=big
13491      ;;
13492    powerpc64)
13493      VAR_CPU=ppc64
13494      VAR_CPU_ARCH=ppc
13495      VAR_CPU_BITS=64
13496      VAR_CPU_ENDIAN=big
13497      ;;
13498    s390)
13499      VAR_CPU=s390
13500      VAR_CPU_ARCH=s390
13501      VAR_CPU_BITS=32
13502      VAR_CPU_ENDIAN=big
13503      ;;
13504    s390x)
13505      VAR_CPU=s390x
13506      VAR_CPU_ARCH=s390
13507      VAR_CPU_BITS=64
13508      VAR_CPU_ENDIAN=big
13509      ;;
13510    sparc)
13511      VAR_CPU=sparc
13512      VAR_CPU_ARCH=sparc
13513      VAR_CPU_BITS=32
13514      VAR_CPU_ENDIAN=big
13515      ;;
13516    sparcv9)
13517      VAR_CPU=sparcv9
13518      VAR_CPU_ARCH=sparc
13519      VAR_CPU_BITS=64
13520      VAR_CPU_ENDIAN=big
13521      ;;
13522    *)
13523      as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5
13524      ;;
13525  esac
13526
13527  # ..and setup our own variables. (Do this explicitely to facilitate searching)
13528  OPENJDK_BUILD_OS="$VAR_OS"
13529  OPENJDK_BUILD_OS_API="$VAR_OS_API"
13530  OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV"
13531  OPENJDK_BUILD_CPU="$VAR_CPU"
13532  OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH"
13533  OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS"
13534  OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13535
13536
13537
13538
13539
13540
13541
13542  { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5
13543$as_echo_n "checking openjdk-build os-cpu... " >&6; }
13544  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5
13545$as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; }
13546
13547  # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13548
13549  case "$host_os" in
13550    *linux*)
13551      VAR_OS=linux
13552      VAR_OS_API=posix
13553      VAR_OS_ENV=linux
13554      ;;
13555    *solaris*)
13556      VAR_OS=solaris
13557      VAR_OS_API=posix
13558      VAR_OS_ENV=solaris
13559      ;;
13560    *darwin*)
13561      VAR_OS=macosx
13562      VAR_OS_API=posix
13563      VAR_OS_ENV=macosx
13564      ;;
13565    *bsd*)
13566      VAR_OS=bsd
13567      VAR_OS_API=posix
13568      VAR_OS_ENV=bsd
13569      ;;
13570    *cygwin*)
13571      VAR_OS=windows
13572      VAR_OS_API=winapi
13573      VAR_OS_ENV=windows.cygwin
13574      ;;
13575    *mingw*)
13576      VAR_OS=windows
13577      VAR_OS_API=winapi
13578      VAR_OS_ENV=windows.msys
13579      ;;
13580    *aix*)
13581      VAR_OS=aix
13582      VAR_OS_API=posix
13583      VAR_OS_ENV=aix
13584      ;;
13585    *)
13586      as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
13587      ;;
13588  esac
13589
13590
13591  # First argument is the cpu name from the trip/quad
13592  case "$host_cpu" in
13593    x86_64)
13594      VAR_CPU=x86_64
13595      VAR_CPU_ARCH=x86
13596      VAR_CPU_BITS=64
13597      VAR_CPU_ENDIAN=little
13598      ;;
13599    i?86)
13600      VAR_CPU=x86
13601      VAR_CPU_ARCH=x86
13602      VAR_CPU_BITS=32
13603      VAR_CPU_ENDIAN=little
13604      ;;
13605    arm*)
13606      VAR_CPU=arm
13607      VAR_CPU_ARCH=arm
13608      VAR_CPU_BITS=32
13609      VAR_CPU_ENDIAN=little
13610      ;;
13611    powerpc)
13612      VAR_CPU=ppc
13613      VAR_CPU_ARCH=ppc
13614      VAR_CPU_BITS=32
13615      VAR_CPU_ENDIAN=big
13616      ;;
13617    powerpc64)
13618      VAR_CPU=ppc64
13619      VAR_CPU_ARCH=ppc
13620      VAR_CPU_BITS=64
13621      VAR_CPU_ENDIAN=big
13622      ;;
13623    s390)
13624      VAR_CPU=s390
13625      VAR_CPU_ARCH=s390
13626      VAR_CPU_BITS=32
13627      VAR_CPU_ENDIAN=big
13628      ;;
13629    s390x)
13630      VAR_CPU=s390x
13631      VAR_CPU_ARCH=s390
13632      VAR_CPU_BITS=64
13633      VAR_CPU_ENDIAN=big
13634      ;;
13635    sparc)
13636      VAR_CPU=sparc
13637      VAR_CPU_ARCH=sparc
13638      VAR_CPU_BITS=32
13639      VAR_CPU_ENDIAN=big
13640      ;;
13641    sparcv9)
13642      VAR_CPU=sparcv9
13643      VAR_CPU_ARCH=sparc
13644      VAR_CPU_BITS=64
13645      VAR_CPU_ENDIAN=big
13646      ;;
13647    *)
13648      as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5
13649      ;;
13650  esac
13651
13652  # ... and setup our own variables. (Do this explicitely to facilitate searching)
13653  OPENJDK_TARGET_OS="$VAR_OS"
13654  OPENJDK_TARGET_OS_API="$VAR_OS_API"
13655  OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV"
13656  OPENJDK_TARGET_CPU="$VAR_CPU"
13657  OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH"
13658  OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS"
13659  OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13660
13661
13662
13663
13664
13665
13666
13667  { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5
13668$as_echo_n "checking openjdk-target os-cpu... " >&6; }
13669  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5
13670$as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; }
13671
13672
13673
13674# Check whether --with-target-bits was given.
13675if test "${with_target_bits+set}" = set; then :
13676  withval=$with_target_bits;
13677fi
13678
13679
13680  # We have three types of compiles:
13681  # native  == normal compilation, target system == build system
13682  # cross   == traditional cross compilation, target system != build system; special toolchain needed
13683  # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines
13684  #
13685  if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then
13686    # We're doing a proper cross-compilation
13687    COMPILE_TYPE="cross"
13688  else
13689    COMPILE_TYPE="native"
13690  fi
13691
13692  if test "x$with_target_bits" != x; then
13693    if test "x$COMPILE_TYPE" = "xcross"; then
13694      as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5
13695    fi
13696
13697    if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13698      # A reduced build is requested
13699      COMPILE_TYPE="reduced"
13700      OPENJDK_TARGET_CPU_BITS=32
13701      if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
13702        OPENJDK_TARGET_CPU=x86
13703      elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
13704        OPENJDK_TARGET_CPU=sparc
13705      else
13706        as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5
13707      fi
13708    elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
13709      as_fn_error $? "It is not possible to use --with-target-bits=64 on a 32 bit system. Use proper cross-compilation instead." "$LINENO" 5
13710    elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then
13711      { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5
13712$as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;}
13713    else
13714      as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5
13715    fi
13716  fi
13717
13718
13719  { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5
13720$as_echo_n "checking compilation type... " >&6; }
13721  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5
13722$as_echo "$COMPILE_TYPE" >&6; }
13723
13724
13725  if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
13726    REQUIRED_OS_NAME=SunOS
13727    REQUIRED_OS_VERSION=5.10
13728  fi
13729  if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
13730    REQUIRED_OS_NAME=Linux
13731    REQUIRED_OS_VERSION=2.6
13732  fi
13733  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13734    REQUIRED_OS_NAME=Windows
13735    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
13736      REQUIRED_OS_VERSION=5.2
13737    else
13738      REQUIRED_OS_VERSION=5.1
13739    fi
13740  fi
13741  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
13742    REQUIRED_OS_NAME=Darwin
13743    REQUIRED_OS_VERSION=11.2
13744  fi
13745
13746
13747
13748
13749
13750  # Also store the legacy naming of the cpu.
13751  # Ie i586 and amd64 instead of x86 and x86_64
13752  OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU"
13753  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13754    OPENJDK_TARGET_CPU_LEGACY="i586"
13755  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13756    # On all platforms except MacOSX replace x86_64 with amd64.
13757    OPENJDK_TARGET_CPU_LEGACY="amd64"
13758  fi
13759
13760
13761  # And the second legacy naming of the cpu.
13762  # Ie i386 and amd64 instead of x86 and x86_64.
13763  OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU"
13764  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13765    OPENJDK_TARGET_CPU_LEGACY_LIB="i386"
13766  elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13767    OPENJDK_TARGET_CPU_LEGACY_LIB="amd64"
13768  fi
13769
13770
13771  # This is the name of the cpu (but using i386 and amd64 instead of
13772  # x86 and x86_64, respectively), preceeded by a /, to be used when
13773  # locating libraries. On macosx, it's empty, though.
13774  OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB"
13775  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13776    OPENJDK_TARGET_CPU_LIBDIR=""
13777  fi
13778
13779
13780  # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to
13781  # /amd64 or /sparcv9. This string is appended to some library paths, like this:
13782  # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so
13783  OPENJDK_TARGET_CPU_ISADIR=""
13784  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13785    if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13786      OPENJDK_TARGET_CPU_ISADIR="/amd64"
13787    elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then
13788      OPENJDK_TARGET_CPU_ISADIR="/sparcv9"
13789    fi
13790  fi
13791
13792
13793  # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property
13794  OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU"
13795  if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then
13796    # On linux only, we replace x86 with i386.
13797    OPENJDK_TARGET_CPU_OSARCH="i386"
13798  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13799    # On all platforms except macosx, we replace x86_64 with amd64.
13800    OPENJDK_TARGET_CPU_OSARCH="amd64"
13801  fi
13802
13803
13804  OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU"
13805  if test "x$OPENJDK_TARGET_CPU" = xx86; then
13806    OPENJDK_TARGET_CPU_JLI="i386"
13807  elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13808    # On all platforms except macosx, we replace x86_64 with amd64.
13809    OPENJDK_TARGET_CPU_JLI="amd64"
13810  fi
13811  # Now setup the -D flags for building libjli.
13812  OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'"
13813  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13814    if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then
13815      OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'"
13816    elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
13817      OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'"
13818    fi
13819  fi
13820
13821
13822  # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths.
13823  if test "x$OPENJDK_TARGET_OS_API" = xposix; then
13824    OPENJDK_TARGET_OS_API_DIR="solaris"
13825  fi
13826  if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then
13827    OPENJDK_TARGET_OS_API_DIR="windows"
13828  fi
13829
13830
13831  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13832      OPENJDK_TARGET_OS_EXPORT_DIR=macosx
13833  else
13834      OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_API_DIR}
13835  fi
13836
13837
13838  if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13839    A_LP64="LP64:="
13840    # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
13841    # unpack200.exe
13842    if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then
13843      ADD_LP64="-D_LP64=1"
13844    fi
13845  fi
13846  LP64=$A_LP64
13847
13848
13849  if test "x$COMPILE_TYPE" = "xcross"; then
13850    # FIXME: ... or should this include reduced builds..?
13851    DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY"
13852  else
13853    DEFINE_CROSS_COMPILE_ARCH=""
13854  fi
13855
13856
13857  # ZERO_ARCHDEF is used to enable architecture-specific code
13858  case "${OPENJDK_TARGET_CPU}" in
13859    ppc*)    ZERO_ARCHDEF=PPC   ;;
13860    s390*)   ZERO_ARCHDEF=S390  ;;
13861    sparc*)  ZERO_ARCHDEF=SPARC ;;
13862    x86_64*) ZERO_ARCHDEF=AMD64 ;;
13863    x86)     ZERO_ARCHDEF=IA32  ;;
13864    *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
13865  esac
13866
13867
13868
13869
13870# Continue setting up basic stuff. Most remaining code require fundamental tools.
13871
13872  # We get the top-level directory from the supporting wrappers.
13873  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5
13874$as_echo_n "checking for top-level directory... " >&6; }
13875  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5
13876$as_echo "$TOPDIR" >&6; }
13877
13878  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13879
13880  # Input might be given as Windows format, start by converting to
13881  # unix format.
13882  path="$TOPDIR"
13883  new_path=`$CYGPATH -u "$path"`
13884
13885  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
13886  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
13887  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
13888  # "foo.exe" is OK but "foo" is an error.
13889  #
13890  # This test is therefore slightly more accurate than "test -f" to check for file precense.
13891  # It is also a way to make sure we got the proper file name for the real test later on.
13892  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
13893  if test "x$test_shortpath" = x; then
13894    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13895$as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13896    as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5
13897  fi
13898
13899  # Call helper function which possibly converts this using DOS-style short mode.
13900  # If so, the updated path is stored in $new_path.
13901
13902  input_path="$new_path"
13903  # Check if we need to convert this using DOS-style short mode. If the path
13904  # contains just simple characters, use it. Otherwise (spaces, weird characters),
13905  # take no chances and rewrite it.
13906  # Note: m4 eats our [], so we need to use [ and ] instead.
13907  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
13908  if test "x$has_forbidden_chars" != x; then
13909    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13910    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
13911    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
13912    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
13913      # Going to short mode and back again did indeed matter. Since short mode is
13914      # case insensitive, let's make it lowercase to improve readability.
13915      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13916      # Now convert it back to Unix-stile (cygpath)
13917      input_path=`$CYGPATH -u "$shortmode_path"`
13918      new_path="$input_path"
13919    fi
13920  fi
13921
13922  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
13923  if test "x$test_cygdrive_prefix" = x; then
13924    # As a simple fix, exclude /usr/bin since it's not a real path.
13925    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
13926      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
13927      # a path prefixed by /cygdrive for fixpath to work.
13928      new_path="$CYGWIN_ROOT_PATH$input_path"
13929    fi
13930  fi
13931
13932
13933  if test "x$path" != "x$new_path"; then
13934    TOPDIR="$new_path"
13935    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13936$as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13937  fi
13938
13939  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13940
13941  path="$TOPDIR"
13942  has_colon=`$ECHO $path | $GREP ^.:`
13943  new_path="$path"
13944  if test "x$has_colon" = x; then
13945    # Not in mixed or Windows style, start by that.
13946    new_path=`cmd //c echo $path`
13947  fi
13948
13949
13950  input_path="$new_path"
13951  # Check if we need to convert this using DOS-style short mode. If the path
13952  # contains just simple characters, use it. Otherwise (spaces, weird characters),
13953  # take no chances and rewrite it.
13954  # Note: m4 eats our [], so we need to use [ and ] instead.
13955  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
13956  if test "x$has_forbidden_chars" != x; then
13957    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13958    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13959  fi
13960
13961
13962  windows_path="$new_path"
13963  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13964    unix_path=`$CYGPATH -u "$windows_path"`
13965    new_path="$unix_path"
13966  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13967    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
13968    new_path="$unix_path"
13969  fi
13970
13971  if test "x$path" != "x$new_path"; then
13972    TOPDIR="$new_path"
13973    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13974$as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13975  fi
13976
13977  # Save the first 10 bytes of this path to the storage, so fixpath can work.
13978  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
13979
13980  else
13981    # We're on a posix platform. Hooray! :)
13982    path="$TOPDIR"
13983    has_space=`$ECHO "$path" | $GREP " "`
13984    if test "x$has_space" != x; then
13985      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13986$as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13987      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
13988    fi
13989
13990    # Use eval to expand a potential ~
13991    eval path="$path"
13992    if test ! -f "$path" && test ! -d "$path"; then
13993      as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
13994    fi
13995
13996    TOPDIR="`cd "$path"; $THEPWDCMD -L`"
13997  fi
13998
13999
14000
14001  # SRC_ROOT is a traditional alias for TOPDIR.
14002  SRC_ROOT=$TOPDIR
14003
14004  # Locate the directory of this script.
14005  AUTOCONF_DIR=$TOPDIR/common/autoconf
14006
14007  # Save the current directory this script was started from
14008  CURDIR="$PWD"
14009
14010  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14011
14012  # Input might be given as Windows format, start by converting to
14013  # unix format.
14014  path="$CURDIR"
14015  new_path=`$CYGPATH -u "$path"`
14016
14017  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14018  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14019  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14020  # "foo.exe" is OK but "foo" is an error.
14021  #
14022  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14023  # It is also a way to make sure we got the proper file name for the real test later on.
14024  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14025  if test "x$test_shortpath" = x; then
14026    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14027$as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14028    as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5
14029  fi
14030
14031  # Call helper function which possibly converts this using DOS-style short mode.
14032  # If so, the updated path is stored in $new_path.
14033
14034  input_path="$new_path"
14035  # Check if we need to convert this using DOS-style short mode. If the path
14036  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14037  # take no chances and rewrite it.
14038  # Note: m4 eats our [], so we need to use [ and ] instead.
14039  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14040  if test "x$has_forbidden_chars" != x; then
14041    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14042    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14043    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14044    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14045      # Going to short mode and back again did indeed matter. Since short mode is
14046      # case insensitive, let's make it lowercase to improve readability.
14047      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14048      # Now convert it back to Unix-stile (cygpath)
14049      input_path=`$CYGPATH -u "$shortmode_path"`
14050      new_path="$input_path"
14051    fi
14052  fi
14053
14054  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14055  if test "x$test_cygdrive_prefix" = x; then
14056    # As a simple fix, exclude /usr/bin since it's not a real path.
14057    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14058      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14059      # a path prefixed by /cygdrive for fixpath to work.
14060      new_path="$CYGWIN_ROOT_PATH$input_path"
14061    fi
14062  fi
14063
14064
14065  if test "x$path" != "x$new_path"; then
14066    CURDIR="$new_path"
14067    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14068$as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14069  fi
14070
14071  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14072
14073  path="$CURDIR"
14074  has_colon=`$ECHO $path | $GREP ^.:`
14075  new_path="$path"
14076  if test "x$has_colon" = x; then
14077    # Not in mixed or Windows style, start by that.
14078    new_path=`cmd //c echo $path`
14079  fi
14080
14081
14082  input_path="$new_path"
14083  # Check if we need to convert this using DOS-style short mode. If the path
14084  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14085  # take no chances and rewrite it.
14086  # Note: m4 eats our [], so we need to use [ and ] instead.
14087  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14088  if test "x$has_forbidden_chars" != x; then
14089    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14090    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14091  fi
14092
14093
14094  windows_path="$new_path"
14095  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14096    unix_path=`$CYGPATH -u "$windows_path"`
14097    new_path="$unix_path"
14098  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14099    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14100    new_path="$unix_path"
14101  fi
14102
14103  if test "x$path" != "x$new_path"; then
14104    CURDIR="$new_path"
14105    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14106$as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14107  fi
14108
14109  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14110  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14111
14112  else
14113    # We're on a posix platform. Hooray! :)
14114    path="$CURDIR"
14115    has_space=`$ECHO "$path" | $GREP " "`
14116    if test "x$has_space" != x; then
14117      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14118$as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14119      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14120    fi
14121
14122    # Use eval to expand a potential ~
14123    eval path="$path"
14124    if test ! -f "$path" && test ! -d "$path"; then
14125      as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14126    fi
14127
14128    CURDIR="`cd "$path"; $THEPWDCMD -L`"
14129  fi
14130
14131
14132  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
14133    PATH_SEP=";"
14134
14135  SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m`
14136  if test $SRC_ROOT_LENGTH -gt 100; then
14137    as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5
14138  fi
14139
14140  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14141    { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5
14142$as_echo_n "checking cygwin release... " >&6; }
14143    CYGWIN_VERSION=`$UNAME -r`
14144    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5
14145$as_echo "$CYGWIN_VERSION" >&6; }
14146    WINDOWS_ENV_VENDOR='cygwin'
14147    WINDOWS_ENV_VERSION="$CYGWIN_VERSION"
14148
14149    CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.`
14150    if test "x$CYGWIN_VERSION_OK" = x; then
14151      { $as_echo "$as_me:${as_lineno-$LINENO}: Your cygwin is too old. You are running $CYGWIN_VERSION, but at least cygwin 1.7 is required. Please upgrade." >&5
14152$as_echo "$as_me: Your cygwin is too old. You are running $CYGWIN_VERSION, but at least cygwin 1.7 is required. Please upgrade." >&6;}
14153      as_fn_error $? "Cannot continue" "$LINENO" 5
14154    fi
14155    if test "x$CYGPATH" = x; then
14156      as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5
14157    fi
14158    { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5
14159$as_echo_n "checking cygwin root directory as unix-style path... " >&6; }
14160    # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14161    cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"`
14162    # Force cygpath to report the proper root by including a trailing space, and then stripping it off again.
14163    CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "`
14164    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5
14165$as_echo "$CYGWIN_ROOT_PATH" >&6; }
14166    WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH"
14167    test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/`
14168    if test "x$test_cygdrive_prefix" = x; then
14169      as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5
14170    fi
14171  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14172    { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5
14173$as_echo_n "checking msys release... " >&6; }
14174    MSYS_VERSION=`$UNAME -r`
14175    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5
14176$as_echo "$MSYS_VERSION" >&6; }
14177
14178    WINDOWS_ENV_VENDOR='msys'
14179    WINDOWS_ENV_VERSION="$MSYS_VERSION"
14180
14181    { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5
14182$as_echo_n "checking msys root directory as unix-style path... " >&6; }
14183    # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14184    MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"`
14185
14186  windows_path="$MSYS_ROOT_PATH"
14187  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14188    unix_path=`$CYGPATH -u "$windows_path"`
14189    MSYS_ROOT_PATH="$unix_path"
14190  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14191    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14192    MSYS_ROOT_PATH="$unix_path"
14193  fi
14194
14195    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5
14196$as_echo "$MSYS_ROOT_PATH" >&6; }
14197    WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH"
14198  else
14199    as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5
14200  fi
14201
14202  # Test if windows or unix (cygwin/msys) find is first in path.
14203  { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5
14204$as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; }
14205  FIND_BINARY_OUTPUT=`find --version 2>&1`
14206  if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then
14207    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5
14208$as_echo "unix style" >&6; }
14209  elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then
14210    { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5
14211$as_echo "Windows" >&6; }
14212    { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5
14213$as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;}
14214    { $as_echo "$as_me:${as_lineno-$LINENO}: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&5
14215$as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;}
14216    as_fn_error $? "Cannot continue" "$LINENO" 5
14217  else
14218    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
14219$as_echo "unknown" >&6; }
14220    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5
14221$as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;}
14222  fi
14223
14224  else
14225    PATH_SEP=":"
14226  fi
14227
14228
14229  if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14230    # Add extra search paths on solaris for utilities like ar and as etc...
14231    PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14232  fi
14233
14234  # You can force the sys-root if the sys-root encoded into the cross compiler tools
14235  # is not correct.
14236
14237# Check whether --with-sys-root was given.
14238if test "${with_sys_root+set}" = set; then :
14239  withval=$with_sys_root;
14240fi
14241
14242
14243  if test "x$with_sys_root" != x; then
14244    SYS_ROOT=$with_sys_root
14245  else
14246    SYS_ROOT=/
14247  fi
14248
14249
14250
14251# Check whether --with-tools-dir was given.
14252if test "${with_tools_dir+set}" = set; then :
14253  withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir
14254
14255fi
14256
14257
14258
14259# Check whether --with-devkit was given.
14260if test "${with_devkit+set}" = set; then :
14261  withval=$with_devkit;
14262        if test "x$with_sys_root" != x; then
14263          as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5
14264        fi
14265
14266  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14267
14268  # Input might be given as Windows format, start by converting to
14269  # unix format.
14270  path="$with_devkit"
14271  new_path=`$CYGPATH -u "$path"`
14272
14273  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14274  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14275  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14276  # "foo.exe" is OK but "foo" is an error.
14277  #
14278  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14279  # It is also a way to make sure we got the proper file name for the real test later on.
14280  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14281  if test "x$test_shortpath" = x; then
14282    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14283$as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14284    as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5
14285  fi
14286
14287  # Call helper function which possibly converts this using DOS-style short mode.
14288  # If so, the updated path is stored in $new_path.
14289
14290  input_path="$new_path"
14291  # Check if we need to convert this using DOS-style short mode. If the path
14292  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14293  # take no chances and rewrite it.
14294  # Note: m4 eats our [], so we need to use [ and ] instead.
14295  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14296  if test "x$has_forbidden_chars" != x; then
14297    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14298    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14299    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14300    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14301      # Going to short mode and back again did indeed matter. Since short mode is
14302      # case insensitive, let's make it lowercase to improve readability.
14303      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14304      # Now convert it back to Unix-stile (cygpath)
14305      input_path=`$CYGPATH -u "$shortmode_path"`
14306      new_path="$input_path"
14307    fi
14308  fi
14309
14310  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14311  if test "x$test_cygdrive_prefix" = x; then
14312    # As a simple fix, exclude /usr/bin since it's not a real path.
14313    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14314      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14315      # a path prefixed by /cygdrive for fixpath to work.
14316      new_path="$CYGWIN_ROOT_PATH$input_path"
14317    fi
14318  fi
14319
14320
14321  if test "x$path" != "x$new_path"; then
14322    with_devkit="$new_path"
14323    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14324$as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14325  fi
14326
14327  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14328
14329  path="$with_devkit"
14330  has_colon=`$ECHO $path | $GREP ^.:`
14331  new_path="$path"
14332  if test "x$has_colon" = x; then
14333    # Not in mixed or Windows style, start by that.
14334    new_path=`cmd //c echo $path`
14335  fi
14336
14337
14338  input_path="$new_path"
14339  # Check if we need to convert this using DOS-style short mode. If the path
14340  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14341  # take no chances and rewrite it.
14342  # Note: m4 eats our [], so we need to use [ and ] instead.
14343  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14344  if test "x$has_forbidden_chars" != x; then
14345    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14346    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14347  fi
14348
14349
14350  windows_path="$new_path"
14351  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14352    unix_path=`$CYGPATH -u "$windows_path"`
14353    new_path="$unix_path"
14354  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14355    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14356    new_path="$unix_path"
14357  fi
14358
14359  if test "x$path" != "x$new_path"; then
14360    with_devkit="$new_path"
14361    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14362$as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14363  fi
14364
14365  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14366  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14367
14368  else
14369    # We're on a posix platform. Hooray! :)
14370    path="$with_devkit"
14371    has_space=`$ECHO "$path" | $GREP " "`
14372    if test "x$has_space" != x; then
14373      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14374$as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14375      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14376    fi
14377
14378    # Use eval to expand a potential ~
14379    eval path="$path"
14380    if test ! -f "$path" && test ! -d "$path"; then
14381      as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14382    fi
14383
14384    with_devkit="`cd "$path"; $THEPWDCMD -L`"
14385  fi
14386
14387
14388  if test "x$TOOLS_DIR" = x; then
14389    TOOLS_DIR="$with_devkit/bin"
14390  else
14391    TOOLS_DIR="$TOOLS_DIR:$with_devkit/bin"
14392  fi
14393
14394        if test -d "$with_devkit/$host_alias/libc"; then
14395          SYS_ROOT=$with_devkit/$host_alias/libc
14396        elif test -d "$with_devkit/$host/sys-root"; then
14397          SYS_ROOT=$with_devkit/$host/sys-root
14398        fi
14399
14400fi
14401
14402
14403
14404  # Setup default logging of stdout and stderr to build.log in the output root.
14405  BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14406  BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14407  BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14408
14409
14410
14411
14412
14413# Check if it's a pure open build or if custom sources are to be used.
14414
14415  # Check whether --enable-openjdk-only was given.
14416if test "${enable_openjdk_only+set}" = set; then :
14417  enableval=$enable_openjdk_only;
14418else
14419  enable_openjdk_only="no"
14420fi
14421
14422
14423  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5
14424$as_echo_n "checking for presence of closed sources... " >&6; }
14425  if test -d "$SRC_ROOT/jdk/src/closed"; then
14426    CLOSED_SOURCE_PRESENT=yes
14427  else
14428    CLOSED_SOURCE_PRESENT=no
14429  fi
14430  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5
14431$as_echo "$CLOSED_SOURCE_PRESENT" >&6; }
14432
14433  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5
14434$as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; }
14435  SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only"
14436  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5
14437$as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; }
14438
14439  if test "x$CLOSED_SOURCE_PRESENT" = xno; then
14440    OPENJDK=true
14441    if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14442      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5
14443$as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;}
14444    fi
14445  else
14446    if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14447      OPENJDK=true
14448    else
14449      OPENJDK=false
14450    fi
14451  fi
14452
14453  if test "x$OPENJDK" = "xtrue"; then
14454    SET_OPENJDK="OPENJDK=true"
14455  fi
14456
14457
14458
14459  # custom-make-dir is deprecated. Please use your custom-hook.m4 to override
14460  # the IncludeCustomExtension macro.
14461
14462
14463# Check whether --with-custom-make-dir was given.
14464if test "${with_custom_make_dir+set}" = set; then :
14465  withval=$with_custom_make_dir; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&5
14466$as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;}
14467fi
14468
14469
14470
14471
14472# These are needed to be able to create a configuration name (and thus the output directory)
14473
14474  ###############################################################################
14475  #
14476  # Check which variant of the JDK that we want to build.
14477  # Currently we have:
14478  #    normal:   standard edition
14479  # but the custom make system may add other variants
14480  #
14481  # Effectively the JDK variant gives a name to a specific set of
14482  # modules to compile into the JDK. In the future, these modules
14483  # might even be Jigsaw modules.
14484  #
14485  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5
14486$as_echo_n "checking which variant of the JDK to build... " >&6; }
14487
14488# Check whether --with-jdk-variant was given.
14489if test "${with_jdk_variant+set}" = set; then :
14490  withval=$with_jdk_variant;
14491fi
14492
14493
14494  if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then
14495    JDK_VARIANT="normal"
14496  else
14497    as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5
14498  fi
14499
14500
14501
14502  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5
14503$as_echo "$JDK_VARIANT" >&6; }
14504
14505
14506###############################################################################
14507#
14508# Check which interpreter of the JVM we want to build.
14509# Currently we have:
14510#    template: Template interpreter (the default)
14511#    cpp     : C++ interpreter
14512{ $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5
14513$as_echo_n "checking which interpreter of the JVM to build... " >&6; }
14514
14515# Check whether --with-jvm-interpreter was given.
14516if test "${with_jvm_interpreter+set}" = set; then :
14517  withval=$with_jvm_interpreter;
14518fi
14519
14520
14521if test "x$with_jvm_interpreter" = x; then
14522     with_jvm_interpreter="template"
14523fi
14524
14525JVM_INTERPRETER="$with_jvm_interpreter"
14526
14527if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then
14528   as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5
14529fi
14530
14531
14532
14533{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_interpreter" >&5
14534$as_echo "$with_jvm_interpreter" >&6; }
14535
14536
14537
14538  ###############################################################################
14539  #
14540  # Check which variants of the JVM that we want to build.
14541  # Currently we have:
14542  #    server: normal interpreter and a tiered C1/C2 compiler
14543  #    client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms)
14544  #    minimal1: reduced form of client with optional VM services and features stripped out
14545  #    kernel: kernel footprint JVM that passes the TCK without major performance problems,
14546  #             ie normal interpreter and C1, only the serial GC, kernel jvmti etc
14547  #    zero: no machine code interpreter, no compiler
14548  #    zeroshark: zero interpreter and shark/llvm compiler backend
14549#    core: interpreter only, no compiler (only works on some platforms)
14550  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5
14551$as_echo_n "checking which variants of the JVM to build... " >&6; }
14552
14553# Check whether --with-jvm-variants was given.
14554if test "${with_jvm_variants+set}" = set; then :
14555  withval=$with_jvm_variants;
14556fi
14557
14558
14559  if test "x$with_jvm_variants" = x; then
14560    with_jvm_variants="server"
14561  fi
14562
14563  JVM_VARIANTS=",$with_jvm_variants,"
14564  TEST_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,//' -e 's/client,//'  -e 's/minimal1,//' -e 's/kernel,//' -e 's/zero,//' -e 's/zeroshark,//' -e 's/core,//'`
14565
14566  if test "x$TEST_VARIANTS" != "x,"; then
14567     as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark, core" "$LINENO" 5
14568  fi
14569  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5
14570$as_echo "$with_jvm_variants" >&6; }
14571
14572  JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
14573  JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
14574  JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'`
14575  JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'`
14576  JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
14577  JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
14578  JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
14579
14580  if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14581    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14582      as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5
14583    fi
14584  fi
14585  if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14586    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14587      as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5
14588    fi
14589  fi
14590  if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14591    if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14592      as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5
14593    fi
14594  fi
14595
14596  # Replace the commas with AND for use in the build directory name.
14597  ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'`
14598  COUNT_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,/1/' -e 's/client,/1/' -e 's/minimal1,/1/' -e 's/kernel,/1/' -e 's/zero,/1/' -e 's/zeroshark,/1/' -e 's/core,/1/'`
14599  if test "x$COUNT_VARIANTS" != "x,1"; then
14600    BUILDING_MULTIPLE_JVM_VARIANTS=yes
14601  else
14602    BUILDING_MULTIPLE_JVM_VARIANTS=no
14603  fi
14604
14605
14606
14607
14608
14609
14610
14611
14612
14613
14614  INCLUDE_SA=true
14615  if test "x$JVM_VARIANT_ZERO" = xtrue ; then
14616    INCLUDE_SA=false
14617  fi
14618  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then
14619    INCLUDE_SA=false
14620  fi
14621  if test "x$VAR_CPU" = xppc64 ; then
14622    INCLUDE_SA=false
14623  fi
14624
14625
14626  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
14627    MACOSX_UNIVERSAL="true"
14628  fi
14629
14630
14631
14632
14633  ###############################################################################
14634  #
14635  # Set the debug level
14636  #    release: no debug information, all optimizations, no asserts.
14637  #    fastdebug: debug information (-g), all optimizations, all asserts
14638  #    slowdebug: debug information (-g), no optimizations, all asserts
14639  #
14640  DEBUG_LEVEL="release"
14641  { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5
14642$as_echo_n "checking which debug level to use... " >&6; }
14643  # Check whether --enable-debug was given.
14644if test "${enable_debug+set}" = set; then :
14645  enableval=$enable_debug;
14646        ENABLE_DEBUG="${enableval}"
14647        DEBUG_LEVEL="fastdebug"
14648
14649else
14650  ENABLE_DEBUG="no"
14651fi
14652
14653
14654
14655# Check whether --with-debug-level was given.
14656if test "${with_debug_level+set}" = set; then :
14657  withval=$with_debug_level;
14658        DEBUG_LEVEL="${withval}"
14659        if test "x$ENABLE_DEBUG" = xyes; then
14660          as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5
14661        fi
14662
14663fi
14664
14665  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5
14666$as_echo "$DEBUG_LEVEL" >&6; }
14667
14668  if test "x$DEBUG_LEVEL" != xrelease && \
14669      test "x$DEBUG_LEVEL" != xfastdebug && \
14670      test "x$DEBUG_LEVEL" != xslowdebug; then
14671    as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5
14672  fi
14673
14674
14675  ###############################################################################
14676  #
14677  # Setup legacy vars/targets and new vars to deal with different debug levels.
14678  #
14679
14680  case $DEBUG_LEVEL in
14681    release )
14682      VARIANT="OPT"
14683      FASTDEBUG="false"
14684      DEBUG_CLASSFILES="false"
14685      BUILD_VARIANT_RELEASE=""
14686      HOTSPOT_DEBUG_LEVEL="product"
14687      HOTSPOT_EXPORT="product"
14688      ;;
14689    fastdebug )
14690      VARIANT="DBG"
14691      FASTDEBUG="true"
14692      DEBUG_CLASSFILES="true"
14693      BUILD_VARIANT_RELEASE="-fastdebug"
14694      HOTSPOT_DEBUG_LEVEL="fastdebug"
14695      HOTSPOT_EXPORT="fastdebug"
14696      ;;
14697    slowdebug )
14698      VARIANT="DBG"
14699      FASTDEBUG="false"
14700      DEBUG_CLASSFILES="true"
14701      BUILD_VARIANT_RELEASE="-debug"
14702      HOTSPOT_DEBUG_LEVEL="jvmg"
14703      HOTSPOT_EXPORT="debug"
14704      ;;
14705  esac
14706
14707  #####
14708  # Generate the legacy makefile targets for hotspot.
14709  # The hotspot api for selecting the build artifacts, really, needs to be improved.
14710  # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to
14711  # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc
14712  # But until then ...
14713  HOTSPOT_TARGET=""
14714
14715  if test "x$JVM_VARIANT_SERVER" = xtrue; then
14716    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
14717  fi
14718
14719  if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14720    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
14721  fi
14722
14723  if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14724    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
14725  fi
14726
14727  if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14728    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel "
14729  fi
14730
14731  if test "x$JVM_VARIANT_ZERO" = xtrue; then
14732    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
14733  fi
14734
14735  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
14736    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
14737  fi
14738
14739  if test "x$JVM_VARIANT_CORE" = xtrue; then
14740    HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
14741  fi
14742
14743  HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT"
14744
14745  # On Macosx universal binaries are produced, but they only contain
14746  # 64 bit intel. This invalidates control of which jvms are built
14747  # from configure, but only server is valid anyway. Fix this
14748  # when hotspot makefiles are rewritten.
14749  if test "x$MACOSX_UNIVERSAL" = xtrue; then
14750    HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT}
14751  fi
14752
14753  #####
14754
14755
14756
14757
14758
14759
14760
14761
14762# With basic setup done, call the custom early hook.
14763
14764
14765# To properly create a configuration name, we need to have the OpenJDK target
14766# and options (variants and debug level) parsed.
14767
14768
14769
14770# Check whether --with-conf-name was given.
14771if test "${with_conf_name+set}" = set; then :
14772  withval=$with_conf_name;  CONF_NAME=${with_conf_name}
14773fi
14774
14775
14776  # Test from where we are running configure, in or outside of src root.
14777  { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5
14778$as_echo_n "checking where to store configuration... " >&6; }
14779  if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \
14780      || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \
14781      || test "x$CURDIR" = "x$SRC_ROOT/make" ; then
14782    # We are running configure from the src root.
14783    # Create a default ./build/target-variant-debuglevel output root.
14784    if test "x${CONF_NAME}" = x; then
14785      { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5
14786$as_echo "in default location" >&6; }
14787      CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}"
14788    else
14789      { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5
14790$as_echo "in build directory with custom name" >&6; }
14791    fi
14792    OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}"
14793    $MKDIR -p "$OUTPUT_ROOT"
14794    if test ! -d "$OUTPUT_ROOT"; then
14795      as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5
14796    fi
14797  else
14798    # We are running configure from outside of the src dir.
14799    # Then use the current directory as output dir!
14800    # If configuration is situated in normal build directory, just use the build
14801    # directory name as configuration name, otherwise use the complete path.
14802    if test "x${CONF_NAME}" = x; then
14803      CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"`
14804    fi
14805    OUTPUT_ROOT="$CURDIR"
14806    { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5
14807$as_echo "in current directory" >&6; }
14808
14809    # WARNING: This might be a bad thing to do. You need to be sure you want to
14810    # have a configuration in this directory. Do some sanity checks!
14811
14812    if test ! -e "$OUTPUT_ROOT/spec.gmk"; then
14813      # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for
14814      # other files
14815      files_present=`$LS $OUTPUT_ROOT`
14816      # Configure has already touched config.log and confdefs.h in the current dir when this check
14817      # is performed.
14818      filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \
14819      | $TR -d '\n'`
14820      if test "x$filtered_files" != x; then
14821        { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5
14822$as_echo "$as_me: Current directory is $CURDIR." >&6;}
14823        { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5
14824$as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;}
14825        { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5
14826$as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;}
14827        { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5
14828$as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;}
14829        { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5
14830$as_echo "$as_me: seriously mess up just about everything." >&6;}
14831        { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5
14832$as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;}
14833        { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5
14834$as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;}
14835        as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5
14836      fi
14837    fi
14838  fi
14839  { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5
14840$as_echo_n "checking what configuration name to use... " >&6; }
14841  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5
14842$as_echo "$CONF_NAME" >&6; }
14843
14844
14845  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14846
14847  # Input might be given as Windows format, start by converting to
14848  # unix format.
14849  path="$OUTPUT_ROOT"
14850  new_path=`$CYGPATH -u "$path"`
14851
14852  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14853  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14854  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14855  # "foo.exe" is OK but "foo" is an error.
14856  #
14857  # This test is therefore slightly more accurate than "test -f" to check for file precense.
14858  # It is also a way to make sure we got the proper file name for the real test later on.
14859  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14860  if test "x$test_shortpath" = x; then
14861    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14862$as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14863    as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5
14864  fi
14865
14866  # Call helper function which possibly converts this using DOS-style short mode.
14867  # If so, the updated path is stored in $new_path.
14868
14869  input_path="$new_path"
14870  # Check if we need to convert this using DOS-style short mode. If the path
14871  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14872  # take no chances and rewrite it.
14873  # Note: m4 eats our [], so we need to use [ and ] instead.
14874  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14875  if test "x$has_forbidden_chars" != x; then
14876    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14877    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14878    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14879    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14880      # Going to short mode and back again did indeed matter. Since short mode is
14881      # case insensitive, let's make it lowercase to improve readability.
14882      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14883      # Now convert it back to Unix-stile (cygpath)
14884      input_path=`$CYGPATH -u "$shortmode_path"`
14885      new_path="$input_path"
14886    fi
14887  fi
14888
14889  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14890  if test "x$test_cygdrive_prefix" = x; then
14891    # As a simple fix, exclude /usr/bin since it's not a real path.
14892    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14893      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14894      # a path prefixed by /cygdrive for fixpath to work.
14895      new_path="$CYGWIN_ROOT_PATH$input_path"
14896    fi
14897  fi
14898
14899
14900  if test "x$path" != "x$new_path"; then
14901    OUTPUT_ROOT="$new_path"
14902    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14903$as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14904  fi
14905
14906  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14907
14908  path="$OUTPUT_ROOT"
14909  has_colon=`$ECHO $path | $GREP ^.:`
14910  new_path="$path"
14911  if test "x$has_colon" = x; then
14912    # Not in mixed or Windows style, start by that.
14913    new_path=`cmd //c echo $path`
14914  fi
14915
14916
14917  input_path="$new_path"
14918  # Check if we need to convert this using DOS-style short mode. If the path
14919  # contains just simple characters, use it. Otherwise (spaces, weird characters),
14920  # take no chances and rewrite it.
14921  # Note: m4 eats our [], so we need to use [ and ] instead.
14922  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14923  if test "x$has_forbidden_chars" != x; then
14924    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14925    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14926  fi
14927
14928
14929  windows_path="$new_path"
14930  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14931    unix_path=`$CYGPATH -u "$windows_path"`
14932    new_path="$unix_path"
14933  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14934    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14935    new_path="$unix_path"
14936  fi
14937
14938  if test "x$path" != "x$new_path"; then
14939    OUTPUT_ROOT="$new_path"
14940    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14941$as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14942  fi
14943
14944  # Save the first 10 bytes of this path to the storage, so fixpath can work.
14945  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14946
14947  else
14948    # We're on a posix platform. Hooray! :)
14949    path="$OUTPUT_ROOT"
14950    has_space=`$ECHO "$path" | $GREP " "`
14951    if test "x$has_space" != x; then
14952      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14953$as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14954      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14955    fi
14956
14957    # Use eval to expand a potential ~
14958    eval path="$path"
14959    if test ! -f "$path" && test ! -d "$path"; then
14960      as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5
14961    fi
14962
14963    OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`"
14964  fi
14965
14966
14967  SPEC=$OUTPUT_ROOT/spec.gmk
14968
14969  CONF_NAME=$CONF_NAME
14970
14971  OUTPUT_ROOT=$OUTPUT_ROOT
14972
14973
14974  # Most of the probed defines are put into config.h
14975  ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in"
14976
14977  # The spec.gmk file contains all variables for the make system.
14978  ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in"
14979
14980  # The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
14981  ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in"
14982
14983  # The bootcycle-spec.gmk file contains support for boot cycle builds.
14984  ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in"
14985
14986  # The compare.sh is used to compare the build output to other builds.
14987  ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in"
14988
14989  # Spec.sh is currently used by compare-objects.sh
14990  ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in"
14991
14992  # The generated Makefile knows where the spec.gmk is and where the source is.
14993  # You can run make from the OUTPUT_ROOT, or from the top-level Makefile
14994  # which will look for generated configurations
14995  ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in"
14996
14997
14998
14999# Must be done before we can call HELP_MSG_MISSING_DEPENDENCY.
15000
15001  for ac_prog in apt-get yum port pkgutil pkgadd
15002do
15003  # Extract the first word of "$ac_prog", so it can be a program name with args.
15004set dummy $ac_prog; ac_word=$2
15005{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15006$as_echo_n "checking for $ac_word... " >&6; }
15007if ${ac_cv_prog_PKGHANDLER+:} false; then :
15008  $as_echo_n "(cached) " >&6
15009else
15010  if test -n "$PKGHANDLER"; then
15011  ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test.
15012else
15013as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15014for as_dir in $PATH
15015do
15016  IFS=$as_save_IFS
15017  test -z "$as_dir" && as_dir=.
15018    for ac_exec_ext in '' $ac_executable_extensions; do
15019  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15020    ac_cv_prog_PKGHANDLER="$ac_prog"
15021    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15022    break 2
15023  fi
15024done
15025  done
15026IFS=$as_save_IFS
15027
15028fi
15029fi
15030PKGHANDLER=$ac_cv_prog_PKGHANDLER
15031if test -n "$PKGHANDLER"; then
15032  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5
15033$as_echo "$PKGHANDLER" >&6; }
15034else
15035  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15036$as_echo "no" >&6; }
15037fi
15038
15039
15040  test -n "$PKGHANDLER" && break
15041done
15042
15043
15044
15045# Setup tools that requires more complex handling, or that is not needed by the configure script.
15046
15047
15048  # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky.
15049  if test "x$MAKE" != x; then
15050    # User has supplied a make, test it.
15051    if test ! -f "$MAKE"; then
15052      as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5
15053    fi
15054
15055  MAKE_CANDIDATE=""$MAKE""
15056  DESCRIPTION="user supplied MAKE=$MAKE"
15057  if test "x$MAKE_CANDIDATE" != x; then
15058    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15059$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15060    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15061    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15062    if test "x$IS_GNU_MAKE" = x; then
15063      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15064$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15065    else
15066      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15067      if test "x$IS_MODERN_MAKE" = x; then
15068        { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15069$as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15070      else
15071        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15072          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15073            MAKE_EXPECTED_ENV='cygwin'
15074          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15075            MAKE_EXPECTED_ENV='msys'
15076          else
15077            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15078          fi
15079          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15080          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15081        else
15082          # Not relevant for non-Windows
15083          IS_MAKE_CORRECT_ENV=true
15084        fi
15085        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15086          { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
15087$as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
15088        else
15089          FOUND_MAKE=$MAKE_CANDIDATE
15090
15091  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15092
15093  # First separate the path from the arguments. This will split at the first
15094  # space.
15095  complete="$FOUND_MAKE"
15096  path="${complete%% *}"
15097  tmp="$complete EOL"
15098  arguments="${tmp#* }"
15099
15100  # Input might be given as Windows format, start by converting to
15101  # unix format.
15102  new_path=`$CYGPATH -u "$path"`
15103
15104  # Now try to locate executable using which
15105  new_path=`$WHICH "$new_path" 2> /dev/null`
15106  # bat and cmd files are not always considered executable in cygwin causing which
15107  # to not find them
15108  if test "x$new_path" = x \
15109      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15110      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15111    new_path=`$CYGPATH -u "$path"`
15112  fi
15113  if test "x$new_path" = x; then
15114    # Oops. Which didn't find the executable.
15115    # The splitting of arguments from the executable at a space might have been incorrect,
15116    # since paths with space are more likely in Windows. Give it another try with the whole
15117    # argument.
15118    path="$complete"
15119    arguments="EOL"
15120    new_path=`$CYGPATH -u "$path"`
15121    new_path=`$WHICH "$new_path" 2> /dev/null`
15122    # bat and cmd files are not always considered executable in cygwin causing which
15123    # to not find them
15124    if test "x$new_path" = x \
15125        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15126        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15127      new_path=`$CYGPATH -u "$path"`
15128    fi
15129    if test "x$new_path" = x; then
15130      # It's still not found. Now this is an unrecoverable error.
15131      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15132$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15133      has_space=`$ECHO "$complete" | $GREP " "`
15134      if test "x$has_space" != x; then
15135        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15136$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15137      fi
15138      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15139    fi
15140  fi
15141
15142  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15143  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15144  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15145  # "foo.exe" is OK but "foo" is an error.
15146  #
15147  # This test is therefore slightly more accurate than "test -f" to check for file presence.
15148  # It is also a way to make sure we got the proper file name for the real test later on.
15149  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15150  if test "x$test_shortpath" = x; then
15151    # Short path failed, file does not exist as specified.
15152    # Try adding .exe or .cmd
15153    if test -f "${new_path}.exe"; then
15154      input_to_shortpath="${new_path}.exe"
15155    elif test -f "${new_path}.cmd"; then
15156      input_to_shortpath="${new_path}.cmd"
15157    else
15158      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15159$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15160      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15161$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15162      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15163    fi
15164  else
15165    input_to_shortpath="$new_path"
15166  fi
15167
15168  # Call helper function which possibly converts this using DOS-style short mode.
15169  # If so, the updated path is stored in $new_path.
15170  new_path="$input_to_shortpath"
15171
15172  input_path="$input_to_shortpath"
15173  # Check if we need to convert this using DOS-style short mode. If the path
15174  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15175  # take no chances and rewrite it.
15176  # Note: m4 eats our [], so we need to use [ and ] instead.
15177  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15178  if test "x$has_forbidden_chars" != x; then
15179    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15180    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15181    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15182    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15183      # Going to short mode and back again did indeed matter. Since short mode is
15184      # case insensitive, let's make it lowercase to improve readability.
15185      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15186      # Now convert it back to Unix-stile (cygpath)
15187      input_path=`$CYGPATH -u "$shortmode_path"`
15188      new_path="$input_path"
15189    fi
15190  fi
15191
15192  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15193  if test "x$test_cygdrive_prefix" = x; then
15194    # As a simple fix, exclude /usr/bin since it's not a real path.
15195    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15196      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15197      # a path prefixed by /cygdrive for fixpath to work.
15198      new_path="$CYGWIN_ROOT_PATH$input_path"
15199    fi
15200  fi
15201
15202  # remove trailing .exe if any
15203  new_path="${new_path/%.exe/}"
15204
15205  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15206
15207  # First separate the path from the arguments. This will split at the first
15208  # space.
15209  complete="$FOUND_MAKE"
15210  path="${complete%% *}"
15211  tmp="$complete EOL"
15212  arguments="${tmp#* }"
15213
15214  # Input might be given as Windows format, start by converting to
15215  # unix format.
15216  new_path="$path"
15217
15218  windows_path="$new_path"
15219  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15220    unix_path=`$CYGPATH -u "$windows_path"`
15221    new_path="$unix_path"
15222  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15223    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15224    new_path="$unix_path"
15225  fi
15226
15227
15228  # Now try to locate executable using which
15229  new_path=`$WHICH "$new_path" 2> /dev/null`
15230
15231  if test "x$new_path" = x; then
15232    # Oops. Which didn't find the executable.
15233    # The splitting of arguments from the executable at a space might have been incorrect,
15234    # since paths with space are more likely in Windows. Give it another try with the whole
15235    # argument.
15236    path="$complete"
15237    arguments="EOL"
15238    new_path="$path"
15239
15240  windows_path="$new_path"
15241  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15242    unix_path=`$CYGPATH -u "$windows_path"`
15243    new_path="$unix_path"
15244  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15245    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15246    new_path="$unix_path"
15247  fi
15248
15249
15250    new_path=`$WHICH "$new_path" 2> /dev/null`
15251
15252    if test "x$new_path" = x; then
15253      # It's still not found. Now this is an unrecoverable error.
15254      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15255$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15256      has_space=`$ECHO "$complete" | $GREP " "`
15257      if test "x$has_space" != x; then
15258        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15259$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15260      fi
15261      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15262    fi
15263  fi
15264
15265  # Now new_path has a complete unix path to the binary
15266  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15267    # Keep paths in /bin as-is, but remove trailing .exe if any
15268    new_path="${new_path/%.exe/}"
15269    # Do not save /bin paths to all_fixpath_prefixes!
15270  else
15271    # Not in mixed or Windows style, start by that.
15272    new_path=`cmd //c echo $new_path`
15273
15274  input_path="$new_path"
15275  # Check if we need to convert this using DOS-style short mode. If the path
15276  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15277  # take no chances and rewrite it.
15278  # Note: m4 eats our [], so we need to use [ and ] instead.
15279  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15280  if test "x$has_forbidden_chars" != x; then
15281    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15282    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15283  fi
15284
15285    # Output is in $new_path
15286
15287  windows_path="$new_path"
15288  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15289    unix_path=`$CYGPATH -u "$windows_path"`
15290    new_path="$unix_path"
15291  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15292    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15293    new_path="$unix_path"
15294  fi
15295
15296    # remove trailing .exe if any
15297    new_path="${new_path/%.exe/}"
15298
15299    # Save the first 10 bytes of this path to the storage, so fixpath can work.
15300    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15301  fi
15302
15303  else
15304    # We're on a posix platform. Hooray! :)
15305    # First separate the path from the arguments. This will split at the first
15306    # space.
15307    complete="$FOUND_MAKE"
15308    path="${complete%% *}"
15309    tmp="$complete EOL"
15310    arguments="${tmp#* }"
15311
15312    # Cannot rely on the command "which" here since it doesn't always work.
15313    is_absolute_path=`$ECHO "$path" | $GREP ^/`
15314    if test -z "$is_absolute_path"; then
15315      # Path to executable is not absolute. Find it.
15316      IFS_save="$IFS"
15317      IFS=:
15318      for p in $PATH; do
15319        if test -f "$p/$path" && test -x "$p/$path"; then
15320          new_path="$p/$path"
15321          break
15322        fi
15323      done
15324      IFS="$IFS_save"
15325    else
15326      # This is an absolute path, we can use it without further modifications.
15327      new_path="$path"
15328    fi
15329
15330    if test "x$new_path" = x; then
15331      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15332$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15333      has_space=`$ECHO "$complete" | $GREP " "`
15334      if test "x$has_space" != x; then
15335        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15336$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15337      fi
15338      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15339    fi
15340  fi
15341
15342  # Now join together the path and the arguments once again
15343  if test "x$arguments" != xEOL; then
15344    new_complete="$new_path ${arguments% *}"
15345  else
15346    new_complete="$new_path"
15347  fi
15348
15349  if test "x$complete" != "x$new_complete"; then
15350    FOUND_MAKE="$new_complete"
15351    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15352$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15353  fi
15354
15355        fi
15356      fi
15357    fi
15358  fi
15359
15360    if test "x$FOUND_MAKE" = x; then
15361      as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5
15362    fi
15363  else
15364    # Try our hardest to locate a correct version of GNU make
15365    for ac_prog in gmake
15366do
15367  # Extract the first word of "$ac_prog", so it can be a program name with args.
15368set dummy $ac_prog; ac_word=$2
15369{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15370$as_echo_n "checking for $ac_word... " >&6; }
15371if ${ac_cv_path_CHECK_GMAKE+:} false; then :
15372  $as_echo_n "(cached) " >&6
15373else
15374  case $CHECK_GMAKE in
15375  [\\/]* | ?:[\\/]*)
15376  ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path.
15377  ;;
15378  *)
15379  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15380for as_dir in $PATH
15381do
15382  IFS=$as_save_IFS
15383  test -z "$as_dir" && as_dir=.
15384    for ac_exec_ext in '' $ac_executable_extensions; do
15385  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15386    ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15387    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15388    break 2
15389  fi
15390done
15391  done
15392IFS=$as_save_IFS
15393
15394  ;;
15395esac
15396fi
15397CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE
15398if test -n "$CHECK_GMAKE"; then
15399  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5
15400$as_echo "$CHECK_GMAKE" >&6; }
15401else
15402  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15403$as_echo "no" >&6; }
15404fi
15405
15406
15407  test -n "$CHECK_GMAKE" && break
15408done
15409
15410
15411  MAKE_CANDIDATE=""$CHECK_GMAKE""
15412  DESCRIPTION="gmake in PATH"
15413  if test "x$MAKE_CANDIDATE" != x; then
15414    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15415$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15416    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15417    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15418    if test "x$IS_GNU_MAKE" = x; then
15419      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15420$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15421    else
15422      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15423      if test "x$IS_MODERN_MAKE" = x; then
15424        { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15425$as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15426      else
15427        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15428          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15429            MAKE_EXPECTED_ENV='cygwin'
15430          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15431            MAKE_EXPECTED_ENV='msys'
15432          else
15433            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15434          fi
15435          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15436          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15437        else
15438          # Not relevant for non-Windows
15439          IS_MAKE_CORRECT_ENV=true
15440        fi
15441        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15442          { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
15443$as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
15444        else
15445          FOUND_MAKE=$MAKE_CANDIDATE
15446
15447  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15448
15449  # First separate the path from the arguments. This will split at the first
15450  # space.
15451  complete="$FOUND_MAKE"
15452  path="${complete%% *}"
15453  tmp="$complete EOL"
15454  arguments="${tmp#* }"
15455
15456  # Input might be given as Windows format, start by converting to
15457  # unix format.
15458  new_path=`$CYGPATH -u "$path"`
15459
15460  # Now try to locate executable using which
15461  new_path=`$WHICH "$new_path" 2> /dev/null`
15462  # bat and cmd files are not always considered executable in cygwin causing which
15463  # to not find them
15464  if test "x$new_path" = x \
15465      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15466      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15467    new_path=`$CYGPATH -u "$path"`
15468  fi
15469  if test "x$new_path" = x; then
15470    # Oops. Which didn't find the executable.
15471    # The splitting of arguments from the executable at a space might have been incorrect,
15472    # since paths with space are more likely in Windows. Give it another try with the whole
15473    # argument.
15474    path="$complete"
15475    arguments="EOL"
15476    new_path=`$CYGPATH -u "$path"`
15477    new_path=`$WHICH "$new_path" 2> /dev/null`
15478    # bat and cmd files are not always considered executable in cygwin causing which
15479    # to not find them
15480    if test "x$new_path" = x \
15481        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15482        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15483      new_path=`$CYGPATH -u "$path"`
15484    fi
15485    if test "x$new_path" = x; then
15486      # It's still not found. Now this is an unrecoverable error.
15487      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15488$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15489      has_space=`$ECHO "$complete" | $GREP " "`
15490      if test "x$has_space" != x; then
15491        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15492$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15493      fi
15494      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15495    fi
15496  fi
15497
15498  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15499  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15500  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15501  # "foo.exe" is OK but "foo" is an error.
15502  #
15503  # This test is therefore slightly more accurate than "test -f" to check for file presence.
15504  # It is also a way to make sure we got the proper file name for the real test later on.
15505  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15506  if test "x$test_shortpath" = x; then
15507    # Short path failed, file does not exist as specified.
15508    # Try adding .exe or .cmd
15509    if test -f "${new_path}.exe"; then
15510      input_to_shortpath="${new_path}.exe"
15511    elif test -f "${new_path}.cmd"; then
15512      input_to_shortpath="${new_path}.cmd"
15513    else
15514      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15515$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15516      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15517$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15518      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15519    fi
15520  else
15521    input_to_shortpath="$new_path"
15522  fi
15523
15524  # Call helper function which possibly converts this using DOS-style short mode.
15525  # If so, the updated path is stored in $new_path.
15526  new_path="$input_to_shortpath"
15527
15528  input_path="$input_to_shortpath"
15529  # Check if we need to convert this using DOS-style short mode. If the path
15530  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15531  # take no chances and rewrite it.
15532  # Note: m4 eats our [], so we need to use [ and ] instead.
15533  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15534  if test "x$has_forbidden_chars" != x; then
15535    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15536    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15537    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15538    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15539      # Going to short mode and back again did indeed matter. Since short mode is
15540      # case insensitive, let's make it lowercase to improve readability.
15541      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15542      # Now convert it back to Unix-stile (cygpath)
15543      input_path=`$CYGPATH -u "$shortmode_path"`
15544      new_path="$input_path"
15545    fi
15546  fi
15547
15548  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15549  if test "x$test_cygdrive_prefix" = x; then
15550    # As a simple fix, exclude /usr/bin since it's not a real path.
15551    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15552      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15553      # a path prefixed by /cygdrive for fixpath to work.
15554      new_path="$CYGWIN_ROOT_PATH$input_path"
15555    fi
15556  fi
15557
15558  # remove trailing .exe if any
15559  new_path="${new_path/%.exe/}"
15560
15561  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15562
15563  # First separate the path from the arguments. This will split at the first
15564  # space.
15565  complete="$FOUND_MAKE"
15566  path="${complete%% *}"
15567  tmp="$complete EOL"
15568  arguments="${tmp#* }"
15569
15570  # Input might be given as Windows format, start by converting to
15571  # unix format.
15572  new_path="$path"
15573
15574  windows_path="$new_path"
15575  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15576    unix_path=`$CYGPATH -u "$windows_path"`
15577    new_path="$unix_path"
15578  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15579    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15580    new_path="$unix_path"
15581  fi
15582
15583
15584  # Now try to locate executable using which
15585  new_path=`$WHICH "$new_path" 2> /dev/null`
15586
15587  if test "x$new_path" = x; then
15588    # Oops. Which didn't find the executable.
15589    # The splitting of arguments from the executable at a space might have been incorrect,
15590    # since paths with space are more likely in Windows. Give it another try with the whole
15591    # argument.
15592    path="$complete"
15593    arguments="EOL"
15594    new_path="$path"
15595
15596  windows_path="$new_path"
15597  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15598    unix_path=`$CYGPATH -u "$windows_path"`
15599    new_path="$unix_path"
15600  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15601    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15602    new_path="$unix_path"
15603  fi
15604
15605
15606    new_path=`$WHICH "$new_path" 2> /dev/null`
15607
15608    if test "x$new_path" = x; then
15609      # It's still not found. Now this is an unrecoverable error.
15610      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15611$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15612      has_space=`$ECHO "$complete" | $GREP " "`
15613      if test "x$has_space" != x; then
15614        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15615$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15616      fi
15617      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15618    fi
15619  fi
15620
15621  # Now new_path has a complete unix path to the binary
15622  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15623    # Keep paths in /bin as-is, but remove trailing .exe if any
15624    new_path="${new_path/%.exe/}"
15625    # Do not save /bin paths to all_fixpath_prefixes!
15626  else
15627    # Not in mixed or Windows style, start by that.
15628    new_path=`cmd //c echo $new_path`
15629
15630  input_path="$new_path"
15631  # Check if we need to convert this using DOS-style short mode. If the path
15632  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15633  # take no chances and rewrite it.
15634  # Note: m4 eats our [], so we need to use [ and ] instead.
15635  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15636  if test "x$has_forbidden_chars" != x; then
15637    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15638    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15639  fi
15640
15641    # Output is in $new_path
15642
15643  windows_path="$new_path"
15644  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15645    unix_path=`$CYGPATH -u "$windows_path"`
15646    new_path="$unix_path"
15647  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15648    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15649    new_path="$unix_path"
15650  fi
15651
15652    # remove trailing .exe if any
15653    new_path="${new_path/%.exe/}"
15654
15655    # Save the first 10 bytes of this path to the storage, so fixpath can work.
15656    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15657  fi
15658
15659  else
15660    # We're on a posix platform. Hooray! :)
15661    # First separate the path from the arguments. This will split at the first
15662    # space.
15663    complete="$FOUND_MAKE"
15664    path="${complete%% *}"
15665    tmp="$complete EOL"
15666    arguments="${tmp#* }"
15667
15668    # Cannot rely on the command "which" here since it doesn't always work.
15669    is_absolute_path=`$ECHO "$path" | $GREP ^/`
15670    if test -z "$is_absolute_path"; then
15671      # Path to executable is not absolute. Find it.
15672      IFS_save="$IFS"
15673      IFS=:
15674      for p in $PATH; do
15675        if test -f "$p/$path" && test -x "$p/$path"; then
15676          new_path="$p/$path"
15677          break
15678        fi
15679      done
15680      IFS="$IFS_save"
15681    else
15682      # This is an absolute path, we can use it without further modifications.
15683      new_path="$path"
15684    fi
15685
15686    if test "x$new_path" = x; then
15687      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15688$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15689      has_space=`$ECHO "$complete" | $GREP " "`
15690      if test "x$has_space" != x; then
15691        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15692$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15693      fi
15694      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15695    fi
15696  fi
15697
15698  # Now join together the path and the arguments once again
15699  if test "x$arguments" != xEOL; then
15700    new_complete="$new_path ${arguments% *}"
15701  else
15702    new_complete="$new_path"
15703  fi
15704
15705  if test "x$complete" != "x$new_complete"; then
15706    FOUND_MAKE="$new_complete"
15707    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15708$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15709  fi
15710
15711        fi
15712      fi
15713    fi
15714  fi
15715
15716
15717    if test "x$FOUND_MAKE" = x; then
15718      for ac_prog in make
15719do
15720  # Extract the first word of "$ac_prog", so it can be a program name with args.
15721set dummy $ac_prog; ac_word=$2
15722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15723$as_echo_n "checking for $ac_word... " >&6; }
15724if ${ac_cv_path_CHECK_MAKE+:} false; then :
15725  $as_echo_n "(cached) " >&6
15726else
15727  case $CHECK_MAKE in
15728  [\\/]* | ?:[\\/]*)
15729  ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path.
15730  ;;
15731  *)
15732  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15733for as_dir in $PATH
15734do
15735  IFS=$as_save_IFS
15736  test -z "$as_dir" && as_dir=.
15737    for ac_exec_ext in '' $ac_executable_extensions; do
15738  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15739    ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext"
15740    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15741    break 2
15742  fi
15743done
15744  done
15745IFS=$as_save_IFS
15746
15747  ;;
15748esac
15749fi
15750CHECK_MAKE=$ac_cv_path_CHECK_MAKE
15751if test -n "$CHECK_MAKE"; then
15752  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5
15753$as_echo "$CHECK_MAKE" >&6; }
15754else
15755  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15756$as_echo "no" >&6; }
15757fi
15758
15759
15760  test -n "$CHECK_MAKE" && break
15761done
15762
15763
15764  MAKE_CANDIDATE=""$CHECK_MAKE""
15765  DESCRIPTION="make in PATH"
15766  if test "x$MAKE_CANDIDATE" != x; then
15767    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15768$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15769    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15770    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15771    if test "x$IS_GNU_MAKE" = x; then
15772      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15773$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15774    else
15775      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15776      if test "x$IS_MODERN_MAKE" = x; then
15777        { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15778$as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15779      else
15780        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15781          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15782            MAKE_EXPECTED_ENV='cygwin'
15783          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15784            MAKE_EXPECTED_ENV='msys'
15785          else
15786            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15787          fi
15788          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15789          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15790        else
15791          # Not relevant for non-Windows
15792          IS_MAKE_CORRECT_ENV=true
15793        fi
15794        if test "x$IS_MAKE_CORRECT_ENV" = x; then
15795          { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
15796$as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
15797        else
15798          FOUND_MAKE=$MAKE_CANDIDATE
15799
15800  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15801
15802  # First separate the path from the arguments. This will split at the first
15803  # space.
15804  complete="$FOUND_MAKE"
15805  path="${complete%% *}"
15806  tmp="$complete EOL"
15807  arguments="${tmp#* }"
15808
15809  # Input might be given as Windows format, start by converting to
15810  # unix format.
15811  new_path=`$CYGPATH -u "$path"`
15812
15813  # Now try to locate executable using which
15814  new_path=`$WHICH "$new_path" 2> /dev/null`
15815  # bat and cmd files are not always considered executable in cygwin causing which
15816  # to not find them
15817  if test "x$new_path" = x \
15818      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15819      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15820    new_path=`$CYGPATH -u "$path"`
15821  fi
15822  if test "x$new_path" = x; then
15823    # Oops. Which didn't find the executable.
15824    # The splitting of arguments from the executable at a space might have been incorrect,
15825    # since paths with space are more likely in Windows. Give it another try with the whole
15826    # argument.
15827    path="$complete"
15828    arguments="EOL"
15829    new_path=`$CYGPATH -u "$path"`
15830    new_path=`$WHICH "$new_path" 2> /dev/null`
15831    # bat and cmd files are not always considered executable in cygwin causing which
15832    # to not find them
15833    if test "x$new_path" = x \
15834        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15835        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15836      new_path=`$CYGPATH -u "$path"`
15837    fi
15838    if test "x$new_path" = x; then
15839      # It's still not found. Now this is an unrecoverable error.
15840      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15841$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15842      has_space=`$ECHO "$complete" | $GREP " "`
15843      if test "x$has_space" != x; then
15844        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15845$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15846      fi
15847      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15848    fi
15849  fi
15850
15851  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15852  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15853  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15854  # "foo.exe" is OK but "foo" is an error.
15855  #
15856  # This test is therefore slightly more accurate than "test -f" to check for file presence.
15857  # It is also a way to make sure we got the proper file name for the real test later on.
15858  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15859  if test "x$test_shortpath" = x; then
15860    # Short path failed, file does not exist as specified.
15861    # Try adding .exe or .cmd
15862    if test -f "${new_path}.exe"; then
15863      input_to_shortpath="${new_path}.exe"
15864    elif test -f "${new_path}.cmd"; then
15865      input_to_shortpath="${new_path}.cmd"
15866    else
15867      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15868$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15869      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15870$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15871      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15872    fi
15873  else
15874    input_to_shortpath="$new_path"
15875  fi
15876
15877  # Call helper function which possibly converts this using DOS-style short mode.
15878  # If so, the updated path is stored in $new_path.
15879  new_path="$input_to_shortpath"
15880
15881  input_path="$input_to_shortpath"
15882  # Check if we need to convert this using DOS-style short mode. If the path
15883  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15884  # take no chances and rewrite it.
15885  # Note: m4 eats our [], so we need to use [ and ] instead.
15886  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15887  if test "x$has_forbidden_chars" != x; then
15888    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15889    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15890    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15891    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15892      # Going to short mode and back again did indeed matter. Since short mode is
15893      # case insensitive, let's make it lowercase to improve readability.
15894      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15895      # Now convert it back to Unix-stile (cygpath)
15896      input_path=`$CYGPATH -u "$shortmode_path"`
15897      new_path="$input_path"
15898    fi
15899  fi
15900
15901  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15902  if test "x$test_cygdrive_prefix" = x; then
15903    # As a simple fix, exclude /usr/bin since it's not a real path.
15904    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15905      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15906      # a path prefixed by /cygdrive for fixpath to work.
15907      new_path="$CYGWIN_ROOT_PATH$input_path"
15908    fi
15909  fi
15910
15911  # remove trailing .exe if any
15912  new_path="${new_path/%.exe/}"
15913
15914  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15915
15916  # First separate the path from the arguments. This will split at the first
15917  # space.
15918  complete="$FOUND_MAKE"
15919  path="${complete%% *}"
15920  tmp="$complete EOL"
15921  arguments="${tmp#* }"
15922
15923  # Input might be given as Windows format, start by converting to
15924  # unix format.
15925  new_path="$path"
15926
15927  windows_path="$new_path"
15928  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15929    unix_path=`$CYGPATH -u "$windows_path"`
15930    new_path="$unix_path"
15931  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15932    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15933    new_path="$unix_path"
15934  fi
15935
15936
15937  # Now try to locate executable using which
15938  new_path=`$WHICH "$new_path" 2> /dev/null`
15939
15940  if test "x$new_path" = x; then
15941    # Oops. Which didn't find the executable.
15942    # The splitting of arguments from the executable at a space might have been incorrect,
15943    # since paths with space are more likely in Windows. Give it another try with the whole
15944    # argument.
15945    path="$complete"
15946    arguments="EOL"
15947    new_path="$path"
15948
15949  windows_path="$new_path"
15950  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15951    unix_path=`$CYGPATH -u "$windows_path"`
15952    new_path="$unix_path"
15953  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15954    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15955    new_path="$unix_path"
15956  fi
15957
15958
15959    new_path=`$WHICH "$new_path" 2> /dev/null`
15960
15961    if test "x$new_path" = x; then
15962      # It's still not found. Now this is an unrecoverable error.
15963      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15964$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15965      has_space=`$ECHO "$complete" | $GREP " "`
15966      if test "x$has_space" != x; then
15967        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15968$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15969      fi
15970      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15971    fi
15972  fi
15973
15974  # Now new_path has a complete unix path to the binary
15975  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15976    # Keep paths in /bin as-is, but remove trailing .exe if any
15977    new_path="${new_path/%.exe/}"
15978    # Do not save /bin paths to all_fixpath_prefixes!
15979  else
15980    # Not in mixed or Windows style, start by that.
15981    new_path=`cmd //c echo $new_path`
15982
15983  input_path="$new_path"
15984  # Check if we need to convert this using DOS-style short mode. If the path
15985  # contains just simple characters, use it. Otherwise (spaces, weird characters),
15986  # take no chances and rewrite it.
15987  # Note: m4 eats our [], so we need to use [ and ] instead.
15988  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15989  if test "x$has_forbidden_chars" != x; then
15990    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15991    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15992  fi
15993
15994    # Output is in $new_path
15995
15996  windows_path="$new_path"
15997  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15998    unix_path=`$CYGPATH -u "$windows_path"`
15999    new_path="$unix_path"
16000  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16001    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16002    new_path="$unix_path"
16003  fi
16004
16005    # remove trailing .exe if any
16006    new_path="${new_path/%.exe/}"
16007
16008    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16009    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16010  fi
16011
16012  else
16013    # We're on a posix platform. Hooray! :)
16014    # First separate the path from the arguments. This will split at the first
16015    # space.
16016    complete="$FOUND_MAKE"
16017    path="${complete%% *}"
16018    tmp="$complete EOL"
16019    arguments="${tmp#* }"
16020
16021    # Cannot rely on the command "which" here since it doesn't always work.
16022    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16023    if test -z "$is_absolute_path"; then
16024      # Path to executable is not absolute. Find it.
16025      IFS_save="$IFS"
16026      IFS=:
16027      for p in $PATH; do
16028        if test -f "$p/$path" && test -x "$p/$path"; then
16029          new_path="$p/$path"
16030          break
16031        fi
16032      done
16033      IFS="$IFS_save"
16034    else
16035      # This is an absolute path, we can use it without further modifications.
16036      new_path="$path"
16037    fi
16038
16039    if test "x$new_path" = x; then
16040      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16041$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16042      has_space=`$ECHO "$complete" | $GREP " "`
16043      if test "x$has_space" != x; then
16044        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16045$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16046      fi
16047      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16048    fi
16049  fi
16050
16051  # Now join together the path and the arguments once again
16052  if test "x$arguments" != xEOL; then
16053    new_complete="$new_path ${arguments% *}"
16054  else
16055    new_complete="$new_path"
16056  fi
16057
16058  if test "x$complete" != "x$new_complete"; then
16059    FOUND_MAKE="$new_complete"
16060    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16061$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16062  fi
16063
16064        fi
16065      fi
16066    fi
16067  fi
16068
16069    fi
16070
16071    if test "x$FOUND_MAKE" = x; then
16072      if test "x$TOOLS_DIR" != x; then
16073        # We have a tools-dir, check that as well before giving up.
16074        OLD_PATH=$PATH
16075        PATH=$TOOLS_DIR:$PATH
16076        for ac_prog in gmake
16077do
16078  # Extract the first word of "$ac_prog", so it can be a program name with args.
16079set dummy $ac_prog; ac_word=$2
16080{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16081$as_echo_n "checking for $ac_word... " >&6; }
16082if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16083  $as_echo_n "(cached) " >&6
16084else
16085  case $CHECK_TOOLSDIR_GMAKE in
16086  [\\/]* | ?:[\\/]*)
16087  ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16088  ;;
16089  *)
16090  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16091for as_dir in $PATH
16092do
16093  IFS=$as_save_IFS
16094  test -z "$as_dir" && as_dir=.
16095    for ac_exec_ext in '' $ac_executable_extensions; do
16096  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16097    ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext"
16098    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16099    break 2
16100  fi
16101done
16102  done
16103IFS=$as_save_IFS
16104
16105  ;;
16106esac
16107fi
16108CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE
16109if test -n "$CHECK_TOOLSDIR_GMAKE"; then
16110  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5
16111$as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; }
16112else
16113  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16114$as_echo "no" >&6; }
16115fi
16116
16117
16118  test -n "$CHECK_TOOLSDIR_GMAKE" && break
16119done
16120
16121
16122  MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE""
16123  DESCRIPTION="gmake in tools-dir"
16124  if test "x$MAKE_CANDIDATE" != x; then
16125    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16126$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16127    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16128    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16129    if test "x$IS_GNU_MAKE" = x; then
16130      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16131$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16132    else
16133      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16134      if test "x$IS_MODERN_MAKE" = x; then
16135        { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
16136$as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
16137      else
16138        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16139          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16140            MAKE_EXPECTED_ENV='cygwin'
16141          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16142            MAKE_EXPECTED_ENV='msys'
16143          else
16144            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16145          fi
16146          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16147          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16148        else
16149          # Not relevant for non-Windows
16150          IS_MAKE_CORRECT_ENV=true
16151        fi
16152        if test "x$IS_MAKE_CORRECT_ENV" = x; then
16153          { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
16154$as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
16155        else
16156          FOUND_MAKE=$MAKE_CANDIDATE
16157
16158  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16159
16160  # First separate the path from the arguments. This will split at the first
16161  # space.
16162  complete="$FOUND_MAKE"
16163  path="${complete%% *}"
16164  tmp="$complete EOL"
16165  arguments="${tmp#* }"
16166
16167  # Input might be given as Windows format, start by converting to
16168  # unix format.
16169  new_path=`$CYGPATH -u "$path"`
16170
16171  # Now try to locate executable using which
16172  new_path=`$WHICH "$new_path" 2> /dev/null`
16173  # bat and cmd files are not always considered executable in cygwin causing which
16174  # to not find them
16175  if test "x$new_path" = x \
16176      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16177      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16178    new_path=`$CYGPATH -u "$path"`
16179  fi
16180  if test "x$new_path" = x; then
16181    # Oops. Which didn't find the executable.
16182    # The splitting of arguments from the executable at a space might have been incorrect,
16183    # since paths with space are more likely in Windows. Give it another try with the whole
16184    # argument.
16185    path="$complete"
16186    arguments="EOL"
16187    new_path=`$CYGPATH -u "$path"`
16188    new_path=`$WHICH "$new_path" 2> /dev/null`
16189    # bat and cmd files are not always considered executable in cygwin causing which
16190    # to not find them
16191    if test "x$new_path" = x \
16192        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16193        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16194      new_path=`$CYGPATH -u "$path"`
16195    fi
16196    if test "x$new_path" = x; then
16197      # It's still not found. Now this is an unrecoverable error.
16198      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16199$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16200      has_space=`$ECHO "$complete" | $GREP " "`
16201      if test "x$has_space" != x; then
16202        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16203$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16204      fi
16205      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16206    fi
16207  fi
16208
16209  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16210  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16211  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16212  # "foo.exe" is OK but "foo" is an error.
16213  #
16214  # This test is therefore slightly more accurate than "test -f" to check for file presence.
16215  # It is also a way to make sure we got the proper file name for the real test later on.
16216  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16217  if test "x$test_shortpath" = x; then
16218    # Short path failed, file does not exist as specified.
16219    # Try adding .exe or .cmd
16220    if test -f "${new_path}.exe"; then
16221      input_to_shortpath="${new_path}.exe"
16222    elif test -f "${new_path}.cmd"; then
16223      input_to_shortpath="${new_path}.cmd"
16224    else
16225      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16226$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16227      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16228$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16229      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16230    fi
16231  else
16232    input_to_shortpath="$new_path"
16233  fi
16234
16235  # Call helper function which possibly converts this using DOS-style short mode.
16236  # If so, the updated path is stored in $new_path.
16237  new_path="$input_to_shortpath"
16238
16239  input_path="$input_to_shortpath"
16240  # Check if we need to convert this using DOS-style short mode. If the path
16241  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16242  # take no chances and rewrite it.
16243  # Note: m4 eats our [], so we need to use [ and ] instead.
16244  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16245  if test "x$has_forbidden_chars" != x; then
16246    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16247    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16248    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16249    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16250      # Going to short mode and back again did indeed matter. Since short mode is
16251      # case insensitive, let's make it lowercase to improve readability.
16252      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16253      # Now convert it back to Unix-stile (cygpath)
16254      input_path=`$CYGPATH -u "$shortmode_path"`
16255      new_path="$input_path"
16256    fi
16257  fi
16258
16259  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16260  if test "x$test_cygdrive_prefix" = x; then
16261    # As a simple fix, exclude /usr/bin since it's not a real path.
16262    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16263      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16264      # a path prefixed by /cygdrive for fixpath to work.
16265      new_path="$CYGWIN_ROOT_PATH$input_path"
16266    fi
16267  fi
16268
16269  # remove trailing .exe if any
16270  new_path="${new_path/%.exe/}"
16271
16272  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16273
16274  # First separate the path from the arguments. This will split at the first
16275  # space.
16276  complete="$FOUND_MAKE"
16277  path="${complete%% *}"
16278  tmp="$complete EOL"
16279  arguments="${tmp#* }"
16280
16281  # Input might be given as Windows format, start by converting to
16282  # unix format.
16283  new_path="$path"
16284
16285  windows_path="$new_path"
16286  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16287    unix_path=`$CYGPATH -u "$windows_path"`
16288    new_path="$unix_path"
16289  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16290    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16291    new_path="$unix_path"
16292  fi
16293
16294
16295  # Now try to locate executable using which
16296  new_path=`$WHICH "$new_path" 2> /dev/null`
16297
16298  if test "x$new_path" = x; then
16299    # Oops. Which didn't find the executable.
16300    # The splitting of arguments from the executable at a space might have been incorrect,
16301    # since paths with space are more likely in Windows. Give it another try with the whole
16302    # argument.
16303    path="$complete"
16304    arguments="EOL"
16305    new_path="$path"
16306
16307  windows_path="$new_path"
16308  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16309    unix_path=`$CYGPATH -u "$windows_path"`
16310    new_path="$unix_path"
16311  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16312    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16313    new_path="$unix_path"
16314  fi
16315
16316
16317    new_path=`$WHICH "$new_path" 2> /dev/null`
16318
16319    if test "x$new_path" = x; then
16320      # It's still not found. Now this is an unrecoverable error.
16321      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16322$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16323      has_space=`$ECHO "$complete" | $GREP " "`
16324      if test "x$has_space" != x; then
16325        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16326$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16327      fi
16328      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16329    fi
16330  fi
16331
16332  # Now new_path has a complete unix path to the binary
16333  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16334    # Keep paths in /bin as-is, but remove trailing .exe if any
16335    new_path="${new_path/%.exe/}"
16336    # Do not save /bin paths to all_fixpath_prefixes!
16337  else
16338    # Not in mixed or Windows style, start by that.
16339    new_path=`cmd //c echo $new_path`
16340
16341  input_path="$new_path"
16342  # Check if we need to convert this using DOS-style short mode. If the path
16343  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16344  # take no chances and rewrite it.
16345  # Note: m4 eats our [], so we need to use [ and ] instead.
16346  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16347  if test "x$has_forbidden_chars" != x; then
16348    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16349    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16350  fi
16351
16352    # Output is in $new_path
16353
16354  windows_path="$new_path"
16355  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16356    unix_path=`$CYGPATH -u "$windows_path"`
16357    new_path="$unix_path"
16358  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16359    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16360    new_path="$unix_path"
16361  fi
16362
16363    # remove trailing .exe if any
16364    new_path="${new_path/%.exe/}"
16365
16366    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16367    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16368  fi
16369
16370  else
16371    # We're on a posix platform. Hooray! :)
16372    # First separate the path from the arguments. This will split at the first
16373    # space.
16374    complete="$FOUND_MAKE"
16375    path="${complete%% *}"
16376    tmp="$complete EOL"
16377    arguments="${tmp#* }"
16378
16379    # Cannot rely on the command "which" here since it doesn't always work.
16380    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16381    if test -z "$is_absolute_path"; then
16382      # Path to executable is not absolute. Find it.
16383      IFS_save="$IFS"
16384      IFS=:
16385      for p in $PATH; do
16386        if test -f "$p/$path" && test -x "$p/$path"; then
16387          new_path="$p/$path"
16388          break
16389        fi
16390      done
16391      IFS="$IFS_save"
16392    else
16393      # This is an absolute path, we can use it without further modifications.
16394      new_path="$path"
16395    fi
16396
16397    if test "x$new_path" = x; then
16398      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16399$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16400      has_space=`$ECHO "$complete" | $GREP " "`
16401      if test "x$has_space" != x; then
16402        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16403$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16404      fi
16405      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16406    fi
16407  fi
16408
16409  # Now join together the path and the arguments once again
16410  if test "x$arguments" != xEOL; then
16411    new_complete="$new_path ${arguments% *}"
16412  else
16413    new_complete="$new_path"
16414  fi
16415
16416  if test "x$complete" != "x$new_complete"; then
16417    FOUND_MAKE="$new_complete"
16418    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16419$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16420  fi
16421
16422        fi
16423      fi
16424    fi
16425  fi
16426
16427        if test "x$FOUND_MAKE" = x; then
16428          for ac_prog in make
16429do
16430  # Extract the first word of "$ac_prog", so it can be a program name with args.
16431set dummy $ac_prog; ac_word=$2
16432{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16433$as_echo_n "checking for $ac_word... " >&6; }
16434if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then :
16435  $as_echo_n "(cached) " >&6
16436else
16437  case $CHECK_TOOLSDIR_MAKE in
16438  [\\/]* | ?:[\\/]*)
16439  ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path.
16440  ;;
16441  *)
16442  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16443for as_dir in $PATH
16444do
16445  IFS=$as_save_IFS
16446  test -z "$as_dir" && as_dir=.
16447    for ac_exec_ext in '' $ac_executable_extensions; do
16448  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16449    ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext"
16450    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16451    break 2
16452  fi
16453done
16454  done
16455IFS=$as_save_IFS
16456
16457  ;;
16458esac
16459fi
16460CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE
16461if test -n "$CHECK_TOOLSDIR_MAKE"; then
16462  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5
16463$as_echo "$CHECK_TOOLSDIR_MAKE" >&6; }
16464else
16465  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16466$as_echo "no" >&6; }
16467fi
16468
16469
16470  test -n "$CHECK_TOOLSDIR_MAKE" && break
16471done
16472
16473
16474  MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE""
16475  DESCRIPTION="make in tools-dir"
16476  if test "x$MAKE_CANDIDATE" != x; then
16477    { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16478$as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16479    MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16480    IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16481    if test "x$IS_GNU_MAKE" = x; then
16482      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16483$as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16484    else
16485      IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16486      if test "x$IS_MODERN_MAKE" = x; then
16487        { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
16488$as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
16489      else
16490        if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16491          if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16492            MAKE_EXPECTED_ENV='cygwin'
16493          elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16494            MAKE_EXPECTED_ENV='msys'
16495          else
16496            as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16497          fi
16498          MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16499          IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16500        else
16501          # Not relevant for non-Windows
16502          IS_MAKE_CORRECT_ENV=true
16503        fi
16504        if test "x$IS_MAKE_CORRECT_ENV" = x; then
16505          { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
16506$as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
16507        else
16508          FOUND_MAKE=$MAKE_CANDIDATE
16509
16510  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16511
16512  # First separate the path from the arguments. This will split at the first
16513  # space.
16514  complete="$FOUND_MAKE"
16515  path="${complete%% *}"
16516  tmp="$complete EOL"
16517  arguments="${tmp#* }"
16518
16519  # Input might be given as Windows format, start by converting to
16520  # unix format.
16521  new_path=`$CYGPATH -u "$path"`
16522
16523  # Now try to locate executable using which
16524  new_path=`$WHICH "$new_path" 2> /dev/null`
16525  # bat and cmd files are not always considered executable in cygwin causing which
16526  # to not find them
16527  if test "x$new_path" = x \
16528      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16529      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16530    new_path=`$CYGPATH -u "$path"`
16531  fi
16532  if test "x$new_path" = x; then
16533    # Oops. Which didn't find the executable.
16534    # The splitting of arguments from the executable at a space might have been incorrect,
16535    # since paths with space are more likely in Windows. Give it another try with the whole
16536    # argument.
16537    path="$complete"
16538    arguments="EOL"
16539    new_path=`$CYGPATH -u "$path"`
16540    new_path=`$WHICH "$new_path" 2> /dev/null`
16541    # bat and cmd files are not always considered executable in cygwin causing which
16542    # to not find them
16543    if test "x$new_path" = x \
16544        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16545        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16546      new_path=`$CYGPATH -u "$path"`
16547    fi
16548    if test "x$new_path" = x; then
16549      # It's still not found. Now this is an unrecoverable error.
16550      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16551$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16552      has_space=`$ECHO "$complete" | $GREP " "`
16553      if test "x$has_space" != x; then
16554        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16555$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16556      fi
16557      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16558    fi
16559  fi
16560
16561  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16562  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16563  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16564  # "foo.exe" is OK but "foo" is an error.
16565  #
16566  # This test is therefore slightly more accurate than "test -f" to check for file presence.
16567  # It is also a way to make sure we got the proper file name for the real test later on.
16568  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16569  if test "x$test_shortpath" = x; then
16570    # Short path failed, file does not exist as specified.
16571    # Try adding .exe or .cmd
16572    if test -f "${new_path}.exe"; then
16573      input_to_shortpath="${new_path}.exe"
16574    elif test -f "${new_path}.cmd"; then
16575      input_to_shortpath="${new_path}.cmd"
16576    else
16577      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16578$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16579      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16580$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16581      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16582    fi
16583  else
16584    input_to_shortpath="$new_path"
16585  fi
16586
16587  # Call helper function which possibly converts this using DOS-style short mode.
16588  # If so, the updated path is stored in $new_path.
16589  new_path="$input_to_shortpath"
16590
16591  input_path="$input_to_shortpath"
16592  # Check if we need to convert this using DOS-style short mode. If the path
16593  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16594  # take no chances and rewrite it.
16595  # Note: m4 eats our [], so we need to use [ and ] instead.
16596  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16597  if test "x$has_forbidden_chars" != x; then
16598    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16599    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16600    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16601    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16602      # Going to short mode and back again did indeed matter. Since short mode is
16603      # case insensitive, let's make it lowercase to improve readability.
16604      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16605      # Now convert it back to Unix-stile (cygpath)
16606      input_path=`$CYGPATH -u "$shortmode_path"`
16607      new_path="$input_path"
16608    fi
16609  fi
16610
16611  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16612  if test "x$test_cygdrive_prefix" = x; then
16613    # As a simple fix, exclude /usr/bin since it's not a real path.
16614    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16615      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16616      # a path prefixed by /cygdrive for fixpath to work.
16617      new_path="$CYGWIN_ROOT_PATH$input_path"
16618    fi
16619  fi
16620
16621  # remove trailing .exe if any
16622  new_path="${new_path/%.exe/}"
16623
16624  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16625
16626  # First separate the path from the arguments. This will split at the first
16627  # space.
16628  complete="$FOUND_MAKE"
16629  path="${complete%% *}"
16630  tmp="$complete EOL"
16631  arguments="${tmp#* }"
16632
16633  # Input might be given as Windows format, start by converting to
16634  # unix format.
16635  new_path="$path"
16636
16637  windows_path="$new_path"
16638  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16639    unix_path=`$CYGPATH -u "$windows_path"`
16640    new_path="$unix_path"
16641  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16642    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16643    new_path="$unix_path"
16644  fi
16645
16646
16647  # Now try to locate executable using which
16648  new_path=`$WHICH "$new_path" 2> /dev/null`
16649
16650  if test "x$new_path" = x; then
16651    # Oops. Which didn't find the executable.
16652    # The splitting of arguments from the executable at a space might have been incorrect,
16653    # since paths with space are more likely in Windows. Give it another try with the whole
16654    # argument.
16655    path="$complete"
16656    arguments="EOL"
16657    new_path="$path"
16658
16659  windows_path="$new_path"
16660  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16661    unix_path=`$CYGPATH -u "$windows_path"`
16662    new_path="$unix_path"
16663  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16664    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16665    new_path="$unix_path"
16666  fi
16667
16668
16669    new_path=`$WHICH "$new_path" 2> /dev/null`
16670
16671    if test "x$new_path" = x; then
16672      # It's still not found. Now this is an unrecoverable error.
16673      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16674$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16675      has_space=`$ECHO "$complete" | $GREP " "`
16676      if test "x$has_space" != x; then
16677        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16678$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16679      fi
16680      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16681    fi
16682  fi
16683
16684  # Now new_path has a complete unix path to the binary
16685  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16686    # Keep paths in /bin as-is, but remove trailing .exe if any
16687    new_path="${new_path/%.exe/}"
16688    # Do not save /bin paths to all_fixpath_prefixes!
16689  else
16690    # Not in mixed or Windows style, start by that.
16691    new_path=`cmd //c echo $new_path`
16692
16693  input_path="$new_path"
16694  # Check if we need to convert this using DOS-style short mode. If the path
16695  # contains just simple characters, use it. Otherwise (spaces, weird characters),
16696  # take no chances and rewrite it.
16697  # Note: m4 eats our [], so we need to use [ and ] instead.
16698  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16699  if test "x$has_forbidden_chars" != x; then
16700    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16701    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16702  fi
16703
16704    # Output is in $new_path
16705
16706  windows_path="$new_path"
16707  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16708    unix_path=`$CYGPATH -u "$windows_path"`
16709    new_path="$unix_path"
16710  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16711    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16712    new_path="$unix_path"
16713  fi
16714
16715    # remove trailing .exe if any
16716    new_path="${new_path/%.exe/}"
16717
16718    # Save the first 10 bytes of this path to the storage, so fixpath can work.
16719    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16720  fi
16721
16722  else
16723    # We're on a posix platform. Hooray! :)
16724    # First separate the path from the arguments. This will split at the first
16725    # space.
16726    complete="$FOUND_MAKE"
16727    path="${complete%% *}"
16728    tmp="$complete EOL"
16729    arguments="${tmp#* }"
16730
16731    # Cannot rely on the command "which" here since it doesn't always work.
16732    is_absolute_path=`$ECHO "$path" | $GREP ^/`
16733    if test -z "$is_absolute_path"; then
16734      # Path to executable is not absolute. Find it.
16735      IFS_save="$IFS"
16736      IFS=:
16737      for p in $PATH; do
16738        if test -f "$p/$path" && test -x "$p/$path"; then
16739          new_path="$p/$path"
16740          break
16741        fi
16742      done
16743      IFS="$IFS_save"
16744    else
16745      # This is an absolute path, we can use it without further modifications.
16746      new_path="$path"
16747    fi
16748
16749    if test "x$new_path" = x; then
16750      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16751$as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16752      has_space=`$ECHO "$complete" | $GREP " "`
16753      if test "x$has_space" != x; then
16754        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16755$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16756      fi
16757      as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16758    fi
16759  fi
16760
16761  # Now join together the path and the arguments once again
16762  if test "x$arguments" != xEOL; then
16763    new_complete="$new_path ${arguments% *}"
16764  else
16765    new_complete="$new_path"
16766  fi
16767
16768  if test "x$complete" != "x$new_complete"; then
16769    FOUND_MAKE="$new_complete"
16770    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16771$as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16772  fi
16773
16774        fi
16775      fi
16776    fi
16777  fi
16778
16779        fi
16780        PATH=$OLD_PATH
16781      fi
16782    fi
16783
16784    if test "x$FOUND_MAKE" = x; then
16785      as_fn_error $? "Cannot find GNU make 3.81 or newer! Please put it in the path, or add e.g. MAKE=/opt/gmake3.81/make as argument to configure." "$LINENO" 5
16786    fi
16787  fi
16788
16789  MAKE=$FOUND_MAKE
16790
16791  { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5
16792$as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;}
16793
16794
16795
16796  # Test if find supports -delete
16797  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5
16798$as_echo_n "checking if find supports -delete... " >&6; }
16799  FIND_DELETE="-delete"
16800
16801  DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?)
16802
16803  echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete
16804
16805  TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1`
16806  if test -f $DELETEDIR/TestIfFindSupportsDelete; then
16807    # No, it does not.
16808    rm $DELETEDIR/TestIfFindSupportsDelete
16809    FIND_DELETE="-exec rm \{\} \+"
16810    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16811$as_echo "no" >&6; }
16812  else
16813    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16814$as_echo "yes" >&6; }
16815  fi
16816  rmdir $DELETEDIR
16817
16818
16819
16820  # These tools might not be installed by default,
16821  # need hint on how to install them.
16822
16823
16824
16825  # Publish this variable in the help.
16826
16827
16828  if test "x$UNZIP" = x; then
16829    # The variable is not set by user, try to locate tool using the code snippet
16830    for ac_prog in unzip
16831do
16832  # Extract the first word of "$ac_prog", so it can be a program name with args.
16833set dummy $ac_prog; ac_word=$2
16834{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16835$as_echo_n "checking for $ac_word... " >&6; }
16836if ${ac_cv_path_UNZIP+:} false; then :
16837  $as_echo_n "(cached) " >&6
16838else
16839  case $UNZIP in
16840  [\\/]* | ?:[\\/]*)
16841  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16842  ;;
16843  *)
16844  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16845for as_dir in $PATH
16846do
16847  IFS=$as_save_IFS
16848  test -z "$as_dir" && as_dir=.
16849    for ac_exec_ext in '' $ac_executable_extensions; do
16850  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16851    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16852    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16853    break 2
16854  fi
16855done
16856  done
16857IFS=$as_save_IFS
16858
16859  ;;
16860esac
16861fi
16862UNZIP=$ac_cv_path_UNZIP
16863if test -n "$UNZIP"; then
16864  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16865$as_echo "$UNZIP" >&6; }
16866else
16867  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16868$as_echo "no" >&6; }
16869fi
16870
16871
16872  test -n "$UNZIP" && break
16873done
16874
16875  else
16876    # The variable is set, but is it from the command line or the environment?
16877
16878    # Try to remove the string !UNZIP! from our list.
16879    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/}
16880    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
16881      # If it failed, the variable was not from the command line. Ignore it,
16882      # but warn the user (except for BASH, which is always set by the calling BASH).
16883      if test "xUNZIP" != xBASH; then
16884        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5
16885$as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;}
16886      fi
16887      # Try to locate tool using the code snippet
16888      for ac_prog in unzip
16889do
16890  # Extract the first word of "$ac_prog", so it can be a program name with args.
16891set dummy $ac_prog; ac_word=$2
16892{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16893$as_echo_n "checking for $ac_word... " >&6; }
16894if ${ac_cv_path_UNZIP+:} false; then :
16895  $as_echo_n "(cached) " >&6
16896else
16897  case $UNZIP in
16898  [\\/]* | ?:[\\/]*)
16899  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16900  ;;
16901  *)
16902  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16903for as_dir in $PATH
16904do
16905  IFS=$as_save_IFS
16906  test -z "$as_dir" && as_dir=.
16907    for ac_exec_ext in '' $ac_executable_extensions; do
16908  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16909    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16910    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16911    break 2
16912  fi
16913done
16914  done
16915IFS=$as_save_IFS
16916
16917  ;;
16918esac
16919fi
16920UNZIP=$ac_cv_path_UNZIP
16921if test -n "$UNZIP"; then
16922  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16923$as_echo "$UNZIP" >&6; }
16924else
16925  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16926$as_echo "no" >&6; }
16927fi
16928
16929
16930  test -n "$UNZIP" && break
16931done
16932
16933    else
16934      # If it succeeded, then it was overridden by the user. We will use it
16935      # for the tool.
16936
16937      # First remove it from the list of overridden variables, so we can test
16938      # for unknown variables in the end.
16939      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
16940
16941      # Check if the provided tool contains a complete path.
16942      tool_specified="$UNZIP"
16943      tool_basename="${tool_specified##*/}"
16944      if test "x$tool_basename" = "x$tool_specified"; then
16945        # A command without a complete path is provided, search $PATH.
16946        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5
16947$as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;}
16948        # Extract the first word of "$tool_basename", so it can be a program name with args.
16949set dummy $tool_basename; ac_word=$2
16950{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16951$as_echo_n "checking for $ac_word... " >&6; }
16952if ${ac_cv_path_UNZIP+:} false; then :
16953  $as_echo_n "(cached) " >&6
16954else
16955  case $UNZIP in
16956  [\\/]* | ?:[\\/]*)
16957  ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16958  ;;
16959  *)
16960  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16961for as_dir in $PATH
16962do
16963  IFS=$as_save_IFS
16964  test -z "$as_dir" && as_dir=.
16965    for ac_exec_ext in '' $ac_executable_extensions; do
16966  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16967    ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16968    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16969    break 2
16970  fi
16971done
16972  done
16973IFS=$as_save_IFS
16974
16975  ;;
16976esac
16977fi
16978UNZIP=$ac_cv_path_UNZIP
16979if test -n "$UNZIP"; then
16980  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16981$as_echo "$UNZIP" >&6; }
16982else
16983  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16984$as_echo "no" >&6; }
16985fi
16986
16987
16988        if test "x$UNZIP" = x; then
16989          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
16990        fi
16991      else
16992        # Otherwise we believe it is a complete path. Use it as it is.
16993        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5
16994$as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;}
16995        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5
16996$as_echo_n "checking for UNZIP... " >&6; }
16997        if test ! -x "$tool_specified"; then
16998          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
16999$as_echo "not found" >&6; }
17000          as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17001        fi
17002        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17003$as_echo "$tool_specified" >&6; }
17004      fi
17005    fi
17006  fi
17007
17008
17009
17010  if test "x$UNZIP" = x; then
17011    as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5
17012  fi
17013
17014
17015
17016
17017
17018  # Publish this variable in the help.
17019
17020
17021  if test "x$ZIP" = x; then
17022    # The variable is not set by user, try to locate tool using the code snippet
17023    for ac_prog in zip
17024do
17025  # Extract the first word of "$ac_prog", so it can be a program name with args.
17026set dummy $ac_prog; ac_word=$2
17027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17028$as_echo_n "checking for $ac_word... " >&6; }
17029if ${ac_cv_path_ZIP+:} false; then :
17030  $as_echo_n "(cached) " >&6
17031else
17032  case $ZIP in
17033  [\\/]* | ?:[\\/]*)
17034  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17035  ;;
17036  *)
17037  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17038for as_dir in $PATH
17039do
17040  IFS=$as_save_IFS
17041  test -z "$as_dir" && as_dir=.
17042    for ac_exec_ext in '' $ac_executable_extensions; do
17043  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17044    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17045    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17046    break 2
17047  fi
17048done
17049  done
17050IFS=$as_save_IFS
17051
17052  ;;
17053esac
17054fi
17055ZIP=$ac_cv_path_ZIP
17056if test -n "$ZIP"; then
17057  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17058$as_echo "$ZIP" >&6; }
17059else
17060  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17061$as_echo "no" >&6; }
17062fi
17063
17064
17065  test -n "$ZIP" && break
17066done
17067
17068  else
17069    # The variable is set, but is it from the command line or the environment?
17070
17071    # Try to remove the string !ZIP! from our list.
17072    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/}
17073    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17074      # If it failed, the variable was not from the command line. Ignore it,
17075      # but warn the user (except for BASH, which is always set by the calling BASH).
17076      if test "xZIP" != xBASH; then
17077        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5
17078$as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;}
17079      fi
17080      # Try to locate tool using the code snippet
17081      for ac_prog in zip
17082do
17083  # Extract the first word of "$ac_prog", so it can be a program name with args.
17084set dummy $ac_prog; ac_word=$2
17085{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17086$as_echo_n "checking for $ac_word... " >&6; }
17087if ${ac_cv_path_ZIP+:} false; then :
17088  $as_echo_n "(cached) " >&6
17089else
17090  case $ZIP in
17091  [\\/]* | ?:[\\/]*)
17092  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17093  ;;
17094  *)
17095  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17096for as_dir in $PATH
17097do
17098  IFS=$as_save_IFS
17099  test -z "$as_dir" && as_dir=.
17100    for ac_exec_ext in '' $ac_executable_extensions; do
17101  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17102    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17103    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17104    break 2
17105  fi
17106done
17107  done
17108IFS=$as_save_IFS
17109
17110  ;;
17111esac
17112fi
17113ZIP=$ac_cv_path_ZIP
17114if test -n "$ZIP"; then
17115  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17116$as_echo "$ZIP" >&6; }
17117else
17118  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17119$as_echo "no" >&6; }
17120fi
17121
17122
17123  test -n "$ZIP" && break
17124done
17125
17126    else
17127      # If it succeeded, then it was overridden by the user. We will use it
17128      # for the tool.
17129
17130      # First remove it from the list of overridden variables, so we can test
17131      # for unknown variables in the end.
17132      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17133
17134      # Check if the provided tool contains a complete path.
17135      tool_specified="$ZIP"
17136      tool_basename="${tool_specified##*/}"
17137      if test "x$tool_basename" = "x$tool_specified"; then
17138        # A command without a complete path is provided, search $PATH.
17139        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5
17140$as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;}
17141        # Extract the first word of "$tool_basename", so it can be a program name with args.
17142set dummy $tool_basename; ac_word=$2
17143{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17144$as_echo_n "checking for $ac_word... " >&6; }
17145if ${ac_cv_path_ZIP+:} false; then :
17146  $as_echo_n "(cached) " >&6
17147else
17148  case $ZIP in
17149  [\\/]* | ?:[\\/]*)
17150  ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17151  ;;
17152  *)
17153  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17154for as_dir in $PATH
17155do
17156  IFS=$as_save_IFS
17157  test -z "$as_dir" && as_dir=.
17158    for ac_exec_ext in '' $ac_executable_extensions; do
17159  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17160    ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17161    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17162    break 2
17163  fi
17164done
17165  done
17166IFS=$as_save_IFS
17167
17168  ;;
17169esac
17170fi
17171ZIP=$ac_cv_path_ZIP
17172if test -n "$ZIP"; then
17173  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17174$as_echo "$ZIP" >&6; }
17175else
17176  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17177$as_echo "no" >&6; }
17178fi
17179
17180
17181        if test "x$ZIP" = x; then
17182          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17183        fi
17184      else
17185        # Otherwise we believe it is a complete path. Use it as it is.
17186        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5
17187$as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;}
17188        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5
17189$as_echo_n "checking for ZIP... " >&6; }
17190        if test ! -x "$tool_specified"; then
17191          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17192$as_echo "not found" >&6; }
17193          as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17194        fi
17195        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17196$as_echo "$tool_specified" >&6; }
17197      fi
17198    fi
17199  fi
17200
17201
17202
17203  if test "x$ZIP" = x; then
17204    as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5
17205  fi
17206
17207
17208
17209  # Non-required basic tools
17210
17211
17212
17213  # Publish this variable in the help.
17214
17215
17216  if test "x$LDD" = x; then
17217    # The variable is not set by user, try to locate tool using the code snippet
17218    for ac_prog in ldd
17219do
17220  # Extract the first word of "$ac_prog", so it can be a program name with args.
17221set dummy $ac_prog; ac_word=$2
17222{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17223$as_echo_n "checking for $ac_word... " >&6; }
17224if ${ac_cv_path_LDD+:} false; then :
17225  $as_echo_n "(cached) " >&6
17226else
17227  case $LDD in
17228  [\\/]* | ?:[\\/]*)
17229  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17230  ;;
17231  *)
17232  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17233for as_dir in $PATH
17234do
17235  IFS=$as_save_IFS
17236  test -z "$as_dir" && as_dir=.
17237    for ac_exec_ext in '' $ac_executable_extensions; do
17238  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17239    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17240    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17241    break 2
17242  fi
17243done
17244  done
17245IFS=$as_save_IFS
17246
17247  ;;
17248esac
17249fi
17250LDD=$ac_cv_path_LDD
17251if test -n "$LDD"; then
17252  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17253$as_echo "$LDD" >&6; }
17254else
17255  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17256$as_echo "no" >&6; }
17257fi
17258
17259
17260  test -n "$LDD" && break
17261done
17262
17263  else
17264    # The variable is set, but is it from the command line or the environment?
17265
17266    # Try to remove the string !LDD! from our list.
17267    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/}
17268    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17269      # If it failed, the variable was not from the command line. Ignore it,
17270      # but warn the user (except for BASH, which is always set by the calling BASH).
17271      if test "xLDD" != xBASH; then
17272        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5
17273$as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;}
17274      fi
17275      # Try to locate tool using the code snippet
17276      for ac_prog in ldd
17277do
17278  # Extract the first word of "$ac_prog", so it can be a program name with args.
17279set dummy $ac_prog; ac_word=$2
17280{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17281$as_echo_n "checking for $ac_word... " >&6; }
17282if ${ac_cv_path_LDD+:} false; then :
17283  $as_echo_n "(cached) " >&6
17284else
17285  case $LDD in
17286  [\\/]* | ?:[\\/]*)
17287  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17288  ;;
17289  *)
17290  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17291for as_dir in $PATH
17292do
17293  IFS=$as_save_IFS
17294  test -z "$as_dir" && as_dir=.
17295    for ac_exec_ext in '' $ac_executable_extensions; do
17296  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17297    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17298    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17299    break 2
17300  fi
17301done
17302  done
17303IFS=$as_save_IFS
17304
17305  ;;
17306esac
17307fi
17308LDD=$ac_cv_path_LDD
17309if test -n "$LDD"; then
17310  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17311$as_echo "$LDD" >&6; }
17312else
17313  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17314$as_echo "no" >&6; }
17315fi
17316
17317
17318  test -n "$LDD" && break
17319done
17320
17321    else
17322      # If it succeeded, then it was overridden by the user. We will use it
17323      # for the tool.
17324
17325      # First remove it from the list of overridden variables, so we can test
17326      # for unknown variables in the end.
17327      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17328
17329      # Check if the provided tool contains a complete path.
17330      tool_specified="$LDD"
17331      tool_basename="${tool_specified##*/}"
17332      if test "x$tool_basename" = "x$tool_specified"; then
17333        # A command without a complete path is provided, search $PATH.
17334        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5
17335$as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;}
17336        # Extract the first word of "$tool_basename", so it can be a program name with args.
17337set dummy $tool_basename; ac_word=$2
17338{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17339$as_echo_n "checking for $ac_word... " >&6; }
17340if ${ac_cv_path_LDD+:} false; then :
17341  $as_echo_n "(cached) " >&6
17342else
17343  case $LDD in
17344  [\\/]* | ?:[\\/]*)
17345  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17346  ;;
17347  *)
17348  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17349for as_dir in $PATH
17350do
17351  IFS=$as_save_IFS
17352  test -z "$as_dir" && as_dir=.
17353    for ac_exec_ext in '' $ac_executable_extensions; do
17354  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17355    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17356    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17357    break 2
17358  fi
17359done
17360  done
17361IFS=$as_save_IFS
17362
17363  ;;
17364esac
17365fi
17366LDD=$ac_cv_path_LDD
17367if test -n "$LDD"; then
17368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17369$as_echo "$LDD" >&6; }
17370else
17371  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17372$as_echo "no" >&6; }
17373fi
17374
17375
17376        if test "x$LDD" = x; then
17377          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17378        fi
17379      else
17380        # Otherwise we believe it is a complete path. Use it as it is.
17381        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5
17382$as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;}
17383        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5
17384$as_echo_n "checking for LDD... " >&6; }
17385        if test ! -x "$tool_specified"; then
17386          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17387$as_echo "not found" >&6; }
17388          as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5
17389        fi
17390        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17391$as_echo "$tool_specified" >&6; }
17392      fi
17393    fi
17394  fi
17395
17396
17397  if test "x$LDD" = "x"; then
17398    # List shared lib dependencies is used for
17399    # debug output and checking for forbidden dependencies.
17400    # We can build without it.
17401    LDD="true"
17402  fi
17403
17404
17405  # Publish this variable in the help.
17406
17407
17408  if test "x$OTOOL" = x; then
17409    # The variable is not set by user, try to locate tool using the code snippet
17410    for ac_prog in otool
17411do
17412  # Extract the first word of "$ac_prog", so it can be a program name with args.
17413set dummy $ac_prog; ac_word=$2
17414{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17415$as_echo_n "checking for $ac_word... " >&6; }
17416if ${ac_cv_path_OTOOL+:} false; then :
17417  $as_echo_n "(cached) " >&6
17418else
17419  case $OTOOL in
17420  [\\/]* | ?:[\\/]*)
17421  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17422  ;;
17423  *)
17424  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17425for as_dir in $PATH
17426do
17427  IFS=$as_save_IFS
17428  test -z "$as_dir" && as_dir=.
17429    for ac_exec_ext in '' $ac_executable_extensions; do
17430  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17431    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17432    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17433    break 2
17434  fi
17435done
17436  done
17437IFS=$as_save_IFS
17438
17439  ;;
17440esac
17441fi
17442OTOOL=$ac_cv_path_OTOOL
17443if test -n "$OTOOL"; then
17444  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17445$as_echo "$OTOOL" >&6; }
17446else
17447  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17448$as_echo "no" >&6; }
17449fi
17450
17451
17452  test -n "$OTOOL" && break
17453done
17454
17455  else
17456    # The variable is set, but is it from the command line or the environment?
17457
17458    # Try to remove the string !OTOOL! from our list.
17459    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/}
17460    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17461      # If it failed, the variable was not from the command line. Ignore it,
17462      # but warn the user (except for BASH, which is always set by the calling BASH).
17463      if test "xOTOOL" != xBASH; then
17464        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5
17465$as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;}
17466      fi
17467      # Try to locate tool using the code snippet
17468      for ac_prog in otool
17469do
17470  # Extract the first word of "$ac_prog", so it can be a program name with args.
17471set dummy $ac_prog; ac_word=$2
17472{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17473$as_echo_n "checking for $ac_word... " >&6; }
17474if ${ac_cv_path_OTOOL+:} false; then :
17475  $as_echo_n "(cached) " >&6
17476else
17477  case $OTOOL in
17478  [\\/]* | ?:[\\/]*)
17479  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17480  ;;
17481  *)
17482  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17483for as_dir in $PATH
17484do
17485  IFS=$as_save_IFS
17486  test -z "$as_dir" && as_dir=.
17487    for ac_exec_ext in '' $ac_executable_extensions; do
17488  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17489    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17490    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17491    break 2
17492  fi
17493done
17494  done
17495IFS=$as_save_IFS
17496
17497  ;;
17498esac
17499fi
17500OTOOL=$ac_cv_path_OTOOL
17501if test -n "$OTOOL"; then
17502  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17503$as_echo "$OTOOL" >&6; }
17504else
17505  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17506$as_echo "no" >&6; }
17507fi
17508
17509
17510  test -n "$OTOOL" && break
17511done
17512
17513    else
17514      # If it succeeded, then it was overridden by the user. We will use it
17515      # for the tool.
17516
17517      # First remove it from the list of overridden variables, so we can test
17518      # for unknown variables in the end.
17519      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17520
17521      # Check if the provided tool contains a complete path.
17522      tool_specified="$OTOOL"
17523      tool_basename="${tool_specified##*/}"
17524      if test "x$tool_basename" = "x$tool_specified"; then
17525        # A command without a complete path is provided, search $PATH.
17526        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5
17527$as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;}
17528        # Extract the first word of "$tool_basename", so it can be a program name with args.
17529set dummy $tool_basename; ac_word=$2
17530{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17531$as_echo_n "checking for $ac_word... " >&6; }
17532if ${ac_cv_path_OTOOL+:} false; then :
17533  $as_echo_n "(cached) " >&6
17534else
17535  case $OTOOL in
17536  [\\/]* | ?:[\\/]*)
17537  ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17538  ;;
17539  *)
17540  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17541for as_dir in $PATH
17542do
17543  IFS=$as_save_IFS
17544  test -z "$as_dir" && as_dir=.
17545    for ac_exec_ext in '' $ac_executable_extensions; do
17546  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17547    ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17548    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17549    break 2
17550  fi
17551done
17552  done
17553IFS=$as_save_IFS
17554
17555  ;;
17556esac
17557fi
17558OTOOL=$ac_cv_path_OTOOL
17559if test -n "$OTOOL"; then
17560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17561$as_echo "$OTOOL" >&6; }
17562else
17563  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17564$as_echo "no" >&6; }
17565fi
17566
17567
17568        if test "x$OTOOL" = x; then
17569          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17570        fi
17571      else
17572        # Otherwise we believe it is a complete path. Use it as it is.
17573        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5
17574$as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;}
17575        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5
17576$as_echo_n "checking for OTOOL... " >&6; }
17577        if test ! -x "$tool_specified"; then
17578          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17579$as_echo "not found" >&6; }
17580          as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5
17581        fi
17582        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17583$as_echo "$tool_specified" >&6; }
17584      fi
17585    fi
17586  fi
17587
17588
17589  if test "x$OTOOL" = "x"; then
17590    OTOOL="true"
17591  fi
17592
17593
17594  # Publish this variable in the help.
17595
17596
17597  if test "x$READELF" = x; then
17598    # The variable is not set by user, try to locate tool using the code snippet
17599    for ac_prog in greadelf readelf
17600do
17601  # Extract the first word of "$ac_prog", so it can be a program name with args.
17602set dummy $ac_prog; ac_word=$2
17603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17604$as_echo_n "checking for $ac_word... " >&6; }
17605if ${ac_cv_path_READELF+:} false; then :
17606  $as_echo_n "(cached) " >&6
17607else
17608  case $READELF in
17609  [\\/]* | ?:[\\/]*)
17610  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17611  ;;
17612  *)
17613  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17614for as_dir in $PATH
17615do
17616  IFS=$as_save_IFS
17617  test -z "$as_dir" && as_dir=.
17618    for ac_exec_ext in '' $ac_executable_extensions; do
17619  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17620    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17621    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17622    break 2
17623  fi
17624done
17625  done
17626IFS=$as_save_IFS
17627
17628  ;;
17629esac
17630fi
17631READELF=$ac_cv_path_READELF
17632if test -n "$READELF"; then
17633  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17634$as_echo "$READELF" >&6; }
17635else
17636  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17637$as_echo "no" >&6; }
17638fi
17639
17640
17641  test -n "$READELF" && break
17642done
17643
17644  else
17645    # The variable is set, but is it from the command line or the environment?
17646
17647    # Try to remove the string !READELF! from our list.
17648    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/}
17649    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17650      # If it failed, the variable was not from the command line. Ignore it,
17651      # but warn the user (except for BASH, which is always set by the calling BASH).
17652      if test "xREADELF" != xBASH; then
17653        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5
17654$as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;}
17655      fi
17656      # Try to locate tool using the code snippet
17657      for ac_prog in greadelf readelf
17658do
17659  # Extract the first word of "$ac_prog", so it can be a program name with args.
17660set dummy $ac_prog; ac_word=$2
17661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17662$as_echo_n "checking for $ac_word... " >&6; }
17663if ${ac_cv_path_READELF+:} false; then :
17664  $as_echo_n "(cached) " >&6
17665else
17666  case $READELF in
17667  [\\/]* | ?:[\\/]*)
17668  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17669  ;;
17670  *)
17671  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17672for as_dir in $PATH
17673do
17674  IFS=$as_save_IFS
17675  test -z "$as_dir" && as_dir=.
17676    for ac_exec_ext in '' $ac_executable_extensions; do
17677  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17678    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17679    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17680    break 2
17681  fi
17682done
17683  done
17684IFS=$as_save_IFS
17685
17686  ;;
17687esac
17688fi
17689READELF=$ac_cv_path_READELF
17690if test -n "$READELF"; then
17691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17692$as_echo "$READELF" >&6; }
17693else
17694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17695$as_echo "no" >&6; }
17696fi
17697
17698
17699  test -n "$READELF" && break
17700done
17701
17702    else
17703      # If it succeeded, then it was overridden by the user. We will use it
17704      # for the tool.
17705
17706      # First remove it from the list of overridden variables, so we can test
17707      # for unknown variables in the end.
17708      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17709
17710      # Check if the provided tool contains a complete path.
17711      tool_specified="$READELF"
17712      tool_basename="${tool_specified##*/}"
17713      if test "x$tool_basename" = "x$tool_specified"; then
17714        # A command without a complete path is provided, search $PATH.
17715        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5
17716$as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;}
17717        # Extract the first word of "$tool_basename", so it can be a program name with args.
17718set dummy $tool_basename; ac_word=$2
17719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17720$as_echo_n "checking for $ac_word... " >&6; }
17721if ${ac_cv_path_READELF+:} false; then :
17722  $as_echo_n "(cached) " >&6
17723else
17724  case $READELF in
17725  [\\/]* | ?:[\\/]*)
17726  ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17727  ;;
17728  *)
17729  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17730for as_dir in $PATH
17731do
17732  IFS=$as_save_IFS
17733  test -z "$as_dir" && as_dir=.
17734    for ac_exec_ext in '' $ac_executable_extensions; do
17735  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17736    ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17737    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17738    break 2
17739  fi
17740done
17741  done
17742IFS=$as_save_IFS
17743
17744  ;;
17745esac
17746fi
17747READELF=$ac_cv_path_READELF
17748if test -n "$READELF"; then
17749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17750$as_echo "$READELF" >&6; }
17751else
17752  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17753$as_echo "no" >&6; }
17754fi
17755
17756
17757        if test "x$READELF" = x; then
17758          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17759        fi
17760      else
17761        # Otherwise we believe it is a complete path. Use it as it is.
17762        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5
17763$as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;}
17764        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5
17765$as_echo_n "checking for READELF... " >&6; }
17766        if test ! -x "$tool_specified"; then
17767          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17768$as_echo "not found" >&6; }
17769          as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5
17770        fi
17771        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17772$as_echo "$tool_specified" >&6; }
17773      fi
17774    fi
17775  fi
17776
17777
17778
17779
17780  # Publish this variable in the help.
17781
17782
17783  if test "x$HG" = x; then
17784    # The variable is not set by user, try to locate tool using the code snippet
17785    for ac_prog in hg
17786do
17787  # Extract the first word of "$ac_prog", so it can be a program name with args.
17788set dummy $ac_prog; ac_word=$2
17789{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17790$as_echo_n "checking for $ac_word... " >&6; }
17791if ${ac_cv_path_HG+:} false; then :
17792  $as_echo_n "(cached) " >&6
17793else
17794  case $HG in
17795  [\\/]* | ?:[\\/]*)
17796  ac_cv_path_HG="$HG" # Let the user override the test with a path.
17797  ;;
17798  *)
17799  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17800for as_dir in $PATH
17801do
17802  IFS=$as_save_IFS
17803  test -z "$as_dir" && as_dir=.
17804    for ac_exec_ext in '' $ac_executable_extensions; do
17805  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17806    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17807    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17808    break 2
17809  fi
17810done
17811  done
17812IFS=$as_save_IFS
17813
17814  ;;
17815esac
17816fi
17817HG=$ac_cv_path_HG
17818if test -n "$HG"; then
17819  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17820$as_echo "$HG" >&6; }
17821else
17822  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17823$as_echo "no" >&6; }
17824fi
17825
17826
17827  test -n "$HG" && break
17828done
17829
17830  else
17831    # The variable is set, but is it from the command line or the environment?
17832
17833    # Try to remove the string !HG! from our list.
17834    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/}
17835    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17836      # If it failed, the variable was not from the command line. Ignore it,
17837      # but warn the user (except for BASH, which is always set by the calling BASH).
17838      if test "xHG" != xBASH; then
17839        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5
17840$as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;}
17841      fi
17842      # Try to locate tool using the code snippet
17843      for ac_prog in hg
17844do
17845  # Extract the first word of "$ac_prog", so it can be a program name with args.
17846set dummy $ac_prog; ac_word=$2
17847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17848$as_echo_n "checking for $ac_word... " >&6; }
17849if ${ac_cv_path_HG+:} false; then :
17850  $as_echo_n "(cached) " >&6
17851else
17852  case $HG in
17853  [\\/]* | ?:[\\/]*)
17854  ac_cv_path_HG="$HG" # Let the user override the test with a path.
17855  ;;
17856  *)
17857  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17858for as_dir in $PATH
17859do
17860  IFS=$as_save_IFS
17861  test -z "$as_dir" && as_dir=.
17862    for ac_exec_ext in '' $ac_executable_extensions; do
17863  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17864    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17865    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17866    break 2
17867  fi
17868done
17869  done
17870IFS=$as_save_IFS
17871
17872  ;;
17873esac
17874fi
17875HG=$ac_cv_path_HG
17876if test -n "$HG"; then
17877  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17878$as_echo "$HG" >&6; }
17879else
17880  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17881$as_echo "no" >&6; }
17882fi
17883
17884
17885  test -n "$HG" && break
17886done
17887
17888    else
17889      # If it succeeded, then it was overridden by the user. We will use it
17890      # for the tool.
17891
17892      # First remove it from the list of overridden variables, so we can test
17893      # for unknown variables in the end.
17894      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17895
17896      # Check if the provided tool contains a complete path.
17897      tool_specified="$HG"
17898      tool_basename="${tool_specified##*/}"
17899      if test "x$tool_basename" = "x$tool_specified"; then
17900        # A command without a complete path is provided, search $PATH.
17901        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5
17902$as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;}
17903        # Extract the first word of "$tool_basename", so it can be a program name with args.
17904set dummy $tool_basename; ac_word=$2
17905{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17906$as_echo_n "checking for $ac_word... " >&6; }
17907if ${ac_cv_path_HG+:} false; then :
17908  $as_echo_n "(cached) " >&6
17909else
17910  case $HG in
17911  [\\/]* | ?:[\\/]*)
17912  ac_cv_path_HG="$HG" # Let the user override the test with a path.
17913  ;;
17914  *)
17915  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17916for as_dir in $PATH
17917do
17918  IFS=$as_save_IFS
17919  test -z "$as_dir" && as_dir=.
17920    for ac_exec_ext in '' $ac_executable_extensions; do
17921  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17922    ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17923    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17924    break 2
17925  fi
17926done
17927  done
17928IFS=$as_save_IFS
17929
17930  ;;
17931esac
17932fi
17933HG=$ac_cv_path_HG
17934if test -n "$HG"; then
17935  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17936$as_echo "$HG" >&6; }
17937else
17938  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17939$as_echo "no" >&6; }
17940fi
17941
17942
17943        if test "x$HG" = x; then
17944          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17945        fi
17946      else
17947        # Otherwise we believe it is a complete path. Use it as it is.
17948        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5
17949$as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;}
17950        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5
17951$as_echo_n "checking for HG... " >&6; }
17952        if test ! -x "$tool_specified"; then
17953          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17954$as_echo "not found" >&6; }
17955          as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5
17956        fi
17957        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17958$as_echo "$tool_specified" >&6; }
17959      fi
17960    fi
17961  fi
17962
17963
17964
17965
17966  # Publish this variable in the help.
17967
17968
17969  if test "x$STAT" = x; then
17970    # The variable is not set by user, try to locate tool using the code snippet
17971    for ac_prog in stat
17972do
17973  # Extract the first word of "$ac_prog", so it can be a program name with args.
17974set dummy $ac_prog; ac_word=$2
17975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17976$as_echo_n "checking for $ac_word... " >&6; }
17977if ${ac_cv_path_STAT+:} false; then :
17978  $as_echo_n "(cached) " >&6
17979else
17980  case $STAT in
17981  [\\/]* | ?:[\\/]*)
17982  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
17983  ;;
17984  *)
17985  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17986for as_dir in $PATH
17987do
17988  IFS=$as_save_IFS
17989  test -z "$as_dir" && as_dir=.
17990    for ac_exec_ext in '' $ac_executable_extensions; do
17991  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17992    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
17993    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17994    break 2
17995  fi
17996done
17997  done
17998IFS=$as_save_IFS
17999
18000  ;;
18001esac
18002fi
18003STAT=$ac_cv_path_STAT
18004if test -n "$STAT"; then
18005  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18006$as_echo "$STAT" >&6; }
18007else
18008  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18009$as_echo "no" >&6; }
18010fi
18011
18012
18013  test -n "$STAT" && break
18014done
18015
18016  else
18017    # The variable is set, but is it from the command line or the environment?
18018
18019    # Try to remove the string !STAT! from our list.
18020    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/}
18021    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18022      # If it failed, the variable was not from the command line. Ignore it,
18023      # but warn the user (except for BASH, which is always set by the calling BASH).
18024      if test "xSTAT" != xBASH; then
18025        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5
18026$as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;}
18027      fi
18028      # Try to locate tool using the code snippet
18029      for ac_prog in stat
18030do
18031  # Extract the first word of "$ac_prog", so it can be a program name with args.
18032set dummy $ac_prog; ac_word=$2
18033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18034$as_echo_n "checking for $ac_word... " >&6; }
18035if ${ac_cv_path_STAT+:} false; then :
18036  $as_echo_n "(cached) " >&6
18037else
18038  case $STAT in
18039  [\\/]* | ?:[\\/]*)
18040  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18041  ;;
18042  *)
18043  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18044for as_dir in $PATH
18045do
18046  IFS=$as_save_IFS
18047  test -z "$as_dir" && as_dir=.
18048    for ac_exec_ext in '' $ac_executable_extensions; do
18049  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18050    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18051    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18052    break 2
18053  fi
18054done
18055  done
18056IFS=$as_save_IFS
18057
18058  ;;
18059esac
18060fi
18061STAT=$ac_cv_path_STAT
18062if test -n "$STAT"; then
18063  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18064$as_echo "$STAT" >&6; }
18065else
18066  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18067$as_echo "no" >&6; }
18068fi
18069
18070
18071  test -n "$STAT" && break
18072done
18073
18074    else
18075      # If it succeeded, then it was overridden by the user. We will use it
18076      # for the tool.
18077
18078      # First remove it from the list of overridden variables, so we can test
18079      # for unknown variables in the end.
18080      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18081
18082      # Check if the provided tool contains a complete path.
18083      tool_specified="$STAT"
18084      tool_basename="${tool_specified##*/}"
18085      if test "x$tool_basename" = "x$tool_specified"; then
18086        # A command without a complete path is provided, search $PATH.
18087        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5
18088$as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;}
18089        # Extract the first word of "$tool_basename", so it can be a program name with args.
18090set dummy $tool_basename; ac_word=$2
18091{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18092$as_echo_n "checking for $ac_word... " >&6; }
18093if ${ac_cv_path_STAT+:} false; then :
18094  $as_echo_n "(cached) " >&6
18095else
18096  case $STAT in
18097  [\\/]* | ?:[\\/]*)
18098  ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18099  ;;
18100  *)
18101  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18102for as_dir in $PATH
18103do
18104  IFS=$as_save_IFS
18105  test -z "$as_dir" && as_dir=.
18106    for ac_exec_ext in '' $ac_executable_extensions; do
18107  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18108    ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18109    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18110    break 2
18111  fi
18112done
18113  done
18114IFS=$as_save_IFS
18115
18116  ;;
18117esac
18118fi
18119STAT=$ac_cv_path_STAT
18120if test -n "$STAT"; then
18121  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18122$as_echo "$STAT" >&6; }
18123else
18124  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18125$as_echo "no" >&6; }
18126fi
18127
18128
18129        if test "x$STAT" = x; then
18130          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18131        fi
18132      else
18133        # Otherwise we believe it is a complete path. Use it as it is.
18134        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5
18135$as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;}
18136        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5
18137$as_echo_n "checking for STAT... " >&6; }
18138        if test ! -x "$tool_specified"; then
18139          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18140$as_echo "not found" >&6; }
18141          as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5
18142        fi
18143        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18144$as_echo "$tool_specified" >&6; }
18145      fi
18146    fi
18147  fi
18148
18149
18150
18151
18152  # Publish this variable in the help.
18153
18154
18155  if test "x$TIME" = x; then
18156    # The variable is not set by user, try to locate tool using the code snippet
18157    for ac_prog in time
18158do
18159  # Extract the first word of "$ac_prog", so it can be a program name with args.
18160set dummy $ac_prog; ac_word=$2
18161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18162$as_echo_n "checking for $ac_word... " >&6; }
18163if ${ac_cv_path_TIME+:} false; then :
18164  $as_echo_n "(cached) " >&6
18165else
18166  case $TIME in
18167  [\\/]* | ?:[\\/]*)
18168  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18169  ;;
18170  *)
18171  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18172for as_dir in $PATH
18173do
18174  IFS=$as_save_IFS
18175  test -z "$as_dir" && as_dir=.
18176    for ac_exec_ext in '' $ac_executable_extensions; do
18177  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18178    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18179    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18180    break 2
18181  fi
18182done
18183  done
18184IFS=$as_save_IFS
18185
18186  ;;
18187esac
18188fi
18189TIME=$ac_cv_path_TIME
18190if test -n "$TIME"; then
18191  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18192$as_echo "$TIME" >&6; }
18193else
18194  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18195$as_echo "no" >&6; }
18196fi
18197
18198
18199  test -n "$TIME" && break
18200done
18201
18202  else
18203    # The variable is set, but is it from the command line or the environment?
18204
18205    # Try to remove the string !TIME! from our list.
18206    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/}
18207    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18208      # If it failed, the variable was not from the command line. Ignore it,
18209      # but warn the user (except for BASH, which is always set by the calling BASH).
18210      if test "xTIME" != xBASH; then
18211        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5
18212$as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;}
18213      fi
18214      # Try to locate tool using the code snippet
18215      for ac_prog in time
18216do
18217  # Extract the first word of "$ac_prog", so it can be a program name with args.
18218set dummy $ac_prog; ac_word=$2
18219{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18220$as_echo_n "checking for $ac_word... " >&6; }
18221if ${ac_cv_path_TIME+:} false; then :
18222  $as_echo_n "(cached) " >&6
18223else
18224  case $TIME in
18225  [\\/]* | ?:[\\/]*)
18226  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18227  ;;
18228  *)
18229  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18230for as_dir in $PATH
18231do
18232  IFS=$as_save_IFS
18233  test -z "$as_dir" && as_dir=.
18234    for ac_exec_ext in '' $ac_executable_extensions; do
18235  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18236    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18237    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18238    break 2
18239  fi
18240done
18241  done
18242IFS=$as_save_IFS
18243
18244  ;;
18245esac
18246fi
18247TIME=$ac_cv_path_TIME
18248if test -n "$TIME"; then
18249  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18250$as_echo "$TIME" >&6; }
18251else
18252  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18253$as_echo "no" >&6; }
18254fi
18255
18256
18257  test -n "$TIME" && break
18258done
18259
18260    else
18261      # If it succeeded, then it was overridden by the user. We will use it
18262      # for the tool.
18263
18264      # First remove it from the list of overridden variables, so we can test
18265      # for unknown variables in the end.
18266      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18267
18268      # Check if the provided tool contains a complete path.
18269      tool_specified="$TIME"
18270      tool_basename="${tool_specified##*/}"
18271      if test "x$tool_basename" = "x$tool_specified"; then
18272        # A command without a complete path is provided, search $PATH.
18273        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5
18274$as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;}
18275        # Extract the first word of "$tool_basename", so it can be a program name with args.
18276set dummy $tool_basename; ac_word=$2
18277{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18278$as_echo_n "checking for $ac_word... " >&6; }
18279if ${ac_cv_path_TIME+:} false; then :
18280  $as_echo_n "(cached) " >&6
18281else
18282  case $TIME in
18283  [\\/]* | ?:[\\/]*)
18284  ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18285  ;;
18286  *)
18287  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18288for as_dir in $PATH
18289do
18290  IFS=$as_save_IFS
18291  test -z "$as_dir" && as_dir=.
18292    for ac_exec_ext in '' $ac_executable_extensions; do
18293  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18294    ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18295    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18296    break 2
18297  fi
18298done
18299  done
18300IFS=$as_save_IFS
18301
18302  ;;
18303esac
18304fi
18305TIME=$ac_cv_path_TIME
18306if test -n "$TIME"; then
18307  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18308$as_echo "$TIME" >&6; }
18309else
18310  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18311$as_echo "no" >&6; }
18312fi
18313
18314
18315        if test "x$TIME" = x; then
18316          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18317        fi
18318      else
18319        # Otherwise we believe it is a complete path. Use it as it is.
18320        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5
18321$as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;}
18322        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5
18323$as_echo_n "checking for TIME... " >&6; }
18324        if test ! -x "$tool_specified"; then
18325          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18326$as_echo "not found" >&6; }
18327          as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5
18328        fi
18329        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18330$as_echo "$tool_specified" >&6; }
18331      fi
18332    fi
18333  fi
18334
18335
18336  # Check if it's GNU time
18337  IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'`
18338  if test "x$IS_GNU_TIME" != x; then
18339    IS_GNU_TIME=yes
18340  else
18341    IS_GNU_TIME=no
18342  fi
18343
18344
18345  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
18346
18347
18348
18349  # Publish this variable in the help.
18350
18351
18352  if test "x$COMM" = x; then
18353    # The variable is not set by user, try to locate tool using the code snippet
18354    for ac_prog in comm
18355do
18356  # Extract the first word of "$ac_prog", so it can be a program name with args.
18357set dummy $ac_prog; ac_word=$2
18358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18359$as_echo_n "checking for $ac_word... " >&6; }
18360if ${ac_cv_path_COMM+:} false; then :
18361  $as_echo_n "(cached) " >&6
18362else
18363  case $COMM in
18364  [\\/]* | ?:[\\/]*)
18365  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18366  ;;
18367  *)
18368  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18369for as_dir in $PATH
18370do
18371  IFS=$as_save_IFS
18372  test -z "$as_dir" && as_dir=.
18373    for ac_exec_ext in '' $ac_executable_extensions; do
18374  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18375    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18376    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18377    break 2
18378  fi
18379done
18380  done
18381IFS=$as_save_IFS
18382
18383  ;;
18384esac
18385fi
18386COMM=$ac_cv_path_COMM
18387if test -n "$COMM"; then
18388  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18389$as_echo "$COMM" >&6; }
18390else
18391  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18392$as_echo "no" >&6; }
18393fi
18394
18395
18396  test -n "$COMM" && break
18397done
18398
18399  else
18400    # The variable is set, but is it from the command line or the environment?
18401
18402    # Try to remove the string !COMM! from our list.
18403    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
18404    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18405      # If it failed, the variable was not from the command line. Ignore it,
18406      # but warn the user (except for BASH, which is always set by the calling BASH).
18407      if test "xCOMM" != xBASH; then
18408        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
18409$as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
18410      fi
18411      # Try to locate tool using the code snippet
18412      for ac_prog in comm
18413do
18414  # Extract the first word of "$ac_prog", so it can be a program name with args.
18415set dummy $ac_prog; ac_word=$2
18416{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18417$as_echo_n "checking for $ac_word... " >&6; }
18418if ${ac_cv_path_COMM+:} false; then :
18419  $as_echo_n "(cached) " >&6
18420else
18421  case $COMM in
18422  [\\/]* | ?:[\\/]*)
18423  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18424  ;;
18425  *)
18426  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18427for as_dir in $PATH
18428do
18429  IFS=$as_save_IFS
18430  test -z "$as_dir" && as_dir=.
18431    for ac_exec_ext in '' $ac_executable_extensions; do
18432  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18433    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18434    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18435    break 2
18436  fi
18437done
18438  done
18439IFS=$as_save_IFS
18440
18441  ;;
18442esac
18443fi
18444COMM=$ac_cv_path_COMM
18445if test -n "$COMM"; then
18446  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18447$as_echo "$COMM" >&6; }
18448else
18449  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18450$as_echo "no" >&6; }
18451fi
18452
18453
18454  test -n "$COMM" && break
18455done
18456
18457    else
18458      # If it succeeded, then it was overridden by the user. We will use it
18459      # for the tool.
18460
18461      # First remove it from the list of overridden variables, so we can test
18462      # for unknown variables in the end.
18463      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18464
18465      # Check if the provided tool contains a complete path.
18466      tool_specified="$COMM"
18467      tool_basename="${tool_specified##*/}"
18468      if test "x$tool_basename" = "x$tool_specified"; then
18469        # A command without a complete path is provided, search $PATH.
18470        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
18471$as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
18472        # Extract the first word of "$tool_basename", so it can be a program name with args.
18473set dummy $tool_basename; ac_word=$2
18474{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18475$as_echo_n "checking for $ac_word... " >&6; }
18476if ${ac_cv_path_COMM+:} false; then :
18477  $as_echo_n "(cached) " >&6
18478else
18479  case $COMM in
18480  [\\/]* | ?:[\\/]*)
18481  ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18482  ;;
18483  *)
18484  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18485for as_dir in $PATH
18486do
18487  IFS=$as_save_IFS
18488  test -z "$as_dir" && as_dir=.
18489    for ac_exec_ext in '' $ac_executable_extensions; do
18490  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18491    ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18492    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18493    break 2
18494  fi
18495done
18496  done
18497IFS=$as_save_IFS
18498
18499  ;;
18500esac
18501fi
18502COMM=$ac_cv_path_COMM
18503if test -n "$COMM"; then
18504  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18505$as_echo "$COMM" >&6; }
18506else
18507  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18508$as_echo "no" >&6; }
18509fi
18510
18511
18512        if test "x$COMM" = x; then
18513          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18514        fi
18515      else
18516        # Otherwise we believe it is a complete path. Use it as it is.
18517        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
18518$as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
18519        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
18520$as_echo_n "checking for COMM... " >&6; }
18521        if test ! -x "$tool_specified"; then
18522          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18523$as_echo "not found" >&6; }
18524          as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
18525        fi
18526        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18527$as_echo "$tool_specified" >&6; }
18528      fi
18529    fi
18530  fi
18531
18532
18533
18534  if test "x$COMM" = x; then
18535    as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
18536  fi
18537
18538
18539  fi
18540
18541  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
18542
18543
18544
18545  # Publish this variable in the help.
18546
18547
18548  if test "x$DSYMUTIL" = x; then
18549    # The variable is not set by user, try to locate tool using the code snippet
18550    for ac_prog in dsymutil
18551do
18552  # Extract the first word of "$ac_prog", so it can be a program name with args.
18553set dummy $ac_prog; ac_word=$2
18554{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18555$as_echo_n "checking for $ac_word... " >&6; }
18556if ${ac_cv_path_DSYMUTIL+:} false; then :
18557  $as_echo_n "(cached) " >&6
18558else
18559  case $DSYMUTIL in
18560  [\\/]* | ?:[\\/]*)
18561  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18562  ;;
18563  *)
18564  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18565for as_dir in $PATH
18566do
18567  IFS=$as_save_IFS
18568  test -z "$as_dir" && as_dir=.
18569    for ac_exec_ext in '' $ac_executable_extensions; do
18570  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18571    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18572    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18573    break 2
18574  fi
18575done
18576  done
18577IFS=$as_save_IFS
18578
18579  ;;
18580esac
18581fi
18582DSYMUTIL=$ac_cv_path_DSYMUTIL
18583if test -n "$DSYMUTIL"; then
18584  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18585$as_echo "$DSYMUTIL" >&6; }
18586else
18587  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18588$as_echo "no" >&6; }
18589fi
18590
18591
18592  test -n "$DSYMUTIL" && break
18593done
18594
18595  else
18596    # The variable is set, but is it from the command line or the environment?
18597
18598    # Try to remove the string !DSYMUTIL! from our list.
18599    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/}
18600    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18601      # If it failed, the variable was not from the command line. Ignore it,
18602      # but warn the user (except for BASH, which is always set by the calling BASH).
18603      if test "xDSYMUTIL" != xBASH; then
18604        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5
18605$as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;}
18606      fi
18607      # Try to locate tool using the code snippet
18608      for ac_prog in dsymutil
18609do
18610  # Extract the first word of "$ac_prog", so it can be a program name with args.
18611set dummy $ac_prog; ac_word=$2
18612{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18613$as_echo_n "checking for $ac_word... " >&6; }
18614if ${ac_cv_path_DSYMUTIL+:} false; then :
18615  $as_echo_n "(cached) " >&6
18616else
18617  case $DSYMUTIL in
18618  [\\/]* | ?:[\\/]*)
18619  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18620  ;;
18621  *)
18622  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18623for as_dir in $PATH
18624do
18625  IFS=$as_save_IFS
18626  test -z "$as_dir" && as_dir=.
18627    for ac_exec_ext in '' $ac_executable_extensions; do
18628  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18629    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18630    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18631    break 2
18632  fi
18633done
18634  done
18635IFS=$as_save_IFS
18636
18637  ;;
18638esac
18639fi
18640DSYMUTIL=$ac_cv_path_DSYMUTIL
18641if test -n "$DSYMUTIL"; then
18642  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18643$as_echo "$DSYMUTIL" >&6; }
18644else
18645  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18646$as_echo "no" >&6; }
18647fi
18648
18649
18650  test -n "$DSYMUTIL" && break
18651done
18652
18653    else
18654      # If it succeeded, then it was overridden by the user. We will use it
18655      # for the tool.
18656
18657      # First remove it from the list of overridden variables, so we can test
18658      # for unknown variables in the end.
18659      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18660
18661      # Check if the provided tool contains a complete path.
18662      tool_specified="$DSYMUTIL"
18663      tool_basename="${tool_specified##*/}"
18664      if test "x$tool_basename" = "x$tool_specified"; then
18665        # A command without a complete path is provided, search $PATH.
18666        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5
18667$as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;}
18668        # Extract the first word of "$tool_basename", so it can be a program name with args.
18669set dummy $tool_basename; ac_word=$2
18670{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18671$as_echo_n "checking for $ac_word... " >&6; }
18672if ${ac_cv_path_DSYMUTIL+:} false; then :
18673  $as_echo_n "(cached) " >&6
18674else
18675  case $DSYMUTIL in
18676  [\\/]* | ?:[\\/]*)
18677  ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18678  ;;
18679  *)
18680  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18681for as_dir in $PATH
18682do
18683  IFS=$as_save_IFS
18684  test -z "$as_dir" && as_dir=.
18685    for ac_exec_ext in '' $ac_executable_extensions; do
18686  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18687    ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18688    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18689    break 2
18690  fi
18691done
18692  done
18693IFS=$as_save_IFS
18694
18695  ;;
18696esac
18697fi
18698DSYMUTIL=$ac_cv_path_DSYMUTIL
18699if test -n "$DSYMUTIL"; then
18700  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18701$as_echo "$DSYMUTIL" >&6; }
18702else
18703  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18704$as_echo "no" >&6; }
18705fi
18706
18707
18708        if test "x$DSYMUTIL" = x; then
18709          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18710        fi
18711      else
18712        # Otherwise we believe it is a complete path. Use it as it is.
18713        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5
18714$as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;}
18715        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5
18716$as_echo_n "checking for DSYMUTIL... " >&6; }
18717        if test ! -x "$tool_specified"; then
18718          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18719$as_echo "not found" >&6; }
18720          as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5
18721        fi
18722        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18723$as_echo "$tool_specified" >&6; }
18724      fi
18725    fi
18726  fi
18727
18728
18729
18730  if test "x$DSYMUTIL" = x; then
18731    as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5
18732  fi
18733
18734
18735
18736
18737
18738  # Publish this variable in the help.
18739
18740
18741  if test "x$XATTR" = x; then
18742    # The variable is not set by user, try to locate tool using the code snippet
18743    for ac_prog in xattr
18744do
18745  # Extract the first word of "$ac_prog", so it can be a program name with args.
18746set dummy $ac_prog; ac_word=$2
18747{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18748$as_echo_n "checking for $ac_word... " >&6; }
18749if ${ac_cv_path_XATTR+:} false; then :
18750  $as_echo_n "(cached) " >&6
18751else
18752  case $XATTR in
18753  [\\/]* | ?:[\\/]*)
18754  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18755  ;;
18756  *)
18757  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18758for as_dir in $PATH
18759do
18760  IFS=$as_save_IFS
18761  test -z "$as_dir" && as_dir=.
18762    for ac_exec_ext in '' $ac_executable_extensions; do
18763  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18764    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18765    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18766    break 2
18767  fi
18768done
18769  done
18770IFS=$as_save_IFS
18771
18772  ;;
18773esac
18774fi
18775XATTR=$ac_cv_path_XATTR
18776if test -n "$XATTR"; then
18777  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18778$as_echo "$XATTR" >&6; }
18779else
18780  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18781$as_echo "no" >&6; }
18782fi
18783
18784
18785  test -n "$XATTR" && break
18786done
18787
18788  else
18789    # The variable is set, but is it from the command line or the environment?
18790
18791    # Try to remove the string !XATTR! from our list.
18792    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/}
18793    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18794      # If it failed, the variable was not from the command line. Ignore it,
18795      # but warn the user (except for BASH, which is always set by the calling BASH).
18796      if test "xXATTR" != xBASH; then
18797        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5
18798$as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;}
18799      fi
18800      # Try to locate tool using the code snippet
18801      for ac_prog in xattr
18802do
18803  # Extract the first word of "$ac_prog", so it can be a program name with args.
18804set dummy $ac_prog; ac_word=$2
18805{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18806$as_echo_n "checking for $ac_word... " >&6; }
18807if ${ac_cv_path_XATTR+:} false; then :
18808  $as_echo_n "(cached) " >&6
18809else
18810  case $XATTR in
18811  [\\/]* | ?:[\\/]*)
18812  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18813  ;;
18814  *)
18815  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18816for as_dir in $PATH
18817do
18818  IFS=$as_save_IFS
18819  test -z "$as_dir" && as_dir=.
18820    for ac_exec_ext in '' $ac_executable_extensions; do
18821  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18822    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18823    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18824    break 2
18825  fi
18826done
18827  done
18828IFS=$as_save_IFS
18829
18830  ;;
18831esac
18832fi
18833XATTR=$ac_cv_path_XATTR
18834if test -n "$XATTR"; then
18835  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18836$as_echo "$XATTR" >&6; }
18837else
18838  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18839$as_echo "no" >&6; }
18840fi
18841
18842
18843  test -n "$XATTR" && break
18844done
18845
18846    else
18847      # If it succeeded, then it was overridden by the user. We will use it
18848      # for the tool.
18849
18850      # First remove it from the list of overridden variables, so we can test
18851      # for unknown variables in the end.
18852      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18853
18854      # Check if the provided tool contains a complete path.
18855      tool_specified="$XATTR"
18856      tool_basename="${tool_specified##*/}"
18857      if test "x$tool_basename" = "x$tool_specified"; then
18858        # A command without a complete path is provided, search $PATH.
18859        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5
18860$as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;}
18861        # Extract the first word of "$tool_basename", so it can be a program name with args.
18862set dummy $tool_basename; ac_word=$2
18863{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18864$as_echo_n "checking for $ac_word... " >&6; }
18865if ${ac_cv_path_XATTR+:} false; then :
18866  $as_echo_n "(cached) " >&6
18867else
18868  case $XATTR in
18869  [\\/]* | ?:[\\/]*)
18870  ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18871  ;;
18872  *)
18873  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18874for as_dir in $PATH
18875do
18876  IFS=$as_save_IFS
18877  test -z "$as_dir" && as_dir=.
18878    for ac_exec_ext in '' $ac_executable_extensions; do
18879  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18880    ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18881    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18882    break 2
18883  fi
18884done
18885  done
18886IFS=$as_save_IFS
18887
18888  ;;
18889esac
18890fi
18891XATTR=$ac_cv_path_XATTR
18892if test -n "$XATTR"; then
18893  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18894$as_echo "$XATTR" >&6; }
18895else
18896  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18897$as_echo "no" >&6; }
18898fi
18899
18900
18901        if test "x$XATTR" = x; then
18902          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18903        fi
18904      else
18905        # Otherwise we believe it is a complete path. Use it as it is.
18906        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5
18907$as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;}
18908        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5
18909$as_echo_n "checking for XATTR... " >&6; }
18910        if test ! -x "$tool_specified"; then
18911          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18912$as_echo "not found" >&6; }
18913          as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5
18914        fi
18915        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18916$as_echo "$tool_specified" >&6; }
18917      fi
18918    fi
18919  fi
18920
18921
18922
18923  if test "x$XATTR" = x; then
18924    as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5
18925  fi
18926
18927
18928
18929
18930  # Publish this variable in the help.
18931
18932
18933  if test "x$CODESIGN" = x; then
18934    # The variable is not set by user, try to locate tool using the code snippet
18935    for ac_prog in codesign
18936do
18937  # Extract the first word of "$ac_prog", so it can be a program name with args.
18938set dummy $ac_prog; ac_word=$2
18939{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18940$as_echo_n "checking for $ac_word... " >&6; }
18941if ${ac_cv_path_CODESIGN+:} false; then :
18942  $as_echo_n "(cached) " >&6
18943else
18944  case $CODESIGN in
18945  [\\/]* | ?:[\\/]*)
18946  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
18947  ;;
18948  *)
18949  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18950for as_dir in $PATH
18951do
18952  IFS=$as_save_IFS
18953  test -z "$as_dir" && as_dir=.
18954    for ac_exec_ext in '' $ac_executable_extensions; do
18955  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18956    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
18957    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18958    break 2
18959  fi
18960done
18961  done
18962IFS=$as_save_IFS
18963
18964  ;;
18965esac
18966fi
18967CODESIGN=$ac_cv_path_CODESIGN
18968if test -n "$CODESIGN"; then
18969  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
18970$as_echo "$CODESIGN" >&6; }
18971else
18972  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18973$as_echo "no" >&6; }
18974fi
18975
18976
18977  test -n "$CODESIGN" && break
18978done
18979
18980  else
18981    # The variable is set, but is it from the command line or the environment?
18982
18983    # Try to remove the string !CODESIGN! from our list.
18984    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/}
18985    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18986      # If it failed, the variable was not from the command line. Ignore it,
18987      # but warn the user (except for BASH, which is always set by the calling BASH).
18988      if test "xCODESIGN" != xBASH; then
18989        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5
18990$as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;}
18991      fi
18992      # Try to locate tool using the code snippet
18993      for ac_prog in codesign
18994do
18995  # Extract the first word of "$ac_prog", so it can be a program name with args.
18996set dummy $ac_prog; ac_word=$2
18997{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18998$as_echo_n "checking for $ac_word... " >&6; }
18999if ${ac_cv_path_CODESIGN+:} false; then :
19000  $as_echo_n "(cached) " >&6
19001else
19002  case $CODESIGN in
19003  [\\/]* | ?:[\\/]*)
19004  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19005  ;;
19006  *)
19007  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19008for as_dir in $PATH
19009do
19010  IFS=$as_save_IFS
19011  test -z "$as_dir" && as_dir=.
19012    for ac_exec_ext in '' $ac_executable_extensions; do
19013  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19014    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19015    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19016    break 2
19017  fi
19018done
19019  done
19020IFS=$as_save_IFS
19021
19022  ;;
19023esac
19024fi
19025CODESIGN=$ac_cv_path_CODESIGN
19026if test -n "$CODESIGN"; then
19027  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19028$as_echo "$CODESIGN" >&6; }
19029else
19030  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19031$as_echo "no" >&6; }
19032fi
19033
19034
19035  test -n "$CODESIGN" && break
19036done
19037
19038    else
19039      # If it succeeded, then it was overridden by the user. We will use it
19040      # for the tool.
19041
19042      # First remove it from the list of overridden variables, so we can test
19043      # for unknown variables in the end.
19044      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19045
19046      # Check if the provided tool contains a complete path.
19047      tool_specified="$CODESIGN"
19048      tool_basename="${tool_specified##*/}"
19049      if test "x$tool_basename" = "x$tool_specified"; then
19050        # A command without a complete path is provided, search $PATH.
19051        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5
19052$as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;}
19053        # Extract the first word of "$tool_basename", so it can be a program name with args.
19054set dummy $tool_basename; ac_word=$2
19055{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19056$as_echo_n "checking for $ac_word... " >&6; }
19057if ${ac_cv_path_CODESIGN+:} false; then :
19058  $as_echo_n "(cached) " >&6
19059else
19060  case $CODESIGN in
19061  [\\/]* | ?:[\\/]*)
19062  ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19063  ;;
19064  *)
19065  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19066for as_dir in $PATH
19067do
19068  IFS=$as_save_IFS
19069  test -z "$as_dir" && as_dir=.
19070    for ac_exec_ext in '' $ac_executable_extensions; do
19071  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19072    ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19073    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19074    break 2
19075  fi
19076done
19077  done
19078IFS=$as_save_IFS
19079
19080  ;;
19081esac
19082fi
19083CODESIGN=$ac_cv_path_CODESIGN
19084if test -n "$CODESIGN"; then
19085  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19086$as_echo "$CODESIGN" >&6; }
19087else
19088  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19089$as_echo "no" >&6; }
19090fi
19091
19092
19093        if test "x$CODESIGN" = x; then
19094          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19095        fi
19096      else
19097        # Otherwise we believe it is a complete path. Use it as it is.
19098        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5
19099$as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;}
19100        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5
19101$as_echo_n "checking for CODESIGN... " >&6; }
19102        if test ! -x "$tool_specified"; then
19103          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19104$as_echo "not found" >&6; }
19105          as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5
19106        fi
19107        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19108$as_echo "$tool_specified" >&6; }
19109      fi
19110    fi
19111  fi
19112
19113
19114    if test "x$CODESIGN" != "x"; then
19115      # Verify that the openjdk_codesign certificate is present
19116      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5
19117$as_echo_n "checking if openjdk_codesign certificate is present... " >&6; }
19118      rm -f codesign-testfile
19119      touch codesign-testfile
19120      codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN=
19121      rm -f codesign-testfile
19122      if test "x$CODESIGN" = x; then
19123        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19124$as_echo "no" >&6; }
19125      else
19126        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19127$as_echo "yes" >&6; }
19128      fi
19129    fi
19130  fi
19131
19132
19133# Check if pkg-config is available.
19134
19135
19136if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
19137	if test -n "$ac_tool_prefix"; then
19138  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
19139set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
19140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19141$as_echo_n "checking for $ac_word... " >&6; }
19142if ${ac_cv_path_PKG_CONFIG+:} false; then :
19143  $as_echo_n "(cached) " >&6
19144else
19145  case $PKG_CONFIG in
19146  [\\/]* | ?:[\\/]*)
19147  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
19148  ;;
19149  *)
19150  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19151for as_dir in $PATH
19152do
19153  IFS=$as_save_IFS
19154  test -z "$as_dir" && as_dir=.
19155    for ac_exec_ext in '' $ac_executable_extensions; do
19156  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19157    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19158    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19159    break 2
19160  fi
19161done
19162  done
19163IFS=$as_save_IFS
19164
19165  ;;
19166esac
19167fi
19168PKG_CONFIG=$ac_cv_path_PKG_CONFIG
19169if test -n "$PKG_CONFIG"; then
19170  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19171$as_echo "$PKG_CONFIG" >&6; }
19172else
19173  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19174$as_echo "no" >&6; }
19175fi
19176
19177
19178fi
19179if test -z "$ac_cv_path_PKG_CONFIG"; then
19180  ac_pt_PKG_CONFIG=$PKG_CONFIG
19181  # Extract the first word of "pkg-config", so it can be a program name with args.
19182set dummy pkg-config; ac_word=$2
19183{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19184$as_echo_n "checking for $ac_word... " >&6; }
19185if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
19186  $as_echo_n "(cached) " >&6
19187else
19188  case $ac_pt_PKG_CONFIG in
19189  [\\/]* | ?:[\\/]*)
19190  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
19191  ;;
19192  *)
19193  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19194for as_dir in $PATH
19195do
19196  IFS=$as_save_IFS
19197  test -z "$as_dir" && as_dir=.
19198    for ac_exec_ext in '' $ac_executable_extensions; do
19199  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19200    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19201    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19202    break 2
19203  fi
19204done
19205  done
19206IFS=$as_save_IFS
19207
19208  ;;
19209esac
19210fi
19211ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
19212if test -n "$ac_pt_PKG_CONFIG"; then
19213  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
19214$as_echo "$ac_pt_PKG_CONFIG" >&6; }
19215else
19216  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19217$as_echo "no" >&6; }
19218fi
19219
19220  if test "x$ac_pt_PKG_CONFIG" = x; then
19221    PKG_CONFIG=""
19222  else
19223    case $cross_compiling:$ac_tool_warned in
19224yes:)
19225{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19226$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19227ac_tool_warned=yes ;;
19228esac
19229    PKG_CONFIG=$ac_pt_PKG_CONFIG
19230  fi
19231else
19232  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
19233fi
19234
19235fi
19236if test -n "$PKG_CONFIG"; then
19237	_pkg_min_version=0.9.0
19238	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
19239$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
19240	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
19241		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19242$as_echo "yes" >&6; }
19243	else
19244		{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19245$as_echo "no" >&6; }
19246		PKG_CONFIG=""
19247	fi
19248
19249fi
19250
19251# After basic tools have been setup, we can check build os specific details.
19252
19253  ###############################################################################
19254
19255  # Note that this is the build platform OS version!
19256
19257  OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`"
19258  OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`"
19259  OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`"
19260  OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`"
19261
19262
19263
19264
19265
19266# Setup builddeps, for automatic downloading of tools we need.
19267# This is needed before we can call BDEPS_CHECK_MODULE, which is done in
19268# boot-jdk setup, but we need to have basic tools setup first.
19269
19270
19271# Check whether --with-builddeps-conf was given.
19272if test "${with_builddeps_conf+set}" = set; then :
19273  withval=$with_builddeps_conf;
19274fi
19275
19276
19277
19278# Check whether --with-builddeps-server was given.
19279if test "${with_builddeps_server+set}" = set; then :
19280  withval=$with_builddeps_server;
19281fi
19282
19283
19284
19285# Check whether --with-builddeps-dir was given.
19286if test "${with_builddeps_dir+set}" = set; then :
19287  withval=$with_builddeps_dir;
19288else
19289  with_builddeps_dir=/localhome/builddeps
19290fi
19291
19292
19293
19294# Check whether --with-builddeps-group was given.
19295if test "${with_builddeps_group+set}" = set; then :
19296  withval=$with_builddeps_group;
19297fi
19298
19299
19300
19301
19302  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19303    if test "x$with_builddeps_conf" != x; then
19304      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5
19305$as_echo_n "checking for supplied builddeps configuration file... " >&6; }
19306      builddepsfile=$with_builddeps_conf
19307      if test -s $builddepsfile; then
19308        . $builddepsfile
19309        { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5
19310$as_echo "loaded!" >&6; }
19311      else
19312        as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5
19313      fi
19314    else
19315      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5
19316$as_echo_n "checking for builddeps.conf files in sources...... " >&6; }
19317      builddepsfile=`mktemp`
19318      touch $builddepsfile
19319      # Put all found confs into a single file.
19320      find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile
19321      # Source the file to acquire the variables
19322      if test -s $builddepsfile; then
19323        . $builddepsfile
19324        { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5
19325$as_echo "found at least one!" >&6; }
19326      else
19327        as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5
19328      fi
19329    fi
19330    # Create build and target names that use _ instead of "-" and ".".
19331    # This is necessary to use them in variable names.
19332    build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19333    target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19334    # Extract rewrite information for build and target
19335    eval rewritten_build=\${REWRITE_${build_var}}
19336    if test "x$rewritten_build" = x; then
19337      rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME}
19338      echo Build stays the same $rewritten_build
19339    else
19340      echo Rewriting build for builddeps into $rewritten_build
19341    fi
19342    eval rewritten_target=\${REWRITE_${target_var}}
19343    if test "x$rewritten_target" = x; then
19344      rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME}
19345      echo Target stays the same $rewritten_target
19346    else
19347      echo Rewriting target for builddeps into $rewritten_target
19348    fi
19349    rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'`
19350    rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'`
19351  fi
19352  for ac_prog in 7z unzip
19353do
19354  # Extract the first word of "$ac_prog", so it can be a program name with args.
19355set dummy $ac_prog; ac_word=$2
19356{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19357$as_echo_n "checking for $ac_word... " >&6; }
19358if ${ac_cv_prog_BDEPS_UNZIP+:} false; then :
19359  $as_echo_n "(cached) " >&6
19360else
19361  if test -n "$BDEPS_UNZIP"; then
19362  ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test.
19363else
19364as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19365for as_dir in $PATH
19366do
19367  IFS=$as_save_IFS
19368  test -z "$as_dir" && as_dir=.
19369    for ac_exec_ext in '' $ac_executable_extensions; do
19370  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19371    ac_cv_prog_BDEPS_UNZIP="$ac_prog"
19372    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19373    break 2
19374  fi
19375done
19376  done
19377IFS=$as_save_IFS
19378
19379fi
19380fi
19381BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP
19382if test -n "$BDEPS_UNZIP"; then
19383  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5
19384$as_echo "$BDEPS_UNZIP" >&6; }
19385else
19386  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19387$as_echo "no" >&6; }
19388fi
19389
19390
19391  test -n "$BDEPS_UNZIP" && break
19392done
19393
19394  if test "x$BDEPS_UNZIP" = x7z; then
19395    BDEPS_UNZIP="7z x"
19396  fi
19397
19398  for ac_prog in wget lftp ftp
19399do
19400  # Extract the first word of "$ac_prog", so it can be a program name with args.
19401set dummy $ac_prog; ac_word=$2
19402{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19403$as_echo_n "checking for $ac_word... " >&6; }
19404if ${ac_cv_prog_BDEPS_FTP+:} false; then :
19405  $as_echo_n "(cached) " >&6
19406else
19407  if test -n "$BDEPS_FTP"; then
19408  ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test.
19409else
19410as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19411for as_dir in $PATH
19412do
19413  IFS=$as_save_IFS
19414  test -z "$as_dir" && as_dir=.
19415    for ac_exec_ext in '' $ac_executable_extensions; do
19416  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19417    ac_cv_prog_BDEPS_FTP="$ac_prog"
19418    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19419    break 2
19420  fi
19421done
19422  done
19423IFS=$as_save_IFS
19424
19425fi
19426fi
19427BDEPS_FTP=$ac_cv_prog_BDEPS_FTP
19428if test -n "$BDEPS_FTP"; then
19429  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5
19430$as_echo "$BDEPS_FTP" >&6; }
19431else
19432  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19433$as_echo "no" >&6; }
19434fi
19435
19436
19437  test -n "$BDEPS_FTP" && break
19438done
19439
19440
19441
19442###############################################################################
19443#
19444# Determine OpenJDK variants, options and version numbers.
19445#
19446###############################################################################
19447
19448# We need build & target for this.
19449
19450
19451  ###############################################################################
19452  #
19453  # Should we build a JDK/JVM with headful support (ie a graphical ui)?
19454  # We always build headless support.
19455  #
19456  { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5
19457$as_echo_n "checking headful support... " >&6; }
19458  # Check whether --enable-headful was given.
19459if test "${enable_headful+set}" = set; then :
19460  enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful}
19461else
19462  SUPPORT_HEADFUL=yes
19463fi
19464
19465
19466  SUPPORT_HEADLESS=yes
19467  BUILD_HEADLESS="BUILD_HEADLESS:=true"
19468
19469  if test "x$SUPPORT_HEADFUL" = xyes; then
19470    # We are building both headful and headless.
19471    headful_msg="include support for both headful and headless"
19472  fi
19473
19474  if test "x$SUPPORT_HEADFUL" = xno; then
19475    # Thus we are building headless only.
19476    BUILD_HEADLESS="BUILD_HEADLESS:=true"
19477    headful_msg="headless only"
19478  fi
19479
19480  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5
19481$as_echo "$headful_msg" >&6; }
19482
19483
19484
19485
19486
19487  # Control wether Hotspot runs Queens test after build.
19488  # Check whether --enable-hotspot-test-in-build was given.
19489if test "${enable_hotspot_test_in_build+set}" = set; then :
19490  enableval=$enable_hotspot_test_in_build;
19491else
19492  enable_hotspot_test_in_build=no
19493fi
19494
19495  if test "x$enable_hotspot_test_in_build" = "xyes"; then
19496    TEST_IN_BUILD=true
19497  else
19498    TEST_IN_BUILD=false
19499  fi
19500
19501
19502  ###############################################################################
19503  #
19504  # Choose cacerts source file
19505  #
19506
19507# Check whether --with-cacerts-file was given.
19508if test "${with_cacerts_file+set}" = set; then :
19509  withval=$with_cacerts_file;
19510fi
19511
19512  if test "x$with_cacerts_file" != x; then
19513    CACERTS_FILE=$with_cacerts_file
19514  else
19515    CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts
19516  fi
19517
19518
19519  ###############################################################################
19520  #
19521  # Enable or disable unlimited crypto
19522  #
19523  # Check whether --enable-unlimited-crypto was given.
19524if test "${enable_unlimited_crypto+set}" = set; then :
19525  enableval=$enable_unlimited_crypto;
19526else
19527  enable_unlimited_crypto=no
19528fi
19529
19530  if test "x$enable_unlimited_crypto" = "xyes"; then
19531    UNLIMITED_CRYPTO=true
19532  else
19533    UNLIMITED_CRYPTO=false
19534  fi
19535
19536
19537  ###############################################################################
19538  #
19539  # Enable or disable the elliptic curve crypto implementation
19540  #
19541
19542
19543  ###############################################################################
19544  #
19545  # --enable-rmiconnector-iiop
19546  #
19547  # Check whether --enable-rmiconnector-iiop was given.
19548if test "${enable_rmiconnector_iiop+set}" = set; then :
19549  enableval=$enable_rmiconnector_iiop;
19550fi
19551
19552  if test "x$enable_rmiconnector_iiop" = "xyes"; then
19553    RMICONNECTOR_IIOP=true
19554  else
19555    RMICONNECTOR_IIOP=false
19556  fi
19557
19558
19559  ###############################################################################
19560  #
19561  # Compress jars
19562  #
19563  COMPRESS_JARS=false
19564
19565
19566
19567
19568  # Source the version numbers
19569  . $AUTOCONF_DIR/version-numbers
19570
19571  # Get the settings from parameters
19572
19573# Check whether --with-milestone was given.
19574if test "${with_milestone+set}" = set; then :
19575  withval=$with_milestone;
19576fi
19577
19578  if test "x$with_milestone" = xyes; then
19579    as_fn_error $? "Milestone must have a value" "$LINENO" 5
19580  elif test "x$with_milestone" != x; then
19581    MILESTONE="$with_milestone"
19582  fi
19583  if test "x$MILESTONE" = x; then
19584    MILESTONE=internal
19585  fi
19586
19587
19588# Check whether --with-update-version was given.
19589if test "${with_update_version+set}" = set; then :
19590  withval=$with_update_version;
19591fi
19592
19593  if test "x$with_update_version" = xyes; then
19594    as_fn_error $? "Update version must have a value" "$LINENO" 5
19595  elif test "x$with_update_version" != x; then
19596    JDK_UPDATE_VERSION="$with_update_version"
19597    # On macosx 10.7, it's not possible to set --with-update-version=0X due
19598    # to a bug in expr (which reduces it to just X). To work around this, we
19599    # always add a 0 to one digit update versions.
19600    if test "${#JDK_UPDATE_VERSION}" = "1"; then
19601      JDK_UPDATE_VERSION="0${JDK_UPDATE_VERSION}"
19602    fi
19603  fi
19604
19605
19606# Check whether --with-user-release-suffix was given.
19607if test "${with_user_release_suffix+set}" = set; then :
19608  withval=$with_user_release_suffix;
19609fi
19610
19611  if test "x$with_user_release_suffix" = xyes; then
19612    as_fn_error $? "Release suffix must have a value" "$LINENO" 5
19613  elif test "x$with_user_release_suffix" != x; then
19614    USER_RELEASE_SUFFIX="$with_user_release_suffix"
19615  fi
19616
19617
19618# Check whether --with-build-number was given.
19619if test "${with_build_number+set}" = set; then :
19620  withval=$with_build_number;
19621fi
19622
19623  if test "x$with_build_number" = xyes; then
19624    as_fn_error $? "Build number must have a value" "$LINENO" 5
19625  elif test "x$with_build_number" != x; then
19626    JDK_BUILD_NUMBER="$with_build_number"
19627  fi
19628  # Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
19629  if test "x$JDK_BUILD_NUMBER" = x; then
19630    JDK_BUILD_NUMBER=b00
19631    if test "x$USER_RELEASE_SUFFIX" = x; then
19632      BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
19633      # Avoid [:alnum:] since it depends on the locale.
19634      CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
19635      USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19636    fi
19637  fi
19638
19639  # Now set the JDK version, milestone, build number etc.
19640
19641
19642
19643
19644
19645
19646
19647
19648
19649
19650
19651
19652
19653
19654
19655  COPYRIGHT_YEAR=`date +'%Y'`
19656
19657
19658  if test "x$JDK_UPDATE_VERSION" != x; then
19659    JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}"
19660  else
19661    JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}"
19662  fi
19663
19664
19665  COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'`
19666
19667
19668
19669###############################################################################
19670#
19671# Setup BootJDK, used to bootstrap the build.
19672#
19673###############################################################################
19674
19675
19676  BOOT_JDK_FOUND=no
19677
19678# Check whether --with-boot-jdk was given.
19679if test "${with_boot_jdk+set}" = set; then :
19680  withval=$with_boot_jdk;
19681fi
19682
19683
19684  # We look for the Boot JDK through various means, going from more certain to
19685  # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if
19686  # we detected something (if so, the path to the jdk is in BOOT_JDK). But we
19687  # must check if this is indeed valid; otherwise we'll continue looking.
19688
19689  # Test: Is bootjdk explicitely set by command line arguments?
19690
19691  if test "x$BOOT_JDK_FOUND" = xno; then
19692    # Now execute the test
19693
19694  if test "x$with_boot_jdk" != x; then
19695    BOOT_JDK=$with_boot_jdk
19696    BOOT_JDK_FOUND=maybe
19697    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5
19698$as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;}
19699  fi
19700
19701
19702    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
19703    if test "x$BOOT_JDK_FOUND" = xmaybe; then
19704      # Do we have a bin/java?
19705      if test ! -x "$BOOT_JDK/bin/java"; then
19706        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
19707$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
19708        BOOT_JDK_FOUND=no
19709      else
19710        # Do we have a bin/javac?
19711        if test ! -x "$BOOT_JDK/bin/javac"; then
19712          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
19713$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
19714          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
19715$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
19716          BOOT_JDK_FOUND=no
19717        else
19718          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
19719          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
19720            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
19721$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
19722            BOOT_JDK_FOUND=no
19723          else
19724            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
19725            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
19726
19727            # Extra M4 quote needed to protect [] in grep expression.
19728            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
19729            if test "x$FOUND_CORRECT_VERSION" = x; then
19730              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
19731$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
19732              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
19733$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
19734              BOOT_JDK_FOUND=no
19735            else
19736              # We're done! :-)
19737              BOOT_JDK_FOUND=yes
19738
19739  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19740
19741  # Input might be given as Windows format, start by converting to
19742  # unix format.
19743  path="$BOOT_JDK"
19744  new_path=`$CYGPATH -u "$path"`
19745
19746  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
19747  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
19748  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
19749  # "foo.exe" is OK but "foo" is an error.
19750  #
19751  # This test is therefore slightly more accurate than "test -f" to check for file precense.
19752  # It is also a way to make sure we got the proper file name for the real test later on.
19753  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
19754  if test "x$test_shortpath" = x; then
19755    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19756$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19757    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
19758  fi
19759
19760  # Call helper function which possibly converts this using DOS-style short mode.
19761  # If so, the updated path is stored in $new_path.
19762
19763  input_path="$new_path"
19764  # Check if we need to convert this using DOS-style short mode. If the path
19765  # contains just simple characters, use it. Otherwise (spaces, weird characters),
19766  # take no chances and rewrite it.
19767  # Note: m4 eats our [], so we need to use [ and ] instead.
19768  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
19769  if test "x$has_forbidden_chars" != x; then
19770    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19771    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
19772    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
19773    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
19774      # Going to short mode and back again did indeed matter. Since short mode is
19775      # case insensitive, let's make it lowercase to improve readability.
19776      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19777      # Now convert it back to Unix-stile (cygpath)
19778      input_path=`$CYGPATH -u "$shortmode_path"`
19779      new_path="$input_path"
19780    fi
19781  fi
19782
19783  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
19784  if test "x$test_cygdrive_prefix" = x; then
19785    # As a simple fix, exclude /usr/bin since it's not a real path.
19786    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
19787      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
19788      # a path prefixed by /cygdrive for fixpath to work.
19789      new_path="$CYGWIN_ROOT_PATH$input_path"
19790    fi
19791  fi
19792
19793
19794  if test "x$path" != "x$new_path"; then
19795    BOOT_JDK="$new_path"
19796    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19797$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19798  fi
19799
19800  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19801
19802  path="$BOOT_JDK"
19803  has_colon=`$ECHO $path | $GREP ^.:`
19804  new_path="$path"
19805  if test "x$has_colon" = x; then
19806    # Not in mixed or Windows style, start by that.
19807    new_path=`cmd //c echo $path`
19808  fi
19809
19810
19811  input_path="$new_path"
19812  # Check if we need to convert this using DOS-style short mode. If the path
19813  # contains just simple characters, use it. Otherwise (spaces, weird characters),
19814  # take no chances and rewrite it.
19815  # Note: m4 eats our [], so we need to use [ and ] instead.
19816  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
19817  if test "x$has_forbidden_chars" != x; then
19818    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19819    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19820  fi
19821
19822
19823  windows_path="$new_path"
19824  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19825    unix_path=`$CYGPATH -u "$windows_path"`
19826    new_path="$unix_path"
19827  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19828    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
19829    new_path="$unix_path"
19830  fi
19831
19832  if test "x$path" != "x$new_path"; then
19833    BOOT_JDK="$new_path"
19834    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19835$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19836  fi
19837
19838  # Save the first 10 bytes of this path to the storage, so fixpath can work.
19839  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
19840
19841  else
19842    # We're on a posix platform. Hooray! :)
19843    path="$BOOT_JDK"
19844    has_space=`$ECHO "$path" | $GREP " "`
19845    if test "x$has_space" != x; then
19846      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19847$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19848      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
19849    fi
19850
19851    # Use eval to expand a potential ~
19852    eval path="$path"
19853    if test ! -f "$path" && test ! -d "$path"; then
19854      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
19855    fi
19856
19857    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
19858  fi
19859
19860              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
19861$as_echo_n "checking for Boot JDK... " >&6; }
19862              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
19863$as_echo "$BOOT_JDK" >&6; }
19864              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
19865$as_echo_n "checking Boot JDK version... " >&6; }
19866              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
19867              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
19868$as_echo "$BOOT_JDK_VERSION" >&6; }
19869            fi # end check jdk version
19870          fi # end check rt.jar
19871        fi # end check javac
19872      fi # end check java
19873    fi # end check boot jdk found
19874  fi
19875
19876  if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then
19877    # Having specified an argument which is incorrect will produce an instant failure;
19878    # we should not go on looking
19879    as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5
19880  fi
19881
19882  # Test: Is bootjdk available from builddeps?
19883
19884  if test "x$BOOT_JDK_FOUND" = xno; then
19885    # Now execute the test
19886
19887
19888
19889  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19890    # Source the builddeps file again, to make sure it uses the latest variables!
19891    . $builddepsfile
19892    # Look for a target and build machine specific resource!
19893    eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
19894    if test "x$resource" = x; then
19895      # Ok, lets instead look for a target specific resource
19896      eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}}
19897    fi
19898    if test "x$resource" = x; then
19899      # Ok, lets instead look for a build specific resource
19900      eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}}
19901    fi
19902    if test "x$resource" = x; then
19903      # Ok, lets instead look for a generic resource
19904      # (The bootjdk comes from M4 and not the shell, thus no need for eval here.)
19905      resource=${builddep_bootjdk}
19906    fi
19907    if test "x$resource" != x; then
19908      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5
19909$as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;}
19910      # If the resource in the builddeps.conf file is an existing directory,
19911      # for example /java/linux/cups
19912      if test -d ${resource}; then
19913        depdir=${resource}
19914      else
19915
19916  # bootjdk is for example mymodule
19917  # $resource is for example libs/general/libmymod_1_2_3.zip
19918  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
19919  # $with_builddeps_dir is for example /localhome/builddeps
19920  # depdir is the name of the variable into which we store the depdir, eg MYMOD
19921  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
19922  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
19923  filename=`basename $resource`
19924  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
19925  filebase=${filename%%.*}
19926  extension=${filename#*.}
19927  installdir=$with_builddeps_dir/$filebase
19928  if test ! -f $installdir/$filename.unpacked; then
19929    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5
19930$as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;}
19931    if test ! -d $installdir; then
19932      mkdir -p $installdir
19933    fi
19934    if test ! -d $installdir; then
19935      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
19936    fi
19937    tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX`
19938    touch $tmpfile
19939    if test ! -f $tmpfile; then
19940      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
19941    fi
19942
19943  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
19944  # $tmpfile is the local file name for the downloaded file.
19945  VALID_TOOL=no
19946  if test "x$BDEPS_FTP" = xwget; then
19947    VALID_TOOL=yes
19948    wget -O $tmpfile $with_builddeps_server/$resource
19949  fi
19950  if test "x$BDEPS_FTP" = xlftp; then
19951    VALID_TOOL=yes
19952    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
19953  fi
19954  if test "x$BDEPS_FTP" = xftp; then
19955    VALID_TOOL=yes
19956    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
19957    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
19958    FTPUSERPWD=${FTPSERVER%%@*}
19959    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
19960      FTPUSER=${userpwd%%:*}
19961      FTPPWD=${userpwd#*@}
19962      FTPSERVER=${FTPSERVER#*@}
19963    else
19964      FTPUSER=ftp
19965      FTPPWD=ftp
19966    fi
19967    # the "pass" command does not work on some
19968    # ftp clients (read ftp.exe) but if it works,
19969    # passive mode is better!
19970    ( \
19971        echo "user $FTPUSER $FTPPWD"        ; \
19972        echo "pass"                         ; \
19973        echo "bin"                          ; \
19974        echo "get $FTPPATH $tmpfile"              ; \
19975    ) | ftp -in $FTPSERVER
19976  fi
19977  if test "x$VALID_TOOL" != xyes; then
19978    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
19979  fi
19980
19981    mv $tmpfile $installdir/$filename
19982    if test ! -s $installdir/$filename; then
19983      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
19984    fi
19985    case "$extension" in
19986      zip)  echo "Unzipping $installdir/$filename..."
19987        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
19988        ;;
19989      tar.gz) echo "Untaring $installdir/$filename..."
19990        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19991        ;;
19992      tgz) echo "Untaring $installdir/$filename..."
19993        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19994        ;;
19995      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
19996        ;;
19997    esac
19998  fi
19999  if test -f $installdir/$filename.unpacked; then
20000    depdir=$installdir
20001  fi
20002
20003      fi
20004      # Source the builddeps file again, because in the previous command, the depdir
20005      # was updated to point at the current build dependency install directory.
20006      . $builddepsfile
20007      # Now extract variables from the builddeps.conf files.
20008      theroot=${builddep_bootjdk_ROOT}
20009      thecflags=${builddep_bootjdk_CFLAGS}
20010      thelibs=${builddep_bootjdk_LIBS}
20011      if test "x$depdir" = x; then
20012        as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5
20013      fi
20014      BOOT_JDK=$depdir
20015      if test "x$theroot" != x; then
20016        BOOT_JDK="$theroot"
20017      fi
20018      if test "x$thecflags" != x; then
20019        BOOT_JDK_CFLAGS="$thecflags"
20020      fi
20021      if test "x$thelibs" != x; then
20022        BOOT_JDK_LIBS="$thelibs"
20023      fi
20024      BOOT_JDK_FOUND=maybe
20025      else BOOT_JDK_FOUND=no
20026
20027    fi
20028    else BOOT_JDK_FOUND=no
20029
20030  fi
20031
20032
20033
20034    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20035    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20036      # Do we have a bin/java?
20037      if test ! -x "$BOOT_JDK/bin/java"; then
20038        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20039$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20040        BOOT_JDK_FOUND=no
20041      else
20042        # Do we have a bin/javac?
20043        if test ! -x "$BOOT_JDK/bin/javac"; then
20044          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20045$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20046          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20047$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20048          BOOT_JDK_FOUND=no
20049        else
20050          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20051          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20052            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20053$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20054            BOOT_JDK_FOUND=no
20055          else
20056            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20057            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20058
20059            # Extra M4 quote needed to protect [] in grep expression.
20060            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20061            if test "x$FOUND_CORRECT_VERSION" = x; then
20062              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20063$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20064              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20065$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20066              BOOT_JDK_FOUND=no
20067            else
20068              # We're done! :-)
20069              BOOT_JDK_FOUND=yes
20070
20071  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20072
20073  # Input might be given as Windows format, start by converting to
20074  # unix format.
20075  path="$BOOT_JDK"
20076  new_path=`$CYGPATH -u "$path"`
20077
20078  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20079  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20080  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20081  # "foo.exe" is OK but "foo" is an error.
20082  #
20083  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20084  # It is also a way to make sure we got the proper file name for the real test later on.
20085  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20086  if test "x$test_shortpath" = x; then
20087    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20088$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20089    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20090  fi
20091
20092  # Call helper function which possibly converts this using DOS-style short mode.
20093  # If so, the updated path is stored in $new_path.
20094
20095  input_path="$new_path"
20096  # Check if we need to convert this using DOS-style short mode. If the path
20097  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20098  # take no chances and rewrite it.
20099  # Note: m4 eats our [], so we need to use [ and ] instead.
20100  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20101  if test "x$has_forbidden_chars" != x; then
20102    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20103    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20104    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20105    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20106      # Going to short mode and back again did indeed matter. Since short mode is
20107      # case insensitive, let's make it lowercase to improve readability.
20108      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20109      # Now convert it back to Unix-stile (cygpath)
20110      input_path=`$CYGPATH -u "$shortmode_path"`
20111      new_path="$input_path"
20112    fi
20113  fi
20114
20115  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20116  if test "x$test_cygdrive_prefix" = x; then
20117    # As a simple fix, exclude /usr/bin since it's not a real path.
20118    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20119      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20120      # a path prefixed by /cygdrive for fixpath to work.
20121      new_path="$CYGWIN_ROOT_PATH$input_path"
20122    fi
20123  fi
20124
20125
20126  if test "x$path" != "x$new_path"; then
20127    BOOT_JDK="$new_path"
20128    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20129$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20130  fi
20131
20132  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20133
20134  path="$BOOT_JDK"
20135  has_colon=`$ECHO $path | $GREP ^.:`
20136  new_path="$path"
20137  if test "x$has_colon" = x; then
20138    # Not in mixed or Windows style, start by that.
20139    new_path=`cmd //c echo $path`
20140  fi
20141
20142
20143  input_path="$new_path"
20144  # Check if we need to convert this using DOS-style short mode. If the path
20145  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20146  # take no chances and rewrite it.
20147  # Note: m4 eats our [], so we need to use [ and ] instead.
20148  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20149  if test "x$has_forbidden_chars" != x; then
20150    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20151    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20152  fi
20153
20154
20155  windows_path="$new_path"
20156  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20157    unix_path=`$CYGPATH -u "$windows_path"`
20158    new_path="$unix_path"
20159  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20160    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20161    new_path="$unix_path"
20162  fi
20163
20164  if test "x$path" != "x$new_path"; then
20165    BOOT_JDK="$new_path"
20166    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20167$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20168  fi
20169
20170  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20171  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20172
20173  else
20174    # We're on a posix platform. Hooray! :)
20175    path="$BOOT_JDK"
20176    has_space=`$ECHO "$path" | $GREP " "`
20177    if test "x$has_space" != x; then
20178      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20179$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20180      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20181    fi
20182
20183    # Use eval to expand a potential ~
20184    eval path="$path"
20185    if test ! -f "$path" && test ! -d "$path"; then
20186      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20187    fi
20188
20189    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20190  fi
20191
20192              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20193$as_echo_n "checking for Boot JDK... " >&6; }
20194              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20195$as_echo "$BOOT_JDK" >&6; }
20196              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20197$as_echo_n "checking Boot JDK version... " >&6; }
20198              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20199              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20200$as_echo "$BOOT_JDK_VERSION" >&6; }
20201            fi # end check jdk version
20202          fi # end check rt.jar
20203        fi # end check javac
20204      fi # end check java
20205    fi # end check boot jdk found
20206  fi
20207
20208
20209  # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
20210
20211  if test "x$BOOT_JDK_FOUND" = xno; then
20212    # Now execute the test
20213
20214  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
20215    # First check at user selected default
20216
20217  if test "x$BOOT_JDK_FOUND" = xno; then
20218    # Now execute the test
20219
20220  if test -x /usr/libexec/java_home; then
20221    BOOT_JDK=`/usr/libexec/java_home `
20222    BOOT_JDK_FOUND=maybe
20223    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5
20224$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;}
20225  fi
20226
20227
20228    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20229    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20230      # Do we have a bin/java?
20231      if test ! -x "$BOOT_JDK/bin/java"; then
20232        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20233$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20234        BOOT_JDK_FOUND=no
20235      else
20236        # Do we have a bin/javac?
20237        if test ! -x "$BOOT_JDK/bin/javac"; then
20238          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20239$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20240          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20241$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20242          BOOT_JDK_FOUND=no
20243        else
20244          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20245          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20246            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20247$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20248            BOOT_JDK_FOUND=no
20249          else
20250            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20251            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20252
20253            # Extra M4 quote needed to protect [] in grep expression.
20254            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20255            if test "x$FOUND_CORRECT_VERSION" = x; then
20256              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20257$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20258              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20259$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20260              BOOT_JDK_FOUND=no
20261            else
20262              # We're done! :-)
20263              BOOT_JDK_FOUND=yes
20264
20265  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20266
20267  # Input might be given as Windows format, start by converting to
20268  # unix format.
20269  path="$BOOT_JDK"
20270  new_path=`$CYGPATH -u "$path"`
20271
20272  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20273  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20274  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20275  # "foo.exe" is OK but "foo" is an error.
20276  #
20277  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20278  # It is also a way to make sure we got the proper file name for the real test later on.
20279  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20280  if test "x$test_shortpath" = x; then
20281    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20282$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20283    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20284  fi
20285
20286  # Call helper function which possibly converts this using DOS-style short mode.
20287  # If so, the updated path is stored in $new_path.
20288
20289  input_path="$new_path"
20290  # Check if we need to convert this using DOS-style short mode. If the path
20291  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20292  # take no chances and rewrite it.
20293  # Note: m4 eats our [], so we need to use [ and ] instead.
20294  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20295  if test "x$has_forbidden_chars" != x; then
20296    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20297    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20298    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20299    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20300      # Going to short mode and back again did indeed matter. Since short mode is
20301      # case insensitive, let's make it lowercase to improve readability.
20302      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20303      # Now convert it back to Unix-stile (cygpath)
20304      input_path=`$CYGPATH -u "$shortmode_path"`
20305      new_path="$input_path"
20306    fi
20307  fi
20308
20309  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20310  if test "x$test_cygdrive_prefix" = x; then
20311    # As a simple fix, exclude /usr/bin since it's not a real path.
20312    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20313      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20314      # a path prefixed by /cygdrive for fixpath to work.
20315      new_path="$CYGWIN_ROOT_PATH$input_path"
20316    fi
20317  fi
20318
20319
20320  if test "x$path" != "x$new_path"; then
20321    BOOT_JDK="$new_path"
20322    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20323$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20324  fi
20325
20326  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20327
20328  path="$BOOT_JDK"
20329  has_colon=`$ECHO $path | $GREP ^.:`
20330  new_path="$path"
20331  if test "x$has_colon" = x; then
20332    # Not in mixed or Windows style, start by that.
20333    new_path=`cmd //c echo $path`
20334  fi
20335
20336
20337  input_path="$new_path"
20338  # Check if we need to convert this using DOS-style short mode. If the path
20339  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20340  # take no chances and rewrite it.
20341  # Note: m4 eats our [], so we need to use [ and ] instead.
20342  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20343  if test "x$has_forbidden_chars" != x; then
20344    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20345    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20346  fi
20347
20348
20349  windows_path="$new_path"
20350  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20351    unix_path=`$CYGPATH -u "$windows_path"`
20352    new_path="$unix_path"
20353  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20354    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20355    new_path="$unix_path"
20356  fi
20357
20358  if test "x$path" != "x$new_path"; then
20359    BOOT_JDK="$new_path"
20360    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20361$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20362  fi
20363
20364  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20365  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20366
20367  else
20368    # We're on a posix platform. Hooray! :)
20369    path="$BOOT_JDK"
20370    has_space=`$ECHO "$path" | $GREP " "`
20371    if test "x$has_space" != x; then
20372      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20373$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20374      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20375    fi
20376
20377    # Use eval to expand a potential ~
20378    eval path="$path"
20379    if test ! -f "$path" && test ! -d "$path"; then
20380      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20381    fi
20382
20383    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20384  fi
20385
20386              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20387$as_echo_n "checking for Boot JDK... " >&6; }
20388              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20389$as_echo "$BOOT_JDK" >&6; }
20390              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20391$as_echo_n "checking Boot JDK version... " >&6; }
20392              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20393              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20394$as_echo "$BOOT_JDK_VERSION" >&6; }
20395            fi # end check jdk version
20396          fi # end check rt.jar
20397        fi # end check javac
20398      fi # end check java
20399    fi # end check boot jdk found
20400  fi
20401
20402    # If that did not work out (e.g. too old), try explicit versions instead
20403
20404  if test "x$BOOT_JDK_FOUND" = xno; then
20405    # Now execute the test
20406
20407  if test -x /usr/libexec/java_home; then
20408    BOOT_JDK=`/usr/libexec/java_home -v 1.9`
20409    BOOT_JDK_FOUND=maybe
20410    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5
20411$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;}
20412  fi
20413
20414
20415    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20416    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20417      # Do we have a bin/java?
20418      if test ! -x "$BOOT_JDK/bin/java"; then
20419        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20420$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20421        BOOT_JDK_FOUND=no
20422      else
20423        # Do we have a bin/javac?
20424        if test ! -x "$BOOT_JDK/bin/javac"; then
20425          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20426$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20427          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20428$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20429          BOOT_JDK_FOUND=no
20430        else
20431          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20432          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20433            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20434$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20435            BOOT_JDK_FOUND=no
20436          else
20437            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20438            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20439
20440            # Extra M4 quote needed to protect [] in grep expression.
20441            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20442            if test "x$FOUND_CORRECT_VERSION" = x; then
20443              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20444$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20445              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20446$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20447              BOOT_JDK_FOUND=no
20448            else
20449              # We're done! :-)
20450              BOOT_JDK_FOUND=yes
20451
20452  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20453
20454  # Input might be given as Windows format, start by converting to
20455  # unix format.
20456  path="$BOOT_JDK"
20457  new_path=`$CYGPATH -u "$path"`
20458
20459  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20460  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20461  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20462  # "foo.exe" is OK but "foo" is an error.
20463  #
20464  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20465  # It is also a way to make sure we got the proper file name for the real test later on.
20466  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20467  if test "x$test_shortpath" = x; then
20468    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20469$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20470    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20471  fi
20472
20473  # Call helper function which possibly converts this using DOS-style short mode.
20474  # If so, the updated path is stored in $new_path.
20475
20476  input_path="$new_path"
20477  # Check if we need to convert this using DOS-style short mode. If the path
20478  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20479  # take no chances and rewrite it.
20480  # Note: m4 eats our [], so we need to use [ and ] instead.
20481  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20482  if test "x$has_forbidden_chars" != x; then
20483    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20484    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20485    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20486    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20487      # Going to short mode and back again did indeed matter. Since short mode is
20488      # case insensitive, let's make it lowercase to improve readability.
20489      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20490      # Now convert it back to Unix-stile (cygpath)
20491      input_path=`$CYGPATH -u "$shortmode_path"`
20492      new_path="$input_path"
20493    fi
20494  fi
20495
20496  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20497  if test "x$test_cygdrive_prefix" = x; then
20498    # As a simple fix, exclude /usr/bin since it's not a real path.
20499    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20500      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20501      # a path prefixed by /cygdrive for fixpath to work.
20502      new_path="$CYGWIN_ROOT_PATH$input_path"
20503    fi
20504  fi
20505
20506
20507  if test "x$path" != "x$new_path"; then
20508    BOOT_JDK="$new_path"
20509    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20510$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20511  fi
20512
20513  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20514
20515  path="$BOOT_JDK"
20516  has_colon=`$ECHO $path | $GREP ^.:`
20517  new_path="$path"
20518  if test "x$has_colon" = x; then
20519    # Not in mixed or Windows style, start by that.
20520    new_path=`cmd //c echo $path`
20521  fi
20522
20523
20524  input_path="$new_path"
20525  # Check if we need to convert this using DOS-style short mode. If the path
20526  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20527  # take no chances and rewrite it.
20528  # Note: m4 eats our [], so we need to use [ and ] instead.
20529  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20530  if test "x$has_forbidden_chars" != x; then
20531    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20532    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20533  fi
20534
20535
20536  windows_path="$new_path"
20537  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20538    unix_path=`$CYGPATH -u "$windows_path"`
20539    new_path="$unix_path"
20540  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20541    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20542    new_path="$unix_path"
20543  fi
20544
20545  if test "x$path" != "x$new_path"; then
20546    BOOT_JDK="$new_path"
20547    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20548$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20549  fi
20550
20551  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20552  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20553
20554  else
20555    # We're on a posix platform. Hooray! :)
20556    path="$BOOT_JDK"
20557    has_space=`$ECHO "$path" | $GREP " "`
20558    if test "x$has_space" != x; then
20559      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20560$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20561      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20562    fi
20563
20564    # Use eval to expand a potential ~
20565    eval path="$path"
20566    if test ! -f "$path" && test ! -d "$path"; then
20567      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20568    fi
20569
20570    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20571  fi
20572
20573              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20574$as_echo_n "checking for Boot JDK... " >&6; }
20575              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20576$as_echo "$BOOT_JDK" >&6; }
20577              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20578$as_echo_n "checking Boot JDK version... " >&6; }
20579              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20580              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20581$as_echo "$BOOT_JDK_VERSION" >&6; }
20582            fi # end check jdk version
20583          fi # end check rt.jar
20584        fi # end check javac
20585      fi # end check java
20586    fi # end check boot jdk found
20587  fi
20588
20589
20590  if test "x$BOOT_JDK_FOUND" = xno; then
20591    # Now execute the test
20592
20593  if test -x /usr/libexec/java_home; then
20594    BOOT_JDK=`/usr/libexec/java_home -v 1.8`
20595    BOOT_JDK_FOUND=maybe
20596    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5
20597$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;}
20598  fi
20599
20600
20601    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20602    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20603      # Do we have a bin/java?
20604      if test ! -x "$BOOT_JDK/bin/java"; then
20605        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20606$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20607        BOOT_JDK_FOUND=no
20608      else
20609        # Do we have a bin/javac?
20610        if test ! -x "$BOOT_JDK/bin/javac"; then
20611          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20612$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20613          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20614$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20615          BOOT_JDK_FOUND=no
20616        else
20617          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20618          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20619            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20620$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20621            BOOT_JDK_FOUND=no
20622          else
20623            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20624            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20625
20626            # Extra M4 quote needed to protect [] in grep expression.
20627            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20628            if test "x$FOUND_CORRECT_VERSION" = x; then
20629              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20630$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20631              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20632$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20633              BOOT_JDK_FOUND=no
20634            else
20635              # We're done! :-)
20636              BOOT_JDK_FOUND=yes
20637
20638  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20639
20640  # Input might be given as Windows format, start by converting to
20641  # unix format.
20642  path="$BOOT_JDK"
20643  new_path=`$CYGPATH -u "$path"`
20644
20645  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20646  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20647  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20648  # "foo.exe" is OK but "foo" is an error.
20649  #
20650  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20651  # It is also a way to make sure we got the proper file name for the real test later on.
20652  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20653  if test "x$test_shortpath" = x; then
20654    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20655$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20656    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20657  fi
20658
20659  # Call helper function which possibly converts this using DOS-style short mode.
20660  # If so, the updated path is stored in $new_path.
20661
20662  input_path="$new_path"
20663  # Check if we need to convert this using DOS-style short mode. If the path
20664  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20665  # take no chances and rewrite it.
20666  # Note: m4 eats our [], so we need to use [ and ] instead.
20667  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20668  if test "x$has_forbidden_chars" != x; then
20669    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20670    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20671    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20672    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20673      # Going to short mode and back again did indeed matter. Since short mode is
20674      # case insensitive, let's make it lowercase to improve readability.
20675      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20676      # Now convert it back to Unix-stile (cygpath)
20677      input_path=`$CYGPATH -u "$shortmode_path"`
20678      new_path="$input_path"
20679    fi
20680  fi
20681
20682  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20683  if test "x$test_cygdrive_prefix" = x; then
20684    # As a simple fix, exclude /usr/bin since it's not a real path.
20685    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20686      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20687      # a path prefixed by /cygdrive for fixpath to work.
20688      new_path="$CYGWIN_ROOT_PATH$input_path"
20689    fi
20690  fi
20691
20692
20693  if test "x$path" != "x$new_path"; then
20694    BOOT_JDK="$new_path"
20695    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20696$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20697  fi
20698
20699  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20700
20701  path="$BOOT_JDK"
20702  has_colon=`$ECHO $path | $GREP ^.:`
20703  new_path="$path"
20704  if test "x$has_colon" = x; then
20705    # Not in mixed or Windows style, start by that.
20706    new_path=`cmd //c echo $path`
20707  fi
20708
20709
20710  input_path="$new_path"
20711  # Check if we need to convert this using DOS-style short mode. If the path
20712  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20713  # take no chances and rewrite it.
20714  # Note: m4 eats our [], so we need to use [ and ] instead.
20715  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20716  if test "x$has_forbidden_chars" != x; then
20717    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20718    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20719  fi
20720
20721
20722  windows_path="$new_path"
20723  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20724    unix_path=`$CYGPATH -u "$windows_path"`
20725    new_path="$unix_path"
20726  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20727    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20728    new_path="$unix_path"
20729  fi
20730
20731  if test "x$path" != "x$new_path"; then
20732    BOOT_JDK="$new_path"
20733    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20734$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20735  fi
20736
20737  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20738  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20739
20740  else
20741    # We're on a posix platform. Hooray! :)
20742    path="$BOOT_JDK"
20743    has_space=`$ECHO "$path" | $GREP " "`
20744    if test "x$has_space" != x; then
20745      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20746$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20747      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20748    fi
20749
20750    # Use eval to expand a potential ~
20751    eval path="$path"
20752    if test ! -f "$path" && test ! -d "$path"; then
20753      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20754    fi
20755
20756    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20757  fi
20758
20759              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20760$as_echo_n "checking for Boot JDK... " >&6; }
20761              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20762$as_echo "$BOOT_JDK" >&6; }
20763              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20764$as_echo_n "checking Boot JDK version... " >&6; }
20765              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20766              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20767$as_echo "$BOOT_JDK_VERSION" >&6; }
20768            fi # end check jdk version
20769          fi # end check rt.jar
20770        fi # end check javac
20771      fi # end check java
20772    fi # end check boot jdk found
20773  fi
20774
20775
20776  if test "x$BOOT_JDK_FOUND" = xno; then
20777    # Now execute the test
20778
20779  if test -x /usr/libexec/java_home; then
20780    BOOT_JDK=`/usr/libexec/java_home -v 1.7`
20781    BOOT_JDK_FOUND=maybe
20782    { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5
20783$as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;}
20784  fi
20785
20786
20787    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20788    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20789      # Do we have a bin/java?
20790      if test ! -x "$BOOT_JDK/bin/java"; then
20791        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20792$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20793        BOOT_JDK_FOUND=no
20794      else
20795        # Do we have a bin/javac?
20796        if test ! -x "$BOOT_JDK/bin/javac"; then
20797          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20798$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20799          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20800$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20801          BOOT_JDK_FOUND=no
20802        else
20803          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20804          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20805            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20806$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20807            BOOT_JDK_FOUND=no
20808          else
20809            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20810            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20811
20812            # Extra M4 quote needed to protect [] in grep expression.
20813            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20814            if test "x$FOUND_CORRECT_VERSION" = x; then
20815              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20816$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20817              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20818$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20819              BOOT_JDK_FOUND=no
20820            else
20821              # We're done! :-)
20822              BOOT_JDK_FOUND=yes
20823
20824  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20825
20826  # Input might be given as Windows format, start by converting to
20827  # unix format.
20828  path="$BOOT_JDK"
20829  new_path=`$CYGPATH -u "$path"`
20830
20831  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20832  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20833  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20834  # "foo.exe" is OK but "foo" is an error.
20835  #
20836  # This test is therefore slightly more accurate than "test -f" to check for file precense.
20837  # It is also a way to make sure we got the proper file name for the real test later on.
20838  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20839  if test "x$test_shortpath" = x; then
20840    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20841$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20842    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20843  fi
20844
20845  # Call helper function which possibly converts this using DOS-style short mode.
20846  # If so, the updated path is stored in $new_path.
20847
20848  input_path="$new_path"
20849  # Check if we need to convert this using DOS-style short mode. If the path
20850  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20851  # take no chances and rewrite it.
20852  # Note: m4 eats our [], so we need to use [ and ] instead.
20853  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20854  if test "x$has_forbidden_chars" != x; then
20855    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20856    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20857    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20858    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20859      # Going to short mode and back again did indeed matter. Since short mode is
20860      # case insensitive, let's make it lowercase to improve readability.
20861      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20862      # Now convert it back to Unix-stile (cygpath)
20863      input_path=`$CYGPATH -u "$shortmode_path"`
20864      new_path="$input_path"
20865    fi
20866  fi
20867
20868  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20869  if test "x$test_cygdrive_prefix" = x; then
20870    # As a simple fix, exclude /usr/bin since it's not a real path.
20871    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20872      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20873      # a path prefixed by /cygdrive for fixpath to work.
20874      new_path="$CYGWIN_ROOT_PATH$input_path"
20875    fi
20876  fi
20877
20878
20879  if test "x$path" != "x$new_path"; then
20880    BOOT_JDK="$new_path"
20881    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20882$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20883  fi
20884
20885  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20886
20887  path="$BOOT_JDK"
20888  has_colon=`$ECHO $path | $GREP ^.:`
20889  new_path="$path"
20890  if test "x$has_colon" = x; then
20891    # Not in mixed or Windows style, start by that.
20892    new_path=`cmd //c echo $path`
20893  fi
20894
20895
20896  input_path="$new_path"
20897  # Check if we need to convert this using DOS-style short mode. If the path
20898  # contains just simple characters, use it. Otherwise (spaces, weird characters),
20899  # take no chances and rewrite it.
20900  # Note: m4 eats our [], so we need to use [ and ] instead.
20901  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20902  if test "x$has_forbidden_chars" != x; then
20903    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20904    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20905  fi
20906
20907
20908  windows_path="$new_path"
20909  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20910    unix_path=`$CYGPATH -u "$windows_path"`
20911    new_path="$unix_path"
20912  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20913    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20914    new_path="$unix_path"
20915  fi
20916
20917  if test "x$path" != "x$new_path"; then
20918    BOOT_JDK="$new_path"
20919    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20920$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20921  fi
20922
20923  # Save the first 10 bytes of this path to the storage, so fixpath can work.
20924  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20925
20926  else
20927    # We're on a posix platform. Hooray! :)
20928    path="$BOOT_JDK"
20929    has_space=`$ECHO "$path" | $GREP " "`
20930    if test "x$has_space" != x; then
20931      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20932$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20933      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20934    fi
20935
20936    # Use eval to expand a potential ~
20937    eval path="$path"
20938    if test ! -f "$path" && test ! -d "$path"; then
20939      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20940    fi
20941
20942    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20943  fi
20944
20945              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20946$as_echo_n "checking for Boot JDK... " >&6; }
20947              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20948$as_echo "$BOOT_JDK" >&6; }
20949              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20950$as_echo_n "checking Boot JDK version... " >&6; }
20951              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20952              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20953$as_echo "$BOOT_JDK_VERSION" >&6; }
20954            fi # end check jdk version
20955          fi # end check rt.jar
20956        fi # end check javac
20957      fi # end check java
20958    fi # end check boot jdk found
20959  fi
20960
20961  fi
20962
20963
20964    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20965    if test "x$BOOT_JDK_FOUND" = xmaybe; then
20966      # Do we have a bin/java?
20967      if test ! -x "$BOOT_JDK/bin/java"; then
20968        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20969$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20970        BOOT_JDK_FOUND=no
20971      else
20972        # Do we have a bin/javac?
20973        if test ! -x "$BOOT_JDK/bin/javac"; then
20974          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20975$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20976          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20977$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20978          BOOT_JDK_FOUND=no
20979        else
20980          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20981          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20982            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20983$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20984            BOOT_JDK_FOUND=no
20985          else
20986            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20987            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20988
20989            # Extra M4 quote needed to protect [] in grep expression.
20990            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20991            if test "x$FOUND_CORRECT_VERSION" = x; then
20992              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20993$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20994              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20995$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20996              BOOT_JDK_FOUND=no
20997            else
20998              # We're done! :-)
20999              BOOT_JDK_FOUND=yes
21000
21001  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21002
21003  # Input might be given as Windows format, start by converting to
21004  # unix format.
21005  path="$BOOT_JDK"
21006  new_path=`$CYGPATH -u "$path"`
21007
21008  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21009  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21010  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21011  # "foo.exe" is OK but "foo" is an error.
21012  #
21013  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21014  # It is also a way to make sure we got the proper file name for the real test later on.
21015  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21016  if test "x$test_shortpath" = x; then
21017    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21018$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21019    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21020  fi
21021
21022  # Call helper function which possibly converts this using DOS-style short mode.
21023  # If so, the updated path is stored in $new_path.
21024
21025  input_path="$new_path"
21026  # Check if we need to convert this using DOS-style short mode. If the path
21027  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21028  # take no chances and rewrite it.
21029  # Note: m4 eats our [], so we need to use [ and ] instead.
21030  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21031  if test "x$has_forbidden_chars" != x; then
21032    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21033    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21034    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21035    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21036      # Going to short mode and back again did indeed matter. Since short mode is
21037      # case insensitive, let's make it lowercase to improve readability.
21038      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21039      # Now convert it back to Unix-stile (cygpath)
21040      input_path=`$CYGPATH -u "$shortmode_path"`
21041      new_path="$input_path"
21042    fi
21043  fi
21044
21045  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21046  if test "x$test_cygdrive_prefix" = x; then
21047    # As a simple fix, exclude /usr/bin since it's not a real path.
21048    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21049      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21050      # a path prefixed by /cygdrive for fixpath to work.
21051      new_path="$CYGWIN_ROOT_PATH$input_path"
21052    fi
21053  fi
21054
21055
21056  if test "x$path" != "x$new_path"; then
21057    BOOT_JDK="$new_path"
21058    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21059$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21060  fi
21061
21062  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21063
21064  path="$BOOT_JDK"
21065  has_colon=`$ECHO $path | $GREP ^.:`
21066  new_path="$path"
21067  if test "x$has_colon" = x; then
21068    # Not in mixed or Windows style, start by that.
21069    new_path=`cmd //c echo $path`
21070  fi
21071
21072
21073  input_path="$new_path"
21074  # Check if we need to convert this using DOS-style short mode. If the path
21075  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21076  # take no chances and rewrite it.
21077  # Note: m4 eats our [], so we need to use [ and ] instead.
21078  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21079  if test "x$has_forbidden_chars" != x; then
21080    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21081    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21082  fi
21083
21084
21085  windows_path="$new_path"
21086  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21087    unix_path=`$CYGPATH -u "$windows_path"`
21088    new_path="$unix_path"
21089  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21090    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21091    new_path="$unix_path"
21092  fi
21093
21094  if test "x$path" != "x$new_path"; then
21095    BOOT_JDK="$new_path"
21096    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21097$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21098  fi
21099
21100  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21101  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21102
21103  else
21104    # We're on a posix platform. Hooray! :)
21105    path="$BOOT_JDK"
21106    has_space=`$ECHO "$path" | $GREP " "`
21107    if test "x$has_space" != x; then
21108      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21109$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21110      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21111    fi
21112
21113    # Use eval to expand a potential ~
21114    eval path="$path"
21115    if test ! -f "$path" && test ! -d "$path"; then
21116      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21117    fi
21118
21119    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21120  fi
21121
21122              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21123$as_echo_n "checking for Boot JDK... " >&6; }
21124              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21125$as_echo "$BOOT_JDK" >&6; }
21126              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21127$as_echo_n "checking Boot JDK version... " >&6; }
21128              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21129              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21130$as_echo "$BOOT_JDK_VERSION" >&6; }
21131            fi # end check jdk version
21132          fi # end check rt.jar
21133        fi # end check javac
21134      fi # end check java
21135    fi # end check boot jdk found
21136  fi
21137
21138
21139  # Test: Is $JAVA_HOME set?
21140
21141  if test "x$BOOT_JDK_FOUND" = xno; then
21142    # Now execute the test
21143
21144  if test "x$JAVA_HOME" != x; then
21145    JAVA_HOME_PROCESSED="$JAVA_HOME"
21146
21147  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21148
21149  # Input might be given as Windows format, start by converting to
21150  # unix format.
21151  path="$JAVA_HOME_PROCESSED"
21152  new_path=`$CYGPATH -u "$path"`
21153
21154  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21155  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21156  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21157  # "foo.exe" is OK but "foo" is an error.
21158  #
21159  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21160  # It is also a way to make sure we got the proper file name for the real test later on.
21161  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21162  if test "x$test_shortpath" = x; then
21163    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21164$as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21165    as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5
21166  fi
21167
21168  # Call helper function which possibly converts this using DOS-style short mode.
21169  # If so, the updated path is stored in $new_path.
21170
21171  input_path="$new_path"
21172  # Check if we need to convert this using DOS-style short mode. If the path
21173  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21174  # take no chances and rewrite it.
21175  # Note: m4 eats our [], so we need to use [ and ] instead.
21176  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21177  if test "x$has_forbidden_chars" != x; then
21178    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21179    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21180    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21181    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21182      # Going to short mode and back again did indeed matter. Since short mode is
21183      # case insensitive, let's make it lowercase to improve readability.
21184      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21185      # Now convert it back to Unix-stile (cygpath)
21186      input_path=`$CYGPATH -u "$shortmode_path"`
21187      new_path="$input_path"
21188    fi
21189  fi
21190
21191  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21192  if test "x$test_cygdrive_prefix" = x; then
21193    # As a simple fix, exclude /usr/bin since it's not a real path.
21194    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21195      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21196      # a path prefixed by /cygdrive for fixpath to work.
21197      new_path="$CYGWIN_ROOT_PATH$input_path"
21198    fi
21199  fi
21200
21201
21202  if test "x$path" != "x$new_path"; then
21203    JAVA_HOME_PROCESSED="$new_path"
21204    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21205$as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21206  fi
21207
21208  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21209
21210  path="$JAVA_HOME_PROCESSED"
21211  has_colon=`$ECHO $path | $GREP ^.:`
21212  new_path="$path"
21213  if test "x$has_colon" = x; then
21214    # Not in mixed or Windows style, start by that.
21215    new_path=`cmd //c echo $path`
21216  fi
21217
21218
21219  input_path="$new_path"
21220  # Check if we need to convert this using DOS-style short mode. If the path
21221  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21222  # take no chances and rewrite it.
21223  # Note: m4 eats our [], so we need to use [ and ] instead.
21224  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21225  if test "x$has_forbidden_chars" != x; then
21226    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21227    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21228  fi
21229
21230
21231  windows_path="$new_path"
21232  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21233    unix_path=`$CYGPATH -u "$windows_path"`
21234    new_path="$unix_path"
21235  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21236    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21237    new_path="$unix_path"
21238  fi
21239
21240  if test "x$path" != "x$new_path"; then
21241    JAVA_HOME_PROCESSED="$new_path"
21242    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21243$as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21244  fi
21245
21246  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21247  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21248
21249  else
21250    # We're on a posix platform. Hooray! :)
21251    path="$JAVA_HOME_PROCESSED"
21252    has_space=`$ECHO "$path" | $GREP " "`
21253    if test "x$has_space" != x; then
21254      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21255$as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21256      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21257    fi
21258
21259    # Use eval to expand a potential ~
21260    eval path="$path"
21261    if test ! -f "$path" && test ! -d "$path"; then
21262      as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5
21263    fi
21264
21265    JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`"
21266  fi
21267
21268    if test ! -d "$JAVA_HOME_PROCESSED"; then
21269      { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5
21270$as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;}
21271    else
21272      # Aha, the user has set a JAVA_HOME
21273      # let us use that as the Boot JDK.
21274      BOOT_JDK="$JAVA_HOME_PROCESSED"
21275      BOOT_JDK_FOUND=maybe
21276      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5
21277$as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;}
21278    fi
21279  fi
21280
21281
21282    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21283    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21284      # Do we have a bin/java?
21285      if test ! -x "$BOOT_JDK/bin/java"; then
21286        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21287$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21288        BOOT_JDK_FOUND=no
21289      else
21290        # Do we have a bin/javac?
21291        if test ! -x "$BOOT_JDK/bin/javac"; then
21292          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21293$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21294          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21295$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21296          BOOT_JDK_FOUND=no
21297        else
21298          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21299          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21300            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21301$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21302            BOOT_JDK_FOUND=no
21303          else
21304            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21305            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21306
21307            # Extra M4 quote needed to protect [] in grep expression.
21308            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21309            if test "x$FOUND_CORRECT_VERSION" = x; then
21310              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21311$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21312              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21313$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21314              BOOT_JDK_FOUND=no
21315            else
21316              # We're done! :-)
21317              BOOT_JDK_FOUND=yes
21318
21319  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21320
21321  # Input might be given as Windows format, start by converting to
21322  # unix format.
21323  path="$BOOT_JDK"
21324  new_path=`$CYGPATH -u "$path"`
21325
21326  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21327  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21328  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21329  # "foo.exe" is OK but "foo" is an error.
21330  #
21331  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21332  # It is also a way to make sure we got the proper file name for the real test later on.
21333  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21334  if test "x$test_shortpath" = x; then
21335    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21336$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21337    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21338  fi
21339
21340  # Call helper function which possibly converts this using DOS-style short mode.
21341  # If so, the updated path is stored in $new_path.
21342
21343  input_path="$new_path"
21344  # Check if we need to convert this using DOS-style short mode. If the path
21345  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21346  # take no chances and rewrite it.
21347  # Note: m4 eats our [], so we need to use [ and ] instead.
21348  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21349  if test "x$has_forbidden_chars" != x; then
21350    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21351    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21352    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21353    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21354      # Going to short mode and back again did indeed matter. Since short mode is
21355      # case insensitive, let's make it lowercase to improve readability.
21356      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21357      # Now convert it back to Unix-stile (cygpath)
21358      input_path=`$CYGPATH -u "$shortmode_path"`
21359      new_path="$input_path"
21360    fi
21361  fi
21362
21363  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21364  if test "x$test_cygdrive_prefix" = x; then
21365    # As a simple fix, exclude /usr/bin since it's not a real path.
21366    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21367      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21368      # a path prefixed by /cygdrive for fixpath to work.
21369      new_path="$CYGWIN_ROOT_PATH$input_path"
21370    fi
21371  fi
21372
21373
21374  if test "x$path" != "x$new_path"; then
21375    BOOT_JDK="$new_path"
21376    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21377$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21378  fi
21379
21380  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21381
21382  path="$BOOT_JDK"
21383  has_colon=`$ECHO $path | $GREP ^.:`
21384  new_path="$path"
21385  if test "x$has_colon" = x; then
21386    # Not in mixed or Windows style, start by that.
21387    new_path=`cmd //c echo $path`
21388  fi
21389
21390
21391  input_path="$new_path"
21392  # Check if we need to convert this using DOS-style short mode. If the path
21393  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21394  # take no chances and rewrite it.
21395  # Note: m4 eats our [], so we need to use [ and ] instead.
21396  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21397  if test "x$has_forbidden_chars" != x; then
21398    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21399    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21400  fi
21401
21402
21403  windows_path="$new_path"
21404  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21405    unix_path=`$CYGPATH -u "$windows_path"`
21406    new_path="$unix_path"
21407  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21408    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21409    new_path="$unix_path"
21410  fi
21411
21412  if test "x$path" != "x$new_path"; then
21413    BOOT_JDK="$new_path"
21414    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21415$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21416  fi
21417
21418  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21419  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21420
21421  else
21422    # We're on a posix platform. Hooray! :)
21423    path="$BOOT_JDK"
21424    has_space=`$ECHO "$path" | $GREP " "`
21425    if test "x$has_space" != x; then
21426      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21427$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21428      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21429    fi
21430
21431    # Use eval to expand a potential ~
21432    eval path="$path"
21433    if test ! -f "$path" && test ! -d "$path"; then
21434      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21435    fi
21436
21437    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21438  fi
21439
21440              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21441$as_echo_n "checking for Boot JDK... " >&6; }
21442              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21443$as_echo "$BOOT_JDK" >&6; }
21444              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21445$as_echo_n "checking Boot JDK version... " >&6; }
21446              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21447              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21448$as_echo "$BOOT_JDK_VERSION" >&6; }
21449            fi # end check jdk version
21450          fi # end check rt.jar
21451        fi # end check javac
21452      fi # end check java
21453    fi # end check boot jdk found
21454  fi
21455
21456
21457  # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
21458
21459  if test "x$BOOT_JDK_FOUND" = xno; then
21460    # Now execute the test
21461
21462  # Extract the first word of "javac", so it can be a program name with args.
21463set dummy javac; ac_word=$2
21464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21465$as_echo_n "checking for $ac_word... " >&6; }
21466if ${ac_cv_path_JAVAC_CHECK+:} false; then :
21467  $as_echo_n "(cached) " >&6
21468else
21469  case $JAVAC_CHECK in
21470  [\\/]* | ?:[\\/]*)
21471  ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path.
21472  ;;
21473  *)
21474  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21475for as_dir in $PATH
21476do
21477  IFS=$as_save_IFS
21478  test -z "$as_dir" && as_dir=.
21479    for ac_exec_ext in '' $ac_executable_extensions; do
21480  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21481    ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext"
21482    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21483    break 2
21484  fi
21485done
21486  done
21487IFS=$as_save_IFS
21488
21489  ;;
21490esac
21491fi
21492JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK
21493if test -n "$JAVAC_CHECK"; then
21494  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5
21495$as_echo "$JAVAC_CHECK" >&6; }
21496else
21497  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21498$as_echo "no" >&6; }
21499fi
21500
21501
21502  # Extract the first word of "java", so it can be a program name with args.
21503set dummy java; ac_word=$2
21504{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21505$as_echo_n "checking for $ac_word... " >&6; }
21506if ${ac_cv_path_JAVA_CHECK+:} false; then :
21507  $as_echo_n "(cached) " >&6
21508else
21509  case $JAVA_CHECK in
21510  [\\/]* | ?:[\\/]*)
21511  ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path.
21512  ;;
21513  *)
21514  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21515for as_dir in $PATH
21516do
21517  IFS=$as_save_IFS
21518  test -z "$as_dir" && as_dir=.
21519    for ac_exec_ext in '' $ac_executable_extensions; do
21520  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21521    ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext"
21522    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21523    break 2
21524  fi
21525done
21526  done
21527IFS=$as_save_IFS
21528
21529  ;;
21530esac
21531fi
21532JAVA_CHECK=$ac_cv_path_JAVA_CHECK
21533if test -n "$JAVA_CHECK"; then
21534  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5
21535$as_echo "$JAVA_CHECK" >&6; }
21536else
21537  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21538$as_echo "no" >&6; }
21539fi
21540
21541
21542  BINARY="$JAVAC_CHECK"
21543  if test "x$JAVAC_CHECK" = x; then
21544    BINARY="$JAVA_CHECK"
21545  fi
21546  if test "x$BINARY" != x; then
21547    # So there is a java(c) binary, it might be part of a JDK.
21548    # Lets find the JDK/JRE directory by following symbolic links.
21549    # Linux/GNU systems often have links from /usr/bin/java to
21550    # /etc/alternatives/java to the real JDK binary.
21551
21552  if test "x$OPENJDK_BUILD_OS" != xwindows; then
21553    # Follow a chain of symbolic links. Use readlink
21554    # where it exists, else fall back to horribly
21555    # complicated shell code.
21556    if test "x$READLINK_TESTED" != yes; then
21557      # On MacOSX there is a readlink tool with a different
21558      # purpose than the GNU readlink tool. Check the found readlink.
21559      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
21560      if test "x$ISGNU" = x; then
21561        # A readlink that we do not know how to use.
21562        # Are there other non-GNU readlinks out there?
21563        READLINK_TESTED=yes
21564        READLINK=
21565      fi
21566    fi
21567
21568    if test "x$READLINK" != x; then
21569      BINARY=`$READLINK -f $BINARY`
21570    else
21571      # Save the current directory for restoring afterwards
21572      STARTDIR=$PWD
21573      COUNTER=0
21574      sym_link_dir=`$DIRNAME $BINARY`
21575      sym_link_file=`$BASENAME $BINARY`
21576      cd $sym_link_dir
21577      # Use -P flag to resolve symlinks in directories.
21578      cd `$THEPWDCMD -P`
21579      sym_link_dir=`$THEPWDCMD -P`
21580      # Resolve file symlinks
21581      while test $COUNTER -lt 20; do
21582        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
21583        if test "x$ISLINK" == x; then
21584          # This is not a symbolic link! We are done!
21585          break
21586        fi
21587        # Again resolve directory symlinks since the target of the just found
21588        # link could be in a different directory
21589        cd `$DIRNAME $ISLINK`
21590        sym_link_dir=`$THEPWDCMD -P`
21591        sym_link_file=`$BASENAME $ISLINK`
21592        let COUNTER=COUNTER+1
21593      done
21594      cd $STARTDIR
21595      BINARY=$sym_link_dir/$sym_link_file
21596    fi
21597  fi
21598
21599    BOOT_JDK=`dirname "$BINARY"`
21600    BOOT_JDK=`cd "$BOOT_JDK/.."; pwd`
21601    if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then
21602      # Looks like we found ourselves an JDK
21603      BOOT_JDK_FOUND=maybe
21604      { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5
21605$as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;}
21606    fi
21607  fi
21608
21609
21610    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21611    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21612      # Do we have a bin/java?
21613      if test ! -x "$BOOT_JDK/bin/java"; then
21614        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21615$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21616        BOOT_JDK_FOUND=no
21617      else
21618        # Do we have a bin/javac?
21619        if test ! -x "$BOOT_JDK/bin/javac"; then
21620          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21621$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21622          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21623$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21624          BOOT_JDK_FOUND=no
21625        else
21626          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21627          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21628            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21629$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21630            BOOT_JDK_FOUND=no
21631          else
21632            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21633            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21634
21635            # Extra M4 quote needed to protect [] in grep expression.
21636            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21637            if test "x$FOUND_CORRECT_VERSION" = x; then
21638              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21639$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21640              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21641$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21642              BOOT_JDK_FOUND=no
21643            else
21644              # We're done! :-)
21645              BOOT_JDK_FOUND=yes
21646
21647  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21648
21649  # Input might be given as Windows format, start by converting to
21650  # unix format.
21651  path="$BOOT_JDK"
21652  new_path=`$CYGPATH -u "$path"`
21653
21654  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21655  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21656  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21657  # "foo.exe" is OK but "foo" is an error.
21658  #
21659  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21660  # It is also a way to make sure we got the proper file name for the real test later on.
21661  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21662  if test "x$test_shortpath" = x; then
21663    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21664$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21665    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21666  fi
21667
21668  # Call helper function which possibly converts this using DOS-style short mode.
21669  # If so, the updated path is stored in $new_path.
21670
21671  input_path="$new_path"
21672  # Check if we need to convert this using DOS-style short mode. If the path
21673  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21674  # take no chances and rewrite it.
21675  # Note: m4 eats our [], so we need to use [ and ] instead.
21676  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21677  if test "x$has_forbidden_chars" != x; then
21678    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21679    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21680    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21681    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21682      # Going to short mode and back again did indeed matter. Since short mode is
21683      # case insensitive, let's make it lowercase to improve readability.
21684      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21685      # Now convert it back to Unix-stile (cygpath)
21686      input_path=`$CYGPATH -u "$shortmode_path"`
21687      new_path="$input_path"
21688    fi
21689  fi
21690
21691  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21692  if test "x$test_cygdrive_prefix" = x; then
21693    # As a simple fix, exclude /usr/bin since it's not a real path.
21694    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21695      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21696      # a path prefixed by /cygdrive for fixpath to work.
21697      new_path="$CYGWIN_ROOT_PATH$input_path"
21698    fi
21699  fi
21700
21701
21702  if test "x$path" != "x$new_path"; then
21703    BOOT_JDK="$new_path"
21704    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21705$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21706  fi
21707
21708  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21709
21710  path="$BOOT_JDK"
21711  has_colon=`$ECHO $path | $GREP ^.:`
21712  new_path="$path"
21713  if test "x$has_colon" = x; then
21714    # Not in mixed or Windows style, start by that.
21715    new_path=`cmd //c echo $path`
21716  fi
21717
21718
21719  input_path="$new_path"
21720  # Check if we need to convert this using DOS-style short mode. If the path
21721  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21722  # take no chances and rewrite it.
21723  # Note: m4 eats our [], so we need to use [ and ] instead.
21724  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21725  if test "x$has_forbidden_chars" != x; then
21726    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21727    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21728  fi
21729
21730
21731  windows_path="$new_path"
21732  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21733    unix_path=`$CYGPATH -u "$windows_path"`
21734    new_path="$unix_path"
21735  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21736    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21737    new_path="$unix_path"
21738  fi
21739
21740  if test "x$path" != "x$new_path"; then
21741    BOOT_JDK="$new_path"
21742    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21743$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21744  fi
21745
21746  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21747  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21748
21749  else
21750    # We're on a posix platform. Hooray! :)
21751    path="$BOOT_JDK"
21752    has_space=`$ECHO "$path" | $GREP " "`
21753    if test "x$has_space" != x; then
21754      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21755$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21756      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21757    fi
21758
21759    # Use eval to expand a potential ~
21760    eval path="$path"
21761    if test ! -f "$path" && test ! -d "$path"; then
21762      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21763    fi
21764
21765    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21766  fi
21767
21768              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21769$as_echo_n "checking for Boot JDK... " >&6; }
21770              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21771$as_echo "$BOOT_JDK" >&6; }
21772              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21773$as_echo_n "checking Boot JDK version... " >&6; }
21774              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21775              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21776$as_echo "$BOOT_JDK_VERSION" >&6; }
21777            fi # end check jdk version
21778          fi # end check rt.jar
21779        fi # end check javac
21780      fi # end check java
21781    fi # end check boot jdk found
21782  fi
21783
21784
21785  # Test: Is there a JDK installed in default, well-known locations?
21786
21787  if test "x$BOOT_JDK_FOUND" = xno; then
21788    # Now execute the test
21789
21790  if test "x$OPENJDK_TARGET_OS" = xwindows; then
21791
21792  if test "x$BOOT_JDK_FOUND" = xno; then
21793    # Now execute the test
21794
21795  if test "x$ProgramW6432" != x; then
21796    VIRTUAL_DIR="$ProgramW6432/Java"
21797
21798  windows_path="$VIRTUAL_DIR"
21799  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21800    unix_path=`$CYGPATH -u "$windows_path"`
21801    VIRTUAL_DIR="$unix_path"
21802  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21803    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21804    VIRTUAL_DIR="$unix_path"
21805  fi
21806
21807
21808  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
21809  BOOT_JDK_SUFFIX=""
21810  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
21811  if test "x$ALL_JDKS_FOUND" != x; then
21812    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
21813
21814  if test "x$BOOT_JDK_FOUND" = xno; then
21815    # Now execute the test
21816
21817        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
21818        if test -d "$BOOT_JDK"; then
21819          BOOT_JDK_FOUND=maybe
21820          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
21821$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
21822        fi
21823
21824
21825    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21826    if test "x$BOOT_JDK_FOUND" = xmaybe; then
21827      # Do we have a bin/java?
21828      if test ! -x "$BOOT_JDK/bin/java"; then
21829        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21830$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21831        BOOT_JDK_FOUND=no
21832      else
21833        # Do we have a bin/javac?
21834        if test ! -x "$BOOT_JDK/bin/javac"; then
21835          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21836$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21837          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21838$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21839          BOOT_JDK_FOUND=no
21840        else
21841          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21842          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21843            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21844$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21845            BOOT_JDK_FOUND=no
21846          else
21847            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21848            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21849
21850            # Extra M4 quote needed to protect [] in grep expression.
21851            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21852            if test "x$FOUND_CORRECT_VERSION" = x; then
21853              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21854$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21855              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21856$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21857              BOOT_JDK_FOUND=no
21858            else
21859              # We're done! :-)
21860              BOOT_JDK_FOUND=yes
21861
21862  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21863
21864  # Input might be given as Windows format, start by converting to
21865  # unix format.
21866  path="$BOOT_JDK"
21867  new_path=`$CYGPATH -u "$path"`
21868
21869  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21870  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21871  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21872  # "foo.exe" is OK but "foo" is an error.
21873  #
21874  # This test is therefore slightly more accurate than "test -f" to check for file precense.
21875  # It is also a way to make sure we got the proper file name for the real test later on.
21876  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21877  if test "x$test_shortpath" = x; then
21878    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21879$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21880    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21881  fi
21882
21883  # Call helper function which possibly converts this using DOS-style short mode.
21884  # If so, the updated path is stored in $new_path.
21885
21886  input_path="$new_path"
21887  # Check if we need to convert this using DOS-style short mode. If the path
21888  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21889  # take no chances and rewrite it.
21890  # Note: m4 eats our [], so we need to use [ and ] instead.
21891  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21892  if test "x$has_forbidden_chars" != x; then
21893    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21894    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21895    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21896    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21897      # Going to short mode and back again did indeed matter. Since short mode is
21898      # case insensitive, let's make it lowercase to improve readability.
21899      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21900      # Now convert it back to Unix-stile (cygpath)
21901      input_path=`$CYGPATH -u "$shortmode_path"`
21902      new_path="$input_path"
21903    fi
21904  fi
21905
21906  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21907  if test "x$test_cygdrive_prefix" = x; then
21908    # As a simple fix, exclude /usr/bin since it's not a real path.
21909    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21910      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21911      # a path prefixed by /cygdrive for fixpath to work.
21912      new_path="$CYGWIN_ROOT_PATH$input_path"
21913    fi
21914  fi
21915
21916
21917  if test "x$path" != "x$new_path"; then
21918    BOOT_JDK="$new_path"
21919    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21920$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21921  fi
21922
21923  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21924
21925  path="$BOOT_JDK"
21926  has_colon=`$ECHO $path | $GREP ^.:`
21927  new_path="$path"
21928  if test "x$has_colon" = x; then
21929    # Not in mixed or Windows style, start by that.
21930    new_path=`cmd //c echo $path`
21931  fi
21932
21933
21934  input_path="$new_path"
21935  # Check if we need to convert this using DOS-style short mode. If the path
21936  # contains just simple characters, use it. Otherwise (spaces, weird characters),
21937  # take no chances and rewrite it.
21938  # Note: m4 eats our [], so we need to use [ and ] instead.
21939  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21940  if test "x$has_forbidden_chars" != x; then
21941    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21942    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21943  fi
21944
21945
21946  windows_path="$new_path"
21947  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21948    unix_path=`$CYGPATH -u "$windows_path"`
21949    new_path="$unix_path"
21950  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21951    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21952    new_path="$unix_path"
21953  fi
21954
21955  if test "x$path" != "x$new_path"; then
21956    BOOT_JDK="$new_path"
21957    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21958$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21959  fi
21960
21961  # Save the first 10 bytes of this path to the storage, so fixpath can work.
21962  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21963
21964  else
21965    # We're on a posix platform. Hooray! :)
21966    path="$BOOT_JDK"
21967    has_space=`$ECHO "$path" | $GREP " "`
21968    if test "x$has_space" != x; then
21969      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21970$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21971      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21972    fi
21973
21974    # Use eval to expand a potential ~
21975    eval path="$path"
21976    if test ! -f "$path" && test ! -d "$path"; then
21977      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21978    fi
21979
21980    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21981  fi
21982
21983              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21984$as_echo_n "checking for Boot JDK... " >&6; }
21985              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21986$as_echo "$BOOT_JDK" >&6; }
21987              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21988$as_echo_n "checking Boot JDK version... " >&6; }
21989              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21990              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21991$as_echo "$BOOT_JDK_VERSION" >&6; }
21992            fi # end check jdk version
21993          fi # end check rt.jar
21994        fi # end check javac
21995      fi # end check java
21996    fi # end check boot jdk found
21997  fi
21998
21999    done
22000  fi
22001
22002  fi
22003
22004
22005    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22006    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22007      # Do we have a bin/java?
22008      if test ! -x "$BOOT_JDK/bin/java"; then
22009        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22010$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22011        BOOT_JDK_FOUND=no
22012      else
22013        # Do we have a bin/javac?
22014        if test ! -x "$BOOT_JDK/bin/javac"; then
22015          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22016$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22017          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22018$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22019          BOOT_JDK_FOUND=no
22020        else
22021          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22022          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22023            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22024$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22025            BOOT_JDK_FOUND=no
22026          else
22027            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22028            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22029
22030            # Extra M4 quote needed to protect [] in grep expression.
22031            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22032            if test "x$FOUND_CORRECT_VERSION" = x; then
22033              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22034$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22035              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22036$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22037              BOOT_JDK_FOUND=no
22038            else
22039              # We're done! :-)
22040              BOOT_JDK_FOUND=yes
22041
22042  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22043
22044  # Input might be given as Windows format, start by converting to
22045  # unix format.
22046  path="$BOOT_JDK"
22047  new_path=`$CYGPATH -u "$path"`
22048
22049  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22050  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22051  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22052  # "foo.exe" is OK but "foo" is an error.
22053  #
22054  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22055  # It is also a way to make sure we got the proper file name for the real test later on.
22056  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22057  if test "x$test_shortpath" = x; then
22058    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22059$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22060    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22061  fi
22062
22063  # Call helper function which possibly converts this using DOS-style short mode.
22064  # If so, the updated path is stored in $new_path.
22065
22066  input_path="$new_path"
22067  # Check if we need to convert this using DOS-style short mode. If the path
22068  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22069  # take no chances and rewrite it.
22070  # Note: m4 eats our [], so we need to use [ and ] instead.
22071  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22072  if test "x$has_forbidden_chars" != x; then
22073    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22074    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22075    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22076    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22077      # Going to short mode and back again did indeed matter. Since short mode is
22078      # case insensitive, let's make it lowercase to improve readability.
22079      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22080      # Now convert it back to Unix-stile (cygpath)
22081      input_path=`$CYGPATH -u "$shortmode_path"`
22082      new_path="$input_path"
22083    fi
22084  fi
22085
22086  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22087  if test "x$test_cygdrive_prefix" = x; then
22088    # As a simple fix, exclude /usr/bin since it's not a real path.
22089    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22090      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22091      # a path prefixed by /cygdrive for fixpath to work.
22092      new_path="$CYGWIN_ROOT_PATH$input_path"
22093    fi
22094  fi
22095
22096
22097  if test "x$path" != "x$new_path"; then
22098    BOOT_JDK="$new_path"
22099    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22100$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22101  fi
22102
22103  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22104
22105  path="$BOOT_JDK"
22106  has_colon=`$ECHO $path | $GREP ^.:`
22107  new_path="$path"
22108  if test "x$has_colon" = x; then
22109    # Not in mixed or Windows style, start by that.
22110    new_path=`cmd //c echo $path`
22111  fi
22112
22113
22114  input_path="$new_path"
22115  # Check if we need to convert this using DOS-style short mode. If the path
22116  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22117  # take no chances and rewrite it.
22118  # Note: m4 eats our [], so we need to use [ and ] instead.
22119  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22120  if test "x$has_forbidden_chars" != x; then
22121    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22122    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22123  fi
22124
22125
22126  windows_path="$new_path"
22127  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22128    unix_path=`$CYGPATH -u "$windows_path"`
22129    new_path="$unix_path"
22130  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22131    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22132    new_path="$unix_path"
22133  fi
22134
22135  if test "x$path" != "x$new_path"; then
22136    BOOT_JDK="$new_path"
22137    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22138$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22139  fi
22140
22141  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22142  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22143
22144  else
22145    # We're on a posix platform. Hooray! :)
22146    path="$BOOT_JDK"
22147    has_space=`$ECHO "$path" | $GREP " "`
22148    if test "x$has_space" != x; then
22149      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22150$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22151      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22152    fi
22153
22154    # Use eval to expand a potential ~
22155    eval path="$path"
22156    if test ! -f "$path" && test ! -d "$path"; then
22157      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22158    fi
22159
22160    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22161  fi
22162
22163              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22164$as_echo_n "checking for Boot JDK... " >&6; }
22165              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22166$as_echo "$BOOT_JDK" >&6; }
22167              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22168$as_echo_n "checking Boot JDK version... " >&6; }
22169              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22170              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22171$as_echo "$BOOT_JDK_VERSION" >&6; }
22172            fi # end check jdk version
22173          fi # end check rt.jar
22174        fi # end check javac
22175      fi # end check java
22176    fi # end check boot jdk found
22177  fi
22178
22179
22180  if test "x$BOOT_JDK_FOUND" = xno; then
22181    # Now execute the test
22182
22183  if test "x$PROGRAMW6432" != x; then
22184    VIRTUAL_DIR="$PROGRAMW6432/Java"
22185
22186  windows_path="$VIRTUAL_DIR"
22187  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22188    unix_path=`$CYGPATH -u "$windows_path"`
22189    VIRTUAL_DIR="$unix_path"
22190  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22191    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22192    VIRTUAL_DIR="$unix_path"
22193  fi
22194
22195
22196  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22197  BOOT_JDK_SUFFIX=""
22198  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22199  if test "x$ALL_JDKS_FOUND" != x; then
22200    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22201
22202  if test "x$BOOT_JDK_FOUND" = xno; then
22203    # Now execute the test
22204
22205        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22206        if test -d "$BOOT_JDK"; then
22207          BOOT_JDK_FOUND=maybe
22208          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22209$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22210        fi
22211
22212
22213    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22214    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22215      # Do we have a bin/java?
22216      if test ! -x "$BOOT_JDK/bin/java"; then
22217        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22218$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22219        BOOT_JDK_FOUND=no
22220      else
22221        # Do we have a bin/javac?
22222        if test ! -x "$BOOT_JDK/bin/javac"; then
22223          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22224$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22225          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22226$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22227          BOOT_JDK_FOUND=no
22228        else
22229          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22230          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22231            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22232$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22233            BOOT_JDK_FOUND=no
22234          else
22235            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22236            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22237
22238            # Extra M4 quote needed to protect [] in grep expression.
22239            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22240            if test "x$FOUND_CORRECT_VERSION" = x; then
22241              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22242$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22243              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22244$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22245              BOOT_JDK_FOUND=no
22246            else
22247              # We're done! :-)
22248              BOOT_JDK_FOUND=yes
22249
22250  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22251
22252  # Input might be given as Windows format, start by converting to
22253  # unix format.
22254  path="$BOOT_JDK"
22255  new_path=`$CYGPATH -u "$path"`
22256
22257  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22258  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22259  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22260  # "foo.exe" is OK but "foo" is an error.
22261  #
22262  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22263  # It is also a way to make sure we got the proper file name for the real test later on.
22264  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22265  if test "x$test_shortpath" = x; then
22266    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22267$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22268    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22269  fi
22270
22271  # Call helper function which possibly converts this using DOS-style short mode.
22272  # If so, the updated path is stored in $new_path.
22273
22274  input_path="$new_path"
22275  # Check if we need to convert this using DOS-style short mode. If the path
22276  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22277  # take no chances and rewrite it.
22278  # Note: m4 eats our [], so we need to use [ and ] instead.
22279  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22280  if test "x$has_forbidden_chars" != x; then
22281    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22282    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22283    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22284    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22285      # Going to short mode and back again did indeed matter. Since short mode is
22286      # case insensitive, let's make it lowercase to improve readability.
22287      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22288      # Now convert it back to Unix-stile (cygpath)
22289      input_path=`$CYGPATH -u "$shortmode_path"`
22290      new_path="$input_path"
22291    fi
22292  fi
22293
22294  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22295  if test "x$test_cygdrive_prefix" = x; then
22296    # As a simple fix, exclude /usr/bin since it's not a real path.
22297    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22298      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22299      # a path prefixed by /cygdrive for fixpath to work.
22300      new_path="$CYGWIN_ROOT_PATH$input_path"
22301    fi
22302  fi
22303
22304
22305  if test "x$path" != "x$new_path"; then
22306    BOOT_JDK="$new_path"
22307    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22308$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22309  fi
22310
22311  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22312
22313  path="$BOOT_JDK"
22314  has_colon=`$ECHO $path | $GREP ^.:`
22315  new_path="$path"
22316  if test "x$has_colon" = x; then
22317    # Not in mixed or Windows style, start by that.
22318    new_path=`cmd //c echo $path`
22319  fi
22320
22321
22322  input_path="$new_path"
22323  # Check if we need to convert this using DOS-style short mode. If the path
22324  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22325  # take no chances and rewrite it.
22326  # Note: m4 eats our [], so we need to use [ and ] instead.
22327  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22328  if test "x$has_forbidden_chars" != x; then
22329    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22330    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22331  fi
22332
22333
22334  windows_path="$new_path"
22335  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22336    unix_path=`$CYGPATH -u "$windows_path"`
22337    new_path="$unix_path"
22338  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22339    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22340    new_path="$unix_path"
22341  fi
22342
22343  if test "x$path" != "x$new_path"; then
22344    BOOT_JDK="$new_path"
22345    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22346$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22347  fi
22348
22349  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22350  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22351
22352  else
22353    # We're on a posix platform. Hooray! :)
22354    path="$BOOT_JDK"
22355    has_space=`$ECHO "$path" | $GREP " "`
22356    if test "x$has_space" != x; then
22357      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22358$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22359      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22360    fi
22361
22362    # Use eval to expand a potential ~
22363    eval path="$path"
22364    if test ! -f "$path" && test ! -d "$path"; then
22365      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22366    fi
22367
22368    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22369  fi
22370
22371              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22372$as_echo_n "checking for Boot JDK... " >&6; }
22373              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22374$as_echo "$BOOT_JDK" >&6; }
22375              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22376$as_echo_n "checking Boot JDK version... " >&6; }
22377              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22378              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22379$as_echo "$BOOT_JDK_VERSION" >&6; }
22380            fi # end check jdk version
22381          fi # end check rt.jar
22382        fi # end check javac
22383      fi # end check java
22384    fi # end check boot jdk found
22385  fi
22386
22387    done
22388  fi
22389
22390  fi
22391
22392
22393    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22394    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22395      # Do we have a bin/java?
22396      if test ! -x "$BOOT_JDK/bin/java"; then
22397        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22398$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22399        BOOT_JDK_FOUND=no
22400      else
22401        # Do we have a bin/javac?
22402        if test ! -x "$BOOT_JDK/bin/javac"; then
22403          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22404$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22405          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22406$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22407          BOOT_JDK_FOUND=no
22408        else
22409          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22410          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22411            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22412$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22413            BOOT_JDK_FOUND=no
22414          else
22415            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22416            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22417
22418            # Extra M4 quote needed to protect [] in grep expression.
22419            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22420            if test "x$FOUND_CORRECT_VERSION" = x; then
22421              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22422$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22423              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22424$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22425              BOOT_JDK_FOUND=no
22426            else
22427              # We're done! :-)
22428              BOOT_JDK_FOUND=yes
22429
22430  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22431
22432  # Input might be given as Windows format, start by converting to
22433  # unix format.
22434  path="$BOOT_JDK"
22435  new_path=`$CYGPATH -u "$path"`
22436
22437  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22438  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22439  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22440  # "foo.exe" is OK but "foo" is an error.
22441  #
22442  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22443  # It is also a way to make sure we got the proper file name for the real test later on.
22444  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22445  if test "x$test_shortpath" = x; then
22446    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22447$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22448    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22449  fi
22450
22451  # Call helper function which possibly converts this using DOS-style short mode.
22452  # If so, the updated path is stored in $new_path.
22453
22454  input_path="$new_path"
22455  # Check if we need to convert this using DOS-style short mode. If the path
22456  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22457  # take no chances and rewrite it.
22458  # Note: m4 eats our [], so we need to use [ and ] instead.
22459  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22460  if test "x$has_forbidden_chars" != x; then
22461    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22462    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22463    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22464    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22465      # Going to short mode and back again did indeed matter. Since short mode is
22466      # case insensitive, let's make it lowercase to improve readability.
22467      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22468      # Now convert it back to Unix-stile (cygpath)
22469      input_path=`$CYGPATH -u "$shortmode_path"`
22470      new_path="$input_path"
22471    fi
22472  fi
22473
22474  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22475  if test "x$test_cygdrive_prefix" = x; then
22476    # As a simple fix, exclude /usr/bin since it's not a real path.
22477    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22478      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22479      # a path prefixed by /cygdrive for fixpath to work.
22480      new_path="$CYGWIN_ROOT_PATH$input_path"
22481    fi
22482  fi
22483
22484
22485  if test "x$path" != "x$new_path"; then
22486    BOOT_JDK="$new_path"
22487    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22488$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22489  fi
22490
22491  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22492
22493  path="$BOOT_JDK"
22494  has_colon=`$ECHO $path | $GREP ^.:`
22495  new_path="$path"
22496  if test "x$has_colon" = x; then
22497    # Not in mixed or Windows style, start by that.
22498    new_path=`cmd //c echo $path`
22499  fi
22500
22501
22502  input_path="$new_path"
22503  # Check if we need to convert this using DOS-style short mode. If the path
22504  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22505  # take no chances and rewrite it.
22506  # Note: m4 eats our [], so we need to use [ and ] instead.
22507  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22508  if test "x$has_forbidden_chars" != x; then
22509    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22510    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22511  fi
22512
22513
22514  windows_path="$new_path"
22515  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22516    unix_path=`$CYGPATH -u "$windows_path"`
22517    new_path="$unix_path"
22518  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22519    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22520    new_path="$unix_path"
22521  fi
22522
22523  if test "x$path" != "x$new_path"; then
22524    BOOT_JDK="$new_path"
22525    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22526$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22527  fi
22528
22529  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22530  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22531
22532  else
22533    # We're on a posix platform. Hooray! :)
22534    path="$BOOT_JDK"
22535    has_space=`$ECHO "$path" | $GREP " "`
22536    if test "x$has_space" != x; then
22537      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22538$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22539      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22540    fi
22541
22542    # Use eval to expand a potential ~
22543    eval path="$path"
22544    if test ! -f "$path" && test ! -d "$path"; then
22545      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22546    fi
22547
22548    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22549  fi
22550
22551              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22552$as_echo_n "checking for Boot JDK... " >&6; }
22553              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22554$as_echo "$BOOT_JDK" >&6; }
22555              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22556$as_echo_n "checking Boot JDK version... " >&6; }
22557              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22558              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22559$as_echo "$BOOT_JDK_VERSION" >&6; }
22560            fi # end check jdk version
22561          fi # end check rt.jar
22562        fi # end check javac
22563      fi # end check java
22564    fi # end check boot jdk found
22565  fi
22566
22567
22568  if test "x$BOOT_JDK_FOUND" = xno; then
22569    # Now execute the test
22570
22571  if test "x$PROGRAMFILES" != x; then
22572    VIRTUAL_DIR="$PROGRAMFILES/Java"
22573
22574  windows_path="$VIRTUAL_DIR"
22575  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22576    unix_path=`$CYGPATH -u "$windows_path"`
22577    VIRTUAL_DIR="$unix_path"
22578  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22579    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22580    VIRTUAL_DIR="$unix_path"
22581  fi
22582
22583
22584  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22585  BOOT_JDK_SUFFIX=""
22586  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22587  if test "x$ALL_JDKS_FOUND" != x; then
22588    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22589
22590  if test "x$BOOT_JDK_FOUND" = xno; then
22591    # Now execute the test
22592
22593        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22594        if test -d "$BOOT_JDK"; then
22595          BOOT_JDK_FOUND=maybe
22596          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22597$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22598        fi
22599
22600
22601    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22602    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22603      # Do we have a bin/java?
22604      if test ! -x "$BOOT_JDK/bin/java"; then
22605        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22606$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22607        BOOT_JDK_FOUND=no
22608      else
22609        # Do we have a bin/javac?
22610        if test ! -x "$BOOT_JDK/bin/javac"; then
22611          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22612$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22613          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22614$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22615          BOOT_JDK_FOUND=no
22616        else
22617          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22618          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22619            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22620$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22621            BOOT_JDK_FOUND=no
22622          else
22623            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22624            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22625
22626            # Extra M4 quote needed to protect [] in grep expression.
22627            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22628            if test "x$FOUND_CORRECT_VERSION" = x; then
22629              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22630$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22631              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22632$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22633              BOOT_JDK_FOUND=no
22634            else
22635              # We're done! :-)
22636              BOOT_JDK_FOUND=yes
22637
22638  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22639
22640  # Input might be given as Windows format, start by converting to
22641  # unix format.
22642  path="$BOOT_JDK"
22643  new_path=`$CYGPATH -u "$path"`
22644
22645  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22646  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22647  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22648  # "foo.exe" is OK but "foo" is an error.
22649  #
22650  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22651  # It is also a way to make sure we got the proper file name for the real test later on.
22652  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22653  if test "x$test_shortpath" = x; then
22654    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22655$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22656    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22657  fi
22658
22659  # Call helper function which possibly converts this using DOS-style short mode.
22660  # If so, the updated path is stored in $new_path.
22661
22662  input_path="$new_path"
22663  # Check if we need to convert this using DOS-style short mode. If the path
22664  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22665  # take no chances and rewrite it.
22666  # Note: m4 eats our [], so we need to use [ and ] instead.
22667  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22668  if test "x$has_forbidden_chars" != x; then
22669    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22670    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22671    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22672    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22673      # Going to short mode and back again did indeed matter. Since short mode is
22674      # case insensitive, let's make it lowercase to improve readability.
22675      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22676      # Now convert it back to Unix-stile (cygpath)
22677      input_path=`$CYGPATH -u "$shortmode_path"`
22678      new_path="$input_path"
22679    fi
22680  fi
22681
22682  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22683  if test "x$test_cygdrive_prefix" = x; then
22684    # As a simple fix, exclude /usr/bin since it's not a real path.
22685    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22686      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22687      # a path prefixed by /cygdrive for fixpath to work.
22688      new_path="$CYGWIN_ROOT_PATH$input_path"
22689    fi
22690  fi
22691
22692
22693  if test "x$path" != "x$new_path"; then
22694    BOOT_JDK="$new_path"
22695    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22696$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22697  fi
22698
22699  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22700
22701  path="$BOOT_JDK"
22702  has_colon=`$ECHO $path | $GREP ^.:`
22703  new_path="$path"
22704  if test "x$has_colon" = x; then
22705    # Not in mixed or Windows style, start by that.
22706    new_path=`cmd //c echo $path`
22707  fi
22708
22709
22710  input_path="$new_path"
22711  # Check if we need to convert this using DOS-style short mode. If the path
22712  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22713  # take no chances and rewrite it.
22714  # Note: m4 eats our [], so we need to use [ and ] instead.
22715  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22716  if test "x$has_forbidden_chars" != x; then
22717    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22718    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22719  fi
22720
22721
22722  windows_path="$new_path"
22723  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22724    unix_path=`$CYGPATH -u "$windows_path"`
22725    new_path="$unix_path"
22726  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22727    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22728    new_path="$unix_path"
22729  fi
22730
22731  if test "x$path" != "x$new_path"; then
22732    BOOT_JDK="$new_path"
22733    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22734$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22735  fi
22736
22737  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22738  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22739
22740  else
22741    # We're on a posix platform. Hooray! :)
22742    path="$BOOT_JDK"
22743    has_space=`$ECHO "$path" | $GREP " "`
22744    if test "x$has_space" != x; then
22745      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22746$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22747      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22748    fi
22749
22750    # Use eval to expand a potential ~
22751    eval path="$path"
22752    if test ! -f "$path" && test ! -d "$path"; then
22753      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22754    fi
22755
22756    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22757  fi
22758
22759              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22760$as_echo_n "checking for Boot JDK... " >&6; }
22761              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22762$as_echo "$BOOT_JDK" >&6; }
22763              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22764$as_echo_n "checking Boot JDK version... " >&6; }
22765              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22766              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22767$as_echo "$BOOT_JDK_VERSION" >&6; }
22768            fi # end check jdk version
22769          fi # end check rt.jar
22770        fi # end check javac
22771      fi # end check java
22772    fi # end check boot jdk found
22773  fi
22774
22775    done
22776  fi
22777
22778  fi
22779
22780
22781    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22782    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22783      # Do we have a bin/java?
22784      if test ! -x "$BOOT_JDK/bin/java"; then
22785        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22786$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22787        BOOT_JDK_FOUND=no
22788      else
22789        # Do we have a bin/javac?
22790        if test ! -x "$BOOT_JDK/bin/javac"; then
22791          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22792$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22793          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22794$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22795          BOOT_JDK_FOUND=no
22796        else
22797          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22798          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22799            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22800$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22801            BOOT_JDK_FOUND=no
22802          else
22803            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22804            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22805
22806            # Extra M4 quote needed to protect [] in grep expression.
22807            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22808            if test "x$FOUND_CORRECT_VERSION" = x; then
22809              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22810$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22811              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22812$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22813              BOOT_JDK_FOUND=no
22814            else
22815              # We're done! :-)
22816              BOOT_JDK_FOUND=yes
22817
22818  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22819
22820  # Input might be given as Windows format, start by converting to
22821  # unix format.
22822  path="$BOOT_JDK"
22823  new_path=`$CYGPATH -u "$path"`
22824
22825  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22826  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22827  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22828  # "foo.exe" is OK but "foo" is an error.
22829  #
22830  # This test is therefore slightly more accurate than "test -f" to check for file precense.
22831  # It is also a way to make sure we got the proper file name for the real test later on.
22832  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22833  if test "x$test_shortpath" = x; then
22834    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22835$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22836    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22837  fi
22838
22839  # Call helper function which possibly converts this using DOS-style short mode.
22840  # If so, the updated path is stored in $new_path.
22841
22842  input_path="$new_path"
22843  # Check if we need to convert this using DOS-style short mode. If the path
22844  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22845  # take no chances and rewrite it.
22846  # Note: m4 eats our [], so we need to use [ and ] instead.
22847  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22848  if test "x$has_forbidden_chars" != x; then
22849    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22850    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22851    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22852    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22853      # Going to short mode and back again did indeed matter. Since short mode is
22854      # case insensitive, let's make it lowercase to improve readability.
22855      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22856      # Now convert it back to Unix-stile (cygpath)
22857      input_path=`$CYGPATH -u "$shortmode_path"`
22858      new_path="$input_path"
22859    fi
22860  fi
22861
22862  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22863  if test "x$test_cygdrive_prefix" = x; then
22864    # As a simple fix, exclude /usr/bin since it's not a real path.
22865    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22866      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22867      # a path prefixed by /cygdrive for fixpath to work.
22868      new_path="$CYGWIN_ROOT_PATH$input_path"
22869    fi
22870  fi
22871
22872
22873  if test "x$path" != "x$new_path"; then
22874    BOOT_JDK="$new_path"
22875    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22876$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22877  fi
22878
22879  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22880
22881  path="$BOOT_JDK"
22882  has_colon=`$ECHO $path | $GREP ^.:`
22883  new_path="$path"
22884  if test "x$has_colon" = x; then
22885    # Not in mixed or Windows style, start by that.
22886    new_path=`cmd //c echo $path`
22887  fi
22888
22889
22890  input_path="$new_path"
22891  # Check if we need to convert this using DOS-style short mode. If the path
22892  # contains just simple characters, use it. Otherwise (spaces, weird characters),
22893  # take no chances and rewrite it.
22894  # Note: m4 eats our [], so we need to use [ and ] instead.
22895  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22896  if test "x$has_forbidden_chars" != x; then
22897    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22898    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22899  fi
22900
22901
22902  windows_path="$new_path"
22903  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22904    unix_path=`$CYGPATH -u "$windows_path"`
22905    new_path="$unix_path"
22906  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22907    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22908    new_path="$unix_path"
22909  fi
22910
22911  if test "x$path" != "x$new_path"; then
22912    BOOT_JDK="$new_path"
22913    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22914$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22915  fi
22916
22917  # Save the first 10 bytes of this path to the storage, so fixpath can work.
22918  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22919
22920  else
22921    # We're on a posix platform. Hooray! :)
22922    path="$BOOT_JDK"
22923    has_space=`$ECHO "$path" | $GREP " "`
22924    if test "x$has_space" != x; then
22925      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22926$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22927      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22928    fi
22929
22930    # Use eval to expand a potential ~
22931    eval path="$path"
22932    if test ! -f "$path" && test ! -d "$path"; then
22933      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22934    fi
22935
22936    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22937  fi
22938
22939              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22940$as_echo_n "checking for Boot JDK... " >&6; }
22941              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22942$as_echo "$BOOT_JDK" >&6; }
22943              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22944$as_echo_n "checking Boot JDK version... " >&6; }
22945              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22946              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22947$as_echo "$BOOT_JDK_VERSION" >&6; }
22948            fi # end check jdk version
22949          fi # end check rt.jar
22950        fi # end check javac
22951      fi # end check java
22952    fi # end check boot jdk found
22953  fi
22954
22955
22956  if test "x$BOOT_JDK_FOUND" = xno; then
22957    # Now execute the test
22958
22959  if test "x$ProgramFiles" != x; then
22960    VIRTUAL_DIR="$ProgramFiles/Java"
22961
22962  windows_path="$VIRTUAL_DIR"
22963  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22964    unix_path=`$CYGPATH -u "$windows_path"`
22965    VIRTUAL_DIR="$unix_path"
22966  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22967    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22968    VIRTUAL_DIR="$unix_path"
22969  fi
22970
22971
22972  BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22973  BOOT_JDK_SUFFIX=""
22974  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22975  if test "x$ALL_JDKS_FOUND" != x; then
22976    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22977
22978  if test "x$BOOT_JDK_FOUND" = xno; then
22979    # Now execute the test
22980
22981        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22982        if test -d "$BOOT_JDK"; then
22983          BOOT_JDK_FOUND=maybe
22984          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22985$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22986        fi
22987
22988
22989    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22990    if test "x$BOOT_JDK_FOUND" = xmaybe; then
22991      # Do we have a bin/java?
22992      if test ! -x "$BOOT_JDK/bin/java"; then
22993        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22994$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22995        BOOT_JDK_FOUND=no
22996      else
22997        # Do we have a bin/javac?
22998        if test ! -x "$BOOT_JDK/bin/javac"; then
22999          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23000$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23001          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23002$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23003          BOOT_JDK_FOUND=no
23004        else
23005          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23006          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23007            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23008$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23009            BOOT_JDK_FOUND=no
23010          else
23011            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23012            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23013
23014            # Extra M4 quote needed to protect [] in grep expression.
23015            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23016            if test "x$FOUND_CORRECT_VERSION" = x; then
23017              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23018$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23019              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23020$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23021              BOOT_JDK_FOUND=no
23022            else
23023              # We're done! :-)
23024              BOOT_JDK_FOUND=yes
23025
23026  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23027
23028  # Input might be given as Windows format, start by converting to
23029  # unix format.
23030  path="$BOOT_JDK"
23031  new_path=`$CYGPATH -u "$path"`
23032
23033  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23034  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23035  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23036  # "foo.exe" is OK but "foo" is an error.
23037  #
23038  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23039  # It is also a way to make sure we got the proper file name for the real test later on.
23040  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23041  if test "x$test_shortpath" = x; then
23042    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23043$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23044    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23045  fi
23046
23047  # Call helper function which possibly converts this using DOS-style short mode.
23048  # If so, the updated path is stored in $new_path.
23049
23050  input_path="$new_path"
23051  # Check if we need to convert this using DOS-style short mode. If the path
23052  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23053  # take no chances and rewrite it.
23054  # Note: m4 eats our [], so we need to use [ and ] instead.
23055  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23056  if test "x$has_forbidden_chars" != x; then
23057    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23058    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23059    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23060    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23061      # Going to short mode and back again did indeed matter. Since short mode is
23062      # case insensitive, let's make it lowercase to improve readability.
23063      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23064      # Now convert it back to Unix-stile (cygpath)
23065      input_path=`$CYGPATH -u "$shortmode_path"`
23066      new_path="$input_path"
23067    fi
23068  fi
23069
23070  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23071  if test "x$test_cygdrive_prefix" = x; then
23072    # As a simple fix, exclude /usr/bin since it's not a real path.
23073    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23074      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23075      # a path prefixed by /cygdrive for fixpath to work.
23076      new_path="$CYGWIN_ROOT_PATH$input_path"
23077    fi
23078  fi
23079
23080
23081  if test "x$path" != "x$new_path"; then
23082    BOOT_JDK="$new_path"
23083    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23084$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23085  fi
23086
23087  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23088
23089  path="$BOOT_JDK"
23090  has_colon=`$ECHO $path | $GREP ^.:`
23091  new_path="$path"
23092  if test "x$has_colon" = x; then
23093    # Not in mixed or Windows style, start by that.
23094    new_path=`cmd //c echo $path`
23095  fi
23096
23097
23098  input_path="$new_path"
23099  # Check if we need to convert this using DOS-style short mode. If the path
23100  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23101  # take no chances and rewrite it.
23102  # Note: m4 eats our [], so we need to use [ and ] instead.
23103  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23104  if test "x$has_forbidden_chars" != x; then
23105    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23106    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23107  fi
23108
23109
23110  windows_path="$new_path"
23111  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23112    unix_path=`$CYGPATH -u "$windows_path"`
23113    new_path="$unix_path"
23114  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23115    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23116    new_path="$unix_path"
23117  fi
23118
23119  if test "x$path" != "x$new_path"; then
23120    BOOT_JDK="$new_path"
23121    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23122$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23123  fi
23124
23125  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23126  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23127
23128  else
23129    # We're on a posix platform. Hooray! :)
23130    path="$BOOT_JDK"
23131    has_space=`$ECHO "$path" | $GREP " "`
23132    if test "x$has_space" != x; then
23133      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23134$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23135      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23136    fi
23137
23138    # Use eval to expand a potential ~
23139    eval path="$path"
23140    if test ! -f "$path" && test ! -d "$path"; then
23141      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23142    fi
23143
23144    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23145  fi
23146
23147              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23148$as_echo_n "checking for Boot JDK... " >&6; }
23149              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23150$as_echo "$BOOT_JDK" >&6; }
23151              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23152$as_echo_n "checking Boot JDK version... " >&6; }
23153              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23154              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23155$as_echo "$BOOT_JDK_VERSION" >&6; }
23156            fi # end check jdk version
23157          fi # end check rt.jar
23158        fi # end check javac
23159      fi # end check java
23160    fi # end check boot jdk found
23161  fi
23162
23163    done
23164  fi
23165
23166  fi
23167
23168
23169    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23170    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23171      # Do we have a bin/java?
23172      if test ! -x "$BOOT_JDK/bin/java"; then
23173        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23174$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23175        BOOT_JDK_FOUND=no
23176      else
23177        # Do we have a bin/javac?
23178        if test ! -x "$BOOT_JDK/bin/javac"; then
23179          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23180$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23181          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23182$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23183          BOOT_JDK_FOUND=no
23184        else
23185          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23186          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23187            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23188$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23189            BOOT_JDK_FOUND=no
23190          else
23191            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23192            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23193
23194            # Extra M4 quote needed to protect [] in grep expression.
23195            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23196            if test "x$FOUND_CORRECT_VERSION" = x; then
23197              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23198$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23199              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23200$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23201              BOOT_JDK_FOUND=no
23202            else
23203              # We're done! :-)
23204              BOOT_JDK_FOUND=yes
23205
23206  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23207
23208  # Input might be given as Windows format, start by converting to
23209  # unix format.
23210  path="$BOOT_JDK"
23211  new_path=`$CYGPATH -u "$path"`
23212
23213  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23214  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23215  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23216  # "foo.exe" is OK but "foo" is an error.
23217  #
23218  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23219  # It is also a way to make sure we got the proper file name for the real test later on.
23220  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23221  if test "x$test_shortpath" = x; then
23222    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23223$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23224    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23225  fi
23226
23227  # Call helper function which possibly converts this using DOS-style short mode.
23228  # If so, the updated path is stored in $new_path.
23229
23230  input_path="$new_path"
23231  # Check if we need to convert this using DOS-style short mode. If the path
23232  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23233  # take no chances and rewrite it.
23234  # Note: m4 eats our [], so we need to use [ and ] instead.
23235  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23236  if test "x$has_forbidden_chars" != x; then
23237    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23238    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23239    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23240    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23241      # Going to short mode and back again did indeed matter. Since short mode is
23242      # case insensitive, let's make it lowercase to improve readability.
23243      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23244      # Now convert it back to Unix-stile (cygpath)
23245      input_path=`$CYGPATH -u "$shortmode_path"`
23246      new_path="$input_path"
23247    fi
23248  fi
23249
23250  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23251  if test "x$test_cygdrive_prefix" = x; then
23252    # As a simple fix, exclude /usr/bin since it's not a real path.
23253    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23254      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23255      # a path prefixed by /cygdrive for fixpath to work.
23256      new_path="$CYGWIN_ROOT_PATH$input_path"
23257    fi
23258  fi
23259
23260
23261  if test "x$path" != "x$new_path"; then
23262    BOOT_JDK="$new_path"
23263    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23264$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23265  fi
23266
23267  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23268
23269  path="$BOOT_JDK"
23270  has_colon=`$ECHO $path | $GREP ^.:`
23271  new_path="$path"
23272  if test "x$has_colon" = x; then
23273    # Not in mixed or Windows style, start by that.
23274    new_path=`cmd //c echo $path`
23275  fi
23276
23277
23278  input_path="$new_path"
23279  # Check if we need to convert this using DOS-style short mode. If the path
23280  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23281  # take no chances and rewrite it.
23282  # Note: m4 eats our [], so we need to use [ and ] instead.
23283  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23284  if test "x$has_forbidden_chars" != x; then
23285    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23286    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23287  fi
23288
23289
23290  windows_path="$new_path"
23291  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23292    unix_path=`$CYGPATH -u "$windows_path"`
23293    new_path="$unix_path"
23294  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23295    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23296    new_path="$unix_path"
23297  fi
23298
23299  if test "x$path" != "x$new_path"; then
23300    BOOT_JDK="$new_path"
23301    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23302$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23303  fi
23304
23305  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23306  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23307
23308  else
23309    # We're on a posix platform. Hooray! :)
23310    path="$BOOT_JDK"
23311    has_space=`$ECHO "$path" | $GREP " "`
23312    if test "x$has_space" != x; then
23313      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23314$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23315      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23316    fi
23317
23318    # Use eval to expand a potential ~
23319    eval path="$path"
23320    if test ! -f "$path" && test ! -d "$path"; then
23321      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23322    fi
23323
23324    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23325  fi
23326
23327              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23328$as_echo_n "checking for Boot JDK... " >&6; }
23329              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23330$as_echo "$BOOT_JDK" >&6; }
23331              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23332$as_echo_n "checking Boot JDK version... " >&6; }
23333              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23334              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23335$as_echo "$BOOT_JDK_VERSION" >&6; }
23336            fi # end check jdk version
23337          fi # end check rt.jar
23338        fi # end check javac
23339      fi # end check java
23340    fi # end check boot jdk found
23341  fi
23342
23343
23344  if test "x$BOOT_JDK_FOUND" = xno; then
23345    # Now execute the test
23346
23347  BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java"
23348  BOOT_JDK_SUFFIX=""
23349  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23350  if test "x$ALL_JDKS_FOUND" != x; then
23351    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23352
23353  if test "x$BOOT_JDK_FOUND" = xno; then
23354    # Now execute the test
23355
23356        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23357        if test -d "$BOOT_JDK"; then
23358          BOOT_JDK_FOUND=maybe
23359          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23360$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23361        fi
23362
23363
23364    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23365    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23366      # Do we have a bin/java?
23367      if test ! -x "$BOOT_JDK/bin/java"; then
23368        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23369$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23370        BOOT_JDK_FOUND=no
23371      else
23372        # Do we have a bin/javac?
23373        if test ! -x "$BOOT_JDK/bin/javac"; then
23374          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23375$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23376          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23377$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23378          BOOT_JDK_FOUND=no
23379        else
23380          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23381          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23382            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23383$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23384            BOOT_JDK_FOUND=no
23385          else
23386            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23387            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23388
23389            # Extra M4 quote needed to protect [] in grep expression.
23390            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23391            if test "x$FOUND_CORRECT_VERSION" = x; then
23392              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23393$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23394              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23395$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23396              BOOT_JDK_FOUND=no
23397            else
23398              # We're done! :-)
23399              BOOT_JDK_FOUND=yes
23400
23401  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23402
23403  # Input might be given as Windows format, start by converting to
23404  # unix format.
23405  path="$BOOT_JDK"
23406  new_path=`$CYGPATH -u "$path"`
23407
23408  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23409  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23410  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23411  # "foo.exe" is OK but "foo" is an error.
23412  #
23413  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23414  # It is also a way to make sure we got the proper file name for the real test later on.
23415  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23416  if test "x$test_shortpath" = x; then
23417    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23418$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23419    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23420  fi
23421
23422  # Call helper function which possibly converts this using DOS-style short mode.
23423  # If so, the updated path is stored in $new_path.
23424
23425  input_path="$new_path"
23426  # Check if we need to convert this using DOS-style short mode. If the path
23427  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23428  # take no chances and rewrite it.
23429  # Note: m4 eats our [], so we need to use [ and ] instead.
23430  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23431  if test "x$has_forbidden_chars" != x; then
23432    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23433    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23434    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23435    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23436      # Going to short mode and back again did indeed matter. Since short mode is
23437      # case insensitive, let's make it lowercase to improve readability.
23438      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23439      # Now convert it back to Unix-stile (cygpath)
23440      input_path=`$CYGPATH -u "$shortmode_path"`
23441      new_path="$input_path"
23442    fi
23443  fi
23444
23445  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23446  if test "x$test_cygdrive_prefix" = x; then
23447    # As a simple fix, exclude /usr/bin since it's not a real path.
23448    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23449      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23450      # a path prefixed by /cygdrive for fixpath to work.
23451      new_path="$CYGWIN_ROOT_PATH$input_path"
23452    fi
23453  fi
23454
23455
23456  if test "x$path" != "x$new_path"; then
23457    BOOT_JDK="$new_path"
23458    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23459$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23460  fi
23461
23462  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23463
23464  path="$BOOT_JDK"
23465  has_colon=`$ECHO $path | $GREP ^.:`
23466  new_path="$path"
23467  if test "x$has_colon" = x; then
23468    # Not in mixed or Windows style, start by that.
23469    new_path=`cmd //c echo $path`
23470  fi
23471
23472
23473  input_path="$new_path"
23474  # Check if we need to convert this using DOS-style short mode. If the path
23475  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23476  # take no chances and rewrite it.
23477  # Note: m4 eats our [], so we need to use [ and ] instead.
23478  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23479  if test "x$has_forbidden_chars" != x; then
23480    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23481    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23482  fi
23483
23484
23485  windows_path="$new_path"
23486  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23487    unix_path=`$CYGPATH -u "$windows_path"`
23488    new_path="$unix_path"
23489  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23490    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23491    new_path="$unix_path"
23492  fi
23493
23494  if test "x$path" != "x$new_path"; then
23495    BOOT_JDK="$new_path"
23496    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23497$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23498  fi
23499
23500  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23501  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23502
23503  else
23504    # We're on a posix platform. Hooray! :)
23505    path="$BOOT_JDK"
23506    has_space=`$ECHO "$path" | $GREP " "`
23507    if test "x$has_space" != x; then
23508      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23509$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23510      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23511    fi
23512
23513    # Use eval to expand a potential ~
23514    eval path="$path"
23515    if test ! -f "$path" && test ! -d "$path"; then
23516      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23517    fi
23518
23519    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23520  fi
23521
23522              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23523$as_echo_n "checking for Boot JDK... " >&6; }
23524              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23525$as_echo "$BOOT_JDK" >&6; }
23526              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23527$as_echo_n "checking Boot JDK version... " >&6; }
23528              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23529              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23530$as_echo "$BOOT_JDK_VERSION" >&6; }
23531            fi # end check jdk version
23532          fi # end check rt.jar
23533        fi # end check javac
23534      fi # end check java
23535    fi # end check boot jdk found
23536  fi
23537
23538    done
23539  fi
23540
23541
23542    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23543    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23544      # Do we have a bin/java?
23545      if test ! -x "$BOOT_JDK/bin/java"; then
23546        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23547$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23548        BOOT_JDK_FOUND=no
23549      else
23550        # Do we have a bin/javac?
23551        if test ! -x "$BOOT_JDK/bin/javac"; then
23552          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23553$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23554          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23555$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23556          BOOT_JDK_FOUND=no
23557        else
23558          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23559          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23560            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23561$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23562            BOOT_JDK_FOUND=no
23563          else
23564            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23565            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23566
23567            # Extra M4 quote needed to protect [] in grep expression.
23568            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23569            if test "x$FOUND_CORRECT_VERSION" = x; then
23570              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23571$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23572              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23573$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23574              BOOT_JDK_FOUND=no
23575            else
23576              # We're done! :-)
23577              BOOT_JDK_FOUND=yes
23578
23579  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23580
23581  # Input might be given as Windows format, start by converting to
23582  # unix format.
23583  path="$BOOT_JDK"
23584  new_path=`$CYGPATH -u "$path"`
23585
23586  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23587  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23588  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23589  # "foo.exe" is OK but "foo" is an error.
23590  #
23591  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23592  # It is also a way to make sure we got the proper file name for the real test later on.
23593  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23594  if test "x$test_shortpath" = x; then
23595    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23596$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23597    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23598  fi
23599
23600  # Call helper function which possibly converts this using DOS-style short mode.
23601  # If so, the updated path is stored in $new_path.
23602
23603  input_path="$new_path"
23604  # Check if we need to convert this using DOS-style short mode. If the path
23605  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23606  # take no chances and rewrite it.
23607  # Note: m4 eats our [], so we need to use [ and ] instead.
23608  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23609  if test "x$has_forbidden_chars" != x; then
23610    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23611    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23612    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23613    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23614      # Going to short mode and back again did indeed matter. Since short mode is
23615      # case insensitive, let's make it lowercase to improve readability.
23616      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23617      # Now convert it back to Unix-stile (cygpath)
23618      input_path=`$CYGPATH -u "$shortmode_path"`
23619      new_path="$input_path"
23620    fi
23621  fi
23622
23623  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23624  if test "x$test_cygdrive_prefix" = x; then
23625    # As a simple fix, exclude /usr/bin since it's not a real path.
23626    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23627      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23628      # a path prefixed by /cygdrive for fixpath to work.
23629      new_path="$CYGWIN_ROOT_PATH$input_path"
23630    fi
23631  fi
23632
23633
23634  if test "x$path" != "x$new_path"; then
23635    BOOT_JDK="$new_path"
23636    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23637$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23638  fi
23639
23640  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23641
23642  path="$BOOT_JDK"
23643  has_colon=`$ECHO $path | $GREP ^.:`
23644  new_path="$path"
23645  if test "x$has_colon" = x; then
23646    # Not in mixed or Windows style, start by that.
23647    new_path=`cmd //c echo $path`
23648  fi
23649
23650
23651  input_path="$new_path"
23652  # Check if we need to convert this using DOS-style short mode. If the path
23653  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23654  # take no chances and rewrite it.
23655  # Note: m4 eats our [], so we need to use [ and ] instead.
23656  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23657  if test "x$has_forbidden_chars" != x; then
23658    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23659    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23660  fi
23661
23662
23663  windows_path="$new_path"
23664  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23665    unix_path=`$CYGPATH -u "$windows_path"`
23666    new_path="$unix_path"
23667  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23668    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23669    new_path="$unix_path"
23670  fi
23671
23672  if test "x$path" != "x$new_path"; then
23673    BOOT_JDK="$new_path"
23674    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23675$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23676  fi
23677
23678  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23679  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23680
23681  else
23682    # We're on a posix platform. Hooray! :)
23683    path="$BOOT_JDK"
23684    has_space=`$ECHO "$path" | $GREP " "`
23685    if test "x$has_space" != x; then
23686      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23687$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23688      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23689    fi
23690
23691    # Use eval to expand a potential ~
23692    eval path="$path"
23693    if test ! -f "$path" && test ! -d "$path"; then
23694      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23695    fi
23696
23697    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23698  fi
23699
23700              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23701$as_echo_n "checking for Boot JDK... " >&6; }
23702              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23703$as_echo "$BOOT_JDK" >&6; }
23704              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23705$as_echo_n "checking Boot JDK version... " >&6; }
23706              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23707              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23708$as_echo "$BOOT_JDK_VERSION" >&6; }
23709            fi # end check jdk version
23710          fi # end check rt.jar
23711        fi # end check javac
23712      fi # end check java
23713    fi # end check boot jdk found
23714  fi
23715
23716  elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
23717
23718  if test "x$BOOT_JDK_FOUND" = xno; then
23719    # Now execute the test
23720
23721  BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines"
23722  BOOT_JDK_SUFFIX="/Contents/Home"
23723  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23724  if test "x$ALL_JDKS_FOUND" != x; then
23725    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23726
23727  if test "x$BOOT_JDK_FOUND" = xno; then
23728    # Now execute the test
23729
23730        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23731        if test -d "$BOOT_JDK"; then
23732          BOOT_JDK_FOUND=maybe
23733          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23734$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23735        fi
23736
23737
23738    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23739    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23740      # Do we have a bin/java?
23741      if test ! -x "$BOOT_JDK/bin/java"; then
23742        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23743$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23744        BOOT_JDK_FOUND=no
23745      else
23746        # Do we have a bin/javac?
23747        if test ! -x "$BOOT_JDK/bin/javac"; then
23748          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23749$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23750          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23751$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23752          BOOT_JDK_FOUND=no
23753        else
23754          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23755          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23756            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23757$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23758            BOOT_JDK_FOUND=no
23759          else
23760            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23761            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23762
23763            # Extra M4 quote needed to protect [] in grep expression.
23764            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23765            if test "x$FOUND_CORRECT_VERSION" = x; then
23766              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23767$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23768              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23769$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23770              BOOT_JDK_FOUND=no
23771            else
23772              # We're done! :-)
23773              BOOT_JDK_FOUND=yes
23774
23775  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23776
23777  # Input might be given as Windows format, start by converting to
23778  # unix format.
23779  path="$BOOT_JDK"
23780  new_path=`$CYGPATH -u "$path"`
23781
23782  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23783  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23784  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23785  # "foo.exe" is OK but "foo" is an error.
23786  #
23787  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23788  # It is also a way to make sure we got the proper file name for the real test later on.
23789  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23790  if test "x$test_shortpath" = x; then
23791    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23792$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23793    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23794  fi
23795
23796  # Call helper function which possibly converts this using DOS-style short mode.
23797  # If so, the updated path is stored in $new_path.
23798
23799  input_path="$new_path"
23800  # Check if we need to convert this using DOS-style short mode. If the path
23801  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23802  # take no chances and rewrite it.
23803  # Note: m4 eats our [], so we need to use [ and ] instead.
23804  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23805  if test "x$has_forbidden_chars" != x; then
23806    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23807    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23808    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23809    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23810      # Going to short mode and back again did indeed matter. Since short mode is
23811      # case insensitive, let's make it lowercase to improve readability.
23812      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23813      # Now convert it back to Unix-stile (cygpath)
23814      input_path=`$CYGPATH -u "$shortmode_path"`
23815      new_path="$input_path"
23816    fi
23817  fi
23818
23819  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23820  if test "x$test_cygdrive_prefix" = x; then
23821    # As a simple fix, exclude /usr/bin since it's not a real path.
23822    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23823      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23824      # a path prefixed by /cygdrive for fixpath to work.
23825      new_path="$CYGWIN_ROOT_PATH$input_path"
23826    fi
23827  fi
23828
23829
23830  if test "x$path" != "x$new_path"; then
23831    BOOT_JDK="$new_path"
23832    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23833$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23834  fi
23835
23836  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23837
23838  path="$BOOT_JDK"
23839  has_colon=`$ECHO $path | $GREP ^.:`
23840  new_path="$path"
23841  if test "x$has_colon" = x; then
23842    # Not in mixed or Windows style, start by that.
23843    new_path=`cmd //c echo $path`
23844  fi
23845
23846
23847  input_path="$new_path"
23848  # Check if we need to convert this using DOS-style short mode. If the path
23849  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23850  # take no chances and rewrite it.
23851  # Note: m4 eats our [], so we need to use [ and ] instead.
23852  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23853  if test "x$has_forbidden_chars" != x; then
23854    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23855    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23856  fi
23857
23858
23859  windows_path="$new_path"
23860  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23861    unix_path=`$CYGPATH -u "$windows_path"`
23862    new_path="$unix_path"
23863  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23864    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23865    new_path="$unix_path"
23866  fi
23867
23868  if test "x$path" != "x$new_path"; then
23869    BOOT_JDK="$new_path"
23870    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23871$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23872  fi
23873
23874  # Save the first 10 bytes of this path to the storage, so fixpath can work.
23875  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23876
23877  else
23878    # We're on a posix platform. Hooray! :)
23879    path="$BOOT_JDK"
23880    has_space=`$ECHO "$path" | $GREP " "`
23881    if test "x$has_space" != x; then
23882      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23883$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23884      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23885    fi
23886
23887    # Use eval to expand a potential ~
23888    eval path="$path"
23889    if test ! -f "$path" && test ! -d "$path"; then
23890      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23891    fi
23892
23893    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23894  fi
23895
23896              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23897$as_echo_n "checking for Boot JDK... " >&6; }
23898              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23899$as_echo "$BOOT_JDK" >&6; }
23900              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23901$as_echo_n "checking Boot JDK version... " >&6; }
23902              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23903              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23904$as_echo "$BOOT_JDK_VERSION" >&6; }
23905            fi # end check jdk version
23906          fi # end check rt.jar
23907        fi # end check javac
23908      fi # end check java
23909    fi # end check boot jdk found
23910  fi
23911
23912    done
23913  fi
23914
23915
23916    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23917    if test "x$BOOT_JDK_FOUND" = xmaybe; then
23918      # Do we have a bin/java?
23919      if test ! -x "$BOOT_JDK/bin/java"; then
23920        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23921$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23922        BOOT_JDK_FOUND=no
23923      else
23924        # Do we have a bin/javac?
23925        if test ! -x "$BOOT_JDK/bin/javac"; then
23926          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23927$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23928          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23929$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23930          BOOT_JDK_FOUND=no
23931        else
23932          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23933          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23934            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23935$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23936            BOOT_JDK_FOUND=no
23937          else
23938            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23939            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23940
23941            # Extra M4 quote needed to protect [] in grep expression.
23942            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23943            if test "x$FOUND_CORRECT_VERSION" = x; then
23944              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23945$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23946              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23947$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23948              BOOT_JDK_FOUND=no
23949            else
23950              # We're done! :-)
23951              BOOT_JDK_FOUND=yes
23952
23953  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23954
23955  # Input might be given as Windows format, start by converting to
23956  # unix format.
23957  path="$BOOT_JDK"
23958  new_path=`$CYGPATH -u "$path"`
23959
23960  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23961  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23962  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23963  # "foo.exe" is OK but "foo" is an error.
23964  #
23965  # This test is therefore slightly more accurate than "test -f" to check for file precense.
23966  # It is also a way to make sure we got the proper file name for the real test later on.
23967  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23968  if test "x$test_shortpath" = x; then
23969    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23970$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23971    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23972  fi
23973
23974  # Call helper function which possibly converts this using DOS-style short mode.
23975  # If so, the updated path is stored in $new_path.
23976
23977  input_path="$new_path"
23978  # Check if we need to convert this using DOS-style short mode. If the path
23979  # contains just simple characters, use it. Otherwise (spaces, weird characters),
23980  # take no chances and rewrite it.
23981  # Note: m4 eats our [], so we need to use [ and ] instead.
23982  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23983  if test "x$has_forbidden_chars" != x; then
23984    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23985    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23986    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23987    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23988      # Going to short mode and back again did indeed matter. Since short mode is
23989      # case insensitive, let's make it lowercase to improve readability.
23990      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23991      # Now convert it back to Unix-stile (cygpath)
23992      input_path=`$CYGPATH -u "$shortmode_path"`
23993      new_path="$input_path"
23994    fi
23995  fi
23996
23997  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23998  if test "x$test_cygdrive_prefix" = x; then
23999    # As a simple fix, exclude /usr/bin since it's not a real path.
24000    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24001      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24002      # a path prefixed by /cygdrive for fixpath to work.
24003      new_path="$CYGWIN_ROOT_PATH$input_path"
24004    fi
24005  fi
24006
24007
24008  if test "x$path" != "x$new_path"; then
24009    BOOT_JDK="$new_path"
24010    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24011$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24012  fi
24013
24014  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24015
24016  path="$BOOT_JDK"
24017  has_colon=`$ECHO $path | $GREP ^.:`
24018  new_path="$path"
24019  if test "x$has_colon" = x; then
24020    # Not in mixed or Windows style, start by that.
24021    new_path=`cmd //c echo $path`
24022  fi
24023
24024
24025  input_path="$new_path"
24026  # Check if we need to convert this using DOS-style short mode. If the path
24027  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24028  # take no chances and rewrite it.
24029  # Note: m4 eats our [], so we need to use [ and ] instead.
24030  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24031  if test "x$has_forbidden_chars" != x; then
24032    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24033    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24034  fi
24035
24036
24037  windows_path="$new_path"
24038  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24039    unix_path=`$CYGPATH -u "$windows_path"`
24040    new_path="$unix_path"
24041  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24042    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24043    new_path="$unix_path"
24044  fi
24045
24046  if test "x$path" != "x$new_path"; then
24047    BOOT_JDK="$new_path"
24048    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24049$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24050  fi
24051
24052  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24053  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24054
24055  else
24056    # We're on a posix platform. Hooray! :)
24057    path="$BOOT_JDK"
24058    has_space=`$ECHO "$path" | $GREP " "`
24059    if test "x$has_space" != x; then
24060      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24061$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24062      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24063    fi
24064
24065    # Use eval to expand a potential ~
24066    eval path="$path"
24067    if test ! -f "$path" && test ! -d "$path"; then
24068      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24069    fi
24070
24071    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24072  fi
24073
24074              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24075$as_echo_n "checking for Boot JDK... " >&6; }
24076              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24077$as_echo "$BOOT_JDK" >&6; }
24078              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24079$as_echo_n "checking Boot JDK version... " >&6; }
24080              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24081              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24082$as_echo "$BOOT_JDK_VERSION" >&6; }
24083            fi # end check jdk version
24084          fi # end check rt.jar
24085        fi # end check javac
24086      fi # end check java
24087    fi # end check boot jdk found
24088  fi
24089
24090
24091  if test "x$BOOT_JDK_FOUND" = xno; then
24092    # Now execute the test
24093
24094  BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines"
24095  BOOT_JDK_SUFFIX="/Contents/Home"
24096  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24097  if test "x$ALL_JDKS_FOUND" != x; then
24098    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24099
24100  if test "x$BOOT_JDK_FOUND" = xno; then
24101    # Now execute the test
24102
24103        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24104        if test -d "$BOOT_JDK"; then
24105          BOOT_JDK_FOUND=maybe
24106          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24107$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24108        fi
24109
24110
24111    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24112    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24113      # Do we have a bin/java?
24114      if test ! -x "$BOOT_JDK/bin/java"; then
24115        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24116$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24117        BOOT_JDK_FOUND=no
24118      else
24119        # Do we have a bin/javac?
24120        if test ! -x "$BOOT_JDK/bin/javac"; then
24121          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24122$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24123          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24124$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24125          BOOT_JDK_FOUND=no
24126        else
24127          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24128          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24129            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24130$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24131            BOOT_JDK_FOUND=no
24132          else
24133            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24134            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24135
24136            # Extra M4 quote needed to protect [] in grep expression.
24137            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24138            if test "x$FOUND_CORRECT_VERSION" = x; then
24139              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24140$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24141              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24142$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24143              BOOT_JDK_FOUND=no
24144            else
24145              # We're done! :-)
24146              BOOT_JDK_FOUND=yes
24147
24148  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24149
24150  # Input might be given as Windows format, start by converting to
24151  # unix format.
24152  path="$BOOT_JDK"
24153  new_path=`$CYGPATH -u "$path"`
24154
24155  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24156  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24157  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24158  # "foo.exe" is OK but "foo" is an error.
24159  #
24160  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24161  # It is also a way to make sure we got the proper file name for the real test later on.
24162  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24163  if test "x$test_shortpath" = x; then
24164    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24165$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24166    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24167  fi
24168
24169  # Call helper function which possibly converts this using DOS-style short mode.
24170  # If so, the updated path is stored in $new_path.
24171
24172  input_path="$new_path"
24173  # Check if we need to convert this using DOS-style short mode. If the path
24174  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24175  # take no chances and rewrite it.
24176  # Note: m4 eats our [], so we need to use [ and ] instead.
24177  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24178  if test "x$has_forbidden_chars" != x; then
24179    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24180    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24181    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24182    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24183      # Going to short mode and back again did indeed matter. Since short mode is
24184      # case insensitive, let's make it lowercase to improve readability.
24185      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24186      # Now convert it back to Unix-stile (cygpath)
24187      input_path=`$CYGPATH -u "$shortmode_path"`
24188      new_path="$input_path"
24189    fi
24190  fi
24191
24192  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24193  if test "x$test_cygdrive_prefix" = x; then
24194    # As a simple fix, exclude /usr/bin since it's not a real path.
24195    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24196      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24197      # a path prefixed by /cygdrive for fixpath to work.
24198      new_path="$CYGWIN_ROOT_PATH$input_path"
24199    fi
24200  fi
24201
24202
24203  if test "x$path" != "x$new_path"; then
24204    BOOT_JDK="$new_path"
24205    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24206$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24207  fi
24208
24209  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24210
24211  path="$BOOT_JDK"
24212  has_colon=`$ECHO $path | $GREP ^.:`
24213  new_path="$path"
24214  if test "x$has_colon" = x; then
24215    # Not in mixed or Windows style, start by that.
24216    new_path=`cmd //c echo $path`
24217  fi
24218
24219
24220  input_path="$new_path"
24221  # Check if we need to convert this using DOS-style short mode. If the path
24222  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24223  # take no chances and rewrite it.
24224  # Note: m4 eats our [], so we need to use [ and ] instead.
24225  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24226  if test "x$has_forbidden_chars" != x; then
24227    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24228    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24229  fi
24230
24231
24232  windows_path="$new_path"
24233  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24234    unix_path=`$CYGPATH -u "$windows_path"`
24235    new_path="$unix_path"
24236  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24237    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24238    new_path="$unix_path"
24239  fi
24240
24241  if test "x$path" != "x$new_path"; then
24242    BOOT_JDK="$new_path"
24243    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24244$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24245  fi
24246
24247  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24248  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24249
24250  else
24251    # We're on a posix platform. Hooray! :)
24252    path="$BOOT_JDK"
24253    has_space=`$ECHO "$path" | $GREP " "`
24254    if test "x$has_space" != x; then
24255      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24256$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24257      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24258    fi
24259
24260    # Use eval to expand a potential ~
24261    eval path="$path"
24262    if test ! -f "$path" && test ! -d "$path"; then
24263      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24264    fi
24265
24266    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24267  fi
24268
24269              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24270$as_echo_n "checking for Boot JDK... " >&6; }
24271              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24272$as_echo "$BOOT_JDK" >&6; }
24273              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24274$as_echo_n "checking Boot JDK version... " >&6; }
24275              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24276              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24277$as_echo "$BOOT_JDK_VERSION" >&6; }
24278            fi # end check jdk version
24279          fi # end check rt.jar
24280        fi # end check javac
24281      fi # end check java
24282    fi # end check boot jdk found
24283  fi
24284
24285    done
24286  fi
24287
24288
24289    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24290    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24291      # Do we have a bin/java?
24292      if test ! -x "$BOOT_JDK/bin/java"; then
24293        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24294$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24295        BOOT_JDK_FOUND=no
24296      else
24297        # Do we have a bin/javac?
24298        if test ! -x "$BOOT_JDK/bin/javac"; then
24299          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24300$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24301          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24302$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24303          BOOT_JDK_FOUND=no
24304        else
24305          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24306          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24307            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24308$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24309            BOOT_JDK_FOUND=no
24310          else
24311            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24312            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24313
24314            # Extra M4 quote needed to protect [] in grep expression.
24315            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24316            if test "x$FOUND_CORRECT_VERSION" = x; then
24317              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24318$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24319              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24320$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24321              BOOT_JDK_FOUND=no
24322            else
24323              # We're done! :-)
24324              BOOT_JDK_FOUND=yes
24325
24326  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24327
24328  # Input might be given as Windows format, start by converting to
24329  # unix format.
24330  path="$BOOT_JDK"
24331  new_path=`$CYGPATH -u "$path"`
24332
24333  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24334  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24335  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24336  # "foo.exe" is OK but "foo" is an error.
24337  #
24338  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24339  # It is also a way to make sure we got the proper file name for the real test later on.
24340  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24341  if test "x$test_shortpath" = x; then
24342    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24343$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24344    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24345  fi
24346
24347  # Call helper function which possibly converts this using DOS-style short mode.
24348  # If so, the updated path is stored in $new_path.
24349
24350  input_path="$new_path"
24351  # Check if we need to convert this using DOS-style short mode. If the path
24352  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24353  # take no chances and rewrite it.
24354  # Note: m4 eats our [], so we need to use [ and ] instead.
24355  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24356  if test "x$has_forbidden_chars" != x; then
24357    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24358    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24359    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24360    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24361      # Going to short mode and back again did indeed matter. Since short mode is
24362      # case insensitive, let's make it lowercase to improve readability.
24363      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24364      # Now convert it back to Unix-stile (cygpath)
24365      input_path=`$CYGPATH -u "$shortmode_path"`
24366      new_path="$input_path"
24367    fi
24368  fi
24369
24370  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24371  if test "x$test_cygdrive_prefix" = x; then
24372    # As a simple fix, exclude /usr/bin since it's not a real path.
24373    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24374      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24375      # a path prefixed by /cygdrive for fixpath to work.
24376      new_path="$CYGWIN_ROOT_PATH$input_path"
24377    fi
24378  fi
24379
24380
24381  if test "x$path" != "x$new_path"; then
24382    BOOT_JDK="$new_path"
24383    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24384$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24385  fi
24386
24387  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24388
24389  path="$BOOT_JDK"
24390  has_colon=`$ECHO $path | $GREP ^.:`
24391  new_path="$path"
24392  if test "x$has_colon" = x; then
24393    # Not in mixed or Windows style, start by that.
24394    new_path=`cmd //c echo $path`
24395  fi
24396
24397
24398  input_path="$new_path"
24399  # Check if we need to convert this using DOS-style short mode. If the path
24400  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24401  # take no chances and rewrite it.
24402  # Note: m4 eats our [], so we need to use [ and ] instead.
24403  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24404  if test "x$has_forbidden_chars" != x; then
24405    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24406    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24407  fi
24408
24409
24410  windows_path="$new_path"
24411  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24412    unix_path=`$CYGPATH -u "$windows_path"`
24413    new_path="$unix_path"
24414  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24415    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24416    new_path="$unix_path"
24417  fi
24418
24419  if test "x$path" != "x$new_path"; then
24420    BOOT_JDK="$new_path"
24421    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24422$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24423  fi
24424
24425  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24426  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24427
24428  else
24429    # We're on a posix platform. Hooray! :)
24430    path="$BOOT_JDK"
24431    has_space=`$ECHO "$path" | $GREP " "`
24432    if test "x$has_space" != x; then
24433      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24434$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24435      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24436    fi
24437
24438    # Use eval to expand a potential ~
24439    eval path="$path"
24440    if test ! -f "$path" && test ! -d "$path"; then
24441      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24442    fi
24443
24444    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24445  fi
24446
24447              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24448$as_echo_n "checking for Boot JDK... " >&6; }
24449              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24450$as_echo "$BOOT_JDK" >&6; }
24451              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24452$as_echo_n "checking Boot JDK version... " >&6; }
24453              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24454              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24455$as_echo "$BOOT_JDK_VERSION" >&6; }
24456            fi # end check jdk version
24457          fi # end check rt.jar
24458        fi # end check javac
24459      fi # end check java
24460    fi # end check boot jdk found
24461  fi
24462
24463  elif test "x$OPENJDK_TARGET_OS" = xlinux; then
24464
24465  if test "x$BOOT_JDK_FOUND" = xno; then
24466    # Now execute the test
24467
24468  BOOT_JDK_PREFIX="/usr/lib/jvm"
24469  BOOT_JDK_SUFFIX=""
24470  ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24471  if test "x$ALL_JDKS_FOUND" != x; then
24472    for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24473
24474  if test "x$BOOT_JDK_FOUND" = xno; then
24475    # Now execute the test
24476
24477        BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24478        if test -d "$BOOT_JDK"; then
24479          BOOT_JDK_FOUND=maybe
24480          { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24481$as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24482        fi
24483
24484
24485    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24486    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24487      # Do we have a bin/java?
24488      if test ! -x "$BOOT_JDK/bin/java"; then
24489        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24490$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24491        BOOT_JDK_FOUND=no
24492      else
24493        # Do we have a bin/javac?
24494        if test ! -x "$BOOT_JDK/bin/javac"; then
24495          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24496$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24497          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24498$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24499          BOOT_JDK_FOUND=no
24500        else
24501          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24502          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24503            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24504$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24505            BOOT_JDK_FOUND=no
24506          else
24507            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24508            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24509
24510            # Extra M4 quote needed to protect [] in grep expression.
24511            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24512            if test "x$FOUND_CORRECT_VERSION" = x; then
24513              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24514$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24515              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24516$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24517              BOOT_JDK_FOUND=no
24518            else
24519              # We're done! :-)
24520              BOOT_JDK_FOUND=yes
24521
24522  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24523
24524  # Input might be given as Windows format, start by converting to
24525  # unix format.
24526  path="$BOOT_JDK"
24527  new_path=`$CYGPATH -u "$path"`
24528
24529  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24530  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24531  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24532  # "foo.exe" is OK but "foo" is an error.
24533  #
24534  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24535  # It is also a way to make sure we got the proper file name for the real test later on.
24536  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24537  if test "x$test_shortpath" = x; then
24538    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24539$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24540    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24541  fi
24542
24543  # Call helper function which possibly converts this using DOS-style short mode.
24544  # If so, the updated path is stored in $new_path.
24545
24546  input_path="$new_path"
24547  # Check if we need to convert this using DOS-style short mode. If the path
24548  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24549  # take no chances and rewrite it.
24550  # Note: m4 eats our [], so we need to use [ and ] instead.
24551  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24552  if test "x$has_forbidden_chars" != x; then
24553    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24554    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24555    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24556    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24557      # Going to short mode and back again did indeed matter. Since short mode is
24558      # case insensitive, let's make it lowercase to improve readability.
24559      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24560      # Now convert it back to Unix-stile (cygpath)
24561      input_path=`$CYGPATH -u "$shortmode_path"`
24562      new_path="$input_path"
24563    fi
24564  fi
24565
24566  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24567  if test "x$test_cygdrive_prefix" = x; then
24568    # As a simple fix, exclude /usr/bin since it's not a real path.
24569    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24570      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24571      # a path prefixed by /cygdrive for fixpath to work.
24572      new_path="$CYGWIN_ROOT_PATH$input_path"
24573    fi
24574  fi
24575
24576
24577  if test "x$path" != "x$new_path"; then
24578    BOOT_JDK="$new_path"
24579    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24580$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24581  fi
24582
24583  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24584
24585  path="$BOOT_JDK"
24586  has_colon=`$ECHO $path | $GREP ^.:`
24587  new_path="$path"
24588  if test "x$has_colon" = x; then
24589    # Not in mixed or Windows style, start by that.
24590    new_path=`cmd //c echo $path`
24591  fi
24592
24593
24594  input_path="$new_path"
24595  # Check if we need to convert this using DOS-style short mode. If the path
24596  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24597  # take no chances and rewrite it.
24598  # Note: m4 eats our [], so we need to use [ and ] instead.
24599  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24600  if test "x$has_forbidden_chars" != x; then
24601    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24602    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24603  fi
24604
24605
24606  windows_path="$new_path"
24607  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24608    unix_path=`$CYGPATH -u "$windows_path"`
24609    new_path="$unix_path"
24610  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24611    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24612    new_path="$unix_path"
24613  fi
24614
24615  if test "x$path" != "x$new_path"; then
24616    BOOT_JDK="$new_path"
24617    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24618$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24619  fi
24620
24621  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24622  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24623
24624  else
24625    # We're on a posix platform. Hooray! :)
24626    path="$BOOT_JDK"
24627    has_space=`$ECHO "$path" | $GREP " "`
24628    if test "x$has_space" != x; then
24629      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24630$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24631      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24632    fi
24633
24634    # Use eval to expand a potential ~
24635    eval path="$path"
24636    if test ! -f "$path" && test ! -d "$path"; then
24637      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24638    fi
24639
24640    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24641  fi
24642
24643              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24644$as_echo_n "checking for Boot JDK... " >&6; }
24645              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24646$as_echo "$BOOT_JDK" >&6; }
24647              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24648$as_echo_n "checking Boot JDK version... " >&6; }
24649              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24650              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24651$as_echo "$BOOT_JDK_VERSION" >&6; }
24652            fi # end check jdk version
24653          fi # end check rt.jar
24654        fi # end check javac
24655      fi # end check java
24656    fi # end check boot jdk found
24657  fi
24658
24659    done
24660  fi
24661
24662
24663    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24664    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24665      # Do we have a bin/java?
24666      if test ! -x "$BOOT_JDK/bin/java"; then
24667        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24668$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24669        BOOT_JDK_FOUND=no
24670      else
24671        # Do we have a bin/javac?
24672        if test ! -x "$BOOT_JDK/bin/javac"; then
24673          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24674$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24675          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24676$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24677          BOOT_JDK_FOUND=no
24678        else
24679          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24680          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24681            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24682$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24683            BOOT_JDK_FOUND=no
24684          else
24685            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24686            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24687
24688            # Extra M4 quote needed to protect [] in grep expression.
24689            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24690            if test "x$FOUND_CORRECT_VERSION" = x; then
24691              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24692$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24693              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24694$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24695              BOOT_JDK_FOUND=no
24696            else
24697              # We're done! :-)
24698              BOOT_JDK_FOUND=yes
24699
24700  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24701
24702  # Input might be given as Windows format, start by converting to
24703  # unix format.
24704  path="$BOOT_JDK"
24705  new_path=`$CYGPATH -u "$path"`
24706
24707  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24708  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24709  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24710  # "foo.exe" is OK but "foo" is an error.
24711  #
24712  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24713  # It is also a way to make sure we got the proper file name for the real test later on.
24714  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24715  if test "x$test_shortpath" = x; then
24716    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24717$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24718    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24719  fi
24720
24721  # Call helper function which possibly converts this using DOS-style short mode.
24722  # If so, the updated path is stored in $new_path.
24723
24724  input_path="$new_path"
24725  # Check if we need to convert this using DOS-style short mode. If the path
24726  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24727  # take no chances and rewrite it.
24728  # Note: m4 eats our [], so we need to use [ and ] instead.
24729  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24730  if test "x$has_forbidden_chars" != x; then
24731    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24732    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24733    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24734    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24735      # Going to short mode and back again did indeed matter. Since short mode is
24736      # case insensitive, let's make it lowercase to improve readability.
24737      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24738      # Now convert it back to Unix-stile (cygpath)
24739      input_path=`$CYGPATH -u "$shortmode_path"`
24740      new_path="$input_path"
24741    fi
24742  fi
24743
24744  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24745  if test "x$test_cygdrive_prefix" = x; then
24746    # As a simple fix, exclude /usr/bin since it's not a real path.
24747    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24748      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24749      # a path prefixed by /cygdrive for fixpath to work.
24750      new_path="$CYGWIN_ROOT_PATH$input_path"
24751    fi
24752  fi
24753
24754
24755  if test "x$path" != "x$new_path"; then
24756    BOOT_JDK="$new_path"
24757    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24758$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24759  fi
24760
24761  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24762
24763  path="$BOOT_JDK"
24764  has_colon=`$ECHO $path | $GREP ^.:`
24765  new_path="$path"
24766  if test "x$has_colon" = x; then
24767    # Not in mixed or Windows style, start by that.
24768    new_path=`cmd //c echo $path`
24769  fi
24770
24771
24772  input_path="$new_path"
24773  # Check if we need to convert this using DOS-style short mode. If the path
24774  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24775  # take no chances and rewrite it.
24776  # Note: m4 eats our [], so we need to use [ and ] instead.
24777  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24778  if test "x$has_forbidden_chars" != x; then
24779    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24780    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24781  fi
24782
24783
24784  windows_path="$new_path"
24785  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24786    unix_path=`$CYGPATH -u "$windows_path"`
24787    new_path="$unix_path"
24788  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24789    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24790    new_path="$unix_path"
24791  fi
24792
24793  if test "x$path" != "x$new_path"; then
24794    BOOT_JDK="$new_path"
24795    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24796$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24797  fi
24798
24799  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24800  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24801
24802  else
24803    # We're on a posix platform. Hooray! :)
24804    path="$BOOT_JDK"
24805    has_space=`$ECHO "$path" | $GREP " "`
24806    if test "x$has_space" != x; then
24807      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24808$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24809      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24810    fi
24811
24812    # Use eval to expand a potential ~
24813    eval path="$path"
24814    if test ! -f "$path" && test ! -d "$path"; then
24815      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24816    fi
24817
24818    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24819  fi
24820
24821              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24822$as_echo_n "checking for Boot JDK... " >&6; }
24823              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24824$as_echo "$BOOT_JDK" >&6; }
24825              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24826$as_echo_n "checking Boot JDK version... " >&6; }
24827              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24828              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24829$as_echo "$BOOT_JDK_VERSION" >&6; }
24830            fi # end check jdk version
24831          fi # end check rt.jar
24832        fi # end check javac
24833      fi # end check java
24834    fi # end check boot jdk found
24835  fi
24836
24837  fi
24838
24839
24840    # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24841    if test "x$BOOT_JDK_FOUND" = xmaybe; then
24842      # Do we have a bin/java?
24843      if test ! -x "$BOOT_JDK/bin/java"; then
24844        { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24845$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24846        BOOT_JDK_FOUND=no
24847      else
24848        # Do we have a bin/javac?
24849        if test ! -x "$BOOT_JDK/bin/javac"; then
24850          { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24851$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24852          { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24853$as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24854          BOOT_JDK_FOUND=no
24855        else
24856          # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24857          if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24858            { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24859$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24860            BOOT_JDK_FOUND=no
24861          else
24862            # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24863            BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24864
24865            # Extra M4 quote needed to protect [] in grep expression.
24866            FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24867            if test "x$FOUND_CORRECT_VERSION" = x; then
24868              { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24869$as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24870              { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24871$as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24872              BOOT_JDK_FOUND=no
24873            else
24874              # We're done! :-)
24875              BOOT_JDK_FOUND=yes
24876
24877  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24878
24879  # Input might be given as Windows format, start by converting to
24880  # unix format.
24881  path="$BOOT_JDK"
24882  new_path=`$CYGPATH -u "$path"`
24883
24884  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24885  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24886  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24887  # "foo.exe" is OK but "foo" is an error.
24888  #
24889  # This test is therefore slightly more accurate than "test -f" to check for file precense.
24890  # It is also a way to make sure we got the proper file name for the real test later on.
24891  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24892  if test "x$test_shortpath" = x; then
24893    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24894$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24895    as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24896  fi
24897
24898  # Call helper function which possibly converts this using DOS-style short mode.
24899  # If so, the updated path is stored in $new_path.
24900
24901  input_path="$new_path"
24902  # Check if we need to convert this using DOS-style short mode. If the path
24903  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24904  # take no chances and rewrite it.
24905  # Note: m4 eats our [], so we need to use [ and ] instead.
24906  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24907  if test "x$has_forbidden_chars" != x; then
24908    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24909    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24910    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24911    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24912      # Going to short mode and back again did indeed matter. Since short mode is
24913      # case insensitive, let's make it lowercase to improve readability.
24914      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24915      # Now convert it back to Unix-stile (cygpath)
24916      input_path=`$CYGPATH -u "$shortmode_path"`
24917      new_path="$input_path"
24918    fi
24919  fi
24920
24921  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24922  if test "x$test_cygdrive_prefix" = x; then
24923    # As a simple fix, exclude /usr/bin since it's not a real path.
24924    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24925      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24926      # a path prefixed by /cygdrive for fixpath to work.
24927      new_path="$CYGWIN_ROOT_PATH$input_path"
24928    fi
24929  fi
24930
24931
24932  if test "x$path" != "x$new_path"; then
24933    BOOT_JDK="$new_path"
24934    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24935$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24936  fi
24937
24938  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24939
24940  path="$BOOT_JDK"
24941  has_colon=`$ECHO $path | $GREP ^.:`
24942  new_path="$path"
24943  if test "x$has_colon" = x; then
24944    # Not in mixed or Windows style, start by that.
24945    new_path=`cmd //c echo $path`
24946  fi
24947
24948
24949  input_path="$new_path"
24950  # Check if we need to convert this using DOS-style short mode. If the path
24951  # contains just simple characters, use it. Otherwise (spaces, weird characters),
24952  # take no chances and rewrite it.
24953  # Note: m4 eats our [], so we need to use [ and ] instead.
24954  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24955  if test "x$has_forbidden_chars" != x; then
24956    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24957    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24958  fi
24959
24960
24961  windows_path="$new_path"
24962  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24963    unix_path=`$CYGPATH -u "$windows_path"`
24964    new_path="$unix_path"
24965  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24966    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24967    new_path="$unix_path"
24968  fi
24969
24970  if test "x$path" != "x$new_path"; then
24971    BOOT_JDK="$new_path"
24972    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24973$as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24974  fi
24975
24976  # Save the first 10 bytes of this path to the storage, so fixpath can work.
24977  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24978
24979  else
24980    # We're on a posix platform. Hooray! :)
24981    path="$BOOT_JDK"
24982    has_space=`$ECHO "$path" | $GREP " "`
24983    if test "x$has_space" != x; then
24984      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24985$as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24986      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24987    fi
24988
24989    # Use eval to expand a potential ~
24990    eval path="$path"
24991    if test ! -f "$path" && test ! -d "$path"; then
24992      as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24993    fi
24994
24995    BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24996  fi
24997
24998              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24999$as_echo_n "checking for Boot JDK... " >&6; }
25000              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25001$as_echo "$BOOT_JDK" >&6; }
25002              { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25003$as_echo_n "checking Boot JDK version... " >&6; }
25004              BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25005              { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25006$as_echo "$BOOT_JDK_VERSION" >&6; }
25007            fi # end check jdk version
25008          fi # end check rt.jar
25009        fi # end check javac
25010      fi # end check java
25011    fi # end check boot jdk found
25012  fi
25013
25014
25015  # If we haven't found anything yet, we've truly lost. Give up.
25016  if test "x$BOOT_JDK_FOUND" = xno; then
25017
25018  # Print a helpful message on how to acquire the necessary build dependency.
25019  # openjdk is the help tag: freetype, cups, pulse, alsa etc
25020  MISSING_DEPENDENCY=openjdk
25021
25022  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25023    cygwin_help $MISSING_DEPENDENCY
25024  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25025    msys_help $MISSING_DEPENDENCY
25026  else
25027    PKGHANDLER_COMMAND=
25028
25029    case $PKGHANDLER in
25030      apt-get)
25031        apt_help     $MISSING_DEPENDENCY ;;
25032      yum)
25033        yum_help     $MISSING_DEPENDENCY ;;
25034      port)
25035        port_help    $MISSING_DEPENDENCY ;;
25036      pkgutil)
25037        pkgutil_help $MISSING_DEPENDENCY ;;
25038      pkgadd)
25039        pkgadd_help  $MISSING_DEPENDENCY ;;
25040    esac
25041
25042    if test "x$PKGHANDLER_COMMAND" != x; then
25043      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
25044    fi
25045  fi
25046
25047    { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5
25048$as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;}
25049    { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5
25050$as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25051    as_fn_error $? "Cannot continue" "$LINENO" 5
25052  fi
25053
25054  # Setup proper paths for what we found
25055  BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar"
25056  if test ! -f "$BOOT_RTJAR"; then
25057    # On MacOSX it is called classes.jar
25058    BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar"
25059    if test -f "$BOOT_RTJAR"; then
25060      # Remove the ..
25061      BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}"
25062    fi
25063  fi
25064  BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar"
25065  BOOT_JDK="$BOOT_JDK"
25066
25067
25068
25069
25070  # Setup tools from the Boot JDK.
25071
25072  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25073
25074  # Publish this variable in the help.
25075
25076
25077  if test "x$JAVA" = x; then
25078    # The variable is not set by user, try to locate tool using the code snippet
25079
25080      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25081$as_echo_n "checking for java in Boot JDK... " >&6; }
25082      JAVA=$BOOT_JDK/bin/java
25083      if test ! -x $JAVA; then
25084        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25085$as_echo "not found" >&6; }
25086        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25087$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25088        as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25089      fi
25090      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25091$as_echo "ok" >&6; }
25092
25093
25094  else
25095    # The variable is set, but is it from the command line or the environment?
25096
25097    # Try to remove the string !JAVA! from our list.
25098    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/}
25099    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25100      # If it failed, the variable was not from the command line. Ignore it,
25101      # but warn the user (except for BASH, which is always set by the calling BASH).
25102      if test "xJAVA" != xBASH; then
25103        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5
25104$as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;}
25105      fi
25106      # Try to locate tool using the code snippet
25107
25108      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25109$as_echo_n "checking for java in Boot JDK... " >&6; }
25110      JAVA=$BOOT_JDK/bin/java
25111      if test ! -x $JAVA; then
25112        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25113$as_echo "not found" >&6; }
25114        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25115$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25116        as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25117      fi
25118      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25119$as_echo "ok" >&6; }
25120
25121
25122    else
25123      # If it succeeded, then it was overridden by the user. We will use it
25124      # for the tool.
25125
25126      # First remove it from the list of overridden variables, so we can test
25127      # for unknown variables in the end.
25128      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25129
25130      # Check if the provided tool contains a complete path.
25131      tool_specified="$JAVA"
25132      tool_basename="${tool_specified##*/}"
25133      if test "x$tool_basename" = "x$tool_specified"; then
25134        # A command without a complete path is provided, search $PATH.
25135        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5
25136$as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;}
25137        # Extract the first word of "$tool_basename", so it can be a program name with args.
25138set dummy $tool_basename; ac_word=$2
25139{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25140$as_echo_n "checking for $ac_word... " >&6; }
25141if ${ac_cv_path_JAVA+:} false; then :
25142  $as_echo_n "(cached) " >&6
25143else
25144  case $JAVA in
25145  [\\/]* | ?:[\\/]*)
25146  ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path.
25147  ;;
25148  *)
25149  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25150for as_dir in $PATH
25151do
25152  IFS=$as_save_IFS
25153  test -z "$as_dir" && as_dir=.
25154    for ac_exec_ext in '' $ac_executable_extensions; do
25155  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25156    ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext"
25157    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25158    break 2
25159  fi
25160done
25161  done
25162IFS=$as_save_IFS
25163
25164  ;;
25165esac
25166fi
25167JAVA=$ac_cv_path_JAVA
25168if test -n "$JAVA"; then
25169  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5
25170$as_echo "$JAVA" >&6; }
25171else
25172  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25173$as_echo "no" >&6; }
25174fi
25175
25176
25177        if test "x$JAVA" = x; then
25178          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25179        fi
25180      else
25181        # Otherwise we believe it is a complete path. Use it as it is.
25182        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5
25183$as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;}
25184        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5
25185$as_echo_n "checking for JAVA... " >&6; }
25186        if test ! -x "$tool_specified"; then
25187          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25188$as_echo "not found" >&6; }
25189          as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5
25190        fi
25191        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25192$as_echo "$tool_specified" >&6; }
25193      fi
25194    fi
25195  fi
25196
25197
25198
25199  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25200
25201  # Publish this variable in the help.
25202
25203
25204  if test "x$JAVAC" = x; then
25205    # The variable is not set by user, try to locate tool using the code snippet
25206
25207      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25208$as_echo_n "checking for javac in Boot JDK... " >&6; }
25209      JAVAC=$BOOT_JDK/bin/javac
25210      if test ! -x $JAVAC; then
25211        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25212$as_echo "not found" >&6; }
25213        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25214$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25215        as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25216      fi
25217      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25218$as_echo "ok" >&6; }
25219
25220
25221  else
25222    # The variable is set, but is it from the command line or the environment?
25223
25224    # Try to remove the string !JAVAC! from our list.
25225    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/}
25226    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25227      # If it failed, the variable was not from the command line. Ignore it,
25228      # but warn the user (except for BASH, which is always set by the calling BASH).
25229      if test "xJAVAC" != xBASH; then
25230        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5
25231$as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;}
25232      fi
25233      # Try to locate tool using the code snippet
25234
25235      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25236$as_echo_n "checking for javac in Boot JDK... " >&6; }
25237      JAVAC=$BOOT_JDK/bin/javac
25238      if test ! -x $JAVAC; then
25239        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25240$as_echo "not found" >&6; }
25241        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25242$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25243        as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25244      fi
25245      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25246$as_echo "ok" >&6; }
25247
25248
25249    else
25250      # If it succeeded, then it was overridden by the user. We will use it
25251      # for the tool.
25252
25253      # First remove it from the list of overridden variables, so we can test
25254      # for unknown variables in the end.
25255      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25256
25257      # Check if the provided tool contains a complete path.
25258      tool_specified="$JAVAC"
25259      tool_basename="${tool_specified##*/}"
25260      if test "x$tool_basename" = "x$tool_specified"; then
25261        # A command without a complete path is provided, search $PATH.
25262        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5
25263$as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;}
25264        # Extract the first word of "$tool_basename", so it can be a program name with args.
25265set dummy $tool_basename; ac_word=$2
25266{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25267$as_echo_n "checking for $ac_word... " >&6; }
25268if ${ac_cv_path_JAVAC+:} false; then :
25269  $as_echo_n "(cached) " >&6
25270else
25271  case $JAVAC in
25272  [\\/]* | ?:[\\/]*)
25273  ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path.
25274  ;;
25275  *)
25276  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25277for as_dir in $PATH
25278do
25279  IFS=$as_save_IFS
25280  test -z "$as_dir" && as_dir=.
25281    for ac_exec_ext in '' $ac_executable_extensions; do
25282  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25283    ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext"
25284    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25285    break 2
25286  fi
25287done
25288  done
25289IFS=$as_save_IFS
25290
25291  ;;
25292esac
25293fi
25294JAVAC=$ac_cv_path_JAVAC
25295if test -n "$JAVAC"; then
25296  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5
25297$as_echo "$JAVAC" >&6; }
25298else
25299  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25300$as_echo "no" >&6; }
25301fi
25302
25303
25304        if test "x$JAVAC" = x; then
25305          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25306        fi
25307      else
25308        # Otherwise we believe it is a complete path. Use it as it is.
25309        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5
25310$as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;}
25311        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5
25312$as_echo_n "checking for JAVAC... " >&6; }
25313        if test ! -x "$tool_specified"; then
25314          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25315$as_echo "not found" >&6; }
25316          as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5
25317        fi
25318        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25319$as_echo "$tool_specified" >&6; }
25320      fi
25321    fi
25322  fi
25323
25324
25325
25326  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25327
25328  # Publish this variable in the help.
25329
25330
25331  if test "x$JAVAH" = x; then
25332    # The variable is not set by user, try to locate tool using the code snippet
25333
25334      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25335$as_echo_n "checking for javah in Boot JDK... " >&6; }
25336      JAVAH=$BOOT_JDK/bin/javah
25337      if test ! -x $JAVAH; then
25338        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25339$as_echo "not found" >&6; }
25340        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25341$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25342        as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25343      fi
25344      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25345$as_echo "ok" >&6; }
25346
25347
25348  else
25349    # The variable is set, but is it from the command line or the environment?
25350
25351    # Try to remove the string !JAVAH! from our list.
25352    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/}
25353    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25354      # If it failed, the variable was not from the command line. Ignore it,
25355      # but warn the user (except for BASH, which is always set by the calling BASH).
25356      if test "xJAVAH" != xBASH; then
25357        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5
25358$as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;}
25359      fi
25360      # Try to locate tool using the code snippet
25361
25362      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25363$as_echo_n "checking for javah in Boot JDK... " >&6; }
25364      JAVAH=$BOOT_JDK/bin/javah
25365      if test ! -x $JAVAH; then
25366        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25367$as_echo "not found" >&6; }
25368        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25369$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25370        as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25371      fi
25372      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25373$as_echo "ok" >&6; }
25374
25375
25376    else
25377      # If it succeeded, then it was overridden by the user. We will use it
25378      # for the tool.
25379
25380      # First remove it from the list of overridden variables, so we can test
25381      # for unknown variables in the end.
25382      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25383
25384      # Check if the provided tool contains a complete path.
25385      tool_specified="$JAVAH"
25386      tool_basename="${tool_specified##*/}"
25387      if test "x$tool_basename" = "x$tool_specified"; then
25388        # A command without a complete path is provided, search $PATH.
25389        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5
25390$as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;}
25391        # Extract the first word of "$tool_basename", so it can be a program name with args.
25392set dummy $tool_basename; ac_word=$2
25393{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25394$as_echo_n "checking for $ac_word... " >&6; }
25395if ${ac_cv_path_JAVAH+:} false; then :
25396  $as_echo_n "(cached) " >&6
25397else
25398  case $JAVAH in
25399  [\\/]* | ?:[\\/]*)
25400  ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path.
25401  ;;
25402  *)
25403  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25404for as_dir in $PATH
25405do
25406  IFS=$as_save_IFS
25407  test -z "$as_dir" && as_dir=.
25408    for ac_exec_ext in '' $ac_executable_extensions; do
25409  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25410    ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext"
25411    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25412    break 2
25413  fi
25414done
25415  done
25416IFS=$as_save_IFS
25417
25418  ;;
25419esac
25420fi
25421JAVAH=$ac_cv_path_JAVAH
25422if test -n "$JAVAH"; then
25423  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5
25424$as_echo "$JAVAH" >&6; }
25425else
25426  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25427$as_echo "no" >&6; }
25428fi
25429
25430
25431        if test "x$JAVAH" = x; then
25432          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25433        fi
25434      else
25435        # Otherwise we believe it is a complete path. Use it as it is.
25436        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5
25437$as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;}
25438        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5
25439$as_echo_n "checking for JAVAH... " >&6; }
25440        if test ! -x "$tool_specified"; then
25441          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25442$as_echo "not found" >&6; }
25443          as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5
25444        fi
25445        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25446$as_echo "$tool_specified" >&6; }
25447      fi
25448    fi
25449  fi
25450
25451
25452
25453  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25454
25455  # Publish this variable in the help.
25456
25457
25458  if test "x$JAR" = x; then
25459    # The variable is not set by user, try to locate tool using the code snippet
25460
25461      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25462$as_echo_n "checking for jar in Boot JDK... " >&6; }
25463      JAR=$BOOT_JDK/bin/jar
25464      if test ! -x $JAR; then
25465        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25466$as_echo "not found" >&6; }
25467        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25468$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25469        as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25470      fi
25471      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25472$as_echo "ok" >&6; }
25473
25474
25475  else
25476    # The variable is set, but is it from the command line or the environment?
25477
25478    # Try to remove the string !JAR! from our list.
25479    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/}
25480    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25481      # If it failed, the variable was not from the command line. Ignore it,
25482      # but warn the user (except for BASH, which is always set by the calling BASH).
25483      if test "xJAR" != xBASH; then
25484        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5
25485$as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;}
25486      fi
25487      # Try to locate tool using the code snippet
25488
25489      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25490$as_echo_n "checking for jar in Boot JDK... " >&6; }
25491      JAR=$BOOT_JDK/bin/jar
25492      if test ! -x $JAR; then
25493        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25494$as_echo "not found" >&6; }
25495        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25496$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25497        as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25498      fi
25499      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25500$as_echo "ok" >&6; }
25501
25502
25503    else
25504      # If it succeeded, then it was overridden by the user. We will use it
25505      # for the tool.
25506
25507      # First remove it from the list of overridden variables, so we can test
25508      # for unknown variables in the end.
25509      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25510
25511      # Check if the provided tool contains a complete path.
25512      tool_specified="$JAR"
25513      tool_basename="${tool_specified##*/}"
25514      if test "x$tool_basename" = "x$tool_specified"; then
25515        # A command without a complete path is provided, search $PATH.
25516        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5
25517$as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;}
25518        # Extract the first word of "$tool_basename", so it can be a program name with args.
25519set dummy $tool_basename; ac_word=$2
25520{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25521$as_echo_n "checking for $ac_word... " >&6; }
25522if ${ac_cv_path_JAR+:} false; then :
25523  $as_echo_n "(cached) " >&6
25524else
25525  case $JAR in
25526  [\\/]* | ?:[\\/]*)
25527  ac_cv_path_JAR="$JAR" # Let the user override the test with a path.
25528  ;;
25529  *)
25530  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25531for as_dir in $PATH
25532do
25533  IFS=$as_save_IFS
25534  test -z "$as_dir" && as_dir=.
25535    for ac_exec_ext in '' $ac_executable_extensions; do
25536  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25537    ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext"
25538    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25539    break 2
25540  fi
25541done
25542  done
25543IFS=$as_save_IFS
25544
25545  ;;
25546esac
25547fi
25548JAR=$ac_cv_path_JAR
25549if test -n "$JAR"; then
25550  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5
25551$as_echo "$JAR" >&6; }
25552else
25553  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25554$as_echo "no" >&6; }
25555fi
25556
25557
25558        if test "x$JAR" = x; then
25559          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25560        fi
25561      else
25562        # Otherwise we believe it is a complete path. Use it as it is.
25563        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5
25564$as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;}
25565        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5
25566$as_echo_n "checking for JAR... " >&6; }
25567        if test ! -x "$tool_specified"; then
25568          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25569$as_echo "not found" >&6; }
25570          as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5
25571        fi
25572        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25573$as_echo "$tool_specified" >&6; }
25574      fi
25575    fi
25576  fi
25577
25578
25579
25580  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25581
25582  # Publish this variable in the help.
25583
25584
25585  if test "x$NATIVE2ASCII" = x; then
25586    # The variable is not set by user, try to locate tool using the code snippet
25587
25588      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25589$as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25590      NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25591      if test ! -x $NATIVE2ASCII; then
25592        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25593$as_echo "not found" >&6; }
25594        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25595$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25596        as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25597      fi
25598      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25599$as_echo "ok" >&6; }
25600
25601
25602  else
25603    # The variable is set, but is it from the command line or the environment?
25604
25605    # Try to remove the string !NATIVE2ASCII! from our list.
25606    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NATIVE2ASCII!/}
25607    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25608      # If it failed, the variable was not from the command line. Ignore it,
25609      # but warn the user (except for BASH, which is always set by the calling BASH).
25610      if test "xNATIVE2ASCII" != xBASH; then
25611        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&5
25612$as_echo "$as_me: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&2;}
25613      fi
25614      # Try to locate tool using the code snippet
25615
25616      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25617$as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25618      NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25619      if test ! -x $NATIVE2ASCII; then
25620        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25621$as_echo "not found" >&6; }
25622        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25623$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25624        as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25625      fi
25626      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25627$as_echo "ok" >&6; }
25628
25629
25630    else
25631      # If it succeeded, then it was overridden by the user. We will use it
25632      # for the tool.
25633
25634      # First remove it from the list of overridden variables, so we can test
25635      # for unknown variables in the end.
25636      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25637
25638      # Check if the provided tool contains a complete path.
25639      tool_specified="$NATIVE2ASCII"
25640      tool_basename="${tool_specified##*/}"
25641      if test "x$tool_basename" = "x$tool_specified"; then
25642        # A command without a complete path is provided, search $PATH.
25643        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&5
25644$as_echo "$as_me: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&6;}
25645        # Extract the first word of "$tool_basename", so it can be a program name with args.
25646set dummy $tool_basename; ac_word=$2
25647{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25648$as_echo_n "checking for $ac_word... " >&6; }
25649if ${ac_cv_path_NATIVE2ASCII+:} false; then :
25650  $as_echo_n "(cached) " >&6
25651else
25652  case $NATIVE2ASCII in
25653  [\\/]* | ?:[\\/]*)
25654  ac_cv_path_NATIVE2ASCII="$NATIVE2ASCII" # Let the user override the test with a path.
25655  ;;
25656  *)
25657  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25658for as_dir in $PATH
25659do
25660  IFS=$as_save_IFS
25661  test -z "$as_dir" && as_dir=.
25662    for ac_exec_ext in '' $ac_executable_extensions; do
25663  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25664    ac_cv_path_NATIVE2ASCII="$as_dir/$ac_word$ac_exec_ext"
25665    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25666    break 2
25667  fi
25668done
25669  done
25670IFS=$as_save_IFS
25671
25672  ;;
25673esac
25674fi
25675NATIVE2ASCII=$ac_cv_path_NATIVE2ASCII
25676if test -n "$NATIVE2ASCII"; then
25677  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE2ASCII" >&5
25678$as_echo "$NATIVE2ASCII" >&6; }
25679else
25680  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25681$as_echo "no" >&6; }
25682fi
25683
25684
25685        if test "x$NATIVE2ASCII" = x; then
25686          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25687        fi
25688      else
25689        # Otherwise we believe it is a complete path. Use it as it is.
25690        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&5
25691$as_echo "$as_me: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&6;}
25692        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NATIVE2ASCII" >&5
25693$as_echo_n "checking for NATIVE2ASCII... " >&6; }
25694        if test ! -x "$tool_specified"; then
25695          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25696$as_echo "not found" >&6; }
25697          as_fn_error $? "User supplied tool NATIVE2ASCII=$tool_specified does not exist or is not executable" "$LINENO" 5
25698        fi
25699        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25700$as_echo "$tool_specified" >&6; }
25701      fi
25702    fi
25703  fi
25704
25705
25706
25707  # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25708
25709  # Publish this variable in the help.
25710
25711
25712  if test "x$JARSIGNER" = x; then
25713    # The variable is not set by user, try to locate tool using the code snippet
25714
25715      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25716$as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25717      JARSIGNER=$BOOT_JDK/bin/jarsigner
25718      if test ! -x $JARSIGNER; then
25719        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25720$as_echo "not found" >&6; }
25721        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25722$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25723        as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25724      fi
25725      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25726$as_echo "ok" >&6; }
25727
25728
25729  else
25730    # The variable is set, but is it from the command line or the environment?
25731
25732    # Try to remove the string !JARSIGNER! from our list.
25733    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/}
25734    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25735      # If it failed, the variable was not from the command line. Ignore it,
25736      # but warn the user (except for BASH, which is always set by the calling BASH).
25737      if test "xJARSIGNER" != xBASH; then
25738        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5
25739$as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;}
25740      fi
25741      # Try to locate tool using the code snippet
25742
25743      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25744$as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25745      JARSIGNER=$BOOT_JDK/bin/jarsigner
25746      if test ! -x $JARSIGNER; then
25747        { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25748$as_echo "not found" >&6; }
25749        { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25750$as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25751        as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25752      fi
25753      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25754$as_echo "ok" >&6; }
25755
25756
25757    else
25758      # If it succeeded, then it was overridden by the user. We will use it
25759      # for the tool.
25760
25761      # First remove it from the list of overridden variables, so we can test
25762      # for unknown variables in the end.
25763      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25764
25765      # Check if the provided tool contains a complete path.
25766      tool_specified="$JARSIGNER"
25767      tool_basename="${tool_specified##*/}"
25768      if test "x$tool_basename" = "x$tool_specified"; then
25769        # A command without a complete path is provided, search $PATH.
25770        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5
25771$as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;}
25772        # Extract the first word of "$tool_basename", so it can be a program name with args.
25773set dummy $tool_basename; ac_word=$2
25774{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25775$as_echo_n "checking for $ac_word... " >&6; }
25776if ${ac_cv_path_JARSIGNER+:} false; then :
25777  $as_echo_n "(cached) " >&6
25778else
25779  case $JARSIGNER in
25780  [\\/]* | ?:[\\/]*)
25781  ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path.
25782  ;;
25783  *)
25784  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25785for as_dir in $PATH
25786do
25787  IFS=$as_save_IFS
25788  test -z "$as_dir" && as_dir=.
25789    for ac_exec_ext in '' $ac_executable_extensions; do
25790  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25791    ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext"
25792    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25793    break 2
25794  fi
25795done
25796  done
25797IFS=$as_save_IFS
25798
25799  ;;
25800esac
25801fi
25802JARSIGNER=$ac_cv_path_JARSIGNER
25803if test -n "$JARSIGNER"; then
25804  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5
25805$as_echo "$JARSIGNER" >&6; }
25806else
25807  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25808$as_echo "no" >&6; }
25809fi
25810
25811
25812        if test "x$JARSIGNER" = x; then
25813          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25814        fi
25815      else
25816        # Otherwise we believe it is a complete path. Use it as it is.
25817        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5
25818$as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;}
25819        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5
25820$as_echo_n "checking for JARSIGNER... " >&6; }
25821        if test ! -x "$tool_specified"; then
25822          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25823$as_echo "not found" >&6; }
25824          as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5
25825        fi
25826        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25827$as_echo "$tool_specified" >&6; }
25828      fi
25829    fi
25830  fi
25831
25832
25833
25834  # Finally, set some other options...
25835
25836  # When compiling code to be executed by the Boot JDK, force jdk7 compatibility.
25837  BOOT_JDK_SOURCETARGET="-source 7 -target 7"
25838
25839
25840
25841
25842  ##############################################################################
25843  #
25844  # Specify options for anything that is run with the Boot JDK.
25845  #
25846
25847# Check whether --with-boot-jdk-jvmargs was given.
25848if test "${with_boot_jdk_jvmargs+set}" = set; then :
25849  withval=$with_boot_jdk_jvmargs;
25850fi
25851
25852
25853  if test "x$with_boot_jdk_jvmargs" = x; then
25854    # Not all JVM:s accept the same arguments on the command line.
25855    # OpenJDK specific increase in thread stack for JDK build,
25856    # well more specifically, when running javac.
25857    if test "x$BUILD_NUM_BITS" = x32; then
25858      STACK_SIZE=768
25859    else
25860      # Running Javac on a JVM on a 64-bit machine, the stack takes more space
25861      # since 64-bit pointers are pushed on the stach. Apparently, we need
25862      # to increase the stack space when javacing the JDK....
25863      STACK_SIZE=1536
25864    fi
25865
25866    # Minimum amount of heap memory.
25867
25868  $ECHO "Check if jvm arg is ok: -Xms64M" >&5
25869  $ECHO "Command: $JAVA -Xms64M -version" >&5
25870  OUTPUT=`$JAVA -Xms64M -version 2>&1`
25871  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25872  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25873  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25874    boot_jdk_jvmargs="$boot_jdk_jvmargs -Xms64M"
25875    JVM_ARG_OK=true
25876  else
25877    $ECHO "Arg failed:" >&5
25878    $ECHO "$OUTPUT" >&5
25879    JVM_ARG_OK=false
25880  fi
25881
25882    if test "x$OPENJDK_TARGET_OS" = "xmacosx" || test "x$OPENJDK_TARGET_CPU" = "xppc64" ; then
25883      # Why does macosx need more heap? Its the huge JDK batch.
25884
25885  $ECHO "Check if jvm arg is ok: -Xmx1600M" >&5
25886  $ECHO "Command: $JAVA -Xmx1600M -version" >&5
25887  OUTPUT=`$JAVA -Xmx1600M -version 2>&1`
25888  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25889  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25890  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25891    boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1600M"
25892    JVM_ARG_OK=true
25893  else
25894    $ECHO "Arg failed:" >&5
25895    $ECHO "$OUTPUT" >&5
25896    JVM_ARG_OK=false
25897  fi
25898
25899    else
25900
25901  $ECHO "Check if jvm arg is ok: -Xmx1100M" >&5
25902  $ECHO "Command: $JAVA -Xmx1100M -version" >&5
25903  OUTPUT=`$JAVA -Xmx1100M -version 2>&1`
25904  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25905  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25906  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25907    boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1100M"
25908    JVM_ARG_OK=true
25909  else
25910    $ECHO "Arg failed:" >&5
25911    $ECHO "$OUTPUT" >&5
25912    JVM_ARG_OK=false
25913  fi
25914
25915    fi
25916    # When is adding -client something that speeds up the JVM?
25917    # ADD_JVM_ARG_IF_OK([-client],boot_jdk_jvmargs,[$JAVA])
25918
25919  $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5
25920  $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5
25921  OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1`
25922  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25923  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25924  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25925    boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:ThreadStackSize=$STACK_SIZE"
25926    JVM_ARG_OK=true
25927  else
25928    $ECHO "Arg failed:" >&5
25929    $ECHO "$OUTPUT" >&5
25930    JVM_ARG_OK=false
25931  fi
25932
25933    # Disable special log output when a debug build is used as Boot JDK...
25934
25935  $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5
25936  $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5
25937  OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1`
25938  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25939  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25940  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25941    boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput"
25942    JVM_ARG_OK=true
25943  else
25944    $ECHO "Arg failed:" >&5
25945    $ECHO "$OUTPUT" >&5
25946    JVM_ARG_OK=false
25947  fi
25948
25949  fi
25950
25951  BOOT_JDK_JVMARGS=$boot_jdk_jvmargs
25952
25953
25954
25955###############################################################################
25956#
25957# Configure the sources to use. We can add or override individual directories.
25958#
25959###############################################################################
25960
25961
25962  # Where are the sources. Any of these can be overridden
25963  # using --with-override-corba and the likes.
25964  LANGTOOLS_TOPDIR="$SRC_ROOT/langtools"
25965  CORBA_TOPDIR="$SRC_ROOT/corba"
25966  JAXP_TOPDIR="$SRC_ROOT/jaxp"
25967  JAXWS_TOPDIR="$SRC_ROOT/jaxws"
25968  HOTSPOT_TOPDIR="$SRC_ROOT/hotspot"
25969  NASHORN_TOPDIR="$SRC_ROOT/nashorn"
25970  JDK_TOPDIR="$SRC_ROOT/jdk"
25971
25972
25973
25974
25975
25976
25977
25978
25979
25980
25981  ###############################################################################
25982  #
25983  # Pickup additional source for a component from outside of the source root
25984  # or override source for a component.
25985  #
25986
25987# Check whether --with-add-source-root was given.
25988if test "${with_add_source_root+set}" = set; then :
25989  withval=$with_add_source_root;
25990fi
25991
25992
25993
25994# Check whether --with-override-source-root was given.
25995if test "${with_override_source_root+set}" = set; then :
25996  withval=$with_override_source_root;
25997fi
25998
25999
26000
26001# Check whether --with-adds-and-overrides was given.
26002if test "${with_adds_and_overrides+set}" = set; then :
26003  withval=$with_adds_and_overrides;
26004fi
26005
26006
26007  if test "x$with_adds_and_overrides" != x; then
26008    with_add_source_root="$with_adds_and_overrides/adds"
26009    with_override_source_root="$with_adds_and_overrides/overrides"
26010  fi
26011
26012  if test "x$with_add_source_root" != x; then
26013    if ! test -d $with_add_source_root; then
26014      as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5
26015    fi
26016    CURDIR="$PWD"
26017    cd "$with_add_source_root"
26018    ADD_SRC_ROOT="`pwd`"
26019    cd "$CURDIR"
26020    # Verify that the addon source root does not have any root makefiles.
26021    # If it does, then it is usually an error, prevent this.
26022    if test -f $with_add_source_root/langtools/make/Makefile; then
26023      as_fn_error $? "Your add source root seems to contain a full langtools repo! An add source root should only contain additional sources." "$LINENO" 5
26024    fi
26025    if test -f $with_add_source_root/corba/make/Makefile; then
26026      as_fn_error $? "Your add source root seems to contain a full corba repo! An add source root should only contain additional sources." "$LINENO" 5
26027    fi
26028    if test -f $with_add_source_root/jaxp/make/Makefile; then
26029      as_fn_error $? "Your add source root seems to contain a full jaxp repo! An add source root should only contain additional sources." "$LINENO" 5
26030    fi
26031    if test -f $with_add_source_root/jaxws/make/Makefile; then
26032      as_fn_error $? "Your add source root seems to contain a full jaxws repo! An add source root should only contain additional sources." "$LINENO" 5
26033    fi
26034    if test -f $with_add_source_root/hotspot/make/Makefile; then
26035      as_fn_error $? "Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources." "$LINENO" 5
26036    fi
26037    if test -f $with_add_source_root/nashorn/make/Makefile; then
26038      as_fn_error $? "Your add source root seems to contain a full nashorn repo! An add source root should only contain additional sources." "$LINENO" 5
26039    fi
26040    if test -f $with_add_source_root/jdk/make/Makefile; then
26041      as_fn_error $? "Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources." "$LINENO" 5
26042    fi
26043  fi
26044
26045
26046  if test "x$with_override_source_root" != x; then
26047    if ! test -d $with_override_source_root; then
26048      as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5
26049    fi
26050    CURDIR="$PWD"
26051    cd "$with_override_source_root"
26052    OVERRIDE_SRC_ROOT="`pwd`"
26053    cd "$CURDIR"
26054    if test -f $with_override_source_root/langtools/make/Makefile; then
26055      as_fn_error $? "Your override source root seems to contain a full langtools repo! An override source root should only contain sources that override." "$LINENO" 5
26056    fi
26057    if test -f $with_override_source_root/corba/make/Makefile; then
26058      as_fn_error $? "Your override source root seems to contain a full corba repo! An override source root should only contain sources that override." "$LINENO" 5
26059    fi
26060    if test -f $with_override_source_root/jaxp/make/Makefile; then
26061      as_fn_error $? "Your override source root seems to contain a full jaxp repo! An override source root should only contain sources that override." "$LINENO" 5
26062    fi
26063    if test -f $with_override_source_root/jaxws/make/Makefile; then
26064      as_fn_error $? "Your override source root seems to contain a full jaxws repo! An override source root should only contain sources that override." "$LINENO" 5
26065    fi
26066    if test -f $with_override_source_root/hotspot/make/Makefile; then
26067      as_fn_error $? "Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override." "$LINENO" 5
26068    fi
26069    if test -f $with_override_source_root/nashorn/make/Makefile; then
26070      as_fn_error $? "Your override source root seems to contain a full nashorn repo! An override source root should only contain sources that override." "$LINENO" 5
26071    fi
26072    if test -f $with_override_source_root/jdk/make/Makefile; then
26073      as_fn_error $? "Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override." "$LINENO" 5
26074    fi
26075  fi
26076
26077
26078  ###############################################################################
26079  #
26080  # Override a repo completely, this is used for example when you have 3 small
26081  # development sandboxes of the langtools sources and want to avoid having 3 full
26082  # OpenJDK sources checked out on disk.
26083  #
26084  # Assuming that the 3 langtools sandboxes are located here:
26085  # /home/fredrik/sandbox1/langtools
26086  # /home/fredrik/sandbox2/langtools
26087  # /home/fredrik/sandbox3/langtools
26088  #
26089  # From the source root you create build subdirs manually:
26090  #     mkdir -p build1 build2 build3
26091  # in each build directory run:
26092  #     (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make)
26093  #     (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make)
26094  #     (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make)
26095  #
26096
26097
26098# Check whether --with-override-langtools was given.
26099if test "${with_override_langtools+set}" = set; then :
26100  withval=$with_override_langtools;
26101fi
26102
26103
26104
26105# Check whether --with-override-corba was given.
26106if test "${with_override_corba+set}" = set; then :
26107  withval=$with_override_corba;
26108fi
26109
26110
26111
26112# Check whether --with-override-jaxp was given.
26113if test "${with_override_jaxp+set}" = set; then :
26114  withval=$with_override_jaxp;
26115fi
26116
26117
26118
26119# Check whether --with-override-jaxws was given.
26120if test "${with_override_jaxws+set}" = set; then :
26121  withval=$with_override_jaxws;
26122fi
26123
26124
26125
26126# Check whether --with-override-hotspot was given.
26127if test "${with_override_hotspot+set}" = set; then :
26128  withval=$with_override_hotspot;
26129fi
26130
26131
26132
26133# Check whether --with-override-nashorn was given.
26134if test "${with_override_nashorn+set}" = set; then :
26135  withval=$with_override_nashorn;
26136fi
26137
26138
26139
26140# Check whether --with-override-jdk was given.
26141if test "${with_override_jdk+set}" = set; then :
26142  withval=$with_override_jdk;
26143fi
26144
26145
26146  if test "x$with_override_langtools" != x; then
26147    CURDIR="$PWD"
26148    cd "$with_override_langtools"
26149    LANGTOOLS_TOPDIR="`pwd`"
26150    cd "$CURDIR"
26151    if ! test -f $LANGTOOLS_TOPDIR/make/Makefile; then
26152      as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5
26153    fi
26154    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5
26155$as_echo_n "checking if langtools should be overridden... " >&6; }
26156    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5
26157$as_echo "yes with $LANGTOOLS_TOPDIR" >&6; }
26158  fi
26159  if test "x$with_override_corba" != x; then
26160    CURDIR="$PWD"
26161    cd "$with_override_corba"
26162    CORBA_TOPDIR="`pwd`"
26163    cd "$CURDIR"
26164    if ! test -f $CORBA_TOPDIR/make/Makefile; then
26165      as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5
26166    fi
26167    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5
26168$as_echo_n "checking if corba should be overridden... " >&6; }
26169    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5
26170$as_echo "yes with $CORBA_TOPDIR" >&6; }
26171  fi
26172  if test "x$with_override_jaxp" != x; then
26173    CURDIR="$PWD"
26174    cd "$with_override_jaxp"
26175    JAXP_TOPDIR="`pwd`"
26176    cd "$CURDIR"
26177    if ! test -f $JAXP_TOPDIR/make/Makefile; then
26178      as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5
26179    fi
26180    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5
26181$as_echo_n "checking if jaxp should be overridden... " >&6; }
26182    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5
26183$as_echo "yes with $JAXP_TOPDIR" >&6; }
26184  fi
26185  if test "x$with_override_jaxws" != x; then
26186    CURDIR="$PWD"
26187    cd "$with_override_jaxws"
26188    JAXWS_TOPDIR="`pwd`"
26189    cd "$CURDIR"
26190    if ! test -f $JAXWS_TOPDIR/make/Makefile; then
26191      as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5
26192    fi
26193    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5
26194$as_echo_n "checking if jaxws should be overridden... " >&6; }
26195    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5
26196$as_echo "yes with $JAXWS_TOPDIR" >&6; }
26197  fi
26198  if test "x$with_override_hotspot" != x; then
26199    CURDIR="$PWD"
26200    cd "$with_override_hotspot"
26201    HOTSPOT_TOPDIR="`pwd`"
26202    cd "$CURDIR"
26203    if ! test -f $HOTSPOT_TOPDIR/make/Makefile; then
26204      as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5
26205    fi
26206    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5
26207$as_echo_n "checking if hotspot should be overridden... " >&6; }
26208    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5
26209$as_echo "yes with $HOTSPOT_TOPDIR" >&6; }
26210  fi
26211  if test "x$with_override_nashorn" != x; then
26212    CURDIR="$PWD"
26213    cd "$with_override_nashorn"
26214    NASHORN_TOPDIR="`pwd`"
26215    cd "$CURDIR"
26216    if ! test -f $NASHORN_TOPDIR/make/Makefile; then
26217      as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
26218    fi
26219    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
26220$as_echo_n "checking if nashorn should be overridden... " >&6; }
26221    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5
26222$as_echo "yes with $NASHORN_TOPDIR" >&6; }
26223  fi
26224  if test "x$with_override_jdk" != x; then
26225    CURDIR="$PWD"
26226    cd "$with_override_jdk"
26227    JDK_TOPDIR="`pwd`"
26228    cd "$CURDIR"
26229    if ! test -f $JDK_TOPDIR/make/Makefile; then
26230      as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5
26231    fi
26232    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5
26233$as_echo_n "checking if JDK should be overridden... " >&6; }
26234    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5
26235$as_echo "yes with $JDK_TOPDIR" >&6; }
26236  fi
26237
26238
26239  BUILD_OUTPUT="$OUTPUT_ROOT"
26240
26241
26242  HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist"
26243  BUILD_HOTSPOT=true
26244
26245
26246
26247# Check whether --with-import-hotspot was given.
26248if test "${with_import_hotspot+set}" = set; then :
26249  withval=$with_import_hotspot;
26250fi
26251
26252  if test "x$with_import_hotspot" != x; then
26253    CURDIR="$PWD"
26254    cd "$with_import_hotspot"
26255    HOTSPOT_DIST="`pwd`"
26256    cd "$CURDIR"
26257    if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then
26258      as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5
26259    fi
26260    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5
26261$as_echo_n "checking if hotspot should be imported... " >&6; }
26262    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5
26263$as_echo "yes from $HOTSPOT_DIST" >&6; }
26264    BUILD_HOTSPOT=false
26265  fi
26266
26267  JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk"
26268
26269
26270###############################################################################
26271#
26272# Setup the toolchain (compilers etc), i.e. tools used to compile and process
26273# native code.
26274#
26275###############################################################################
26276
26277# First determine the toolchain type (compiler family)
26278
26279
26280# Check whether --with-toolchain-type was given.
26281if test "${with_toolchain_type+set}" = set; then :
26282  withval=$with_toolchain_type;
26283fi
26284
26285
26286  # Use indirect variable referencing
26287  toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS
26288  VALID_TOOLCHAINS=${!toolchain_var_name}
26289  # First toolchain type in the list is the default
26290  DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *}
26291
26292  if test "x$with_toolchain_type" = xlist; then
26293    # List all toolchains
26294    { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5
26295$as_echo "$as_me: The following toolchains are valid on this platform:" >&6;}
26296    for toolchain in $VALID_TOOLCHAINS; do
26297      toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
26298      TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26299      $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
26300    done
26301
26302    exit 0
26303  elif test "x$with_toolchain_type" != x; then
26304    # User override; check that it is valid
26305    if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then
26306      { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5
26307$as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;}
26308      { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5
26309$as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;}
26310      as_fn_error $? "Cannot continue." "$LINENO" 5
26311    fi
26312    TOOLCHAIN_TYPE=$with_toolchain_type
26313  else
26314    # No flag given, use default
26315    TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN
26316  fi
26317
26318
26319  TOOLCHAIN_CC_BINARY_clang="clang"
26320  TOOLCHAIN_CC_BINARY_gcc="gcc"
26321  TOOLCHAIN_CC_BINARY_microsoft="cl"
26322  TOOLCHAIN_CC_BINARY_solstudio="cc"
26323  TOOLCHAIN_CC_BINARY_xlc="xlc_r"
26324
26325  TOOLCHAIN_CXX_BINARY_clang="clang++"
26326  TOOLCHAIN_CXX_BINARY_gcc="g++"
26327  TOOLCHAIN_CXX_BINARY_microsoft="cl"
26328  TOOLCHAIN_CXX_BINARY_solstudio="CC"
26329  TOOLCHAIN_CXX_BINARY_xlc="xlC_r"
26330
26331  # Use indirect variable referencing
26332  toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE
26333  TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26334  toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE
26335  TOOLCHAIN_CC_BINARY=${!toolchain_var_name}
26336  toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE
26337  TOOLCHAIN_CXX_BINARY=${!toolchain_var_name}
26338
26339
26340  # Define filename patterns
26341  if test "x$OPENJDK_TARGET_OS" = xwindows; then
26342    LIBRARY_PREFIX=
26343    SHARED_LIBRARY_SUFFIX='.dll'
26344    STATIC_LIBRARY_SUFFIX='.lib'
26345    SHARED_LIBRARY='$1.dll'
26346    STATIC_LIBRARY='$1.lib'
26347    OBJ_SUFFIX='.obj'
26348    EXE_SUFFIX='.exe'
26349  else
26350    LIBRARY_PREFIX=lib
26351    SHARED_LIBRARY_SUFFIX='.so'
26352    STATIC_LIBRARY_SUFFIX='.a'
26353    SHARED_LIBRARY='lib$1.so'
26354    STATIC_LIBRARY='lib$1.a'
26355    OBJ_SUFFIX='.o'
26356    EXE_SUFFIX=''
26357    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26358      SHARED_LIBRARY='lib$1.dylib'
26359      SHARED_LIBRARY_SUFFIX='.dylib'
26360    fi
26361  fi
26362
26363
26364
26365
26366
26367
26368
26369
26370
26371
26372  if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then
26373    { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5
26374$as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;}
26375  else
26376    { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5
26377$as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;}
26378  fi
26379
26380
26381# Then detect the actual binaries needed
26382
26383  # FIXME: Is this needed?
26384  ac_ext=cpp
26385ac_cpp='$CXXCPP $CPPFLAGS'
26386ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26387ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26388ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26389
26390
26391  # Store the CFLAGS etc passed to the configure script.
26392  ORG_CFLAGS="$CFLAGS"
26393  ORG_CXXFLAGS="$CXXFLAGS"
26394  ORG_OBJCFLAGS="$OBJCFLAGS"
26395
26396  # On Windows, we need to detect the visual studio installation first.
26397  # This will change the PATH, but we need to keep that new PATH even
26398  # after toolchain detection is done, since the compiler (on x86) uses
26399  # it for DLL resolution in runtime.
26400  if test "x$OPENJDK_BUILD_OS" = "xwindows" && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then
26401
26402  # Store path to cygwin link.exe to help excluding it when searching for
26403  # VS linker. This must be done before changing the PATH when looking for VS.
26404  # Extract the first word of "link", so it can be a program name with args.
26405set dummy link; ac_word=$2
26406{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26407$as_echo_n "checking for $ac_word... " >&6; }
26408if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26409  $as_echo_n "(cached) " >&6
26410else
26411  case $CYGWIN_LINK in
26412  [\\/]* | ?:[\\/]*)
26413  ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26414  ;;
26415  *)
26416  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26417for as_dir in $PATH
26418do
26419  IFS=$as_save_IFS
26420  test -z "$as_dir" && as_dir=.
26421    for ac_exec_ext in '' $ac_executable_extensions; do
26422  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26423    ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26424    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26425    break 2
26426  fi
26427done
26428  done
26429IFS=$as_save_IFS
26430
26431  ;;
26432esac
26433fi
26434CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26435if test -n "$CYGWIN_LINK"; then
26436  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26437$as_echo "$CYGWIN_LINK" >&6; }
26438else
26439  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26440$as_echo "no" >&6; }
26441fi
26442
26443
26444  if test "x$CYGWIN_LINK" != x; then
26445    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26446$as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26447    "$CYGWIN_LINK" --version > /dev/null
26448    if test $? -eq 0 ; then
26449      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26450$as_echo "yes" >&6; }
26451    else
26452      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26453$as_echo "no" >&6; }
26454      # This might be the VS linker. Don't exclude it later on.
26455      CYGWIN_LINK=""
26456    fi
26457  fi
26458
26459  # First-hand choice is to locate and run the vsvars bat file.
26460
26461  if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26462    VCVARSFILE="vc/bin/vcvars32.bat"
26463  else
26464    VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26465  fi
26466
26467  VS_ENV_CMD=""
26468  VS_ENV_ARGS=""
26469  if test "x$with_toolsdir" != x; then
26470
26471  if test "x$VS_ENV_CMD" = x; then
26472    VS100BASE="$with_toolsdir/../.."
26473    METHOD="--with-tools-dir"
26474
26475  windows_path="$VS100BASE"
26476  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26477    unix_path=`$CYGPATH -u "$windows_path"`
26478    VS100BASE="$unix_path"
26479  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26480    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26481    VS100BASE="$unix_path"
26482  fi
26483
26484    if test -d "$VS100BASE"; then
26485      if test -f "$VS100BASE/$VCVARSFILE"; then
26486        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26487$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26488        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26489      else
26490        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26491$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26492        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26493$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26494      fi
26495    fi
26496  fi
26497
26498  fi
26499
26500  if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26501    # Having specified an argument which is incorrect will produce an instant failure;
26502    # we should not go on looking
26503    { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26504$as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26505    { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26506$as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26507    as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26508  fi
26509
26510  if test "x$VS100COMNTOOLS" != x; then
26511
26512  if test "x$VS_ENV_CMD" = x; then
26513    VS100BASE="$VS100COMNTOOLS/../.."
26514    METHOD="VS100COMNTOOLS variable"
26515
26516  windows_path="$VS100BASE"
26517  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26518    unix_path=`$CYGPATH -u "$windows_path"`
26519    VS100BASE="$unix_path"
26520  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26521    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26522    VS100BASE="$unix_path"
26523  fi
26524
26525    if test -d "$VS100BASE"; then
26526      if test -f "$VS100BASE/$VCVARSFILE"; then
26527        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26528$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26529        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26530      else
26531        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26532$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26533        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26534$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26535      fi
26536    fi
26537  fi
26538
26539  fi
26540  if test "x$PROGRAMFILES" != x; then
26541
26542  if test "x$VS_ENV_CMD" = x; then
26543    VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26544    METHOD="well-known name"
26545
26546  windows_path="$VS100BASE"
26547  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26548    unix_path=`$CYGPATH -u "$windows_path"`
26549    VS100BASE="$unix_path"
26550  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26551    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26552    VS100BASE="$unix_path"
26553  fi
26554
26555    if test -d "$VS100BASE"; then
26556      if test -f "$VS100BASE/$VCVARSFILE"; then
26557        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26558$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26559        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26560      else
26561        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26562$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26563        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26564$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26565      fi
26566    fi
26567  fi
26568
26569  fi
26570
26571  if test "x$VS_ENV_CMD" = x; then
26572    VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26573    METHOD="well-known name"
26574
26575  windows_path="$VS100BASE"
26576  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26577    unix_path=`$CYGPATH -u "$windows_path"`
26578    VS100BASE="$unix_path"
26579  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26580    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26581    VS100BASE="$unix_path"
26582  fi
26583
26584    if test -d "$VS100BASE"; then
26585      if test -f "$VS100BASE/$VCVARSFILE"; then
26586        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26587$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26588        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26589      else
26590        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26591$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26592        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26593$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26594      fi
26595    fi
26596  fi
26597
26598
26599  if test "x$VS_ENV_CMD" = x; then
26600    VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
26601    METHOD="well-known name"
26602
26603  windows_path="$VS100BASE"
26604  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26605    unix_path=`$CYGPATH -u "$windows_path"`
26606    VS100BASE="$unix_path"
26607  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26608    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26609    VS100BASE="$unix_path"
26610  fi
26611
26612    if test -d "$VS100BASE"; then
26613      if test -f "$VS100BASE/$VCVARSFILE"; then
26614        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26615$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26616        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26617      else
26618        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26619$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26620        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26621$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26622      fi
26623    fi
26624  fi
26625
26626
26627  if test "x$ProgramW6432" != x; then
26628
26629  if test "x$VS_ENV_CMD" = x; then
26630    WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
26631    METHOD="well-known name"
26632
26633  windows_path="$WIN_SDK_BASE"
26634  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26635    unix_path=`$CYGPATH -u "$windows_path"`
26636    WIN_SDK_BASE="$unix_path"
26637  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26638    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26639    WIN_SDK_BASE="$unix_path"
26640  fi
26641
26642    if test -d "$WIN_SDK_BASE"; then
26643      # There have been cases of partial or broken SDK installations. A missing
26644      # lib dir is not going to work.
26645      if test ! -d "$WIN_SDK_BASE/../lib"; then
26646        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26647$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26648        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26649$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26650      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26651        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26652$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26653        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26654        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26655          VS_ENV_ARGS="/x86"
26656        else
26657          VS_ENV_ARGS="/x64"
26658        fi
26659      else
26660        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26661$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26662        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26663$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26664      fi
26665    fi
26666  fi
26667
26668  fi
26669  if test "x$PROGRAMW6432" != x; then
26670
26671  if test "x$VS_ENV_CMD" = x; then
26672    WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
26673    METHOD="well-known name"
26674
26675  windows_path="$WIN_SDK_BASE"
26676  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26677    unix_path=`$CYGPATH -u "$windows_path"`
26678    WIN_SDK_BASE="$unix_path"
26679  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26680    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26681    WIN_SDK_BASE="$unix_path"
26682  fi
26683
26684    if test -d "$WIN_SDK_BASE"; then
26685      # There have been cases of partial or broken SDK installations. A missing
26686      # lib dir is not going to work.
26687      if test ! -d "$WIN_SDK_BASE/../lib"; then
26688        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26689$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26690        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26691$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26692      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26693        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26694$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26695        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26696        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26697          VS_ENV_ARGS="/x86"
26698        else
26699          VS_ENV_ARGS="/x64"
26700        fi
26701      else
26702        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26703$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26704        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26705$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26706      fi
26707    fi
26708  fi
26709
26710  fi
26711  if test "x$PROGRAMFILES" != x; then
26712
26713  if test "x$VS_ENV_CMD" = x; then
26714    WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
26715    METHOD="well-known name"
26716
26717  windows_path="$WIN_SDK_BASE"
26718  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26719    unix_path=`$CYGPATH -u "$windows_path"`
26720    WIN_SDK_BASE="$unix_path"
26721  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26722    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26723    WIN_SDK_BASE="$unix_path"
26724  fi
26725
26726    if test -d "$WIN_SDK_BASE"; then
26727      # There have been cases of partial or broken SDK installations. A missing
26728      # lib dir is not going to work.
26729      if test ! -d "$WIN_SDK_BASE/../lib"; then
26730        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26731$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26732        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26733$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26734      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26735        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26736$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26737        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26738        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26739          VS_ENV_ARGS="/x86"
26740        else
26741          VS_ENV_ARGS="/x64"
26742        fi
26743      else
26744        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26745$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26746        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26747$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26748      fi
26749    fi
26750  fi
26751
26752  fi
26753
26754  if test "x$VS_ENV_CMD" = x; then
26755    WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
26756    METHOD="well-known name"
26757
26758  windows_path="$WIN_SDK_BASE"
26759  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26760    unix_path=`$CYGPATH -u "$windows_path"`
26761    WIN_SDK_BASE="$unix_path"
26762  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26763    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26764    WIN_SDK_BASE="$unix_path"
26765  fi
26766
26767    if test -d "$WIN_SDK_BASE"; then
26768      # There have been cases of partial or broken SDK installations. A missing
26769      # lib dir is not going to work.
26770      if test ! -d "$WIN_SDK_BASE/../lib"; then
26771        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26772$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26773        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26774$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26775      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26776        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26777$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26778        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26779        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26780          VS_ENV_ARGS="/x86"
26781        else
26782          VS_ENV_ARGS="/x64"
26783        fi
26784      else
26785        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26786$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26787        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26788$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26789      fi
26790    fi
26791  fi
26792
26793
26794  if test "x$VS_ENV_CMD" = x; then
26795    WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
26796    METHOD="well-known name"
26797
26798  windows_path="$WIN_SDK_BASE"
26799  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26800    unix_path=`$CYGPATH -u "$windows_path"`
26801    WIN_SDK_BASE="$unix_path"
26802  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26803    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26804    WIN_SDK_BASE="$unix_path"
26805  fi
26806
26807    if test -d "$WIN_SDK_BASE"; then
26808      # There have been cases of partial or broken SDK installations. A missing
26809      # lib dir is not going to work.
26810      if test ! -d "$WIN_SDK_BASE/../lib"; then
26811        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26812$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26813        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26814$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26815      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26816        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26817$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26818        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26819        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26820          VS_ENV_ARGS="/x86"
26821        else
26822          VS_ENV_ARGS="/x64"
26823        fi
26824      else
26825        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26826$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26827        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26828$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26829      fi
26830    fi
26831  fi
26832
26833
26834  if test "x$VS_ENV_CMD" != x; then
26835    # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
26836
26837  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26838
26839  # First separate the path from the arguments. This will split at the first
26840  # space.
26841  complete="$VS_ENV_CMD"
26842  path="${complete%% *}"
26843  tmp="$complete EOL"
26844  arguments="${tmp#* }"
26845
26846  # Input might be given as Windows format, start by converting to
26847  # unix format.
26848  new_path=`$CYGPATH -u "$path"`
26849
26850  # Now try to locate executable using which
26851  new_path=`$WHICH "$new_path" 2> /dev/null`
26852  # bat and cmd files are not always considered executable in cygwin causing which
26853  # to not find them
26854  if test "x$new_path" = x \
26855      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26856      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26857    new_path=`$CYGPATH -u "$path"`
26858  fi
26859  if test "x$new_path" = x; then
26860    # Oops. Which didn't find the executable.
26861    # The splitting of arguments from the executable at a space might have been incorrect,
26862    # since paths with space are more likely in Windows. Give it another try with the whole
26863    # argument.
26864    path="$complete"
26865    arguments="EOL"
26866    new_path=`$CYGPATH -u "$path"`
26867    new_path=`$WHICH "$new_path" 2> /dev/null`
26868    # bat and cmd files are not always considered executable in cygwin causing which
26869    # to not find them
26870    if test "x$new_path" = x \
26871        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26872        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26873      new_path=`$CYGPATH -u "$path"`
26874    fi
26875    if test "x$new_path" = x; then
26876      # It's still not found. Now this is an unrecoverable error.
26877      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
26878$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
26879      has_space=`$ECHO "$complete" | $GREP " "`
26880      if test "x$has_space" != x; then
26881        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
26882$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
26883      fi
26884      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26885    fi
26886  fi
26887
26888  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
26889  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
26890  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
26891  # "foo.exe" is OK but "foo" is an error.
26892  #
26893  # This test is therefore slightly more accurate than "test -f" to check for file presence.
26894  # It is also a way to make sure we got the proper file name for the real test later on.
26895  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
26896  if test "x$test_shortpath" = x; then
26897    # Short path failed, file does not exist as specified.
26898    # Try adding .exe or .cmd
26899    if test -f "${new_path}.exe"; then
26900      input_to_shortpath="${new_path}.exe"
26901    elif test -f "${new_path}.cmd"; then
26902      input_to_shortpath="${new_path}.cmd"
26903    else
26904      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
26905$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
26906      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
26907$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
26908      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26909    fi
26910  else
26911    input_to_shortpath="$new_path"
26912  fi
26913
26914  # Call helper function which possibly converts this using DOS-style short mode.
26915  # If so, the updated path is stored in $new_path.
26916  new_path="$input_to_shortpath"
26917
26918  input_path="$input_to_shortpath"
26919  # Check if we need to convert this using DOS-style short mode. If the path
26920  # contains just simple characters, use it. Otherwise (spaces, weird characters),
26921  # take no chances and rewrite it.
26922  # Note: m4 eats our [], so we need to use [ and ] instead.
26923  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
26924  if test "x$has_forbidden_chars" != x; then
26925    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
26926    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
26927    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
26928    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
26929      # Going to short mode and back again did indeed matter. Since short mode is
26930      # case insensitive, let's make it lowercase to improve readability.
26931      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
26932      # Now convert it back to Unix-stile (cygpath)
26933      input_path=`$CYGPATH -u "$shortmode_path"`
26934      new_path="$input_path"
26935    fi
26936  fi
26937
26938  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
26939  if test "x$test_cygdrive_prefix" = x; then
26940    # As a simple fix, exclude /usr/bin since it's not a real path.
26941    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
26942      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
26943      # a path prefixed by /cygdrive for fixpath to work.
26944      new_path="$CYGWIN_ROOT_PATH$input_path"
26945    fi
26946  fi
26947
26948  # remove trailing .exe if any
26949  new_path="${new_path/%.exe/}"
26950
26951  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26952
26953  # First separate the path from the arguments. This will split at the first
26954  # space.
26955  complete="$VS_ENV_CMD"
26956  path="${complete%% *}"
26957  tmp="$complete EOL"
26958  arguments="${tmp#* }"
26959
26960  # Input might be given as Windows format, start by converting to
26961  # unix format.
26962  new_path="$path"
26963
26964  windows_path="$new_path"
26965  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26966    unix_path=`$CYGPATH -u "$windows_path"`
26967    new_path="$unix_path"
26968  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26969    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26970    new_path="$unix_path"
26971  fi
26972
26973
26974  # Now try to locate executable using which
26975  new_path=`$WHICH "$new_path" 2> /dev/null`
26976
26977  if test "x$new_path" = x; then
26978    # Oops. Which didn't find the executable.
26979    # The splitting of arguments from the executable at a space might have been incorrect,
26980    # since paths with space are more likely in Windows. Give it another try with the whole
26981    # argument.
26982    path="$complete"
26983    arguments="EOL"
26984    new_path="$path"
26985
26986  windows_path="$new_path"
26987  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26988    unix_path=`$CYGPATH -u "$windows_path"`
26989    new_path="$unix_path"
26990  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26991    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26992    new_path="$unix_path"
26993  fi
26994
26995
26996    new_path=`$WHICH "$new_path" 2> /dev/null`
26997
26998    if test "x$new_path" = x; then
26999      # It's still not found. Now this is an unrecoverable error.
27000      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27001$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27002      has_space=`$ECHO "$complete" | $GREP " "`
27003      if test "x$has_space" != x; then
27004        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27005$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27006      fi
27007      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27008    fi
27009  fi
27010
27011  # Now new_path has a complete unix path to the binary
27012  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27013    # Keep paths in /bin as-is, but remove trailing .exe if any
27014    new_path="${new_path/%.exe/}"
27015    # Do not save /bin paths to all_fixpath_prefixes!
27016  else
27017    # Not in mixed or Windows style, start by that.
27018    new_path=`cmd //c echo $new_path`
27019
27020  input_path="$new_path"
27021  # Check if we need to convert this using DOS-style short mode. If the path
27022  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27023  # take no chances and rewrite it.
27024  # Note: m4 eats our [], so we need to use [ and ] instead.
27025  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27026  if test "x$has_forbidden_chars" != x; then
27027    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27028    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27029  fi
27030
27031    # Output is in $new_path
27032
27033  windows_path="$new_path"
27034  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27035    unix_path=`$CYGPATH -u "$windows_path"`
27036    new_path="$unix_path"
27037  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27038    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27039    new_path="$unix_path"
27040  fi
27041
27042    # remove trailing .exe if any
27043    new_path="${new_path/%.exe/}"
27044
27045    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27046    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27047  fi
27048
27049  else
27050    # We're on a posix platform. Hooray! :)
27051    # First separate the path from the arguments. This will split at the first
27052    # space.
27053    complete="$VS_ENV_CMD"
27054    path="${complete%% *}"
27055    tmp="$complete EOL"
27056    arguments="${tmp#* }"
27057
27058    # Cannot rely on the command "which" here since it doesn't always work.
27059    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27060    if test -z "$is_absolute_path"; then
27061      # Path to executable is not absolute. Find it.
27062      IFS_save="$IFS"
27063      IFS=:
27064      for p in $PATH; do
27065        if test -f "$p/$path" && test -x "$p/$path"; then
27066          new_path="$p/$path"
27067          break
27068        fi
27069      done
27070      IFS="$IFS_save"
27071    else
27072      # This is an absolute path, we can use it without further modifications.
27073      new_path="$path"
27074    fi
27075
27076    if test "x$new_path" = x; then
27077      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27078$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27079      has_space=`$ECHO "$complete" | $GREP " "`
27080      if test "x$has_space" != x; then
27081        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27082$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27083      fi
27084      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27085    fi
27086  fi
27087
27088  # Now join together the path and the arguments once again
27089  if test "x$arguments" != xEOL; then
27090    new_complete="$new_path ${arguments% *}"
27091  else
27092    new_complete="$new_path"
27093  fi
27094
27095  if test "x$complete" != "x$new_complete"; then
27096    VS_ENV_CMD="$new_complete"
27097    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27098$as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27099  fi
27100
27101
27102    # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27103    { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27104$as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27105    cd $OUTPUT_ROOT
27106    # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted
27107    # to autoconf standards.
27108
27109    #----
27110
27111    # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment)
27112    # but calculate the difference in Cygwin environment before/after running it and then
27113    # apply the diff.
27114
27115    if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
27116      _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"`
27117      _dosvs10varsall=`cygpath -a -w -s $_vs10varsall`
27118      _dosbash=`cygpath -a -w -s \`which bash\`.*`
27119    else
27120      _dosvs10varsall=`cmd //c echo $VS_ENV_CMD`
27121      _dosbash=`cmd //c echo \`which bash\``
27122    fi
27123
27124    # generate the set of exported vars before/after the vs10 setup
27125    $ECHO "@echo off"                                           >  localdevenvtmp.bat
27126    $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat
27127    $ECHO "call $_dosvs10varsall $VS_ENV_ARGS"                  >> localdevenvtmp.bat
27128    $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat
27129
27130    # Now execute the newly created bat file.
27131    # The | cat is to stop SetEnv.Cmd to mess with system colors on msys
27132    cmd /c localdevenvtmp.bat | cat
27133
27134    # apply the diff (less some non-vs10 vars named by "!")
27135    $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort
27136    $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort
27137    $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh
27138
27139    # cleanup
27140    $RM localdevenvtmp*
27141    #----
27142    cd $CURDIR
27143    if test ! -s $OUTPUT_ROOT/localdevenv.sh; then
27144      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27145$as_echo "no" >&6; }
27146      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27147$as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27148      { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27149$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27150      { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27151$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27152      as_fn_error $? "Cannot continue" "$LINENO" 5
27153    fi
27154
27155    # Now set all paths and other env variables. This will allow the rest of
27156    # the configure script to find and run the compiler in the proper way.
27157    { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27158$as_echo "$as_me: Setting extracted environment variables" >&6;}
27159    . $OUTPUT_ROOT/localdevenv.sh
27160  else
27161    # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27162    { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27163$as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27164  fi
27165
27166  # At this point, we should have corrent variables in the environment, or we can't continue.
27167  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27168$as_echo_n "checking for Visual Studio variables... " >&6; }
27169
27170  if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27171    if test "x$INCLUDE" = x || test "x$LIB" = x; then
27172      { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27173$as_echo "present but broken" >&6; }
27174      as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27175    else
27176      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27177$as_echo "ok" >&6; }
27178      # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk.
27179      VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'`
27180      VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'`
27181      # Remove any paths containing # (typically F#) as that messes up make
27182      PATH=`$ECHO "$PATH" | $SED 's/[^:#]*#[^:]*://g'`
27183      VS_PATH="$PATH"
27184
27185
27186
27187    fi
27188  else
27189    { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27190$as_echo "not found" >&6; }
27191
27192    if test "x$VS_ENV_CMD" = x; then
27193      { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27194$as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27195      { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27196$as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27197    else
27198      { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27199$as_echo "$as_me: Running the extraction script failed." >&6;}
27200    fi
27201    { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27202$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27203    { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27204$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27205    as_fn_error $? "Cannot continue" "$LINENO" 5
27206  fi
27207
27208  fi
27209
27210  # autoconf magic only relies on PATH, so update it if tools dir is specified
27211  OLD_PATH="$PATH"
27212
27213  # For solaris we really need solaris tools, and not the GNU equivalent.
27214  # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27215  # so add that to path before starting to probe.
27216  # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27217  if test "x$OPENJDK_BUILD_OS" = xsolaris; then
27218    PATH="/usr/ccs/bin:$PATH"
27219  fi
27220
27221  # Finally add TOOLS_DIR at the beginning, to allow --with-tools-dir to
27222  # override all other locations.
27223  if test "x$TOOLS_DIR" != x; then
27224    PATH=$TOOLS_DIR:$PATH
27225  fi
27226
27227  # If a devkit is found on the builddeps server, then prepend its path to the
27228  # PATH variable. If there are cross compilers available in the devkit, these
27229  # will be found by AC_PROG_CC et al.
27230  DEVKIT=
27231
27232
27233  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
27234    # Source the builddeps file again, to make sure it uses the latest variables!
27235    . $builddepsfile
27236    # Look for a target and build machine specific resource!
27237    eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
27238    if test "x$resource" = x; then
27239      # Ok, lets instead look for a target specific resource
27240      eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}}
27241    fi
27242    if test "x$resource" = x; then
27243      # Ok, lets instead look for a build specific resource
27244      eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}}
27245    fi
27246    if test "x$resource" = x; then
27247      # Ok, lets instead look for a generic resource
27248      # (The devkit comes from M4 and not the shell, thus no need for eval here.)
27249      resource=${builddep_devkit}
27250    fi
27251    if test "x$resource" != x; then
27252      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5
27253$as_echo "$as_me: Using builddeps $resource for devkit" >&6;}
27254      # If the resource in the builddeps.conf file is an existing directory,
27255      # for example /java/linux/cups
27256      if test -d ${resource}; then
27257        depdir=${resource}
27258      else
27259
27260  # devkit is for example mymodule
27261  # $resource is for example libs/general/libmymod_1_2_3.zip
27262  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
27263  # $with_builddeps_dir is for example /localhome/builddeps
27264  # depdir is the name of the variable into which we store the depdir, eg MYMOD
27265  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
27266  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
27267  filename=`basename $resource`
27268  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
27269  filebase=${filename%%.*}
27270  extension=${filename#*.}
27271  installdir=$with_builddeps_dir/$filebase
27272  if test ! -f $installdir/$filename.unpacked; then
27273    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5
27274$as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;}
27275    if test ! -d $installdir; then
27276      mkdir -p $installdir
27277    fi
27278    if test ! -d $installdir; then
27279      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
27280    fi
27281    tmpfile=`mktemp $installdir/devkit.XXXXXXXXX`
27282    touch $tmpfile
27283    if test ! -f $tmpfile; then
27284      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
27285    fi
27286
27287  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
27288  # $tmpfile is the local file name for the downloaded file.
27289  VALID_TOOL=no
27290  if test "x$BDEPS_FTP" = xwget; then
27291    VALID_TOOL=yes
27292    wget -O $tmpfile $with_builddeps_server/$resource
27293  fi
27294  if test "x$BDEPS_FTP" = xlftp; then
27295    VALID_TOOL=yes
27296    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
27297  fi
27298  if test "x$BDEPS_FTP" = xftp; then
27299    VALID_TOOL=yes
27300    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
27301    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
27302    FTPUSERPWD=${FTPSERVER%%@*}
27303    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
27304      FTPUSER=${userpwd%%:*}
27305      FTPPWD=${userpwd#*@}
27306      FTPSERVER=${FTPSERVER#*@}
27307    else
27308      FTPUSER=ftp
27309      FTPPWD=ftp
27310    fi
27311    # the "pass" command does not work on some
27312    # ftp clients (read ftp.exe) but if it works,
27313    # passive mode is better!
27314    ( \
27315        echo "user $FTPUSER $FTPPWD"        ; \
27316        echo "pass"                         ; \
27317        echo "bin"                          ; \
27318        echo "get $FTPPATH $tmpfile"              ; \
27319    ) | ftp -in $FTPSERVER
27320  fi
27321  if test "x$VALID_TOOL" != xyes; then
27322    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
27323  fi
27324
27325    mv $tmpfile $installdir/$filename
27326    if test ! -s $installdir/$filename; then
27327      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
27328    fi
27329    case "$extension" in
27330      zip)  echo "Unzipping $installdir/$filename..."
27331        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
27332        ;;
27333      tar.gz) echo "Untaring $installdir/$filename..."
27334        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27335        ;;
27336      tgz) echo "Untaring $installdir/$filename..."
27337        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27338        ;;
27339      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
27340        ;;
27341    esac
27342  fi
27343  if test -f $installdir/$filename.unpacked; then
27344    depdir=$installdir
27345  fi
27346
27347      fi
27348      # Source the builddeps file again, because in the previous command, the depdir
27349      # was updated to point at the current build dependency install directory.
27350      . $builddepsfile
27351      # Now extract variables from the builddeps.conf files.
27352      theroot=${builddep_devkit_ROOT}
27353      thecflags=${builddep_devkit_CFLAGS}
27354      thelibs=${builddep_devkit_LIBS}
27355      if test "x$depdir" = x; then
27356        as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5
27357      fi
27358      DEVKIT=$depdir
27359      if test "x$theroot" != x; then
27360        DEVKIT="$theroot"
27361      fi
27362      if test "x$thecflags" != x; then
27363        DEVKIT_CFLAGS="$thecflags"
27364      fi
27365      if test "x$thelibs" != x; then
27366        DEVKIT_LIBS="$thelibs"
27367      fi
27368
27369        # Found devkit
27370        PATH="$DEVKIT/bin:$PATH"
27371        SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root"
27372        if test "x$x_includes" = "xNONE"; then
27373          x_includes="$SYS_ROOT/usr/include/X11"
27374        fi
27375        if test "x$x_libraries" = "xNONE"; then
27376          x_libraries="$SYS_ROOT/usr/lib"
27377        fi
27378
27379
27380    fi
27381
27382  fi
27383
27384
27385
27386  #
27387  # Setup the compilers (CC and CXX)
27388  #
27389
27390  COMPILER_NAME=C
27391  SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27392
27393  if test "x$CC" != x; then
27394    # User has supplied compiler name already, always let that override.
27395    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27396$as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27397    if test "x`basename $CC`" = "x$CC"; then
27398      # A command without a complete path is provided, search $PATH.
27399
27400      for ac_prog in $CC
27401do
27402  # Extract the first word of "$ac_prog", so it can be a program name with args.
27403set dummy $ac_prog; ac_word=$2
27404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27405$as_echo_n "checking for $ac_word... " >&6; }
27406if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27407  $as_echo_n "(cached) " >&6
27408else
27409  case $POTENTIAL_CC in
27410  [\\/]* | ?:[\\/]*)
27411  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27412  ;;
27413  *)
27414  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27415for as_dir in $PATH
27416do
27417  IFS=$as_save_IFS
27418  test -z "$as_dir" && as_dir=.
27419    for ac_exec_ext in '' $ac_executable_extensions; do
27420  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27421    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27422    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27423    break 2
27424  fi
27425done
27426  done
27427IFS=$as_save_IFS
27428
27429  ;;
27430esac
27431fi
27432POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27433if test -n "$POTENTIAL_CC"; then
27434  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27435$as_echo "$POTENTIAL_CC" >&6; }
27436else
27437  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27438$as_echo "no" >&6; }
27439fi
27440
27441
27442  test -n "$POTENTIAL_CC" && break
27443done
27444
27445      if test "x$POTENTIAL_CC" != x; then
27446        CC=$POTENTIAL_CC
27447      else
27448        as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27449      fi
27450    else
27451      # Otherwise it might already be a complete path
27452      if test ! -x "$CC"; then
27453        as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27454      fi
27455    fi
27456  else
27457    # No user supplied value. Locate compiler ourselves.
27458
27459    # If we are cross compiling, assume cross compilation tools follows the
27460    # cross compilation standard where they are prefixed with the autoconf
27461    # standard name for the target. For example the binary
27462    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27463    # If we are not cross compiling, then the default compiler name will be
27464    # used.
27465
27466    CC=
27467    # If TOOLS_DIR is set, check for all compiler names in there first
27468    # before checking the rest of the PATH.
27469    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27470    # step, this should not be necessary.
27471    if test -n "$TOOLS_DIR"; then
27472      PATH_save="$PATH"
27473      PATH="$TOOLS_DIR"
27474      for ac_prog in $SEARCH_LIST
27475do
27476  # Extract the first word of "$ac_prog", so it can be a program name with args.
27477set dummy $ac_prog; ac_word=$2
27478{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27479$as_echo_n "checking for $ac_word... " >&6; }
27480if ${ac_cv_path_TOOLS_DIR_CC+:} false; then :
27481  $as_echo_n "(cached) " >&6
27482else
27483  case $TOOLS_DIR_CC in
27484  [\\/]* | ?:[\\/]*)
27485  ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path.
27486  ;;
27487  *)
27488  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27489for as_dir in $PATH
27490do
27491  IFS=$as_save_IFS
27492  test -z "$as_dir" && as_dir=.
27493    for ac_exec_ext in '' $ac_executable_extensions; do
27494  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27495    ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext"
27496    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27497    break 2
27498  fi
27499done
27500  done
27501IFS=$as_save_IFS
27502
27503  ;;
27504esac
27505fi
27506TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC
27507if test -n "$TOOLS_DIR_CC"; then
27508  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5
27509$as_echo "$TOOLS_DIR_CC" >&6; }
27510else
27511  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27512$as_echo "no" >&6; }
27513fi
27514
27515
27516  test -n "$TOOLS_DIR_CC" && break
27517done
27518
27519      CC=$TOOLS_DIR_CC
27520      PATH="$PATH_save"
27521    fi
27522
27523    # AC_PATH_PROGS can't be run multiple times with the same variable,
27524    # so create a new name for this run.
27525    if test "x$CC" = x; then
27526      for ac_prog in $SEARCH_LIST
27527do
27528  # Extract the first word of "$ac_prog", so it can be a program name with args.
27529set dummy $ac_prog; ac_word=$2
27530{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27531$as_echo_n "checking for $ac_word... " >&6; }
27532if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27533  $as_echo_n "(cached) " >&6
27534else
27535  case $POTENTIAL_CC in
27536  [\\/]* | ?:[\\/]*)
27537  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27538  ;;
27539  *)
27540  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27541for as_dir in $PATH
27542do
27543  IFS=$as_save_IFS
27544  test -z "$as_dir" && as_dir=.
27545    for ac_exec_ext in '' $ac_executable_extensions; do
27546  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27547    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27548    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27549    break 2
27550  fi
27551done
27552  done
27553IFS=$as_save_IFS
27554
27555  ;;
27556esac
27557fi
27558POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27559if test -n "$POTENTIAL_CC"; then
27560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27561$as_echo "$POTENTIAL_CC" >&6; }
27562else
27563  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27564$as_echo "no" >&6; }
27565fi
27566
27567
27568  test -n "$POTENTIAL_CC" && break
27569done
27570
27571      CC=$POTENTIAL_CC
27572    fi
27573
27574    if test "x$CC" = x; then
27575
27576  # Print a helpful message on how to acquire the necessary build dependency.
27577  # devkit is the help tag: freetype, cups, pulse, alsa etc
27578  MISSING_DEPENDENCY=devkit
27579
27580  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27581    cygwin_help $MISSING_DEPENDENCY
27582  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27583    msys_help $MISSING_DEPENDENCY
27584  else
27585    PKGHANDLER_COMMAND=
27586
27587    case $PKGHANDLER in
27588      apt-get)
27589        apt_help     $MISSING_DEPENDENCY ;;
27590      yum)
27591        yum_help     $MISSING_DEPENDENCY ;;
27592      port)
27593        port_help    $MISSING_DEPENDENCY ;;
27594      pkgutil)
27595        pkgutil_help $MISSING_DEPENDENCY ;;
27596      pkgadd)
27597        pkgadd_help  $MISSING_DEPENDENCY ;;
27598    esac
27599
27600    if test "x$PKGHANDLER_COMMAND" != x; then
27601      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
27602    fi
27603  fi
27604
27605      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
27606    fi
27607  fi
27608
27609  # Now we have a compiler binary in CC. Make sure it's okay.
27610
27611  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27612
27613  # First separate the path from the arguments. This will split at the first
27614  # space.
27615  complete="$CC"
27616  path="${complete%% *}"
27617  tmp="$complete EOL"
27618  arguments="${tmp#* }"
27619
27620  # Input might be given as Windows format, start by converting to
27621  # unix format.
27622  new_path=`$CYGPATH -u "$path"`
27623
27624  # Now try to locate executable using which
27625  new_path=`$WHICH "$new_path" 2> /dev/null`
27626  # bat and cmd files are not always considered executable in cygwin causing which
27627  # to not find them
27628  if test "x$new_path" = x \
27629      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27630      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27631    new_path=`$CYGPATH -u "$path"`
27632  fi
27633  if test "x$new_path" = x; then
27634    # Oops. Which didn't find the executable.
27635    # The splitting of arguments from the executable at a space might have been incorrect,
27636    # since paths with space are more likely in Windows. Give it another try with the whole
27637    # argument.
27638    path="$complete"
27639    arguments="EOL"
27640    new_path=`$CYGPATH -u "$path"`
27641    new_path=`$WHICH "$new_path" 2> /dev/null`
27642    # bat and cmd files are not always considered executable in cygwin causing which
27643    # to not find them
27644    if test "x$new_path" = x \
27645        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27646        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27647      new_path=`$CYGPATH -u "$path"`
27648    fi
27649    if test "x$new_path" = x; then
27650      # It's still not found. Now this is an unrecoverable error.
27651      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27652$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27653      has_space=`$ECHO "$complete" | $GREP " "`
27654      if test "x$has_space" != x; then
27655        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27656$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27657      fi
27658      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27659    fi
27660  fi
27661
27662  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27663  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27664  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27665  # "foo.exe" is OK but "foo" is an error.
27666  #
27667  # This test is therefore slightly more accurate than "test -f" to check for file presence.
27668  # It is also a way to make sure we got the proper file name for the real test later on.
27669  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27670  if test "x$test_shortpath" = x; then
27671    # Short path failed, file does not exist as specified.
27672    # Try adding .exe or .cmd
27673    if test -f "${new_path}.exe"; then
27674      input_to_shortpath="${new_path}.exe"
27675    elif test -f "${new_path}.cmd"; then
27676      input_to_shortpath="${new_path}.cmd"
27677    else
27678      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
27679$as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
27680      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27681$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27682      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27683    fi
27684  else
27685    input_to_shortpath="$new_path"
27686  fi
27687
27688  # Call helper function which possibly converts this using DOS-style short mode.
27689  # If so, the updated path is stored in $new_path.
27690  new_path="$input_to_shortpath"
27691
27692  input_path="$input_to_shortpath"
27693  # Check if we need to convert this using DOS-style short mode. If the path
27694  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27695  # take no chances and rewrite it.
27696  # Note: m4 eats our [], so we need to use [ and ] instead.
27697  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27698  if test "x$has_forbidden_chars" != x; then
27699    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27700    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27701    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27702    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27703      # Going to short mode and back again did indeed matter. Since short mode is
27704      # case insensitive, let's make it lowercase to improve readability.
27705      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27706      # Now convert it back to Unix-stile (cygpath)
27707      input_path=`$CYGPATH -u "$shortmode_path"`
27708      new_path="$input_path"
27709    fi
27710  fi
27711
27712  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27713  if test "x$test_cygdrive_prefix" = x; then
27714    # As a simple fix, exclude /usr/bin since it's not a real path.
27715    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27716      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27717      # a path prefixed by /cygdrive for fixpath to work.
27718      new_path="$CYGWIN_ROOT_PATH$input_path"
27719    fi
27720  fi
27721
27722  # remove trailing .exe if any
27723  new_path="${new_path/%.exe/}"
27724
27725  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27726
27727  # First separate the path from the arguments. This will split at the first
27728  # space.
27729  complete="$CC"
27730  path="${complete%% *}"
27731  tmp="$complete EOL"
27732  arguments="${tmp#* }"
27733
27734  # Input might be given as Windows format, start by converting to
27735  # unix format.
27736  new_path="$path"
27737
27738  windows_path="$new_path"
27739  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27740    unix_path=`$CYGPATH -u "$windows_path"`
27741    new_path="$unix_path"
27742  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27743    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27744    new_path="$unix_path"
27745  fi
27746
27747
27748  # Now try to locate executable using which
27749  new_path=`$WHICH "$new_path" 2> /dev/null`
27750
27751  if test "x$new_path" = x; then
27752    # Oops. Which didn't find the executable.
27753    # The splitting of arguments from the executable at a space might have been incorrect,
27754    # since paths with space are more likely in Windows. Give it another try with the whole
27755    # argument.
27756    path="$complete"
27757    arguments="EOL"
27758    new_path="$path"
27759
27760  windows_path="$new_path"
27761  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27762    unix_path=`$CYGPATH -u "$windows_path"`
27763    new_path="$unix_path"
27764  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27765    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27766    new_path="$unix_path"
27767  fi
27768
27769
27770    new_path=`$WHICH "$new_path" 2> /dev/null`
27771
27772    if test "x$new_path" = x; then
27773      # It's still not found. Now this is an unrecoverable error.
27774      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27775$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27776      has_space=`$ECHO "$complete" | $GREP " "`
27777      if test "x$has_space" != x; then
27778        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27779$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27780      fi
27781      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27782    fi
27783  fi
27784
27785  # Now new_path has a complete unix path to the binary
27786  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27787    # Keep paths in /bin as-is, but remove trailing .exe if any
27788    new_path="${new_path/%.exe/}"
27789    # Do not save /bin paths to all_fixpath_prefixes!
27790  else
27791    # Not in mixed or Windows style, start by that.
27792    new_path=`cmd //c echo $new_path`
27793
27794  input_path="$new_path"
27795  # Check if we need to convert this using DOS-style short mode. If the path
27796  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27797  # take no chances and rewrite it.
27798  # Note: m4 eats our [], so we need to use [ and ] instead.
27799  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27800  if test "x$has_forbidden_chars" != x; then
27801    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27802    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27803  fi
27804
27805    # Output is in $new_path
27806
27807  windows_path="$new_path"
27808  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27809    unix_path=`$CYGPATH -u "$windows_path"`
27810    new_path="$unix_path"
27811  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27812    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27813    new_path="$unix_path"
27814  fi
27815
27816    # remove trailing .exe if any
27817    new_path="${new_path/%.exe/}"
27818
27819    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27820    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27821  fi
27822
27823  else
27824    # We're on a posix platform. Hooray! :)
27825    # First separate the path from the arguments. This will split at the first
27826    # space.
27827    complete="$CC"
27828    path="${complete%% *}"
27829    tmp="$complete EOL"
27830    arguments="${tmp#* }"
27831
27832    # Cannot rely on the command "which" here since it doesn't always work.
27833    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27834    if test -z "$is_absolute_path"; then
27835      # Path to executable is not absolute. Find it.
27836      IFS_save="$IFS"
27837      IFS=:
27838      for p in $PATH; do
27839        if test -f "$p/$path" && test -x "$p/$path"; then
27840          new_path="$p/$path"
27841          break
27842        fi
27843      done
27844      IFS="$IFS_save"
27845    else
27846      # This is an absolute path, we can use it without further modifications.
27847      new_path="$path"
27848    fi
27849
27850    if test "x$new_path" = x; then
27851      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27852$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27853      has_space=`$ECHO "$complete" | $GREP " "`
27854      if test "x$has_space" != x; then
27855        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27856$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27857      fi
27858      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27859    fi
27860  fi
27861
27862  # Now join together the path and the arguments once again
27863  if test "x$arguments" != xEOL; then
27864    new_complete="$new_path ${arguments% *}"
27865  else
27866    new_complete="$new_path"
27867  fi
27868
27869  if test "x$complete" != "x$new_complete"; then
27870    CC="$new_complete"
27871    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
27872$as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
27873  fi
27874
27875  TEST_COMPILER="$CC"
27876  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
27877  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
27878  if test "x$OPENJDK_BUILD_OS" != xaix; then
27879    # FIXME: This test should not be needed anymore; we don't do that for any platform.
27880    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
27881$as_echo_n "checking resolved symbolic links for CC... " >&6; }
27882
27883  if test "x$OPENJDK_BUILD_OS" != xwindows; then
27884    # Follow a chain of symbolic links. Use readlink
27885    # where it exists, else fall back to horribly
27886    # complicated shell code.
27887    if test "x$READLINK_TESTED" != yes; then
27888      # On MacOSX there is a readlink tool with a different
27889      # purpose than the GNU readlink tool. Check the found readlink.
27890      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
27891      if test "x$ISGNU" = x; then
27892        # A readlink that we do not know how to use.
27893        # Are there other non-GNU readlinks out there?
27894        READLINK_TESTED=yes
27895        READLINK=
27896      fi
27897    fi
27898
27899    if test "x$READLINK" != x; then
27900      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
27901    else
27902      # Save the current directory for restoring afterwards
27903      STARTDIR=$PWD
27904      COUNTER=0
27905      sym_link_dir=`$DIRNAME $TEST_COMPILER`
27906      sym_link_file=`$BASENAME $TEST_COMPILER`
27907      cd $sym_link_dir
27908      # Use -P flag to resolve symlinks in directories.
27909      cd `$THEPWDCMD -P`
27910      sym_link_dir=`$THEPWDCMD -P`
27911      # Resolve file symlinks
27912      while test $COUNTER -lt 20; do
27913        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
27914        if test "x$ISLINK" == x; then
27915          # This is not a symbolic link! We are done!
27916          break
27917        fi
27918        # Again resolve directory symlinks since the target of the just found
27919        # link could be in a different directory
27920        cd `$DIRNAME $ISLINK`
27921        sym_link_dir=`$THEPWDCMD -P`
27922        sym_link_file=`$BASENAME $ISLINK`
27923        let COUNTER=COUNTER+1
27924      done
27925      cd $STARTDIR
27926      TEST_COMPILER=$sym_link_dir/$sym_link_file
27927    fi
27928  fi
27929
27930    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
27931$as_echo "$TEST_COMPILER" >&6; }
27932  fi
27933  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
27934$as_echo_n "checking if CC is disguised ccache... " >&6; }
27935
27936  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
27937  if test "x$COMPILER_BASENAME" = "xccache"; then
27938    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
27939$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
27940    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
27941    # We want to control ccache invocation ourselves, so ignore this cc and try
27942    # searching again.
27943
27944    # Remove the path to the fake ccache cc from the PATH
27945    RETRY_COMPILER_SAVED_PATH="$PATH"
27946    COMPILER_DIRNAME=`$DIRNAME $CC`
27947    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
27948
27949    # Try again looking for our compiler
27950    if test -n "$ac_tool_prefix"; then
27951  for ac_prog in $TOOLCHAIN_CC_BINARY
27952  do
27953    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
27954set dummy $ac_tool_prefix$ac_prog; ac_word=$2
27955{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27956$as_echo_n "checking for $ac_word... " >&6; }
27957if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
27958  $as_echo_n "(cached) " >&6
27959else
27960  if test -n "$PROPER_COMPILER_CC"; then
27961  ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
27962else
27963as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27964for as_dir in $PATH
27965do
27966  IFS=$as_save_IFS
27967  test -z "$as_dir" && as_dir=.
27968    for ac_exec_ext in '' $ac_executable_extensions; do
27969  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27970    ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
27971    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27972    break 2
27973  fi
27974done
27975  done
27976IFS=$as_save_IFS
27977
27978fi
27979fi
27980PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
27981if test -n "$PROPER_COMPILER_CC"; then
27982  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
27983$as_echo "$PROPER_COMPILER_CC" >&6; }
27984else
27985  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27986$as_echo "no" >&6; }
27987fi
27988
27989
27990    test -n "$PROPER_COMPILER_CC" && break
27991  done
27992fi
27993if test -z "$PROPER_COMPILER_CC"; then
27994  ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
27995  for ac_prog in $TOOLCHAIN_CC_BINARY
27996do
27997  # Extract the first word of "$ac_prog", so it can be a program name with args.
27998set dummy $ac_prog; ac_word=$2
27999{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28000$as_echo_n "checking for $ac_word... " >&6; }
28001if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
28002  $as_echo_n "(cached) " >&6
28003else
28004  if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28005  ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
28006else
28007as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28008for as_dir in $PATH
28009do
28010  IFS=$as_save_IFS
28011  test -z "$as_dir" && as_dir=.
28012    for ac_exec_ext in '' $ac_executable_extensions; do
28013  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28014    ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
28015    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28016    break 2
28017  fi
28018done
28019  done
28020IFS=$as_save_IFS
28021
28022fi
28023fi
28024ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
28025if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
28027$as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
28028else
28029  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28030$as_echo "no" >&6; }
28031fi
28032
28033
28034  test -n "$ac_ct_PROPER_COMPILER_CC" && break
28035done
28036
28037  if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
28038    PROPER_COMPILER_CC=""
28039  else
28040    case $cross_compiling:$ac_tool_warned in
28041yes:)
28042{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28043$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28044ac_tool_warned=yes ;;
28045esac
28046    PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
28047  fi
28048fi
28049
28050
28051  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28052
28053  # First separate the path from the arguments. This will split at the first
28054  # space.
28055  complete="$PROPER_COMPILER_CC"
28056  path="${complete%% *}"
28057  tmp="$complete EOL"
28058  arguments="${tmp#* }"
28059
28060  # Input might be given as Windows format, start by converting to
28061  # unix format.
28062  new_path=`$CYGPATH -u "$path"`
28063
28064  # Now try to locate executable using which
28065  new_path=`$WHICH "$new_path" 2> /dev/null`
28066  # bat and cmd files are not always considered executable in cygwin causing which
28067  # to not find them
28068  if test "x$new_path" = x \
28069      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28070      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28071    new_path=`$CYGPATH -u "$path"`
28072  fi
28073  if test "x$new_path" = x; then
28074    # Oops. Which didn't find the executable.
28075    # The splitting of arguments from the executable at a space might have been incorrect,
28076    # since paths with space are more likely in Windows. Give it another try with the whole
28077    # argument.
28078    path="$complete"
28079    arguments="EOL"
28080    new_path=`$CYGPATH -u "$path"`
28081    new_path=`$WHICH "$new_path" 2> /dev/null`
28082    # bat and cmd files are not always considered executable in cygwin causing which
28083    # to not find them
28084    if test "x$new_path" = x \
28085        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28086        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28087      new_path=`$CYGPATH -u "$path"`
28088    fi
28089    if test "x$new_path" = x; then
28090      # It's still not found. Now this is an unrecoverable error.
28091      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28092$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28093      has_space=`$ECHO "$complete" | $GREP " "`
28094      if test "x$has_space" != x; then
28095        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28096$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28097      fi
28098      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28099    fi
28100  fi
28101
28102  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28103  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28104  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28105  # "foo.exe" is OK but "foo" is an error.
28106  #
28107  # This test is therefore slightly more accurate than "test -f" to check for file presence.
28108  # It is also a way to make sure we got the proper file name for the real test later on.
28109  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28110  if test "x$test_shortpath" = x; then
28111    # Short path failed, file does not exist as specified.
28112    # Try adding .exe or .cmd
28113    if test -f "${new_path}.exe"; then
28114      input_to_shortpath="${new_path}.exe"
28115    elif test -f "${new_path}.cmd"; then
28116      input_to_shortpath="${new_path}.cmd"
28117    else
28118      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
28119$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
28120      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28121$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28122      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28123    fi
28124  else
28125    input_to_shortpath="$new_path"
28126  fi
28127
28128  # Call helper function which possibly converts this using DOS-style short mode.
28129  # If so, the updated path is stored in $new_path.
28130  new_path="$input_to_shortpath"
28131
28132  input_path="$input_to_shortpath"
28133  # Check if we need to convert this using DOS-style short mode. If the path
28134  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28135  # take no chances and rewrite it.
28136  # Note: m4 eats our [], so we need to use [ and ] instead.
28137  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28138  if test "x$has_forbidden_chars" != x; then
28139    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28140    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28141    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28142    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28143      # Going to short mode and back again did indeed matter. Since short mode is
28144      # case insensitive, let's make it lowercase to improve readability.
28145      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28146      # Now convert it back to Unix-stile (cygpath)
28147      input_path=`$CYGPATH -u "$shortmode_path"`
28148      new_path="$input_path"
28149    fi
28150  fi
28151
28152  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28153  if test "x$test_cygdrive_prefix" = x; then
28154    # As a simple fix, exclude /usr/bin since it's not a real path.
28155    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28156      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28157      # a path prefixed by /cygdrive for fixpath to work.
28158      new_path="$CYGWIN_ROOT_PATH$input_path"
28159    fi
28160  fi
28161
28162  # remove trailing .exe if any
28163  new_path="${new_path/%.exe/}"
28164
28165  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28166
28167  # First separate the path from the arguments. This will split at the first
28168  # space.
28169  complete="$PROPER_COMPILER_CC"
28170  path="${complete%% *}"
28171  tmp="$complete EOL"
28172  arguments="${tmp#* }"
28173
28174  # Input might be given as Windows format, start by converting to
28175  # unix format.
28176  new_path="$path"
28177
28178  windows_path="$new_path"
28179  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28180    unix_path=`$CYGPATH -u "$windows_path"`
28181    new_path="$unix_path"
28182  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28183    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28184    new_path="$unix_path"
28185  fi
28186
28187
28188  # Now try to locate executable using which
28189  new_path=`$WHICH "$new_path" 2> /dev/null`
28190
28191  if test "x$new_path" = x; then
28192    # Oops. Which didn't find the executable.
28193    # The splitting of arguments from the executable at a space might have been incorrect,
28194    # since paths with space are more likely in Windows. Give it another try with the whole
28195    # argument.
28196    path="$complete"
28197    arguments="EOL"
28198    new_path="$path"
28199
28200  windows_path="$new_path"
28201  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28202    unix_path=`$CYGPATH -u "$windows_path"`
28203    new_path="$unix_path"
28204  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28205    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28206    new_path="$unix_path"
28207  fi
28208
28209
28210    new_path=`$WHICH "$new_path" 2> /dev/null`
28211
28212    if test "x$new_path" = x; then
28213      # It's still not found. Now this is an unrecoverable error.
28214      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28215$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28216      has_space=`$ECHO "$complete" | $GREP " "`
28217      if test "x$has_space" != x; then
28218        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28219$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28220      fi
28221      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28222    fi
28223  fi
28224
28225  # Now new_path has a complete unix path to the binary
28226  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28227    # Keep paths in /bin as-is, but remove trailing .exe if any
28228    new_path="${new_path/%.exe/}"
28229    # Do not save /bin paths to all_fixpath_prefixes!
28230  else
28231    # Not in mixed or Windows style, start by that.
28232    new_path=`cmd //c echo $new_path`
28233
28234  input_path="$new_path"
28235  # Check if we need to convert this using DOS-style short mode. If the path
28236  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28237  # take no chances and rewrite it.
28238  # Note: m4 eats our [], so we need to use [ and ] instead.
28239  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28240  if test "x$has_forbidden_chars" != x; then
28241    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28242    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28243  fi
28244
28245    # Output is in $new_path
28246
28247  windows_path="$new_path"
28248  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28249    unix_path=`$CYGPATH -u "$windows_path"`
28250    new_path="$unix_path"
28251  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28252    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28253    new_path="$unix_path"
28254  fi
28255
28256    # remove trailing .exe if any
28257    new_path="${new_path/%.exe/}"
28258
28259    # Save the first 10 bytes of this path to the storage, so fixpath can work.
28260    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28261  fi
28262
28263  else
28264    # We're on a posix platform. Hooray! :)
28265    # First separate the path from the arguments. This will split at the first
28266    # space.
28267    complete="$PROPER_COMPILER_CC"
28268    path="${complete%% *}"
28269    tmp="$complete EOL"
28270    arguments="${tmp#* }"
28271
28272    # Cannot rely on the command "which" here since it doesn't always work.
28273    is_absolute_path=`$ECHO "$path" | $GREP ^/`
28274    if test -z "$is_absolute_path"; then
28275      # Path to executable is not absolute. Find it.
28276      IFS_save="$IFS"
28277      IFS=:
28278      for p in $PATH; do
28279        if test -f "$p/$path" && test -x "$p/$path"; then
28280          new_path="$p/$path"
28281          break
28282        fi
28283      done
28284      IFS="$IFS_save"
28285    else
28286      # This is an absolute path, we can use it without further modifications.
28287      new_path="$path"
28288    fi
28289
28290    if test "x$new_path" = x; then
28291      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28292$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28293      has_space=`$ECHO "$complete" | $GREP " "`
28294      if test "x$has_space" != x; then
28295        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28296$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28297      fi
28298      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28299    fi
28300  fi
28301
28302  # Now join together the path and the arguments once again
28303  if test "x$arguments" != xEOL; then
28304    new_complete="$new_path ${arguments% *}"
28305  else
28306    new_complete="$new_path"
28307  fi
28308
28309  if test "x$complete" != "x$new_complete"; then
28310    PROPER_COMPILER_CC="$new_complete"
28311    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
28312$as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
28313  fi
28314
28315    PATH="$RETRY_COMPILER_SAVED_PATH"
28316
28317    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
28318$as_echo_n "checking for resolved symbolic links for CC... " >&6; }
28319
28320  if test "x$OPENJDK_BUILD_OS" != xwindows; then
28321    # Follow a chain of symbolic links. Use readlink
28322    # where it exists, else fall back to horribly
28323    # complicated shell code.
28324    if test "x$READLINK_TESTED" != yes; then
28325      # On MacOSX there is a readlink tool with a different
28326      # purpose than the GNU readlink tool. Check the found readlink.
28327      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28328      if test "x$ISGNU" = x; then
28329        # A readlink that we do not know how to use.
28330        # Are there other non-GNU readlinks out there?
28331        READLINK_TESTED=yes
28332        READLINK=
28333      fi
28334    fi
28335
28336    if test "x$READLINK" != x; then
28337      PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
28338    else
28339      # Save the current directory for restoring afterwards
28340      STARTDIR=$PWD
28341      COUNTER=0
28342      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
28343      sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
28344      cd $sym_link_dir
28345      # Use -P flag to resolve symlinks in directories.
28346      cd `$THEPWDCMD -P`
28347      sym_link_dir=`$THEPWDCMD -P`
28348      # Resolve file symlinks
28349      while test $COUNTER -lt 20; do
28350        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28351        if test "x$ISLINK" == x; then
28352          # This is not a symbolic link! We are done!
28353          break
28354        fi
28355        # Again resolve directory symlinks since the target of the just found
28356        # link could be in a different directory
28357        cd `$DIRNAME $ISLINK`
28358        sym_link_dir=`$THEPWDCMD -P`
28359        sym_link_file=`$BASENAME $ISLINK`
28360        let COUNTER=COUNTER+1
28361      done
28362      cd $STARTDIR
28363      PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
28364    fi
28365  fi
28366
28367    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28368$as_echo "$PROPER_COMPILER_CC" >&6; }
28369    CC="$PROPER_COMPILER_CC"
28370  else
28371    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
28372$as_echo "no, keeping CC" >&6; }
28373  fi
28374
28375
28376  COMPILER=$CC
28377  COMPILER_NAME=$COMPILER_NAME
28378
28379  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
28380    # cc -V output typically looks like
28381    #     cc: Sun C 5.12 Linux_i386 2011/11/16
28382    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
28383    # Check that this is likely to be the Solaris Studio cc.
28384    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
28385    if test $? -ne 0; then
28386      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28387      { $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
28388$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28389      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28390$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28391      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28392$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28393      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28394    fi
28395    # Remove usage instructions (if present), and
28396    # collapse compiler output into a single line
28397    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28398        $SED -e 's/ *[Uu]sage:.*//'`
28399    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28400        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
28401  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
28402    # xlc -qversion output typically looks like
28403    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
28404    #     Version: 11.01.0000.0015
28405    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
28406    # Check that this is likely to be the IBM XL C compiler.
28407    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
28408    if test $? -ne 0; then
28409      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28410      { $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
28411$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28412      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28413$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28414      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28415$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28416      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28417    fi
28418    # Collapse compiler output into a single line
28419    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28420    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28421        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
28422  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
28423    # There is no specific version flag, but all output starts with a version string.
28424    # First line typically looks something like:
28425    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
28426    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
28427    # Check that this is likely to be Microsoft CL.EXE.
28428    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
28429    if test $? -ne 0; then
28430      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28431$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28432      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28433$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28434      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28435    fi
28436    # Collapse compiler output into a single line
28437    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28438    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28439        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
28440  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
28441    # gcc --version output typically looks like
28442    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
28443    #     Copyright (C) 2013 Free Software Foundation, Inc.
28444    #     This is free software; see the source for copying conditions.  There is NO
28445    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28446    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28447    # Check that this is likely to be GCC.
28448    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
28449    if test $? -ne 0; then
28450      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28451$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28452      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
28453$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
28454      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28455    fi
28456    # Remove Copyright and legalese from version string, and
28457    # collapse into a single line
28458    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28459        $SED -e 's/ *Copyright .*//'`
28460    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28461        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
28462  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
28463    # clang --version output typically looks like
28464    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
28465    #    clang version 3.3 (tags/RELEASE_33/final)
28466    # or
28467    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
28468    #    Target: x86_64-pc-linux-gnu
28469    #    Thread model: posix
28470    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28471    # Check that this is likely to be clang
28472    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
28473    if test $? -ne 0; then
28474      { $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
28475$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28476      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28477$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28478      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28479    fi
28480    # Collapse compiler output into a single line
28481    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28482    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28483        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
28484  else
28485      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
28486  fi
28487  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
28488  CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
28489  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
28490  CC_VERSION_STRING="$COMPILER_VERSION_STRING"
28491
28492  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
28493$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
28494
28495
28496  # Now that we have resolved CC ourself, let autoconf have its go at it
28497  ac_ext=c
28498ac_cpp='$CPP $CPPFLAGS'
28499ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28500ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28501ac_compiler_gnu=$ac_cv_c_compiler_gnu
28502if test -n "$ac_tool_prefix"; then
28503  for ac_prog in $CC
28504  do
28505    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28506set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28508$as_echo_n "checking for $ac_word... " >&6; }
28509if ${ac_cv_prog_CC+:} false; then :
28510  $as_echo_n "(cached) " >&6
28511else
28512  if test -n "$CC"; then
28513  ac_cv_prog_CC="$CC" # Let the user override the test.
28514else
28515as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28516for as_dir in $PATH
28517do
28518  IFS=$as_save_IFS
28519  test -z "$as_dir" && as_dir=.
28520    for ac_exec_ext in '' $ac_executable_extensions; do
28521  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28522    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
28523    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28524    break 2
28525  fi
28526done
28527  done
28528IFS=$as_save_IFS
28529
28530fi
28531fi
28532CC=$ac_cv_prog_CC
28533if test -n "$CC"; then
28534  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
28535$as_echo "$CC" >&6; }
28536else
28537  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28538$as_echo "no" >&6; }
28539fi
28540
28541
28542    test -n "$CC" && break
28543  done
28544fi
28545if test -z "$CC"; then
28546  ac_ct_CC=$CC
28547  for ac_prog in $CC
28548do
28549  # Extract the first word of "$ac_prog", so it can be a program name with args.
28550set dummy $ac_prog; ac_word=$2
28551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28552$as_echo_n "checking for $ac_word... " >&6; }
28553if ${ac_cv_prog_ac_ct_CC+:} false; then :
28554  $as_echo_n "(cached) " >&6
28555else
28556  if test -n "$ac_ct_CC"; then
28557  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
28558else
28559as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28560for as_dir in $PATH
28561do
28562  IFS=$as_save_IFS
28563  test -z "$as_dir" && as_dir=.
28564    for ac_exec_ext in '' $ac_executable_extensions; do
28565  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28566    ac_cv_prog_ac_ct_CC="$ac_prog"
28567    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28568    break 2
28569  fi
28570done
28571  done
28572IFS=$as_save_IFS
28573
28574fi
28575fi
28576ac_ct_CC=$ac_cv_prog_ac_ct_CC
28577if test -n "$ac_ct_CC"; then
28578  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
28579$as_echo "$ac_ct_CC" >&6; }
28580else
28581  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28582$as_echo "no" >&6; }
28583fi
28584
28585
28586  test -n "$ac_ct_CC" && break
28587done
28588
28589  if test "x$ac_ct_CC" = x; then
28590    CC=""
28591  else
28592    case $cross_compiling:$ac_tool_warned in
28593yes:)
28594{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28595$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28596ac_tool_warned=yes ;;
28597esac
28598    CC=$ac_ct_CC
28599  fi
28600fi
28601
28602
28603test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28604$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28605as_fn_error $? "no acceptable C compiler found in \$PATH
28606See \`config.log' for more details" "$LINENO" 5; }
28607
28608# Provide some information about the compiler.
28609$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
28610set X $ac_compile
28611ac_compiler=$2
28612for ac_option in --version -v -V -qversion; do
28613  { { ac_try="$ac_compiler $ac_option >&5"
28614case "(($ac_try" in
28615  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28616  *) ac_try_echo=$ac_try;;
28617esac
28618eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28619$as_echo "$ac_try_echo"; } >&5
28620  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
28621  ac_status=$?
28622  if test -s conftest.err; then
28623    sed '10a\
28624... rest of stderr output deleted ...
28625         10q' conftest.err >conftest.er1
28626    cat conftest.er1 >&5
28627  fi
28628  rm -f conftest.er1 conftest.err
28629  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28630  test $ac_status = 0; }
28631done
28632
28633cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28634/* end confdefs.h.  */
28635
28636int
28637main ()
28638{
28639
28640  ;
28641  return 0;
28642}
28643_ACEOF
28644ac_clean_files_save=$ac_clean_files
28645ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
28646# Try to create an executable without -o first, disregard a.out.
28647# It will help us diagnose broken compilers, and finding out an intuition
28648# of exeext.
28649{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
28650$as_echo_n "checking whether the C compiler works... " >&6; }
28651ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
28652
28653# The possible output files:
28654ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
28655
28656ac_rmfiles=
28657for ac_file in $ac_files
28658do
28659  case $ac_file in
28660    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28661    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
28662  esac
28663done
28664rm -f $ac_rmfiles
28665
28666if { { ac_try="$ac_link_default"
28667case "(($ac_try" in
28668  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28669  *) ac_try_echo=$ac_try;;
28670esac
28671eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28672$as_echo "$ac_try_echo"; } >&5
28673  (eval "$ac_link_default") 2>&5
28674  ac_status=$?
28675  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28676  test $ac_status = 0; }; then :
28677  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
28678# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
28679# in a Makefile.  We should not override ac_cv_exeext if it was cached,
28680# so that the user can short-circuit this test for compilers unknown to
28681# Autoconf.
28682for ac_file in $ac_files ''
28683do
28684  test -f "$ac_file" || continue
28685  case $ac_file in
28686    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
28687	;;
28688    [ab].out )
28689	# We found the default executable, but exeext='' is most
28690	# certainly right.
28691	break;;
28692    *.* )
28693	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
28694	then :; else
28695	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28696	fi
28697	# We set ac_cv_exeext here because the later test for it is not
28698	# safe: cross compilers may not add the suffix if given an `-o'
28699	# argument, so we may need to know it at that point already.
28700	# Even if this section looks crufty: it has the advantage of
28701	# actually working.
28702	break;;
28703    * )
28704	break;;
28705  esac
28706done
28707test "$ac_cv_exeext" = no && ac_cv_exeext=
28708
28709else
28710  ac_file=''
28711fi
28712if test -z "$ac_file"; then :
28713  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28714$as_echo "no" >&6; }
28715$as_echo "$as_me: failed program was:" >&5
28716sed 's/^/| /' conftest.$ac_ext >&5
28717
28718{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28719$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28720as_fn_error 77 "C compiler cannot create executables
28721See \`config.log' for more details" "$LINENO" 5; }
28722else
28723  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28724$as_echo "yes" >&6; }
28725fi
28726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
28727$as_echo_n "checking for C compiler default output file name... " >&6; }
28728{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
28729$as_echo "$ac_file" >&6; }
28730ac_exeext=$ac_cv_exeext
28731
28732rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
28733ac_clean_files=$ac_clean_files_save
28734{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
28735$as_echo_n "checking for suffix of executables... " >&6; }
28736if { { ac_try="$ac_link"
28737case "(($ac_try" in
28738  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28739  *) ac_try_echo=$ac_try;;
28740esac
28741eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28742$as_echo "$ac_try_echo"; } >&5
28743  (eval "$ac_link") 2>&5
28744  ac_status=$?
28745  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28746  test $ac_status = 0; }; then :
28747  # If both `conftest.exe' and `conftest' are `present' (well, observable)
28748# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
28749# work properly (i.e., refer to `conftest.exe'), while it won't with
28750# `rm'.
28751for ac_file in conftest.exe conftest conftest.*; do
28752  test -f "$ac_file" || continue
28753  case $ac_file in
28754    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28755    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28756	  break;;
28757    * ) break;;
28758  esac
28759done
28760else
28761  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28762$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28763as_fn_error $? "cannot compute suffix of executables: cannot compile and link
28764See \`config.log' for more details" "$LINENO" 5; }
28765fi
28766rm -f conftest conftest$ac_cv_exeext
28767{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
28768$as_echo "$ac_cv_exeext" >&6; }
28769
28770rm -f conftest.$ac_ext
28771EXEEXT=$ac_cv_exeext
28772ac_exeext=$EXEEXT
28773cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28774/* end confdefs.h.  */
28775#include <stdio.h>
28776int
28777main ()
28778{
28779FILE *f = fopen ("conftest.out", "w");
28780 return ferror (f) || fclose (f) != 0;
28781
28782  ;
28783  return 0;
28784}
28785_ACEOF
28786ac_clean_files="$ac_clean_files conftest.out"
28787# Check that the compiler produces executables we can run.  If not, either
28788# the compiler is broken, or we cross compile.
28789{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
28790$as_echo_n "checking whether we are cross compiling... " >&6; }
28791if test "$cross_compiling" != yes; then
28792  { { ac_try="$ac_link"
28793case "(($ac_try" in
28794  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28795  *) ac_try_echo=$ac_try;;
28796esac
28797eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28798$as_echo "$ac_try_echo"; } >&5
28799  (eval "$ac_link") 2>&5
28800  ac_status=$?
28801  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28802  test $ac_status = 0; }
28803  if { ac_try='./conftest$ac_cv_exeext'
28804  { { case "(($ac_try" in
28805  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28806  *) ac_try_echo=$ac_try;;
28807esac
28808eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28809$as_echo "$ac_try_echo"; } >&5
28810  (eval "$ac_try") 2>&5
28811  ac_status=$?
28812  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28813  test $ac_status = 0; }; }; then
28814    cross_compiling=no
28815  else
28816    if test "$cross_compiling" = maybe; then
28817	cross_compiling=yes
28818    else
28819	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28820$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28821as_fn_error $? "cannot run C compiled programs.
28822If you meant to cross compile, use \`--host'.
28823See \`config.log' for more details" "$LINENO" 5; }
28824    fi
28825  fi
28826fi
28827{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
28828$as_echo "$cross_compiling" >&6; }
28829
28830rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
28831ac_clean_files=$ac_clean_files_save
28832{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
28833$as_echo_n "checking for suffix of object files... " >&6; }
28834if ${ac_cv_objext+:} false; then :
28835  $as_echo_n "(cached) " >&6
28836else
28837  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28838/* end confdefs.h.  */
28839
28840int
28841main ()
28842{
28843
28844  ;
28845  return 0;
28846}
28847_ACEOF
28848rm -f conftest.o conftest.obj
28849if { { ac_try="$ac_compile"
28850case "(($ac_try" in
28851  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28852  *) ac_try_echo=$ac_try;;
28853esac
28854eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28855$as_echo "$ac_try_echo"; } >&5
28856  (eval "$ac_compile") 2>&5
28857  ac_status=$?
28858  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28859  test $ac_status = 0; }; then :
28860  for ac_file in conftest.o conftest.obj conftest.*; do
28861  test -f "$ac_file" || continue;
28862  case $ac_file in
28863    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
28864    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
28865       break;;
28866  esac
28867done
28868else
28869  $as_echo "$as_me: failed program was:" >&5
28870sed 's/^/| /' conftest.$ac_ext >&5
28871
28872{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28873$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28874as_fn_error $? "cannot compute suffix of object files: cannot compile
28875See \`config.log' for more details" "$LINENO" 5; }
28876fi
28877rm -f conftest.$ac_cv_objext conftest.$ac_ext
28878fi
28879{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
28880$as_echo "$ac_cv_objext" >&6; }
28881OBJEXT=$ac_cv_objext
28882ac_objext=$OBJEXT
28883{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
28884$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
28885if ${ac_cv_c_compiler_gnu+:} false; then :
28886  $as_echo_n "(cached) " >&6
28887else
28888  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28889/* end confdefs.h.  */
28890
28891int
28892main ()
28893{
28894#ifndef __GNUC__
28895       choke me
28896#endif
28897
28898  ;
28899  return 0;
28900}
28901_ACEOF
28902if ac_fn_c_try_compile "$LINENO"; then :
28903  ac_compiler_gnu=yes
28904else
28905  ac_compiler_gnu=no
28906fi
28907rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28908ac_cv_c_compiler_gnu=$ac_compiler_gnu
28909
28910fi
28911{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
28912$as_echo "$ac_cv_c_compiler_gnu" >&6; }
28913if test $ac_compiler_gnu = yes; then
28914  GCC=yes
28915else
28916  GCC=
28917fi
28918ac_test_CFLAGS=${CFLAGS+set}
28919ac_save_CFLAGS=$CFLAGS
28920{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
28921$as_echo_n "checking whether $CC accepts -g... " >&6; }
28922if ${ac_cv_prog_cc_g+:} false; then :
28923  $as_echo_n "(cached) " >&6
28924else
28925  ac_save_c_werror_flag=$ac_c_werror_flag
28926   ac_c_werror_flag=yes
28927   ac_cv_prog_cc_g=no
28928   CFLAGS="-g"
28929   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28930/* end confdefs.h.  */
28931
28932int
28933main ()
28934{
28935
28936  ;
28937  return 0;
28938}
28939_ACEOF
28940if ac_fn_c_try_compile "$LINENO"; then :
28941  ac_cv_prog_cc_g=yes
28942else
28943  CFLAGS=""
28944      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28945/* end confdefs.h.  */
28946
28947int
28948main ()
28949{
28950
28951  ;
28952  return 0;
28953}
28954_ACEOF
28955if ac_fn_c_try_compile "$LINENO"; then :
28956
28957else
28958  ac_c_werror_flag=$ac_save_c_werror_flag
28959	 CFLAGS="-g"
28960	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28961/* end confdefs.h.  */
28962
28963int
28964main ()
28965{
28966
28967  ;
28968  return 0;
28969}
28970_ACEOF
28971if ac_fn_c_try_compile "$LINENO"; then :
28972  ac_cv_prog_cc_g=yes
28973fi
28974rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28975fi
28976rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28977fi
28978rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28979   ac_c_werror_flag=$ac_save_c_werror_flag
28980fi
28981{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
28982$as_echo "$ac_cv_prog_cc_g" >&6; }
28983if test "$ac_test_CFLAGS" = set; then
28984  CFLAGS=$ac_save_CFLAGS
28985elif test $ac_cv_prog_cc_g = yes; then
28986  if test "$GCC" = yes; then
28987    CFLAGS="-g -O2"
28988  else
28989    CFLAGS="-g"
28990  fi
28991else
28992  if test "$GCC" = yes; then
28993    CFLAGS="-O2"
28994  else
28995    CFLAGS=
28996  fi
28997fi
28998{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
28999$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
29000if ${ac_cv_prog_cc_c89+:} false; then :
29001  $as_echo_n "(cached) " >&6
29002else
29003  ac_cv_prog_cc_c89=no
29004ac_save_CC=$CC
29005cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29006/* end confdefs.h.  */
29007#include <stdarg.h>
29008#include <stdio.h>
29009struct stat;
29010/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
29011struct buf { int x; };
29012FILE * (*rcsopen) (struct buf *, struct stat *, int);
29013static char *e (p, i)
29014     char **p;
29015     int i;
29016{
29017  return p[i];
29018}
29019static char *f (char * (*g) (char **, int), char **p, ...)
29020{
29021  char *s;
29022  va_list v;
29023  va_start (v,p);
29024  s = g (p, va_arg (v,int));
29025  va_end (v);
29026  return s;
29027}
29028
29029/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
29030   function prototypes and stuff, but not '\xHH' hex character constants.
29031   These don't provoke an error unfortunately, instead are silently treated
29032   as 'x'.  The following induces an error, until -std is added to get
29033   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
29034   array size at least.  It's necessary to write '\x00'==0 to get something
29035   that's true only with -std.  */
29036int osf4_cc_array ['\x00' == 0 ? 1 : -1];
29037
29038/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
29039   inside strings and character constants.  */
29040#define FOO(x) 'x'
29041int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
29042
29043int test (int i, double x);
29044struct s1 {int (*f) (int a);};
29045struct s2 {int (*f) (double a);};
29046int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
29047int argc;
29048char **argv;
29049int
29050main ()
29051{
29052return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
29053  ;
29054  return 0;
29055}
29056_ACEOF
29057for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
29058	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
29059do
29060  CC="$ac_save_CC $ac_arg"
29061  if ac_fn_c_try_compile "$LINENO"; then :
29062  ac_cv_prog_cc_c89=$ac_arg
29063fi
29064rm -f core conftest.err conftest.$ac_objext
29065  test "x$ac_cv_prog_cc_c89" != "xno" && break
29066done
29067rm -f conftest.$ac_ext
29068CC=$ac_save_CC
29069
29070fi
29071# AC_CACHE_VAL
29072case "x$ac_cv_prog_cc_c89" in
29073  x)
29074    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
29075$as_echo "none needed" >&6; } ;;
29076  xno)
29077    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
29078$as_echo "unsupported" >&6; } ;;
29079  *)
29080    CC="$CC $ac_cv_prog_cc_c89"
29081    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
29082$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
29083esac
29084if test "x$ac_cv_prog_cc_c89" != xno; then :
29085
29086fi
29087
29088ac_ext=cpp
29089ac_cpp='$CXXCPP $CPPFLAGS'
29090ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29091ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29092ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29093
29094
29095
29096  COMPILER_NAME=C++
29097  SEARCH_LIST="$TOOLCHAIN_CXX_BINARY"
29098
29099  if test "x$CXX" != x; then
29100    # User has supplied compiler name already, always let that override.
29101    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
29102$as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
29103    if test "x`basename $CXX`" = "x$CXX"; then
29104      # A command without a complete path is provided, search $PATH.
29105
29106      for ac_prog in $CXX
29107do
29108  # Extract the first word of "$ac_prog", so it can be a program name with args.
29109set dummy $ac_prog; ac_word=$2
29110{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29111$as_echo_n "checking for $ac_word... " >&6; }
29112if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29113  $as_echo_n "(cached) " >&6
29114else
29115  case $POTENTIAL_CXX in
29116  [\\/]* | ?:[\\/]*)
29117  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29118  ;;
29119  *)
29120  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29121for as_dir in $PATH
29122do
29123  IFS=$as_save_IFS
29124  test -z "$as_dir" && as_dir=.
29125    for ac_exec_ext in '' $ac_executable_extensions; do
29126  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29127    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29128    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29129    break 2
29130  fi
29131done
29132  done
29133IFS=$as_save_IFS
29134
29135  ;;
29136esac
29137fi
29138POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29139if test -n "$POTENTIAL_CXX"; then
29140  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29141$as_echo "$POTENTIAL_CXX" >&6; }
29142else
29143  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29144$as_echo "no" >&6; }
29145fi
29146
29147
29148  test -n "$POTENTIAL_CXX" && break
29149done
29150
29151      if test "x$POTENTIAL_CXX" != x; then
29152        CXX=$POTENTIAL_CXX
29153      else
29154        as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29155      fi
29156    else
29157      # Otherwise it might already be a complete path
29158      if test ! -x "$CXX"; then
29159        as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29160      fi
29161    fi
29162  else
29163    # No user supplied value. Locate compiler ourselves.
29164
29165    # If we are cross compiling, assume cross compilation tools follows the
29166    # cross compilation standard where they are prefixed with the autoconf
29167    # standard name for the target. For example the binary
29168    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29169    # If we are not cross compiling, then the default compiler name will be
29170    # used.
29171
29172    CXX=
29173    # If TOOLS_DIR is set, check for all compiler names in there first
29174    # before checking the rest of the PATH.
29175    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29176    # step, this should not be necessary.
29177    if test -n "$TOOLS_DIR"; then
29178      PATH_save="$PATH"
29179      PATH="$TOOLS_DIR"
29180      for ac_prog in $SEARCH_LIST
29181do
29182  # Extract the first word of "$ac_prog", so it can be a program name with args.
29183set dummy $ac_prog; ac_word=$2
29184{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29185$as_echo_n "checking for $ac_word... " >&6; }
29186if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then :
29187  $as_echo_n "(cached) " >&6
29188else
29189  case $TOOLS_DIR_CXX in
29190  [\\/]* | ?:[\\/]*)
29191  ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path.
29192  ;;
29193  *)
29194  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29195for as_dir in $PATH
29196do
29197  IFS=$as_save_IFS
29198  test -z "$as_dir" && as_dir=.
29199    for ac_exec_ext in '' $ac_executable_extensions; do
29200  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29201    ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext"
29202    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29203    break 2
29204  fi
29205done
29206  done
29207IFS=$as_save_IFS
29208
29209  ;;
29210esac
29211fi
29212TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX
29213if test -n "$TOOLS_DIR_CXX"; then
29214  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5
29215$as_echo "$TOOLS_DIR_CXX" >&6; }
29216else
29217  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29218$as_echo "no" >&6; }
29219fi
29220
29221
29222  test -n "$TOOLS_DIR_CXX" && break
29223done
29224
29225      CXX=$TOOLS_DIR_CXX
29226      PATH="$PATH_save"
29227    fi
29228
29229    # AC_PATH_PROGS can't be run multiple times with the same variable,
29230    # so create a new name for this run.
29231    if test "x$CXX" = x; then
29232      for ac_prog in $SEARCH_LIST
29233do
29234  # Extract the first word of "$ac_prog", so it can be a program name with args.
29235set dummy $ac_prog; ac_word=$2
29236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29237$as_echo_n "checking for $ac_word... " >&6; }
29238if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29239  $as_echo_n "(cached) " >&6
29240else
29241  case $POTENTIAL_CXX in
29242  [\\/]* | ?:[\\/]*)
29243  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29244  ;;
29245  *)
29246  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29247for as_dir in $PATH
29248do
29249  IFS=$as_save_IFS
29250  test -z "$as_dir" && as_dir=.
29251    for ac_exec_ext in '' $ac_executable_extensions; do
29252  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29253    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29254    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29255    break 2
29256  fi
29257done
29258  done
29259IFS=$as_save_IFS
29260
29261  ;;
29262esac
29263fi
29264POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29265if test -n "$POTENTIAL_CXX"; then
29266  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29267$as_echo "$POTENTIAL_CXX" >&6; }
29268else
29269  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29270$as_echo "no" >&6; }
29271fi
29272
29273
29274  test -n "$POTENTIAL_CXX" && break
29275done
29276
29277      CXX=$POTENTIAL_CXX
29278    fi
29279
29280    if test "x$CXX" = x; then
29281
29282  # Print a helpful message on how to acquire the necessary build dependency.
29283  # devkit is the help tag: freetype, cups, pulse, alsa etc
29284  MISSING_DEPENDENCY=devkit
29285
29286  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29287    cygwin_help $MISSING_DEPENDENCY
29288  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29289    msys_help $MISSING_DEPENDENCY
29290  else
29291    PKGHANDLER_COMMAND=
29292
29293    case $PKGHANDLER in
29294      apt-get)
29295        apt_help     $MISSING_DEPENDENCY ;;
29296      yum)
29297        yum_help     $MISSING_DEPENDENCY ;;
29298      port)
29299        port_help    $MISSING_DEPENDENCY ;;
29300      pkgutil)
29301        pkgutil_help $MISSING_DEPENDENCY ;;
29302      pkgadd)
29303        pkgadd_help  $MISSING_DEPENDENCY ;;
29304    esac
29305
29306    if test "x$PKGHANDLER_COMMAND" != x; then
29307      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29308    fi
29309  fi
29310
29311      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29312    fi
29313  fi
29314
29315  # Now we have a compiler binary in CXX. Make sure it's okay.
29316
29317  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29318
29319  # First separate the path from the arguments. This will split at the first
29320  # space.
29321  complete="$CXX"
29322  path="${complete%% *}"
29323  tmp="$complete EOL"
29324  arguments="${tmp#* }"
29325
29326  # Input might be given as Windows format, start by converting to
29327  # unix format.
29328  new_path=`$CYGPATH -u "$path"`
29329
29330  # Now try to locate executable using which
29331  new_path=`$WHICH "$new_path" 2> /dev/null`
29332  # bat and cmd files are not always considered executable in cygwin causing which
29333  # to not find them
29334  if test "x$new_path" = x \
29335      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29336      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29337    new_path=`$CYGPATH -u "$path"`
29338  fi
29339  if test "x$new_path" = x; then
29340    # Oops. Which didn't find the executable.
29341    # The splitting of arguments from the executable at a space might have been incorrect,
29342    # since paths with space are more likely in Windows. Give it another try with the whole
29343    # argument.
29344    path="$complete"
29345    arguments="EOL"
29346    new_path=`$CYGPATH -u "$path"`
29347    new_path=`$WHICH "$new_path" 2> /dev/null`
29348    # bat and cmd files are not always considered executable in cygwin causing which
29349    # to not find them
29350    if test "x$new_path" = x \
29351        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29352        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29353      new_path=`$CYGPATH -u "$path"`
29354    fi
29355    if test "x$new_path" = x; then
29356      # It's still not found. Now this is an unrecoverable error.
29357      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29358$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29359      has_space=`$ECHO "$complete" | $GREP " "`
29360      if test "x$has_space" != x; then
29361        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29362$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29363      fi
29364      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29365    fi
29366  fi
29367
29368  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29369  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29370  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29371  # "foo.exe" is OK but "foo" is an error.
29372  #
29373  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29374  # It is also a way to make sure we got the proper file name for the real test later on.
29375  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29376  if test "x$test_shortpath" = x; then
29377    # Short path failed, file does not exist as specified.
29378    # Try adding .exe or .cmd
29379    if test -f "${new_path}.exe"; then
29380      input_to_shortpath="${new_path}.exe"
29381    elif test -f "${new_path}.cmd"; then
29382      input_to_shortpath="${new_path}.cmd"
29383    else
29384      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
29385$as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
29386      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29387$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29388      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29389    fi
29390  else
29391    input_to_shortpath="$new_path"
29392  fi
29393
29394  # Call helper function which possibly converts this using DOS-style short mode.
29395  # If so, the updated path is stored in $new_path.
29396  new_path="$input_to_shortpath"
29397
29398  input_path="$input_to_shortpath"
29399  # Check if we need to convert this using DOS-style short mode. If the path
29400  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29401  # take no chances and rewrite it.
29402  # Note: m4 eats our [], so we need to use [ and ] instead.
29403  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29404  if test "x$has_forbidden_chars" != x; then
29405    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29406    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29407    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29408    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29409      # Going to short mode and back again did indeed matter. Since short mode is
29410      # case insensitive, let's make it lowercase to improve readability.
29411      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29412      # Now convert it back to Unix-stile (cygpath)
29413      input_path=`$CYGPATH -u "$shortmode_path"`
29414      new_path="$input_path"
29415    fi
29416  fi
29417
29418  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29419  if test "x$test_cygdrive_prefix" = x; then
29420    # As a simple fix, exclude /usr/bin since it's not a real path.
29421    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29422      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29423      # a path prefixed by /cygdrive for fixpath to work.
29424      new_path="$CYGWIN_ROOT_PATH$input_path"
29425    fi
29426  fi
29427
29428  # remove trailing .exe if any
29429  new_path="${new_path/%.exe/}"
29430
29431  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29432
29433  # First separate the path from the arguments. This will split at the first
29434  # space.
29435  complete="$CXX"
29436  path="${complete%% *}"
29437  tmp="$complete EOL"
29438  arguments="${tmp#* }"
29439
29440  # Input might be given as Windows format, start by converting to
29441  # unix format.
29442  new_path="$path"
29443
29444  windows_path="$new_path"
29445  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29446    unix_path=`$CYGPATH -u "$windows_path"`
29447    new_path="$unix_path"
29448  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29449    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29450    new_path="$unix_path"
29451  fi
29452
29453
29454  # Now try to locate executable using which
29455  new_path=`$WHICH "$new_path" 2> /dev/null`
29456
29457  if test "x$new_path" = x; then
29458    # Oops. Which didn't find the executable.
29459    # The splitting of arguments from the executable at a space might have been incorrect,
29460    # since paths with space are more likely in Windows. Give it another try with the whole
29461    # argument.
29462    path="$complete"
29463    arguments="EOL"
29464    new_path="$path"
29465
29466  windows_path="$new_path"
29467  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29468    unix_path=`$CYGPATH -u "$windows_path"`
29469    new_path="$unix_path"
29470  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29471    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29472    new_path="$unix_path"
29473  fi
29474
29475
29476    new_path=`$WHICH "$new_path" 2> /dev/null`
29477
29478    if test "x$new_path" = x; then
29479      # It's still not found. Now this is an unrecoverable error.
29480      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29481$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29482      has_space=`$ECHO "$complete" | $GREP " "`
29483      if test "x$has_space" != x; then
29484        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29485$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29486      fi
29487      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29488    fi
29489  fi
29490
29491  # Now new_path has a complete unix path to the binary
29492  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29493    # Keep paths in /bin as-is, but remove trailing .exe if any
29494    new_path="${new_path/%.exe/}"
29495    # Do not save /bin paths to all_fixpath_prefixes!
29496  else
29497    # Not in mixed or Windows style, start by that.
29498    new_path=`cmd //c echo $new_path`
29499
29500  input_path="$new_path"
29501  # Check if we need to convert this using DOS-style short mode. If the path
29502  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29503  # take no chances and rewrite it.
29504  # Note: m4 eats our [], so we need to use [ and ] instead.
29505  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29506  if test "x$has_forbidden_chars" != x; then
29507    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29508    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29509  fi
29510
29511    # Output is in $new_path
29512
29513  windows_path="$new_path"
29514  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29515    unix_path=`$CYGPATH -u "$windows_path"`
29516    new_path="$unix_path"
29517  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29518    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29519    new_path="$unix_path"
29520  fi
29521
29522    # remove trailing .exe if any
29523    new_path="${new_path/%.exe/}"
29524
29525    # Save the first 10 bytes of this path to the storage, so fixpath can work.
29526    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29527  fi
29528
29529  else
29530    # We're on a posix platform. Hooray! :)
29531    # First separate the path from the arguments. This will split at the first
29532    # space.
29533    complete="$CXX"
29534    path="${complete%% *}"
29535    tmp="$complete EOL"
29536    arguments="${tmp#* }"
29537
29538    # Cannot rely on the command "which" here since it doesn't always work.
29539    is_absolute_path=`$ECHO "$path" | $GREP ^/`
29540    if test -z "$is_absolute_path"; then
29541      # Path to executable is not absolute. Find it.
29542      IFS_save="$IFS"
29543      IFS=:
29544      for p in $PATH; do
29545        if test -f "$p/$path" && test -x "$p/$path"; then
29546          new_path="$p/$path"
29547          break
29548        fi
29549      done
29550      IFS="$IFS_save"
29551    else
29552      # This is an absolute path, we can use it without further modifications.
29553      new_path="$path"
29554    fi
29555
29556    if test "x$new_path" = x; then
29557      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29558$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29559      has_space=`$ECHO "$complete" | $GREP " "`
29560      if test "x$has_space" != x; then
29561        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29562$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29563      fi
29564      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29565    fi
29566  fi
29567
29568  # Now join together the path and the arguments once again
29569  if test "x$arguments" != xEOL; then
29570    new_complete="$new_path ${arguments% *}"
29571  else
29572    new_complete="$new_path"
29573  fi
29574
29575  if test "x$complete" != "x$new_complete"; then
29576    CXX="$new_complete"
29577    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
29578$as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
29579  fi
29580
29581  TEST_COMPILER="$CXX"
29582  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29583  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29584  if test "x$OPENJDK_BUILD_OS" != xaix; then
29585    # FIXME: This test should not be needed anymore; we don't do that for any platform.
29586    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
29587$as_echo_n "checking resolved symbolic links for CXX... " >&6; }
29588
29589  if test "x$OPENJDK_BUILD_OS" != xwindows; then
29590    # Follow a chain of symbolic links. Use readlink
29591    # where it exists, else fall back to horribly
29592    # complicated shell code.
29593    if test "x$READLINK_TESTED" != yes; then
29594      # On MacOSX there is a readlink tool with a different
29595      # purpose than the GNU readlink tool. Check the found readlink.
29596      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29597      if test "x$ISGNU" = x; then
29598        # A readlink that we do not know how to use.
29599        # Are there other non-GNU readlinks out there?
29600        READLINK_TESTED=yes
29601        READLINK=
29602      fi
29603    fi
29604
29605    if test "x$READLINK" != x; then
29606      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29607    else
29608      # Save the current directory for restoring afterwards
29609      STARTDIR=$PWD
29610      COUNTER=0
29611      sym_link_dir=`$DIRNAME $TEST_COMPILER`
29612      sym_link_file=`$BASENAME $TEST_COMPILER`
29613      cd $sym_link_dir
29614      # Use -P flag to resolve symlinks in directories.
29615      cd `$THEPWDCMD -P`
29616      sym_link_dir=`$THEPWDCMD -P`
29617      # Resolve file symlinks
29618      while test $COUNTER -lt 20; do
29619        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
29620        if test "x$ISLINK" == x; then
29621          # This is not a symbolic link! We are done!
29622          break
29623        fi
29624        # Again resolve directory symlinks since the target of the just found
29625        # link could be in a different directory
29626        cd `$DIRNAME $ISLINK`
29627        sym_link_dir=`$THEPWDCMD -P`
29628        sym_link_file=`$BASENAME $ISLINK`
29629        let COUNTER=COUNTER+1
29630      done
29631      cd $STARTDIR
29632      TEST_COMPILER=$sym_link_dir/$sym_link_file
29633    fi
29634  fi
29635
29636    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
29637$as_echo "$TEST_COMPILER" >&6; }
29638  fi
29639  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
29640$as_echo_n "checking if CXX is disguised ccache... " >&6; }
29641
29642  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
29643  if test "x$COMPILER_BASENAME" = "xccache"; then
29644    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
29645$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
29646    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
29647    # We want to control ccache invocation ourselves, so ignore this cc and try
29648    # searching again.
29649
29650    # Remove the path to the fake ccache cc from the PATH
29651    RETRY_COMPILER_SAVED_PATH="$PATH"
29652    COMPILER_DIRNAME=`$DIRNAME $CXX`
29653    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
29654
29655    # Try again looking for our compiler
29656    if test -n "$ac_tool_prefix"; then
29657  for ac_prog in $TOOLCHAIN_CXX_BINARY
29658  do
29659    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
29660set dummy $ac_tool_prefix$ac_prog; ac_word=$2
29661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29662$as_echo_n "checking for $ac_word... " >&6; }
29663if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
29664  $as_echo_n "(cached) " >&6
29665else
29666  if test -n "$PROPER_COMPILER_CXX"; then
29667  ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
29668else
29669as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29670for as_dir in $PATH
29671do
29672  IFS=$as_save_IFS
29673  test -z "$as_dir" && as_dir=.
29674    for ac_exec_ext in '' $ac_executable_extensions; do
29675  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29676    ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
29677    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29678    break 2
29679  fi
29680done
29681  done
29682IFS=$as_save_IFS
29683
29684fi
29685fi
29686PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
29687if test -n "$PROPER_COMPILER_CXX"; then
29688  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
29689$as_echo "$PROPER_COMPILER_CXX" >&6; }
29690else
29691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29692$as_echo "no" >&6; }
29693fi
29694
29695
29696    test -n "$PROPER_COMPILER_CXX" && break
29697  done
29698fi
29699if test -z "$PROPER_COMPILER_CXX"; then
29700  ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
29701  for ac_prog in $TOOLCHAIN_CXX_BINARY
29702do
29703  # Extract the first word of "$ac_prog", so it can be a program name with args.
29704set dummy $ac_prog; ac_word=$2
29705{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29706$as_echo_n "checking for $ac_word... " >&6; }
29707if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
29708  $as_echo_n "(cached) " >&6
29709else
29710  if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29711  ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
29712else
29713as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29714for as_dir in $PATH
29715do
29716  IFS=$as_save_IFS
29717  test -z "$as_dir" && as_dir=.
29718    for ac_exec_ext in '' $ac_executable_extensions; do
29719  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29720    ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
29721    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29722    break 2
29723  fi
29724done
29725  done
29726IFS=$as_save_IFS
29727
29728fi
29729fi
29730ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
29731if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29732  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
29733$as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
29734else
29735  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29736$as_echo "no" >&6; }
29737fi
29738
29739
29740  test -n "$ac_ct_PROPER_COMPILER_CXX" && break
29741done
29742
29743  if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
29744    PROPER_COMPILER_CXX=""
29745  else
29746    case $cross_compiling:$ac_tool_warned in
29747yes:)
29748{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
29749$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
29750ac_tool_warned=yes ;;
29751esac
29752    PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
29753  fi
29754fi
29755
29756
29757  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29758
29759  # First separate the path from the arguments. This will split at the first
29760  # space.
29761  complete="$PROPER_COMPILER_CXX"
29762  path="${complete%% *}"
29763  tmp="$complete EOL"
29764  arguments="${tmp#* }"
29765
29766  # Input might be given as Windows format, start by converting to
29767  # unix format.
29768  new_path=`$CYGPATH -u "$path"`
29769
29770  # Now try to locate executable using which
29771  new_path=`$WHICH "$new_path" 2> /dev/null`
29772  # bat and cmd files are not always considered executable in cygwin causing which
29773  # to not find them
29774  if test "x$new_path" = x \
29775      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29776      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29777    new_path=`$CYGPATH -u "$path"`
29778  fi
29779  if test "x$new_path" = x; then
29780    # Oops. Which didn't find the executable.
29781    # The splitting of arguments from the executable at a space might have been incorrect,
29782    # since paths with space are more likely in Windows. Give it another try with the whole
29783    # argument.
29784    path="$complete"
29785    arguments="EOL"
29786    new_path=`$CYGPATH -u "$path"`
29787    new_path=`$WHICH "$new_path" 2> /dev/null`
29788    # bat and cmd files are not always considered executable in cygwin causing which
29789    # to not find them
29790    if test "x$new_path" = x \
29791        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29792        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29793      new_path=`$CYGPATH -u "$path"`
29794    fi
29795    if test "x$new_path" = x; then
29796      # It's still not found. Now this is an unrecoverable error.
29797      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29798$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29799      has_space=`$ECHO "$complete" | $GREP " "`
29800      if test "x$has_space" != x; then
29801        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29802$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29803      fi
29804      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29805    fi
29806  fi
29807
29808  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29809  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29810  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29811  # "foo.exe" is OK but "foo" is an error.
29812  #
29813  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29814  # It is also a way to make sure we got the proper file name for the real test later on.
29815  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29816  if test "x$test_shortpath" = x; then
29817    # Short path failed, file does not exist as specified.
29818    # Try adding .exe or .cmd
29819    if test -f "${new_path}.exe"; then
29820      input_to_shortpath="${new_path}.exe"
29821    elif test -f "${new_path}.cmd"; then
29822      input_to_shortpath="${new_path}.cmd"
29823    else
29824      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
29825$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
29826      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29827$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29828      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29829    fi
29830  else
29831    input_to_shortpath="$new_path"
29832  fi
29833
29834  # Call helper function which possibly converts this using DOS-style short mode.
29835  # If so, the updated path is stored in $new_path.
29836  new_path="$input_to_shortpath"
29837
29838  input_path="$input_to_shortpath"
29839  # Check if we need to convert this using DOS-style short mode. If the path
29840  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29841  # take no chances and rewrite it.
29842  # Note: m4 eats our [], so we need to use [ and ] instead.
29843  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29844  if test "x$has_forbidden_chars" != x; then
29845    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29846    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29847    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29848    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29849      # Going to short mode and back again did indeed matter. Since short mode is
29850      # case insensitive, let's make it lowercase to improve readability.
29851      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29852      # Now convert it back to Unix-stile (cygpath)
29853      input_path=`$CYGPATH -u "$shortmode_path"`
29854      new_path="$input_path"
29855    fi
29856  fi
29857
29858  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29859  if test "x$test_cygdrive_prefix" = x; then
29860    # As a simple fix, exclude /usr/bin since it's not a real path.
29861    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29862      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29863      # a path prefixed by /cygdrive for fixpath to work.
29864      new_path="$CYGWIN_ROOT_PATH$input_path"
29865    fi
29866  fi
29867
29868  # remove trailing .exe if any
29869  new_path="${new_path/%.exe/}"
29870
29871  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29872
29873  # First separate the path from the arguments. This will split at the first
29874  # space.
29875  complete="$PROPER_COMPILER_CXX"
29876  path="${complete%% *}"
29877  tmp="$complete EOL"
29878  arguments="${tmp#* }"
29879
29880  # Input might be given as Windows format, start by converting to
29881  # unix format.
29882  new_path="$path"
29883
29884  windows_path="$new_path"
29885  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29886    unix_path=`$CYGPATH -u "$windows_path"`
29887    new_path="$unix_path"
29888  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29889    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29890    new_path="$unix_path"
29891  fi
29892
29893
29894  # Now try to locate executable using which
29895  new_path=`$WHICH "$new_path" 2> /dev/null`
29896
29897  if test "x$new_path" = x; then
29898    # Oops. Which didn't find the executable.
29899    # The splitting of arguments from the executable at a space might have been incorrect,
29900    # since paths with space are more likely in Windows. Give it another try with the whole
29901    # argument.
29902    path="$complete"
29903    arguments="EOL"
29904    new_path="$path"
29905
29906  windows_path="$new_path"
29907  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29908    unix_path=`$CYGPATH -u "$windows_path"`
29909    new_path="$unix_path"
29910  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29911    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29912    new_path="$unix_path"
29913  fi
29914
29915
29916    new_path=`$WHICH "$new_path" 2> /dev/null`
29917
29918    if test "x$new_path" = x; then
29919      # It's still not found. Now this is an unrecoverable error.
29920      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29921$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29922      has_space=`$ECHO "$complete" | $GREP " "`
29923      if test "x$has_space" != x; then
29924        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29925$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29926      fi
29927      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29928    fi
29929  fi
29930
29931  # Now new_path has a complete unix path to the binary
29932  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29933    # Keep paths in /bin as-is, but remove trailing .exe if any
29934    new_path="${new_path/%.exe/}"
29935    # Do not save /bin paths to all_fixpath_prefixes!
29936  else
29937    # Not in mixed or Windows style, start by that.
29938    new_path=`cmd //c echo $new_path`
29939
29940  input_path="$new_path"
29941  # Check if we need to convert this using DOS-style short mode. If the path
29942  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29943  # take no chances and rewrite it.
29944  # Note: m4 eats our [], so we need to use [ and ] instead.
29945  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29946  if test "x$has_forbidden_chars" != x; then
29947    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29948    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29949  fi
29950
29951    # Output is in $new_path
29952
29953  windows_path="$new_path"
29954  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29955    unix_path=`$CYGPATH -u "$windows_path"`
29956    new_path="$unix_path"
29957  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29958    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29959    new_path="$unix_path"
29960  fi
29961
29962    # remove trailing .exe if any
29963    new_path="${new_path/%.exe/}"
29964
29965    # Save the first 10 bytes of this path to the storage, so fixpath can work.
29966    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29967  fi
29968
29969  else
29970    # We're on a posix platform. Hooray! :)
29971    # First separate the path from the arguments. This will split at the first
29972    # space.
29973    complete="$PROPER_COMPILER_CXX"
29974    path="${complete%% *}"
29975    tmp="$complete EOL"
29976    arguments="${tmp#* }"
29977
29978    # Cannot rely on the command "which" here since it doesn't always work.
29979    is_absolute_path=`$ECHO "$path" | $GREP ^/`
29980    if test -z "$is_absolute_path"; then
29981      # Path to executable is not absolute. Find it.
29982      IFS_save="$IFS"
29983      IFS=:
29984      for p in $PATH; do
29985        if test -f "$p/$path" && test -x "$p/$path"; then
29986          new_path="$p/$path"
29987          break
29988        fi
29989      done
29990      IFS="$IFS_save"
29991    else
29992      # This is an absolute path, we can use it without further modifications.
29993      new_path="$path"
29994    fi
29995
29996    if test "x$new_path" = x; then
29997      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29998$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29999      has_space=`$ECHO "$complete" | $GREP " "`
30000      if test "x$has_space" != x; then
30001        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30002$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30003      fi
30004      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30005    fi
30006  fi
30007
30008  # Now join together the path and the arguments once again
30009  if test "x$arguments" != xEOL; then
30010    new_complete="$new_path ${arguments% *}"
30011  else
30012    new_complete="$new_path"
30013  fi
30014
30015  if test "x$complete" != "x$new_complete"; then
30016    PROPER_COMPILER_CXX="$new_complete"
30017    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
30018$as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
30019  fi
30020
30021    PATH="$RETRY_COMPILER_SAVED_PATH"
30022
30023    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
30024$as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
30025
30026  if test "x$OPENJDK_BUILD_OS" != xwindows; then
30027    # Follow a chain of symbolic links. Use readlink
30028    # where it exists, else fall back to horribly
30029    # complicated shell code.
30030    if test "x$READLINK_TESTED" != yes; then
30031      # On MacOSX there is a readlink tool with a different
30032      # purpose than the GNU readlink tool. Check the found readlink.
30033      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30034      if test "x$ISGNU" = x; then
30035        # A readlink that we do not know how to use.
30036        # Are there other non-GNU readlinks out there?
30037        READLINK_TESTED=yes
30038        READLINK=
30039      fi
30040    fi
30041
30042    if test "x$READLINK" != x; then
30043      PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
30044    else
30045      # Save the current directory for restoring afterwards
30046      STARTDIR=$PWD
30047      COUNTER=0
30048      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
30049      sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
30050      cd $sym_link_dir
30051      # Use -P flag to resolve symlinks in directories.
30052      cd `$THEPWDCMD -P`
30053      sym_link_dir=`$THEPWDCMD -P`
30054      # Resolve file symlinks
30055      while test $COUNTER -lt 20; do
30056        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30057        if test "x$ISLINK" == x; then
30058          # This is not a symbolic link! We are done!
30059          break
30060        fi
30061        # Again resolve directory symlinks since the target of the just found
30062        # link could be in a different directory
30063        cd `$DIRNAME $ISLINK`
30064        sym_link_dir=`$THEPWDCMD -P`
30065        sym_link_file=`$BASENAME $ISLINK`
30066        let COUNTER=COUNTER+1
30067      done
30068      cd $STARTDIR
30069      PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
30070    fi
30071  fi
30072
30073    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30074$as_echo "$PROPER_COMPILER_CXX" >&6; }
30075    CXX="$PROPER_COMPILER_CXX"
30076  else
30077    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
30078$as_echo "no, keeping CXX" >&6; }
30079  fi
30080
30081
30082  COMPILER=$CXX
30083  COMPILER_NAME=$COMPILER_NAME
30084
30085  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
30086    # cc -V output typically looks like
30087    #     cc: Sun C 5.12 Linux_i386 2011/11/16
30088    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
30089    # Check that this is likely to be the Solaris Studio cc.
30090    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30091    if test $? -ne 0; then
30092      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30093      { $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
30094$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30095      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30096$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30097      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30098$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30099      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30100    fi
30101    # Remove usage instructions (if present), and
30102    # collapse compiler output into a single line
30103    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30104        $SED -e 's/ *[Uu]sage:.*//'`
30105    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30106        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
30107  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
30108    # xlc -qversion output typically looks like
30109    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
30110    #     Version: 11.01.0000.0015
30111    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
30112    # Check that this is likely to be the IBM XL C compiler.
30113    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
30114    if test $? -ne 0; then
30115      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30116      { $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
30117$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30118      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30119$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30120      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30121$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30122      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30123    fi
30124    # Collapse compiler output into a single line
30125    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30126    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30127        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
30128  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
30129    # There is no specific version flag, but all output starts with a version string.
30130    # First line typically looks something like:
30131    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30132    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30133    # Check that this is likely to be Microsoft CL.EXE.
30134    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
30135    if test $? -ne 0; then
30136      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30137$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30138      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30139$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30140      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30141    fi
30142    # Collapse compiler output into a single line
30143    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30144    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30145        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
30146  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
30147    # gcc --version output typically looks like
30148    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
30149    #     Copyright (C) 2013 Free Software Foundation, Inc.
30150    #     This is free software; see the source for copying conditions.  There is NO
30151    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30152    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30153    # Check that this is likely to be GCC.
30154    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
30155    if test $? -ne 0; then
30156      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30157$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30158      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
30159$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
30160      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30161    fi
30162    # Remove Copyright and legalese from version string, and
30163    # collapse into a single line
30164    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30165        $SED -e 's/ *Copyright .*//'`
30166    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30167        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
30168  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
30169    # clang --version output typically looks like
30170    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
30171    #    clang version 3.3 (tags/RELEASE_33/final)
30172    # or
30173    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
30174    #    Target: x86_64-pc-linux-gnu
30175    #    Thread model: posix
30176    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30177    # Check that this is likely to be clang
30178    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
30179    if test $? -ne 0; then
30180      { $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
30181$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30182      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30183$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30184      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30185    fi
30186    # Collapse compiler output into a single line
30187    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30188    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30189        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
30190  else
30191      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
30192  fi
30193  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
30194  CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
30195  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
30196  CXX_VERSION_STRING="$COMPILER_VERSION_STRING"
30197
30198  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
30199$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
30200
30201
30202  # Now that we have resolved CXX ourself, let autoconf have its go at it
30203  ac_ext=cpp
30204ac_cpp='$CXXCPP $CPPFLAGS'
30205ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30206ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30207ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30208if test -z "$CXX"; then
30209  if test -n "$CCC"; then
30210    CXX=$CCC
30211  else
30212    if test -n "$ac_tool_prefix"; then
30213  for ac_prog in $CXX
30214  do
30215    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30216set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30217{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30218$as_echo_n "checking for $ac_word... " >&6; }
30219if ${ac_cv_prog_CXX+:} false; then :
30220  $as_echo_n "(cached) " >&6
30221else
30222  if test -n "$CXX"; then
30223  ac_cv_prog_CXX="$CXX" # Let the user override the test.
30224else
30225as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30226for as_dir in $PATH
30227do
30228  IFS=$as_save_IFS
30229  test -z "$as_dir" && as_dir=.
30230    for ac_exec_ext in '' $ac_executable_extensions; do
30231  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30232    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
30233    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30234    break 2
30235  fi
30236done
30237  done
30238IFS=$as_save_IFS
30239
30240fi
30241fi
30242CXX=$ac_cv_prog_CXX
30243if test -n "$CXX"; then
30244  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
30245$as_echo "$CXX" >&6; }
30246else
30247  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30248$as_echo "no" >&6; }
30249fi
30250
30251
30252    test -n "$CXX" && break
30253  done
30254fi
30255if test -z "$CXX"; then
30256  ac_ct_CXX=$CXX
30257  for ac_prog in $CXX
30258do
30259  # Extract the first word of "$ac_prog", so it can be a program name with args.
30260set dummy $ac_prog; ac_word=$2
30261{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30262$as_echo_n "checking for $ac_word... " >&6; }
30263if ${ac_cv_prog_ac_ct_CXX+:} false; then :
30264  $as_echo_n "(cached) " >&6
30265else
30266  if test -n "$ac_ct_CXX"; then
30267  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
30268else
30269as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30270for as_dir in $PATH
30271do
30272  IFS=$as_save_IFS
30273  test -z "$as_dir" && as_dir=.
30274    for ac_exec_ext in '' $ac_executable_extensions; do
30275  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30276    ac_cv_prog_ac_ct_CXX="$ac_prog"
30277    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30278    break 2
30279  fi
30280done
30281  done
30282IFS=$as_save_IFS
30283
30284fi
30285fi
30286ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
30287if test -n "$ac_ct_CXX"; then
30288  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
30289$as_echo "$ac_ct_CXX" >&6; }
30290else
30291  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30292$as_echo "no" >&6; }
30293fi
30294
30295
30296  test -n "$ac_ct_CXX" && break
30297done
30298
30299  if test "x$ac_ct_CXX" = x; then
30300    CXX="g++"
30301  else
30302    case $cross_compiling:$ac_tool_warned in
30303yes:)
30304{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30305$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30306ac_tool_warned=yes ;;
30307esac
30308    CXX=$ac_ct_CXX
30309  fi
30310fi
30311
30312  fi
30313fi
30314# Provide some information about the compiler.
30315$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
30316set X $ac_compile
30317ac_compiler=$2
30318for ac_option in --version -v -V -qversion; do
30319  { { ac_try="$ac_compiler $ac_option >&5"
30320case "(($ac_try" in
30321  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30322  *) ac_try_echo=$ac_try;;
30323esac
30324eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30325$as_echo "$ac_try_echo"; } >&5
30326  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30327  ac_status=$?
30328  if test -s conftest.err; then
30329    sed '10a\
30330... rest of stderr output deleted ...
30331         10q' conftest.err >conftest.er1
30332    cat conftest.er1 >&5
30333  fi
30334  rm -f conftest.er1 conftest.err
30335  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30336  test $ac_status = 0; }
30337done
30338
30339{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
30340$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
30341if ${ac_cv_cxx_compiler_gnu+:} false; then :
30342  $as_echo_n "(cached) " >&6
30343else
30344  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30345/* end confdefs.h.  */
30346
30347int
30348main ()
30349{
30350#ifndef __GNUC__
30351       choke me
30352#endif
30353
30354  ;
30355  return 0;
30356}
30357_ACEOF
30358if ac_fn_cxx_try_compile "$LINENO"; then :
30359  ac_compiler_gnu=yes
30360else
30361  ac_compiler_gnu=no
30362fi
30363rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30364ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
30365
30366fi
30367{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
30368$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
30369if test $ac_compiler_gnu = yes; then
30370  GXX=yes
30371else
30372  GXX=
30373fi
30374ac_test_CXXFLAGS=${CXXFLAGS+set}
30375ac_save_CXXFLAGS=$CXXFLAGS
30376{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
30377$as_echo_n "checking whether $CXX accepts -g... " >&6; }
30378if ${ac_cv_prog_cxx_g+:} false; then :
30379  $as_echo_n "(cached) " >&6
30380else
30381  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
30382   ac_cxx_werror_flag=yes
30383   ac_cv_prog_cxx_g=no
30384   CXXFLAGS="-g"
30385   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30386/* end confdefs.h.  */
30387
30388int
30389main ()
30390{
30391
30392  ;
30393  return 0;
30394}
30395_ACEOF
30396if ac_fn_cxx_try_compile "$LINENO"; then :
30397  ac_cv_prog_cxx_g=yes
30398else
30399  CXXFLAGS=""
30400      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30401/* end confdefs.h.  */
30402
30403int
30404main ()
30405{
30406
30407  ;
30408  return 0;
30409}
30410_ACEOF
30411if ac_fn_cxx_try_compile "$LINENO"; then :
30412
30413else
30414  ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30415	 CXXFLAGS="-g"
30416	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30417/* end confdefs.h.  */
30418
30419int
30420main ()
30421{
30422
30423  ;
30424  return 0;
30425}
30426_ACEOF
30427if ac_fn_cxx_try_compile "$LINENO"; then :
30428  ac_cv_prog_cxx_g=yes
30429fi
30430rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30431fi
30432rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30433fi
30434rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30435   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30436fi
30437{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
30438$as_echo "$ac_cv_prog_cxx_g" >&6; }
30439if test "$ac_test_CXXFLAGS" = set; then
30440  CXXFLAGS=$ac_save_CXXFLAGS
30441elif test $ac_cv_prog_cxx_g = yes; then
30442  if test "$GXX" = yes; then
30443    CXXFLAGS="-g -O2"
30444  else
30445    CXXFLAGS="-g"
30446  fi
30447else
30448  if test "$GXX" = yes; then
30449    CXXFLAGS="-O2"
30450  else
30451    CXXFLAGS=
30452  fi
30453fi
30454ac_ext=cpp
30455ac_cpp='$CXXCPP $CPPFLAGS'
30456ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30457ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30458ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30459
30460
30461  #
30462  # Setup the preprocessor (CPP and CXXCPP)
30463  #
30464  ac_ext=c
30465ac_cpp='$CPP $CPPFLAGS'
30466ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30467ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30468ac_compiler_gnu=$ac_cv_c_compiler_gnu
30469{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
30470$as_echo_n "checking how to run the C preprocessor... " >&6; }
30471# On Suns, sometimes $CPP names a directory.
30472if test -n "$CPP" && test -d "$CPP"; then
30473  CPP=
30474fi
30475if test -z "$CPP"; then
30476  if ${ac_cv_prog_CPP+:} false; then :
30477  $as_echo_n "(cached) " >&6
30478else
30479      # Double quotes because CPP needs to be expanded
30480    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
30481    do
30482      ac_preproc_ok=false
30483for ac_c_preproc_warn_flag in '' yes
30484do
30485  # Use a header file that comes with gcc, so configuring glibc
30486  # with a fresh cross-compiler works.
30487  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30488  # <limits.h> exists even on freestanding compilers.
30489  # On the NeXT, cc -E runs the code through the compiler's parser,
30490  # not just through cpp. "Syntax error" is here to catch this case.
30491  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30492/* end confdefs.h.  */
30493#ifdef __STDC__
30494# include <limits.h>
30495#else
30496# include <assert.h>
30497#endif
30498		     Syntax error
30499_ACEOF
30500if ac_fn_c_try_cpp "$LINENO"; then :
30501
30502else
30503  # Broken: fails on valid input.
30504continue
30505fi
30506rm -f conftest.err conftest.i conftest.$ac_ext
30507
30508  # OK, works on sane cases.  Now check whether nonexistent headers
30509  # can be detected and how.
30510  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30511/* end confdefs.h.  */
30512#include <ac_nonexistent.h>
30513_ACEOF
30514if ac_fn_c_try_cpp "$LINENO"; then :
30515  # Broken: success on invalid input.
30516continue
30517else
30518  # Passes both tests.
30519ac_preproc_ok=:
30520break
30521fi
30522rm -f conftest.err conftest.i conftest.$ac_ext
30523
30524done
30525# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30526rm -f conftest.i conftest.err conftest.$ac_ext
30527if $ac_preproc_ok; then :
30528  break
30529fi
30530
30531    done
30532    ac_cv_prog_CPP=$CPP
30533
30534fi
30535  CPP=$ac_cv_prog_CPP
30536else
30537  ac_cv_prog_CPP=$CPP
30538fi
30539{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
30540$as_echo "$CPP" >&6; }
30541ac_preproc_ok=false
30542for ac_c_preproc_warn_flag in '' yes
30543do
30544  # Use a header file that comes with gcc, so configuring glibc
30545  # with a fresh cross-compiler works.
30546  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30547  # <limits.h> exists even on freestanding compilers.
30548  # On the NeXT, cc -E runs the code through the compiler's parser,
30549  # not just through cpp. "Syntax error" is here to catch this case.
30550  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30551/* end confdefs.h.  */
30552#ifdef __STDC__
30553# include <limits.h>
30554#else
30555# include <assert.h>
30556#endif
30557		     Syntax error
30558_ACEOF
30559if ac_fn_c_try_cpp "$LINENO"; then :
30560
30561else
30562  # Broken: fails on valid input.
30563continue
30564fi
30565rm -f conftest.err conftest.i conftest.$ac_ext
30566
30567  # OK, works on sane cases.  Now check whether nonexistent headers
30568  # can be detected and how.
30569  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30570/* end confdefs.h.  */
30571#include <ac_nonexistent.h>
30572_ACEOF
30573if ac_fn_c_try_cpp "$LINENO"; then :
30574  # Broken: success on invalid input.
30575continue
30576else
30577  # Passes both tests.
30578ac_preproc_ok=:
30579break
30580fi
30581rm -f conftest.err conftest.i conftest.$ac_ext
30582
30583done
30584# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30585rm -f conftest.i conftest.err conftest.$ac_ext
30586if $ac_preproc_ok; then :
30587
30588else
30589  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30590$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30591as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
30592See \`config.log' for more details" "$LINENO" 5; }
30593fi
30594
30595ac_ext=cpp
30596ac_cpp='$CXXCPP $CPPFLAGS'
30597ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30598ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30599ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30600
30601
30602  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30603
30604  # First separate the path from the arguments. This will split at the first
30605  # space.
30606  complete="$CPP"
30607  path="${complete%% *}"
30608  tmp="$complete EOL"
30609  arguments="${tmp#* }"
30610
30611  # Input might be given as Windows format, start by converting to
30612  # unix format.
30613  new_path=`$CYGPATH -u "$path"`
30614
30615  # Now try to locate executable using which
30616  new_path=`$WHICH "$new_path" 2> /dev/null`
30617  # bat and cmd files are not always considered executable in cygwin causing which
30618  # to not find them
30619  if test "x$new_path" = x \
30620      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30621      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30622    new_path=`$CYGPATH -u "$path"`
30623  fi
30624  if test "x$new_path" = x; then
30625    # Oops. Which didn't find the executable.
30626    # The splitting of arguments from the executable at a space might have been incorrect,
30627    # since paths with space are more likely in Windows. Give it another try with the whole
30628    # argument.
30629    path="$complete"
30630    arguments="EOL"
30631    new_path=`$CYGPATH -u "$path"`
30632    new_path=`$WHICH "$new_path" 2> /dev/null`
30633    # bat and cmd files are not always considered executable in cygwin causing which
30634    # to not find them
30635    if test "x$new_path" = x \
30636        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30637        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30638      new_path=`$CYGPATH -u "$path"`
30639    fi
30640    if test "x$new_path" = x; then
30641      # It's still not found. Now this is an unrecoverable error.
30642      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30643$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30644      has_space=`$ECHO "$complete" | $GREP " "`
30645      if test "x$has_space" != x; then
30646        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30647$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30648      fi
30649      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30650    fi
30651  fi
30652
30653  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30654  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30655  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30656  # "foo.exe" is OK but "foo" is an error.
30657  #
30658  # This test is therefore slightly more accurate than "test -f" to check for file presence.
30659  # It is also a way to make sure we got the proper file name for the real test later on.
30660  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30661  if test "x$test_shortpath" = x; then
30662    # Short path failed, file does not exist as specified.
30663    # Try adding .exe or .cmd
30664    if test -f "${new_path}.exe"; then
30665      input_to_shortpath="${new_path}.exe"
30666    elif test -f "${new_path}.cmd"; then
30667      input_to_shortpath="${new_path}.cmd"
30668    else
30669      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
30670$as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
30671      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30672$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30673      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30674    fi
30675  else
30676    input_to_shortpath="$new_path"
30677  fi
30678
30679  # Call helper function which possibly converts this using DOS-style short mode.
30680  # If so, the updated path is stored in $new_path.
30681  new_path="$input_to_shortpath"
30682
30683  input_path="$input_to_shortpath"
30684  # Check if we need to convert this using DOS-style short mode. If the path
30685  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30686  # take no chances and rewrite it.
30687  # Note: m4 eats our [], so we need to use [ and ] instead.
30688  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30689  if test "x$has_forbidden_chars" != x; then
30690    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30691    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30692    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30693    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30694      # Going to short mode and back again did indeed matter. Since short mode is
30695      # case insensitive, let's make it lowercase to improve readability.
30696      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30697      # Now convert it back to Unix-stile (cygpath)
30698      input_path=`$CYGPATH -u "$shortmode_path"`
30699      new_path="$input_path"
30700    fi
30701  fi
30702
30703  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30704  if test "x$test_cygdrive_prefix" = x; then
30705    # As a simple fix, exclude /usr/bin since it's not a real path.
30706    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30707      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30708      # a path prefixed by /cygdrive for fixpath to work.
30709      new_path="$CYGWIN_ROOT_PATH$input_path"
30710    fi
30711  fi
30712
30713  # remove trailing .exe if any
30714  new_path="${new_path/%.exe/}"
30715
30716  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30717
30718  # First separate the path from the arguments. This will split at the first
30719  # space.
30720  complete="$CPP"
30721  path="${complete%% *}"
30722  tmp="$complete EOL"
30723  arguments="${tmp#* }"
30724
30725  # Input might be given as Windows format, start by converting to
30726  # unix format.
30727  new_path="$path"
30728
30729  windows_path="$new_path"
30730  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30731    unix_path=`$CYGPATH -u "$windows_path"`
30732    new_path="$unix_path"
30733  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30734    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30735    new_path="$unix_path"
30736  fi
30737
30738
30739  # Now try to locate executable using which
30740  new_path=`$WHICH "$new_path" 2> /dev/null`
30741
30742  if test "x$new_path" = x; then
30743    # Oops. Which didn't find the executable.
30744    # The splitting of arguments from the executable at a space might have been incorrect,
30745    # since paths with space are more likely in Windows. Give it another try with the whole
30746    # argument.
30747    path="$complete"
30748    arguments="EOL"
30749    new_path="$path"
30750
30751  windows_path="$new_path"
30752  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30753    unix_path=`$CYGPATH -u "$windows_path"`
30754    new_path="$unix_path"
30755  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30756    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30757    new_path="$unix_path"
30758  fi
30759
30760
30761    new_path=`$WHICH "$new_path" 2> /dev/null`
30762
30763    if test "x$new_path" = x; then
30764      # It's still not found. Now this is an unrecoverable error.
30765      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30766$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30767      has_space=`$ECHO "$complete" | $GREP " "`
30768      if test "x$has_space" != x; then
30769        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30770$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30771      fi
30772      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30773    fi
30774  fi
30775
30776  # Now new_path has a complete unix path to the binary
30777  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30778    # Keep paths in /bin as-is, but remove trailing .exe if any
30779    new_path="${new_path/%.exe/}"
30780    # Do not save /bin paths to all_fixpath_prefixes!
30781  else
30782    # Not in mixed or Windows style, start by that.
30783    new_path=`cmd //c echo $new_path`
30784
30785  input_path="$new_path"
30786  # Check if we need to convert this using DOS-style short mode. If the path
30787  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30788  # take no chances and rewrite it.
30789  # Note: m4 eats our [], so we need to use [ and ] instead.
30790  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30791  if test "x$has_forbidden_chars" != x; then
30792    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30793    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30794  fi
30795
30796    # Output is in $new_path
30797
30798  windows_path="$new_path"
30799  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30800    unix_path=`$CYGPATH -u "$windows_path"`
30801    new_path="$unix_path"
30802  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30803    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30804    new_path="$unix_path"
30805  fi
30806
30807    # remove trailing .exe if any
30808    new_path="${new_path/%.exe/}"
30809
30810    # Save the first 10 bytes of this path to the storage, so fixpath can work.
30811    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30812  fi
30813
30814  else
30815    # We're on a posix platform. Hooray! :)
30816    # First separate the path from the arguments. This will split at the first
30817    # space.
30818    complete="$CPP"
30819    path="${complete%% *}"
30820    tmp="$complete EOL"
30821    arguments="${tmp#* }"
30822
30823    # Cannot rely on the command "which" here since it doesn't always work.
30824    is_absolute_path=`$ECHO "$path" | $GREP ^/`
30825    if test -z "$is_absolute_path"; then
30826      # Path to executable is not absolute. Find it.
30827      IFS_save="$IFS"
30828      IFS=:
30829      for p in $PATH; do
30830        if test -f "$p/$path" && test -x "$p/$path"; then
30831          new_path="$p/$path"
30832          break
30833        fi
30834      done
30835      IFS="$IFS_save"
30836    else
30837      # This is an absolute path, we can use it without further modifications.
30838      new_path="$path"
30839    fi
30840
30841    if test "x$new_path" = x; then
30842      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30843$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30844      has_space=`$ECHO "$complete" | $GREP " "`
30845      if test "x$has_space" != x; then
30846        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30847$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30848      fi
30849      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30850    fi
30851  fi
30852
30853  # Now join together the path and the arguments once again
30854  if test "x$arguments" != xEOL; then
30855    new_complete="$new_path ${arguments% *}"
30856  else
30857    new_complete="$new_path"
30858  fi
30859
30860  if test "x$complete" != "x$new_complete"; then
30861    CPP="$new_complete"
30862    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
30863$as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
30864  fi
30865
30866  ac_ext=cpp
30867ac_cpp='$CXXCPP $CPPFLAGS'
30868ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30869ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30870ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30871{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
30872$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
30873if test -z "$CXXCPP"; then
30874  if ${ac_cv_prog_CXXCPP+:} false; then :
30875  $as_echo_n "(cached) " >&6
30876else
30877      # Double quotes because CXXCPP needs to be expanded
30878    for CXXCPP in "$CXX -E" "/lib/cpp"
30879    do
30880      ac_preproc_ok=false
30881for ac_cxx_preproc_warn_flag in '' yes
30882do
30883  # Use a header file that comes with gcc, so configuring glibc
30884  # with a fresh cross-compiler works.
30885  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30886  # <limits.h> exists even on freestanding compilers.
30887  # On the NeXT, cc -E runs the code through the compiler's parser,
30888  # not just through cpp. "Syntax error" is here to catch this case.
30889  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30890/* end confdefs.h.  */
30891#ifdef __STDC__
30892# include <limits.h>
30893#else
30894# include <assert.h>
30895#endif
30896		     Syntax error
30897_ACEOF
30898if ac_fn_cxx_try_cpp "$LINENO"; then :
30899
30900else
30901  # Broken: fails on valid input.
30902continue
30903fi
30904rm -f conftest.err conftest.i conftest.$ac_ext
30905
30906  # OK, works on sane cases.  Now check whether nonexistent headers
30907  # can be detected and how.
30908  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30909/* end confdefs.h.  */
30910#include <ac_nonexistent.h>
30911_ACEOF
30912if ac_fn_cxx_try_cpp "$LINENO"; then :
30913  # Broken: success on invalid input.
30914continue
30915else
30916  # Passes both tests.
30917ac_preproc_ok=:
30918break
30919fi
30920rm -f conftest.err conftest.i conftest.$ac_ext
30921
30922done
30923# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30924rm -f conftest.i conftest.err conftest.$ac_ext
30925if $ac_preproc_ok; then :
30926  break
30927fi
30928
30929    done
30930    ac_cv_prog_CXXCPP=$CXXCPP
30931
30932fi
30933  CXXCPP=$ac_cv_prog_CXXCPP
30934else
30935  ac_cv_prog_CXXCPP=$CXXCPP
30936fi
30937{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
30938$as_echo "$CXXCPP" >&6; }
30939ac_preproc_ok=false
30940for ac_cxx_preproc_warn_flag in '' yes
30941do
30942  # Use a header file that comes with gcc, so configuring glibc
30943  # with a fresh cross-compiler works.
30944  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30945  # <limits.h> exists even on freestanding compilers.
30946  # On the NeXT, cc -E runs the code through the compiler's parser,
30947  # not just through cpp. "Syntax error" is here to catch this case.
30948  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30949/* end confdefs.h.  */
30950#ifdef __STDC__
30951# include <limits.h>
30952#else
30953# include <assert.h>
30954#endif
30955		     Syntax error
30956_ACEOF
30957if ac_fn_cxx_try_cpp "$LINENO"; then :
30958
30959else
30960  # Broken: fails on valid input.
30961continue
30962fi
30963rm -f conftest.err conftest.i conftest.$ac_ext
30964
30965  # OK, works on sane cases.  Now check whether nonexistent headers
30966  # can be detected and how.
30967  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30968/* end confdefs.h.  */
30969#include <ac_nonexistent.h>
30970_ACEOF
30971if ac_fn_cxx_try_cpp "$LINENO"; then :
30972  # Broken: success on invalid input.
30973continue
30974else
30975  # Passes both tests.
30976ac_preproc_ok=:
30977break
30978fi
30979rm -f conftest.err conftest.i conftest.$ac_ext
30980
30981done
30982# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30983rm -f conftest.i conftest.err conftest.$ac_ext
30984if $ac_preproc_ok; then :
30985
30986else
30987  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30988$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30989as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
30990See \`config.log' for more details" "$LINENO" 5; }
30991fi
30992
30993ac_ext=cpp
30994ac_cpp='$CXXCPP $CPPFLAGS'
30995ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30996ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30997ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30998
30999
31000  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31001
31002  # First separate the path from the arguments. This will split at the first
31003  # space.
31004  complete="$CXXCPP"
31005  path="${complete%% *}"
31006  tmp="$complete EOL"
31007  arguments="${tmp#* }"
31008
31009  # Input might be given as Windows format, start by converting to
31010  # unix format.
31011  new_path=`$CYGPATH -u "$path"`
31012
31013  # Now try to locate executable using which
31014  new_path=`$WHICH "$new_path" 2> /dev/null`
31015  # bat and cmd files are not always considered executable in cygwin causing which
31016  # to not find them
31017  if test "x$new_path" = x \
31018      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31019      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31020    new_path=`$CYGPATH -u "$path"`
31021  fi
31022  if test "x$new_path" = x; then
31023    # Oops. Which didn't find the executable.
31024    # The splitting of arguments from the executable at a space might have been incorrect,
31025    # since paths with space are more likely in Windows. Give it another try with the whole
31026    # argument.
31027    path="$complete"
31028    arguments="EOL"
31029    new_path=`$CYGPATH -u "$path"`
31030    new_path=`$WHICH "$new_path" 2> /dev/null`
31031    # bat and cmd files are not always considered executable in cygwin causing which
31032    # to not find them
31033    if test "x$new_path" = x \
31034        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31035        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31036      new_path=`$CYGPATH -u "$path"`
31037    fi
31038    if test "x$new_path" = x; then
31039      # It's still not found. Now this is an unrecoverable error.
31040      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31041$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31042      has_space=`$ECHO "$complete" | $GREP " "`
31043      if test "x$has_space" != x; then
31044        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31045$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31046      fi
31047      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31048    fi
31049  fi
31050
31051  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31052  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31053  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31054  # "foo.exe" is OK but "foo" is an error.
31055  #
31056  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31057  # It is also a way to make sure we got the proper file name for the real test later on.
31058  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31059  if test "x$test_shortpath" = x; then
31060    # Short path failed, file does not exist as specified.
31061    # Try adding .exe or .cmd
31062    if test -f "${new_path}.exe"; then
31063      input_to_shortpath="${new_path}.exe"
31064    elif test -f "${new_path}.cmd"; then
31065      input_to_shortpath="${new_path}.cmd"
31066    else
31067      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
31068$as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
31069      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31070$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31071      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31072    fi
31073  else
31074    input_to_shortpath="$new_path"
31075  fi
31076
31077  # Call helper function which possibly converts this using DOS-style short mode.
31078  # If so, the updated path is stored in $new_path.
31079  new_path="$input_to_shortpath"
31080
31081  input_path="$input_to_shortpath"
31082  # Check if we need to convert this using DOS-style short mode. If the path
31083  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31084  # take no chances and rewrite it.
31085  # Note: m4 eats our [], so we need to use [ and ] instead.
31086  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31087  if test "x$has_forbidden_chars" != x; then
31088    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31089    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31090    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31091    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31092      # Going to short mode and back again did indeed matter. Since short mode is
31093      # case insensitive, let's make it lowercase to improve readability.
31094      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31095      # Now convert it back to Unix-stile (cygpath)
31096      input_path=`$CYGPATH -u "$shortmode_path"`
31097      new_path="$input_path"
31098    fi
31099  fi
31100
31101  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31102  if test "x$test_cygdrive_prefix" = x; then
31103    # As a simple fix, exclude /usr/bin since it's not a real path.
31104    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31105      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31106      # a path prefixed by /cygdrive for fixpath to work.
31107      new_path="$CYGWIN_ROOT_PATH$input_path"
31108    fi
31109  fi
31110
31111  # remove trailing .exe if any
31112  new_path="${new_path/%.exe/}"
31113
31114  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31115
31116  # First separate the path from the arguments. This will split at the first
31117  # space.
31118  complete="$CXXCPP"
31119  path="${complete%% *}"
31120  tmp="$complete EOL"
31121  arguments="${tmp#* }"
31122
31123  # Input might be given as Windows format, start by converting to
31124  # unix format.
31125  new_path="$path"
31126
31127  windows_path="$new_path"
31128  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31129    unix_path=`$CYGPATH -u "$windows_path"`
31130    new_path="$unix_path"
31131  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31132    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31133    new_path="$unix_path"
31134  fi
31135
31136
31137  # Now try to locate executable using which
31138  new_path=`$WHICH "$new_path" 2> /dev/null`
31139
31140  if test "x$new_path" = x; then
31141    # Oops. Which didn't find the executable.
31142    # The splitting of arguments from the executable at a space might have been incorrect,
31143    # since paths with space are more likely in Windows. Give it another try with the whole
31144    # argument.
31145    path="$complete"
31146    arguments="EOL"
31147    new_path="$path"
31148
31149  windows_path="$new_path"
31150  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31151    unix_path=`$CYGPATH -u "$windows_path"`
31152    new_path="$unix_path"
31153  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31154    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31155    new_path="$unix_path"
31156  fi
31157
31158
31159    new_path=`$WHICH "$new_path" 2> /dev/null`
31160
31161    if test "x$new_path" = x; then
31162      # It's still not found. Now this is an unrecoverable error.
31163      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31164$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31165      has_space=`$ECHO "$complete" | $GREP " "`
31166      if test "x$has_space" != x; then
31167        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31168$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31169      fi
31170      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31171    fi
31172  fi
31173
31174  # Now new_path has a complete unix path to the binary
31175  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31176    # Keep paths in /bin as-is, but remove trailing .exe if any
31177    new_path="${new_path/%.exe/}"
31178    # Do not save /bin paths to all_fixpath_prefixes!
31179  else
31180    # Not in mixed or Windows style, start by that.
31181    new_path=`cmd //c echo $new_path`
31182
31183  input_path="$new_path"
31184  # Check if we need to convert this using DOS-style short mode. If the path
31185  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31186  # take no chances and rewrite it.
31187  # Note: m4 eats our [], so we need to use [ and ] instead.
31188  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31189  if test "x$has_forbidden_chars" != x; then
31190    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31191    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31192  fi
31193
31194    # Output is in $new_path
31195
31196  windows_path="$new_path"
31197  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31198    unix_path=`$CYGPATH -u "$windows_path"`
31199    new_path="$unix_path"
31200  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31201    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31202    new_path="$unix_path"
31203  fi
31204
31205    # remove trailing .exe if any
31206    new_path="${new_path/%.exe/}"
31207
31208    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31209    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31210  fi
31211
31212  else
31213    # We're on a posix platform. Hooray! :)
31214    # First separate the path from the arguments. This will split at the first
31215    # space.
31216    complete="$CXXCPP"
31217    path="${complete%% *}"
31218    tmp="$complete EOL"
31219    arguments="${tmp#* }"
31220
31221    # Cannot rely on the command "which" here since it doesn't always work.
31222    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31223    if test -z "$is_absolute_path"; then
31224      # Path to executable is not absolute. Find it.
31225      IFS_save="$IFS"
31226      IFS=:
31227      for p in $PATH; do
31228        if test -f "$p/$path" && test -x "$p/$path"; then
31229          new_path="$p/$path"
31230          break
31231        fi
31232      done
31233      IFS="$IFS_save"
31234    else
31235      # This is an absolute path, we can use it without further modifications.
31236      new_path="$path"
31237    fi
31238
31239    if test "x$new_path" = x; then
31240      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31241$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31242      has_space=`$ECHO "$complete" | $GREP " "`
31243      if test "x$has_space" != x; then
31244        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31245$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31246      fi
31247      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31248    fi
31249  fi
31250
31251  # Now join together the path and the arguments once again
31252  if test "x$arguments" != xEOL; then
31253    new_complete="$new_path ${arguments% *}"
31254  else
31255    new_complete="$new_path"
31256  fi
31257
31258  if test "x$complete" != "x$new_complete"; then
31259    CXXCPP="$new_complete"
31260    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
31261$as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
31262  fi
31263
31264
31265  #
31266  # Setup the linker (LD)
31267  #
31268  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
31269    # In the Microsoft toolchain we have a separate LD command "link".
31270    # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is
31271    # a cygwin program for something completely different.
31272    # Extract the first word of "link", so it can be a program name with args.
31273set dummy link; ac_word=$2
31274{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31275$as_echo_n "checking for $ac_word... " >&6; }
31276if ${ac_cv_prog_LD+:} false; then :
31277  $as_echo_n "(cached) " >&6
31278else
31279  if test -n "$LD"; then
31280  ac_cv_prog_LD="$LD" # Let the user override the test.
31281else
31282  ac_prog_rejected=no
31283as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31284for as_dir in $PATH
31285do
31286  IFS=$as_save_IFS
31287  test -z "$as_dir" && as_dir=.
31288    for ac_exec_ext in '' $ac_executable_extensions; do
31289  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31290    if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
31291       ac_prog_rejected=yes
31292       continue
31293     fi
31294    ac_cv_prog_LD="link"
31295    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31296    break 2
31297  fi
31298done
31299  done
31300IFS=$as_save_IFS
31301
31302if test $ac_prog_rejected = yes; then
31303  # We found a bogon in the path, so make sure we never use it.
31304  set dummy $ac_cv_prog_LD
31305  shift
31306  if test $# != 0; then
31307    # We chose a different compiler from the bogus one.
31308    # However, it has the same basename, so the bogon will be chosen
31309    # first if we set LD to just the basename; use the full file name.
31310    shift
31311    ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@"
31312  fi
31313fi
31314fi
31315fi
31316LD=$ac_cv_prog_LD
31317if test -n "$LD"; then
31318  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
31319$as_echo "$LD" >&6; }
31320else
31321  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31322$as_echo "no" >&6; }
31323fi
31324
31325
31326
31327  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31328
31329  # First separate the path from the arguments. This will split at the first
31330  # space.
31331  complete="$LD"
31332  path="${complete%% *}"
31333  tmp="$complete EOL"
31334  arguments="${tmp#* }"
31335
31336  # Input might be given as Windows format, start by converting to
31337  # unix format.
31338  new_path=`$CYGPATH -u "$path"`
31339
31340  # Now try to locate executable using which
31341  new_path=`$WHICH "$new_path" 2> /dev/null`
31342  # bat and cmd files are not always considered executable in cygwin causing which
31343  # to not find them
31344  if test "x$new_path" = x \
31345      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31346      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31347    new_path=`$CYGPATH -u "$path"`
31348  fi
31349  if test "x$new_path" = x; then
31350    # Oops. Which didn't find the executable.
31351    # The splitting of arguments from the executable at a space might have been incorrect,
31352    # since paths with space are more likely in Windows. Give it another try with the whole
31353    # argument.
31354    path="$complete"
31355    arguments="EOL"
31356    new_path=`$CYGPATH -u "$path"`
31357    new_path=`$WHICH "$new_path" 2> /dev/null`
31358    # bat and cmd files are not always considered executable in cygwin causing which
31359    # to not find them
31360    if test "x$new_path" = x \
31361        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31362        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31363      new_path=`$CYGPATH -u "$path"`
31364    fi
31365    if test "x$new_path" = x; then
31366      # It's still not found. Now this is an unrecoverable error.
31367      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31368$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31369      has_space=`$ECHO "$complete" | $GREP " "`
31370      if test "x$has_space" != x; then
31371        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31372$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31373      fi
31374      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31375    fi
31376  fi
31377
31378  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31379  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31380  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31381  # "foo.exe" is OK but "foo" is an error.
31382  #
31383  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31384  # It is also a way to make sure we got the proper file name for the real test later on.
31385  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31386  if test "x$test_shortpath" = x; then
31387    # Short path failed, file does not exist as specified.
31388    # Try adding .exe or .cmd
31389    if test -f "${new_path}.exe"; then
31390      input_to_shortpath="${new_path}.exe"
31391    elif test -f "${new_path}.cmd"; then
31392      input_to_shortpath="${new_path}.cmd"
31393    else
31394      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5
31395$as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;}
31396      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31397$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31398      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31399    fi
31400  else
31401    input_to_shortpath="$new_path"
31402  fi
31403
31404  # Call helper function which possibly converts this using DOS-style short mode.
31405  # If so, the updated path is stored in $new_path.
31406  new_path="$input_to_shortpath"
31407
31408  input_path="$input_to_shortpath"
31409  # Check if we need to convert this using DOS-style short mode. If the path
31410  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31411  # take no chances and rewrite it.
31412  # Note: m4 eats our [], so we need to use [ and ] instead.
31413  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31414  if test "x$has_forbidden_chars" != x; then
31415    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31416    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31417    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31418    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31419      # Going to short mode and back again did indeed matter. Since short mode is
31420      # case insensitive, let's make it lowercase to improve readability.
31421      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31422      # Now convert it back to Unix-stile (cygpath)
31423      input_path=`$CYGPATH -u "$shortmode_path"`
31424      new_path="$input_path"
31425    fi
31426  fi
31427
31428  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31429  if test "x$test_cygdrive_prefix" = x; then
31430    # As a simple fix, exclude /usr/bin since it's not a real path.
31431    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31432      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31433      # a path prefixed by /cygdrive for fixpath to work.
31434      new_path="$CYGWIN_ROOT_PATH$input_path"
31435    fi
31436  fi
31437
31438  # remove trailing .exe if any
31439  new_path="${new_path/%.exe/}"
31440
31441  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31442
31443  # First separate the path from the arguments. This will split at the first
31444  # space.
31445  complete="$LD"
31446  path="${complete%% *}"
31447  tmp="$complete EOL"
31448  arguments="${tmp#* }"
31449
31450  # Input might be given as Windows format, start by converting to
31451  # unix format.
31452  new_path="$path"
31453
31454  windows_path="$new_path"
31455  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31456    unix_path=`$CYGPATH -u "$windows_path"`
31457    new_path="$unix_path"
31458  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31459    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31460    new_path="$unix_path"
31461  fi
31462
31463
31464  # Now try to locate executable using which
31465  new_path=`$WHICH "$new_path" 2> /dev/null`
31466
31467  if test "x$new_path" = x; then
31468    # Oops. Which didn't find the executable.
31469    # The splitting of arguments from the executable at a space might have been incorrect,
31470    # since paths with space are more likely in Windows. Give it another try with the whole
31471    # argument.
31472    path="$complete"
31473    arguments="EOL"
31474    new_path="$path"
31475
31476  windows_path="$new_path"
31477  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31478    unix_path=`$CYGPATH -u "$windows_path"`
31479    new_path="$unix_path"
31480  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31481    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31482    new_path="$unix_path"
31483  fi
31484
31485
31486    new_path=`$WHICH "$new_path" 2> /dev/null`
31487
31488    if test "x$new_path" = x; then
31489      # It's still not found. Now this is an unrecoverable error.
31490      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31491$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31492      has_space=`$ECHO "$complete" | $GREP " "`
31493      if test "x$has_space" != x; then
31494        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31495$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31496      fi
31497      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31498    fi
31499  fi
31500
31501  # Now new_path has a complete unix path to the binary
31502  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31503    # Keep paths in /bin as-is, but remove trailing .exe if any
31504    new_path="${new_path/%.exe/}"
31505    # Do not save /bin paths to all_fixpath_prefixes!
31506  else
31507    # Not in mixed or Windows style, start by that.
31508    new_path=`cmd //c echo $new_path`
31509
31510  input_path="$new_path"
31511  # Check if we need to convert this using DOS-style short mode. If the path
31512  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31513  # take no chances and rewrite it.
31514  # Note: m4 eats our [], so we need to use [ and ] instead.
31515  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31516  if test "x$has_forbidden_chars" != x; then
31517    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31518    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31519  fi
31520
31521    # Output is in $new_path
31522
31523  windows_path="$new_path"
31524  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31525    unix_path=`$CYGPATH -u "$windows_path"`
31526    new_path="$unix_path"
31527  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31528    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31529    new_path="$unix_path"
31530  fi
31531
31532    # remove trailing .exe if any
31533    new_path="${new_path/%.exe/}"
31534
31535    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31536    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31537  fi
31538
31539  else
31540    # We're on a posix platform. Hooray! :)
31541    # First separate the path from the arguments. This will split at the first
31542    # space.
31543    complete="$LD"
31544    path="${complete%% *}"
31545    tmp="$complete EOL"
31546    arguments="${tmp#* }"
31547
31548    # Cannot rely on the command "which" here since it doesn't always work.
31549    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31550    if test -z "$is_absolute_path"; then
31551      # Path to executable is not absolute. Find it.
31552      IFS_save="$IFS"
31553      IFS=:
31554      for p in $PATH; do
31555        if test -f "$p/$path" && test -x "$p/$path"; then
31556          new_path="$p/$path"
31557          break
31558        fi
31559      done
31560      IFS="$IFS_save"
31561    else
31562      # This is an absolute path, we can use it without further modifications.
31563      new_path="$path"
31564    fi
31565
31566    if test "x$new_path" = x; then
31567      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31568$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31569      has_space=`$ECHO "$complete" | $GREP " "`
31570      if test "x$has_space" != x; then
31571        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31572$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31573      fi
31574      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31575    fi
31576  fi
31577
31578  # Now join together the path and the arguments once again
31579  if test "x$arguments" != xEOL; then
31580    new_complete="$new_path ${arguments% *}"
31581  else
31582    new_complete="$new_path"
31583  fi
31584
31585  if test "x$complete" != "x$new_complete"; then
31586    LD="$new_complete"
31587    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5
31588$as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;}
31589  fi
31590
31591    # Verify that we indeed succeeded with this trick.
31592    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
31593$as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
31594    "$LD" --version > /dev/null
31595    if test $? -eq 0 ; then
31596      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31597$as_echo "no" >&6; }
31598      as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
31599    else
31600      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31601$as_echo "yes" >&6; }
31602    fi
31603    LDCXX="$LD"
31604  else
31605    # All other toolchains use the compiler to link.
31606    LD="$CC"
31607    LDCXX="$CXX"
31608  fi
31609
31610  # FIXME: it should be CXXLD, according to standard (cf CXXCPP)
31611
31612
31613  #
31614  # Setup the assembler (AS)
31615  #
31616  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
31617    # FIXME: should this really be solaris, or solstudio?
31618
31619
31620  # Publish this variable in the help.
31621
31622
31623  if test "x$AS" = x; then
31624    # The variable is not set by user, try to locate tool using the code snippet
31625    for ac_prog in as
31626do
31627  # Extract the first word of "$ac_prog", so it can be a program name with args.
31628set dummy $ac_prog; ac_word=$2
31629{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31630$as_echo_n "checking for $ac_word... " >&6; }
31631if ${ac_cv_path_AS+:} false; then :
31632  $as_echo_n "(cached) " >&6
31633else
31634  case $AS in
31635  [\\/]* | ?:[\\/]*)
31636  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31637  ;;
31638  *)
31639  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31640for as_dir in $PATH
31641do
31642  IFS=$as_save_IFS
31643  test -z "$as_dir" && as_dir=.
31644    for ac_exec_ext in '' $ac_executable_extensions; do
31645  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31646    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31647    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31648    break 2
31649  fi
31650done
31651  done
31652IFS=$as_save_IFS
31653
31654  ;;
31655esac
31656fi
31657AS=$ac_cv_path_AS
31658if test -n "$AS"; then
31659  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31660$as_echo "$AS" >&6; }
31661else
31662  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31663$as_echo "no" >&6; }
31664fi
31665
31666
31667  test -n "$AS" && break
31668done
31669
31670  else
31671    # The variable is set, but is it from the command line or the environment?
31672
31673    # Try to remove the string !AS! from our list.
31674    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
31675    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
31676      # If it failed, the variable was not from the command line. Ignore it,
31677      # but warn the user (except for BASH, which is always set by the calling BASH).
31678      if test "xAS" != xBASH; then
31679        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
31680$as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
31681      fi
31682      # Try to locate tool using the code snippet
31683      for ac_prog in as
31684do
31685  # Extract the first word of "$ac_prog", so it can be a program name with args.
31686set dummy $ac_prog; ac_word=$2
31687{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31688$as_echo_n "checking for $ac_word... " >&6; }
31689if ${ac_cv_path_AS+:} false; then :
31690  $as_echo_n "(cached) " >&6
31691else
31692  case $AS in
31693  [\\/]* | ?:[\\/]*)
31694  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31695  ;;
31696  *)
31697  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31698for as_dir in $PATH
31699do
31700  IFS=$as_save_IFS
31701  test -z "$as_dir" && as_dir=.
31702    for ac_exec_ext in '' $ac_executable_extensions; do
31703  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31704    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31705    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31706    break 2
31707  fi
31708done
31709  done
31710IFS=$as_save_IFS
31711
31712  ;;
31713esac
31714fi
31715AS=$ac_cv_path_AS
31716if test -n "$AS"; then
31717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31718$as_echo "$AS" >&6; }
31719else
31720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31721$as_echo "no" >&6; }
31722fi
31723
31724
31725  test -n "$AS" && break
31726done
31727
31728    else
31729      # If it succeeded, then it was overridden by the user. We will use it
31730      # for the tool.
31731
31732      # First remove it from the list of overridden variables, so we can test
31733      # for unknown variables in the end.
31734      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
31735
31736      # Check if the provided tool contains a complete path.
31737      tool_specified="$AS"
31738      tool_basename="${tool_specified##*/}"
31739      if test "x$tool_basename" = "x$tool_specified"; then
31740        # A command without a complete path is provided, search $PATH.
31741        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
31742$as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
31743        # Extract the first word of "$tool_basename", so it can be a program name with args.
31744set dummy $tool_basename; ac_word=$2
31745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31746$as_echo_n "checking for $ac_word... " >&6; }
31747if ${ac_cv_path_AS+:} false; then :
31748  $as_echo_n "(cached) " >&6
31749else
31750  case $AS in
31751  [\\/]* | ?:[\\/]*)
31752  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31753  ;;
31754  *)
31755  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31756for as_dir in $PATH
31757do
31758  IFS=$as_save_IFS
31759  test -z "$as_dir" && as_dir=.
31760    for ac_exec_ext in '' $ac_executable_extensions; do
31761  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31762    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31763    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31764    break 2
31765  fi
31766done
31767  done
31768IFS=$as_save_IFS
31769
31770  ;;
31771esac
31772fi
31773AS=$ac_cv_path_AS
31774if test -n "$AS"; then
31775  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31776$as_echo "$AS" >&6; }
31777else
31778  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31779$as_echo "no" >&6; }
31780fi
31781
31782
31783        if test "x$AS" = x; then
31784          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
31785        fi
31786      else
31787        # Otherwise we believe it is a complete path. Use it as it is.
31788        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
31789$as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
31790        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
31791$as_echo_n "checking for AS... " >&6; }
31792        if test ! -x "$tool_specified"; then
31793          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
31794$as_echo "not found" >&6; }
31795          as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
31796        fi
31797        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
31798$as_echo "$tool_specified" >&6; }
31799      fi
31800    fi
31801  fi
31802
31803
31804
31805  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31806
31807  # First separate the path from the arguments. This will split at the first
31808  # space.
31809  complete="$AS"
31810  path="${complete%% *}"
31811  tmp="$complete EOL"
31812  arguments="${tmp#* }"
31813
31814  # Input might be given as Windows format, start by converting to
31815  # unix format.
31816  new_path=`$CYGPATH -u "$path"`
31817
31818  # Now try to locate executable using which
31819  new_path=`$WHICH "$new_path" 2> /dev/null`
31820  # bat and cmd files are not always considered executable in cygwin causing which
31821  # to not find them
31822  if test "x$new_path" = x \
31823      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31824      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31825    new_path=`$CYGPATH -u "$path"`
31826  fi
31827  if test "x$new_path" = x; then
31828    # Oops. Which didn't find the executable.
31829    # The splitting of arguments from the executable at a space might have been incorrect,
31830    # since paths with space are more likely in Windows. Give it another try with the whole
31831    # argument.
31832    path="$complete"
31833    arguments="EOL"
31834    new_path=`$CYGPATH -u "$path"`
31835    new_path=`$WHICH "$new_path" 2> /dev/null`
31836    # bat and cmd files are not always considered executable in cygwin causing which
31837    # to not find them
31838    if test "x$new_path" = x \
31839        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31840        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31841      new_path=`$CYGPATH -u "$path"`
31842    fi
31843    if test "x$new_path" = x; then
31844      # It's still not found. Now this is an unrecoverable error.
31845      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31846$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31847      has_space=`$ECHO "$complete" | $GREP " "`
31848      if test "x$has_space" != x; then
31849        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31850$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31851      fi
31852      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31853    fi
31854  fi
31855
31856  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31857  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31858  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31859  # "foo.exe" is OK but "foo" is an error.
31860  #
31861  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31862  # It is also a way to make sure we got the proper file name for the real test later on.
31863  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31864  if test "x$test_shortpath" = x; then
31865    # Short path failed, file does not exist as specified.
31866    # Try adding .exe or .cmd
31867    if test -f "${new_path}.exe"; then
31868      input_to_shortpath="${new_path}.exe"
31869    elif test -f "${new_path}.cmd"; then
31870      input_to_shortpath="${new_path}.cmd"
31871    else
31872      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
31873$as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
31874      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31875$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31876      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31877    fi
31878  else
31879    input_to_shortpath="$new_path"
31880  fi
31881
31882  # Call helper function which possibly converts this using DOS-style short mode.
31883  # If so, the updated path is stored in $new_path.
31884  new_path="$input_to_shortpath"
31885
31886  input_path="$input_to_shortpath"
31887  # Check if we need to convert this using DOS-style short mode. If the path
31888  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31889  # take no chances and rewrite it.
31890  # Note: m4 eats our [], so we need to use [ and ] instead.
31891  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31892  if test "x$has_forbidden_chars" != x; then
31893    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31894    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31895    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31896    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31897      # Going to short mode and back again did indeed matter. Since short mode is
31898      # case insensitive, let's make it lowercase to improve readability.
31899      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31900      # Now convert it back to Unix-stile (cygpath)
31901      input_path=`$CYGPATH -u "$shortmode_path"`
31902      new_path="$input_path"
31903    fi
31904  fi
31905
31906  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31907  if test "x$test_cygdrive_prefix" = x; then
31908    # As a simple fix, exclude /usr/bin since it's not a real path.
31909    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31910      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31911      # a path prefixed by /cygdrive for fixpath to work.
31912      new_path="$CYGWIN_ROOT_PATH$input_path"
31913    fi
31914  fi
31915
31916  # remove trailing .exe if any
31917  new_path="${new_path/%.exe/}"
31918
31919  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31920
31921  # First separate the path from the arguments. This will split at the first
31922  # space.
31923  complete="$AS"
31924  path="${complete%% *}"
31925  tmp="$complete EOL"
31926  arguments="${tmp#* }"
31927
31928  # Input might be given as Windows format, start by converting to
31929  # unix format.
31930  new_path="$path"
31931
31932  windows_path="$new_path"
31933  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31934    unix_path=`$CYGPATH -u "$windows_path"`
31935    new_path="$unix_path"
31936  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31937    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31938    new_path="$unix_path"
31939  fi
31940
31941
31942  # Now try to locate executable using which
31943  new_path=`$WHICH "$new_path" 2> /dev/null`
31944
31945  if test "x$new_path" = x; then
31946    # Oops. Which didn't find the executable.
31947    # The splitting of arguments from the executable at a space might have been incorrect,
31948    # since paths with space are more likely in Windows. Give it another try with the whole
31949    # argument.
31950    path="$complete"
31951    arguments="EOL"
31952    new_path="$path"
31953
31954  windows_path="$new_path"
31955  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31956    unix_path=`$CYGPATH -u "$windows_path"`
31957    new_path="$unix_path"
31958  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31959    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31960    new_path="$unix_path"
31961  fi
31962
31963
31964    new_path=`$WHICH "$new_path" 2> /dev/null`
31965
31966    if test "x$new_path" = x; then
31967      # It's still not found. Now this is an unrecoverable error.
31968      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31969$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31970      has_space=`$ECHO "$complete" | $GREP " "`
31971      if test "x$has_space" != x; then
31972        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31973$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31974      fi
31975      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31976    fi
31977  fi
31978
31979  # Now new_path has a complete unix path to the binary
31980  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31981    # Keep paths in /bin as-is, but remove trailing .exe if any
31982    new_path="${new_path/%.exe/}"
31983    # Do not save /bin paths to all_fixpath_prefixes!
31984  else
31985    # Not in mixed or Windows style, start by that.
31986    new_path=`cmd //c echo $new_path`
31987
31988  input_path="$new_path"
31989  # Check if we need to convert this using DOS-style short mode. If the path
31990  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31991  # take no chances and rewrite it.
31992  # Note: m4 eats our [], so we need to use [ and ] instead.
31993  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31994  if test "x$has_forbidden_chars" != x; then
31995    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31996    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31997  fi
31998
31999    # Output is in $new_path
32000
32001  windows_path="$new_path"
32002  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32003    unix_path=`$CYGPATH -u "$windows_path"`
32004    new_path="$unix_path"
32005  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32006    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32007    new_path="$unix_path"
32008  fi
32009
32010    # remove trailing .exe if any
32011    new_path="${new_path/%.exe/}"
32012
32013    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32014    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32015  fi
32016
32017  else
32018    # We're on a posix platform. Hooray! :)
32019    # First separate the path from the arguments. This will split at the first
32020    # space.
32021    complete="$AS"
32022    path="${complete%% *}"
32023    tmp="$complete EOL"
32024    arguments="${tmp#* }"
32025
32026    # Cannot rely on the command "which" here since it doesn't always work.
32027    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32028    if test -z "$is_absolute_path"; then
32029      # Path to executable is not absolute. Find it.
32030      IFS_save="$IFS"
32031      IFS=:
32032      for p in $PATH; do
32033        if test -f "$p/$path" && test -x "$p/$path"; then
32034          new_path="$p/$path"
32035          break
32036        fi
32037      done
32038      IFS="$IFS_save"
32039    else
32040      # This is an absolute path, we can use it without further modifications.
32041      new_path="$path"
32042    fi
32043
32044    if test "x$new_path" = x; then
32045      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32046$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32047      has_space=`$ECHO "$complete" | $GREP " "`
32048      if test "x$has_space" != x; then
32049        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32050$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32051      fi
32052      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32053    fi
32054  fi
32055
32056  # Now join together the path and the arguments once again
32057  if test "x$arguments" != xEOL; then
32058    new_complete="$new_path ${arguments% *}"
32059  else
32060    new_complete="$new_path"
32061  fi
32062
32063  if test "x$complete" != "x$new_complete"; then
32064    AS="$new_complete"
32065    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
32066$as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
32067  fi
32068
32069  else
32070    # FIXME: is this correct for microsoft?
32071    AS="$CC -c"
32072  fi
32073
32074
32075  #
32076  # Setup the archiver (AR)
32077  #
32078  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
32079    # The corresponding ar tool is lib.exe (used to create static libraries)
32080    # Extract the first word of "lib", so it can be a program name with args.
32081set dummy lib; ac_word=$2
32082{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32083$as_echo_n "checking for $ac_word... " >&6; }
32084if ${ac_cv_prog_AR+:} false; then :
32085  $as_echo_n "(cached) " >&6
32086else
32087  if test -n "$AR"; then
32088  ac_cv_prog_AR="$AR" # Let the user override the test.
32089else
32090as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32091for as_dir in $PATH
32092do
32093  IFS=$as_save_IFS
32094  test -z "$as_dir" && as_dir=.
32095    for ac_exec_ext in '' $ac_executable_extensions; do
32096  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32097    ac_cv_prog_AR="lib"
32098    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32099    break 2
32100  fi
32101done
32102  done
32103IFS=$as_save_IFS
32104
32105fi
32106fi
32107AR=$ac_cv_prog_AR
32108if test -n "$AR"; then
32109  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32110$as_echo "$AR" >&6; }
32111else
32112  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32113$as_echo "no" >&6; }
32114fi
32115
32116
32117  else
32118
32119
32120  # Publish this variable in the help.
32121
32122
32123  if test "x$AR" = x; then
32124    # The variable is not set by user, try to locate tool using the code snippet
32125    if test -n "$ac_tool_prefix"; then
32126  for ac_prog in ar
32127  do
32128    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32129set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32130{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32131$as_echo_n "checking for $ac_word... " >&6; }
32132if ${ac_cv_prog_AR+:} false; then :
32133  $as_echo_n "(cached) " >&6
32134else
32135  if test -n "$AR"; then
32136  ac_cv_prog_AR="$AR" # Let the user override the test.
32137else
32138as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32139for as_dir in $PATH
32140do
32141  IFS=$as_save_IFS
32142  test -z "$as_dir" && as_dir=.
32143    for ac_exec_ext in '' $ac_executable_extensions; do
32144  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32145    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32146    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32147    break 2
32148  fi
32149done
32150  done
32151IFS=$as_save_IFS
32152
32153fi
32154fi
32155AR=$ac_cv_prog_AR
32156if test -n "$AR"; then
32157  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32158$as_echo "$AR" >&6; }
32159else
32160  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32161$as_echo "no" >&6; }
32162fi
32163
32164
32165    test -n "$AR" && break
32166  done
32167fi
32168if test -z "$AR"; then
32169  ac_ct_AR=$AR
32170  for ac_prog in ar
32171do
32172  # Extract the first word of "$ac_prog", so it can be a program name with args.
32173set dummy $ac_prog; ac_word=$2
32174{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32175$as_echo_n "checking for $ac_word... " >&6; }
32176if ${ac_cv_prog_ac_ct_AR+:} false; then :
32177  $as_echo_n "(cached) " >&6
32178else
32179  if test -n "$ac_ct_AR"; then
32180  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32181else
32182as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32183for as_dir in $PATH
32184do
32185  IFS=$as_save_IFS
32186  test -z "$as_dir" && as_dir=.
32187    for ac_exec_ext in '' $ac_executable_extensions; do
32188  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32189    ac_cv_prog_ac_ct_AR="$ac_prog"
32190    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32191    break 2
32192  fi
32193done
32194  done
32195IFS=$as_save_IFS
32196
32197fi
32198fi
32199ac_ct_AR=$ac_cv_prog_ac_ct_AR
32200if test -n "$ac_ct_AR"; then
32201  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32202$as_echo "$ac_ct_AR" >&6; }
32203else
32204  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32205$as_echo "no" >&6; }
32206fi
32207
32208
32209  test -n "$ac_ct_AR" && break
32210done
32211
32212  if test "x$ac_ct_AR" = x; then
32213    AR=""
32214  else
32215    case $cross_compiling:$ac_tool_warned in
32216yes:)
32217{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32218$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32219ac_tool_warned=yes ;;
32220esac
32221    AR=$ac_ct_AR
32222  fi
32223fi
32224
32225  else
32226    # The variable is set, but is it from the command line or the environment?
32227
32228    # Try to remove the string !AR! from our list.
32229    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32230    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32231      # If it failed, the variable was not from the command line. Ignore it,
32232      # but warn the user (except for BASH, which is always set by the calling BASH).
32233      if test "xAR" != xBASH; then
32234        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32235$as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32236      fi
32237      # Try to locate tool using the code snippet
32238      if test -n "$ac_tool_prefix"; then
32239  for ac_prog in ar
32240  do
32241    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32242set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32244$as_echo_n "checking for $ac_word... " >&6; }
32245if ${ac_cv_prog_AR+:} false; then :
32246  $as_echo_n "(cached) " >&6
32247else
32248  if test -n "$AR"; then
32249  ac_cv_prog_AR="$AR" # Let the user override the test.
32250else
32251as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32252for as_dir in $PATH
32253do
32254  IFS=$as_save_IFS
32255  test -z "$as_dir" && as_dir=.
32256    for ac_exec_ext in '' $ac_executable_extensions; do
32257  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32258    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32259    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32260    break 2
32261  fi
32262done
32263  done
32264IFS=$as_save_IFS
32265
32266fi
32267fi
32268AR=$ac_cv_prog_AR
32269if test -n "$AR"; then
32270  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32271$as_echo "$AR" >&6; }
32272else
32273  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32274$as_echo "no" >&6; }
32275fi
32276
32277
32278    test -n "$AR" && break
32279  done
32280fi
32281if test -z "$AR"; then
32282  ac_ct_AR=$AR
32283  for ac_prog in ar
32284do
32285  # Extract the first word of "$ac_prog", so it can be a program name with args.
32286set dummy $ac_prog; ac_word=$2
32287{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32288$as_echo_n "checking for $ac_word... " >&6; }
32289if ${ac_cv_prog_ac_ct_AR+:} false; then :
32290  $as_echo_n "(cached) " >&6
32291else
32292  if test -n "$ac_ct_AR"; then
32293  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32294else
32295as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32296for as_dir in $PATH
32297do
32298  IFS=$as_save_IFS
32299  test -z "$as_dir" && as_dir=.
32300    for ac_exec_ext in '' $ac_executable_extensions; do
32301  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32302    ac_cv_prog_ac_ct_AR="$ac_prog"
32303    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32304    break 2
32305  fi
32306done
32307  done
32308IFS=$as_save_IFS
32309
32310fi
32311fi
32312ac_ct_AR=$ac_cv_prog_ac_ct_AR
32313if test -n "$ac_ct_AR"; then
32314  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32315$as_echo "$ac_ct_AR" >&6; }
32316else
32317  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32318$as_echo "no" >&6; }
32319fi
32320
32321
32322  test -n "$ac_ct_AR" && break
32323done
32324
32325  if test "x$ac_ct_AR" = x; then
32326    AR=""
32327  else
32328    case $cross_compiling:$ac_tool_warned in
32329yes:)
32330{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32331$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32332ac_tool_warned=yes ;;
32333esac
32334    AR=$ac_ct_AR
32335  fi
32336fi
32337
32338    else
32339      # If it succeeded, then it was overridden by the user. We will use it
32340      # for the tool.
32341
32342      # First remove it from the list of overridden variables, so we can test
32343      # for unknown variables in the end.
32344      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32345
32346      # Check if the provided tool contains a complete path.
32347      tool_specified="$AR"
32348      tool_basename="${tool_specified##*/}"
32349      if test "x$tool_basename" = "x$tool_specified"; then
32350        # A command without a complete path is provided, search $PATH.
32351        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
32352$as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
32353        # Extract the first word of "$tool_basename", so it can be a program name with args.
32354set dummy $tool_basename; ac_word=$2
32355{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32356$as_echo_n "checking for $ac_word... " >&6; }
32357if ${ac_cv_path_AR+:} false; then :
32358  $as_echo_n "(cached) " >&6
32359else
32360  case $AR in
32361  [\\/]* | ?:[\\/]*)
32362  ac_cv_path_AR="$AR" # Let the user override the test with a path.
32363  ;;
32364  *)
32365  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32366for as_dir in $PATH
32367do
32368  IFS=$as_save_IFS
32369  test -z "$as_dir" && as_dir=.
32370    for ac_exec_ext in '' $ac_executable_extensions; do
32371  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32372    ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
32373    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32374    break 2
32375  fi
32376done
32377  done
32378IFS=$as_save_IFS
32379
32380  ;;
32381esac
32382fi
32383AR=$ac_cv_path_AR
32384if test -n "$AR"; then
32385  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32386$as_echo "$AR" >&6; }
32387else
32388  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32389$as_echo "no" >&6; }
32390fi
32391
32392
32393        if test "x$AR" = x; then
32394          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32395        fi
32396      else
32397        # Otherwise we believe it is a complete path. Use it as it is.
32398        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
32399$as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
32400        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
32401$as_echo_n "checking for AR... " >&6; }
32402        if test ! -x "$tool_specified"; then
32403          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32404$as_echo "not found" >&6; }
32405          as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
32406        fi
32407        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32408$as_echo "$tool_specified" >&6; }
32409      fi
32410    fi
32411  fi
32412
32413
32414  fi
32415
32416  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32417
32418  # First separate the path from the arguments. This will split at the first
32419  # space.
32420  complete="$AR"
32421  path="${complete%% *}"
32422  tmp="$complete EOL"
32423  arguments="${tmp#* }"
32424
32425  # Input might be given as Windows format, start by converting to
32426  # unix format.
32427  new_path=`$CYGPATH -u "$path"`
32428
32429  # Now try to locate executable using which
32430  new_path=`$WHICH "$new_path" 2> /dev/null`
32431  # bat and cmd files are not always considered executable in cygwin causing which
32432  # to not find them
32433  if test "x$new_path" = x \
32434      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32435      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32436    new_path=`$CYGPATH -u "$path"`
32437  fi
32438  if test "x$new_path" = x; then
32439    # Oops. Which didn't find the executable.
32440    # The splitting of arguments from the executable at a space might have been incorrect,
32441    # since paths with space are more likely in Windows. Give it another try with the whole
32442    # argument.
32443    path="$complete"
32444    arguments="EOL"
32445    new_path=`$CYGPATH -u "$path"`
32446    new_path=`$WHICH "$new_path" 2> /dev/null`
32447    # bat and cmd files are not always considered executable in cygwin causing which
32448    # to not find them
32449    if test "x$new_path" = x \
32450        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32451        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32452      new_path=`$CYGPATH -u "$path"`
32453    fi
32454    if test "x$new_path" = x; then
32455      # It's still not found. Now this is an unrecoverable error.
32456      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32457$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32458      has_space=`$ECHO "$complete" | $GREP " "`
32459      if test "x$has_space" != x; then
32460        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32461$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32462      fi
32463      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32464    fi
32465  fi
32466
32467  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32468  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32469  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32470  # "foo.exe" is OK but "foo" is an error.
32471  #
32472  # This test is therefore slightly more accurate than "test -f" to check for file presence.
32473  # It is also a way to make sure we got the proper file name for the real test later on.
32474  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32475  if test "x$test_shortpath" = x; then
32476    # Short path failed, file does not exist as specified.
32477    # Try adding .exe or .cmd
32478    if test -f "${new_path}.exe"; then
32479      input_to_shortpath="${new_path}.exe"
32480    elif test -f "${new_path}.cmd"; then
32481      input_to_shortpath="${new_path}.cmd"
32482    else
32483      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
32484$as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
32485      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32486$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32487      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32488    fi
32489  else
32490    input_to_shortpath="$new_path"
32491  fi
32492
32493  # Call helper function which possibly converts this using DOS-style short mode.
32494  # If so, the updated path is stored in $new_path.
32495  new_path="$input_to_shortpath"
32496
32497  input_path="$input_to_shortpath"
32498  # Check if we need to convert this using DOS-style short mode. If the path
32499  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32500  # take no chances and rewrite it.
32501  # Note: m4 eats our [], so we need to use [ and ] instead.
32502  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32503  if test "x$has_forbidden_chars" != x; then
32504    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32505    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32506    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32507    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32508      # Going to short mode and back again did indeed matter. Since short mode is
32509      # case insensitive, let's make it lowercase to improve readability.
32510      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32511      # Now convert it back to Unix-stile (cygpath)
32512      input_path=`$CYGPATH -u "$shortmode_path"`
32513      new_path="$input_path"
32514    fi
32515  fi
32516
32517  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32518  if test "x$test_cygdrive_prefix" = x; then
32519    # As a simple fix, exclude /usr/bin since it's not a real path.
32520    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32521      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32522      # a path prefixed by /cygdrive for fixpath to work.
32523      new_path="$CYGWIN_ROOT_PATH$input_path"
32524    fi
32525  fi
32526
32527  # remove trailing .exe if any
32528  new_path="${new_path/%.exe/}"
32529
32530  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32531
32532  # First separate the path from the arguments. This will split at the first
32533  # space.
32534  complete="$AR"
32535  path="${complete%% *}"
32536  tmp="$complete EOL"
32537  arguments="${tmp#* }"
32538
32539  # Input might be given as Windows format, start by converting to
32540  # unix format.
32541  new_path="$path"
32542
32543  windows_path="$new_path"
32544  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32545    unix_path=`$CYGPATH -u "$windows_path"`
32546    new_path="$unix_path"
32547  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32548    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32549    new_path="$unix_path"
32550  fi
32551
32552
32553  # Now try to locate executable using which
32554  new_path=`$WHICH "$new_path" 2> /dev/null`
32555
32556  if test "x$new_path" = x; then
32557    # Oops. Which didn't find the executable.
32558    # The splitting of arguments from the executable at a space might have been incorrect,
32559    # since paths with space are more likely in Windows. Give it another try with the whole
32560    # argument.
32561    path="$complete"
32562    arguments="EOL"
32563    new_path="$path"
32564
32565  windows_path="$new_path"
32566  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32567    unix_path=`$CYGPATH -u "$windows_path"`
32568    new_path="$unix_path"
32569  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32570    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32571    new_path="$unix_path"
32572  fi
32573
32574
32575    new_path=`$WHICH "$new_path" 2> /dev/null`
32576
32577    if test "x$new_path" = x; then
32578      # It's still not found. Now this is an unrecoverable error.
32579      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32580$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32581      has_space=`$ECHO "$complete" | $GREP " "`
32582      if test "x$has_space" != x; then
32583        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32584$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32585      fi
32586      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32587    fi
32588  fi
32589
32590  # Now new_path has a complete unix path to the binary
32591  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32592    # Keep paths in /bin as-is, but remove trailing .exe if any
32593    new_path="${new_path/%.exe/}"
32594    # Do not save /bin paths to all_fixpath_prefixes!
32595  else
32596    # Not in mixed or Windows style, start by that.
32597    new_path=`cmd //c echo $new_path`
32598
32599  input_path="$new_path"
32600  # Check if we need to convert this using DOS-style short mode. If the path
32601  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32602  # take no chances and rewrite it.
32603  # Note: m4 eats our [], so we need to use [ and ] instead.
32604  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32605  if test "x$has_forbidden_chars" != x; then
32606    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32607    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32608  fi
32609
32610    # Output is in $new_path
32611
32612  windows_path="$new_path"
32613  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32614    unix_path=`$CYGPATH -u "$windows_path"`
32615    new_path="$unix_path"
32616  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32617    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32618    new_path="$unix_path"
32619  fi
32620
32621    # remove trailing .exe if any
32622    new_path="${new_path/%.exe/}"
32623
32624    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32625    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32626  fi
32627
32628  else
32629    # We're on a posix platform. Hooray! :)
32630    # First separate the path from the arguments. This will split at the first
32631    # space.
32632    complete="$AR"
32633    path="${complete%% *}"
32634    tmp="$complete EOL"
32635    arguments="${tmp#* }"
32636
32637    # Cannot rely on the command "which" here since it doesn't always work.
32638    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32639    if test -z "$is_absolute_path"; then
32640      # Path to executable is not absolute. Find it.
32641      IFS_save="$IFS"
32642      IFS=:
32643      for p in $PATH; do
32644        if test -f "$p/$path" && test -x "$p/$path"; then
32645          new_path="$p/$path"
32646          break
32647        fi
32648      done
32649      IFS="$IFS_save"
32650    else
32651      # This is an absolute path, we can use it without further modifications.
32652      new_path="$path"
32653    fi
32654
32655    if test "x$new_path" = x; then
32656      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32657$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32658      has_space=`$ECHO "$complete" | $GREP " "`
32659      if test "x$has_space" != x; then
32660        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32661$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32662      fi
32663      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32664    fi
32665  fi
32666
32667  # Now join together the path and the arguments once again
32668  if test "x$arguments" != xEOL; then
32669    new_complete="$new_path ${arguments% *}"
32670  else
32671    new_complete="$new_path"
32672  fi
32673
32674  if test "x$complete" != "x$new_complete"; then
32675    AR="$new_complete"
32676    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
32677$as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
32678  fi
32679
32680
32681
32682  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
32683    ac_ext=m
32684ac_cpp='$OBJCPP $CPPFLAGS'
32685ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32686ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32687ac_compiler_gnu=$ac_cv_objc_compiler_gnu
32688if test -n "$ac_tool_prefix"; then
32689  for ac_prog in gcc objcc objc cc CC
32690  do
32691    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32692set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32693{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32694$as_echo_n "checking for $ac_word... " >&6; }
32695if ${ac_cv_prog_OBJC+:} false; then :
32696  $as_echo_n "(cached) " >&6
32697else
32698  if test -n "$OBJC"; then
32699  ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
32700else
32701as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32702for as_dir in $PATH
32703do
32704  IFS=$as_save_IFS
32705  test -z "$as_dir" && as_dir=.
32706    for ac_exec_ext in '' $ac_executable_extensions; do
32707  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32708    ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
32709    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32710    break 2
32711  fi
32712done
32713  done
32714IFS=$as_save_IFS
32715
32716fi
32717fi
32718OBJC=$ac_cv_prog_OBJC
32719if test -n "$OBJC"; then
32720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
32721$as_echo "$OBJC" >&6; }
32722else
32723  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32724$as_echo "no" >&6; }
32725fi
32726
32727
32728    test -n "$OBJC" && break
32729  done
32730fi
32731if test -z "$OBJC"; then
32732  ac_ct_OBJC=$OBJC
32733  for ac_prog in gcc objcc objc cc CC
32734do
32735  # Extract the first word of "$ac_prog", so it can be a program name with args.
32736set dummy $ac_prog; ac_word=$2
32737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32738$as_echo_n "checking for $ac_word... " >&6; }
32739if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
32740  $as_echo_n "(cached) " >&6
32741else
32742  if test -n "$ac_ct_OBJC"; then
32743  ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
32744else
32745as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32746for as_dir in $PATH
32747do
32748  IFS=$as_save_IFS
32749  test -z "$as_dir" && as_dir=.
32750    for ac_exec_ext in '' $ac_executable_extensions; do
32751  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32752    ac_cv_prog_ac_ct_OBJC="$ac_prog"
32753    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32754    break 2
32755  fi
32756done
32757  done
32758IFS=$as_save_IFS
32759
32760fi
32761fi
32762ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
32763if test -n "$ac_ct_OBJC"; then
32764  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
32765$as_echo "$ac_ct_OBJC" >&6; }
32766else
32767  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32768$as_echo "no" >&6; }
32769fi
32770
32771
32772  test -n "$ac_ct_OBJC" && break
32773done
32774
32775  if test "x$ac_ct_OBJC" = x; then
32776    OBJC="gcc"
32777  else
32778    case $cross_compiling:$ac_tool_warned in
32779yes:)
32780{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32781$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32782ac_tool_warned=yes ;;
32783esac
32784    OBJC=$ac_ct_OBJC
32785  fi
32786fi
32787
32788# Provide some information about the compiler.
32789$as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
32790set X $ac_compile
32791ac_compiler=$2
32792for ac_option in --version -v -V -qversion; do
32793  { { ac_try="$ac_compiler $ac_option >&5"
32794case "(($ac_try" in
32795  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32796  *) ac_try_echo=$ac_try;;
32797esac
32798eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32799$as_echo "$ac_try_echo"; } >&5
32800  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32801  ac_status=$?
32802  if test -s conftest.err; then
32803    sed '10a\
32804... rest of stderr output deleted ...
32805         10q' conftest.err >conftest.er1
32806    cat conftest.er1 >&5
32807  fi
32808  rm -f conftest.er1 conftest.err
32809  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32810  test $ac_status = 0; }
32811done
32812
32813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
32814$as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
32815if ${ac_cv_objc_compiler_gnu+:} false; then :
32816  $as_echo_n "(cached) " >&6
32817else
32818  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32819/* end confdefs.h.  */
32820
32821int
32822main ()
32823{
32824#ifndef __GNUC__
32825       choke me
32826#endif
32827
32828  ;
32829  return 0;
32830}
32831_ACEOF
32832if ac_fn_objc_try_compile "$LINENO"; then :
32833  ac_compiler_gnu=yes
32834else
32835  ac_compiler_gnu=no
32836fi
32837rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32838ac_cv_objc_compiler_gnu=$ac_compiler_gnu
32839
32840fi
32841{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
32842$as_echo "$ac_cv_objc_compiler_gnu" >&6; }
32843if test $ac_compiler_gnu = yes; then
32844  GOBJC=yes
32845else
32846  GOBJC=
32847fi
32848ac_test_OBJCFLAGS=${OBJCFLAGS+set}
32849ac_save_OBJCFLAGS=$OBJCFLAGS
32850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
32851$as_echo_n "checking whether $OBJC accepts -g... " >&6; }
32852if ${ac_cv_prog_objc_g+:} false; then :
32853  $as_echo_n "(cached) " >&6
32854else
32855  ac_save_objc_werror_flag=$ac_objc_werror_flag
32856   ac_objc_werror_flag=yes
32857   ac_cv_prog_objc_g=no
32858   OBJCFLAGS="-g"
32859   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32860/* end confdefs.h.  */
32861
32862int
32863main ()
32864{
32865
32866  ;
32867  return 0;
32868}
32869_ACEOF
32870if ac_fn_objc_try_compile "$LINENO"; then :
32871  ac_cv_prog_objc_g=yes
32872else
32873  OBJCFLAGS=""
32874      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32875/* end confdefs.h.  */
32876
32877int
32878main ()
32879{
32880
32881  ;
32882  return 0;
32883}
32884_ACEOF
32885if ac_fn_objc_try_compile "$LINENO"; then :
32886
32887else
32888  ac_objc_werror_flag=$ac_save_objc_werror_flag
32889	 OBJCFLAGS="-g"
32890	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32891/* end confdefs.h.  */
32892
32893int
32894main ()
32895{
32896
32897  ;
32898  return 0;
32899}
32900_ACEOF
32901if ac_fn_objc_try_compile "$LINENO"; then :
32902  ac_cv_prog_objc_g=yes
32903fi
32904rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32905fi
32906rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32907fi
32908rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32909   ac_objc_werror_flag=$ac_save_objc_werror_flag
32910fi
32911{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
32912$as_echo "$ac_cv_prog_objc_g" >&6; }
32913if test "$ac_test_OBJCFLAGS" = set; then
32914  OBJCFLAGS=$ac_save_OBJCFLAGS
32915elif test $ac_cv_prog_objc_g = yes; then
32916  if test "$GOBJC" = yes; then
32917    OBJCFLAGS="-g -O2"
32918  else
32919    OBJCFLAGS="-g"
32920  fi
32921else
32922  if test "$GOBJC" = yes; then
32923    OBJCFLAGS="-O2"
32924  else
32925    OBJCFLAGS=
32926  fi
32927fi
32928ac_ext=cpp
32929ac_cpp='$CXXCPP $CPPFLAGS'
32930ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32931ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32932ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32933
32934
32935  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32936
32937  # First separate the path from the arguments. This will split at the first
32938  # space.
32939  complete="$OBJC"
32940  path="${complete%% *}"
32941  tmp="$complete EOL"
32942  arguments="${tmp#* }"
32943
32944  # Input might be given as Windows format, start by converting to
32945  # unix format.
32946  new_path=`$CYGPATH -u "$path"`
32947
32948  # Now try to locate executable using which
32949  new_path=`$WHICH "$new_path" 2> /dev/null`
32950  # bat and cmd files are not always considered executable in cygwin causing which
32951  # to not find them
32952  if test "x$new_path" = x \
32953      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32954      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32955    new_path=`$CYGPATH -u "$path"`
32956  fi
32957  if test "x$new_path" = x; then
32958    # Oops. Which didn't find the executable.
32959    # The splitting of arguments from the executable at a space might have been incorrect,
32960    # since paths with space are more likely in Windows. Give it another try with the whole
32961    # argument.
32962    path="$complete"
32963    arguments="EOL"
32964    new_path=`$CYGPATH -u "$path"`
32965    new_path=`$WHICH "$new_path" 2> /dev/null`
32966    # bat and cmd files are not always considered executable in cygwin causing which
32967    # to not find them
32968    if test "x$new_path" = x \
32969        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32970        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32971      new_path=`$CYGPATH -u "$path"`
32972    fi
32973    if test "x$new_path" = x; then
32974      # It's still not found. Now this is an unrecoverable error.
32975      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32976$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32977      has_space=`$ECHO "$complete" | $GREP " "`
32978      if test "x$has_space" != x; then
32979        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32980$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32981      fi
32982      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32983    fi
32984  fi
32985
32986  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32987  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32988  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32989  # "foo.exe" is OK but "foo" is an error.
32990  #
32991  # This test is therefore slightly more accurate than "test -f" to check for file presence.
32992  # It is also a way to make sure we got the proper file name for the real test later on.
32993  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32994  if test "x$test_shortpath" = x; then
32995    # Short path failed, file does not exist as specified.
32996    # Try adding .exe or .cmd
32997    if test -f "${new_path}.exe"; then
32998      input_to_shortpath="${new_path}.exe"
32999    elif test -f "${new_path}.cmd"; then
33000      input_to_shortpath="${new_path}.cmd"
33001    else
33002      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
33003$as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
33004      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33005$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33006      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33007    fi
33008  else
33009    input_to_shortpath="$new_path"
33010  fi
33011
33012  # Call helper function which possibly converts this using DOS-style short mode.
33013  # If so, the updated path is stored in $new_path.
33014  new_path="$input_to_shortpath"
33015
33016  input_path="$input_to_shortpath"
33017  # Check if we need to convert this using DOS-style short mode. If the path
33018  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33019  # take no chances and rewrite it.
33020  # Note: m4 eats our [], so we need to use [ and ] instead.
33021  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33022  if test "x$has_forbidden_chars" != x; then
33023    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33024    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33025    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33026    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33027      # Going to short mode and back again did indeed matter. Since short mode is
33028      # case insensitive, let's make it lowercase to improve readability.
33029      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33030      # Now convert it back to Unix-stile (cygpath)
33031      input_path=`$CYGPATH -u "$shortmode_path"`
33032      new_path="$input_path"
33033    fi
33034  fi
33035
33036  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33037  if test "x$test_cygdrive_prefix" = x; then
33038    # As a simple fix, exclude /usr/bin since it's not a real path.
33039    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33040      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33041      # a path prefixed by /cygdrive for fixpath to work.
33042      new_path="$CYGWIN_ROOT_PATH$input_path"
33043    fi
33044  fi
33045
33046  # remove trailing .exe if any
33047  new_path="${new_path/%.exe/}"
33048
33049  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33050
33051  # First separate the path from the arguments. This will split at the first
33052  # space.
33053  complete="$OBJC"
33054  path="${complete%% *}"
33055  tmp="$complete EOL"
33056  arguments="${tmp#* }"
33057
33058  # Input might be given as Windows format, start by converting to
33059  # unix format.
33060  new_path="$path"
33061
33062  windows_path="$new_path"
33063  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33064    unix_path=`$CYGPATH -u "$windows_path"`
33065    new_path="$unix_path"
33066  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33067    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33068    new_path="$unix_path"
33069  fi
33070
33071
33072  # Now try to locate executable using which
33073  new_path=`$WHICH "$new_path" 2> /dev/null`
33074
33075  if test "x$new_path" = x; then
33076    # Oops. Which didn't find the executable.
33077    # The splitting of arguments from the executable at a space might have been incorrect,
33078    # since paths with space are more likely in Windows. Give it another try with the whole
33079    # argument.
33080    path="$complete"
33081    arguments="EOL"
33082    new_path="$path"
33083
33084  windows_path="$new_path"
33085  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33086    unix_path=`$CYGPATH -u "$windows_path"`
33087    new_path="$unix_path"
33088  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33089    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33090    new_path="$unix_path"
33091  fi
33092
33093
33094    new_path=`$WHICH "$new_path" 2> /dev/null`
33095
33096    if test "x$new_path" = x; then
33097      # It's still not found. Now this is an unrecoverable error.
33098      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33099$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33100      has_space=`$ECHO "$complete" | $GREP " "`
33101      if test "x$has_space" != x; then
33102        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33103$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33104      fi
33105      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33106    fi
33107  fi
33108
33109  # Now new_path has a complete unix path to the binary
33110  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33111    # Keep paths in /bin as-is, but remove trailing .exe if any
33112    new_path="${new_path/%.exe/}"
33113    # Do not save /bin paths to all_fixpath_prefixes!
33114  else
33115    # Not in mixed or Windows style, start by that.
33116    new_path=`cmd //c echo $new_path`
33117
33118  input_path="$new_path"
33119  # Check if we need to convert this using DOS-style short mode. If the path
33120  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33121  # take no chances and rewrite it.
33122  # Note: m4 eats our [], so we need to use [ and ] instead.
33123  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33124  if test "x$has_forbidden_chars" != x; then
33125    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33126    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33127  fi
33128
33129    # Output is in $new_path
33130
33131  windows_path="$new_path"
33132  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33133    unix_path=`$CYGPATH -u "$windows_path"`
33134    new_path="$unix_path"
33135  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33136    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33137    new_path="$unix_path"
33138  fi
33139
33140    # remove trailing .exe if any
33141    new_path="${new_path/%.exe/}"
33142
33143    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33144    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33145  fi
33146
33147  else
33148    # We're on a posix platform. Hooray! :)
33149    # First separate the path from the arguments. This will split at the first
33150    # space.
33151    complete="$OBJC"
33152    path="${complete%% *}"
33153    tmp="$complete EOL"
33154    arguments="${tmp#* }"
33155
33156    # Cannot rely on the command "which" here since it doesn't always work.
33157    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33158    if test -z "$is_absolute_path"; then
33159      # Path to executable is not absolute. Find it.
33160      IFS_save="$IFS"
33161      IFS=:
33162      for p in $PATH; do
33163        if test -f "$p/$path" && test -x "$p/$path"; then
33164          new_path="$p/$path"
33165          break
33166        fi
33167      done
33168      IFS="$IFS_save"
33169    else
33170      # This is an absolute path, we can use it without further modifications.
33171      new_path="$path"
33172    fi
33173
33174    if test "x$new_path" = x; then
33175      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33176$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33177      has_space=`$ECHO "$complete" | $GREP " "`
33178      if test "x$has_space" != x; then
33179        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33180$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33181      fi
33182      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33183    fi
33184  fi
33185
33186  # Now join together the path and the arguments once again
33187  if test "x$arguments" != xEOL; then
33188    new_complete="$new_path ${arguments% *}"
33189  else
33190    new_complete="$new_path"
33191  fi
33192
33193  if test "x$complete" != "x$new_complete"; then
33194    OBJC="$new_complete"
33195    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
33196$as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
33197  fi
33198
33199
33200
33201  # Publish this variable in the help.
33202
33203
33204  if test "x$LIPO" = x; then
33205    # The variable is not set by user, try to locate tool using the code snippet
33206    for ac_prog in lipo
33207do
33208  # Extract the first word of "$ac_prog", so it can be a program name with args.
33209set dummy $ac_prog; ac_word=$2
33210{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33211$as_echo_n "checking for $ac_word... " >&6; }
33212if ${ac_cv_path_LIPO+:} false; then :
33213  $as_echo_n "(cached) " >&6
33214else
33215  case $LIPO in
33216  [\\/]* | ?:[\\/]*)
33217  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33218  ;;
33219  *)
33220  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33221for as_dir in $PATH
33222do
33223  IFS=$as_save_IFS
33224  test -z "$as_dir" && as_dir=.
33225    for ac_exec_ext in '' $ac_executable_extensions; do
33226  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33227    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33228    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33229    break 2
33230  fi
33231done
33232  done
33233IFS=$as_save_IFS
33234
33235  ;;
33236esac
33237fi
33238LIPO=$ac_cv_path_LIPO
33239if test -n "$LIPO"; then
33240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33241$as_echo "$LIPO" >&6; }
33242else
33243  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33244$as_echo "no" >&6; }
33245fi
33246
33247
33248  test -n "$LIPO" && break
33249done
33250
33251  else
33252    # The variable is set, but is it from the command line or the environment?
33253
33254    # Try to remove the string !LIPO! from our list.
33255    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
33256    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
33257      # If it failed, the variable was not from the command line. Ignore it,
33258      # but warn the user (except for BASH, which is always set by the calling BASH).
33259      if test "xLIPO" != xBASH; then
33260        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
33261$as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
33262      fi
33263      # Try to locate tool using the code snippet
33264      for ac_prog in lipo
33265do
33266  # Extract the first word of "$ac_prog", so it can be a program name with args.
33267set dummy $ac_prog; ac_word=$2
33268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33269$as_echo_n "checking for $ac_word... " >&6; }
33270if ${ac_cv_path_LIPO+:} false; then :
33271  $as_echo_n "(cached) " >&6
33272else
33273  case $LIPO in
33274  [\\/]* | ?:[\\/]*)
33275  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33276  ;;
33277  *)
33278  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33279for as_dir in $PATH
33280do
33281  IFS=$as_save_IFS
33282  test -z "$as_dir" && as_dir=.
33283    for ac_exec_ext in '' $ac_executable_extensions; do
33284  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33285    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33286    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33287    break 2
33288  fi
33289done
33290  done
33291IFS=$as_save_IFS
33292
33293  ;;
33294esac
33295fi
33296LIPO=$ac_cv_path_LIPO
33297if test -n "$LIPO"; then
33298  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33299$as_echo "$LIPO" >&6; }
33300else
33301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33302$as_echo "no" >&6; }
33303fi
33304
33305
33306  test -n "$LIPO" && break
33307done
33308
33309    else
33310      # If it succeeded, then it was overridden by the user. We will use it
33311      # for the tool.
33312
33313      # First remove it from the list of overridden variables, so we can test
33314      # for unknown variables in the end.
33315      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33316
33317      # Check if the provided tool contains a complete path.
33318      tool_specified="$LIPO"
33319      tool_basename="${tool_specified##*/}"
33320      if test "x$tool_basename" = "x$tool_specified"; then
33321        # A command without a complete path is provided, search $PATH.
33322        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
33323$as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
33324        # Extract the first word of "$tool_basename", so it can be a program name with args.
33325set dummy $tool_basename; ac_word=$2
33326{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33327$as_echo_n "checking for $ac_word... " >&6; }
33328if ${ac_cv_path_LIPO+:} false; then :
33329  $as_echo_n "(cached) " >&6
33330else
33331  case $LIPO in
33332  [\\/]* | ?:[\\/]*)
33333  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33334  ;;
33335  *)
33336  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33337for as_dir in $PATH
33338do
33339  IFS=$as_save_IFS
33340  test -z "$as_dir" && as_dir=.
33341    for ac_exec_ext in '' $ac_executable_extensions; do
33342  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33343    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33344    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33345    break 2
33346  fi
33347done
33348  done
33349IFS=$as_save_IFS
33350
33351  ;;
33352esac
33353fi
33354LIPO=$ac_cv_path_LIPO
33355if test -n "$LIPO"; then
33356  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33357$as_echo "$LIPO" >&6; }
33358else
33359  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33360$as_echo "no" >&6; }
33361fi
33362
33363
33364        if test "x$LIPO" = x; then
33365          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33366        fi
33367      else
33368        # Otherwise we believe it is a complete path. Use it as it is.
33369        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
33370$as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
33371        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
33372$as_echo_n "checking for LIPO... " >&6; }
33373        if test ! -x "$tool_specified"; then
33374          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33375$as_echo "not found" >&6; }
33376          as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
33377        fi
33378        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33379$as_echo "$tool_specified" >&6; }
33380      fi
33381    fi
33382  fi
33383
33384
33385
33386  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33387
33388  # First separate the path from the arguments. This will split at the first
33389  # space.
33390  complete="$LIPO"
33391  path="${complete%% *}"
33392  tmp="$complete EOL"
33393  arguments="${tmp#* }"
33394
33395  # Input might be given as Windows format, start by converting to
33396  # unix format.
33397  new_path=`$CYGPATH -u "$path"`
33398
33399  # Now try to locate executable using which
33400  new_path=`$WHICH "$new_path" 2> /dev/null`
33401  # bat and cmd files are not always considered executable in cygwin causing which
33402  # to not find them
33403  if test "x$new_path" = x \
33404      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33405      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33406    new_path=`$CYGPATH -u "$path"`
33407  fi
33408  if test "x$new_path" = x; then
33409    # Oops. Which didn't find the executable.
33410    # The splitting of arguments from the executable at a space might have been incorrect,
33411    # since paths with space are more likely in Windows. Give it another try with the whole
33412    # argument.
33413    path="$complete"
33414    arguments="EOL"
33415    new_path=`$CYGPATH -u "$path"`
33416    new_path=`$WHICH "$new_path" 2> /dev/null`
33417    # bat and cmd files are not always considered executable in cygwin causing which
33418    # to not find them
33419    if test "x$new_path" = x \
33420        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33421        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33422      new_path=`$CYGPATH -u "$path"`
33423    fi
33424    if test "x$new_path" = x; then
33425      # It's still not found. Now this is an unrecoverable error.
33426      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33427$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33428      has_space=`$ECHO "$complete" | $GREP " "`
33429      if test "x$has_space" != x; then
33430        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33431$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33432      fi
33433      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33434    fi
33435  fi
33436
33437  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33438  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33439  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33440  # "foo.exe" is OK but "foo" is an error.
33441  #
33442  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33443  # It is also a way to make sure we got the proper file name for the real test later on.
33444  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33445  if test "x$test_shortpath" = x; then
33446    # Short path failed, file does not exist as specified.
33447    # Try adding .exe or .cmd
33448    if test -f "${new_path}.exe"; then
33449      input_to_shortpath="${new_path}.exe"
33450    elif test -f "${new_path}.cmd"; then
33451      input_to_shortpath="${new_path}.cmd"
33452    else
33453      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
33454$as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
33455      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33456$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33457      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33458    fi
33459  else
33460    input_to_shortpath="$new_path"
33461  fi
33462
33463  # Call helper function which possibly converts this using DOS-style short mode.
33464  # If so, the updated path is stored in $new_path.
33465  new_path="$input_to_shortpath"
33466
33467  input_path="$input_to_shortpath"
33468  # Check if we need to convert this using DOS-style short mode. If the path
33469  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33470  # take no chances and rewrite it.
33471  # Note: m4 eats our [], so we need to use [ and ] instead.
33472  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33473  if test "x$has_forbidden_chars" != x; then
33474    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33475    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33476    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33477    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33478      # Going to short mode and back again did indeed matter. Since short mode is
33479      # case insensitive, let's make it lowercase to improve readability.
33480      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33481      # Now convert it back to Unix-stile (cygpath)
33482      input_path=`$CYGPATH -u "$shortmode_path"`
33483      new_path="$input_path"
33484    fi
33485  fi
33486
33487  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33488  if test "x$test_cygdrive_prefix" = x; then
33489    # As a simple fix, exclude /usr/bin since it's not a real path.
33490    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33491      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33492      # a path prefixed by /cygdrive for fixpath to work.
33493      new_path="$CYGWIN_ROOT_PATH$input_path"
33494    fi
33495  fi
33496
33497  # remove trailing .exe if any
33498  new_path="${new_path/%.exe/}"
33499
33500  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33501
33502  # First separate the path from the arguments. This will split at the first
33503  # space.
33504  complete="$LIPO"
33505  path="${complete%% *}"
33506  tmp="$complete EOL"
33507  arguments="${tmp#* }"
33508
33509  # Input might be given as Windows format, start by converting to
33510  # unix format.
33511  new_path="$path"
33512
33513  windows_path="$new_path"
33514  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33515    unix_path=`$CYGPATH -u "$windows_path"`
33516    new_path="$unix_path"
33517  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33518    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33519    new_path="$unix_path"
33520  fi
33521
33522
33523  # Now try to locate executable using which
33524  new_path=`$WHICH "$new_path" 2> /dev/null`
33525
33526  if test "x$new_path" = x; then
33527    # Oops. Which didn't find the executable.
33528    # The splitting of arguments from the executable at a space might have been incorrect,
33529    # since paths with space are more likely in Windows. Give it another try with the whole
33530    # argument.
33531    path="$complete"
33532    arguments="EOL"
33533    new_path="$path"
33534
33535  windows_path="$new_path"
33536  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33537    unix_path=`$CYGPATH -u "$windows_path"`
33538    new_path="$unix_path"
33539  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33540    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33541    new_path="$unix_path"
33542  fi
33543
33544
33545    new_path=`$WHICH "$new_path" 2> /dev/null`
33546
33547    if test "x$new_path" = x; then
33548      # It's still not found. Now this is an unrecoverable error.
33549      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33550$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33551      has_space=`$ECHO "$complete" | $GREP " "`
33552      if test "x$has_space" != x; then
33553        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33554$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33555      fi
33556      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33557    fi
33558  fi
33559
33560  # Now new_path has a complete unix path to the binary
33561  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33562    # Keep paths in /bin as-is, but remove trailing .exe if any
33563    new_path="${new_path/%.exe/}"
33564    # Do not save /bin paths to all_fixpath_prefixes!
33565  else
33566    # Not in mixed or Windows style, start by that.
33567    new_path=`cmd //c echo $new_path`
33568
33569  input_path="$new_path"
33570  # Check if we need to convert this using DOS-style short mode. If the path
33571  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33572  # take no chances and rewrite it.
33573  # Note: m4 eats our [], so we need to use [ and ] instead.
33574  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33575  if test "x$has_forbidden_chars" != x; then
33576    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33577    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33578  fi
33579
33580    # Output is in $new_path
33581
33582  windows_path="$new_path"
33583  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33584    unix_path=`$CYGPATH -u "$windows_path"`
33585    new_path="$unix_path"
33586  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33587    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33588    new_path="$unix_path"
33589  fi
33590
33591    # remove trailing .exe if any
33592    new_path="${new_path/%.exe/}"
33593
33594    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33595    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33596  fi
33597
33598  else
33599    # We're on a posix platform. Hooray! :)
33600    # First separate the path from the arguments. This will split at the first
33601    # space.
33602    complete="$LIPO"
33603    path="${complete%% *}"
33604    tmp="$complete EOL"
33605    arguments="${tmp#* }"
33606
33607    # Cannot rely on the command "which" here since it doesn't always work.
33608    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33609    if test -z "$is_absolute_path"; then
33610      # Path to executable is not absolute. Find it.
33611      IFS_save="$IFS"
33612      IFS=:
33613      for p in $PATH; do
33614        if test -f "$p/$path" && test -x "$p/$path"; then
33615          new_path="$p/$path"
33616          break
33617        fi
33618      done
33619      IFS="$IFS_save"
33620    else
33621      # This is an absolute path, we can use it without further modifications.
33622      new_path="$path"
33623    fi
33624
33625    if test "x$new_path" = x; then
33626      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33627$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33628      has_space=`$ECHO "$complete" | $GREP " "`
33629      if test "x$has_space" != x; then
33630        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33631$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33632      fi
33633      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33634    fi
33635  fi
33636
33637  # Now join together the path and the arguments once again
33638  if test "x$arguments" != xEOL; then
33639    new_complete="$new_path ${arguments% *}"
33640  else
33641    new_complete="$new_path"
33642  fi
33643
33644  if test "x$complete" != "x$new_complete"; then
33645    LIPO="$new_complete"
33646    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
33647$as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
33648  fi
33649
33650  else
33651    OBJC=
33652  fi
33653
33654  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
33655    # Extract the first word of "mt", so it can be a program name with args.
33656set dummy mt; ac_word=$2
33657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33658$as_echo_n "checking for $ac_word... " >&6; }
33659if ${ac_cv_prog_MT+:} false; then :
33660  $as_echo_n "(cached) " >&6
33661else
33662  if test -n "$MT"; then
33663  ac_cv_prog_MT="$MT" # Let the user override the test.
33664else
33665  ac_prog_rejected=no
33666as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33667for as_dir in $PATH
33668do
33669  IFS=$as_save_IFS
33670  test -z "$as_dir" && as_dir=.
33671    for ac_exec_ext in '' $ac_executable_extensions; do
33672  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33673    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
33674       ac_prog_rejected=yes
33675       continue
33676     fi
33677    ac_cv_prog_MT="mt"
33678    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33679    break 2
33680  fi
33681done
33682  done
33683IFS=$as_save_IFS
33684
33685if test $ac_prog_rejected = yes; then
33686  # We found a bogon in the path, so make sure we never use it.
33687  set dummy $ac_cv_prog_MT
33688  shift
33689  if test $# != 0; then
33690    # We chose a different compiler from the bogus one.
33691    # However, it has the same basename, so the bogon will be chosen
33692    # first if we set MT to just the basename; use the full file name.
33693    shift
33694    ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
33695  fi
33696fi
33697fi
33698fi
33699MT=$ac_cv_prog_MT
33700if test -n "$MT"; then
33701  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
33702$as_echo "$MT" >&6; }
33703else
33704  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33705$as_echo "no" >&6; }
33706fi
33707
33708
33709
33710  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33711
33712  # First separate the path from the arguments. This will split at the first
33713  # space.
33714  complete="$MT"
33715  path="${complete%% *}"
33716  tmp="$complete EOL"
33717  arguments="${tmp#* }"
33718
33719  # Input might be given as Windows format, start by converting to
33720  # unix format.
33721  new_path=`$CYGPATH -u "$path"`
33722
33723  # Now try to locate executable using which
33724  new_path=`$WHICH "$new_path" 2> /dev/null`
33725  # bat and cmd files are not always considered executable in cygwin causing which
33726  # to not find them
33727  if test "x$new_path" = x \
33728      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33729      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33730    new_path=`$CYGPATH -u "$path"`
33731  fi
33732  if test "x$new_path" = x; then
33733    # Oops. Which didn't find the executable.
33734    # The splitting of arguments from the executable at a space might have been incorrect,
33735    # since paths with space are more likely in Windows. Give it another try with the whole
33736    # argument.
33737    path="$complete"
33738    arguments="EOL"
33739    new_path=`$CYGPATH -u "$path"`
33740    new_path=`$WHICH "$new_path" 2> /dev/null`
33741    # bat and cmd files are not always considered executable in cygwin causing which
33742    # to not find them
33743    if test "x$new_path" = x \
33744        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33745        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33746      new_path=`$CYGPATH -u "$path"`
33747    fi
33748    if test "x$new_path" = x; then
33749      # It's still not found. Now this is an unrecoverable error.
33750      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33751$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33752      has_space=`$ECHO "$complete" | $GREP " "`
33753      if test "x$has_space" != x; then
33754        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33755$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33756      fi
33757      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33758    fi
33759  fi
33760
33761  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33762  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33763  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33764  # "foo.exe" is OK but "foo" is an error.
33765  #
33766  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33767  # It is also a way to make sure we got the proper file name for the real test later on.
33768  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33769  if test "x$test_shortpath" = x; then
33770    # Short path failed, file does not exist as specified.
33771    # Try adding .exe or .cmd
33772    if test -f "${new_path}.exe"; then
33773      input_to_shortpath="${new_path}.exe"
33774    elif test -f "${new_path}.cmd"; then
33775      input_to_shortpath="${new_path}.cmd"
33776    else
33777      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
33778$as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
33779      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33780$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33781      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33782    fi
33783  else
33784    input_to_shortpath="$new_path"
33785  fi
33786
33787  # Call helper function which possibly converts this using DOS-style short mode.
33788  # If so, the updated path is stored in $new_path.
33789  new_path="$input_to_shortpath"
33790
33791  input_path="$input_to_shortpath"
33792  # Check if we need to convert this using DOS-style short mode. If the path
33793  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33794  # take no chances and rewrite it.
33795  # Note: m4 eats our [], so we need to use [ and ] instead.
33796  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33797  if test "x$has_forbidden_chars" != x; then
33798    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33799    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33800    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33801    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33802      # Going to short mode and back again did indeed matter. Since short mode is
33803      # case insensitive, let's make it lowercase to improve readability.
33804      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33805      # Now convert it back to Unix-stile (cygpath)
33806      input_path=`$CYGPATH -u "$shortmode_path"`
33807      new_path="$input_path"
33808    fi
33809  fi
33810
33811  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33812  if test "x$test_cygdrive_prefix" = x; then
33813    # As a simple fix, exclude /usr/bin since it's not a real path.
33814    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33815      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33816      # a path prefixed by /cygdrive for fixpath to work.
33817      new_path="$CYGWIN_ROOT_PATH$input_path"
33818    fi
33819  fi
33820
33821  # remove trailing .exe if any
33822  new_path="${new_path/%.exe/}"
33823
33824  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33825
33826  # First separate the path from the arguments. This will split at the first
33827  # space.
33828  complete="$MT"
33829  path="${complete%% *}"
33830  tmp="$complete EOL"
33831  arguments="${tmp#* }"
33832
33833  # Input might be given as Windows format, start by converting to
33834  # unix format.
33835  new_path="$path"
33836
33837  windows_path="$new_path"
33838  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33839    unix_path=`$CYGPATH -u "$windows_path"`
33840    new_path="$unix_path"
33841  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33842    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33843    new_path="$unix_path"
33844  fi
33845
33846
33847  # Now try to locate executable using which
33848  new_path=`$WHICH "$new_path" 2> /dev/null`
33849
33850  if test "x$new_path" = x; then
33851    # Oops. Which didn't find the executable.
33852    # The splitting of arguments from the executable at a space might have been incorrect,
33853    # since paths with space are more likely in Windows. Give it another try with the whole
33854    # argument.
33855    path="$complete"
33856    arguments="EOL"
33857    new_path="$path"
33858
33859  windows_path="$new_path"
33860  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33861    unix_path=`$CYGPATH -u "$windows_path"`
33862    new_path="$unix_path"
33863  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33864    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33865    new_path="$unix_path"
33866  fi
33867
33868
33869    new_path=`$WHICH "$new_path" 2> /dev/null`
33870
33871    if test "x$new_path" = x; then
33872      # It's still not found. Now this is an unrecoverable error.
33873      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33874$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33875      has_space=`$ECHO "$complete" | $GREP " "`
33876      if test "x$has_space" != x; then
33877        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33878$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33879      fi
33880      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33881    fi
33882  fi
33883
33884  # Now new_path has a complete unix path to the binary
33885  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33886    # Keep paths in /bin as-is, but remove trailing .exe if any
33887    new_path="${new_path/%.exe/}"
33888    # Do not save /bin paths to all_fixpath_prefixes!
33889  else
33890    # Not in mixed or Windows style, start by that.
33891    new_path=`cmd //c echo $new_path`
33892
33893  input_path="$new_path"
33894  # Check if we need to convert this using DOS-style short mode. If the path
33895  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33896  # take no chances and rewrite it.
33897  # Note: m4 eats our [], so we need to use [ and ] instead.
33898  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33899  if test "x$has_forbidden_chars" != x; then
33900    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33901    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33902  fi
33903
33904    # Output is in $new_path
33905
33906  windows_path="$new_path"
33907  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33908    unix_path=`$CYGPATH -u "$windows_path"`
33909    new_path="$unix_path"
33910  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33911    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33912    new_path="$unix_path"
33913  fi
33914
33915    # remove trailing .exe if any
33916    new_path="${new_path/%.exe/}"
33917
33918    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33919    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33920  fi
33921
33922  else
33923    # We're on a posix platform. Hooray! :)
33924    # First separate the path from the arguments. This will split at the first
33925    # space.
33926    complete="$MT"
33927    path="${complete%% *}"
33928    tmp="$complete EOL"
33929    arguments="${tmp#* }"
33930
33931    # Cannot rely on the command "which" here since it doesn't always work.
33932    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33933    if test -z "$is_absolute_path"; then
33934      # Path to executable is not absolute. Find it.
33935      IFS_save="$IFS"
33936      IFS=:
33937      for p in $PATH; do
33938        if test -f "$p/$path" && test -x "$p/$path"; then
33939          new_path="$p/$path"
33940          break
33941        fi
33942      done
33943      IFS="$IFS_save"
33944    else
33945      # This is an absolute path, we can use it without further modifications.
33946      new_path="$path"
33947    fi
33948
33949    if test "x$new_path" = x; then
33950      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33951$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33952      has_space=`$ECHO "$complete" | $GREP " "`
33953      if test "x$has_space" != x; then
33954        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33955$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33956      fi
33957      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33958    fi
33959  fi
33960
33961  # Now join together the path and the arguments once again
33962  if test "x$arguments" != xEOL; then
33963    new_complete="$new_path ${arguments% *}"
33964  else
33965    new_complete="$new_path"
33966  fi
33967
33968  if test "x$complete" != "x$new_complete"; then
33969    MT="$new_complete"
33970    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
33971$as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
33972  fi
33973
33974    # Setup the resource compiler (RC)
33975    # Extract the first word of "rc", so it can be a program name with args.
33976set dummy rc; ac_word=$2
33977{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33978$as_echo_n "checking for $ac_word... " >&6; }
33979if ${ac_cv_prog_RC+:} false; then :
33980  $as_echo_n "(cached) " >&6
33981else
33982  if test -n "$RC"; then
33983  ac_cv_prog_RC="$RC" # Let the user override the test.
33984else
33985  ac_prog_rejected=no
33986as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33987for as_dir in $PATH
33988do
33989  IFS=$as_save_IFS
33990  test -z "$as_dir" && as_dir=.
33991    for ac_exec_ext in '' $ac_executable_extensions; do
33992  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33993    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
33994       ac_prog_rejected=yes
33995       continue
33996     fi
33997    ac_cv_prog_RC="rc"
33998    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33999    break 2
34000  fi
34001done
34002  done
34003IFS=$as_save_IFS
34004
34005if test $ac_prog_rejected = yes; then
34006  # We found a bogon in the path, so make sure we never use it.
34007  set dummy $ac_cv_prog_RC
34008  shift
34009  if test $# != 0; then
34010    # We chose a different compiler from the bogus one.
34011    # However, it has the same basename, so the bogon will be chosen
34012    # first if we set RC to just the basename; use the full file name.
34013    shift
34014    ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34015  fi
34016fi
34017fi
34018fi
34019RC=$ac_cv_prog_RC
34020if test -n "$RC"; then
34021  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34022$as_echo "$RC" >&6; }
34023else
34024  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34025$as_echo "no" >&6; }
34026fi
34027
34028
34029
34030  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34031
34032  # First separate the path from the arguments. This will split at the first
34033  # space.
34034  complete="$RC"
34035  path="${complete%% *}"
34036  tmp="$complete EOL"
34037  arguments="${tmp#* }"
34038
34039  # Input might be given as Windows format, start by converting to
34040  # unix format.
34041  new_path=`$CYGPATH -u "$path"`
34042
34043  # Now try to locate executable using which
34044  new_path=`$WHICH "$new_path" 2> /dev/null`
34045  # bat and cmd files are not always considered executable in cygwin causing which
34046  # to not find them
34047  if test "x$new_path" = x \
34048      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34049      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34050    new_path=`$CYGPATH -u "$path"`
34051  fi
34052  if test "x$new_path" = x; then
34053    # Oops. Which didn't find the executable.
34054    # The splitting of arguments from the executable at a space might have been incorrect,
34055    # since paths with space are more likely in Windows. Give it another try with the whole
34056    # argument.
34057    path="$complete"
34058    arguments="EOL"
34059    new_path=`$CYGPATH -u "$path"`
34060    new_path=`$WHICH "$new_path" 2> /dev/null`
34061    # bat and cmd files are not always considered executable in cygwin causing which
34062    # to not find them
34063    if test "x$new_path" = x \
34064        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34065        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34066      new_path=`$CYGPATH -u "$path"`
34067    fi
34068    if test "x$new_path" = x; then
34069      # It's still not found. Now this is an unrecoverable error.
34070      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34071$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34072      has_space=`$ECHO "$complete" | $GREP " "`
34073      if test "x$has_space" != x; then
34074        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34075$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34076      fi
34077      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34078    fi
34079  fi
34080
34081  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34082  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34083  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34084  # "foo.exe" is OK but "foo" is an error.
34085  #
34086  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34087  # It is also a way to make sure we got the proper file name for the real test later on.
34088  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34089  if test "x$test_shortpath" = x; then
34090    # Short path failed, file does not exist as specified.
34091    # Try adding .exe or .cmd
34092    if test -f "${new_path}.exe"; then
34093      input_to_shortpath="${new_path}.exe"
34094    elif test -f "${new_path}.cmd"; then
34095      input_to_shortpath="${new_path}.cmd"
34096    else
34097      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34098$as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34099      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34100$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34101      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34102    fi
34103  else
34104    input_to_shortpath="$new_path"
34105  fi
34106
34107  # Call helper function which possibly converts this using DOS-style short mode.
34108  # If so, the updated path is stored in $new_path.
34109  new_path="$input_to_shortpath"
34110
34111  input_path="$input_to_shortpath"
34112  # Check if we need to convert this using DOS-style short mode. If the path
34113  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34114  # take no chances and rewrite it.
34115  # Note: m4 eats our [], so we need to use [ and ] instead.
34116  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34117  if test "x$has_forbidden_chars" != x; then
34118    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34119    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34120    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34121    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34122      # Going to short mode and back again did indeed matter. Since short mode is
34123      # case insensitive, let's make it lowercase to improve readability.
34124      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34125      # Now convert it back to Unix-stile (cygpath)
34126      input_path=`$CYGPATH -u "$shortmode_path"`
34127      new_path="$input_path"
34128    fi
34129  fi
34130
34131  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34132  if test "x$test_cygdrive_prefix" = x; then
34133    # As a simple fix, exclude /usr/bin since it's not a real path.
34134    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34135      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34136      # a path prefixed by /cygdrive for fixpath to work.
34137      new_path="$CYGWIN_ROOT_PATH$input_path"
34138    fi
34139  fi
34140
34141  # remove trailing .exe if any
34142  new_path="${new_path/%.exe/}"
34143
34144  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34145
34146  # First separate the path from the arguments. This will split at the first
34147  # space.
34148  complete="$RC"
34149  path="${complete%% *}"
34150  tmp="$complete EOL"
34151  arguments="${tmp#* }"
34152
34153  # Input might be given as Windows format, start by converting to
34154  # unix format.
34155  new_path="$path"
34156
34157  windows_path="$new_path"
34158  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34159    unix_path=`$CYGPATH -u "$windows_path"`
34160    new_path="$unix_path"
34161  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34162    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34163    new_path="$unix_path"
34164  fi
34165
34166
34167  # Now try to locate executable using which
34168  new_path=`$WHICH "$new_path" 2> /dev/null`
34169
34170  if test "x$new_path" = x; then
34171    # Oops. Which didn't find the executable.
34172    # The splitting of arguments from the executable at a space might have been incorrect,
34173    # since paths with space are more likely in Windows. Give it another try with the whole
34174    # argument.
34175    path="$complete"
34176    arguments="EOL"
34177    new_path="$path"
34178
34179  windows_path="$new_path"
34180  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34181    unix_path=`$CYGPATH -u "$windows_path"`
34182    new_path="$unix_path"
34183  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34184    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34185    new_path="$unix_path"
34186  fi
34187
34188
34189    new_path=`$WHICH "$new_path" 2> /dev/null`
34190
34191    if test "x$new_path" = x; then
34192      # It's still not found. Now this is an unrecoverable error.
34193      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34194$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34195      has_space=`$ECHO "$complete" | $GREP " "`
34196      if test "x$has_space" != x; then
34197        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34198$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34199      fi
34200      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34201    fi
34202  fi
34203
34204  # Now new_path has a complete unix path to the binary
34205  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34206    # Keep paths in /bin as-is, but remove trailing .exe if any
34207    new_path="${new_path/%.exe/}"
34208    # Do not save /bin paths to all_fixpath_prefixes!
34209  else
34210    # Not in mixed or Windows style, start by that.
34211    new_path=`cmd //c echo $new_path`
34212
34213  input_path="$new_path"
34214  # Check if we need to convert this using DOS-style short mode. If the path
34215  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34216  # take no chances and rewrite it.
34217  # Note: m4 eats our [], so we need to use [ and ] instead.
34218  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34219  if test "x$has_forbidden_chars" != x; then
34220    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34221    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34222  fi
34223
34224    # Output is in $new_path
34225
34226  windows_path="$new_path"
34227  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34228    unix_path=`$CYGPATH -u "$windows_path"`
34229    new_path="$unix_path"
34230  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34231    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34232    new_path="$unix_path"
34233  fi
34234
34235    # remove trailing .exe if any
34236    new_path="${new_path/%.exe/}"
34237
34238    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34239    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34240  fi
34241
34242  else
34243    # We're on a posix platform. Hooray! :)
34244    # First separate the path from the arguments. This will split at the first
34245    # space.
34246    complete="$RC"
34247    path="${complete%% *}"
34248    tmp="$complete EOL"
34249    arguments="${tmp#* }"
34250
34251    # Cannot rely on the command "which" here since it doesn't always work.
34252    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34253    if test -z "$is_absolute_path"; then
34254      # Path to executable is not absolute. Find it.
34255      IFS_save="$IFS"
34256      IFS=:
34257      for p in $PATH; do
34258        if test -f "$p/$path" && test -x "$p/$path"; then
34259          new_path="$p/$path"
34260          break
34261        fi
34262      done
34263      IFS="$IFS_save"
34264    else
34265      # This is an absolute path, we can use it without further modifications.
34266      new_path="$path"
34267    fi
34268
34269    if test "x$new_path" = x; then
34270      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34271$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34272      has_space=`$ECHO "$complete" | $GREP " "`
34273      if test "x$has_space" != x; then
34274        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34275$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34276      fi
34277      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34278    fi
34279  fi
34280
34281  # Now join together the path and the arguments once again
34282  if test "x$arguments" != xEOL; then
34283    new_complete="$new_path ${arguments% *}"
34284  else
34285    new_complete="$new_path"
34286  fi
34287
34288  if test "x$complete" != "x$new_complete"; then
34289    RC="$new_complete"
34290    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34291$as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34292  fi
34293
34294    # Extract the first word of "dumpbin", so it can be a program name with args.
34295set dummy dumpbin; ac_word=$2
34296{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34297$as_echo_n "checking for $ac_word... " >&6; }
34298if ${ac_cv_prog_DUMPBIN+:} false; then :
34299  $as_echo_n "(cached) " >&6
34300else
34301  if test -n "$DUMPBIN"; then
34302  ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34303else
34304as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34305for as_dir in $PATH
34306do
34307  IFS=$as_save_IFS
34308  test -z "$as_dir" && as_dir=.
34309    for ac_exec_ext in '' $ac_executable_extensions; do
34310  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34311    ac_cv_prog_DUMPBIN="dumpbin"
34312    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34313    break 2
34314  fi
34315done
34316  done
34317IFS=$as_save_IFS
34318
34319fi
34320fi
34321DUMPBIN=$ac_cv_prog_DUMPBIN
34322if test -n "$DUMPBIN"; then
34323  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34324$as_echo "$DUMPBIN" >&6; }
34325else
34326  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34327$as_echo "no" >&6; }
34328fi
34329
34330
34331
34332  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34333
34334  # First separate the path from the arguments. This will split at the first
34335  # space.
34336  complete="$DUMPBIN"
34337  path="${complete%% *}"
34338  tmp="$complete EOL"
34339  arguments="${tmp#* }"
34340
34341  # Input might be given as Windows format, start by converting to
34342  # unix format.
34343  new_path=`$CYGPATH -u "$path"`
34344
34345  # Now try to locate executable using which
34346  new_path=`$WHICH "$new_path" 2> /dev/null`
34347  # bat and cmd files are not always considered executable in cygwin causing which
34348  # to not find them
34349  if test "x$new_path" = x \
34350      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34351      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34352    new_path=`$CYGPATH -u "$path"`
34353  fi
34354  if test "x$new_path" = x; then
34355    # Oops. Which didn't find the executable.
34356    # The splitting of arguments from the executable at a space might have been incorrect,
34357    # since paths with space are more likely in Windows. Give it another try with the whole
34358    # argument.
34359    path="$complete"
34360    arguments="EOL"
34361    new_path=`$CYGPATH -u "$path"`
34362    new_path=`$WHICH "$new_path" 2> /dev/null`
34363    # bat and cmd files are not always considered executable in cygwin causing which
34364    # to not find them
34365    if test "x$new_path" = x \
34366        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34367        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34368      new_path=`$CYGPATH -u "$path"`
34369    fi
34370    if test "x$new_path" = x; then
34371      # It's still not found. Now this is an unrecoverable error.
34372      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34373$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34374      has_space=`$ECHO "$complete" | $GREP " "`
34375      if test "x$has_space" != x; then
34376        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34377$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34378      fi
34379      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34380    fi
34381  fi
34382
34383  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34384  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34385  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34386  # "foo.exe" is OK but "foo" is an error.
34387  #
34388  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34389  # It is also a way to make sure we got the proper file name for the real test later on.
34390  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34391  if test "x$test_shortpath" = x; then
34392    # Short path failed, file does not exist as specified.
34393    # Try adding .exe or .cmd
34394    if test -f "${new_path}.exe"; then
34395      input_to_shortpath="${new_path}.exe"
34396    elif test -f "${new_path}.cmd"; then
34397      input_to_shortpath="${new_path}.cmd"
34398    else
34399      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34400$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34401      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34402$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34403      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34404    fi
34405  else
34406    input_to_shortpath="$new_path"
34407  fi
34408
34409  # Call helper function which possibly converts this using DOS-style short mode.
34410  # If so, the updated path is stored in $new_path.
34411  new_path="$input_to_shortpath"
34412
34413  input_path="$input_to_shortpath"
34414  # Check if we need to convert this using DOS-style short mode. If the path
34415  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34416  # take no chances and rewrite it.
34417  # Note: m4 eats our [], so we need to use [ and ] instead.
34418  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34419  if test "x$has_forbidden_chars" != x; then
34420    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34421    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34422    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34423    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34424      # Going to short mode and back again did indeed matter. Since short mode is
34425      # case insensitive, let's make it lowercase to improve readability.
34426      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34427      # Now convert it back to Unix-stile (cygpath)
34428      input_path=`$CYGPATH -u "$shortmode_path"`
34429      new_path="$input_path"
34430    fi
34431  fi
34432
34433  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34434  if test "x$test_cygdrive_prefix" = x; then
34435    # As a simple fix, exclude /usr/bin since it's not a real path.
34436    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34437      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34438      # a path prefixed by /cygdrive for fixpath to work.
34439      new_path="$CYGWIN_ROOT_PATH$input_path"
34440    fi
34441  fi
34442
34443  # remove trailing .exe if any
34444  new_path="${new_path/%.exe/}"
34445
34446  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34447
34448  # First separate the path from the arguments. This will split at the first
34449  # space.
34450  complete="$DUMPBIN"
34451  path="${complete%% *}"
34452  tmp="$complete EOL"
34453  arguments="${tmp#* }"
34454
34455  # Input might be given as Windows format, start by converting to
34456  # unix format.
34457  new_path="$path"
34458
34459  windows_path="$new_path"
34460  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34461    unix_path=`$CYGPATH -u "$windows_path"`
34462    new_path="$unix_path"
34463  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34464    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34465    new_path="$unix_path"
34466  fi
34467
34468
34469  # Now try to locate executable using which
34470  new_path=`$WHICH "$new_path" 2> /dev/null`
34471
34472  if test "x$new_path" = x; then
34473    # Oops. Which didn't find the executable.
34474    # The splitting of arguments from the executable at a space might have been incorrect,
34475    # since paths with space are more likely in Windows. Give it another try with the whole
34476    # argument.
34477    path="$complete"
34478    arguments="EOL"
34479    new_path="$path"
34480
34481  windows_path="$new_path"
34482  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34483    unix_path=`$CYGPATH -u "$windows_path"`
34484    new_path="$unix_path"
34485  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34486    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34487    new_path="$unix_path"
34488  fi
34489
34490
34491    new_path=`$WHICH "$new_path" 2> /dev/null`
34492
34493    if test "x$new_path" = x; then
34494      # It's still not found. Now this is an unrecoverable error.
34495      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34496$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34497      has_space=`$ECHO "$complete" | $GREP " "`
34498      if test "x$has_space" != x; then
34499        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34500$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34501      fi
34502      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34503    fi
34504  fi
34505
34506  # Now new_path has a complete unix path to the binary
34507  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34508    # Keep paths in /bin as-is, but remove trailing .exe if any
34509    new_path="${new_path/%.exe/}"
34510    # Do not save /bin paths to all_fixpath_prefixes!
34511  else
34512    # Not in mixed or Windows style, start by that.
34513    new_path=`cmd //c echo $new_path`
34514
34515  input_path="$new_path"
34516  # Check if we need to convert this using DOS-style short mode. If the path
34517  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34518  # take no chances and rewrite it.
34519  # Note: m4 eats our [], so we need to use [ and ] instead.
34520  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34521  if test "x$has_forbidden_chars" != x; then
34522    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34523    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34524  fi
34525
34526    # Output is in $new_path
34527
34528  windows_path="$new_path"
34529  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34530    unix_path=`$CYGPATH -u "$windows_path"`
34531    new_path="$unix_path"
34532  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34533    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34534    new_path="$unix_path"
34535  fi
34536
34537    # remove trailing .exe if any
34538    new_path="${new_path/%.exe/}"
34539
34540    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34541    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34542  fi
34543
34544  else
34545    # We're on a posix platform. Hooray! :)
34546    # First separate the path from the arguments. This will split at the first
34547    # space.
34548    complete="$DUMPBIN"
34549    path="${complete%% *}"
34550    tmp="$complete EOL"
34551    arguments="${tmp#* }"
34552
34553    # Cannot rely on the command "which" here since it doesn't always work.
34554    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34555    if test -z "$is_absolute_path"; then
34556      # Path to executable is not absolute. Find it.
34557      IFS_save="$IFS"
34558      IFS=:
34559      for p in $PATH; do
34560        if test -f "$p/$path" && test -x "$p/$path"; then
34561          new_path="$p/$path"
34562          break
34563        fi
34564      done
34565      IFS="$IFS_save"
34566    else
34567      # This is an absolute path, we can use it without further modifications.
34568      new_path="$path"
34569    fi
34570
34571    if test "x$new_path" = x; then
34572      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34573$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34574      has_space=`$ECHO "$complete" | $GREP " "`
34575      if test "x$has_space" != x; then
34576        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34577$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34578      fi
34579      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34580    fi
34581  fi
34582
34583  # Now join together the path and the arguments once again
34584  if test "x$arguments" != xEOL; then
34585    new_complete="$new_path ${arguments% *}"
34586  else
34587    new_complete="$new_path"
34588  fi
34589
34590  if test "x$complete" != "x$new_complete"; then
34591    DUMPBIN="$new_complete"
34592    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
34593$as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
34594  fi
34595
34596  fi
34597
34598  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
34599
34600
34601  # Publish this variable in the help.
34602
34603
34604  if test "x$STRIP" = x; then
34605    # The variable is not set by user, try to locate tool using the code snippet
34606    for ac_prog in strip
34607do
34608  # Extract the first word of "$ac_prog", so it can be a program name with args.
34609set dummy $ac_prog; ac_word=$2
34610{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34611$as_echo_n "checking for $ac_word... " >&6; }
34612if ${ac_cv_path_STRIP+:} false; then :
34613  $as_echo_n "(cached) " >&6
34614else
34615  case $STRIP in
34616  [\\/]* | ?:[\\/]*)
34617  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34618  ;;
34619  *)
34620  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34621for as_dir in $PATH
34622do
34623  IFS=$as_save_IFS
34624  test -z "$as_dir" && as_dir=.
34625    for ac_exec_ext in '' $ac_executable_extensions; do
34626  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34627    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34628    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34629    break 2
34630  fi
34631done
34632  done
34633IFS=$as_save_IFS
34634
34635  ;;
34636esac
34637fi
34638STRIP=$ac_cv_path_STRIP
34639if test -n "$STRIP"; then
34640  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34641$as_echo "$STRIP" >&6; }
34642else
34643  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34644$as_echo "no" >&6; }
34645fi
34646
34647
34648  test -n "$STRIP" && break
34649done
34650
34651  else
34652    # The variable is set, but is it from the command line or the environment?
34653
34654    # Try to remove the string !STRIP! from our list.
34655    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
34656    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
34657      # If it failed, the variable was not from the command line. Ignore it,
34658      # but warn the user (except for BASH, which is always set by the calling BASH).
34659      if test "xSTRIP" != xBASH; then
34660        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
34661$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
34662      fi
34663      # Try to locate tool using the code snippet
34664      for ac_prog in strip
34665do
34666  # Extract the first word of "$ac_prog", so it can be a program name with args.
34667set dummy $ac_prog; ac_word=$2
34668{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34669$as_echo_n "checking for $ac_word... " >&6; }
34670if ${ac_cv_path_STRIP+:} false; then :
34671  $as_echo_n "(cached) " >&6
34672else
34673  case $STRIP in
34674  [\\/]* | ?:[\\/]*)
34675  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34676  ;;
34677  *)
34678  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34679for as_dir in $PATH
34680do
34681  IFS=$as_save_IFS
34682  test -z "$as_dir" && as_dir=.
34683    for ac_exec_ext in '' $ac_executable_extensions; do
34684  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34685    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34686    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34687    break 2
34688  fi
34689done
34690  done
34691IFS=$as_save_IFS
34692
34693  ;;
34694esac
34695fi
34696STRIP=$ac_cv_path_STRIP
34697if test -n "$STRIP"; then
34698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34699$as_echo "$STRIP" >&6; }
34700else
34701  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34702$as_echo "no" >&6; }
34703fi
34704
34705
34706  test -n "$STRIP" && break
34707done
34708
34709    else
34710      # If it succeeded, then it was overridden by the user. We will use it
34711      # for the tool.
34712
34713      # First remove it from the list of overridden variables, so we can test
34714      # for unknown variables in the end.
34715      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
34716
34717      # Check if the provided tool contains a complete path.
34718      tool_specified="$STRIP"
34719      tool_basename="${tool_specified##*/}"
34720      if test "x$tool_basename" = "x$tool_specified"; then
34721        # A command without a complete path is provided, search $PATH.
34722        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
34723$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
34724        # Extract the first word of "$tool_basename", so it can be a program name with args.
34725set dummy $tool_basename; ac_word=$2
34726{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34727$as_echo_n "checking for $ac_word... " >&6; }
34728if ${ac_cv_path_STRIP+:} false; then :
34729  $as_echo_n "(cached) " >&6
34730else
34731  case $STRIP in
34732  [\\/]* | ?:[\\/]*)
34733  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34734  ;;
34735  *)
34736  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34737for as_dir in $PATH
34738do
34739  IFS=$as_save_IFS
34740  test -z "$as_dir" && as_dir=.
34741    for ac_exec_ext in '' $ac_executable_extensions; do
34742  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34743    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34744    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34745    break 2
34746  fi
34747done
34748  done
34749IFS=$as_save_IFS
34750
34751  ;;
34752esac
34753fi
34754STRIP=$ac_cv_path_STRIP
34755if test -n "$STRIP"; then
34756  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34757$as_echo "$STRIP" >&6; }
34758else
34759  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34760$as_echo "no" >&6; }
34761fi
34762
34763
34764        if test "x$STRIP" = x; then
34765          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
34766        fi
34767      else
34768        # Otherwise we believe it is a complete path. Use it as it is.
34769        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
34770$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
34771        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
34772$as_echo_n "checking for STRIP... " >&6; }
34773        if test ! -x "$tool_specified"; then
34774          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
34775$as_echo "not found" >&6; }
34776          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
34777        fi
34778        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
34779$as_echo "$tool_specified" >&6; }
34780      fi
34781    fi
34782  fi
34783
34784
34785
34786  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34787
34788  # First separate the path from the arguments. This will split at the first
34789  # space.
34790  complete="$STRIP"
34791  path="${complete%% *}"
34792  tmp="$complete EOL"
34793  arguments="${tmp#* }"
34794
34795  # Input might be given as Windows format, start by converting to
34796  # unix format.
34797  new_path=`$CYGPATH -u "$path"`
34798
34799  # Now try to locate executable using which
34800  new_path=`$WHICH "$new_path" 2> /dev/null`
34801  # bat and cmd files are not always considered executable in cygwin causing which
34802  # to not find them
34803  if test "x$new_path" = x \
34804      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34805      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34806    new_path=`$CYGPATH -u "$path"`
34807  fi
34808  if test "x$new_path" = x; then
34809    # Oops. Which didn't find the executable.
34810    # The splitting of arguments from the executable at a space might have been incorrect,
34811    # since paths with space are more likely in Windows. Give it another try with the whole
34812    # argument.
34813    path="$complete"
34814    arguments="EOL"
34815    new_path=`$CYGPATH -u "$path"`
34816    new_path=`$WHICH "$new_path" 2> /dev/null`
34817    # bat and cmd files are not always considered executable in cygwin causing which
34818    # to not find them
34819    if test "x$new_path" = x \
34820        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34821        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34822      new_path=`$CYGPATH -u "$path"`
34823    fi
34824    if test "x$new_path" = x; then
34825      # It's still not found. Now this is an unrecoverable error.
34826      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34827$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34828      has_space=`$ECHO "$complete" | $GREP " "`
34829      if test "x$has_space" != x; then
34830        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34831$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34832      fi
34833      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34834    fi
34835  fi
34836
34837  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34838  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34839  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34840  # "foo.exe" is OK but "foo" is an error.
34841  #
34842  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34843  # It is also a way to make sure we got the proper file name for the real test later on.
34844  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34845  if test "x$test_shortpath" = x; then
34846    # Short path failed, file does not exist as specified.
34847    # Try adding .exe or .cmd
34848    if test -f "${new_path}.exe"; then
34849      input_to_shortpath="${new_path}.exe"
34850    elif test -f "${new_path}.cmd"; then
34851      input_to_shortpath="${new_path}.cmd"
34852    else
34853      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
34854$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
34855      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34856$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34857      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34858    fi
34859  else
34860    input_to_shortpath="$new_path"
34861  fi
34862
34863  # Call helper function which possibly converts this using DOS-style short mode.
34864  # If so, the updated path is stored in $new_path.
34865  new_path="$input_to_shortpath"
34866
34867  input_path="$input_to_shortpath"
34868  # Check if we need to convert this using DOS-style short mode. If the path
34869  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34870  # take no chances and rewrite it.
34871  # Note: m4 eats our [], so we need to use [ and ] instead.
34872  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34873  if test "x$has_forbidden_chars" != x; then
34874    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34875    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34876    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34877    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34878      # Going to short mode and back again did indeed matter. Since short mode is
34879      # case insensitive, let's make it lowercase to improve readability.
34880      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34881      # Now convert it back to Unix-stile (cygpath)
34882      input_path=`$CYGPATH -u "$shortmode_path"`
34883      new_path="$input_path"
34884    fi
34885  fi
34886
34887  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34888  if test "x$test_cygdrive_prefix" = x; then
34889    # As a simple fix, exclude /usr/bin since it's not a real path.
34890    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34891      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34892      # a path prefixed by /cygdrive for fixpath to work.
34893      new_path="$CYGWIN_ROOT_PATH$input_path"
34894    fi
34895  fi
34896
34897  # remove trailing .exe if any
34898  new_path="${new_path/%.exe/}"
34899
34900  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34901
34902  # First separate the path from the arguments. This will split at the first
34903  # space.
34904  complete="$STRIP"
34905  path="${complete%% *}"
34906  tmp="$complete EOL"
34907  arguments="${tmp#* }"
34908
34909  # Input might be given as Windows format, start by converting to
34910  # unix format.
34911  new_path="$path"
34912
34913  windows_path="$new_path"
34914  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34915    unix_path=`$CYGPATH -u "$windows_path"`
34916    new_path="$unix_path"
34917  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34918    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34919    new_path="$unix_path"
34920  fi
34921
34922
34923  # Now try to locate executable using which
34924  new_path=`$WHICH "$new_path" 2> /dev/null`
34925
34926  if test "x$new_path" = x; then
34927    # Oops. Which didn't find the executable.
34928    # The splitting of arguments from the executable at a space might have been incorrect,
34929    # since paths with space are more likely in Windows. Give it another try with the whole
34930    # argument.
34931    path="$complete"
34932    arguments="EOL"
34933    new_path="$path"
34934
34935  windows_path="$new_path"
34936  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34937    unix_path=`$CYGPATH -u "$windows_path"`
34938    new_path="$unix_path"
34939  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34940    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34941    new_path="$unix_path"
34942  fi
34943
34944
34945    new_path=`$WHICH "$new_path" 2> /dev/null`
34946
34947    if test "x$new_path" = x; then
34948      # It's still not found. Now this is an unrecoverable error.
34949      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34950$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34951      has_space=`$ECHO "$complete" | $GREP " "`
34952      if test "x$has_space" != x; then
34953        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34954$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34955      fi
34956      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34957    fi
34958  fi
34959
34960  # Now new_path has a complete unix path to the binary
34961  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34962    # Keep paths in /bin as-is, but remove trailing .exe if any
34963    new_path="${new_path/%.exe/}"
34964    # Do not save /bin paths to all_fixpath_prefixes!
34965  else
34966    # Not in mixed or Windows style, start by that.
34967    new_path=`cmd //c echo $new_path`
34968
34969  input_path="$new_path"
34970  # Check if we need to convert this using DOS-style short mode. If the path
34971  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34972  # take no chances and rewrite it.
34973  # Note: m4 eats our [], so we need to use [ and ] instead.
34974  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34975  if test "x$has_forbidden_chars" != x; then
34976    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34977    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34978  fi
34979
34980    # Output is in $new_path
34981
34982  windows_path="$new_path"
34983  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34984    unix_path=`$CYGPATH -u "$windows_path"`
34985    new_path="$unix_path"
34986  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34987    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34988    new_path="$unix_path"
34989  fi
34990
34991    # remove trailing .exe if any
34992    new_path="${new_path/%.exe/}"
34993
34994    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34995    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34996  fi
34997
34998  else
34999    # We're on a posix platform. Hooray! :)
35000    # First separate the path from the arguments. This will split at the first
35001    # space.
35002    complete="$STRIP"
35003    path="${complete%% *}"
35004    tmp="$complete EOL"
35005    arguments="${tmp#* }"
35006
35007    # Cannot rely on the command "which" here since it doesn't always work.
35008    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35009    if test -z "$is_absolute_path"; then
35010      # Path to executable is not absolute. Find it.
35011      IFS_save="$IFS"
35012      IFS=:
35013      for p in $PATH; do
35014        if test -f "$p/$path" && test -x "$p/$path"; then
35015          new_path="$p/$path"
35016          break
35017        fi
35018      done
35019      IFS="$IFS_save"
35020    else
35021      # This is an absolute path, we can use it without further modifications.
35022      new_path="$path"
35023    fi
35024
35025    if test "x$new_path" = x; then
35026      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35027$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35028      has_space=`$ECHO "$complete" | $GREP " "`
35029      if test "x$has_space" != x; then
35030        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35031$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35032      fi
35033      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35034    fi
35035  fi
35036
35037  # Now join together the path and the arguments once again
35038  if test "x$arguments" != xEOL; then
35039    new_complete="$new_path ${arguments% *}"
35040  else
35041    new_complete="$new_path"
35042  fi
35043
35044  if test "x$complete" != "x$new_complete"; then
35045    STRIP="$new_complete"
35046    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
35047$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
35048  fi
35049
35050
35051
35052  # Publish this variable in the help.
35053
35054
35055  if test "x$NM" = x; then
35056    # The variable is not set by user, try to locate tool using the code snippet
35057    for ac_prog in nm
35058do
35059  # Extract the first word of "$ac_prog", so it can be a program name with args.
35060set dummy $ac_prog; ac_word=$2
35061{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35062$as_echo_n "checking for $ac_word... " >&6; }
35063if ${ac_cv_path_NM+:} false; then :
35064  $as_echo_n "(cached) " >&6
35065else
35066  case $NM in
35067  [\\/]* | ?:[\\/]*)
35068  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35069  ;;
35070  *)
35071  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35072for as_dir in $PATH
35073do
35074  IFS=$as_save_IFS
35075  test -z "$as_dir" && as_dir=.
35076    for ac_exec_ext in '' $ac_executable_extensions; do
35077  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35078    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35079    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35080    break 2
35081  fi
35082done
35083  done
35084IFS=$as_save_IFS
35085
35086  ;;
35087esac
35088fi
35089NM=$ac_cv_path_NM
35090if test -n "$NM"; then
35091  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35092$as_echo "$NM" >&6; }
35093else
35094  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35095$as_echo "no" >&6; }
35096fi
35097
35098
35099  test -n "$NM" && break
35100done
35101
35102  else
35103    # The variable is set, but is it from the command line or the environment?
35104
35105    # Try to remove the string !NM! from our list.
35106    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
35107    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35108      # If it failed, the variable was not from the command line. Ignore it,
35109      # but warn the user (except for BASH, which is always set by the calling BASH).
35110      if test "xNM" != xBASH; then
35111        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
35112$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
35113      fi
35114      # Try to locate tool using the code snippet
35115      for ac_prog in nm
35116do
35117  # Extract the first word of "$ac_prog", so it can be a program name with args.
35118set dummy $ac_prog; ac_word=$2
35119{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35120$as_echo_n "checking for $ac_word... " >&6; }
35121if ${ac_cv_path_NM+:} false; then :
35122  $as_echo_n "(cached) " >&6
35123else
35124  case $NM in
35125  [\\/]* | ?:[\\/]*)
35126  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35127  ;;
35128  *)
35129  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35130for as_dir in $PATH
35131do
35132  IFS=$as_save_IFS
35133  test -z "$as_dir" && as_dir=.
35134    for ac_exec_ext in '' $ac_executable_extensions; do
35135  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35136    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35137    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35138    break 2
35139  fi
35140done
35141  done
35142IFS=$as_save_IFS
35143
35144  ;;
35145esac
35146fi
35147NM=$ac_cv_path_NM
35148if test -n "$NM"; then
35149  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35150$as_echo "$NM" >&6; }
35151else
35152  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35153$as_echo "no" >&6; }
35154fi
35155
35156
35157  test -n "$NM" && break
35158done
35159
35160    else
35161      # If it succeeded, then it was overridden by the user. We will use it
35162      # for the tool.
35163
35164      # First remove it from the list of overridden variables, so we can test
35165      # for unknown variables in the end.
35166      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35167
35168      # Check if the provided tool contains a complete path.
35169      tool_specified="$NM"
35170      tool_basename="${tool_specified##*/}"
35171      if test "x$tool_basename" = "x$tool_specified"; then
35172        # A command without a complete path is provided, search $PATH.
35173        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
35174$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
35175        # Extract the first word of "$tool_basename", so it can be a program name with args.
35176set dummy $tool_basename; ac_word=$2
35177{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35178$as_echo_n "checking for $ac_word... " >&6; }
35179if ${ac_cv_path_NM+:} false; then :
35180  $as_echo_n "(cached) " >&6
35181else
35182  case $NM in
35183  [\\/]* | ?:[\\/]*)
35184  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35185  ;;
35186  *)
35187  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35188for as_dir in $PATH
35189do
35190  IFS=$as_save_IFS
35191  test -z "$as_dir" && as_dir=.
35192    for ac_exec_ext in '' $ac_executable_extensions; do
35193  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35194    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35195    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35196    break 2
35197  fi
35198done
35199  done
35200IFS=$as_save_IFS
35201
35202  ;;
35203esac
35204fi
35205NM=$ac_cv_path_NM
35206if test -n "$NM"; then
35207  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35208$as_echo "$NM" >&6; }
35209else
35210  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35211$as_echo "no" >&6; }
35212fi
35213
35214
35215        if test "x$NM" = x; then
35216          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35217        fi
35218      else
35219        # Otherwise we believe it is a complete path. Use it as it is.
35220        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
35221$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
35222        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
35223$as_echo_n "checking for NM... " >&6; }
35224        if test ! -x "$tool_specified"; then
35225          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35226$as_echo "not found" >&6; }
35227          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
35228        fi
35229        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35230$as_echo "$tool_specified" >&6; }
35231      fi
35232    fi
35233  fi
35234
35235
35236
35237  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35238
35239  # First separate the path from the arguments. This will split at the first
35240  # space.
35241  complete="$NM"
35242  path="${complete%% *}"
35243  tmp="$complete EOL"
35244  arguments="${tmp#* }"
35245
35246  # Input might be given as Windows format, start by converting to
35247  # unix format.
35248  new_path=`$CYGPATH -u "$path"`
35249
35250  # Now try to locate executable using which
35251  new_path=`$WHICH "$new_path" 2> /dev/null`
35252  # bat and cmd files are not always considered executable in cygwin causing which
35253  # to not find them
35254  if test "x$new_path" = x \
35255      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35256      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35257    new_path=`$CYGPATH -u "$path"`
35258  fi
35259  if test "x$new_path" = x; then
35260    # Oops. Which didn't find the executable.
35261    # The splitting of arguments from the executable at a space might have been incorrect,
35262    # since paths with space are more likely in Windows. Give it another try with the whole
35263    # argument.
35264    path="$complete"
35265    arguments="EOL"
35266    new_path=`$CYGPATH -u "$path"`
35267    new_path=`$WHICH "$new_path" 2> /dev/null`
35268    # bat and cmd files are not always considered executable in cygwin causing which
35269    # to not find them
35270    if test "x$new_path" = x \
35271        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35272        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35273      new_path=`$CYGPATH -u "$path"`
35274    fi
35275    if test "x$new_path" = x; then
35276      # It's still not found. Now this is an unrecoverable error.
35277      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35278$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35279      has_space=`$ECHO "$complete" | $GREP " "`
35280      if test "x$has_space" != x; then
35281        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35282$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35283      fi
35284      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35285    fi
35286  fi
35287
35288  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35289  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35290  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35291  # "foo.exe" is OK but "foo" is an error.
35292  #
35293  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35294  # It is also a way to make sure we got the proper file name for the real test later on.
35295  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35296  if test "x$test_shortpath" = x; then
35297    # Short path failed, file does not exist as specified.
35298    # Try adding .exe or .cmd
35299    if test -f "${new_path}.exe"; then
35300      input_to_shortpath="${new_path}.exe"
35301    elif test -f "${new_path}.cmd"; then
35302      input_to_shortpath="${new_path}.cmd"
35303    else
35304      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
35305$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
35306      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35307$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35308      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35309    fi
35310  else
35311    input_to_shortpath="$new_path"
35312  fi
35313
35314  # Call helper function which possibly converts this using DOS-style short mode.
35315  # If so, the updated path is stored in $new_path.
35316  new_path="$input_to_shortpath"
35317
35318  input_path="$input_to_shortpath"
35319  # Check if we need to convert this using DOS-style short mode. If the path
35320  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35321  # take no chances and rewrite it.
35322  # Note: m4 eats our [], so we need to use [ and ] instead.
35323  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35324  if test "x$has_forbidden_chars" != x; then
35325    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35326    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35327    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35328    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35329      # Going to short mode and back again did indeed matter. Since short mode is
35330      # case insensitive, let's make it lowercase to improve readability.
35331      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35332      # Now convert it back to Unix-stile (cygpath)
35333      input_path=`$CYGPATH -u "$shortmode_path"`
35334      new_path="$input_path"
35335    fi
35336  fi
35337
35338  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35339  if test "x$test_cygdrive_prefix" = x; then
35340    # As a simple fix, exclude /usr/bin since it's not a real path.
35341    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35342      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35343      # a path prefixed by /cygdrive for fixpath to work.
35344      new_path="$CYGWIN_ROOT_PATH$input_path"
35345    fi
35346  fi
35347
35348  # remove trailing .exe if any
35349  new_path="${new_path/%.exe/}"
35350
35351  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35352
35353  # First separate the path from the arguments. This will split at the first
35354  # space.
35355  complete="$NM"
35356  path="${complete%% *}"
35357  tmp="$complete EOL"
35358  arguments="${tmp#* }"
35359
35360  # Input might be given as Windows format, start by converting to
35361  # unix format.
35362  new_path="$path"
35363
35364  windows_path="$new_path"
35365  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35366    unix_path=`$CYGPATH -u "$windows_path"`
35367    new_path="$unix_path"
35368  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35369    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35370    new_path="$unix_path"
35371  fi
35372
35373
35374  # Now try to locate executable using which
35375  new_path=`$WHICH "$new_path" 2> /dev/null`
35376
35377  if test "x$new_path" = x; then
35378    # Oops. Which didn't find the executable.
35379    # The splitting of arguments from the executable at a space might have been incorrect,
35380    # since paths with space are more likely in Windows. Give it another try with the whole
35381    # argument.
35382    path="$complete"
35383    arguments="EOL"
35384    new_path="$path"
35385
35386  windows_path="$new_path"
35387  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35388    unix_path=`$CYGPATH -u "$windows_path"`
35389    new_path="$unix_path"
35390  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35391    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35392    new_path="$unix_path"
35393  fi
35394
35395
35396    new_path=`$WHICH "$new_path" 2> /dev/null`
35397
35398    if test "x$new_path" = x; then
35399      # It's still not found. Now this is an unrecoverable error.
35400      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35401$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35402      has_space=`$ECHO "$complete" | $GREP " "`
35403      if test "x$has_space" != x; then
35404        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35405$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35406      fi
35407      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35408    fi
35409  fi
35410
35411  # Now new_path has a complete unix path to the binary
35412  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35413    # Keep paths in /bin as-is, but remove trailing .exe if any
35414    new_path="${new_path/%.exe/}"
35415    # Do not save /bin paths to all_fixpath_prefixes!
35416  else
35417    # Not in mixed or Windows style, start by that.
35418    new_path=`cmd //c echo $new_path`
35419
35420  input_path="$new_path"
35421  # Check if we need to convert this using DOS-style short mode. If the path
35422  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35423  # take no chances and rewrite it.
35424  # Note: m4 eats our [], so we need to use [ and ] instead.
35425  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35426  if test "x$has_forbidden_chars" != x; then
35427    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35428    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35429  fi
35430
35431    # Output is in $new_path
35432
35433  windows_path="$new_path"
35434  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35435    unix_path=`$CYGPATH -u "$windows_path"`
35436    new_path="$unix_path"
35437  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35438    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35439    new_path="$unix_path"
35440  fi
35441
35442    # remove trailing .exe if any
35443    new_path="${new_path/%.exe/}"
35444
35445    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35446    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35447  fi
35448
35449  else
35450    # We're on a posix platform. Hooray! :)
35451    # First separate the path from the arguments. This will split at the first
35452    # space.
35453    complete="$NM"
35454    path="${complete%% *}"
35455    tmp="$complete EOL"
35456    arguments="${tmp#* }"
35457
35458    # Cannot rely on the command "which" here since it doesn't always work.
35459    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35460    if test -z "$is_absolute_path"; then
35461      # Path to executable is not absolute. Find it.
35462      IFS_save="$IFS"
35463      IFS=:
35464      for p in $PATH; do
35465        if test -f "$p/$path" && test -x "$p/$path"; then
35466          new_path="$p/$path"
35467          break
35468        fi
35469      done
35470      IFS="$IFS_save"
35471    else
35472      # This is an absolute path, we can use it without further modifications.
35473      new_path="$path"
35474    fi
35475
35476    if test "x$new_path" = x; then
35477      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35478$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35479      has_space=`$ECHO "$complete" | $GREP " "`
35480      if test "x$has_space" != x; then
35481        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35482$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35483      fi
35484      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35485    fi
35486  fi
35487
35488  # Now join together the path and the arguments once again
35489  if test "x$arguments" != xEOL; then
35490    new_complete="$new_path ${arguments% *}"
35491  else
35492    new_complete="$new_path"
35493  fi
35494
35495  if test "x$complete" != "x$new_complete"; then
35496    NM="$new_complete"
35497    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
35498$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
35499  fi
35500
35501
35502
35503  # Publish this variable in the help.
35504
35505
35506  if test "x$GNM" = x; then
35507    # The variable is not set by user, try to locate tool using the code snippet
35508    for ac_prog in gnm
35509do
35510  # Extract the first word of "$ac_prog", so it can be a program name with args.
35511set dummy $ac_prog; ac_word=$2
35512{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35513$as_echo_n "checking for $ac_word... " >&6; }
35514if ${ac_cv_path_GNM+:} false; then :
35515  $as_echo_n "(cached) " >&6
35516else
35517  case $GNM in
35518  [\\/]* | ?:[\\/]*)
35519  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35520  ;;
35521  *)
35522  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35523for as_dir in $PATH
35524do
35525  IFS=$as_save_IFS
35526  test -z "$as_dir" && as_dir=.
35527    for ac_exec_ext in '' $ac_executable_extensions; do
35528  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35529    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35530    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35531    break 2
35532  fi
35533done
35534  done
35535IFS=$as_save_IFS
35536
35537  ;;
35538esac
35539fi
35540GNM=$ac_cv_path_GNM
35541if test -n "$GNM"; then
35542  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35543$as_echo "$GNM" >&6; }
35544else
35545  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35546$as_echo "no" >&6; }
35547fi
35548
35549
35550  test -n "$GNM" && break
35551done
35552
35553  else
35554    # The variable is set, but is it from the command line or the environment?
35555
35556    # Try to remove the string !GNM! from our list.
35557    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
35558    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35559      # If it failed, the variable was not from the command line. Ignore it,
35560      # but warn the user (except for BASH, which is always set by the calling BASH).
35561      if test "xGNM" != xBASH; then
35562        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
35563$as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
35564      fi
35565      # Try to locate tool using the code snippet
35566      for ac_prog in gnm
35567do
35568  # Extract the first word of "$ac_prog", so it can be a program name with args.
35569set dummy $ac_prog; ac_word=$2
35570{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35571$as_echo_n "checking for $ac_word... " >&6; }
35572if ${ac_cv_path_GNM+:} false; then :
35573  $as_echo_n "(cached) " >&6
35574else
35575  case $GNM in
35576  [\\/]* | ?:[\\/]*)
35577  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35578  ;;
35579  *)
35580  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35581for as_dir in $PATH
35582do
35583  IFS=$as_save_IFS
35584  test -z "$as_dir" && as_dir=.
35585    for ac_exec_ext in '' $ac_executable_extensions; do
35586  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35587    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35588    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35589    break 2
35590  fi
35591done
35592  done
35593IFS=$as_save_IFS
35594
35595  ;;
35596esac
35597fi
35598GNM=$ac_cv_path_GNM
35599if test -n "$GNM"; then
35600  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35601$as_echo "$GNM" >&6; }
35602else
35603  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35604$as_echo "no" >&6; }
35605fi
35606
35607
35608  test -n "$GNM" && break
35609done
35610
35611    else
35612      # If it succeeded, then it was overridden by the user. We will use it
35613      # for the tool.
35614
35615      # First remove it from the list of overridden variables, so we can test
35616      # for unknown variables in the end.
35617      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35618
35619      # Check if the provided tool contains a complete path.
35620      tool_specified="$GNM"
35621      tool_basename="${tool_specified##*/}"
35622      if test "x$tool_basename" = "x$tool_specified"; then
35623        # A command without a complete path is provided, search $PATH.
35624        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
35625$as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
35626        # Extract the first word of "$tool_basename", so it can be a program name with args.
35627set dummy $tool_basename; ac_word=$2
35628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35629$as_echo_n "checking for $ac_word... " >&6; }
35630if ${ac_cv_path_GNM+:} false; then :
35631  $as_echo_n "(cached) " >&6
35632else
35633  case $GNM in
35634  [\\/]* | ?:[\\/]*)
35635  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35636  ;;
35637  *)
35638  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35639for as_dir in $PATH
35640do
35641  IFS=$as_save_IFS
35642  test -z "$as_dir" && as_dir=.
35643    for ac_exec_ext in '' $ac_executable_extensions; do
35644  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35645    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35646    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35647    break 2
35648  fi
35649done
35650  done
35651IFS=$as_save_IFS
35652
35653  ;;
35654esac
35655fi
35656GNM=$ac_cv_path_GNM
35657if test -n "$GNM"; then
35658  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35659$as_echo "$GNM" >&6; }
35660else
35661  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35662$as_echo "no" >&6; }
35663fi
35664
35665
35666        if test "x$GNM" = x; then
35667          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35668        fi
35669      else
35670        # Otherwise we believe it is a complete path. Use it as it is.
35671        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
35672$as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
35673        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
35674$as_echo_n "checking for GNM... " >&6; }
35675        if test ! -x "$tool_specified"; then
35676          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35677$as_echo "not found" >&6; }
35678          as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
35679        fi
35680        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35681$as_echo "$tool_specified" >&6; }
35682      fi
35683    fi
35684  fi
35685
35686
35687
35688  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35689
35690  # First separate the path from the arguments. This will split at the first
35691  # space.
35692  complete="$GNM"
35693  path="${complete%% *}"
35694  tmp="$complete EOL"
35695  arguments="${tmp#* }"
35696
35697  # Input might be given as Windows format, start by converting to
35698  # unix format.
35699  new_path=`$CYGPATH -u "$path"`
35700
35701  # Now try to locate executable using which
35702  new_path=`$WHICH "$new_path" 2> /dev/null`
35703  # bat and cmd files are not always considered executable in cygwin causing which
35704  # to not find them
35705  if test "x$new_path" = x \
35706      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35707      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35708    new_path=`$CYGPATH -u "$path"`
35709  fi
35710  if test "x$new_path" = x; then
35711    # Oops. Which didn't find the executable.
35712    # The splitting of arguments from the executable at a space might have been incorrect,
35713    # since paths with space are more likely in Windows. Give it another try with the whole
35714    # argument.
35715    path="$complete"
35716    arguments="EOL"
35717    new_path=`$CYGPATH -u "$path"`
35718    new_path=`$WHICH "$new_path" 2> /dev/null`
35719    # bat and cmd files are not always considered executable in cygwin causing which
35720    # to not find them
35721    if test "x$new_path" = x \
35722        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35723        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35724      new_path=`$CYGPATH -u "$path"`
35725    fi
35726    if test "x$new_path" = x; then
35727      # It's still not found. Now this is an unrecoverable error.
35728      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35729$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35730      has_space=`$ECHO "$complete" | $GREP " "`
35731      if test "x$has_space" != x; then
35732        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35733$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35734      fi
35735      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35736    fi
35737  fi
35738
35739  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35740  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35741  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35742  # "foo.exe" is OK but "foo" is an error.
35743  #
35744  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35745  # It is also a way to make sure we got the proper file name for the real test later on.
35746  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35747  if test "x$test_shortpath" = x; then
35748    # Short path failed, file does not exist as specified.
35749    # Try adding .exe or .cmd
35750    if test -f "${new_path}.exe"; then
35751      input_to_shortpath="${new_path}.exe"
35752    elif test -f "${new_path}.cmd"; then
35753      input_to_shortpath="${new_path}.cmd"
35754    else
35755      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
35756$as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
35757      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35758$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35759      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35760    fi
35761  else
35762    input_to_shortpath="$new_path"
35763  fi
35764
35765  # Call helper function which possibly converts this using DOS-style short mode.
35766  # If so, the updated path is stored in $new_path.
35767  new_path="$input_to_shortpath"
35768
35769  input_path="$input_to_shortpath"
35770  # Check if we need to convert this using DOS-style short mode. If the path
35771  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35772  # take no chances and rewrite it.
35773  # Note: m4 eats our [], so we need to use [ and ] instead.
35774  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35775  if test "x$has_forbidden_chars" != x; then
35776    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35777    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35778    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35779    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35780      # Going to short mode and back again did indeed matter. Since short mode is
35781      # case insensitive, let's make it lowercase to improve readability.
35782      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35783      # Now convert it back to Unix-stile (cygpath)
35784      input_path=`$CYGPATH -u "$shortmode_path"`
35785      new_path="$input_path"
35786    fi
35787  fi
35788
35789  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35790  if test "x$test_cygdrive_prefix" = x; then
35791    # As a simple fix, exclude /usr/bin since it's not a real path.
35792    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35793      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35794      # a path prefixed by /cygdrive for fixpath to work.
35795      new_path="$CYGWIN_ROOT_PATH$input_path"
35796    fi
35797  fi
35798
35799  # remove trailing .exe if any
35800  new_path="${new_path/%.exe/}"
35801
35802  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35803
35804  # First separate the path from the arguments. This will split at the first
35805  # space.
35806  complete="$GNM"
35807  path="${complete%% *}"
35808  tmp="$complete EOL"
35809  arguments="${tmp#* }"
35810
35811  # Input might be given as Windows format, start by converting to
35812  # unix format.
35813  new_path="$path"
35814
35815  windows_path="$new_path"
35816  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35817    unix_path=`$CYGPATH -u "$windows_path"`
35818    new_path="$unix_path"
35819  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35820    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35821    new_path="$unix_path"
35822  fi
35823
35824
35825  # Now try to locate executable using which
35826  new_path=`$WHICH "$new_path" 2> /dev/null`
35827
35828  if test "x$new_path" = x; then
35829    # Oops. Which didn't find the executable.
35830    # The splitting of arguments from the executable at a space might have been incorrect,
35831    # since paths with space are more likely in Windows. Give it another try with the whole
35832    # argument.
35833    path="$complete"
35834    arguments="EOL"
35835    new_path="$path"
35836
35837  windows_path="$new_path"
35838  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35839    unix_path=`$CYGPATH -u "$windows_path"`
35840    new_path="$unix_path"
35841  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35842    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35843    new_path="$unix_path"
35844  fi
35845
35846
35847    new_path=`$WHICH "$new_path" 2> /dev/null`
35848
35849    if test "x$new_path" = x; then
35850      # It's still not found. Now this is an unrecoverable error.
35851      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35852$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35853      has_space=`$ECHO "$complete" | $GREP " "`
35854      if test "x$has_space" != x; then
35855        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35856$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35857      fi
35858      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35859    fi
35860  fi
35861
35862  # Now new_path has a complete unix path to the binary
35863  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35864    # Keep paths in /bin as-is, but remove trailing .exe if any
35865    new_path="${new_path/%.exe/}"
35866    # Do not save /bin paths to all_fixpath_prefixes!
35867  else
35868    # Not in mixed or Windows style, start by that.
35869    new_path=`cmd //c echo $new_path`
35870
35871  input_path="$new_path"
35872  # Check if we need to convert this using DOS-style short mode. If the path
35873  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35874  # take no chances and rewrite it.
35875  # Note: m4 eats our [], so we need to use [ and ] instead.
35876  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35877  if test "x$has_forbidden_chars" != x; then
35878    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35879    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35880  fi
35881
35882    # Output is in $new_path
35883
35884  windows_path="$new_path"
35885  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35886    unix_path=`$CYGPATH -u "$windows_path"`
35887    new_path="$unix_path"
35888  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35889    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35890    new_path="$unix_path"
35891  fi
35892
35893    # remove trailing .exe if any
35894    new_path="${new_path/%.exe/}"
35895
35896    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35897    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35898  fi
35899
35900  else
35901    # We're on a posix platform. Hooray! :)
35902    # First separate the path from the arguments. This will split at the first
35903    # space.
35904    complete="$GNM"
35905    path="${complete%% *}"
35906    tmp="$complete EOL"
35907    arguments="${tmp#* }"
35908
35909    # Cannot rely on the command "which" here since it doesn't always work.
35910    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35911    if test -z "$is_absolute_path"; then
35912      # Path to executable is not absolute. Find it.
35913      IFS_save="$IFS"
35914      IFS=:
35915      for p in $PATH; do
35916        if test -f "$p/$path" && test -x "$p/$path"; then
35917          new_path="$p/$path"
35918          break
35919        fi
35920      done
35921      IFS="$IFS_save"
35922    else
35923      # This is an absolute path, we can use it without further modifications.
35924      new_path="$path"
35925    fi
35926
35927    if test "x$new_path" = x; then
35928      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35929$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35930      has_space=`$ECHO "$complete" | $GREP " "`
35931      if test "x$has_space" != x; then
35932        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35933$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35934      fi
35935      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35936    fi
35937  fi
35938
35939  # Now join together the path and the arguments once again
35940  if test "x$arguments" != xEOL; then
35941    new_complete="$new_path ${arguments% *}"
35942  else
35943    new_complete="$new_path"
35944  fi
35945
35946  if test "x$complete" != "x$new_complete"; then
35947    GNM="$new_complete"
35948    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
35949$as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
35950  fi
35951
35952
35953
35954
35955  # Publish this variable in the help.
35956
35957
35958  if test "x$MCS" = x; then
35959    # The variable is not set by user, try to locate tool using the code snippet
35960    for ac_prog in mcs
35961do
35962  # Extract the first word of "$ac_prog", so it can be a program name with args.
35963set dummy $ac_prog; ac_word=$2
35964{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35965$as_echo_n "checking for $ac_word... " >&6; }
35966if ${ac_cv_path_MCS+:} false; then :
35967  $as_echo_n "(cached) " >&6
35968else
35969  case $MCS in
35970  [\\/]* | ?:[\\/]*)
35971  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
35972  ;;
35973  *)
35974  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35975for as_dir in $PATH
35976do
35977  IFS=$as_save_IFS
35978  test -z "$as_dir" && as_dir=.
35979    for ac_exec_ext in '' $ac_executable_extensions; do
35980  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35981    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
35982    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35983    break 2
35984  fi
35985done
35986  done
35987IFS=$as_save_IFS
35988
35989  ;;
35990esac
35991fi
35992MCS=$ac_cv_path_MCS
35993if test -n "$MCS"; then
35994  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
35995$as_echo "$MCS" >&6; }
35996else
35997  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35998$as_echo "no" >&6; }
35999fi
36000
36001
36002  test -n "$MCS" && break
36003done
36004
36005  else
36006    # The variable is set, but is it from the command line or the environment?
36007
36008    # Try to remove the string !MCS! from our list.
36009    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
36010    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36011      # If it failed, the variable was not from the command line. Ignore it,
36012      # but warn the user (except for BASH, which is always set by the calling BASH).
36013      if test "xMCS" != xBASH; then
36014        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
36015$as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
36016      fi
36017      # Try to locate tool using the code snippet
36018      for ac_prog in mcs
36019do
36020  # Extract the first word of "$ac_prog", so it can be a program name with args.
36021set dummy $ac_prog; ac_word=$2
36022{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36023$as_echo_n "checking for $ac_word... " >&6; }
36024if ${ac_cv_path_MCS+:} false; then :
36025  $as_echo_n "(cached) " >&6
36026else
36027  case $MCS in
36028  [\\/]* | ?:[\\/]*)
36029  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36030  ;;
36031  *)
36032  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36033for as_dir in $PATH
36034do
36035  IFS=$as_save_IFS
36036  test -z "$as_dir" && as_dir=.
36037    for ac_exec_ext in '' $ac_executable_extensions; do
36038  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36039    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36040    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36041    break 2
36042  fi
36043done
36044  done
36045IFS=$as_save_IFS
36046
36047  ;;
36048esac
36049fi
36050MCS=$ac_cv_path_MCS
36051if test -n "$MCS"; then
36052  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36053$as_echo "$MCS" >&6; }
36054else
36055  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36056$as_echo "no" >&6; }
36057fi
36058
36059
36060  test -n "$MCS" && break
36061done
36062
36063    else
36064      # If it succeeded, then it was overridden by the user. We will use it
36065      # for the tool.
36066
36067      # First remove it from the list of overridden variables, so we can test
36068      # for unknown variables in the end.
36069      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36070
36071      # Check if the provided tool contains a complete path.
36072      tool_specified="$MCS"
36073      tool_basename="${tool_specified##*/}"
36074      if test "x$tool_basename" = "x$tool_specified"; then
36075        # A command without a complete path is provided, search $PATH.
36076        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
36077$as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
36078        # Extract the first word of "$tool_basename", so it can be a program name with args.
36079set dummy $tool_basename; ac_word=$2
36080{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36081$as_echo_n "checking for $ac_word... " >&6; }
36082if ${ac_cv_path_MCS+:} false; then :
36083  $as_echo_n "(cached) " >&6
36084else
36085  case $MCS in
36086  [\\/]* | ?:[\\/]*)
36087  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36088  ;;
36089  *)
36090  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36091for as_dir in $PATH
36092do
36093  IFS=$as_save_IFS
36094  test -z "$as_dir" && as_dir=.
36095    for ac_exec_ext in '' $ac_executable_extensions; do
36096  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36097    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36098    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36099    break 2
36100  fi
36101done
36102  done
36103IFS=$as_save_IFS
36104
36105  ;;
36106esac
36107fi
36108MCS=$ac_cv_path_MCS
36109if test -n "$MCS"; then
36110  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36111$as_echo "$MCS" >&6; }
36112else
36113  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36114$as_echo "no" >&6; }
36115fi
36116
36117
36118        if test "x$MCS" = x; then
36119          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36120        fi
36121      else
36122        # Otherwise we believe it is a complete path. Use it as it is.
36123        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
36124$as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
36125        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
36126$as_echo_n "checking for MCS... " >&6; }
36127        if test ! -x "$tool_specified"; then
36128          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36129$as_echo "not found" >&6; }
36130          as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
36131        fi
36132        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36133$as_echo "$tool_specified" >&6; }
36134      fi
36135    fi
36136  fi
36137
36138
36139
36140  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36141
36142  # First separate the path from the arguments. This will split at the first
36143  # space.
36144  complete="$MCS"
36145  path="${complete%% *}"
36146  tmp="$complete EOL"
36147  arguments="${tmp#* }"
36148
36149  # Input might be given as Windows format, start by converting to
36150  # unix format.
36151  new_path=`$CYGPATH -u "$path"`
36152
36153  # Now try to locate executable using which
36154  new_path=`$WHICH "$new_path" 2> /dev/null`
36155  # bat and cmd files are not always considered executable in cygwin causing which
36156  # to not find them
36157  if test "x$new_path" = x \
36158      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36159      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36160    new_path=`$CYGPATH -u "$path"`
36161  fi
36162  if test "x$new_path" = x; then
36163    # Oops. Which didn't find the executable.
36164    # The splitting of arguments from the executable at a space might have been incorrect,
36165    # since paths with space are more likely in Windows. Give it another try with the whole
36166    # argument.
36167    path="$complete"
36168    arguments="EOL"
36169    new_path=`$CYGPATH -u "$path"`
36170    new_path=`$WHICH "$new_path" 2> /dev/null`
36171    # bat and cmd files are not always considered executable in cygwin causing which
36172    # to not find them
36173    if test "x$new_path" = x \
36174        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36175        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36176      new_path=`$CYGPATH -u "$path"`
36177    fi
36178    if test "x$new_path" = x; then
36179      # It's still not found. Now this is an unrecoverable error.
36180      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36181$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36182      has_space=`$ECHO "$complete" | $GREP " "`
36183      if test "x$has_space" != x; then
36184        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36185$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36186      fi
36187      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36188    fi
36189  fi
36190
36191  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36192  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36193  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36194  # "foo.exe" is OK but "foo" is an error.
36195  #
36196  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36197  # It is also a way to make sure we got the proper file name for the real test later on.
36198  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36199  if test "x$test_shortpath" = x; then
36200    # Short path failed, file does not exist as specified.
36201    # Try adding .exe or .cmd
36202    if test -f "${new_path}.exe"; then
36203      input_to_shortpath="${new_path}.exe"
36204    elif test -f "${new_path}.cmd"; then
36205      input_to_shortpath="${new_path}.cmd"
36206    else
36207      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
36208$as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
36209      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36210$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36211      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36212    fi
36213  else
36214    input_to_shortpath="$new_path"
36215  fi
36216
36217  # Call helper function which possibly converts this using DOS-style short mode.
36218  # If so, the updated path is stored in $new_path.
36219  new_path="$input_to_shortpath"
36220
36221  input_path="$input_to_shortpath"
36222  # Check if we need to convert this using DOS-style short mode. If the path
36223  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36224  # take no chances and rewrite it.
36225  # Note: m4 eats our [], so we need to use [ and ] instead.
36226  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36227  if test "x$has_forbidden_chars" != x; then
36228    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36229    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36230    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36231    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36232      # Going to short mode and back again did indeed matter. Since short mode is
36233      # case insensitive, let's make it lowercase to improve readability.
36234      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36235      # Now convert it back to Unix-stile (cygpath)
36236      input_path=`$CYGPATH -u "$shortmode_path"`
36237      new_path="$input_path"
36238    fi
36239  fi
36240
36241  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36242  if test "x$test_cygdrive_prefix" = x; then
36243    # As a simple fix, exclude /usr/bin since it's not a real path.
36244    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36245      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36246      # a path prefixed by /cygdrive for fixpath to work.
36247      new_path="$CYGWIN_ROOT_PATH$input_path"
36248    fi
36249  fi
36250
36251  # remove trailing .exe if any
36252  new_path="${new_path/%.exe/}"
36253
36254  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36255
36256  # First separate the path from the arguments. This will split at the first
36257  # space.
36258  complete="$MCS"
36259  path="${complete%% *}"
36260  tmp="$complete EOL"
36261  arguments="${tmp#* }"
36262
36263  # Input might be given as Windows format, start by converting to
36264  # unix format.
36265  new_path="$path"
36266
36267  windows_path="$new_path"
36268  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36269    unix_path=`$CYGPATH -u "$windows_path"`
36270    new_path="$unix_path"
36271  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36272    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36273    new_path="$unix_path"
36274  fi
36275
36276
36277  # Now try to locate executable using which
36278  new_path=`$WHICH "$new_path" 2> /dev/null`
36279
36280  if test "x$new_path" = x; then
36281    # Oops. Which didn't find the executable.
36282    # The splitting of arguments from the executable at a space might have been incorrect,
36283    # since paths with space are more likely in Windows. Give it another try with the whole
36284    # argument.
36285    path="$complete"
36286    arguments="EOL"
36287    new_path="$path"
36288
36289  windows_path="$new_path"
36290  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36291    unix_path=`$CYGPATH -u "$windows_path"`
36292    new_path="$unix_path"
36293  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36294    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36295    new_path="$unix_path"
36296  fi
36297
36298
36299    new_path=`$WHICH "$new_path" 2> /dev/null`
36300
36301    if test "x$new_path" = x; then
36302      # It's still not found. Now this is an unrecoverable error.
36303      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36304$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36305      has_space=`$ECHO "$complete" | $GREP " "`
36306      if test "x$has_space" != x; then
36307        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36308$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36309      fi
36310      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36311    fi
36312  fi
36313
36314  # Now new_path has a complete unix path to the binary
36315  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36316    # Keep paths in /bin as-is, but remove trailing .exe if any
36317    new_path="${new_path/%.exe/}"
36318    # Do not save /bin paths to all_fixpath_prefixes!
36319  else
36320    # Not in mixed or Windows style, start by that.
36321    new_path=`cmd //c echo $new_path`
36322
36323  input_path="$new_path"
36324  # Check if we need to convert this using DOS-style short mode. If the path
36325  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36326  # take no chances and rewrite it.
36327  # Note: m4 eats our [], so we need to use [ and ] instead.
36328  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36329  if test "x$has_forbidden_chars" != x; then
36330    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36331    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36332  fi
36333
36334    # Output is in $new_path
36335
36336  windows_path="$new_path"
36337  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36338    unix_path=`$CYGPATH -u "$windows_path"`
36339    new_path="$unix_path"
36340  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36341    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36342    new_path="$unix_path"
36343  fi
36344
36345    # remove trailing .exe if any
36346    new_path="${new_path/%.exe/}"
36347
36348    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36349    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36350  fi
36351
36352  else
36353    # We're on a posix platform. Hooray! :)
36354    # First separate the path from the arguments. This will split at the first
36355    # space.
36356    complete="$MCS"
36357    path="${complete%% *}"
36358    tmp="$complete EOL"
36359    arguments="${tmp#* }"
36360
36361    # Cannot rely on the command "which" here since it doesn't always work.
36362    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36363    if test -z "$is_absolute_path"; then
36364      # Path to executable is not absolute. Find it.
36365      IFS_save="$IFS"
36366      IFS=:
36367      for p in $PATH; do
36368        if test -f "$p/$path" && test -x "$p/$path"; then
36369          new_path="$p/$path"
36370          break
36371        fi
36372      done
36373      IFS="$IFS_save"
36374    else
36375      # This is an absolute path, we can use it without further modifications.
36376      new_path="$path"
36377    fi
36378
36379    if test "x$new_path" = x; then
36380      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36381$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36382      has_space=`$ECHO "$complete" | $GREP " "`
36383      if test "x$has_space" != x; then
36384        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36385$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36386      fi
36387      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36388    fi
36389  fi
36390
36391  # Now join together the path and the arguments once again
36392  if test "x$arguments" != xEOL; then
36393    new_complete="$new_path ${arguments% *}"
36394  else
36395    new_complete="$new_path"
36396  fi
36397
36398  if test "x$complete" != "x$new_complete"; then
36399    MCS="$new_complete"
36400    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
36401$as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
36402  fi
36403
36404  elif test "x$OPENJDK_TARGET_OS" != xwindows; then
36405    # FIXME: we should unify this with the solaris case above.
36406
36407
36408  # Publish this variable in the help.
36409
36410
36411  if test "x$STRIP" = x; then
36412    # The variable is not set by user, try to locate tool using the code snippet
36413    if test -n "$ac_tool_prefix"; then
36414  for ac_prog in strip
36415  do
36416    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36417set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36418{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36419$as_echo_n "checking for $ac_word... " >&6; }
36420if ${ac_cv_prog_STRIP+:} false; then :
36421  $as_echo_n "(cached) " >&6
36422else
36423  if test -n "$STRIP"; then
36424  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36425else
36426as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36427for as_dir in $PATH
36428do
36429  IFS=$as_save_IFS
36430  test -z "$as_dir" && as_dir=.
36431    for ac_exec_ext in '' $ac_executable_extensions; do
36432  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36433    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36434    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36435    break 2
36436  fi
36437done
36438  done
36439IFS=$as_save_IFS
36440
36441fi
36442fi
36443STRIP=$ac_cv_prog_STRIP
36444if test -n "$STRIP"; then
36445  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36446$as_echo "$STRIP" >&6; }
36447else
36448  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36449$as_echo "no" >&6; }
36450fi
36451
36452
36453    test -n "$STRIP" && break
36454  done
36455fi
36456if test -z "$STRIP"; then
36457  ac_ct_STRIP=$STRIP
36458  for ac_prog in strip
36459do
36460  # Extract the first word of "$ac_prog", so it can be a program name with args.
36461set dummy $ac_prog; ac_word=$2
36462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36463$as_echo_n "checking for $ac_word... " >&6; }
36464if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36465  $as_echo_n "(cached) " >&6
36466else
36467  if test -n "$ac_ct_STRIP"; then
36468  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36469else
36470as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36471for as_dir in $PATH
36472do
36473  IFS=$as_save_IFS
36474  test -z "$as_dir" && as_dir=.
36475    for ac_exec_ext in '' $ac_executable_extensions; do
36476  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36477    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36478    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36479    break 2
36480  fi
36481done
36482  done
36483IFS=$as_save_IFS
36484
36485fi
36486fi
36487ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36488if test -n "$ac_ct_STRIP"; then
36489  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36490$as_echo "$ac_ct_STRIP" >&6; }
36491else
36492  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36493$as_echo "no" >&6; }
36494fi
36495
36496
36497  test -n "$ac_ct_STRIP" && break
36498done
36499
36500  if test "x$ac_ct_STRIP" = x; then
36501    STRIP=""
36502  else
36503    case $cross_compiling:$ac_tool_warned in
36504yes:)
36505{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36506$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36507ac_tool_warned=yes ;;
36508esac
36509    STRIP=$ac_ct_STRIP
36510  fi
36511fi
36512
36513  else
36514    # The variable is set, but is it from the command line or the environment?
36515
36516    # Try to remove the string !STRIP! from our list.
36517    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
36518    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36519      # If it failed, the variable was not from the command line. Ignore it,
36520      # but warn the user (except for BASH, which is always set by the calling BASH).
36521      if test "xSTRIP" != xBASH; then
36522        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
36523$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
36524      fi
36525      # Try to locate tool using the code snippet
36526      if test -n "$ac_tool_prefix"; then
36527  for ac_prog in strip
36528  do
36529    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36530set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36531{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36532$as_echo_n "checking for $ac_word... " >&6; }
36533if ${ac_cv_prog_STRIP+:} false; then :
36534  $as_echo_n "(cached) " >&6
36535else
36536  if test -n "$STRIP"; then
36537  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36538else
36539as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36540for as_dir in $PATH
36541do
36542  IFS=$as_save_IFS
36543  test -z "$as_dir" && as_dir=.
36544    for ac_exec_ext in '' $ac_executable_extensions; do
36545  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36546    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36547    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36548    break 2
36549  fi
36550done
36551  done
36552IFS=$as_save_IFS
36553
36554fi
36555fi
36556STRIP=$ac_cv_prog_STRIP
36557if test -n "$STRIP"; then
36558  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36559$as_echo "$STRIP" >&6; }
36560else
36561  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36562$as_echo "no" >&6; }
36563fi
36564
36565
36566    test -n "$STRIP" && break
36567  done
36568fi
36569if test -z "$STRIP"; then
36570  ac_ct_STRIP=$STRIP
36571  for ac_prog in strip
36572do
36573  # Extract the first word of "$ac_prog", so it can be a program name with args.
36574set dummy $ac_prog; ac_word=$2
36575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36576$as_echo_n "checking for $ac_word... " >&6; }
36577if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36578  $as_echo_n "(cached) " >&6
36579else
36580  if test -n "$ac_ct_STRIP"; then
36581  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36582else
36583as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36584for as_dir in $PATH
36585do
36586  IFS=$as_save_IFS
36587  test -z "$as_dir" && as_dir=.
36588    for ac_exec_ext in '' $ac_executable_extensions; do
36589  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36590    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36591    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36592    break 2
36593  fi
36594done
36595  done
36596IFS=$as_save_IFS
36597
36598fi
36599fi
36600ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36601if test -n "$ac_ct_STRIP"; then
36602  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36603$as_echo "$ac_ct_STRIP" >&6; }
36604else
36605  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36606$as_echo "no" >&6; }
36607fi
36608
36609
36610  test -n "$ac_ct_STRIP" && break
36611done
36612
36613  if test "x$ac_ct_STRIP" = x; then
36614    STRIP=""
36615  else
36616    case $cross_compiling:$ac_tool_warned in
36617yes:)
36618{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36619$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36620ac_tool_warned=yes ;;
36621esac
36622    STRIP=$ac_ct_STRIP
36623  fi
36624fi
36625
36626    else
36627      # If it succeeded, then it was overridden by the user. We will use it
36628      # for the tool.
36629
36630      # First remove it from the list of overridden variables, so we can test
36631      # for unknown variables in the end.
36632      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36633
36634      # Check if the provided tool contains a complete path.
36635      tool_specified="$STRIP"
36636      tool_basename="${tool_specified##*/}"
36637      if test "x$tool_basename" = "x$tool_specified"; then
36638        # A command without a complete path is provided, search $PATH.
36639        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
36640$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
36641        # Extract the first word of "$tool_basename", so it can be a program name with args.
36642set dummy $tool_basename; ac_word=$2
36643{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36644$as_echo_n "checking for $ac_word... " >&6; }
36645if ${ac_cv_path_STRIP+:} false; then :
36646  $as_echo_n "(cached) " >&6
36647else
36648  case $STRIP in
36649  [\\/]* | ?:[\\/]*)
36650  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
36651  ;;
36652  *)
36653  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36654for as_dir in $PATH
36655do
36656  IFS=$as_save_IFS
36657  test -z "$as_dir" && as_dir=.
36658    for ac_exec_ext in '' $ac_executable_extensions; do
36659  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36660    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
36661    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36662    break 2
36663  fi
36664done
36665  done
36666IFS=$as_save_IFS
36667
36668  ;;
36669esac
36670fi
36671STRIP=$ac_cv_path_STRIP
36672if test -n "$STRIP"; then
36673  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36674$as_echo "$STRIP" >&6; }
36675else
36676  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36677$as_echo "no" >&6; }
36678fi
36679
36680
36681        if test "x$STRIP" = x; then
36682          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36683        fi
36684      else
36685        # Otherwise we believe it is a complete path. Use it as it is.
36686        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
36687$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
36688        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
36689$as_echo_n "checking for STRIP... " >&6; }
36690        if test ! -x "$tool_specified"; then
36691          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36692$as_echo "not found" >&6; }
36693          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
36694        fi
36695        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36696$as_echo "$tool_specified" >&6; }
36697      fi
36698    fi
36699  fi
36700
36701
36702
36703  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36704
36705  # First separate the path from the arguments. This will split at the first
36706  # space.
36707  complete="$STRIP"
36708  path="${complete%% *}"
36709  tmp="$complete EOL"
36710  arguments="${tmp#* }"
36711
36712  # Input might be given as Windows format, start by converting to
36713  # unix format.
36714  new_path=`$CYGPATH -u "$path"`
36715
36716  # Now try to locate executable using which
36717  new_path=`$WHICH "$new_path" 2> /dev/null`
36718  # bat and cmd files are not always considered executable in cygwin causing which
36719  # to not find them
36720  if test "x$new_path" = x \
36721      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36722      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36723    new_path=`$CYGPATH -u "$path"`
36724  fi
36725  if test "x$new_path" = x; then
36726    # Oops. Which didn't find the executable.
36727    # The splitting of arguments from the executable at a space might have been incorrect,
36728    # since paths with space are more likely in Windows. Give it another try with the whole
36729    # argument.
36730    path="$complete"
36731    arguments="EOL"
36732    new_path=`$CYGPATH -u "$path"`
36733    new_path=`$WHICH "$new_path" 2> /dev/null`
36734    # bat and cmd files are not always considered executable in cygwin causing which
36735    # to not find them
36736    if test "x$new_path" = x \
36737        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36738        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36739      new_path=`$CYGPATH -u "$path"`
36740    fi
36741    if test "x$new_path" = x; then
36742      # It's still not found. Now this is an unrecoverable error.
36743      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36744$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36745      has_space=`$ECHO "$complete" | $GREP " "`
36746      if test "x$has_space" != x; then
36747        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36748$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36749      fi
36750      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36751    fi
36752  fi
36753
36754  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36755  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36756  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36757  # "foo.exe" is OK but "foo" is an error.
36758  #
36759  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36760  # It is also a way to make sure we got the proper file name for the real test later on.
36761  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36762  if test "x$test_shortpath" = x; then
36763    # Short path failed, file does not exist as specified.
36764    # Try adding .exe or .cmd
36765    if test -f "${new_path}.exe"; then
36766      input_to_shortpath="${new_path}.exe"
36767    elif test -f "${new_path}.cmd"; then
36768      input_to_shortpath="${new_path}.cmd"
36769    else
36770      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
36771$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
36772      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36773$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36774      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36775    fi
36776  else
36777    input_to_shortpath="$new_path"
36778  fi
36779
36780  # Call helper function which possibly converts this using DOS-style short mode.
36781  # If so, the updated path is stored in $new_path.
36782  new_path="$input_to_shortpath"
36783
36784  input_path="$input_to_shortpath"
36785  # Check if we need to convert this using DOS-style short mode. If the path
36786  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36787  # take no chances and rewrite it.
36788  # Note: m4 eats our [], so we need to use [ and ] instead.
36789  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36790  if test "x$has_forbidden_chars" != x; then
36791    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36792    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36793    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36794    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36795      # Going to short mode and back again did indeed matter. Since short mode is
36796      # case insensitive, let's make it lowercase to improve readability.
36797      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36798      # Now convert it back to Unix-stile (cygpath)
36799      input_path=`$CYGPATH -u "$shortmode_path"`
36800      new_path="$input_path"
36801    fi
36802  fi
36803
36804  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36805  if test "x$test_cygdrive_prefix" = x; then
36806    # As a simple fix, exclude /usr/bin since it's not a real path.
36807    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36808      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36809      # a path prefixed by /cygdrive for fixpath to work.
36810      new_path="$CYGWIN_ROOT_PATH$input_path"
36811    fi
36812  fi
36813
36814  # remove trailing .exe if any
36815  new_path="${new_path/%.exe/}"
36816
36817  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36818
36819  # First separate the path from the arguments. This will split at the first
36820  # space.
36821  complete="$STRIP"
36822  path="${complete%% *}"
36823  tmp="$complete EOL"
36824  arguments="${tmp#* }"
36825
36826  # Input might be given as Windows format, start by converting to
36827  # unix format.
36828  new_path="$path"
36829
36830  windows_path="$new_path"
36831  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36832    unix_path=`$CYGPATH -u "$windows_path"`
36833    new_path="$unix_path"
36834  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36835    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36836    new_path="$unix_path"
36837  fi
36838
36839
36840  # Now try to locate executable using which
36841  new_path=`$WHICH "$new_path" 2> /dev/null`
36842
36843  if test "x$new_path" = x; then
36844    # Oops. Which didn't find the executable.
36845    # The splitting of arguments from the executable at a space might have been incorrect,
36846    # since paths with space are more likely in Windows. Give it another try with the whole
36847    # argument.
36848    path="$complete"
36849    arguments="EOL"
36850    new_path="$path"
36851
36852  windows_path="$new_path"
36853  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36854    unix_path=`$CYGPATH -u "$windows_path"`
36855    new_path="$unix_path"
36856  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36857    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36858    new_path="$unix_path"
36859  fi
36860
36861
36862    new_path=`$WHICH "$new_path" 2> /dev/null`
36863
36864    if test "x$new_path" = x; then
36865      # It's still not found. Now this is an unrecoverable error.
36866      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36867$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36868      has_space=`$ECHO "$complete" | $GREP " "`
36869      if test "x$has_space" != x; then
36870        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36871$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36872      fi
36873      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36874    fi
36875  fi
36876
36877  # Now new_path has a complete unix path to the binary
36878  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36879    # Keep paths in /bin as-is, but remove trailing .exe if any
36880    new_path="${new_path/%.exe/}"
36881    # Do not save /bin paths to all_fixpath_prefixes!
36882  else
36883    # Not in mixed or Windows style, start by that.
36884    new_path=`cmd //c echo $new_path`
36885
36886  input_path="$new_path"
36887  # Check if we need to convert this using DOS-style short mode. If the path
36888  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36889  # take no chances and rewrite it.
36890  # Note: m4 eats our [], so we need to use [ and ] instead.
36891  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36892  if test "x$has_forbidden_chars" != x; then
36893    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36894    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36895  fi
36896
36897    # Output is in $new_path
36898
36899  windows_path="$new_path"
36900  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36901    unix_path=`$CYGPATH -u "$windows_path"`
36902    new_path="$unix_path"
36903  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36904    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36905    new_path="$unix_path"
36906  fi
36907
36908    # remove trailing .exe if any
36909    new_path="${new_path/%.exe/}"
36910
36911    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36912    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36913  fi
36914
36915  else
36916    # We're on a posix platform. Hooray! :)
36917    # First separate the path from the arguments. This will split at the first
36918    # space.
36919    complete="$STRIP"
36920    path="${complete%% *}"
36921    tmp="$complete EOL"
36922    arguments="${tmp#* }"
36923
36924    # Cannot rely on the command "which" here since it doesn't always work.
36925    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36926    if test -z "$is_absolute_path"; then
36927      # Path to executable is not absolute. Find it.
36928      IFS_save="$IFS"
36929      IFS=:
36930      for p in $PATH; do
36931        if test -f "$p/$path" && test -x "$p/$path"; then
36932          new_path="$p/$path"
36933          break
36934        fi
36935      done
36936      IFS="$IFS_save"
36937    else
36938      # This is an absolute path, we can use it without further modifications.
36939      new_path="$path"
36940    fi
36941
36942    if test "x$new_path" = x; then
36943      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36944$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36945      has_space=`$ECHO "$complete" | $GREP " "`
36946      if test "x$has_space" != x; then
36947        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36948$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36949      fi
36950      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36951    fi
36952  fi
36953
36954  # Now join together the path and the arguments once again
36955  if test "x$arguments" != xEOL; then
36956    new_complete="$new_path ${arguments% *}"
36957  else
36958    new_complete="$new_path"
36959  fi
36960
36961  if test "x$complete" != "x$new_complete"; then
36962    STRIP="$new_complete"
36963    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
36964$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
36965  fi
36966
36967
36968
36969  # Publish this variable in the help.
36970
36971
36972  if test "x$NM" = x; then
36973    # The variable is not set by user, try to locate tool using the code snippet
36974    if test -n "$ac_tool_prefix"; then
36975  for ac_prog in nm
36976  do
36977    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36978set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36979{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36980$as_echo_n "checking for $ac_word... " >&6; }
36981if ${ac_cv_prog_NM+:} false; then :
36982  $as_echo_n "(cached) " >&6
36983else
36984  if test -n "$NM"; then
36985  ac_cv_prog_NM="$NM" # Let the user override the test.
36986else
36987as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36988for as_dir in $PATH
36989do
36990  IFS=$as_save_IFS
36991  test -z "$as_dir" && as_dir=.
36992    for ac_exec_ext in '' $ac_executable_extensions; do
36993  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36994    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
36995    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36996    break 2
36997  fi
36998done
36999  done
37000IFS=$as_save_IFS
37001
37002fi
37003fi
37004NM=$ac_cv_prog_NM
37005if test -n "$NM"; then
37006  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37007$as_echo "$NM" >&6; }
37008else
37009  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37010$as_echo "no" >&6; }
37011fi
37012
37013
37014    test -n "$NM" && break
37015  done
37016fi
37017if test -z "$NM"; then
37018  ac_ct_NM=$NM
37019  for ac_prog in nm
37020do
37021  # Extract the first word of "$ac_prog", so it can be a program name with args.
37022set dummy $ac_prog; ac_word=$2
37023{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37024$as_echo_n "checking for $ac_word... " >&6; }
37025if ${ac_cv_prog_ac_ct_NM+:} false; then :
37026  $as_echo_n "(cached) " >&6
37027else
37028  if test -n "$ac_ct_NM"; then
37029  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37030else
37031as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37032for as_dir in $PATH
37033do
37034  IFS=$as_save_IFS
37035  test -z "$as_dir" && as_dir=.
37036    for ac_exec_ext in '' $ac_executable_extensions; do
37037  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37038    ac_cv_prog_ac_ct_NM="$ac_prog"
37039    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37040    break 2
37041  fi
37042done
37043  done
37044IFS=$as_save_IFS
37045
37046fi
37047fi
37048ac_ct_NM=$ac_cv_prog_ac_ct_NM
37049if test -n "$ac_ct_NM"; then
37050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37051$as_echo "$ac_ct_NM" >&6; }
37052else
37053  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37054$as_echo "no" >&6; }
37055fi
37056
37057
37058  test -n "$ac_ct_NM" && break
37059done
37060
37061  if test "x$ac_ct_NM" = x; then
37062    NM=""
37063  else
37064    case $cross_compiling:$ac_tool_warned in
37065yes:)
37066{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37067$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37068ac_tool_warned=yes ;;
37069esac
37070    NM=$ac_ct_NM
37071  fi
37072fi
37073
37074  else
37075    # The variable is set, but is it from the command line or the environment?
37076
37077    # Try to remove the string !NM! from our list.
37078    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
37079    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37080      # If it failed, the variable was not from the command line. Ignore it,
37081      # but warn the user (except for BASH, which is always set by the calling BASH).
37082      if test "xNM" != xBASH; then
37083        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
37084$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
37085      fi
37086      # Try to locate tool using the code snippet
37087      if test -n "$ac_tool_prefix"; then
37088  for ac_prog in nm
37089  do
37090    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37091set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37092{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37093$as_echo_n "checking for $ac_word... " >&6; }
37094if ${ac_cv_prog_NM+:} false; then :
37095  $as_echo_n "(cached) " >&6
37096else
37097  if test -n "$NM"; then
37098  ac_cv_prog_NM="$NM" # Let the user override the test.
37099else
37100as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37101for as_dir in $PATH
37102do
37103  IFS=$as_save_IFS
37104  test -z "$as_dir" && as_dir=.
37105    for ac_exec_ext in '' $ac_executable_extensions; do
37106  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37107    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37108    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37109    break 2
37110  fi
37111done
37112  done
37113IFS=$as_save_IFS
37114
37115fi
37116fi
37117NM=$ac_cv_prog_NM
37118if test -n "$NM"; then
37119  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37120$as_echo "$NM" >&6; }
37121else
37122  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37123$as_echo "no" >&6; }
37124fi
37125
37126
37127    test -n "$NM" && break
37128  done
37129fi
37130if test -z "$NM"; then
37131  ac_ct_NM=$NM
37132  for ac_prog in nm
37133do
37134  # Extract the first word of "$ac_prog", so it can be a program name with args.
37135set dummy $ac_prog; ac_word=$2
37136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37137$as_echo_n "checking for $ac_word... " >&6; }
37138if ${ac_cv_prog_ac_ct_NM+:} false; then :
37139  $as_echo_n "(cached) " >&6
37140else
37141  if test -n "$ac_ct_NM"; then
37142  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37143else
37144as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37145for as_dir in $PATH
37146do
37147  IFS=$as_save_IFS
37148  test -z "$as_dir" && as_dir=.
37149    for ac_exec_ext in '' $ac_executable_extensions; do
37150  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37151    ac_cv_prog_ac_ct_NM="$ac_prog"
37152    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37153    break 2
37154  fi
37155done
37156  done
37157IFS=$as_save_IFS
37158
37159fi
37160fi
37161ac_ct_NM=$ac_cv_prog_ac_ct_NM
37162if test -n "$ac_ct_NM"; then
37163  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37164$as_echo "$ac_ct_NM" >&6; }
37165else
37166  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37167$as_echo "no" >&6; }
37168fi
37169
37170
37171  test -n "$ac_ct_NM" && break
37172done
37173
37174  if test "x$ac_ct_NM" = x; then
37175    NM=""
37176  else
37177    case $cross_compiling:$ac_tool_warned in
37178yes:)
37179{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37180$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37181ac_tool_warned=yes ;;
37182esac
37183    NM=$ac_ct_NM
37184  fi
37185fi
37186
37187    else
37188      # If it succeeded, then it was overridden by the user. We will use it
37189      # for the tool.
37190
37191      # First remove it from the list of overridden variables, so we can test
37192      # for unknown variables in the end.
37193      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37194
37195      # Check if the provided tool contains a complete path.
37196      tool_specified="$NM"
37197      tool_basename="${tool_specified##*/}"
37198      if test "x$tool_basename" = "x$tool_specified"; then
37199        # A command without a complete path is provided, search $PATH.
37200        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
37201$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
37202        # Extract the first word of "$tool_basename", so it can be a program name with args.
37203set dummy $tool_basename; ac_word=$2
37204{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37205$as_echo_n "checking for $ac_word... " >&6; }
37206if ${ac_cv_path_NM+:} false; then :
37207  $as_echo_n "(cached) " >&6
37208else
37209  case $NM in
37210  [\\/]* | ?:[\\/]*)
37211  ac_cv_path_NM="$NM" # Let the user override the test with a path.
37212  ;;
37213  *)
37214  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37215for as_dir in $PATH
37216do
37217  IFS=$as_save_IFS
37218  test -z "$as_dir" && as_dir=.
37219    for ac_exec_ext in '' $ac_executable_extensions; do
37220  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37221    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
37222    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37223    break 2
37224  fi
37225done
37226  done
37227IFS=$as_save_IFS
37228
37229  ;;
37230esac
37231fi
37232NM=$ac_cv_path_NM
37233if test -n "$NM"; then
37234  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37235$as_echo "$NM" >&6; }
37236else
37237  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37238$as_echo "no" >&6; }
37239fi
37240
37241
37242        if test "x$NM" = x; then
37243          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37244        fi
37245      else
37246        # Otherwise we believe it is a complete path. Use it as it is.
37247        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
37248$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
37249        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
37250$as_echo_n "checking for NM... " >&6; }
37251        if test ! -x "$tool_specified"; then
37252          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37253$as_echo "not found" >&6; }
37254          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
37255        fi
37256        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37257$as_echo "$tool_specified" >&6; }
37258      fi
37259    fi
37260  fi
37261
37262
37263
37264  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37265
37266  # First separate the path from the arguments. This will split at the first
37267  # space.
37268  complete="$NM"
37269  path="${complete%% *}"
37270  tmp="$complete EOL"
37271  arguments="${tmp#* }"
37272
37273  # Input might be given as Windows format, start by converting to
37274  # unix format.
37275  new_path=`$CYGPATH -u "$path"`
37276
37277  # Now try to locate executable using which
37278  new_path=`$WHICH "$new_path" 2> /dev/null`
37279  # bat and cmd files are not always considered executable in cygwin causing which
37280  # to not find them
37281  if test "x$new_path" = x \
37282      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37283      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37284    new_path=`$CYGPATH -u "$path"`
37285  fi
37286  if test "x$new_path" = x; then
37287    # Oops. Which didn't find the executable.
37288    # The splitting of arguments from the executable at a space might have been incorrect,
37289    # since paths with space are more likely in Windows. Give it another try with the whole
37290    # argument.
37291    path="$complete"
37292    arguments="EOL"
37293    new_path=`$CYGPATH -u "$path"`
37294    new_path=`$WHICH "$new_path" 2> /dev/null`
37295    # bat and cmd files are not always considered executable in cygwin causing which
37296    # to not find them
37297    if test "x$new_path" = x \
37298        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37299        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37300      new_path=`$CYGPATH -u "$path"`
37301    fi
37302    if test "x$new_path" = x; then
37303      # It's still not found. Now this is an unrecoverable error.
37304      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37305$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37306      has_space=`$ECHO "$complete" | $GREP " "`
37307      if test "x$has_space" != x; then
37308        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37309$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37310      fi
37311      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37312    fi
37313  fi
37314
37315  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37316  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37317  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37318  # "foo.exe" is OK but "foo" is an error.
37319  #
37320  # This test is therefore slightly more accurate than "test -f" to check for file presence.
37321  # It is also a way to make sure we got the proper file name for the real test later on.
37322  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37323  if test "x$test_shortpath" = x; then
37324    # Short path failed, file does not exist as specified.
37325    # Try adding .exe or .cmd
37326    if test -f "${new_path}.exe"; then
37327      input_to_shortpath="${new_path}.exe"
37328    elif test -f "${new_path}.cmd"; then
37329      input_to_shortpath="${new_path}.cmd"
37330    else
37331      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
37332$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
37333      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37334$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37335      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37336    fi
37337  else
37338    input_to_shortpath="$new_path"
37339  fi
37340
37341  # Call helper function which possibly converts this using DOS-style short mode.
37342  # If so, the updated path is stored in $new_path.
37343  new_path="$input_to_shortpath"
37344
37345  input_path="$input_to_shortpath"
37346  # Check if we need to convert this using DOS-style short mode. If the path
37347  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37348  # take no chances and rewrite it.
37349  # Note: m4 eats our [], so we need to use [ and ] instead.
37350  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37351  if test "x$has_forbidden_chars" != x; then
37352    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37353    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37354    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37355    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37356      # Going to short mode and back again did indeed matter. Since short mode is
37357      # case insensitive, let's make it lowercase to improve readability.
37358      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37359      # Now convert it back to Unix-stile (cygpath)
37360      input_path=`$CYGPATH -u "$shortmode_path"`
37361      new_path="$input_path"
37362    fi
37363  fi
37364
37365  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37366  if test "x$test_cygdrive_prefix" = x; then
37367    # As a simple fix, exclude /usr/bin since it's not a real path.
37368    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37369      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37370      # a path prefixed by /cygdrive for fixpath to work.
37371      new_path="$CYGWIN_ROOT_PATH$input_path"
37372    fi
37373  fi
37374
37375  # remove trailing .exe if any
37376  new_path="${new_path/%.exe/}"
37377
37378  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37379
37380  # First separate the path from the arguments. This will split at the first
37381  # space.
37382  complete="$NM"
37383  path="${complete%% *}"
37384  tmp="$complete EOL"
37385  arguments="${tmp#* }"
37386
37387  # Input might be given as Windows format, start by converting to
37388  # unix format.
37389  new_path="$path"
37390
37391  windows_path="$new_path"
37392  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37393    unix_path=`$CYGPATH -u "$windows_path"`
37394    new_path="$unix_path"
37395  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37396    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37397    new_path="$unix_path"
37398  fi
37399
37400
37401  # Now try to locate executable using which
37402  new_path=`$WHICH "$new_path" 2> /dev/null`
37403
37404  if test "x$new_path" = x; then
37405    # Oops. Which didn't find the executable.
37406    # The splitting of arguments from the executable at a space might have been incorrect,
37407    # since paths with space are more likely in Windows. Give it another try with the whole
37408    # argument.
37409    path="$complete"
37410    arguments="EOL"
37411    new_path="$path"
37412
37413  windows_path="$new_path"
37414  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37415    unix_path=`$CYGPATH -u "$windows_path"`
37416    new_path="$unix_path"
37417  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37418    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37419    new_path="$unix_path"
37420  fi
37421
37422
37423    new_path=`$WHICH "$new_path" 2> /dev/null`
37424
37425    if test "x$new_path" = x; then
37426      # It's still not found. Now this is an unrecoverable error.
37427      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37428$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37429      has_space=`$ECHO "$complete" | $GREP " "`
37430      if test "x$has_space" != x; then
37431        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37432$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37433      fi
37434      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37435    fi
37436  fi
37437
37438  # Now new_path has a complete unix path to the binary
37439  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37440    # Keep paths in /bin as-is, but remove trailing .exe if any
37441    new_path="${new_path/%.exe/}"
37442    # Do not save /bin paths to all_fixpath_prefixes!
37443  else
37444    # Not in mixed or Windows style, start by that.
37445    new_path=`cmd //c echo $new_path`
37446
37447  input_path="$new_path"
37448  # Check if we need to convert this using DOS-style short mode. If the path
37449  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37450  # take no chances and rewrite it.
37451  # Note: m4 eats our [], so we need to use [ and ] instead.
37452  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37453  if test "x$has_forbidden_chars" != x; then
37454    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37455    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37456  fi
37457
37458    # Output is in $new_path
37459
37460  windows_path="$new_path"
37461  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37462    unix_path=`$CYGPATH -u "$windows_path"`
37463    new_path="$unix_path"
37464  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37465    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37466    new_path="$unix_path"
37467  fi
37468
37469    # remove trailing .exe if any
37470    new_path="${new_path/%.exe/}"
37471
37472    # Save the first 10 bytes of this path to the storage, so fixpath can work.
37473    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37474  fi
37475
37476  else
37477    # We're on a posix platform. Hooray! :)
37478    # First separate the path from the arguments. This will split at the first
37479    # space.
37480    complete="$NM"
37481    path="${complete%% *}"
37482    tmp="$complete EOL"
37483    arguments="${tmp#* }"
37484
37485    # Cannot rely on the command "which" here since it doesn't always work.
37486    is_absolute_path=`$ECHO "$path" | $GREP ^/`
37487    if test -z "$is_absolute_path"; then
37488      # Path to executable is not absolute. Find it.
37489      IFS_save="$IFS"
37490      IFS=:
37491      for p in $PATH; do
37492        if test -f "$p/$path" && test -x "$p/$path"; then
37493          new_path="$p/$path"
37494          break
37495        fi
37496      done
37497      IFS="$IFS_save"
37498    else
37499      # This is an absolute path, we can use it without further modifications.
37500      new_path="$path"
37501    fi
37502
37503    if test "x$new_path" = x; then
37504      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37505$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37506      has_space=`$ECHO "$complete" | $GREP " "`
37507      if test "x$has_space" != x; then
37508        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37509$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37510      fi
37511      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37512    fi
37513  fi
37514
37515  # Now join together the path and the arguments once again
37516  if test "x$arguments" != xEOL; then
37517    new_complete="$new_path ${arguments% *}"
37518  else
37519    new_complete="$new_path"
37520  fi
37521
37522  if test "x$complete" != "x$new_complete"; then
37523    NM="$new_complete"
37524    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
37525$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
37526  fi
37527
37528    GNM="$NM"
37529
37530  fi
37531
37532  # objcopy is used for moving debug symbols to separate files when
37533  # full debug symbols are enabled.
37534  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
37535
37536
37537  # Publish this variable in the help.
37538
37539
37540  if test "x$OBJCOPY" = x; then
37541    # The variable is not set by user, try to locate tool using the code snippet
37542    if test -n "$ac_tool_prefix"; then
37543  for ac_prog in gobjcopy objcopy
37544  do
37545    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37546set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37547{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37548$as_echo_n "checking for $ac_word... " >&6; }
37549if ${ac_cv_prog_OBJCOPY+:} false; then :
37550  $as_echo_n "(cached) " >&6
37551else
37552  if test -n "$OBJCOPY"; then
37553  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37554else
37555as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37556for as_dir in $PATH
37557do
37558  IFS=$as_save_IFS
37559  test -z "$as_dir" && as_dir=.
37560    for ac_exec_ext in '' $ac_executable_extensions; do
37561  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37562    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37563    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37564    break 2
37565  fi
37566done
37567  done
37568IFS=$as_save_IFS
37569
37570fi
37571fi
37572OBJCOPY=$ac_cv_prog_OBJCOPY
37573if test -n "$OBJCOPY"; then
37574  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37575$as_echo "$OBJCOPY" >&6; }
37576else
37577  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37578$as_echo "no" >&6; }
37579fi
37580
37581
37582    test -n "$OBJCOPY" && break
37583  done
37584fi
37585if test -z "$OBJCOPY"; then
37586  ac_ct_OBJCOPY=$OBJCOPY
37587  for ac_prog in gobjcopy objcopy
37588do
37589  # Extract the first word of "$ac_prog", so it can be a program name with args.
37590set dummy $ac_prog; ac_word=$2
37591{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37592$as_echo_n "checking for $ac_word... " >&6; }
37593if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37594  $as_echo_n "(cached) " >&6
37595else
37596  if test -n "$ac_ct_OBJCOPY"; then
37597  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37598else
37599as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37600for as_dir in $PATH
37601do
37602  IFS=$as_save_IFS
37603  test -z "$as_dir" && as_dir=.
37604    for ac_exec_ext in '' $ac_executable_extensions; do
37605  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37606    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37607    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37608    break 2
37609  fi
37610done
37611  done
37612IFS=$as_save_IFS
37613
37614fi
37615fi
37616ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37617if test -n "$ac_ct_OBJCOPY"; then
37618  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37619$as_echo "$ac_ct_OBJCOPY" >&6; }
37620else
37621  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37622$as_echo "no" >&6; }
37623fi
37624
37625
37626  test -n "$ac_ct_OBJCOPY" && break
37627done
37628
37629  if test "x$ac_ct_OBJCOPY" = x; then
37630    OBJCOPY=""
37631  else
37632    case $cross_compiling:$ac_tool_warned in
37633yes:)
37634{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37635$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37636ac_tool_warned=yes ;;
37637esac
37638    OBJCOPY=$ac_ct_OBJCOPY
37639  fi
37640fi
37641
37642  else
37643    # The variable is set, but is it from the command line or the environment?
37644
37645    # Try to remove the string !OBJCOPY! from our list.
37646    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
37647    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37648      # If it failed, the variable was not from the command line. Ignore it,
37649      # but warn the user (except for BASH, which is always set by the calling BASH).
37650      if test "xOBJCOPY" != xBASH; then
37651        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
37652$as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
37653      fi
37654      # Try to locate tool using the code snippet
37655      if test -n "$ac_tool_prefix"; then
37656  for ac_prog in gobjcopy objcopy
37657  do
37658    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37659set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37660{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37661$as_echo_n "checking for $ac_word... " >&6; }
37662if ${ac_cv_prog_OBJCOPY+:} false; then :
37663  $as_echo_n "(cached) " >&6
37664else
37665  if test -n "$OBJCOPY"; then
37666  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37667else
37668as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37669for as_dir in $PATH
37670do
37671  IFS=$as_save_IFS
37672  test -z "$as_dir" && as_dir=.
37673    for ac_exec_ext in '' $ac_executable_extensions; do
37674  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37675    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37676    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37677    break 2
37678  fi
37679done
37680  done
37681IFS=$as_save_IFS
37682
37683fi
37684fi
37685OBJCOPY=$ac_cv_prog_OBJCOPY
37686if test -n "$OBJCOPY"; then
37687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37688$as_echo "$OBJCOPY" >&6; }
37689else
37690  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37691$as_echo "no" >&6; }
37692fi
37693
37694
37695    test -n "$OBJCOPY" && break
37696  done
37697fi
37698if test -z "$OBJCOPY"; then
37699  ac_ct_OBJCOPY=$OBJCOPY
37700  for ac_prog in gobjcopy objcopy
37701do
37702  # Extract the first word of "$ac_prog", so it can be a program name with args.
37703set dummy $ac_prog; ac_word=$2
37704{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37705$as_echo_n "checking for $ac_word... " >&6; }
37706if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37707  $as_echo_n "(cached) " >&6
37708else
37709  if test -n "$ac_ct_OBJCOPY"; then
37710  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37711else
37712as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37713for as_dir in $PATH
37714do
37715  IFS=$as_save_IFS
37716  test -z "$as_dir" && as_dir=.
37717    for ac_exec_ext in '' $ac_executable_extensions; do
37718  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37719    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37720    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37721    break 2
37722  fi
37723done
37724  done
37725IFS=$as_save_IFS
37726
37727fi
37728fi
37729ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37730if test -n "$ac_ct_OBJCOPY"; then
37731  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37732$as_echo "$ac_ct_OBJCOPY" >&6; }
37733else
37734  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37735$as_echo "no" >&6; }
37736fi
37737
37738
37739  test -n "$ac_ct_OBJCOPY" && break
37740done
37741
37742  if test "x$ac_ct_OBJCOPY" = x; then
37743    OBJCOPY=""
37744  else
37745    case $cross_compiling:$ac_tool_warned in
37746yes:)
37747{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37748$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37749ac_tool_warned=yes ;;
37750esac
37751    OBJCOPY=$ac_ct_OBJCOPY
37752  fi
37753fi
37754
37755    else
37756      # If it succeeded, then it was overridden by the user. We will use it
37757      # for the tool.
37758
37759      # First remove it from the list of overridden variables, so we can test
37760      # for unknown variables in the end.
37761      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37762
37763      # Check if the provided tool contains a complete path.
37764      tool_specified="$OBJCOPY"
37765      tool_basename="${tool_specified##*/}"
37766      if test "x$tool_basename" = "x$tool_specified"; then
37767        # A command without a complete path is provided, search $PATH.
37768        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
37769$as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
37770        # Extract the first word of "$tool_basename", so it can be a program name with args.
37771set dummy $tool_basename; ac_word=$2
37772{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37773$as_echo_n "checking for $ac_word... " >&6; }
37774if ${ac_cv_path_OBJCOPY+:} false; then :
37775  $as_echo_n "(cached) " >&6
37776else
37777  case $OBJCOPY in
37778  [\\/]* | ?:[\\/]*)
37779  ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
37780  ;;
37781  *)
37782  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37783for as_dir in $PATH
37784do
37785  IFS=$as_save_IFS
37786  test -z "$as_dir" && as_dir=.
37787    for ac_exec_ext in '' $ac_executable_extensions; do
37788  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37789    ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
37790    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37791    break 2
37792  fi
37793done
37794  done
37795IFS=$as_save_IFS
37796
37797  ;;
37798esac
37799fi
37800OBJCOPY=$ac_cv_path_OBJCOPY
37801if test -n "$OBJCOPY"; then
37802  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37803$as_echo "$OBJCOPY" >&6; }
37804else
37805  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37806$as_echo "no" >&6; }
37807fi
37808
37809
37810        if test "x$OBJCOPY" = x; then
37811          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37812        fi
37813      else
37814        # Otherwise we believe it is a complete path. Use it as it is.
37815        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
37816$as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
37817        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
37818$as_echo_n "checking for OBJCOPY... " >&6; }
37819        if test ! -x "$tool_specified"; then
37820          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37821$as_echo "not found" >&6; }
37822          as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
37823        fi
37824        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37825$as_echo "$tool_specified" >&6; }
37826      fi
37827    fi
37828  fi
37829
37830
37831    # Only call fixup if objcopy was found.
37832    if test -n "$OBJCOPY"; then
37833
37834  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37835
37836  # First separate the path from the arguments. This will split at the first
37837  # space.
37838  complete="$OBJCOPY"
37839  path="${complete%% *}"
37840  tmp="$complete EOL"
37841  arguments="${tmp#* }"
37842
37843  # Input might be given as Windows format, start by converting to
37844  # unix format.
37845  new_path=`$CYGPATH -u "$path"`
37846
37847  # Now try to locate executable using which
37848  new_path=`$WHICH "$new_path" 2> /dev/null`
37849  # bat and cmd files are not always considered executable in cygwin causing which
37850  # to not find them
37851  if test "x$new_path" = x \
37852      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37853      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37854    new_path=`$CYGPATH -u "$path"`
37855  fi
37856  if test "x$new_path" = x; then
37857    # Oops. Which didn't find the executable.
37858    # The splitting of arguments from the executable at a space might have been incorrect,
37859    # since paths with space are more likely in Windows. Give it another try with the whole
37860    # argument.
37861    path="$complete"
37862    arguments="EOL"
37863    new_path=`$CYGPATH -u "$path"`
37864    new_path=`$WHICH "$new_path" 2> /dev/null`
37865    # bat and cmd files are not always considered executable in cygwin causing which
37866    # to not find them
37867    if test "x$new_path" = x \
37868        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37869        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37870      new_path=`$CYGPATH -u "$path"`
37871    fi
37872    if test "x$new_path" = x; then
37873      # It's still not found. Now this is an unrecoverable error.
37874      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37875$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37876      has_space=`$ECHO "$complete" | $GREP " "`
37877      if test "x$has_space" != x; then
37878        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37879$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37880      fi
37881      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37882    fi
37883  fi
37884
37885  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37886  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37887  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37888  # "foo.exe" is OK but "foo" is an error.
37889  #
37890  # This test is therefore slightly more accurate than "test -f" to check for file presence.
37891  # It is also a way to make sure we got the proper file name for the real test later on.
37892  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37893  if test "x$test_shortpath" = x; then
37894    # Short path failed, file does not exist as specified.
37895    # Try adding .exe or .cmd
37896    if test -f "${new_path}.exe"; then
37897      input_to_shortpath="${new_path}.exe"
37898    elif test -f "${new_path}.cmd"; then
37899      input_to_shortpath="${new_path}.cmd"
37900    else
37901      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
37902$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
37903      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37904$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37905      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37906    fi
37907  else
37908    input_to_shortpath="$new_path"
37909  fi
37910
37911  # Call helper function which possibly converts this using DOS-style short mode.
37912  # If so, the updated path is stored in $new_path.
37913  new_path="$input_to_shortpath"
37914
37915  input_path="$input_to_shortpath"
37916  # Check if we need to convert this using DOS-style short mode. If the path
37917  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37918  # take no chances and rewrite it.
37919  # Note: m4 eats our [], so we need to use [ and ] instead.
37920  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37921  if test "x$has_forbidden_chars" != x; then
37922    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37923    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37924    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37925    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37926      # Going to short mode and back again did indeed matter. Since short mode is
37927      # case insensitive, let's make it lowercase to improve readability.
37928      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37929      # Now convert it back to Unix-stile (cygpath)
37930      input_path=`$CYGPATH -u "$shortmode_path"`
37931      new_path="$input_path"
37932    fi
37933  fi
37934
37935  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37936  if test "x$test_cygdrive_prefix" = x; then
37937    # As a simple fix, exclude /usr/bin since it's not a real path.
37938    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37939      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37940      # a path prefixed by /cygdrive for fixpath to work.
37941      new_path="$CYGWIN_ROOT_PATH$input_path"
37942    fi
37943  fi
37944
37945  # remove trailing .exe if any
37946  new_path="${new_path/%.exe/}"
37947
37948  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37949
37950  # First separate the path from the arguments. This will split at the first
37951  # space.
37952  complete="$OBJCOPY"
37953  path="${complete%% *}"
37954  tmp="$complete EOL"
37955  arguments="${tmp#* }"
37956
37957  # Input might be given as Windows format, start by converting to
37958  # unix format.
37959  new_path="$path"
37960
37961  windows_path="$new_path"
37962  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37963    unix_path=`$CYGPATH -u "$windows_path"`
37964    new_path="$unix_path"
37965  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37966    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37967    new_path="$unix_path"
37968  fi
37969
37970
37971  # Now try to locate executable using which
37972  new_path=`$WHICH "$new_path" 2> /dev/null`
37973
37974  if test "x$new_path" = x; then
37975    # Oops. Which didn't find the executable.
37976    # The splitting of arguments from the executable at a space might have been incorrect,
37977    # since paths with space are more likely in Windows. Give it another try with the whole
37978    # argument.
37979    path="$complete"
37980    arguments="EOL"
37981    new_path="$path"
37982
37983  windows_path="$new_path"
37984  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37985    unix_path=`$CYGPATH -u "$windows_path"`
37986    new_path="$unix_path"
37987  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37988    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37989    new_path="$unix_path"
37990  fi
37991
37992
37993    new_path=`$WHICH "$new_path" 2> /dev/null`
37994
37995    if test "x$new_path" = x; then
37996      # It's still not found. Now this is an unrecoverable error.
37997      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37998$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37999      has_space=`$ECHO "$complete" | $GREP " "`
38000      if test "x$has_space" != x; then
38001        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38002$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38003      fi
38004      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38005    fi
38006  fi
38007
38008  # Now new_path has a complete unix path to the binary
38009  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38010    # Keep paths in /bin as-is, but remove trailing .exe if any
38011    new_path="${new_path/%.exe/}"
38012    # Do not save /bin paths to all_fixpath_prefixes!
38013  else
38014    # Not in mixed or Windows style, start by that.
38015    new_path=`cmd //c echo $new_path`
38016
38017  input_path="$new_path"
38018  # Check if we need to convert this using DOS-style short mode. If the path
38019  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38020  # take no chances and rewrite it.
38021  # Note: m4 eats our [], so we need to use [ and ] instead.
38022  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38023  if test "x$has_forbidden_chars" != x; then
38024    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38025    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38026  fi
38027
38028    # Output is in $new_path
38029
38030  windows_path="$new_path"
38031  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38032    unix_path=`$CYGPATH -u "$windows_path"`
38033    new_path="$unix_path"
38034  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38035    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38036    new_path="$unix_path"
38037  fi
38038
38039    # remove trailing .exe if any
38040    new_path="${new_path/%.exe/}"
38041
38042    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38043    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38044  fi
38045
38046  else
38047    # We're on a posix platform. Hooray! :)
38048    # First separate the path from the arguments. This will split at the first
38049    # space.
38050    complete="$OBJCOPY"
38051    path="${complete%% *}"
38052    tmp="$complete EOL"
38053    arguments="${tmp#* }"
38054
38055    # Cannot rely on the command "which" here since it doesn't always work.
38056    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38057    if test -z "$is_absolute_path"; then
38058      # Path to executable is not absolute. Find it.
38059      IFS_save="$IFS"
38060      IFS=:
38061      for p in $PATH; do
38062        if test -f "$p/$path" && test -x "$p/$path"; then
38063          new_path="$p/$path"
38064          break
38065        fi
38066      done
38067      IFS="$IFS_save"
38068    else
38069      # This is an absolute path, we can use it without further modifications.
38070      new_path="$path"
38071    fi
38072
38073    if test "x$new_path" = x; then
38074      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38075$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38076      has_space=`$ECHO "$complete" | $GREP " "`
38077      if test "x$has_space" != x; then
38078        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38079$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38080      fi
38081      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38082    fi
38083  fi
38084
38085  # Now join together the path and the arguments once again
38086  if test "x$arguments" != xEOL; then
38087    new_complete="$new_path ${arguments% *}"
38088  else
38089    new_complete="$new_path"
38090  fi
38091
38092  if test "x$complete" != "x$new_complete"; then
38093    OBJCOPY="$new_complete"
38094    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
38095$as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
38096  fi
38097
38098    fi
38099  fi
38100
38101
38102
38103  # Publish this variable in the help.
38104
38105
38106  if test "x$OBJDUMP" = x; then
38107    # The variable is not set by user, try to locate tool using the code snippet
38108    if test -n "$ac_tool_prefix"; then
38109  for ac_prog in gobjdump objdump
38110  do
38111    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38112set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38113{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38114$as_echo_n "checking for $ac_word... " >&6; }
38115if ${ac_cv_prog_OBJDUMP+:} false; then :
38116  $as_echo_n "(cached) " >&6
38117else
38118  if test -n "$OBJDUMP"; then
38119  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38120else
38121as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38122for as_dir in $PATH
38123do
38124  IFS=$as_save_IFS
38125  test -z "$as_dir" && as_dir=.
38126    for ac_exec_ext in '' $ac_executable_extensions; do
38127  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38128    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38129    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38130    break 2
38131  fi
38132done
38133  done
38134IFS=$as_save_IFS
38135
38136fi
38137fi
38138OBJDUMP=$ac_cv_prog_OBJDUMP
38139if test -n "$OBJDUMP"; then
38140  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38141$as_echo "$OBJDUMP" >&6; }
38142else
38143  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38144$as_echo "no" >&6; }
38145fi
38146
38147
38148    test -n "$OBJDUMP" && break
38149  done
38150fi
38151if test -z "$OBJDUMP"; then
38152  ac_ct_OBJDUMP=$OBJDUMP
38153  for ac_prog in gobjdump objdump
38154do
38155  # Extract the first word of "$ac_prog", so it can be a program name with args.
38156set dummy $ac_prog; ac_word=$2
38157{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38158$as_echo_n "checking for $ac_word... " >&6; }
38159if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38160  $as_echo_n "(cached) " >&6
38161else
38162  if test -n "$ac_ct_OBJDUMP"; then
38163  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38164else
38165as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38166for as_dir in $PATH
38167do
38168  IFS=$as_save_IFS
38169  test -z "$as_dir" && as_dir=.
38170    for ac_exec_ext in '' $ac_executable_extensions; do
38171  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38172    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38173    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38174    break 2
38175  fi
38176done
38177  done
38178IFS=$as_save_IFS
38179
38180fi
38181fi
38182ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38183if test -n "$ac_ct_OBJDUMP"; then
38184  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38185$as_echo "$ac_ct_OBJDUMP" >&6; }
38186else
38187  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38188$as_echo "no" >&6; }
38189fi
38190
38191
38192  test -n "$ac_ct_OBJDUMP" && break
38193done
38194
38195  if test "x$ac_ct_OBJDUMP" = x; then
38196    OBJDUMP=""
38197  else
38198    case $cross_compiling:$ac_tool_warned in
38199yes:)
38200{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38201$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38202ac_tool_warned=yes ;;
38203esac
38204    OBJDUMP=$ac_ct_OBJDUMP
38205  fi
38206fi
38207
38208  else
38209    # The variable is set, but is it from the command line or the environment?
38210
38211    # Try to remove the string !OBJDUMP! from our list.
38212    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
38213    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38214      # If it failed, the variable was not from the command line. Ignore it,
38215      # but warn the user (except for BASH, which is always set by the calling BASH).
38216      if test "xOBJDUMP" != xBASH; then
38217        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
38218$as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
38219      fi
38220      # Try to locate tool using the code snippet
38221      if test -n "$ac_tool_prefix"; then
38222  for ac_prog in gobjdump objdump
38223  do
38224    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38225set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38226{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38227$as_echo_n "checking for $ac_word... " >&6; }
38228if ${ac_cv_prog_OBJDUMP+:} false; then :
38229  $as_echo_n "(cached) " >&6
38230else
38231  if test -n "$OBJDUMP"; then
38232  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38233else
38234as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38235for as_dir in $PATH
38236do
38237  IFS=$as_save_IFS
38238  test -z "$as_dir" && as_dir=.
38239    for ac_exec_ext in '' $ac_executable_extensions; do
38240  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38241    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38242    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38243    break 2
38244  fi
38245done
38246  done
38247IFS=$as_save_IFS
38248
38249fi
38250fi
38251OBJDUMP=$ac_cv_prog_OBJDUMP
38252if test -n "$OBJDUMP"; then
38253  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38254$as_echo "$OBJDUMP" >&6; }
38255else
38256  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38257$as_echo "no" >&6; }
38258fi
38259
38260
38261    test -n "$OBJDUMP" && break
38262  done
38263fi
38264if test -z "$OBJDUMP"; then
38265  ac_ct_OBJDUMP=$OBJDUMP
38266  for ac_prog in gobjdump objdump
38267do
38268  # Extract the first word of "$ac_prog", so it can be a program name with args.
38269set dummy $ac_prog; ac_word=$2
38270{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38271$as_echo_n "checking for $ac_word... " >&6; }
38272if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38273  $as_echo_n "(cached) " >&6
38274else
38275  if test -n "$ac_ct_OBJDUMP"; then
38276  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38277else
38278as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38279for as_dir in $PATH
38280do
38281  IFS=$as_save_IFS
38282  test -z "$as_dir" && as_dir=.
38283    for ac_exec_ext in '' $ac_executable_extensions; do
38284  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38285    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38286    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38287    break 2
38288  fi
38289done
38290  done
38291IFS=$as_save_IFS
38292
38293fi
38294fi
38295ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38296if test -n "$ac_ct_OBJDUMP"; then
38297  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38298$as_echo "$ac_ct_OBJDUMP" >&6; }
38299else
38300  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38301$as_echo "no" >&6; }
38302fi
38303
38304
38305  test -n "$ac_ct_OBJDUMP" && break
38306done
38307
38308  if test "x$ac_ct_OBJDUMP" = x; then
38309    OBJDUMP=""
38310  else
38311    case $cross_compiling:$ac_tool_warned in
38312yes:)
38313{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38314$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38315ac_tool_warned=yes ;;
38316esac
38317    OBJDUMP=$ac_ct_OBJDUMP
38318  fi
38319fi
38320
38321    else
38322      # If it succeeded, then it was overridden by the user. We will use it
38323      # for the tool.
38324
38325      # First remove it from the list of overridden variables, so we can test
38326      # for unknown variables in the end.
38327      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38328
38329      # Check if the provided tool contains a complete path.
38330      tool_specified="$OBJDUMP"
38331      tool_basename="${tool_specified##*/}"
38332      if test "x$tool_basename" = "x$tool_specified"; then
38333        # A command without a complete path is provided, search $PATH.
38334        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
38335$as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
38336        # Extract the first word of "$tool_basename", so it can be a program name with args.
38337set dummy $tool_basename; ac_word=$2
38338{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38339$as_echo_n "checking for $ac_word... " >&6; }
38340if ${ac_cv_path_OBJDUMP+:} false; then :
38341  $as_echo_n "(cached) " >&6
38342else
38343  case $OBJDUMP in
38344  [\\/]* | ?:[\\/]*)
38345  ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
38346  ;;
38347  *)
38348  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38349for as_dir in $PATH
38350do
38351  IFS=$as_save_IFS
38352  test -z "$as_dir" && as_dir=.
38353    for ac_exec_ext in '' $ac_executable_extensions; do
38354  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38355    ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
38356    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38357    break 2
38358  fi
38359done
38360  done
38361IFS=$as_save_IFS
38362
38363  ;;
38364esac
38365fi
38366OBJDUMP=$ac_cv_path_OBJDUMP
38367if test -n "$OBJDUMP"; then
38368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38369$as_echo "$OBJDUMP" >&6; }
38370else
38371  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38372$as_echo "no" >&6; }
38373fi
38374
38375
38376        if test "x$OBJDUMP" = x; then
38377          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38378        fi
38379      else
38380        # Otherwise we believe it is a complete path. Use it as it is.
38381        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
38382$as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
38383        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
38384$as_echo_n "checking for OBJDUMP... " >&6; }
38385        if test ! -x "$tool_specified"; then
38386          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38387$as_echo "not found" >&6; }
38388          as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
38389        fi
38390        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38391$as_echo "$tool_specified" >&6; }
38392      fi
38393    fi
38394  fi
38395
38396
38397  if test "x$OBJDUMP" != x; then
38398    # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE
38399    # bails if argument is missing.
38400
38401  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38402
38403  # First separate the path from the arguments. This will split at the first
38404  # space.
38405  complete="$OBJDUMP"
38406  path="${complete%% *}"
38407  tmp="$complete EOL"
38408  arguments="${tmp#* }"
38409
38410  # Input might be given as Windows format, start by converting to
38411  # unix format.
38412  new_path=`$CYGPATH -u "$path"`
38413
38414  # Now try to locate executable using which
38415  new_path=`$WHICH "$new_path" 2> /dev/null`
38416  # bat and cmd files are not always considered executable in cygwin causing which
38417  # to not find them
38418  if test "x$new_path" = x \
38419      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38420      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38421    new_path=`$CYGPATH -u "$path"`
38422  fi
38423  if test "x$new_path" = x; then
38424    # Oops. Which didn't find the executable.
38425    # The splitting of arguments from the executable at a space might have been incorrect,
38426    # since paths with space are more likely in Windows. Give it another try with the whole
38427    # argument.
38428    path="$complete"
38429    arguments="EOL"
38430    new_path=`$CYGPATH -u "$path"`
38431    new_path=`$WHICH "$new_path" 2> /dev/null`
38432    # bat and cmd files are not always considered executable in cygwin causing which
38433    # to not find them
38434    if test "x$new_path" = x \
38435        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38436        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38437      new_path=`$CYGPATH -u "$path"`
38438    fi
38439    if test "x$new_path" = x; then
38440      # It's still not found. Now this is an unrecoverable error.
38441      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38442$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38443      has_space=`$ECHO "$complete" | $GREP " "`
38444      if test "x$has_space" != x; then
38445        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38446$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38447      fi
38448      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38449    fi
38450  fi
38451
38452  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38453  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38454  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38455  # "foo.exe" is OK but "foo" is an error.
38456  #
38457  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38458  # It is also a way to make sure we got the proper file name for the real test later on.
38459  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38460  if test "x$test_shortpath" = x; then
38461    # Short path failed, file does not exist as specified.
38462    # Try adding .exe or .cmd
38463    if test -f "${new_path}.exe"; then
38464      input_to_shortpath="${new_path}.exe"
38465    elif test -f "${new_path}.cmd"; then
38466      input_to_shortpath="${new_path}.cmd"
38467    else
38468      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
38469$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
38470      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38471$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38472      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38473    fi
38474  else
38475    input_to_shortpath="$new_path"
38476  fi
38477
38478  # Call helper function which possibly converts this using DOS-style short mode.
38479  # If so, the updated path is stored in $new_path.
38480  new_path="$input_to_shortpath"
38481
38482  input_path="$input_to_shortpath"
38483  # Check if we need to convert this using DOS-style short mode. If the path
38484  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38485  # take no chances and rewrite it.
38486  # Note: m4 eats our [], so we need to use [ and ] instead.
38487  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38488  if test "x$has_forbidden_chars" != x; then
38489    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38490    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38491    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38492    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38493      # Going to short mode and back again did indeed matter. Since short mode is
38494      # case insensitive, let's make it lowercase to improve readability.
38495      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38496      # Now convert it back to Unix-stile (cygpath)
38497      input_path=`$CYGPATH -u "$shortmode_path"`
38498      new_path="$input_path"
38499    fi
38500  fi
38501
38502  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38503  if test "x$test_cygdrive_prefix" = x; then
38504    # As a simple fix, exclude /usr/bin since it's not a real path.
38505    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38506      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38507      # a path prefixed by /cygdrive for fixpath to work.
38508      new_path="$CYGWIN_ROOT_PATH$input_path"
38509    fi
38510  fi
38511
38512  # remove trailing .exe if any
38513  new_path="${new_path/%.exe/}"
38514
38515  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38516
38517  # First separate the path from the arguments. This will split at the first
38518  # space.
38519  complete="$OBJDUMP"
38520  path="${complete%% *}"
38521  tmp="$complete EOL"
38522  arguments="${tmp#* }"
38523
38524  # Input might be given as Windows format, start by converting to
38525  # unix format.
38526  new_path="$path"
38527
38528  windows_path="$new_path"
38529  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38530    unix_path=`$CYGPATH -u "$windows_path"`
38531    new_path="$unix_path"
38532  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38533    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38534    new_path="$unix_path"
38535  fi
38536
38537
38538  # Now try to locate executable using which
38539  new_path=`$WHICH "$new_path" 2> /dev/null`
38540
38541  if test "x$new_path" = x; then
38542    # Oops. Which didn't find the executable.
38543    # The splitting of arguments from the executable at a space might have been incorrect,
38544    # since paths with space are more likely in Windows. Give it another try with the whole
38545    # argument.
38546    path="$complete"
38547    arguments="EOL"
38548    new_path="$path"
38549
38550  windows_path="$new_path"
38551  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38552    unix_path=`$CYGPATH -u "$windows_path"`
38553    new_path="$unix_path"
38554  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38555    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38556    new_path="$unix_path"
38557  fi
38558
38559
38560    new_path=`$WHICH "$new_path" 2> /dev/null`
38561
38562    if test "x$new_path" = x; then
38563      # It's still not found. Now this is an unrecoverable error.
38564      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38565$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38566      has_space=`$ECHO "$complete" | $GREP " "`
38567      if test "x$has_space" != x; then
38568        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38569$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38570      fi
38571      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38572    fi
38573  fi
38574
38575  # Now new_path has a complete unix path to the binary
38576  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38577    # Keep paths in /bin as-is, but remove trailing .exe if any
38578    new_path="${new_path/%.exe/}"
38579    # Do not save /bin paths to all_fixpath_prefixes!
38580  else
38581    # Not in mixed or Windows style, start by that.
38582    new_path=`cmd //c echo $new_path`
38583
38584  input_path="$new_path"
38585  # Check if we need to convert this using DOS-style short mode. If the path
38586  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38587  # take no chances and rewrite it.
38588  # Note: m4 eats our [], so we need to use [ and ] instead.
38589  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38590  if test "x$has_forbidden_chars" != x; then
38591    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38592    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38593  fi
38594
38595    # Output is in $new_path
38596
38597  windows_path="$new_path"
38598  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38599    unix_path=`$CYGPATH -u "$windows_path"`
38600    new_path="$unix_path"
38601  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38602    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38603    new_path="$unix_path"
38604  fi
38605
38606    # remove trailing .exe if any
38607    new_path="${new_path/%.exe/}"
38608
38609    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38610    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38611  fi
38612
38613  else
38614    # We're on a posix platform. Hooray! :)
38615    # First separate the path from the arguments. This will split at the first
38616    # space.
38617    complete="$OBJDUMP"
38618    path="${complete%% *}"
38619    tmp="$complete EOL"
38620    arguments="${tmp#* }"
38621
38622    # Cannot rely on the command "which" here since it doesn't always work.
38623    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38624    if test -z "$is_absolute_path"; then
38625      # Path to executable is not absolute. Find it.
38626      IFS_save="$IFS"
38627      IFS=:
38628      for p in $PATH; do
38629        if test -f "$p/$path" && test -x "$p/$path"; then
38630          new_path="$p/$path"
38631          break
38632        fi
38633      done
38634      IFS="$IFS_save"
38635    else
38636      # This is an absolute path, we can use it without further modifications.
38637      new_path="$path"
38638    fi
38639
38640    if test "x$new_path" = x; then
38641      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38642$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38643      has_space=`$ECHO "$complete" | $GREP " "`
38644      if test "x$has_space" != x; then
38645        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38646$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38647      fi
38648      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38649    fi
38650  fi
38651
38652  # Now join together the path and the arguments once again
38653  if test "x$arguments" != xEOL; then
38654    new_complete="$new_path ${arguments% *}"
38655  else
38656    new_complete="$new_path"
38657  fi
38658
38659  if test "x$complete" != "x$new_complete"; then
38660    OBJDUMP="$new_complete"
38661    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
38662$as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
38663  fi
38664
38665  fi
38666
38667
38668  # Restore old path.
38669  PATH="$OLD_PATH"
38670
38671  # Restore the flags to the user specified values.
38672  # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
38673  CFLAGS="$ORG_CFLAGS"
38674  CXXFLAGS="$ORG_CXXFLAGS"
38675  OBJCFLAGS="$ORG_OBJCFLAGS"
38676
38677
38678# Finally do some processing after the detection phase
38679
38680  if test "x$COMPILE_TYPE" = "xcross"; then
38681    # Now we need to find a C/C++ compiler that can build executables for the
38682    # build platform. We can't use the AC_PROG_CC macro, since it can only be
38683    # used once. Also, we need to do this without adding a tools dir to the
38684    # path, otherwise we might pick up cross-compilers which don't use standard
38685    # naming.
38686
38687    # FIXME: we should list the discovered compilers as an exclude pattern!
38688    # If we do that, we can do this detection before POST_DETECTION, and still
38689    # find the build compilers in the tools dir, if needed.
38690
38691
38692  # Publish this variable in the help.
38693
38694
38695  if test "x$BUILD_CC" = x; then
38696    # The variable is not set by user, try to locate tool using the code snippet
38697    for ac_prog in cl cc gcc
38698do
38699  # Extract the first word of "$ac_prog", so it can be a program name with args.
38700set dummy $ac_prog; ac_word=$2
38701{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38702$as_echo_n "checking for $ac_word... " >&6; }
38703if ${ac_cv_path_BUILD_CC+:} false; then :
38704  $as_echo_n "(cached) " >&6
38705else
38706  case $BUILD_CC in
38707  [\\/]* | ?:[\\/]*)
38708  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38709  ;;
38710  *)
38711  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38712for as_dir in $PATH
38713do
38714  IFS=$as_save_IFS
38715  test -z "$as_dir" && as_dir=.
38716    for ac_exec_ext in '' $ac_executable_extensions; do
38717  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38718    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38719    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38720    break 2
38721  fi
38722done
38723  done
38724IFS=$as_save_IFS
38725
38726  ;;
38727esac
38728fi
38729BUILD_CC=$ac_cv_path_BUILD_CC
38730if test -n "$BUILD_CC"; then
38731  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38732$as_echo "$BUILD_CC" >&6; }
38733else
38734  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38735$as_echo "no" >&6; }
38736fi
38737
38738
38739  test -n "$BUILD_CC" && break
38740done
38741
38742  else
38743    # The variable is set, but is it from the command line or the environment?
38744
38745    # Try to remove the string !BUILD_CC! from our list.
38746    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
38747    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38748      # If it failed, the variable was not from the command line. Ignore it,
38749      # but warn the user (except for BASH, which is always set by the calling BASH).
38750      if test "xBUILD_CC" != xBASH; then
38751        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
38752$as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
38753      fi
38754      # Try to locate tool using the code snippet
38755      for ac_prog in cl cc gcc
38756do
38757  # Extract the first word of "$ac_prog", so it can be a program name with args.
38758set dummy $ac_prog; ac_word=$2
38759{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38760$as_echo_n "checking for $ac_word... " >&6; }
38761if ${ac_cv_path_BUILD_CC+:} false; then :
38762  $as_echo_n "(cached) " >&6
38763else
38764  case $BUILD_CC in
38765  [\\/]* | ?:[\\/]*)
38766  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38767  ;;
38768  *)
38769  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38770for as_dir in $PATH
38771do
38772  IFS=$as_save_IFS
38773  test -z "$as_dir" && as_dir=.
38774    for ac_exec_ext in '' $ac_executable_extensions; do
38775  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38776    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38777    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38778    break 2
38779  fi
38780done
38781  done
38782IFS=$as_save_IFS
38783
38784  ;;
38785esac
38786fi
38787BUILD_CC=$ac_cv_path_BUILD_CC
38788if test -n "$BUILD_CC"; then
38789  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38790$as_echo "$BUILD_CC" >&6; }
38791else
38792  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38793$as_echo "no" >&6; }
38794fi
38795
38796
38797  test -n "$BUILD_CC" && break
38798done
38799
38800    else
38801      # If it succeeded, then it was overridden by the user. We will use it
38802      # for the tool.
38803
38804      # First remove it from the list of overridden variables, so we can test
38805      # for unknown variables in the end.
38806      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38807
38808      # Check if the provided tool contains a complete path.
38809      tool_specified="$BUILD_CC"
38810      tool_basename="${tool_specified##*/}"
38811      if test "x$tool_basename" = "x$tool_specified"; then
38812        # A command without a complete path is provided, search $PATH.
38813        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
38814$as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
38815        # Extract the first word of "$tool_basename", so it can be a program name with args.
38816set dummy $tool_basename; ac_word=$2
38817{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38818$as_echo_n "checking for $ac_word... " >&6; }
38819if ${ac_cv_path_BUILD_CC+:} false; then :
38820  $as_echo_n "(cached) " >&6
38821else
38822  case $BUILD_CC in
38823  [\\/]* | ?:[\\/]*)
38824  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38825  ;;
38826  *)
38827  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38828for as_dir in $PATH
38829do
38830  IFS=$as_save_IFS
38831  test -z "$as_dir" && as_dir=.
38832    for ac_exec_ext in '' $ac_executable_extensions; do
38833  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38834    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38835    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38836    break 2
38837  fi
38838done
38839  done
38840IFS=$as_save_IFS
38841
38842  ;;
38843esac
38844fi
38845BUILD_CC=$ac_cv_path_BUILD_CC
38846if test -n "$BUILD_CC"; then
38847  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38848$as_echo "$BUILD_CC" >&6; }
38849else
38850  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38851$as_echo "no" >&6; }
38852fi
38853
38854
38855        if test "x$BUILD_CC" = x; then
38856          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38857        fi
38858      else
38859        # Otherwise we believe it is a complete path. Use it as it is.
38860        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
38861$as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
38862        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
38863$as_echo_n "checking for BUILD_CC... " >&6; }
38864        if test ! -x "$tool_specified"; then
38865          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38866$as_echo "not found" >&6; }
38867          as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
38868        fi
38869        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38870$as_echo "$tool_specified" >&6; }
38871      fi
38872    fi
38873  fi
38874
38875
38876
38877  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38878
38879  # First separate the path from the arguments. This will split at the first
38880  # space.
38881  complete="$BUILD_CC"
38882  path="${complete%% *}"
38883  tmp="$complete EOL"
38884  arguments="${tmp#* }"
38885
38886  # Input might be given as Windows format, start by converting to
38887  # unix format.
38888  new_path=`$CYGPATH -u "$path"`
38889
38890  # Now try to locate executable using which
38891  new_path=`$WHICH "$new_path" 2> /dev/null`
38892  # bat and cmd files are not always considered executable in cygwin causing which
38893  # to not find them
38894  if test "x$new_path" = x \
38895      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38896      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38897    new_path=`$CYGPATH -u "$path"`
38898  fi
38899  if test "x$new_path" = x; then
38900    # Oops. Which didn't find the executable.
38901    # The splitting of arguments from the executable at a space might have been incorrect,
38902    # since paths with space are more likely in Windows. Give it another try with the whole
38903    # argument.
38904    path="$complete"
38905    arguments="EOL"
38906    new_path=`$CYGPATH -u "$path"`
38907    new_path=`$WHICH "$new_path" 2> /dev/null`
38908    # bat and cmd files are not always considered executable in cygwin causing which
38909    # to not find them
38910    if test "x$new_path" = x \
38911        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38912        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38913      new_path=`$CYGPATH -u "$path"`
38914    fi
38915    if test "x$new_path" = x; then
38916      # It's still not found. Now this is an unrecoverable error.
38917      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
38918$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
38919      has_space=`$ECHO "$complete" | $GREP " "`
38920      if test "x$has_space" != x; then
38921        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38922$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38923      fi
38924      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38925    fi
38926  fi
38927
38928  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38929  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38930  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38931  # "foo.exe" is OK but "foo" is an error.
38932  #
38933  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38934  # It is also a way to make sure we got the proper file name for the real test later on.
38935  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38936  if test "x$test_shortpath" = x; then
38937    # Short path failed, file does not exist as specified.
38938    # Try adding .exe or .cmd
38939    if test -f "${new_path}.exe"; then
38940      input_to_shortpath="${new_path}.exe"
38941    elif test -f "${new_path}.cmd"; then
38942      input_to_shortpath="${new_path}.cmd"
38943    else
38944      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
38945$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
38946      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38947$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38948      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38949    fi
38950  else
38951    input_to_shortpath="$new_path"
38952  fi
38953
38954  # Call helper function which possibly converts this using DOS-style short mode.
38955  # If so, the updated path is stored in $new_path.
38956  new_path="$input_to_shortpath"
38957
38958  input_path="$input_to_shortpath"
38959  # Check if we need to convert this using DOS-style short mode. If the path
38960  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38961  # take no chances and rewrite it.
38962  # Note: m4 eats our [], so we need to use [ and ] instead.
38963  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38964  if test "x$has_forbidden_chars" != x; then
38965    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38966    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38967    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38968    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38969      # Going to short mode and back again did indeed matter. Since short mode is
38970      # case insensitive, let's make it lowercase to improve readability.
38971      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38972      # Now convert it back to Unix-stile (cygpath)
38973      input_path=`$CYGPATH -u "$shortmode_path"`
38974      new_path="$input_path"
38975    fi
38976  fi
38977
38978  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38979  if test "x$test_cygdrive_prefix" = x; then
38980    # As a simple fix, exclude /usr/bin since it's not a real path.
38981    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38982      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38983      # a path prefixed by /cygdrive for fixpath to work.
38984      new_path="$CYGWIN_ROOT_PATH$input_path"
38985    fi
38986  fi
38987
38988  # remove trailing .exe if any
38989  new_path="${new_path/%.exe/}"
38990
38991  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38992
38993  # First separate the path from the arguments. This will split at the first
38994  # space.
38995  complete="$BUILD_CC"
38996  path="${complete%% *}"
38997  tmp="$complete EOL"
38998  arguments="${tmp#* }"
38999
39000  # Input might be given as Windows format, start by converting to
39001  # unix format.
39002  new_path="$path"
39003
39004  windows_path="$new_path"
39005  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39006    unix_path=`$CYGPATH -u "$windows_path"`
39007    new_path="$unix_path"
39008  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39009    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39010    new_path="$unix_path"
39011  fi
39012
39013
39014  # Now try to locate executable using which
39015  new_path=`$WHICH "$new_path" 2> /dev/null`
39016
39017  if test "x$new_path" = x; then
39018    # Oops. Which didn't find the executable.
39019    # The splitting of arguments from the executable at a space might have been incorrect,
39020    # since paths with space are more likely in Windows. Give it another try with the whole
39021    # argument.
39022    path="$complete"
39023    arguments="EOL"
39024    new_path="$path"
39025
39026  windows_path="$new_path"
39027  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39028    unix_path=`$CYGPATH -u "$windows_path"`
39029    new_path="$unix_path"
39030  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39031    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39032    new_path="$unix_path"
39033  fi
39034
39035
39036    new_path=`$WHICH "$new_path" 2> /dev/null`
39037
39038    if test "x$new_path" = x; then
39039      # It's still not found. Now this is an unrecoverable error.
39040      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39041$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39042      has_space=`$ECHO "$complete" | $GREP " "`
39043      if test "x$has_space" != x; then
39044        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39045$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39046      fi
39047      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39048    fi
39049  fi
39050
39051  # Now new_path has a complete unix path to the binary
39052  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39053    # Keep paths in /bin as-is, but remove trailing .exe if any
39054    new_path="${new_path/%.exe/}"
39055    # Do not save /bin paths to all_fixpath_prefixes!
39056  else
39057    # Not in mixed or Windows style, start by that.
39058    new_path=`cmd //c echo $new_path`
39059
39060  input_path="$new_path"
39061  # Check if we need to convert this using DOS-style short mode. If the path
39062  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39063  # take no chances and rewrite it.
39064  # Note: m4 eats our [], so we need to use [ and ] instead.
39065  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39066  if test "x$has_forbidden_chars" != x; then
39067    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39068    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39069  fi
39070
39071    # Output is in $new_path
39072
39073  windows_path="$new_path"
39074  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39075    unix_path=`$CYGPATH -u "$windows_path"`
39076    new_path="$unix_path"
39077  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39078    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39079    new_path="$unix_path"
39080  fi
39081
39082    # remove trailing .exe if any
39083    new_path="${new_path/%.exe/}"
39084
39085    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39086    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39087  fi
39088
39089  else
39090    # We're on a posix platform. Hooray! :)
39091    # First separate the path from the arguments. This will split at the first
39092    # space.
39093    complete="$BUILD_CC"
39094    path="${complete%% *}"
39095    tmp="$complete EOL"
39096    arguments="${tmp#* }"
39097
39098    # Cannot rely on the command "which" here since it doesn't always work.
39099    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39100    if test -z "$is_absolute_path"; then
39101      # Path to executable is not absolute. Find it.
39102      IFS_save="$IFS"
39103      IFS=:
39104      for p in $PATH; do
39105        if test -f "$p/$path" && test -x "$p/$path"; then
39106          new_path="$p/$path"
39107          break
39108        fi
39109      done
39110      IFS="$IFS_save"
39111    else
39112      # This is an absolute path, we can use it without further modifications.
39113      new_path="$path"
39114    fi
39115
39116    if test "x$new_path" = x; then
39117      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39118$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39119      has_space=`$ECHO "$complete" | $GREP " "`
39120      if test "x$has_space" != x; then
39121        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39122$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39123      fi
39124      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39125    fi
39126  fi
39127
39128  # Now join together the path and the arguments once again
39129  if test "x$arguments" != xEOL; then
39130    new_complete="$new_path ${arguments% *}"
39131  else
39132    new_complete="$new_path"
39133  fi
39134
39135  if test "x$complete" != "x$new_complete"; then
39136    BUILD_CC="$new_complete"
39137    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
39138$as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
39139  fi
39140
39141
39142
39143  # Publish this variable in the help.
39144
39145
39146  if test "x$BUILD_CXX" = x; then
39147    # The variable is not set by user, try to locate tool using the code snippet
39148    for ac_prog in cl CC g++
39149do
39150  # Extract the first word of "$ac_prog", so it can be a program name with args.
39151set dummy $ac_prog; ac_word=$2
39152{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39153$as_echo_n "checking for $ac_word... " >&6; }
39154if ${ac_cv_path_BUILD_CXX+:} false; then :
39155  $as_echo_n "(cached) " >&6
39156else
39157  case $BUILD_CXX in
39158  [\\/]* | ?:[\\/]*)
39159  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39160  ;;
39161  *)
39162  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39163for as_dir in $PATH
39164do
39165  IFS=$as_save_IFS
39166  test -z "$as_dir" && as_dir=.
39167    for ac_exec_ext in '' $ac_executable_extensions; do
39168  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39169    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39170    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39171    break 2
39172  fi
39173done
39174  done
39175IFS=$as_save_IFS
39176
39177  ;;
39178esac
39179fi
39180BUILD_CXX=$ac_cv_path_BUILD_CXX
39181if test -n "$BUILD_CXX"; then
39182  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39183$as_echo "$BUILD_CXX" >&6; }
39184else
39185  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39186$as_echo "no" >&6; }
39187fi
39188
39189
39190  test -n "$BUILD_CXX" && break
39191done
39192
39193  else
39194    # The variable is set, but is it from the command line or the environment?
39195
39196    # Try to remove the string !BUILD_CXX! from our list.
39197    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
39198    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39199      # If it failed, the variable was not from the command line. Ignore it,
39200      # but warn the user (except for BASH, which is always set by the calling BASH).
39201      if test "xBUILD_CXX" != xBASH; then
39202        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
39203$as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
39204      fi
39205      # Try to locate tool using the code snippet
39206      for ac_prog in cl CC g++
39207do
39208  # Extract the first word of "$ac_prog", so it can be a program name with args.
39209set dummy $ac_prog; ac_word=$2
39210{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39211$as_echo_n "checking for $ac_word... " >&6; }
39212if ${ac_cv_path_BUILD_CXX+:} false; then :
39213  $as_echo_n "(cached) " >&6
39214else
39215  case $BUILD_CXX in
39216  [\\/]* | ?:[\\/]*)
39217  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39218  ;;
39219  *)
39220  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39221for as_dir in $PATH
39222do
39223  IFS=$as_save_IFS
39224  test -z "$as_dir" && as_dir=.
39225    for ac_exec_ext in '' $ac_executable_extensions; do
39226  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39227    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39228    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39229    break 2
39230  fi
39231done
39232  done
39233IFS=$as_save_IFS
39234
39235  ;;
39236esac
39237fi
39238BUILD_CXX=$ac_cv_path_BUILD_CXX
39239if test -n "$BUILD_CXX"; then
39240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39241$as_echo "$BUILD_CXX" >&6; }
39242else
39243  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39244$as_echo "no" >&6; }
39245fi
39246
39247
39248  test -n "$BUILD_CXX" && break
39249done
39250
39251    else
39252      # If it succeeded, then it was overridden by the user. We will use it
39253      # for the tool.
39254
39255      # First remove it from the list of overridden variables, so we can test
39256      # for unknown variables in the end.
39257      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39258
39259      # Check if the provided tool contains a complete path.
39260      tool_specified="$BUILD_CXX"
39261      tool_basename="${tool_specified##*/}"
39262      if test "x$tool_basename" = "x$tool_specified"; then
39263        # A command without a complete path is provided, search $PATH.
39264        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
39265$as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
39266        # Extract the first word of "$tool_basename", so it can be a program name with args.
39267set dummy $tool_basename; ac_word=$2
39268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39269$as_echo_n "checking for $ac_word... " >&6; }
39270if ${ac_cv_path_BUILD_CXX+:} false; then :
39271  $as_echo_n "(cached) " >&6
39272else
39273  case $BUILD_CXX in
39274  [\\/]* | ?:[\\/]*)
39275  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39276  ;;
39277  *)
39278  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39279for as_dir in $PATH
39280do
39281  IFS=$as_save_IFS
39282  test -z "$as_dir" && as_dir=.
39283    for ac_exec_ext in '' $ac_executable_extensions; do
39284  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39285    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39286    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39287    break 2
39288  fi
39289done
39290  done
39291IFS=$as_save_IFS
39292
39293  ;;
39294esac
39295fi
39296BUILD_CXX=$ac_cv_path_BUILD_CXX
39297if test -n "$BUILD_CXX"; then
39298  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39299$as_echo "$BUILD_CXX" >&6; }
39300else
39301  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39302$as_echo "no" >&6; }
39303fi
39304
39305
39306        if test "x$BUILD_CXX" = x; then
39307          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39308        fi
39309      else
39310        # Otherwise we believe it is a complete path. Use it as it is.
39311        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
39312$as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
39313        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
39314$as_echo_n "checking for BUILD_CXX... " >&6; }
39315        if test ! -x "$tool_specified"; then
39316          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39317$as_echo "not found" >&6; }
39318          as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
39319        fi
39320        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39321$as_echo "$tool_specified" >&6; }
39322      fi
39323    fi
39324  fi
39325
39326
39327
39328  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39329
39330  # First separate the path from the arguments. This will split at the first
39331  # space.
39332  complete="$BUILD_CXX"
39333  path="${complete%% *}"
39334  tmp="$complete EOL"
39335  arguments="${tmp#* }"
39336
39337  # Input might be given as Windows format, start by converting to
39338  # unix format.
39339  new_path=`$CYGPATH -u "$path"`
39340
39341  # Now try to locate executable using which
39342  new_path=`$WHICH "$new_path" 2> /dev/null`
39343  # bat and cmd files are not always considered executable in cygwin causing which
39344  # to not find them
39345  if test "x$new_path" = x \
39346      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39347      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39348    new_path=`$CYGPATH -u "$path"`
39349  fi
39350  if test "x$new_path" = x; then
39351    # Oops. Which didn't find the executable.
39352    # The splitting of arguments from the executable at a space might have been incorrect,
39353    # since paths with space are more likely in Windows. Give it another try with the whole
39354    # argument.
39355    path="$complete"
39356    arguments="EOL"
39357    new_path=`$CYGPATH -u "$path"`
39358    new_path=`$WHICH "$new_path" 2> /dev/null`
39359    # bat and cmd files are not always considered executable in cygwin causing which
39360    # to not find them
39361    if test "x$new_path" = x \
39362        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39363        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39364      new_path=`$CYGPATH -u "$path"`
39365    fi
39366    if test "x$new_path" = x; then
39367      # It's still not found. Now this is an unrecoverable error.
39368      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39369$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39370      has_space=`$ECHO "$complete" | $GREP " "`
39371      if test "x$has_space" != x; then
39372        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39373$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39374      fi
39375      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39376    fi
39377  fi
39378
39379  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39380  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39381  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39382  # "foo.exe" is OK but "foo" is an error.
39383  #
39384  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39385  # It is also a way to make sure we got the proper file name for the real test later on.
39386  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39387  if test "x$test_shortpath" = x; then
39388    # Short path failed, file does not exist as specified.
39389    # Try adding .exe or .cmd
39390    if test -f "${new_path}.exe"; then
39391      input_to_shortpath="${new_path}.exe"
39392    elif test -f "${new_path}.cmd"; then
39393      input_to_shortpath="${new_path}.cmd"
39394    else
39395      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
39396$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
39397      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39398$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39399      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39400    fi
39401  else
39402    input_to_shortpath="$new_path"
39403  fi
39404
39405  # Call helper function which possibly converts this using DOS-style short mode.
39406  # If so, the updated path is stored in $new_path.
39407  new_path="$input_to_shortpath"
39408
39409  input_path="$input_to_shortpath"
39410  # Check if we need to convert this using DOS-style short mode. If the path
39411  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39412  # take no chances and rewrite it.
39413  # Note: m4 eats our [], so we need to use [ and ] instead.
39414  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39415  if test "x$has_forbidden_chars" != x; then
39416    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39417    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39418    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39419    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39420      # Going to short mode and back again did indeed matter. Since short mode is
39421      # case insensitive, let's make it lowercase to improve readability.
39422      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39423      # Now convert it back to Unix-stile (cygpath)
39424      input_path=`$CYGPATH -u "$shortmode_path"`
39425      new_path="$input_path"
39426    fi
39427  fi
39428
39429  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39430  if test "x$test_cygdrive_prefix" = x; then
39431    # As a simple fix, exclude /usr/bin since it's not a real path.
39432    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39433      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39434      # a path prefixed by /cygdrive for fixpath to work.
39435      new_path="$CYGWIN_ROOT_PATH$input_path"
39436    fi
39437  fi
39438
39439  # remove trailing .exe if any
39440  new_path="${new_path/%.exe/}"
39441
39442  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39443
39444  # First separate the path from the arguments. This will split at the first
39445  # space.
39446  complete="$BUILD_CXX"
39447  path="${complete%% *}"
39448  tmp="$complete EOL"
39449  arguments="${tmp#* }"
39450
39451  # Input might be given as Windows format, start by converting to
39452  # unix format.
39453  new_path="$path"
39454
39455  windows_path="$new_path"
39456  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39457    unix_path=`$CYGPATH -u "$windows_path"`
39458    new_path="$unix_path"
39459  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39460    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39461    new_path="$unix_path"
39462  fi
39463
39464
39465  # Now try to locate executable using which
39466  new_path=`$WHICH "$new_path" 2> /dev/null`
39467
39468  if test "x$new_path" = x; then
39469    # Oops. Which didn't find the executable.
39470    # The splitting of arguments from the executable at a space might have been incorrect,
39471    # since paths with space are more likely in Windows. Give it another try with the whole
39472    # argument.
39473    path="$complete"
39474    arguments="EOL"
39475    new_path="$path"
39476
39477  windows_path="$new_path"
39478  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39479    unix_path=`$CYGPATH -u "$windows_path"`
39480    new_path="$unix_path"
39481  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39482    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39483    new_path="$unix_path"
39484  fi
39485
39486
39487    new_path=`$WHICH "$new_path" 2> /dev/null`
39488
39489    if test "x$new_path" = x; then
39490      # It's still not found. Now this is an unrecoverable error.
39491      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39492$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39493      has_space=`$ECHO "$complete" | $GREP " "`
39494      if test "x$has_space" != x; then
39495        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39496$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39497      fi
39498      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39499    fi
39500  fi
39501
39502  # Now new_path has a complete unix path to the binary
39503  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39504    # Keep paths in /bin as-is, but remove trailing .exe if any
39505    new_path="${new_path/%.exe/}"
39506    # Do not save /bin paths to all_fixpath_prefixes!
39507  else
39508    # Not in mixed or Windows style, start by that.
39509    new_path=`cmd //c echo $new_path`
39510
39511  input_path="$new_path"
39512  # Check if we need to convert this using DOS-style short mode. If the path
39513  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39514  # take no chances and rewrite it.
39515  # Note: m4 eats our [], so we need to use [ and ] instead.
39516  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39517  if test "x$has_forbidden_chars" != x; then
39518    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39519    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39520  fi
39521
39522    # Output is in $new_path
39523
39524  windows_path="$new_path"
39525  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39526    unix_path=`$CYGPATH -u "$windows_path"`
39527    new_path="$unix_path"
39528  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39529    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39530    new_path="$unix_path"
39531  fi
39532
39533    # remove trailing .exe if any
39534    new_path="${new_path/%.exe/}"
39535
39536    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39537    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39538  fi
39539
39540  else
39541    # We're on a posix platform. Hooray! :)
39542    # First separate the path from the arguments. This will split at the first
39543    # space.
39544    complete="$BUILD_CXX"
39545    path="${complete%% *}"
39546    tmp="$complete EOL"
39547    arguments="${tmp#* }"
39548
39549    # Cannot rely on the command "which" here since it doesn't always work.
39550    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39551    if test -z "$is_absolute_path"; then
39552      # Path to executable is not absolute. Find it.
39553      IFS_save="$IFS"
39554      IFS=:
39555      for p in $PATH; do
39556        if test -f "$p/$path" && test -x "$p/$path"; then
39557          new_path="$p/$path"
39558          break
39559        fi
39560      done
39561      IFS="$IFS_save"
39562    else
39563      # This is an absolute path, we can use it without further modifications.
39564      new_path="$path"
39565    fi
39566
39567    if test "x$new_path" = x; then
39568      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39569$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39570      has_space=`$ECHO "$complete" | $GREP " "`
39571      if test "x$has_space" != x; then
39572        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39573$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39574      fi
39575      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39576    fi
39577  fi
39578
39579  # Now join together the path and the arguments once again
39580  if test "x$arguments" != xEOL; then
39581    new_complete="$new_path ${arguments% *}"
39582  else
39583    new_complete="$new_path"
39584  fi
39585
39586  if test "x$complete" != "x$new_complete"; then
39587    BUILD_CXX="$new_complete"
39588    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
39589$as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
39590  fi
39591
39592
39593
39594  # Publish this variable in the help.
39595
39596
39597  if test "x$BUILD_LD" = x; then
39598    # The variable is not set by user, try to locate tool using the code snippet
39599    for ac_prog in ld
39600do
39601  # Extract the first word of "$ac_prog", so it can be a program name with args.
39602set dummy $ac_prog; ac_word=$2
39603{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39604$as_echo_n "checking for $ac_word... " >&6; }
39605if ${ac_cv_path_BUILD_LD+:} false; then :
39606  $as_echo_n "(cached) " >&6
39607else
39608  case $BUILD_LD in
39609  [\\/]* | ?:[\\/]*)
39610  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39611  ;;
39612  *)
39613  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39614for as_dir in $PATH
39615do
39616  IFS=$as_save_IFS
39617  test -z "$as_dir" && as_dir=.
39618    for ac_exec_ext in '' $ac_executable_extensions; do
39619  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39620    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39621    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39622    break 2
39623  fi
39624done
39625  done
39626IFS=$as_save_IFS
39627
39628  ;;
39629esac
39630fi
39631BUILD_LD=$ac_cv_path_BUILD_LD
39632if test -n "$BUILD_LD"; then
39633  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39634$as_echo "$BUILD_LD" >&6; }
39635else
39636  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39637$as_echo "no" >&6; }
39638fi
39639
39640
39641  test -n "$BUILD_LD" && break
39642done
39643
39644  else
39645    # The variable is set, but is it from the command line or the environment?
39646
39647    # Try to remove the string !BUILD_LD! from our list.
39648    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
39649    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39650      # If it failed, the variable was not from the command line. Ignore it,
39651      # but warn the user (except for BASH, which is always set by the calling BASH).
39652      if test "xBUILD_LD" != xBASH; then
39653        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
39654$as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
39655      fi
39656      # Try to locate tool using the code snippet
39657      for ac_prog in ld
39658do
39659  # Extract the first word of "$ac_prog", so it can be a program name with args.
39660set dummy $ac_prog; ac_word=$2
39661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39662$as_echo_n "checking for $ac_word... " >&6; }
39663if ${ac_cv_path_BUILD_LD+:} false; then :
39664  $as_echo_n "(cached) " >&6
39665else
39666  case $BUILD_LD in
39667  [\\/]* | ?:[\\/]*)
39668  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39669  ;;
39670  *)
39671  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39672for as_dir in $PATH
39673do
39674  IFS=$as_save_IFS
39675  test -z "$as_dir" && as_dir=.
39676    for ac_exec_ext in '' $ac_executable_extensions; do
39677  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39678    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39679    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39680    break 2
39681  fi
39682done
39683  done
39684IFS=$as_save_IFS
39685
39686  ;;
39687esac
39688fi
39689BUILD_LD=$ac_cv_path_BUILD_LD
39690if test -n "$BUILD_LD"; then
39691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39692$as_echo "$BUILD_LD" >&6; }
39693else
39694  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39695$as_echo "no" >&6; }
39696fi
39697
39698
39699  test -n "$BUILD_LD" && break
39700done
39701
39702    else
39703      # If it succeeded, then it was overridden by the user. We will use it
39704      # for the tool.
39705
39706      # First remove it from the list of overridden variables, so we can test
39707      # for unknown variables in the end.
39708      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39709
39710      # Check if the provided tool contains a complete path.
39711      tool_specified="$BUILD_LD"
39712      tool_basename="${tool_specified##*/}"
39713      if test "x$tool_basename" = "x$tool_specified"; then
39714        # A command without a complete path is provided, search $PATH.
39715        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
39716$as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
39717        # Extract the first word of "$tool_basename", so it can be a program name with args.
39718set dummy $tool_basename; ac_word=$2
39719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39720$as_echo_n "checking for $ac_word... " >&6; }
39721if ${ac_cv_path_BUILD_LD+:} false; then :
39722  $as_echo_n "(cached) " >&6
39723else
39724  case $BUILD_LD in
39725  [\\/]* | ?:[\\/]*)
39726  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39727  ;;
39728  *)
39729  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39730for as_dir in $PATH
39731do
39732  IFS=$as_save_IFS
39733  test -z "$as_dir" && as_dir=.
39734    for ac_exec_ext in '' $ac_executable_extensions; do
39735  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39736    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39737    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39738    break 2
39739  fi
39740done
39741  done
39742IFS=$as_save_IFS
39743
39744  ;;
39745esac
39746fi
39747BUILD_LD=$ac_cv_path_BUILD_LD
39748if test -n "$BUILD_LD"; then
39749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39750$as_echo "$BUILD_LD" >&6; }
39751else
39752  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39753$as_echo "no" >&6; }
39754fi
39755
39756
39757        if test "x$BUILD_LD" = x; then
39758          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39759        fi
39760      else
39761        # Otherwise we believe it is a complete path. Use it as it is.
39762        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
39763$as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
39764        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
39765$as_echo_n "checking for BUILD_LD... " >&6; }
39766        if test ! -x "$tool_specified"; then
39767          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39768$as_echo "not found" >&6; }
39769          as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
39770        fi
39771        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39772$as_echo "$tool_specified" >&6; }
39773      fi
39774    fi
39775  fi
39776
39777
39778
39779  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39780
39781  # First separate the path from the arguments. This will split at the first
39782  # space.
39783  complete="$BUILD_LD"
39784  path="${complete%% *}"
39785  tmp="$complete EOL"
39786  arguments="${tmp#* }"
39787
39788  # Input might be given as Windows format, start by converting to
39789  # unix format.
39790  new_path=`$CYGPATH -u "$path"`
39791
39792  # Now try to locate executable using which
39793  new_path=`$WHICH "$new_path" 2> /dev/null`
39794  # bat and cmd files are not always considered executable in cygwin causing which
39795  # to not find them
39796  if test "x$new_path" = x \
39797      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39798      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39799    new_path=`$CYGPATH -u "$path"`
39800  fi
39801  if test "x$new_path" = x; then
39802    # Oops. Which didn't find the executable.
39803    # The splitting of arguments from the executable at a space might have been incorrect,
39804    # since paths with space are more likely in Windows. Give it another try with the whole
39805    # argument.
39806    path="$complete"
39807    arguments="EOL"
39808    new_path=`$CYGPATH -u "$path"`
39809    new_path=`$WHICH "$new_path" 2> /dev/null`
39810    # bat and cmd files are not always considered executable in cygwin causing which
39811    # to not find them
39812    if test "x$new_path" = x \
39813        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39814        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39815      new_path=`$CYGPATH -u "$path"`
39816    fi
39817    if test "x$new_path" = x; then
39818      # It's still not found. Now this is an unrecoverable error.
39819      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39820$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39821      has_space=`$ECHO "$complete" | $GREP " "`
39822      if test "x$has_space" != x; then
39823        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39824$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39825      fi
39826      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39827    fi
39828  fi
39829
39830  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39831  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39832  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39833  # "foo.exe" is OK but "foo" is an error.
39834  #
39835  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39836  # It is also a way to make sure we got the proper file name for the real test later on.
39837  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39838  if test "x$test_shortpath" = x; then
39839    # Short path failed, file does not exist as specified.
39840    # Try adding .exe or .cmd
39841    if test -f "${new_path}.exe"; then
39842      input_to_shortpath="${new_path}.exe"
39843    elif test -f "${new_path}.cmd"; then
39844      input_to_shortpath="${new_path}.cmd"
39845    else
39846      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
39847$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
39848      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39849$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39850      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39851    fi
39852  else
39853    input_to_shortpath="$new_path"
39854  fi
39855
39856  # Call helper function which possibly converts this using DOS-style short mode.
39857  # If so, the updated path is stored in $new_path.
39858  new_path="$input_to_shortpath"
39859
39860  input_path="$input_to_shortpath"
39861  # Check if we need to convert this using DOS-style short mode. If the path
39862  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39863  # take no chances and rewrite it.
39864  # Note: m4 eats our [], so we need to use [ and ] instead.
39865  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39866  if test "x$has_forbidden_chars" != x; then
39867    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39868    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39869    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39870    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39871      # Going to short mode and back again did indeed matter. Since short mode is
39872      # case insensitive, let's make it lowercase to improve readability.
39873      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39874      # Now convert it back to Unix-stile (cygpath)
39875      input_path=`$CYGPATH -u "$shortmode_path"`
39876      new_path="$input_path"
39877    fi
39878  fi
39879
39880  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39881  if test "x$test_cygdrive_prefix" = x; then
39882    # As a simple fix, exclude /usr/bin since it's not a real path.
39883    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39884      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39885      # a path prefixed by /cygdrive for fixpath to work.
39886      new_path="$CYGWIN_ROOT_PATH$input_path"
39887    fi
39888  fi
39889
39890  # remove trailing .exe if any
39891  new_path="${new_path/%.exe/}"
39892
39893  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39894
39895  # First separate the path from the arguments. This will split at the first
39896  # space.
39897  complete="$BUILD_LD"
39898  path="${complete%% *}"
39899  tmp="$complete EOL"
39900  arguments="${tmp#* }"
39901
39902  # Input might be given as Windows format, start by converting to
39903  # unix format.
39904  new_path="$path"
39905
39906  windows_path="$new_path"
39907  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39908    unix_path=`$CYGPATH -u "$windows_path"`
39909    new_path="$unix_path"
39910  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39911    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39912    new_path="$unix_path"
39913  fi
39914
39915
39916  # Now try to locate executable using which
39917  new_path=`$WHICH "$new_path" 2> /dev/null`
39918
39919  if test "x$new_path" = x; then
39920    # Oops. Which didn't find the executable.
39921    # The splitting of arguments from the executable at a space might have been incorrect,
39922    # since paths with space are more likely in Windows. Give it another try with the whole
39923    # argument.
39924    path="$complete"
39925    arguments="EOL"
39926    new_path="$path"
39927
39928  windows_path="$new_path"
39929  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39930    unix_path=`$CYGPATH -u "$windows_path"`
39931    new_path="$unix_path"
39932  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39933    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39934    new_path="$unix_path"
39935  fi
39936
39937
39938    new_path=`$WHICH "$new_path" 2> /dev/null`
39939
39940    if test "x$new_path" = x; then
39941      # It's still not found. Now this is an unrecoverable error.
39942      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39943$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39944      has_space=`$ECHO "$complete" | $GREP " "`
39945      if test "x$has_space" != x; then
39946        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39947$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39948      fi
39949      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39950    fi
39951  fi
39952
39953  # Now new_path has a complete unix path to the binary
39954  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39955    # Keep paths in /bin as-is, but remove trailing .exe if any
39956    new_path="${new_path/%.exe/}"
39957    # Do not save /bin paths to all_fixpath_prefixes!
39958  else
39959    # Not in mixed or Windows style, start by that.
39960    new_path=`cmd //c echo $new_path`
39961
39962  input_path="$new_path"
39963  # Check if we need to convert this using DOS-style short mode. If the path
39964  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39965  # take no chances and rewrite it.
39966  # Note: m4 eats our [], so we need to use [ and ] instead.
39967  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39968  if test "x$has_forbidden_chars" != x; then
39969    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39970    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39971  fi
39972
39973    # Output is in $new_path
39974
39975  windows_path="$new_path"
39976  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39977    unix_path=`$CYGPATH -u "$windows_path"`
39978    new_path="$unix_path"
39979  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39980    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39981    new_path="$unix_path"
39982  fi
39983
39984    # remove trailing .exe if any
39985    new_path="${new_path/%.exe/}"
39986
39987    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39988    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39989  fi
39990
39991  else
39992    # We're on a posix platform. Hooray! :)
39993    # First separate the path from the arguments. This will split at the first
39994    # space.
39995    complete="$BUILD_LD"
39996    path="${complete%% *}"
39997    tmp="$complete EOL"
39998    arguments="${tmp#* }"
39999
40000    # Cannot rely on the command "which" here since it doesn't always work.
40001    is_absolute_path=`$ECHO "$path" | $GREP ^/`
40002    if test -z "$is_absolute_path"; then
40003      # Path to executable is not absolute. Find it.
40004      IFS_save="$IFS"
40005      IFS=:
40006      for p in $PATH; do
40007        if test -f "$p/$path" && test -x "$p/$path"; then
40008          new_path="$p/$path"
40009          break
40010        fi
40011      done
40012      IFS="$IFS_save"
40013    else
40014      # This is an absolute path, we can use it without further modifications.
40015      new_path="$path"
40016    fi
40017
40018    if test "x$new_path" = x; then
40019      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40020$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40021      has_space=`$ECHO "$complete" | $GREP " "`
40022      if test "x$has_space" != x; then
40023        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40024$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40025      fi
40026      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40027    fi
40028  fi
40029
40030  # Now join together the path and the arguments once again
40031  if test "x$arguments" != xEOL; then
40032    new_complete="$new_path ${arguments% *}"
40033  else
40034    new_complete="$new_path"
40035  fi
40036
40037  if test "x$complete" != "x$new_complete"; then
40038    BUILD_LD="$new_complete"
40039    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
40040$as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
40041  fi
40042
40043  else
40044    # If we are not cross compiling, use the normal target compilers for
40045    # building the build platform executables.
40046    BUILD_CC="$CC"
40047    BUILD_CXX="$CXX"
40048    BUILD_LD="$LD"
40049  fi
40050
40051
40052
40053
40054
40055
40056  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40057    # For hotspot, we need these in Windows mixed path,
40058    # so rewrite them all. Need added .exe suffix.
40059    HOTSPOT_CXX="$CXX.exe"
40060    HOTSPOT_LD="$LD.exe"
40061    HOTSPOT_MT="$MT.exe"
40062    HOTSPOT_RC="$RC.exe"
40063
40064  unix_path="$HOTSPOT_CXX"
40065  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40066    windows_path=`$CYGPATH -m "$unix_path"`
40067    HOTSPOT_CXX="$windows_path"
40068  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40069    windows_path=`cmd //c echo $unix_path`
40070    HOTSPOT_CXX="$windows_path"
40071  fi
40072
40073
40074  unix_path="$HOTSPOT_LD"
40075  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40076    windows_path=`$CYGPATH -m "$unix_path"`
40077    HOTSPOT_LD="$windows_path"
40078  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40079    windows_path=`cmd //c echo $unix_path`
40080    HOTSPOT_LD="$windows_path"
40081  fi
40082
40083
40084  unix_path="$HOTSPOT_MT"
40085  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40086    windows_path=`$CYGPATH -m "$unix_path"`
40087    HOTSPOT_MT="$windows_path"
40088  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40089    windows_path=`cmd //c echo $unix_path`
40090    HOTSPOT_MT="$windows_path"
40091  fi
40092
40093
40094  unix_path="$HOTSPOT_RC"
40095  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40096    windows_path=`$CYGPATH -m "$unix_path"`
40097    HOTSPOT_RC="$windows_path"
40098  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40099    windows_path=`cmd //c echo $unix_path`
40100    HOTSPOT_RC="$windows_path"
40101  fi
40102
40103
40104
40105  else
40106    HOTSPOT_CXX="$CXX"
40107    HOTSPOT_LD="$LD"
40108  fi
40109
40110
40111
40112  if test  "x$TOOLCHAIN_TYPE" = xclang; then
40113    USE_CLANG=true
40114  fi
40115
40116
40117  # LDEXE is the linker to use, when creating executables. Not really used.
40118  # FIXME: These should just be removed!
40119  LDEXE="$LD"
40120  LDEXECXX="$LDCXX"
40121
40122
40123
40124
40125  # The package path is used only on macosx?
40126  # FIXME: clean this up, and/or move it elsewhere.
40127  PACKAGE_PATH=/opt/local
40128
40129
40130  # Check for extra potential brokenness.
40131  if test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40132    # On Windows, double-check that we got the right compiler.
40133    CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'`
40134    COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"`
40135    if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
40136      if test "x$COMPILER_CPU_TEST" != "x80x86"; then
40137        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
40138      fi
40139    elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
40140      if test "x$COMPILER_CPU_TEST" != "xx64"; then
40141        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
40142      fi
40143    fi
40144  fi
40145
40146  if test "x$TOOLCHAIN_TYPE" = xgcc; then
40147    # If this is a --hash-style=gnu system, use --hash-style=both, why?
40148    HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
40149    # This is later checked when setting flags.
40150  fi
40151
40152  # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed
40153  # in executable.'
40154  USING_BROKEN_SUSE_LD=no
40155  if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then
40156    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
40157$as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
40158    echo "SUNWprivate_1.1 { local: *; };" > version-script.map
40159    echo "int main() { }" > main.c
40160    if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
40161      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40162$as_echo "no" >&6; }
40163      USING_BROKEN_SUSE_LD=no
40164    else
40165      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40166$as_echo "yes" >&6; }
40167      USING_BROKEN_SUSE_LD=yes
40168    fi
40169    rm -rf version-script.map main.c a.out
40170  fi
40171
40172
40173
40174# Setup the JTReg Regression Test Harness.
40175
40176
40177# Check whether --with-jtreg was given.
40178if test "${with_jtreg+set}" = set; then :
40179  withval=$with_jtreg;
40180else
40181  with_jtreg=no
40182fi
40183
40184
40185  if test "x$with_jtreg" = xno; then
40186    # jtreg disabled
40187    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40188$as_echo_n "checking for jtreg... " >&6; }
40189    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40190$as_echo "no" >&6; }
40191  else
40192    if test "x$with_jtreg" != xyes; then
40193      # with path specified.
40194      JT_HOME="$with_jtreg"
40195    fi
40196
40197    if test "x$JT_HOME" != x; then
40198      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40199$as_echo_n "checking for jtreg... " >&6; }
40200
40201      # use JT_HOME enviroment var.
40202
40203  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40204
40205  # Input might be given as Windows format, start by converting to
40206  # unix format.
40207  path="$JT_HOME"
40208  new_path=`$CYGPATH -u "$path"`
40209
40210  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40211  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40212  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40213  # "foo.exe" is OK but "foo" is an error.
40214  #
40215  # This test is therefore slightly more accurate than "test -f" to check for file precense.
40216  # It is also a way to make sure we got the proper file name for the real test later on.
40217  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40218  if test "x$test_shortpath" = x; then
40219    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40220$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40221    as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
40222  fi
40223
40224  # Call helper function which possibly converts this using DOS-style short mode.
40225  # If so, the updated path is stored in $new_path.
40226
40227  input_path="$new_path"
40228  # Check if we need to convert this using DOS-style short mode. If the path
40229  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40230  # take no chances and rewrite it.
40231  # Note: m4 eats our [], so we need to use [ and ] instead.
40232  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40233  if test "x$has_forbidden_chars" != x; then
40234    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40235    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40236    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40237    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40238      # Going to short mode and back again did indeed matter. Since short mode is
40239      # case insensitive, let's make it lowercase to improve readability.
40240      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40241      # Now convert it back to Unix-stile (cygpath)
40242      input_path=`$CYGPATH -u "$shortmode_path"`
40243      new_path="$input_path"
40244    fi
40245  fi
40246
40247  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40248  if test "x$test_cygdrive_prefix" = x; then
40249    # As a simple fix, exclude /usr/bin since it's not a real path.
40250    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
40251      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40252      # a path prefixed by /cygdrive for fixpath to work.
40253      new_path="$CYGWIN_ROOT_PATH$input_path"
40254    fi
40255  fi
40256
40257
40258  if test "x$path" != "x$new_path"; then
40259    JT_HOME="$new_path"
40260    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40261$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40262  fi
40263
40264  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40265
40266  path="$JT_HOME"
40267  has_colon=`$ECHO $path | $GREP ^.:`
40268  new_path="$path"
40269  if test "x$has_colon" = x; then
40270    # Not in mixed or Windows style, start by that.
40271    new_path=`cmd //c echo $path`
40272  fi
40273
40274
40275  input_path="$new_path"
40276  # Check if we need to convert this using DOS-style short mode. If the path
40277  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40278  # take no chances and rewrite it.
40279  # Note: m4 eats our [], so we need to use [ and ] instead.
40280  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40281  if test "x$has_forbidden_chars" != x; then
40282    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40283    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40284  fi
40285
40286
40287  windows_path="$new_path"
40288  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40289    unix_path=`$CYGPATH -u "$windows_path"`
40290    new_path="$unix_path"
40291  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40292    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40293    new_path="$unix_path"
40294  fi
40295
40296  if test "x$path" != "x$new_path"; then
40297    JT_HOME="$new_path"
40298    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40299$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40300  fi
40301
40302  # Save the first 10 bytes of this path to the storage, so fixpath can work.
40303  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40304
40305  else
40306    # We're on a posix platform. Hooray! :)
40307    path="$JT_HOME"
40308    has_space=`$ECHO "$path" | $GREP " "`
40309    if test "x$has_space" != x; then
40310      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40311$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40312      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
40313    fi
40314
40315    # Use eval to expand a potential ~
40316    eval path="$path"
40317    if test ! -f "$path" && test ! -d "$path"; then
40318      as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
40319    fi
40320
40321    JT_HOME="`cd "$path"; $THEPWDCMD -L`"
40322  fi
40323
40324
40325      # jtreg win32 script works for everybody
40326      JTREGEXE="$JT_HOME/win32/bin/jtreg"
40327
40328      if test ! -f "$JTREGEXE"; then
40329        as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
40330      fi
40331
40332      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40333$as_echo "$JTREGEXE" >&6; }
40334    else
40335      # try to find jtreg on path
40336
40337
40338
40339  # Publish this variable in the help.
40340
40341
40342  if test "x$JTREGEXE" = x; then
40343    # The variable is not set by user, try to locate tool using the code snippet
40344    for ac_prog in jtreg
40345do
40346  # Extract the first word of "$ac_prog", so it can be a program name with args.
40347set dummy $ac_prog; ac_word=$2
40348{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40349$as_echo_n "checking for $ac_word... " >&6; }
40350if ${ac_cv_path_JTREGEXE+:} false; then :
40351  $as_echo_n "(cached) " >&6
40352else
40353  case $JTREGEXE in
40354  [\\/]* | ?:[\\/]*)
40355  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40356  ;;
40357  *)
40358  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40359for as_dir in $PATH
40360do
40361  IFS=$as_save_IFS
40362  test -z "$as_dir" && as_dir=.
40363    for ac_exec_ext in '' $ac_executable_extensions; do
40364  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40365    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40366    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40367    break 2
40368  fi
40369done
40370  done
40371IFS=$as_save_IFS
40372
40373  ;;
40374esac
40375fi
40376JTREGEXE=$ac_cv_path_JTREGEXE
40377if test -n "$JTREGEXE"; then
40378  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40379$as_echo "$JTREGEXE" >&6; }
40380else
40381  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40382$as_echo "no" >&6; }
40383fi
40384
40385
40386  test -n "$JTREGEXE" && break
40387done
40388
40389  else
40390    # The variable is set, but is it from the command line or the environment?
40391
40392    # Try to remove the string !JTREGEXE! from our list.
40393    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
40394    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40395      # If it failed, the variable was not from the command line. Ignore it,
40396      # but warn the user (except for BASH, which is always set by the calling BASH).
40397      if test "xJTREGEXE" != xBASH; then
40398        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
40399$as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
40400      fi
40401      # Try to locate tool using the code snippet
40402      for ac_prog in jtreg
40403do
40404  # Extract the first word of "$ac_prog", so it can be a program name with args.
40405set dummy $ac_prog; ac_word=$2
40406{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40407$as_echo_n "checking for $ac_word... " >&6; }
40408if ${ac_cv_path_JTREGEXE+:} false; then :
40409  $as_echo_n "(cached) " >&6
40410else
40411  case $JTREGEXE in
40412  [\\/]* | ?:[\\/]*)
40413  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40414  ;;
40415  *)
40416  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40417for as_dir in $PATH
40418do
40419  IFS=$as_save_IFS
40420  test -z "$as_dir" && as_dir=.
40421    for ac_exec_ext in '' $ac_executable_extensions; do
40422  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40423    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40424    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40425    break 2
40426  fi
40427done
40428  done
40429IFS=$as_save_IFS
40430
40431  ;;
40432esac
40433fi
40434JTREGEXE=$ac_cv_path_JTREGEXE
40435if test -n "$JTREGEXE"; then
40436  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40437$as_echo "$JTREGEXE" >&6; }
40438else
40439  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40440$as_echo "no" >&6; }
40441fi
40442
40443
40444  test -n "$JTREGEXE" && break
40445done
40446
40447    else
40448      # If it succeeded, then it was overridden by the user. We will use it
40449      # for the tool.
40450
40451      # First remove it from the list of overridden variables, so we can test
40452      # for unknown variables in the end.
40453      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40454
40455      # Check if the provided tool contains a complete path.
40456      tool_specified="$JTREGEXE"
40457      tool_basename="${tool_specified##*/}"
40458      if test "x$tool_basename" = "x$tool_specified"; then
40459        # A command without a complete path is provided, search $PATH.
40460        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
40461$as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
40462        # Extract the first word of "$tool_basename", so it can be a program name with args.
40463set dummy $tool_basename; ac_word=$2
40464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40465$as_echo_n "checking for $ac_word... " >&6; }
40466if ${ac_cv_path_JTREGEXE+:} false; then :
40467  $as_echo_n "(cached) " >&6
40468else
40469  case $JTREGEXE in
40470  [\\/]* | ?:[\\/]*)
40471  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40472  ;;
40473  *)
40474  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40475for as_dir in $PATH
40476do
40477  IFS=$as_save_IFS
40478  test -z "$as_dir" && as_dir=.
40479    for ac_exec_ext in '' $ac_executable_extensions; do
40480  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40481    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40482    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40483    break 2
40484  fi
40485done
40486  done
40487IFS=$as_save_IFS
40488
40489  ;;
40490esac
40491fi
40492JTREGEXE=$ac_cv_path_JTREGEXE
40493if test -n "$JTREGEXE"; then
40494  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40495$as_echo "$JTREGEXE" >&6; }
40496else
40497  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40498$as_echo "no" >&6; }
40499fi
40500
40501
40502        if test "x$JTREGEXE" = x; then
40503          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40504        fi
40505      else
40506        # Otherwise we believe it is a complete path. Use it as it is.
40507        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
40508$as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
40509        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
40510$as_echo_n "checking for JTREGEXE... " >&6; }
40511        if test ! -x "$tool_specified"; then
40512          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40513$as_echo "not found" >&6; }
40514          as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
40515        fi
40516        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40517$as_echo "$tool_specified" >&6; }
40518      fi
40519    fi
40520  fi
40521
40522
40523
40524  if test "x$JTREGEXE" = x; then
40525    as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
40526  fi
40527
40528
40529      JT_HOME="`$DIRNAME $JTREGEXE`"
40530    fi
40531  fi
40532
40533
40534
40535
40536
40537
40538  # Option used to tell the compiler whether to create 32- or 64-bit executables
40539  if test "x$TOOLCHAIN_TYPE" = xxlc; then
40540    COMPILER_TARGET_BITS_FLAG="-q"
40541  else
40542    COMPILER_TARGET_BITS_FLAG="-m"
40543  fi
40544
40545
40546  # FIXME: figure out if we should select AR flags depending on OS or toolchain.
40547  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
40548    ARFLAGS="-r"
40549  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40550    ARFLAGS="-X64"
40551  elif test "x$OPENJDK_TARGET_OS" = xwindows; then
40552    # lib.exe is used as AR to create static libraries.
40553    ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
40554  else
40555    ARFLAGS=""
40556  fi
40557
40558
40559  ## Setup strip.
40560  # FIXME: should this really be per platform, or should it be per toolchain type?
40561  # strip is not provided by clang or solstudio; so guessing platform makes most sense.
40562  # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD.
40563  if test "x$OPENJDK_TARGET_OS" = xlinux; then
40564    STRIPFLAGS="-g"
40565  elif test "x$OPENJDK_TARGET_OS" = xsolaris; then
40566    STRIPFLAGS="-x"
40567  elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
40568    STRIPFLAGS="-S"
40569  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40570    STRIPFLAGS="-X32_64"
40571  fi
40572
40573  if test "x$OPENJDK_TARGET_OS" != xwindows; then
40574    POST_STRIP_CMD="$STRIP $STRIPFLAGS"
40575  fi
40576
40577
40578  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40579    # FIXME: break out into MCSFLAGS
40580    POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
40581  fi
40582
40583
40584  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40585    CC_OUT_OPTION=-Fo
40586    EXE_OUT_OPTION=-out:
40587    LD_OUT_OPTION=-out:
40588    AR_OUT_OPTION=-out:
40589  else
40590    # The option used to specify the target .o,.a or .so file.
40591    # When compiling, how to specify the to be created object file.
40592    CC_OUT_OPTION='-o$(SPACE)'
40593    # When linking, how to specify the to be created executable.
40594    EXE_OUT_OPTION='-o$(SPACE)'
40595    # When linking, how to specify the to be created dynamically linkable library.
40596    LD_OUT_OPTION='-o$(SPACE)'
40597    # When archiving, how to specify the to be create static archive for object files.
40598    AR_OUT_OPTION='rcs$(SPACE)'
40599  fi
40600
40601
40602
40603
40604
40605  # On Windows, we need to set RC flags.
40606  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40607    RC_FLAGS="-nologo -l 0x409 -r"
40608    if test "x$VARIANT" = xOPT; then
40609      RC_FLAGS="$RC_FLAGS -d NDEBUG"
40610    fi
40611
40612    # The version variables used to create RC_FLAGS may be overridden
40613    # in a custom configure script, or possibly the command line.
40614    # Let those variables be expanded at make time in spec.gmk.
40615    # The \$ are escaped to the shell, and the $(...) variables
40616    # are evaluated by make.
40617    RC_FLAGS="$RC_FLAGS \
40618        -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40619        -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40620        -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40621        -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40622        -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40623        -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40624        -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40625  fi
40626
40627
40628  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40629    # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40630    CCXXFLAGS="$CCXXFLAGS -nologo"
40631  fi
40632
40633
40634# FIXME: Currently we must test this after toolchain but before flags. Fix!
40635
40636# Now we can test some aspects on the target using configure macros.
40637
40638
40639{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40640$as_echo_n "checking for ANSI C header files... " >&6; }
40641if ${ac_cv_header_stdc+:} false; then :
40642  $as_echo_n "(cached) " >&6
40643else
40644  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40645/* end confdefs.h.  */
40646#include <stdlib.h>
40647#include <stdarg.h>
40648#include <string.h>
40649#include <float.h>
40650
40651int
40652main ()
40653{
40654
40655  ;
40656  return 0;
40657}
40658_ACEOF
40659if ac_fn_cxx_try_compile "$LINENO"; then :
40660  ac_cv_header_stdc=yes
40661else
40662  ac_cv_header_stdc=no
40663fi
40664rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40665
40666if test $ac_cv_header_stdc = yes; then
40667  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
40668  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40669/* end confdefs.h.  */
40670#include <string.h>
40671
40672_ACEOF
40673if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40674  $EGREP "memchr" >/dev/null 2>&1; then :
40675
40676else
40677  ac_cv_header_stdc=no
40678fi
40679rm -f conftest*
40680
40681fi
40682
40683if test $ac_cv_header_stdc = yes; then
40684  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
40685  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40686/* end confdefs.h.  */
40687#include <stdlib.h>
40688
40689_ACEOF
40690if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40691  $EGREP "free" >/dev/null 2>&1; then :
40692
40693else
40694  ac_cv_header_stdc=no
40695fi
40696rm -f conftest*
40697
40698fi
40699
40700if test $ac_cv_header_stdc = yes; then
40701  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
40702  if test "$cross_compiling" = yes; then :
40703  :
40704else
40705  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40706/* end confdefs.h.  */
40707#include <ctype.h>
40708#include <stdlib.h>
40709#if ((' ' & 0x0FF) == 0x020)
40710# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
40711# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
40712#else
40713# define ISLOWER(c) \
40714		   (('a' <= (c) && (c) <= 'i') \
40715		     || ('j' <= (c) && (c) <= 'r') \
40716		     || ('s' <= (c) && (c) <= 'z'))
40717# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
40718#endif
40719
40720#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
40721int
40722main ()
40723{
40724  int i;
40725  for (i = 0; i < 256; i++)
40726    if (XOR (islower (i), ISLOWER (i))
40727	|| toupper (i) != TOUPPER (i))
40728      return 2;
40729  return 0;
40730}
40731_ACEOF
40732if ac_fn_cxx_try_run "$LINENO"; then :
40733
40734else
40735  ac_cv_header_stdc=no
40736fi
40737rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40738  conftest.$ac_objext conftest.beam conftest.$ac_ext
40739fi
40740
40741fi
40742fi
40743{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
40744$as_echo "$ac_cv_header_stdc" >&6; }
40745if test $ac_cv_header_stdc = yes; then
40746
40747$as_echo "#define STDC_HEADERS 1" >>confdefs.h
40748
40749fi
40750
40751# On IRIX 5.3, sys/types and inttypes.h are conflicting.
40752for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
40753		  inttypes.h stdint.h unistd.h
40754do :
40755  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
40756ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
40757"
40758if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
40759  cat >>confdefs.h <<_ACEOF
40760#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
40761_ACEOF
40762
40763fi
40764
40765done
40766
40767
40768
40769  ###############################################################################
40770  #
40771  # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
40772  # (The JVM can use 32 or 64 bit Java pointers but that decision
40773  # is made at runtime.)
40774  #
40775
40776  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
40777    # Always specify -m flag on Solaris
40778    # And -q on AIX because otherwise the compiler produces 32-bit objects by default
40779
40780  # When we add flags to the "official" CFLAGS etc, we need to
40781  # keep track of these additions in ADDED_CFLAGS etc. These
40782  # will later be checked to make sure only controlled additions
40783  # have been made to CFLAGS etc.
40784  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40785  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40786  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40787
40788  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40789  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40790  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40791
40792  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40793  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40794  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40795
40796  elif test "x$COMPILE_TYPE" = xreduced; then
40797    if test "x$OPENJDK_TARGET_OS" != xwindows; then
40798      # Specify -m if running reduced on other Posix platforms
40799
40800  # When we add flags to the "official" CFLAGS etc, we need to
40801  # keep track of these additions in ADDED_CFLAGS etc. These
40802  # will later be checked to make sure only controlled additions
40803  # have been made to CFLAGS etc.
40804  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40805  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40806  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40807
40808  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40809  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40810  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40811
40812  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40813  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40814  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40815
40816    fi
40817  fi
40818
40819  # Make compilation sanity check
40820  for ac_header in stdio.h
40821do :
40822  ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
40823if test "x$ac_cv_header_stdio_h" = xyes; then :
40824  cat >>confdefs.h <<_ACEOF
40825#define HAVE_STDIO_H 1
40826_ACEOF
40827
40828else
40829
40830    { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
40831$as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
40832    if test "x$COMPILE_TYPE" = xreduced; then
40833      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
40834$as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
40835    elif test "x$COMPILE_TYPE" = xcross; then
40836      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
40837$as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
40838    fi
40839    as_fn_error $? "Cannot continue." "$LINENO" 5
40840
40841fi
40842
40843done
40844
40845
40846  # The cast to long int works around a bug in the HP C Compiler
40847# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40848# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40849# This bug is HP SR number 8606223364.
40850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40851$as_echo_n "checking size of int *... " >&6; }
40852if ${ac_cv_sizeof_int_p+:} false; then :
40853  $as_echo_n "(cached) " >&6
40854else
40855  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40856
40857else
40858  if test "$ac_cv_type_int_p" = yes; then
40859     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40860$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40861as_fn_error 77 "cannot compute sizeof (int *)
40862See \`config.log' for more details" "$LINENO" 5; }
40863   else
40864     ac_cv_sizeof_int_p=0
40865   fi
40866fi
40867
40868fi
40869{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40870$as_echo "$ac_cv_sizeof_int_p" >&6; }
40871
40872
40873
40874cat >>confdefs.h <<_ACEOF
40875#define SIZEOF_INT_P $ac_cv_sizeof_int_p
40876_ACEOF
40877
40878
40879
40880  # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
40881  if test "x$ac_cv_sizeof_int_p" = x; then
40882    # The test failed, lets stick to the assumed value.
40883    { $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
40884$as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
40885  else
40886    TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40887
40888    if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40889      # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
40890      # Let's try to implicitely set the compilers target architecture and retry the test
40891      { $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
40892$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;}
40893      { $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
40894$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;}
40895
40896  # When we add flags to the "official" CFLAGS etc, we need to
40897  # keep track of these additions in ADDED_CFLAGS etc. These
40898  # will later be checked to make sure only controlled additions
40899  # have been made to CFLAGS etc.
40900  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40901  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40902  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40903
40904  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40905  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40906  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40907
40908  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40909  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40910  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40911
40912
40913      # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
40914      unset ac_cv_sizeof_int_p
40915      # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
40916      cat >>confdefs.h <<_ACEOF
40917#undef SIZEOF_INT_P
40918_ACEOF
40919
40920      # The cast to long int works around a bug in the HP C Compiler
40921# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40922# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40923# This bug is HP SR number 8606223364.
40924{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40925$as_echo_n "checking size of int *... " >&6; }
40926if ${ac_cv_sizeof_int_p+:} false; then :
40927  $as_echo_n "(cached) " >&6
40928else
40929  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40930
40931else
40932  if test "$ac_cv_type_int_p" = yes; then
40933     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40934$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40935as_fn_error 77 "cannot compute sizeof (int *)
40936See \`config.log' for more details" "$LINENO" 5; }
40937   else
40938     ac_cv_sizeof_int_p=0
40939   fi
40940fi
40941
40942fi
40943{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40944$as_echo "$ac_cv_sizeof_int_p" >&6; }
40945
40946
40947
40948cat >>confdefs.h <<_ACEOF
40949#define SIZEOF_INT_P $ac_cv_sizeof_int_p
40950_ACEOF
40951
40952
40953
40954      TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40955
40956      if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40957        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
40958      fi
40959    fi
40960  fi
40961
40962  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
40963$as_echo_n "checking for target address size... " >&6; }
40964  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
40965$as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
40966
40967
40968  ###############################################################################
40969  #
40970  # Is the target little of big endian?
40971  #
40972   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
40973$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
40974if ${ac_cv_c_bigendian+:} false; then :
40975  $as_echo_n "(cached) " >&6
40976else
40977  ac_cv_c_bigendian=unknown
40978    # See if we're dealing with a universal compiler.
40979    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40980/* end confdefs.h.  */
40981#ifndef __APPLE_CC__
40982	       not a universal capable compiler
40983	     #endif
40984	     typedef int dummy;
40985
40986_ACEOF
40987if ac_fn_cxx_try_compile "$LINENO"; then :
40988
40989	# Check for potential -arch flags.  It is not universal unless
40990	# there are at least two -arch flags with different values.
40991	ac_arch=
40992	ac_prev=
40993	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
40994	 if test -n "$ac_prev"; then
40995	   case $ac_word in
40996	     i?86 | x86_64 | ppc | ppc64)
40997	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
40998		 ac_arch=$ac_word
40999	       else
41000		 ac_cv_c_bigendian=universal
41001		 break
41002	       fi
41003	       ;;
41004	   esac
41005	   ac_prev=
41006	 elif test "x$ac_word" = "x-arch"; then
41007	   ac_prev=arch
41008	 fi
41009       done
41010fi
41011rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41012    if test $ac_cv_c_bigendian = unknown; then
41013      # See if sys/param.h defines the BYTE_ORDER macro.
41014      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41015/* end confdefs.h.  */
41016#include <sys/types.h>
41017	     #include <sys/param.h>
41018
41019int
41020main ()
41021{
41022#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
41023		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
41024		     && LITTLE_ENDIAN)
41025	      bogus endian macros
41026	     #endif
41027
41028  ;
41029  return 0;
41030}
41031_ACEOF
41032if ac_fn_cxx_try_compile "$LINENO"; then :
41033  # It does; now see whether it defined to BIG_ENDIAN or not.
41034	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41035/* end confdefs.h.  */
41036#include <sys/types.h>
41037		#include <sys/param.h>
41038
41039int
41040main ()
41041{
41042#if BYTE_ORDER != BIG_ENDIAN
41043		 not big endian
41044		#endif
41045
41046  ;
41047  return 0;
41048}
41049_ACEOF
41050if ac_fn_cxx_try_compile "$LINENO"; then :
41051  ac_cv_c_bigendian=yes
41052else
41053  ac_cv_c_bigendian=no
41054fi
41055rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41056fi
41057rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41058    fi
41059    if test $ac_cv_c_bigendian = unknown; then
41060      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
41061      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41062/* end confdefs.h.  */
41063#include <limits.h>
41064
41065int
41066main ()
41067{
41068#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
41069	      bogus endian macros
41070	     #endif
41071
41072  ;
41073  return 0;
41074}
41075_ACEOF
41076if ac_fn_cxx_try_compile "$LINENO"; then :
41077  # It does; now see whether it defined to _BIG_ENDIAN or not.
41078	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41079/* end confdefs.h.  */
41080#include <limits.h>
41081
41082int
41083main ()
41084{
41085#ifndef _BIG_ENDIAN
41086		 not big endian
41087		#endif
41088
41089  ;
41090  return 0;
41091}
41092_ACEOF
41093if ac_fn_cxx_try_compile "$LINENO"; then :
41094  ac_cv_c_bigendian=yes
41095else
41096  ac_cv_c_bigendian=no
41097fi
41098rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41099fi
41100rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41101    fi
41102    if test $ac_cv_c_bigendian = unknown; then
41103      # Compile a test program.
41104      if test "$cross_compiling" = yes; then :
41105  # Try to guess by grepping values from an object file.
41106	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41107/* end confdefs.h.  */
41108short int ascii_mm[] =
41109		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
41110		short int ascii_ii[] =
41111		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
41112		int use_ascii (int i) {
41113		  return ascii_mm[i] + ascii_ii[i];
41114		}
41115		short int ebcdic_ii[] =
41116		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
41117		short int ebcdic_mm[] =
41118		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
41119		int use_ebcdic (int i) {
41120		  return ebcdic_mm[i] + ebcdic_ii[i];
41121		}
41122		extern int foo;
41123
41124int
41125main ()
41126{
41127return use_ascii (foo) == use_ebcdic (foo);
41128  ;
41129  return 0;
41130}
41131_ACEOF
41132if ac_fn_cxx_try_compile "$LINENO"; then :
41133  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
41134	      ac_cv_c_bigendian=yes
41135	    fi
41136	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
41137	      if test "$ac_cv_c_bigendian" = unknown; then
41138		ac_cv_c_bigendian=no
41139	      else
41140		# finding both strings is unlikely to happen, but who knows?
41141		ac_cv_c_bigendian=unknown
41142	      fi
41143	    fi
41144fi
41145rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41146else
41147  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41148/* end confdefs.h.  */
41149$ac_includes_default
41150int
41151main ()
41152{
41153
41154	     /* Are we little or big endian?  From Harbison&Steele.  */
41155	     union
41156	     {
41157	       long int l;
41158	       char c[sizeof (long int)];
41159	     } u;
41160	     u.l = 1;
41161	     return u.c[sizeof (long int) - 1] == 1;
41162
41163  ;
41164  return 0;
41165}
41166_ACEOF
41167if ac_fn_cxx_try_run "$LINENO"; then :
41168  ac_cv_c_bigendian=no
41169else
41170  ac_cv_c_bigendian=yes
41171fi
41172rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41173  conftest.$ac_objext conftest.beam conftest.$ac_ext
41174fi
41175
41176    fi
41177fi
41178{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
41179$as_echo "$ac_cv_c_bigendian" >&6; }
41180 case $ac_cv_c_bigendian in #(
41181   yes)
41182     ENDIAN="big";; #(
41183   no)
41184     ENDIAN="little" ;; #(
41185   universal)
41186     ENDIAN="universal_endianness"
41187     ;; #(
41188   *)
41189     ENDIAN="unknown" ;;
41190 esac
41191
41192
41193  if test "x$ENDIAN" = xuniversal_endianness; then
41194    as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
41195  fi
41196  if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
41197    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
41198  fi
41199
41200
41201# Configure flags for the tools
41202
41203  ###############################################################################
41204  #
41205  # How to compile shared libraries.
41206  #
41207
41208  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41209    PICFLAG="-fPIC"
41210    C_FLAG_REORDER=''
41211    CXX_FLAG_REORDER=''
41212
41213    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41214      # Linking is different on MacOSX
41215      SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41216      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41217      SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41218      SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41219      SET_SHARED_LIBRARY_MAPFILE=''
41220    else
41221      # Default works for linux, might work on other platforms as well.
41222      SHARED_LIBRARY_FLAGS='-shared'
41223      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41224      SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41225      SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41226      SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41227    fi
41228  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41229    PICFLAG="-KPIC"
41230    C_FLAG_REORDER='-xF'
41231    CXX_FLAG_REORDER='-xF'
41232    SHARED_LIBRARY_FLAGS="-G"
41233    SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1'
41234    SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41235    SET_SHARED_LIBRARY_NAME=''
41236    SET_SHARED_LIBRARY_MAPFILE='-M$1'
41237  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41238    PICFLAG="-qpic=large"
41239    C_FLAG_REORDER=''
41240    CXX_FLAG_REORDER=''
41241    SHARED_LIBRARY_FLAGS="-qmkshrobj"
41242    SET_EXECUTABLE_ORIGIN=""
41243    SET_SHARED_LIBRARY_ORIGIN=''
41244    SET_SHARED_LIBRARY_NAME=''
41245    SET_SHARED_LIBRARY_MAPFILE=''
41246  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41247    PICFLAG=""
41248    C_FLAG_REORDER=''
41249    CXX_FLAG_REORDER=''
41250    SHARED_LIBRARY_FLAGS="-LD"
41251    SET_EXECUTABLE_ORIGIN=''
41252    SET_SHARED_LIBRARY_ORIGIN=''
41253    SET_SHARED_LIBRARY_NAME=''
41254    SET_SHARED_LIBRARY_MAPFILE=''
41255  fi
41256
41257
41258
41259
41260
41261
41262
41263
41264
41265  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41266    CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
41267    CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
41268    CFLAGS_JDKLIB_EXTRA='-xstrconst'
41269  fi
41270  # The (cross) compiler is now configured, we can now test capabilities
41271  # of the target platform.
41272
41273
41274
41275  ###############################################################################
41276  #
41277  # Setup the opt flags for different compilers
41278  # and different operating systems.
41279  #
41280
41281  # FIXME: this was indirectly the old default, but just inherited.
41282  # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41283  #   C_FLAG_DEPS="-MMD -MF"
41284  # fi
41285
41286  # Generate make dependency files
41287  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41288    C_FLAG_DEPS="-MMD -MF"
41289  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41290    C_FLAG_DEPS="-xMMD -xMF"
41291  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41292    C_FLAG_DEPS="-qmakedep=gcc -MF"
41293  fi
41294  CXX_FLAG_DEPS="$C_FLAG_DEPS"
41295
41296
41297
41298  # Debug symbols
41299  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41300    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
41301      CFLAGS_DEBUG_SYMBOLS="-g1"
41302      CXXFLAGS_DEBUG_SYMBOLS="-g1"
41303    else
41304      CFLAGS_DEBUG_SYMBOLS="-g"
41305      CXXFLAGS_DEBUG_SYMBOLS="-g"
41306    fi
41307  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41308    CFLAGS_DEBUG_SYMBOLS="-g -xs"
41309    CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
41310  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41311    CFLAGS_DEBUG_SYMBOLS="-g"
41312    CXXFLAGS_DEBUG_SYMBOLS="-g"
41313  fi
41314
41315
41316
41317  # Optimization levels
41318  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41319    CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xalias_level=basic -xbuiltin=%all -xdepend -xrestrict -xlibmil"
41320
41321    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
41322      # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global?
41323      C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr"
41324      C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
41325      C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
41326      C_O_FLAG_NONE="-xregs=no%frameptr"
41327      CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
41328      CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
41329      CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
41330      CXX_O_FLAG_NONE="-xregs=no%frameptr"
41331      if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41332        C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
41333        CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
41334      fi
41335    elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41336      C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41337      C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41338      C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41339      C_O_FLAG_NONE=""
41340      CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41341      CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41342      CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41343      CXX_O_FLAG_NONE=""
41344    fi
41345  else
41346    # The remaining toolchains share opt flags between CC and CXX;
41347    # setup for C and duplicate afterwards.
41348    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41349      if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41350        # On MacOSX we optimize for size, something
41351        # we should do for all platforms?
41352        C_O_FLAG_HIGHEST="-Os"
41353        C_O_FLAG_HI="-Os"
41354        C_O_FLAG_NORM="-Os"
41355        C_O_FLAG_NONE=""
41356      else
41357        C_O_FLAG_HIGHEST="-O3"
41358        C_O_FLAG_HI="-O3"
41359        C_O_FLAG_NORM="-O2"
41360        C_O_FLAG_NONE="-O0"
41361      fi
41362    elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41363      C_O_FLAG_HIGHEST="-O3"
41364      C_O_FLAG_HI="-O3 -qstrict"
41365      C_O_FLAG_NORM="-O2"
41366      C_O_FLAG_NONE=""
41367    elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41368      C_O_FLAG_HIGHEST="-O2"
41369      C_O_FLAG_HI="-O1"
41370      C_O_FLAG_NORM="-O1"
41371      C_O_FLAG_NONE="-Od"
41372    fi
41373    CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
41374    CXX_O_FLAG_HI="$C_O_FLAG_HI"
41375    CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41376    CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41377  fi
41378
41379
41380
41381
41382
41383
41384
41385
41386
41387
41388
41389  # Special extras...
41390  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41391    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41392      CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41393      CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41394    fi
41395  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41396    LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
41397    CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41398    CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41399  fi
41400
41401  if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
41402    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
41403$as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
41404  fi
41405
41406  if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
41407    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
41408$as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
41409  fi
41410
41411  if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
41412    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
41413$as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
41414  fi
41415
41416
41417# Check whether --with-extra-cflags was given.
41418if test "${with_extra_cflags+set}" = set; then :
41419  withval=$with_extra_cflags;
41420fi
41421
41422
41423
41424# Check whether --with-extra-cxxflags was given.
41425if test "${with_extra_cxxflags+set}" = set; then :
41426  withval=$with_extra_cxxflags;
41427fi
41428
41429
41430
41431# Check whether --with-extra-ldflags was given.
41432if test "${with_extra_ldflags+set}" = set; then :
41433  withval=$with_extra_ldflags;
41434fi
41435
41436
41437  CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41438  CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41439  LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41440
41441  # Hotspot needs these set in their legacy form
41442  LEGACY_EXTRA_CFLAGS=$with_extra_cflags
41443  LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags
41444  LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags
41445
41446
41447
41448
41449
41450  ###############################################################################
41451  #
41452  # Now setup the CFLAGS and LDFLAGS for the JDK build.
41453  # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41454  #
41455
41456  # Setup compiler/platform specific flags to CFLAGS_JDK,
41457  # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41458  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41459    # these options are used for both C and C++ compiles
41460    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41461        -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41462    case $OPENJDK_TARGET_CPU_ARCH in
41463      arm )
41464        # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
41465        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41466        ;;
41467      ppc )
41468        # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing
41469        ;;
41470      * )
41471        CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer"
41472        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41473        ;;
41474    esac
41475  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41476    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
41477    if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
41478      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
41479      CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
41480    fi
41481
41482    CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
41483    CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
41484  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41485    CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41486    CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41487  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41488    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
41489    -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
41490    -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
41491    -DWIN32 -DIAL"
41492    if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
41493      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64"
41494    else
41495      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86"
41496    fi
41497  fi
41498
41499  ###############################################################################
41500
41501  # Adjust flags according to debug level.
41502  case $DEBUG_LEVEL in
41503    fastdebug )
41504      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41505      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41506      C_O_FLAG_HI="$C_O_FLAG_NORM"
41507      C_O_FLAG_NORM="$C_O_FLAG_NORM"
41508      CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
41509      CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM"
41510      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41511      ;;
41512    slowdebug )
41513      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41514      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41515      C_O_FLAG_HI="$C_O_FLAG_NONE"
41516      C_O_FLAG_NORM="$C_O_FLAG_NONE"
41517      CXX_O_FLAG_HI="$CXX_O_FLAG_NONE"
41518      CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE"
41519      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41520      ;;
41521  esac
41522
41523  # Setup LP64
41524  CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41525
41526  # Set some common defines. These works for all compilers, but assume
41527  # -D is universally accepted.
41528
41529  # Setup endianness
41530  if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41531    # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41532    #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41533    #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41534    #   Note: -Dmacro         is the same as    #define macro 1
41535    #         -Dmacro=        is the same as    #define macro
41536    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41537      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41538    else
41539      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41540    fi
41541  else
41542    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41543  fi
41544
41545  # Setup target OS define. Use OS target name but in upper case.
41546  OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41547  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41548
41549  # Setup target CPU
41550  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41551
41552  # Setup debug/release defines
41553  if test "x$DEBUG_LEVEL" = xrelease; then
41554    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41555    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41556      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41557    fi
41558  else
41559    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41560  fi
41561
41562  # Setup release name
41563  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
41564
41565
41566  # Set some additional per-OS defines.
41567  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41568    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
41569  elif test "x$OPENJDK_TARGET_OS" = xaix; then
41570    # FIXME: PPC64 should not be here.
41571    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DPPC64"
41572  elif test "x$OPENJDK_TARGET_OS" = xbsd; then
41573    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
41574  fi
41575
41576  # Additional macosx handling
41577  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41578    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41579      # FIXME: This needs to be exported in spec.gmk due to closed legacy code.
41580      # FIXME: clean this up, and/or move it elsewhere.
41581
41582      # Setting these parameters makes it an error to link to macosx APIs that are
41583      # newer than the given OS version and makes the linked binaries compatible
41584      # even if built on a newer version of the OS.
41585      # The expected format is X.Y.Z
41586      MACOSX_VERSION_MIN=10.7.0
41587
41588
41589      # The macro takes the version with no dots, ex: 1070
41590      # Let the flags variables get resolved in make for easier override on make
41591      # command line.
41592      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41593      LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41594    fi
41595  fi
41596
41597  # Setup some hard coded includes
41598  CCXXFLAGS_JDK="$CCXXFLAGS_JDK \
41599      -I${JDK_OUTPUTDIR}/include \
41600      -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \
41601      -I${JDK_TOPDIR}/src/share/javavm/export \
41602      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_EXPORT_DIR/javavm/export \
41603      -I${JDK_TOPDIR}/src/share/native/common \
41604      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common"
41605
41606  # The shared libraries are compiled using the picflag.
41607  CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
41608  CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
41609
41610  # Executable flags
41611  CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK"
41612  CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK"
41613
41614
41615
41616
41617
41618
41619  # Setup LDFLAGS et al.
41620  #
41621  # Now this is odd. The JDK native libraries have to link against libjvm.so
41622  # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
41623  # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
41624  # is identical for client and server? Yes. Which is picked at runtime (client or server)?
41625  # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
41626  # libraries will link to whatever is in memory. Yuck.
41627  #
41628  # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
41629  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41630    LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
41631    if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41632      LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
41633    fi
41634    # TODO: make -debug optional "--disable-full-debug-symbols"
41635    LDFLAGS_JDK="$LDFLAGS_JDK -debug"
41636    LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib"
41637    LDFLAGS_JDKLIB_SUFFIX=""
41638    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
41639      LDFLAGS_STACK_SIZE=1048576
41640    else
41641      LDFLAGS_STACK_SIZE=327680
41642    fi
41643    LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE"
41644  else
41645    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41646      # If this is a --hash-style=gnu system, use --hash-style=both, why?
41647      # We have previously set HAS_GNU_HASH if this is the case
41648      if test -n "$HAS_GNU_HASH"; then
41649        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both "
41650      fi
41651      if test "x$OPENJDK_TARGET_OS" = xlinux; then
41652        # And since we now know that the linker is gnu, then add -z defs, to forbid
41653        # undefined symbols in object files.
41654        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
41655        if test "x$DEBUG_LEVEL" = "xrelease"; then
41656          # When building release libraries, tell the linker optimize them.
41657          # Should this be supplied to the OSS linker as well?
41658          LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
41659        fi
41660      fi
41661    fi
41662
41663    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41664      LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
41665      LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
41666    fi
41667
41668    LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \
41669        -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
41670
41671    # On some platforms (mac) the linker warns about non existing -L dirs.
41672    # Add server first if available. Linking aginst client does not always produce the same results.
41673    # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
41674    # Default to server for other variants.
41675    if test "x$JVM_VARIANT_SERVER" = xtrue; then
41676      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41677    elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
41678      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
41679    elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
41680      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
41681    else
41682      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41683    fi
41684
41685    LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
41686    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41687      LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
41688    fi
41689
41690    LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
41691    if test "x$OPENJDK_TARGET_OS" = xlinux; then
41692      LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
41693    fi
41694  fi
41695
41696
41697
41698
41699
41700
41701
41702
41703  # Some Zero and Shark settings.
41704  # ZERO_ARCHFLAG tells the compiler which mode to build for
41705  case "${OPENJDK_TARGET_CPU}" in
41706    s390)
41707      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
41708      ;;
41709    *)
41710      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41711  esac
41712
41713  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
41714$as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
41715  supports=yes
41716
41717  saved_cflags="$CFLAGS"
41718  CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
41719  ac_ext=c
41720ac_cpp='$CPP $CPPFLAGS'
41721ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41722ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41723ac_compiler_gnu=$ac_cv_c_compiler_gnu
41724
41725  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41726/* end confdefs.h.  */
41727int i;
41728_ACEOF
41729if ac_fn_c_try_compile "$LINENO"; then :
41730
41731else
41732  supports=no
41733fi
41734rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41735  ac_ext=cpp
41736ac_cpp='$CXXCPP $CPPFLAGS'
41737ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41738ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41739ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41740
41741  CFLAGS="$saved_cflags"
41742
41743  saved_cxxflags="$CXXFLAGS"
41744  CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
41745  ac_ext=cpp
41746ac_cpp='$CXXCPP $CPPFLAGS'
41747ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41748ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41749ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41750
41751  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41752/* end confdefs.h.  */
41753int i;
41754_ACEOF
41755if ac_fn_cxx_try_compile "$LINENO"; then :
41756
41757else
41758  supports=no
41759fi
41760rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41761  ac_ext=cpp
41762ac_cpp='$CXXCPP $CPPFLAGS'
41763ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41764ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41765ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41766
41767  CXXFLAGS="$saved_cxxflags"
41768
41769  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41770$as_echo "$supports" >&6; }
41771  if test "x$supports" = "xyes" ; then
41772    :
41773  else
41774    ZERO_ARCHFLAG=""
41775  fi
41776
41777
41778
41779  # Check that the compiler supports -mX (or -qX on AIX) flags
41780  # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
41781
41782  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
41783$as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
41784  supports=yes
41785
41786  saved_cflags="$CFLAGS"
41787  CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41788  ac_ext=c
41789ac_cpp='$CPP $CPPFLAGS'
41790ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41791ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41792ac_compiler_gnu=$ac_cv_c_compiler_gnu
41793
41794  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41795/* end confdefs.h.  */
41796int i;
41797_ACEOF
41798if ac_fn_c_try_compile "$LINENO"; then :
41799
41800else
41801  supports=no
41802fi
41803rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41804  ac_ext=cpp
41805ac_cpp='$CXXCPP $CPPFLAGS'
41806ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41807ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41808ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41809
41810  CFLAGS="$saved_cflags"
41811
41812  saved_cxxflags="$CXXFLAGS"
41813  CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41814  ac_ext=cpp
41815ac_cpp='$CXXCPP $CPPFLAGS'
41816ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41817ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41818ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41819
41820  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41821/* end confdefs.h.  */
41822int i;
41823_ACEOF
41824if ac_fn_cxx_try_compile "$LINENO"; then :
41825
41826else
41827  supports=no
41828fi
41829rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41830  ac_ext=cpp
41831ac_cpp='$CXXCPP $CPPFLAGS'
41832ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41833ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41834ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41835
41836  CXXFLAGS="$saved_cxxflags"
41837
41838  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41839$as_echo "$supports" >&6; }
41840  if test "x$supports" = "xyes" ; then
41841    COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
41842  else
41843    COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
41844  fi
41845
41846
41847
41848
41849# Setup debug symbols (need objcopy from the toolchain for that)
41850
41851  #
41852  # ENABLE_DEBUG_SYMBOLS
41853  # This must be done after the toolchain is setup, since we're looking at objcopy.
41854  #
41855  # Check whether --enable-debug-symbols was given.
41856if test "${enable_debug_symbols+set}" = set; then :
41857  enableval=$enable_debug_symbols;
41858fi
41859
41860
41861  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
41862$as_echo_n "checking if we should generate debug symbols... " >&6; }
41863
41864  if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
41865    # explicit enabling of enable-debug-symbols and can't find objcopy
41866    #   this is an error
41867    as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
41868  fi
41869
41870  if test "x$enable_debug_symbols" = "xyes"; then
41871    ENABLE_DEBUG_SYMBOLS=true
41872  elif test "x$enable_debug_symbols" = "xno"; then
41873    ENABLE_DEBUG_SYMBOLS=false
41874  else
41875    # Default is on if objcopy is found
41876    if test "x$OBJCOPY" != x; then
41877      ENABLE_DEBUG_SYMBOLS=true
41878    # MacOS X and Windows don't use objcopy but default is on for those OSes
41879    elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
41880      ENABLE_DEBUG_SYMBOLS=true
41881    else
41882      ENABLE_DEBUG_SYMBOLS=false
41883    fi
41884  fi
41885
41886  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
41887$as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
41888
41889  #
41890  # ZIP_DEBUGINFO_FILES
41891  #
41892  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
41893$as_echo_n "checking if we should zip debug-info files... " >&6; }
41894  # Check whether --enable-zip-debug-info was given.
41895if test "${enable_zip_debug_info+set}" = set; then :
41896  enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
41897else
41898  enable_zip_debug_info="yes"
41899fi
41900
41901  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
41902$as_echo "${enable_zip_debug_info}" >&6; }
41903
41904  if test "x${enable_zip_debug_info}" = "xno"; then
41905    ZIP_DEBUGINFO_FILES=false
41906  else
41907    ZIP_DEBUGINFO_FILES=true
41908  fi
41909
41910
41911
41912
41913
41914###############################################################################
41915#
41916# Check dependencies for external and internal libraries.
41917#
41918###############################################################################
41919
41920# After we have toolchain, we can compile fixpath. It's needed by the lib checks.
41921
41922  # When using cygwin or msys, we need a wrapper binary that renames
41923  # /cygdrive/c/ arguments into c:/ arguments and peeks into
41924  # @files and rewrites these too! This wrapper binary is
41925  # called fixpath.
41926  FIXPATH=
41927  if test "x$OPENJDK_BUILD_OS" = xwindows; then
41928    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
41929$as_echo_n "checking if fixpath can be created... " >&6; }
41930    FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
41931    FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
41932    if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
41933      FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
41934      FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
41935      # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
41936      FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
41937    elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
41938      FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
41939      FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
41940
41941      # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
41942      # @ was chosen as separator to minimize risk of other tools messing around with it
41943      all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
41944      fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
41945
41946      FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
41947    fi
41948    rm -f $OUTPUT_ROOT/fixpath*
41949    cd $OUTPUT_ROOT
41950    $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
41951    cd $CURDIR
41952
41953    if test ! -x $OUTPUT_ROOT/fixpath.exe; then
41954      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41955$as_echo "no" >&6; }
41956      cat $OUTPUT_ROOT/fixpath1.log
41957      as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
41958    fi
41959    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41960$as_echo "yes" >&6; }
41961    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
41962$as_echo_n "checking if fixpath.exe works... " >&6; }
41963    cd $OUTPUT_ROOT
41964    $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
41965    cd $CURDIR
41966    if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
41967      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41968$as_echo "no" >&6; }
41969      cat $OUTPUT_ROOT/fixpath2.log
41970      as_fn_error $? "fixpath did not work!" "$LINENO" 5
41971    fi
41972    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41973$as_echo "yes" >&6; }
41974    rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
41975  fi
41976
41977
41978
41979
41980
41981
41982  ###############################################################################
41983  #
41984  # OS specific settings that we never will need to probe.
41985  #
41986  if test "x$OPENJDK_TARGET_OS" = xlinux; then
41987    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
41988$as_echo_n "checking what is not needed on Linux?... " >&6; }
41989    PULSE_NOT_NEEDED=yes
41990    { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
41991$as_echo "pulse" >&6; }
41992  fi
41993
41994  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41995    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
41996$as_echo_n "checking what is not needed on Solaris?... " >&6; }
41997    ALSA_NOT_NEEDED=yes
41998    PULSE_NOT_NEEDED=yes
41999    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42000$as_echo "alsa pulse" >&6; }
42001  fi
42002
42003  if test "x$OPENJDK_TARGET_OS" = xaix; then
42004    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
42005$as_echo_n "checking what is not needed on AIX?... " >&6; }
42006    ALSA_NOT_NEEDED=yes
42007    PULSE_NOT_NEEDED=yes
42008    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42009$as_echo "alsa pulse" >&6; }
42010  fi
42011
42012
42013  if test "x$OPENJDK_TARGET_OS" = xwindows; then
42014    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
42015$as_echo_n "checking what is not needed on Windows?... " >&6; }
42016    CUPS_NOT_NEEDED=yes
42017    ALSA_NOT_NEEDED=yes
42018    PULSE_NOT_NEEDED=yes
42019    X11_NOT_NEEDED=yes
42020    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
42021$as_echo "alsa cups pulse x11" >&6; }
42022  fi
42023
42024  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42025    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
42026$as_echo_n "checking what is not needed on MacOSX?... " >&6; }
42027    ALSA_NOT_NEEDED=yes
42028    PULSE_NOT_NEEDED=yes
42029    X11_NOT_NEEDED=yes
42030    # If the java runtime framework is disabled, then we need X11.
42031    # This will be adjusted below.
42032    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
42033$as_echo "alsa pulse x11" >&6; }
42034  fi
42035
42036  if test "x$OPENJDK_TARGET_OS" = xbsd; then
42037    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
42038$as_echo_n "checking what is not needed on bsd?... " >&6; }
42039    ALSA_NOT_NEEDED=yes
42040    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
42041$as_echo "alsa" >&6; }
42042  fi
42043
42044  if test "x$OPENJDK" = "xfalse"; then
42045    FREETYPE_NOT_NEEDED=yes
42046  fi
42047
42048  if test "x$SUPPORT_HEADFUL" = xno; then
42049    X11_NOT_NEEDED=yes
42050  fi
42051
42052  ###############################################################################
42053  #
42054  # Check for MacOSX support for OpenJDK.
42055  #
42056
42057
42058  # Check whether --enable-macosx-runtime-support was given.
42059if test "${enable_macosx_runtime_support+set}" = set; then :
42060  enableval=$enable_macosx_runtime_support;
42061fi
42062
42063  if test "x$enable_macosx_runtime_support" != x; then
42064    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&5
42065$as_echo "$as_me: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&2;}
42066  fi
42067
42068
42069  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42070$as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42071  if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42072    { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42073$as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42074  else
42075    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42076$as_echo "no" >&6; }
42077  fi
42078
42079
42080
42081  ###############################################################################
42082  #
42083  # Check for X Windows
42084  #
42085
42086  # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42087  # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42088  # --x-libraries for the sysroot, if that seems to be correct.
42089  if test "x$SYS_ROOT" != "x/"; then
42090    if test "x$x_includes" = xNONE; then
42091      if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then
42092        x_includes="$SYS_ROOT/usr/X11R6/include"
42093      elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then
42094        x_includes="$SYS_ROOT/usr/include"
42095      fi
42096    fi
42097    if test "x$x_libraries" = xNONE; then
42098      if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then
42099        x_libraries="$SYS_ROOT/usr/X11R6/lib"
42100      elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42101        x_libraries="$SYS_ROOT/usr/lib64"
42102      elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then
42103        x_libraries="$SYS_ROOT/usr/lib"
42104      fi
42105    fi
42106  fi
42107
42108  # Now let autoconf do it's magic
42109  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42110$as_echo_n "checking for X... " >&6; }
42111
42112
42113# Check whether --with-x was given.
42114if test "${with_x+set}" = set; then :
42115  withval=$with_x;
42116fi
42117
42118# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42119if test "x$with_x" = xno; then
42120  # The user explicitly disabled X.
42121  have_x=disabled
42122else
42123  case $x_includes,$x_libraries in #(
42124    *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
42125    *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
42126  $as_echo_n "(cached) " >&6
42127else
42128  # One or both of the vars are not set, and there is no cached value.
42129ac_x_includes=no ac_x_libraries=no
42130rm -f -r conftest.dir
42131if mkdir conftest.dir; then
42132  cd conftest.dir
42133  cat >Imakefile <<'_ACEOF'
42134incroot:
42135	@echo incroot='${INCROOT}'
42136usrlibdir:
42137	@echo usrlibdir='${USRLIBDIR}'
42138libdir:
42139	@echo libdir='${LIBDIR}'
42140_ACEOF
42141  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
42142    # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
42143    for ac_var in incroot usrlibdir libdir; do
42144      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
42145    done
42146    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
42147    for ac_extension in a so sl dylib la dll; do
42148      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
42149	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
42150	ac_im_usrlibdir=$ac_im_libdir; break
42151      fi
42152    done
42153    # Screen out bogus values from the imake configuration.  They are
42154    # bogus both because they are the default anyway, and because
42155    # using them would break gcc on systems where it needs fixed includes.
42156    case $ac_im_incroot in
42157	/usr/include) ac_x_includes= ;;
42158	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
42159    esac
42160    case $ac_im_usrlibdir in
42161	/usr/lib | /usr/lib64 | /lib | /lib64) ;;
42162	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
42163    esac
42164  fi
42165  cd ..
42166  rm -f -r conftest.dir
42167fi
42168
42169# Standard set of common directories for X headers.
42170# Check X11 before X11Rn because it is often a symlink to the current release.
42171ac_x_header_dirs='
42172/usr/X11/include
42173/usr/X11R7/include
42174/usr/X11R6/include
42175/usr/X11R5/include
42176/usr/X11R4/include
42177
42178/usr/include/X11
42179/usr/include/X11R7
42180/usr/include/X11R6
42181/usr/include/X11R5
42182/usr/include/X11R4
42183
42184/usr/local/X11/include
42185/usr/local/X11R7/include
42186/usr/local/X11R6/include
42187/usr/local/X11R5/include
42188/usr/local/X11R4/include
42189
42190/usr/local/include/X11
42191/usr/local/include/X11R7
42192/usr/local/include/X11R6
42193/usr/local/include/X11R5
42194/usr/local/include/X11R4
42195
42196/usr/X386/include
42197/usr/x386/include
42198/usr/XFree86/include/X11
42199
42200/usr/include
42201/usr/local/include
42202/usr/unsupported/include
42203/usr/athena/include
42204/usr/local/x11r5/include
42205/usr/lpp/Xamples/include
42206
42207/usr/openwin/include
42208/usr/openwin/share/include'
42209
42210if test "$ac_x_includes" = no; then
42211  # Guess where to find include files, by looking for Xlib.h.
42212  # First, try using that file with no special directory specified.
42213  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42214/* end confdefs.h.  */
42215#include <X11/Xlib.h>
42216_ACEOF
42217if ac_fn_cxx_try_cpp "$LINENO"; then :
42218  # We can compile using X headers with no special include directory.
42219ac_x_includes=
42220else
42221  for ac_dir in $ac_x_header_dirs; do
42222  if test -r "$ac_dir/X11/Xlib.h"; then
42223    ac_x_includes=$ac_dir
42224    break
42225  fi
42226done
42227fi
42228rm -f conftest.err conftest.i conftest.$ac_ext
42229fi # $ac_x_includes = no
42230
42231if test "$ac_x_libraries" = no; then
42232  # Check for the libraries.
42233  # See if we find them without any special options.
42234  # Don't add to $LIBS permanently.
42235  ac_save_LIBS=$LIBS
42236  LIBS="-lX11 $LIBS"
42237  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42238/* end confdefs.h.  */
42239#include <X11/Xlib.h>
42240int
42241main ()
42242{
42243XrmInitialize ()
42244  ;
42245  return 0;
42246}
42247_ACEOF
42248if ac_fn_cxx_try_link "$LINENO"; then :
42249  LIBS=$ac_save_LIBS
42250# We can link X programs with no special library path.
42251ac_x_libraries=
42252else
42253  LIBS=$ac_save_LIBS
42254for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
42255do
42256  # Don't even attempt the hair of trying to link an X program!
42257  for ac_extension in a so sl dylib la dll; do
42258    if test -r "$ac_dir/libX11.$ac_extension"; then
42259      ac_x_libraries=$ac_dir
42260      break 2
42261    fi
42262  done
42263done
42264fi
42265rm -f core conftest.err conftest.$ac_objext \
42266    conftest$ac_exeext conftest.$ac_ext
42267fi # $ac_x_libraries = no
42268
42269case $ac_x_includes,$ac_x_libraries in #(
42270  no,* | *,no | *\'*)
42271    # Didn't find X, or a directory has "'" in its name.
42272    ac_cv_have_x="have_x=no";; #(
42273  *)
42274    # Record where we found X for the cache.
42275    ac_cv_have_x="have_x=yes\
42276	ac_x_includes='$ac_x_includes'\
42277	ac_x_libraries='$ac_x_libraries'"
42278esac
42279fi
42280;; #(
42281    *) have_x=yes;;
42282  esac
42283  eval "$ac_cv_have_x"
42284fi # $with_x != no
42285
42286if test "$have_x" != yes; then
42287  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
42288$as_echo "$have_x" >&6; }
42289  no_x=yes
42290else
42291  # If each of the values was on the command line, it overrides each guess.
42292  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
42293  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
42294  # Update the cache value to reflect the command line values.
42295  ac_cv_have_x="have_x=yes\
42296	ac_x_includes='$x_includes'\
42297	ac_x_libraries='$x_libraries'"
42298  { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
42299$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
42300fi
42301
42302  if test "$no_x" = yes; then
42303  # Not all programs may use this symbol, but it does not hurt to define it.
42304
42305$as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
42306
42307  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
42308else
42309  if test -n "$x_includes"; then
42310    X_CFLAGS="$X_CFLAGS -I$x_includes"
42311  fi
42312
42313  # It would also be nice to do this for all -L options, not just this one.
42314  if test -n "$x_libraries"; then
42315    X_LIBS="$X_LIBS -L$x_libraries"
42316    # For Solaris; some versions of Sun CC require a space after -R and
42317    # others require no space.  Words are not sufficient . . . .
42318    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
42319$as_echo_n "checking whether -R must be followed by a space... " >&6; }
42320    ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
42321    ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
42322    ac_cxx_werror_flag=yes
42323    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42324/* end confdefs.h.  */
42325
42326int
42327main ()
42328{
42329
42330  ;
42331  return 0;
42332}
42333_ACEOF
42334if ac_fn_cxx_try_link "$LINENO"; then :
42335  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42336$as_echo "no" >&6; }
42337       X_LIBS="$X_LIBS -R$x_libraries"
42338else
42339  LIBS="$ac_xsave_LIBS -R $x_libraries"
42340       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42341/* end confdefs.h.  */
42342
42343int
42344main ()
42345{
42346
42347  ;
42348  return 0;
42349}
42350_ACEOF
42351if ac_fn_cxx_try_link "$LINENO"; then :
42352  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42353$as_echo "yes" >&6; }
42354	  X_LIBS="$X_LIBS -R $x_libraries"
42355else
42356  { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
42357$as_echo "neither works" >&6; }
42358fi
42359rm -f core conftest.err conftest.$ac_objext \
42360    conftest$ac_exeext conftest.$ac_ext
42361fi
42362rm -f core conftest.err conftest.$ac_objext \
42363    conftest$ac_exeext conftest.$ac_ext
42364    ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
42365    LIBS=$ac_xsave_LIBS
42366  fi
42367
42368  # Check for system-dependent libraries X programs must link with.
42369  # Do this before checking for the system-independent R6 libraries
42370  # (-lICE), since we may need -lsocket or whatever for X linking.
42371
42372  if test "$ISC" = yes; then
42373    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
42374  else
42375    # Martyn Johnson says this is needed for Ultrix, if the X
42376    # libraries were built with DECnet support.  And Karl Berry says
42377    # the Alpha needs dnet_stub (dnet does not exist).
42378    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
42379    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42380/* end confdefs.h.  */
42381
42382/* Override any GCC internal prototype to avoid an error.
42383   Use char because int might match the return type of a GCC
42384   builtin and then its argument prototype would still apply.  */
42385#ifdef __cplusplus
42386extern "C"
42387#endif
42388char XOpenDisplay ();
42389int
42390main ()
42391{
42392return XOpenDisplay ();
42393  ;
42394  return 0;
42395}
42396_ACEOF
42397if ac_fn_cxx_try_link "$LINENO"; then :
42398
42399else
42400  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
42401$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
42402if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
42403  $as_echo_n "(cached) " >&6
42404else
42405  ac_check_lib_save_LIBS=$LIBS
42406LIBS="-ldnet  $LIBS"
42407cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42408/* end confdefs.h.  */
42409
42410/* Override any GCC internal prototype to avoid an error.
42411   Use char because int might match the return type of a GCC
42412   builtin and then its argument prototype would still apply.  */
42413#ifdef __cplusplus
42414extern "C"
42415#endif
42416char dnet_ntoa ();
42417int
42418main ()
42419{
42420return dnet_ntoa ();
42421  ;
42422  return 0;
42423}
42424_ACEOF
42425if ac_fn_cxx_try_link "$LINENO"; then :
42426  ac_cv_lib_dnet_dnet_ntoa=yes
42427else
42428  ac_cv_lib_dnet_dnet_ntoa=no
42429fi
42430rm -f core conftest.err conftest.$ac_objext \
42431    conftest$ac_exeext conftest.$ac_ext
42432LIBS=$ac_check_lib_save_LIBS
42433fi
42434{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
42435$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
42436if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
42437  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
42438fi
42439
42440    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
42441      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
42442$as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
42443if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
42444  $as_echo_n "(cached) " >&6
42445else
42446  ac_check_lib_save_LIBS=$LIBS
42447LIBS="-ldnet_stub  $LIBS"
42448cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42449/* end confdefs.h.  */
42450
42451/* Override any GCC internal prototype to avoid an error.
42452   Use char because int might match the return type of a GCC
42453   builtin and then its argument prototype would still apply.  */
42454#ifdef __cplusplus
42455extern "C"
42456#endif
42457char dnet_ntoa ();
42458int
42459main ()
42460{
42461return dnet_ntoa ();
42462  ;
42463  return 0;
42464}
42465_ACEOF
42466if ac_fn_cxx_try_link "$LINENO"; then :
42467  ac_cv_lib_dnet_stub_dnet_ntoa=yes
42468else
42469  ac_cv_lib_dnet_stub_dnet_ntoa=no
42470fi
42471rm -f core conftest.err conftest.$ac_objext \
42472    conftest$ac_exeext conftest.$ac_ext
42473LIBS=$ac_check_lib_save_LIBS
42474fi
42475{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
42476$as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
42477if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
42478  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
42479fi
42480
42481    fi
42482fi
42483rm -f core conftest.err conftest.$ac_objext \
42484    conftest$ac_exeext conftest.$ac_ext
42485    LIBS="$ac_xsave_LIBS"
42486
42487    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
42488    # to get the SysV transport functions.
42489    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
42490    # needs -lnsl.
42491    # The nsl library prevents programs from opening the X display
42492    # on Irix 5.2, according to T.E. Dickey.
42493    # The functions gethostbyname, getservbyname, and inet_addr are
42494    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
42495    ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
42496if test "x$ac_cv_func_gethostbyname" = xyes; then :
42497
42498fi
42499
42500    if test $ac_cv_func_gethostbyname = no; then
42501      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
42502$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
42503if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
42504  $as_echo_n "(cached) " >&6
42505else
42506  ac_check_lib_save_LIBS=$LIBS
42507LIBS="-lnsl  $LIBS"
42508cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42509/* end confdefs.h.  */
42510
42511/* Override any GCC internal prototype to avoid an error.
42512   Use char because int might match the return type of a GCC
42513   builtin and then its argument prototype would still apply.  */
42514#ifdef __cplusplus
42515extern "C"
42516#endif
42517char gethostbyname ();
42518int
42519main ()
42520{
42521return gethostbyname ();
42522  ;
42523  return 0;
42524}
42525_ACEOF
42526if ac_fn_cxx_try_link "$LINENO"; then :
42527  ac_cv_lib_nsl_gethostbyname=yes
42528else
42529  ac_cv_lib_nsl_gethostbyname=no
42530fi
42531rm -f core conftest.err conftest.$ac_objext \
42532    conftest$ac_exeext conftest.$ac_ext
42533LIBS=$ac_check_lib_save_LIBS
42534fi
42535{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
42536$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
42537if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
42538  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
42539fi
42540
42541      if test $ac_cv_lib_nsl_gethostbyname = no; then
42542	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
42543$as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
42544if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
42545  $as_echo_n "(cached) " >&6
42546else
42547  ac_check_lib_save_LIBS=$LIBS
42548LIBS="-lbsd  $LIBS"
42549cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42550/* end confdefs.h.  */
42551
42552/* Override any GCC internal prototype to avoid an error.
42553   Use char because int might match the return type of a GCC
42554   builtin and then its argument prototype would still apply.  */
42555#ifdef __cplusplus
42556extern "C"
42557#endif
42558char gethostbyname ();
42559int
42560main ()
42561{
42562return gethostbyname ();
42563  ;
42564  return 0;
42565}
42566_ACEOF
42567if ac_fn_cxx_try_link "$LINENO"; then :
42568  ac_cv_lib_bsd_gethostbyname=yes
42569else
42570  ac_cv_lib_bsd_gethostbyname=no
42571fi
42572rm -f core conftest.err conftest.$ac_objext \
42573    conftest$ac_exeext conftest.$ac_ext
42574LIBS=$ac_check_lib_save_LIBS
42575fi
42576{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
42577$as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
42578if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
42579  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
42580fi
42581
42582      fi
42583    fi
42584
42585    # lieder@skyler.mavd.honeywell.com says without -lsocket,
42586    # socket/setsockopt and other routines are undefined under SCO ODT
42587    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
42588    # on later versions), says Simon Leinen: it contains gethostby*
42589    # variants that don't use the name server (or something).  -lsocket
42590    # must be given before -lnsl if both are needed.  We assume that
42591    # if connect needs -lnsl, so does gethostbyname.
42592    ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
42593if test "x$ac_cv_func_connect" = xyes; then :
42594
42595fi
42596
42597    if test $ac_cv_func_connect = no; then
42598      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
42599$as_echo_n "checking for connect in -lsocket... " >&6; }
42600if ${ac_cv_lib_socket_connect+:} false; then :
42601  $as_echo_n "(cached) " >&6
42602else
42603  ac_check_lib_save_LIBS=$LIBS
42604LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
42605cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42606/* end confdefs.h.  */
42607
42608/* Override any GCC internal prototype to avoid an error.
42609   Use char because int might match the return type of a GCC
42610   builtin and then its argument prototype would still apply.  */
42611#ifdef __cplusplus
42612extern "C"
42613#endif
42614char connect ();
42615int
42616main ()
42617{
42618return connect ();
42619  ;
42620  return 0;
42621}
42622_ACEOF
42623if ac_fn_cxx_try_link "$LINENO"; then :
42624  ac_cv_lib_socket_connect=yes
42625else
42626  ac_cv_lib_socket_connect=no
42627fi
42628rm -f core conftest.err conftest.$ac_objext \
42629    conftest$ac_exeext conftest.$ac_ext
42630LIBS=$ac_check_lib_save_LIBS
42631fi
42632{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
42633$as_echo "$ac_cv_lib_socket_connect" >&6; }
42634if test "x$ac_cv_lib_socket_connect" = xyes; then :
42635  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
42636fi
42637
42638    fi
42639
42640    # Guillermo Gomez says -lposix is necessary on A/UX.
42641    ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
42642if test "x$ac_cv_func_remove" = xyes; then :
42643
42644fi
42645
42646    if test $ac_cv_func_remove = no; then
42647      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
42648$as_echo_n "checking for remove in -lposix... " >&6; }
42649if ${ac_cv_lib_posix_remove+:} false; then :
42650  $as_echo_n "(cached) " >&6
42651else
42652  ac_check_lib_save_LIBS=$LIBS
42653LIBS="-lposix  $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 remove ();
42664int
42665main ()
42666{
42667return remove ();
42668  ;
42669  return 0;
42670}
42671_ACEOF
42672if ac_fn_cxx_try_link "$LINENO"; then :
42673  ac_cv_lib_posix_remove=yes
42674else
42675  ac_cv_lib_posix_remove=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_posix_remove" >&5
42682$as_echo "$ac_cv_lib_posix_remove" >&6; }
42683if test "x$ac_cv_lib_posix_remove" = xyes; then :
42684  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
42685fi
42686
42687    fi
42688
42689    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
42690    ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
42691if test "x$ac_cv_func_shmat" = xyes; then :
42692
42693fi
42694
42695    if test $ac_cv_func_shmat = no; then
42696      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
42697$as_echo_n "checking for shmat in -lipc... " >&6; }
42698if ${ac_cv_lib_ipc_shmat+:} false; then :
42699  $as_echo_n "(cached) " >&6
42700else
42701  ac_check_lib_save_LIBS=$LIBS
42702LIBS="-lipc  $LIBS"
42703cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42704/* end confdefs.h.  */
42705
42706/* Override any GCC internal prototype to avoid an error.
42707   Use char because int might match the return type of a GCC
42708   builtin and then its argument prototype would still apply.  */
42709#ifdef __cplusplus
42710extern "C"
42711#endif
42712char shmat ();
42713int
42714main ()
42715{
42716return shmat ();
42717  ;
42718  return 0;
42719}
42720_ACEOF
42721if ac_fn_cxx_try_link "$LINENO"; then :
42722  ac_cv_lib_ipc_shmat=yes
42723else
42724  ac_cv_lib_ipc_shmat=no
42725fi
42726rm -f core conftest.err conftest.$ac_objext \
42727    conftest$ac_exeext conftest.$ac_ext
42728LIBS=$ac_check_lib_save_LIBS
42729fi
42730{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
42731$as_echo "$ac_cv_lib_ipc_shmat" >&6; }
42732if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
42733  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
42734fi
42735
42736    fi
42737  fi
42738
42739  # Check for libraries that X11R6 Xt/Xaw programs need.
42740  ac_save_LDFLAGS=$LDFLAGS
42741  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
42742  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
42743  # check for ICE first), but we must link in the order -lSM -lICE or
42744  # we get undefined symbols.  So assume we have SM if we have ICE.
42745  # These have to be linked with before -lX11, unlike the other
42746  # libraries we check for below, so use a different variable.
42747  # John Interrante, Karl Berry
42748  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
42749$as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
42750if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
42751  $as_echo_n "(cached) " >&6
42752else
42753  ac_check_lib_save_LIBS=$LIBS
42754LIBS="-lICE $X_EXTRA_LIBS $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 IceConnectionNumber ();
42765int
42766main ()
42767{
42768return IceConnectionNumber ();
42769  ;
42770  return 0;
42771}
42772_ACEOF
42773if ac_fn_cxx_try_link "$LINENO"; then :
42774  ac_cv_lib_ICE_IceConnectionNumber=yes
42775else
42776  ac_cv_lib_ICE_IceConnectionNumber=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_ICE_IceConnectionNumber" >&5
42783$as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
42784if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
42785  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
42786fi
42787
42788  LDFLAGS=$ac_save_LDFLAGS
42789
42790fi
42791
42792
42793  # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
42794  # this doesn't make sense so we remove it.
42795  if test "x$COMPILE_TYPE" = xcross; then
42796    X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
42797  fi
42798
42799  if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then
42800
42801  # Print a helpful message on how to acquire the necessary build dependency.
42802  # x11 is the help tag: freetype, cups, pulse, alsa etc
42803  MISSING_DEPENDENCY=x11
42804
42805  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42806    cygwin_help $MISSING_DEPENDENCY
42807  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42808    msys_help $MISSING_DEPENDENCY
42809  else
42810    PKGHANDLER_COMMAND=
42811
42812    case $PKGHANDLER in
42813      apt-get)
42814        apt_help     $MISSING_DEPENDENCY ;;
42815      yum)
42816        yum_help     $MISSING_DEPENDENCY ;;
42817      port)
42818        port_help    $MISSING_DEPENDENCY ;;
42819      pkgutil)
42820        pkgutil_help $MISSING_DEPENDENCY ;;
42821      pkgadd)
42822        pkgadd_help  $MISSING_DEPENDENCY ;;
42823    esac
42824
42825    if test "x$PKGHANDLER_COMMAND" != x; then
42826      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42827    fi
42828  fi
42829
42830    as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
42831  fi
42832
42833  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42834    OPENWIN_HOME="/usr/openwin"
42835  fi
42836
42837
42838
42839  #
42840  # Weird Sol10 something check...TODO change to try compile
42841  #
42842  if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
42843    if test "`uname -r`" = "5.10"; then
42844      if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
42845        X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
42846      fi
42847    fi
42848  fi
42849
42850  ac_ext=c
42851ac_cpp='$CPP $CPPFLAGS'
42852ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42853ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42854ac_compiler_gnu=$ac_cv_c_compiler_gnu
42855
42856  OLD_CFLAGS="$CFLAGS"
42857  CFLAGS="$CFLAGS $X_CFLAGS"
42858
42859  # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
42860  for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
42861do :
42862  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
42863ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
42864        # include <X11/Xlib.h>
42865        # include <X11/Xutil.h>
42866
42867
42868"
42869if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
42870  cat >>confdefs.h <<_ACEOF
42871#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
42872_ACEOF
42873 X11_A_OK=yes
42874else
42875  X11_A_OK=no; break
42876fi
42877
42878done
42879
42880
42881  CFLAGS="$OLD_CFLAGS"
42882  ac_ext=cpp
42883ac_cpp='$CXXCPP $CPPFLAGS'
42884ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42885ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42886ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42887
42888
42889  if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then
42890
42891  # Print a helpful message on how to acquire the necessary build dependency.
42892  # x11 is the help tag: freetype, cups, pulse, alsa etc
42893  MISSING_DEPENDENCY=x11
42894
42895  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42896    cygwin_help $MISSING_DEPENDENCY
42897  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42898    msys_help $MISSING_DEPENDENCY
42899  else
42900    PKGHANDLER_COMMAND=
42901
42902    case $PKGHANDLER in
42903      apt-get)
42904        apt_help     $MISSING_DEPENDENCY ;;
42905      yum)
42906        yum_help     $MISSING_DEPENDENCY ;;
42907      port)
42908        port_help    $MISSING_DEPENDENCY ;;
42909      pkgutil)
42910        pkgutil_help $MISSING_DEPENDENCY ;;
42911      pkgadd)
42912        pkgadd_help  $MISSING_DEPENDENCY ;;
42913    esac
42914
42915    if test "x$PKGHANDLER_COMMAND" != x; then
42916      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42917    fi
42918  fi
42919
42920    as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
42921  fi
42922
42923
42924
42925
42926
42927
42928  ###############################################################################
42929  #
42930  # The common unix printing system cups is used to print from java.
42931  #
42932
42933# Check whether --with-cups was given.
42934if test "${with_cups+set}" = set; then :
42935  withval=$with_cups;
42936fi
42937
42938
42939# Check whether --with-cups-include was given.
42940if test "${with_cups_include+set}" = set; then :
42941  withval=$with_cups_include;
42942fi
42943
42944
42945  if test "x$CUPS_NOT_NEEDED" = xyes; then
42946    if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
42947      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
42948$as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
42949    fi
42950    CUPS_CFLAGS=
42951  else
42952    CUPS_FOUND=no
42953
42954    if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
42955      as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
42956    fi
42957
42958    if test "x${with_cups}" != x; then
42959      CUPS_CFLAGS="-I${with_cups}/include"
42960      CUPS_FOUND=yes
42961    fi
42962    if test "x${with_cups_include}" != x; then
42963      CUPS_CFLAGS="-I${with_cups_include}"
42964      CUPS_FOUND=yes
42965    fi
42966    if test "x$CUPS_FOUND" = xno; then
42967
42968
42969  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
42970    # Source the builddeps file again, to make sure it uses the latest variables!
42971    . $builddepsfile
42972    # Look for a target and build machine specific resource!
42973    eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
42974    if test "x$resource" = x; then
42975      # Ok, lets instead look for a target specific resource
42976      eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
42977    fi
42978    if test "x$resource" = x; then
42979      # Ok, lets instead look for a build specific resource
42980      eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
42981    fi
42982    if test "x$resource" = x; then
42983      # Ok, lets instead look for a generic resource
42984      # (The cups comes from M4 and not the shell, thus no need for eval here.)
42985      resource=${builddep_cups}
42986    fi
42987    if test "x$resource" != x; then
42988      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
42989$as_echo "$as_me: Using builddeps $resource for cups" >&6;}
42990      # If the resource in the builddeps.conf file is an existing directory,
42991      # for example /java/linux/cups
42992      if test -d ${resource}; then
42993        depdir=${resource}
42994      else
42995
42996  # cups is for example mymodule
42997  # $resource is for example libs/general/libmymod_1_2_3.zip
42998  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
42999  # $with_builddeps_dir is for example /localhome/builddeps
43000  # depdir is the name of the variable into which we store the depdir, eg MYMOD
43001  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43002  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43003  filename=`basename $resource`
43004  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43005  filebase=${filename%%.*}
43006  extension=${filename#*.}
43007  installdir=$with_builddeps_dir/$filebase
43008  if test ! -f $installdir/$filename.unpacked; then
43009    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
43010$as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43011    if test ! -d $installdir; then
43012      mkdir -p $installdir
43013    fi
43014    if test ! -d $installdir; then
43015      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43016    fi
43017    tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
43018    touch $tmpfile
43019    if test ! -f $tmpfile; then
43020      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43021    fi
43022
43023  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43024  # $tmpfile is the local file name for the downloaded file.
43025  VALID_TOOL=no
43026  if test "x$BDEPS_FTP" = xwget; then
43027    VALID_TOOL=yes
43028    wget -O $tmpfile $with_builddeps_server/$resource
43029  fi
43030  if test "x$BDEPS_FTP" = xlftp; then
43031    VALID_TOOL=yes
43032    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43033  fi
43034  if test "x$BDEPS_FTP" = xftp; then
43035    VALID_TOOL=yes
43036    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43037    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43038    FTPUSERPWD=${FTPSERVER%%@*}
43039    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43040      FTPUSER=${userpwd%%:*}
43041      FTPPWD=${userpwd#*@}
43042      FTPSERVER=${FTPSERVER#*@}
43043    else
43044      FTPUSER=ftp
43045      FTPPWD=ftp
43046    fi
43047    # the "pass" command does not work on some
43048    # ftp clients (read ftp.exe) but if it works,
43049    # passive mode is better!
43050    ( \
43051        echo "user $FTPUSER $FTPPWD"        ; \
43052        echo "pass"                         ; \
43053        echo "bin"                          ; \
43054        echo "get $FTPPATH $tmpfile"              ; \
43055    ) | ftp -in $FTPSERVER
43056  fi
43057  if test "x$VALID_TOOL" != xyes; then
43058    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43059  fi
43060
43061    mv $tmpfile $installdir/$filename
43062    if test ! -s $installdir/$filename; then
43063      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43064    fi
43065    case "$extension" in
43066      zip)  echo "Unzipping $installdir/$filename..."
43067        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43068        ;;
43069      tar.gz) echo "Untaring $installdir/$filename..."
43070        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43071        ;;
43072      tgz) echo "Untaring $installdir/$filename..."
43073        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43074        ;;
43075      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43076        ;;
43077    esac
43078  fi
43079  if test -f $installdir/$filename.unpacked; then
43080    depdir=$installdir
43081  fi
43082
43083      fi
43084      # Source the builddeps file again, because in the previous command, the depdir
43085      # was updated to point at the current build dependency install directory.
43086      . $builddepsfile
43087      # Now extract variables from the builddeps.conf files.
43088      theroot=${builddep_cups_ROOT}
43089      thecflags=${builddep_cups_CFLAGS}
43090      thelibs=${builddep_cups_LIBS}
43091      if test "x$depdir" = x; then
43092        as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
43093      fi
43094      CUPS=$depdir
43095      if test "x$theroot" != x; then
43096        CUPS="$theroot"
43097      fi
43098      if test "x$thecflags" != x; then
43099        CUPS_CFLAGS="$thecflags"
43100      fi
43101      if test "x$thelibs" != x; then
43102        CUPS_LIBS="$thelibs"
43103      fi
43104      CUPS_FOUND=yes
43105
43106    fi
43107
43108  fi
43109
43110    fi
43111    if test "x$CUPS_FOUND" = xno; then
43112      # Are the cups headers installed in the default /usr/include location?
43113      for ac_header in cups/cups.h cups/ppd.h
43114do :
43115  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43116ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
43117if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43118  cat >>confdefs.h <<_ACEOF
43119#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43120_ACEOF
43121
43122            CUPS_FOUND=yes
43123            CUPS_CFLAGS=
43124            DEFAULT_CUPS=yes
43125
43126
43127fi
43128
43129done
43130
43131    fi
43132    if test "x$CUPS_FOUND" = xno; then
43133      # Getting nervous now? Lets poke around for standard Solaris third-party
43134      # package installation locations.
43135      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43136$as_echo_n "checking for cups headers... " >&6; }
43137      if test -s /opt/sfw/cups/include/cups/cups.h; then
43138        # An SFW package seems to be installed!
43139        CUPS_FOUND=yes
43140        CUPS_CFLAGS="-I/opt/sfw/cups/include"
43141      elif test -s /opt/csw/include/cups/cups.h; then
43142        # A CSW package seems to be installed!
43143        CUPS_FOUND=yes
43144        CUPS_CFLAGS="-I/opt/csw/include"
43145      fi
43146      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43147$as_echo "$CUPS_FOUND" >&6; }
43148    fi
43149    if test "x$CUPS_FOUND" = xno; then
43150
43151  # Print a helpful message on how to acquire the necessary build dependency.
43152  # cups is the help tag: freetype, cups, pulse, alsa etc
43153  MISSING_DEPENDENCY=cups
43154
43155  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43156    cygwin_help $MISSING_DEPENDENCY
43157  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43158    msys_help $MISSING_DEPENDENCY
43159  else
43160    PKGHANDLER_COMMAND=
43161
43162    case $PKGHANDLER in
43163      apt-get)
43164        apt_help     $MISSING_DEPENDENCY ;;
43165      yum)
43166        yum_help     $MISSING_DEPENDENCY ;;
43167      port)
43168        port_help    $MISSING_DEPENDENCY ;;
43169      pkgutil)
43170        pkgutil_help $MISSING_DEPENDENCY ;;
43171      pkgadd)
43172        pkgadd_help  $MISSING_DEPENDENCY ;;
43173    esac
43174
43175    if test "x$PKGHANDLER_COMMAND" != x; then
43176      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43177    fi
43178  fi
43179
43180      as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
43181    fi
43182  fi
43183
43184
43185
43186
43187
43188
43189  ###############################################################################
43190  #
43191  # The ubiquitous freetype library is used to render fonts.
43192  #
43193
43194# Check whether --with-freetype was given.
43195if test "${with_freetype+set}" = set; then :
43196  withval=$with_freetype;
43197fi
43198
43199
43200# Check whether --with-freetype-include was given.
43201if test "${with_freetype_include+set}" = set; then :
43202  withval=$with_freetype_include;
43203fi
43204
43205
43206# Check whether --with-freetype-lib was given.
43207if test "${with_freetype_lib+set}" = set; then :
43208  withval=$with_freetype_lib;
43209fi
43210
43211  # Check whether --enable-freetype-bundling was given.
43212if test "${enable_freetype_bundling+set}" = set; then :
43213  enableval=$enable_freetype_bundling;
43214fi
43215
43216
43217  FREETYPE_CFLAGS=
43218  FREETYPE_LIBS=
43219  FREETYPE_BUNDLE_LIB_PATH=
43220
43221  if test "x$FREETYPE_NOT_NEEDED" = xyes; then
43222    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43223      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
43224$as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
43225    fi
43226    if test "x$enable_freetype_bundling" != x; then
43227      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
43228$as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
43229    fi
43230  else
43231    # freetype is needed to build; go get it!
43232
43233    BUNDLE_FREETYPE="$enable_freetype_bundling"
43234
43235    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43236      # User has specified settings
43237
43238      if test "x$BUNDLE_FREETYPE" = x; then
43239        # If not specified, default is to bundle freetype
43240        BUNDLE_FREETYPE=yes
43241      fi
43242
43243      if test "x$with_freetype" != x; then
43244        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
43245        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
43246      fi
43247
43248      # Allow --with-freetype-lib and --with-freetype-include to override
43249      if test "x$with_freetype_include" != x; then
43250        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
43251      fi
43252      if test "x$with_freetype_lib" != x; then
43253        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
43254      fi
43255
43256      if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
43257        # Okay, we got it. Check that it works.
43258
43259  POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43260  POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43261  METHOD="--with-freetype"
43262
43263  # First check if the files exists.
43264  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43265    # We found an arbitrary include file. That's a good sign.
43266    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43267$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43268    FOUND_FREETYPE=yes
43269
43270    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43271    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43272      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43273$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43274      FOUND_FREETYPE=no
43275    else
43276      if test "x$OPENJDK_TARGET_OS" = xwindows; then
43277        # On Windows, we will need both .lib and .dll file.
43278        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43279          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43280$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43281          FOUND_FREETYPE=no
43282        fi
43283      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
43284        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43285        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43286      fi
43287    fi
43288  fi
43289
43290  if test "x$FOUND_FREETYPE" = xyes; then
43291
43292  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43293
43294  # Input might be given as Windows format, start by converting to
43295  # unix format.
43296  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43297  new_path=`$CYGPATH -u "$path"`
43298
43299  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43300  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43301  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43302  # "foo.exe" is OK but "foo" is an error.
43303  #
43304  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43305  # It is also a way to make sure we got the proper file name for the real test later on.
43306  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43307  if test "x$test_shortpath" = x; then
43308    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43309$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43310    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43311  fi
43312
43313  # Call helper function which possibly converts this using DOS-style short mode.
43314  # If so, the updated path is stored in $new_path.
43315
43316  input_path="$new_path"
43317  # Check if we need to convert this using DOS-style short mode. If the path
43318  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43319  # take no chances and rewrite it.
43320  # Note: m4 eats our [], so we need to use [ and ] instead.
43321  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43322  if test "x$has_forbidden_chars" != x; then
43323    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43324    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43325    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43326    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43327      # Going to short mode and back again did indeed matter. Since short mode is
43328      # case insensitive, let's make it lowercase to improve readability.
43329      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43330      # Now convert it back to Unix-stile (cygpath)
43331      input_path=`$CYGPATH -u "$shortmode_path"`
43332      new_path="$input_path"
43333    fi
43334  fi
43335
43336  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43337  if test "x$test_cygdrive_prefix" = x; then
43338    # As a simple fix, exclude /usr/bin since it's not a real path.
43339    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43340      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43341      # a path prefixed by /cygdrive for fixpath to work.
43342      new_path="$CYGWIN_ROOT_PATH$input_path"
43343    fi
43344  fi
43345
43346
43347  if test "x$path" != "x$new_path"; then
43348    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43349    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43350$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43351  fi
43352
43353  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43354
43355  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43356  has_colon=`$ECHO $path | $GREP ^.:`
43357  new_path="$path"
43358  if test "x$has_colon" = x; then
43359    # Not in mixed or Windows style, start by that.
43360    new_path=`cmd //c echo $path`
43361  fi
43362
43363
43364  input_path="$new_path"
43365  # Check if we need to convert this using DOS-style short mode. If the path
43366  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43367  # take no chances and rewrite it.
43368  # Note: m4 eats our [], so we need to use [ and ] instead.
43369  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43370  if test "x$has_forbidden_chars" != x; then
43371    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43372    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43373  fi
43374
43375
43376  windows_path="$new_path"
43377  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43378    unix_path=`$CYGPATH -u "$windows_path"`
43379    new_path="$unix_path"
43380  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43381    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43382    new_path="$unix_path"
43383  fi
43384
43385  if test "x$path" != "x$new_path"; then
43386    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43387    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43388$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43389  fi
43390
43391  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43392  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43393
43394  else
43395    # We're on a posix platform. Hooray! :)
43396    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43397    has_space=`$ECHO "$path" | $GREP " "`
43398    if test "x$has_space" != x; then
43399      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43400$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43401      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43402    fi
43403
43404    # Use eval to expand a potential ~
43405    eval path="$path"
43406    if test ! -f "$path" && test ! -d "$path"; then
43407      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43408    fi
43409
43410    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43411  fi
43412
43413
43414  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43415
43416  # Input might be given as Windows format, start by converting to
43417  # unix format.
43418  path="$POTENTIAL_FREETYPE_LIB_PATH"
43419  new_path=`$CYGPATH -u "$path"`
43420
43421  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43422  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43423  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43424  # "foo.exe" is OK but "foo" is an error.
43425  #
43426  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43427  # It is also a way to make sure we got the proper file name for the real test later on.
43428  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43429  if test "x$test_shortpath" = x; then
43430    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43431$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43432    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
43433  fi
43434
43435  # Call helper function which possibly converts this using DOS-style short mode.
43436  # If so, the updated path is stored in $new_path.
43437
43438  input_path="$new_path"
43439  # Check if we need to convert this using DOS-style short mode. If the path
43440  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43441  # take no chances and rewrite it.
43442  # Note: m4 eats our [], so we need to use [ and ] instead.
43443  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43444  if test "x$has_forbidden_chars" != x; then
43445    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43446    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43447    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43448    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43449      # Going to short mode and back again did indeed matter. Since short mode is
43450      # case insensitive, let's make it lowercase to improve readability.
43451      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43452      # Now convert it back to Unix-stile (cygpath)
43453      input_path=`$CYGPATH -u "$shortmode_path"`
43454      new_path="$input_path"
43455    fi
43456  fi
43457
43458  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43459  if test "x$test_cygdrive_prefix" = x; then
43460    # As a simple fix, exclude /usr/bin since it's not a real path.
43461    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43462      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43463      # a path prefixed by /cygdrive for fixpath to work.
43464      new_path="$CYGWIN_ROOT_PATH$input_path"
43465    fi
43466  fi
43467
43468
43469  if test "x$path" != "x$new_path"; then
43470    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43471    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43472$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43473  fi
43474
43475  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43476
43477  path="$POTENTIAL_FREETYPE_LIB_PATH"
43478  has_colon=`$ECHO $path | $GREP ^.:`
43479  new_path="$path"
43480  if test "x$has_colon" = x; then
43481    # Not in mixed or Windows style, start by that.
43482    new_path=`cmd //c echo $path`
43483  fi
43484
43485
43486  input_path="$new_path"
43487  # Check if we need to convert this using DOS-style short mode. If the path
43488  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43489  # take no chances and rewrite it.
43490  # Note: m4 eats our [], so we need to use [ and ] instead.
43491  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43492  if test "x$has_forbidden_chars" != x; then
43493    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43494    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43495  fi
43496
43497
43498  windows_path="$new_path"
43499  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43500    unix_path=`$CYGPATH -u "$windows_path"`
43501    new_path="$unix_path"
43502  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43503    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43504    new_path="$unix_path"
43505  fi
43506
43507  if test "x$path" != "x$new_path"; then
43508    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43509    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43510$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43511  fi
43512
43513  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43514  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43515
43516  else
43517    # We're on a posix platform. Hooray! :)
43518    path="$POTENTIAL_FREETYPE_LIB_PATH"
43519    has_space=`$ECHO "$path" | $GREP " "`
43520    if test "x$has_space" != x; then
43521      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43522$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43523      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43524    fi
43525
43526    # Use eval to expand a potential ~
43527    eval path="$path"
43528    if test ! -f "$path" && test ! -d "$path"; then
43529      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43530    fi
43531
43532    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
43533  fi
43534
43535
43536    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43537    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
43538$as_echo_n "checking for freetype includes... " >&6; }
43539    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
43540$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
43541    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43542    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
43543$as_echo_n "checking for freetype libraries... " >&6; }
43544    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
43545$as_echo "$FREETYPE_LIB_PATH" >&6; }
43546  fi
43547
43548        if test "x$FOUND_FREETYPE" != xyes; then
43549          as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
43550        fi
43551      else
43552        # User specified only one of lib or include. This is an error.
43553        if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
43554          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
43555$as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
43556          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43557        else
43558          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
43559$as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
43560          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43561        fi
43562      fi
43563    else
43564      # User did not specify settings, but we need freetype. Try to locate it.
43565
43566      if test "x$BUNDLE_FREETYPE" = x; then
43567        # If not specified, default is to bundle freetype only on windows
43568        if test "x$OPENJDK_TARGET_OS" = xwindows; then
43569          BUNDLE_FREETYPE=yes
43570        else
43571          BUNDLE_FREETYPE=no
43572        fi
43573      fi
43574
43575      if test "x$FOUND_FREETYPE" != xyes; then
43576        # Check builddeps
43577
43578
43579  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43580    # Source the builddeps file again, to make sure it uses the latest variables!
43581    . $builddepsfile
43582    # Look for a target and build machine specific resource!
43583    eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43584    if test "x$resource" = x; then
43585      # Ok, lets instead look for a target specific resource
43586      eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
43587    fi
43588    if test "x$resource" = x; then
43589      # Ok, lets instead look for a build specific resource
43590      eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
43591    fi
43592    if test "x$resource" = x; then
43593      # Ok, lets instead look for a generic resource
43594      # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
43595      resource=${builddep_freetype2}
43596    fi
43597    if test "x$resource" != x; then
43598      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
43599$as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
43600      # If the resource in the builddeps.conf file is an existing directory,
43601      # for example /java/linux/cups
43602      if test -d ${resource}; then
43603        depdir=${resource}
43604      else
43605
43606  # freetype2 is for example mymodule
43607  # $resource is for example libs/general/libmymod_1_2_3.zip
43608  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43609  # $with_builddeps_dir is for example /localhome/builddeps
43610  # depdir is the name of the variable into which we store the depdir, eg MYMOD
43611  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43612  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43613  filename=`basename $resource`
43614  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43615  filebase=${filename%%.*}
43616  extension=${filename#*.}
43617  installdir=$with_builddeps_dir/$filebase
43618  if test ! -f $installdir/$filename.unpacked; then
43619    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
43620$as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43621    if test ! -d $installdir; then
43622      mkdir -p $installdir
43623    fi
43624    if test ! -d $installdir; then
43625      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43626    fi
43627    tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
43628    touch $tmpfile
43629    if test ! -f $tmpfile; then
43630      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43631    fi
43632
43633  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43634  # $tmpfile is the local file name for the downloaded file.
43635  VALID_TOOL=no
43636  if test "x$BDEPS_FTP" = xwget; then
43637    VALID_TOOL=yes
43638    wget -O $tmpfile $with_builddeps_server/$resource
43639  fi
43640  if test "x$BDEPS_FTP" = xlftp; then
43641    VALID_TOOL=yes
43642    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43643  fi
43644  if test "x$BDEPS_FTP" = xftp; then
43645    VALID_TOOL=yes
43646    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43647    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43648    FTPUSERPWD=${FTPSERVER%%@*}
43649    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43650      FTPUSER=${userpwd%%:*}
43651      FTPPWD=${userpwd#*@}
43652      FTPSERVER=${FTPSERVER#*@}
43653    else
43654      FTPUSER=ftp
43655      FTPPWD=ftp
43656    fi
43657    # the "pass" command does not work on some
43658    # ftp clients (read ftp.exe) but if it works,
43659    # passive mode is better!
43660    ( \
43661        echo "user $FTPUSER $FTPPWD"        ; \
43662        echo "pass"                         ; \
43663        echo "bin"                          ; \
43664        echo "get $FTPPATH $tmpfile"              ; \
43665    ) | ftp -in $FTPSERVER
43666  fi
43667  if test "x$VALID_TOOL" != xyes; then
43668    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43669  fi
43670
43671    mv $tmpfile $installdir/$filename
43672    if test ! -s $installdir/$filename; then
43673      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43674    fi
43675    case "$extension" in
43676      zip)  echo "Unzipping $installdir/$filename..."
43677        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43678        ;;
43679      tar.gz) echo "Untaring $installdir/$filename..."
43680        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43681        ;;
43682      tgz) echo "Untaring $installdir/$filename..."
43683        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43684        ;;
43685      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43686        ;;
43687    esac
43688  fi
43689  if test -f $installdir/$filename.unpacked; then
43690    depdir=$installdir
43691  fi
43692
43693      fi
43694      # Source the builddeps file again, because in the previous command, the depdir
43695      # was updated to point at the current build dependency install directory.
43696      . $builddepsfile
43697      # Now extract variables from the builddeps.conf files.
43698      theroot=${builddep_freetype2_ROOT}
43699      thecflags=${builddep_freetype2_CFLAGS}
43700      thelibs=${builddep_freetype2_LIBS}
43701      if test "x$depdir" = x; then
43702        as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
43703      fi
43704      FREETYPE=$depdir
43705      if test "x$theroot" != x; then
43706        FREETYPE="$theroot"
43707      fi
43708      if test "x$thecflags" != x; then
43709        FREETYPE_CFLAGS="$thecflags"
43710      fi
43711      if test "x$thelibs" != x; then
43712        FREETYPE_LIBS="$thelibs"
43713      fi
43714      FOUND_FREETYPE=yes
43715      else FOUND_FREETYPE=no
43716
43717    fi
43718    else FOUND_FREETYPE=no
43719
43720  fi
43721
43722        # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43723        if test "x$FOUND_FREETYPE" = xyes; then
43724          if test "x$BUNDLE_FREETYPE" = xyes; then
43725            { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43726$as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43727            FOUND_FREETYPE=no
43728          else
43729            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43730$as_echo_n "checking for freetype... " >&6; }
43731            { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43732$as_echo "yes (using builddeps)" >&6; }
43733          fi
43734        fi
43735      fi
43736
43737      if test "x$FOUND_FREETYPE" != xyes; then
43738        # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43739        if test "x$PKG_CONFIG" != x; then
43740
43741pkg_failed=no
43742{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43743$as_echo_n "checking for FREETYPE... " >&6; }
43744
43745if test -n "$FREETYPE_CFLAGS"; then
43746    pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43747 elif test -n "$PKG_CONFIG"; then
43748    if test -n "$PKG_CONFIG" && \
43749    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43750  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43751  ac_status=$?
43752  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43753  test $ac_status = 0; }; then
43754  pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43755else
43756  pkg_failed=yes
43757fi
43758 else
43759    pkg_failed=untried
43760fi
43761if test -n "$FREETYPE_LIBS"; then
43762    pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
43763 elif test -n "$PKG_CONFIG"; then
43764    if test -n "$PKG_CONFIG" && \
43765    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43766  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43767  ac_status=$?
43768  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43769  test $ac_status = 0; }; then
43770  pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
43771else
43772  pkg_failed=yes
43773fi
43774 else
43775    pkg_failed=untried
43776fi
43777
43778
43779
43780if test $pkg_failed = yes; then
43781
43782if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
43783        _pkg_short_errors_supported=yes
43784else
43785        _pkg_short_errors_supported=no
43786fi
43787        if test $_pkg_short_errors_supported = yes; then
43788	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
43789        else
43790	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
43791        fi
43792	# Put the nasty error message in config.log where it belongs
43793	echo "$FREETYPE_PKG_ERRORS" >&5
43794
43795	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43796$as_echo "no" >&6; }
43797                FOUND_FREETYPE=no
43798elif test $pkg_failed = untried; then
43799	FOUND_FREETYPE=no
43800else
43801	FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
43802	FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
43803        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43804$as_echo "yes" >&6; }
43805	FOUND_FREETYPE=yes
43806fi
43807          if test "x$FOUND_FREETYPE" = xyes; then
43808            # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
43809            FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
43810            # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
43811            if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
43812              FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
43813            fi
43814            # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43815            if test "x$BUNDLE_FREETYPE" = xyes; then
43816              { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
43817$as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
43818              FOUND_FREETYPE=no
43819            else
43820              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43821$as_echo_n "checking for freetype... " >&6; }
43822              { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
43823$as_echo "yes (using pkg-config)" >&6; }
43824            fi
43825          fi
43826        fi
43827      fi
43828
43829      if test "x$FOUND_FREETYPE" != xyes; then
43830        # Check in well-known locations
43831        if test "x$OPENJDK_TARGET_OS" = xwindows; then
43832          FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
43833
43834  windows_path="$FREETYPE_BASE_DIR"
43835  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43836    unix_path=`$CYGPATH -u "$windows_path"`
43837    FREETYPE_BASE_DIR="$unix_path"
43838  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43839    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43840    FREETYPE_BASE_DIR="$unix_path"
43841  fi
43842
43843
43844  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
43845  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
43846  METHOD="well-known location"
43847
43848  # First check if the files exists.
43849  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43850    # We found an arbitrary include file. That's a good sign.
43851    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43852$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43853    FOUND_FREETYPE=yes
43854
43855    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43856    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43857      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43858$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43859      FOUND_FREETYPE=no
43860    else
43861      if test "x$OPENJDK_TARGET_OS" = xwindows; then
43862        # On Windows, we will need both .lib and .dll file.
43863        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43864          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43865$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43866          FOUND_FREETYPE=no
43867        fi
43868      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
43869        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43870        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43871      fi
43872    fi
43873  fi
43874
43875  if test "x$FOUND_FREETYPE" = xyes; then
43876
43877  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43878
43879  # Input might be given as Windows format, start by converting to
43880  # unix format.
43881  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43882  new_path=`$CYGPATH -u "$path"`
43883
43884  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43885  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43886  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43887  # "foo.exe" is OK but "foo" is an error.
43888  #
43889  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43890  # It is also a way to make sure we got the proper file name for the real test later on.
43891  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43892  if test "x$test_shortpath" = x; then
43893    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43894$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43895    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43896  fi
43897
43898  # Call helper function which possibly converts this using DOS-style short mode.
43899  # If so, the updated path is stored in $new_path.
43900
43901  input_path="$new_path"
43902  # Check if we need to convert this using DOS-style short mode. If the path
43903  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43904  # take no chances and rewrite it.
43905  # Note: m4 eats our [], so we need to use [ and ] instead.
43906  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43907  if test "x$has_forbidden_chars" != x; then
43908    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43909    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43910    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43911    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43912      # Going to short mode and back again did indeed matter. Since short mode is
43913      # case insensitive, let's make it lowercase to improve readability.
43914      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43915      # Now convert it back to Unix-stile (cygpath)
43916      input_path=`$CYGPATH -u "$shortmode_path"`
43917      new_path="$input_path"
43918    fi
43919  fi
43920
43921  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43922  if test "x$test_cygdrive_prefix" = x; then
43923    # As a simple fix, exclude /usr/bin since it's not a real path.
43924    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43925      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43926      # a path prefixed by /cygdrive for fixpath to work.
43927      new_path="$CYGWIN_ROOT_PATH$input_path"
43928    fi
43929  fi
43930
43931
43932  if test "x$path" != "x$new_path"; then
43933    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43934    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43935$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43936  fi
43937
43938  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43939
43940  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43941  has_colon=`$ECHO $path | $GREP ^.:`
43942  new_path="$path"
43943  if test "x$has_colon" = x; then
43944    # Not in mixed or Windows style, start by that.
43945    new_path=`cmd //c echo $path`
43946  fi
43947
43948
43949  input_path="$new_path"
43950  # Check if we need to convert this using DOS-style short mode. If the path
43951  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43952  # take no chances and rewrite it.
43953  # Note: m4 eats our [], so we need to use [ and ] instead.
43954  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43955  if test "x$has_forbidden_chars" != x; then
43956    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43957    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43958  fi
43959
43960
43961  windows_path="$new_path"
43962  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43963    unix_path=`$CYGPATH -u "$windows_path"`
43964    new_path="$unix_path"
43965  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43966    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43967    new_path="$unix_path"
43968  fi
43969
43970  if test "x$path" != "x$new_path"; then
43971    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43972    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43973$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43974  fi
43975
43976  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43977  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43978
43979  else
43980    # We're on a posix platform. Hooray! :)
43981    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43982    has_space=`$ECHO "$path" | $GREP " "`
43983    if test "x$has_space" != x; then
43984      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43985$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43986      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43987    fi
43988
43989    # Use eval to expand a potential ~
43990    eval path="$path"
43991    if test ! -f "$path" && test ! -d "$path"; then
43992      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43993    fi
43994
43995    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43996  fi
43997
43998
43999  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44000
44001  # Input might be given as Windows format, start by converting to
44002  # unix format.
44003  path="$POTENTIAL_FREETYPE_LIB_PATH"
44004  new_path=`$CYGPATH -u "$path"`
44005
44006  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44007  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44008  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44009  # "foo.exe" is OK but "foo" is an error.
44010  #
44011  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44012  # It is also a way to make sure we got the proper file name for the real test later on.
44013  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44014  if test "x$test_shortpath" = x; then
44015    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44016$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44017    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44018  fi
44019
44020  # Call helper function which possibly converts this using DOS-style short mode.
44021  # If so, the updated path is stored in $new_path.
44022
44023  input_path="$new_path"
44024  # Check if we need to convert this using DOS-style short mode. If the path
44025  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44026  # take no chances and rewrite it.
44027  # Note: m4 eats our [], so we need to use [ and ] instead.
44028  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44029  if test "x$has_forbidden_chars" != x; then
44030    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44031    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44032    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44033    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44034      # Going to short mode and back again did indeed matter. Since short mode is
44035      # case insensitive, let's make it lowercase to improve readability.
44036      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44037      # Now convert it back to Unix-stile (cygpath)
44038      input_path=`$CYGPATH -u "$shortmode_path"`
44039      new_path="$input_path"
44040    fi
44041  fi
44042
44043  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44044  if test "x$test_cygdrive_prefix" = x; then
44045    # As a simple fix, exclude /usr/bin since it's not a real path.
44046    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44047      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44048      # a path prefixed by /cygdrive for fixpath to work.
44049      new_path="$CYGWIN_ROOT_PATH$input_path"
44050    fi
44051  fi
44052
44053
44054  if test "x$path" != "x$new_path"; then
44055    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44056    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44057$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44058  fi
44059
44060  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44061
44062  path="$POTENTIAL_FREETYPE_LIB_PATH"
44063  has_colon=`$ECHO $path | $GREP ^.:`
44064  new_path="$path"
44065  if test "x$has_colon" = x; then
44066    # Not in mixed or Windows style, start by that.
44067    new_path=`cmd //c echo $path`
44068  fi
44069
44070
44071  input_path="$new_path"
44072  # Check if we need to convert this using DOS-style short mode. If the path
44073  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44074  # take no chances and rewrite it.
44075  # Note: m4 eats our [], so we need to use [ and ] instead.
44076  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44077  if test "x$has_forbidden_chars" != x; then
44078    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44079    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44080  fi
44081
44082
44083  windows_path="$new_path"
44084  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44085    unix_path=`$CYGPATH -u "$windows_path"`
44086    new_path="$unix_path"
44087  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44088    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44089    new_path="$unix_path"
44090  fi
44091
44092  if test "x$path" != "x$new_path"; then
44093    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44094    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44095$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44096  fi
44097
44098  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44099  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44100
44101  else
44102    # We're on a posix platform. Hooray! :)
44103    path="$POTENTIAL_FREETYPE_LIB_PATH"
44104    has_space=`$ECHO "$path" | $GREP " "`
44105    if test "x$has_space" != x; then
44106      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44107$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44108      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44109    fi
44110
44111    # Use eval to expand a potential ~
44112    eval path="$path"
44113    if test ! -f "$path" && test ! -d "$path"; then
44114      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44115    fi
44116
44117    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44118  fi
44119
44120
44121    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44122    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44123$as_echo_n "checking for freetype includes... " >&6; }
44124    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44125$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44126    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44127    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44128$as_echo_n "checking for freetype libraries... " >&6; }
44129    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44130$as_echo "$FREETYPE_LIB_PATH" >&6; }
44131  fi
44132
44133          if test "x$FOUND_FREETYPE" != xyes; then
44134            FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
44135
44136  windows_path="$FREETYPE_BASE_DIR"
44137  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44138    unix_path=`$CYGPATH -u "$windows_path"`
44139    FREETYPE_BASE_DIR="$unix_path"
44140  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44141    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44142    FREETYPE_BASE_DIR="$unix_path"
44143  fi
44144
44145
44146  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44147  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44148  METHOD="well-known location"
44149
44150  # First check if the files exists.
44151  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44152    # We found an arbitrary include file. That's a good sign.
44153    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44154$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44155    FOUND_FREETYPE=yes
44156
44157    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44158    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44159      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44160$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44161      FOUND_FREETYPE=no
44162    else
44163      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44164        # On Windows, we will need both .lib and .dll file.
44165        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44166          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44167$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44168          FOUND_FREETYPE=no
44169        fi
44170      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
44171        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44172        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44173      fi
44174    fi
44175  fi
44176
44177  if test "x$FOUND_FREETYPE" = xyes; then
44178
44179  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44180
44181  # Input might be given as Windows format, start by converting to
44182  # unix format.
44183  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44184  new_path=`$CYGPATH -u "$path"`
44185
44186  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44187  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44188  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44189  # "foo.exe" is OK but "foo" is an error.
44190  #
44191  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44192  # It is also a way to make sure we got the proper file name for the real test later on.
44193  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44194  if test "x$test_shortpath" = x; then
44195    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44196$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44197    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44198  fi
44199
44200  # Call helper function which possibly converts this using DOS-style short mode.
44201  # If so, the updated path is stored in $new_path.
44202
44203  input_path="$new_path"
44204  # Check if we need to convert this using DOS-style short mode. If the path
44205  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44206  # take no chances and rewrite it.
44207  # Note: m4 eats our [], so we need to use [ and ] instead.
44208  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44209  if test "x$has_forbidden_chars" != x; then
44210    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44211    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44212    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44213    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44214      # Going to short mode and back again did indeed matter. Since short mode is
44215      # case insensitive, let's make it lowercase to improve readability.
44216      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44217      # Now convert it back to Unix-stile (cygpath)
44218      input_path=`$CYGPATH -u "$shortmode_path"`
44219      new_path="$input_path"
44220    fi
44221  fi
44222
44223  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44224  if test "x$test_cygdrive_prefix" = x; then
44225    # As a simple fix, exclude /usr/bin since it's not a real path.
44226    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44227      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44228      # a path prefixed by /cygdrive for fixpath to work.
44229      new_path="$CYGWIN_ROOT_PATH$input_path"
44230    fi
44231  fi
44232
44233
44234  if test "x$path" != "x$new_path"; then
44235    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44236    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44237$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44238  fi
44239
44240  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44241
44242  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44243  has_colon=`$ECHO $path | $GREP ^.:`
44244  new_path="$path"
44245  if test "x$has_colon" = x; then
44246    # Not in mixed or Windows style, start by that.
44247    new_path=`cmd //c echo $path`
44248  fi
44249
44250
44251  input_path="$new_path"
44252  # Check if we need to convert this using DOS-style short mode. If the path
44253  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44254  # take no chances and rewrite it.
44255  # Note: m4 eats our [], so we need to use [ and ] instead.
44256  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44257  if test "x$has_forbidden_chars" != x; then
44258    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44259    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44260  fi
44261
44262
44263  windows_path="$new_path"
44264  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44265    unix_path=`$CYGPATH -u "$windows_path"`
44266    new_path="$unix_path"
44267  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44268    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44269    new_path="$unix_path"
44270  fi
44271
44272  if test "x$path" != "x$new_path"; then
44273    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44274    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44275$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44276  fi
44277
44278  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44279  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44280
44281  else
44282    # We're on a posix platform. Hooray! :)
44283    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44284    has_space=`$ECHO "$path" | $GREP " "`
44285    if test "x$has_space" != x; then
44286      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44287$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44288      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44289    fi
44290
44291    # Use eval to expand a potential ~
44292    eval path="$path"
44293    if test ! -f "$path" && test ! -d "$path"; then
44294      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44295    fi
44296
44297    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44298  fi
44299
44300
44301  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44302
44303  # Input might be given as Windows format, start by converting to
44304  # unix format.
44305  path="$POTENTIAL_FREETYPE_LIB_PATH"
44306  new_path=`$CYGPATH -u "$path"`
44307
44308  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44309  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44310  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44311  # "foo.exe" is OK but "foo" is an error.
44312  #
44313  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44314  # It is also a way to make sure we got the proper file name for the real test later on.
44315  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44316  if test "x$test_shortpath" = x; then
44317    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44318$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44319    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44320  fi
44321
44322  # Call helper function which possibly converts this using DOS-style short mode.
44323  # If so, the updated path is stored in $new_path.
44324
44325  input_path="$new_path"
44326  # Check if we need to convert this using DOS-style short mode. If the path
44327  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44328  # take no chances and rewrite it.
44329  # Note: m4 eats our [], so we need to use [ and ] instead.
44330  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44331  if test "x$has_forbidden_chars" != x; then
44332    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44333    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44334    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44335    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44336      # Going to short mode and back again did indeed matter. Since short mode is
44337      # case insensitive, let's make it lowercase to improve readability.
44338      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44339      # Now convert it back to Unix-stile (cygpath)
44340      input_path=`$CYGPATH -u "$shortmode_path"`
44341      new_path="$input_path"
44342    fi
44343  fi
44344
44345  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44346  if test "x$test_cygdrive_prefix" = x; then
44347    # As a simple fix, exclude /usr/bin since it's not a real path.
44348    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44349      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44350      # a path prefixed by /cygdrive for fixpath to work.
44351      new_path="$CYGWIN_ROOT_PATH$input_path"
44352    fi
44353  fi
44354
44355
44356  if test "x$path" != "x$new_path"; then
44357    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44358    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44359$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44360  fi
44361
44362  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44363
44364  path="$POTENTIAL_FREETYPE_LIB_PATH"
44365  has_colon=`$ECHO $path | $GREP ^.:`
44366  new_path="$path"
44367  if test "x$has_colon" = x; then
44368    # Not in mixed or Windows style, start by that.
44369    new_path=`cmd //c echo $path`
44370  fi
44371
44372
44373  input_path="$new_path"
44374  # Check if we need to convert this using DOS-style short mode. If the path
44375  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44376  # take no chances and rewrite it.
44377  # Note: m4 eats our [], so we need to use [ and ] instead.
44378  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44379  if test "x$has_forbidden_chars" != x; then
44380    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44381    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44382  fi
44383
44384
44385  windows_path="$new_path"
44386  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44387    unix_path=`$CYGPATH -u "$windows_path"`
44388    new_path="$unix_path"
44389  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44390    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44391    new_path="$unix_path"
44392  fi
44393
44394  if test "x$path" != "x$new_path"; then
44395    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44396    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44397$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44398  fi
44399
44400  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44401  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44402
44403  else
44404    # We're on a posix platform. Hooray! :)
44405    path="$POTENTIAL_FREETYPE_LIB_PATH"
44406    has_space=`$ECHO "$path" | $GREP " "`
44407    if test "x$has_space" != x; then
44408      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44409$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44410      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44411    fi
44412
44413    # Use eval to expand a potential ~
44414    eval path="$path"
44415    if test ! -f "$path" && test ! -d "$path"; then
44416      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44417    fi
44418
44419    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44420  fi
44421
44422
44423    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44424    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44425$as_echo_n "checking for freetype includes... " >&6; }
44426    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44427$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44428    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44429    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44430$as_echo_n "checking for freetype libraries... " >&6; }
44431    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44432$as_echo "$FREETYPE_LIB_PATH" >&6; }
44433  fi
44434
44435          fi
44436        else
44437          if test "x$SYS_ROOT" = "x/"; then
44438            FREETYPE_ROOT=
44439          else
44440            FREETYPE_ROOT="$SYS_ROOT"
44441          fi
44442          FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
44443
44444  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44445  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44446  METHOD="well-known location"
44447
44448  # First check if the files exists.
44449  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44450    # We found an arbitrary include file. That's a good sign.
44451    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44452$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44453    FOUND_FREETYPE=yes
44454
44455    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44456    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44457      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44458$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44459      FOUND_FREETYPE=no
44460    else
44461      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44462        # On Windows, we will need both .lib and .dll file.
44463        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44464          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44465$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44466          FOUND_FREETYPE=no
44467        fi
44468      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
44469        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44470        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44471      fi
44472    fi
44473  fi
44474
44475  if test "x$FOUND_FREETYPE" = xyes; then
44476
44477  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44478
44479  # Input might be given as Windows format, start by converting to
44480  # unix format.
44481  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44482  new_path=`$CYGPATH -u "$path"`
44483
44484  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44485  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44486  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44487  # "foo.exe" is OK but "foo" is an error.
44488  #
44489  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44490  # It is also a way to make sure we got the proper file name for the real test later on.
44491  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44492  if test "x$test_shortpath" = x; then
44493    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44494$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44495    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44496  fi
44497
44498  # Call helper function which possibly converts this using DOS-style short mode.
44499  # If so, the updated path is stored in $new_path.
44500
44501  input_path="$new_path"
44502  # Check if we need to convert this using DOS-style short mode. If the path
44503  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44504  # take no chances and rewrite it.
44505  # Note: m4 eats our [], so we need to use [ and ] instead.
44506  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44507  if test "x$has_forbidden_chars" != x; then
44508    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44509    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44510    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44511    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44512      # Going to short mode and back again did indeed matter. Since short mode is
44513      # case insensitive, let's make it lowercase to improve readability.
44514      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44515      # Now convert it back to Unix-stile (cygpath)
44516      input_path=`$CYGPATH -u "$shortmode_path"`
44517      new_path="$input_path"
44518    fi
44519  fi
44520
44521  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44522  if test "x$test_cygdrive_prefix" = x; then
44523    # As a simple fix, exclude /usr/bin since it's not a real path.
44524    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44525      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44526      # a path prefixed by /cygdrive for fixpath to work.
44527      new_path="$CYGWIN_ROOT_PATH$input_path"
44528    fi
44529  fi
44530
44531
44532  if test "x$path" != "x$new_path"; then
44533    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44534    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44535$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44536  fi
44537
44538  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44539
44540  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44541  has_colon=`$ECHO $path | $GREP ^.:`
44542  new_path="$path"
44543  if test "x$has_colon" = x; then
44544    # Not in mixed or Windows style, start by that.
44545    new_path=`cmd //c echo $path`
44546  fi
44547
44548
44549  input_path="$new_path"
44550  # Check if we need to convert this using DOS-style short mode. If the path
44551  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44552  # take no chances and rewrite it.
44553  # Note: m4 eats our [], so we need to use [ and ] instead.
44554  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44555  if test "x$has_forbidden_chars" != x; then
44556    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44557    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44558  fi
44559
44560
44561  windows_path="$new_path"
44562  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44563    unix_path=`$CYGPATH -u "$windows_path"`
44564    new_path="$unix_path"
44565  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44566    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44567    new_path="$unix_path"
44568  fi
44569
44570  if test "x$path" != "x$new_path"; then
44571    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44572    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44573$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44574  fi
44575
44576  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44577  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44578
44579  else
44580    # We're on a posix platform. Hooray! :)
44581    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44582    has_space=`$ECHO "$path" | $GREP " "`
44583    if test "x$has_space" != x; then
44584      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44585$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44586      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44587    fi
44588
44589    # Use eval to expand a potential ~
44590    eval path="$path"
44591    if test ! -f "$path" && test ! -d "$path"; then
44592      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44593    fi
44594
44595    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44596  fi
44597
44598
44599  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44600
44601  # Input might be given as Windows format, start by converting to
44602  # unix format.
44603  path="$POTENTIAL_FREETYPE_LIB_PATH"
44604  new_path=`$CYGPATH -u "$path"`
44605
44606  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44607  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44608  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44609  # "foo.exe" is OK but "foo" is an error.
44610  #
44611  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44612  # It is also a way to make sure we got the proper file name for the real test later on.
44613  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44614  if test "x$test_shortpath" = x; then
44615    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44616$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44617    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44618  fi
44619
44620  # Call helper function which possibly converts this using DOS-style short mode.
44621  # If so, the updated path is stored in $new_path.
44622
44623  input_path="$new_path"
44624  # Check if we need to convert this using DOS-style short mode. If the path
44625  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44626  # take no chances and rewrite it.
44627  # Note: m4 eats our [], so we need to use [ and ] instead.
44628  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44629  if test "x$has_forbidden_chars" != x; then
44630    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44631    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44632    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44633    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44634      # Going to short mode and back again did indeed matter. Since short mode is
44635      # case insensitive, let's make it lowercase to improve readability.
44636      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44637      # Now convert it back to Unix-stile (cygpath)
44638      input_path=`$CYGPATH -u "$shortmode_path"`
44639      new_path="$input_path"
44640    fi
44641  fi
44642
44643  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44644  if test "x$test_cygdrive_prefix" = x; then
44645    # As a simple fix, exclude /usr/bin since it's not a real path.
44646    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44647      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44648      # a path prefixed by /cygdrive for fixpath to work.
44649      new_path="$CYGWIN_ROOT_PATH$input_path"
44650    fi
44651  fi
44652
44653
44654  if test "x$path" != "x$new_path"; then
44655    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44656    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44657$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44658  fi
44659
44660  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44661
44662  path="$POTENTIAL_FREETYPE_LIB_PATH"
44663  has_colon=`$ECHO $path | $GREP ^.:`
44664  new_path="$path"
44665  if test "x$has_colon" = x; then
44666    # Not in mixed or Windows style, start by that.
44667    new_path=`cmd //c echo $path`
44668  fi
44669
44670
44671  input_path="$new_path"
44672  # Check if we need to convert this using DOS-style short mode. If the path
44673  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44674  # take no chances and rewrite it.
44675  # Note: m4 eats our [], so we need to use [ and ] instead.
44676  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44677  if test "x$has_forbidden_chars" != x; then
44678    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44679    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44680  fi
44681
44682
44683  windows_path="$new_path"
44684  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44685    unix_path=`$CYGPATH -u "$windows_path"`
44686    new_path="$unix_path"
44687  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44688    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44689    new_path="$unix_path"
44690  fi
44691
44692  if test "x$path" != "x$new_path"; then
44693    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44694    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44695$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44696  fi
44697
44698  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44699  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44700
44701  else
44702    # We're on a posix platform. Hooray! :)
44703    path="$POTENTIAL_FREETYPE_LIB_PATH"
44704    has_space=`$ECHO "$path" | $GREP " "`
44705    if test "x$has_space" != x; then
44706      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44707$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44708      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44709    fi
44710
44711    # Use eval to expand a potential ~
44712    eval path="$path"
44713    if test ! -f "$path" && test ! -d "$path"; then
44714      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44715    fi
44716
44717    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44718  fi
44719
44720
44721    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44722    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44723$as_echo_n "checking for freetype includes... " >&6; }
44724    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44725$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44726    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44727    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44728$as_echo_n "checking for freetype libraries... " >&6; }
44729    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44730$as_echo "$FREETYPE_LIB_PATH" >&6; }
44731  fi
44732
44733
44734          if test "x$FOUND_FREETYPE" != xyes; then
44735            FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr/X11"
44736
44737  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44738  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44739  METHOD="well-known location"
44740
44741  # First check if the files exists.
44742  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44743    # We found an arbitrary include file. That's a good sign.
44744    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44745$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44746    FOUND_FREETYPE=yes
44747
44748    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44749    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44750      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44751$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44752      FOUND_FREETYPE=no
44753    else
44754      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44755        # On Windows, we will need both .lib and .dll file.
44756        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44757          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44758$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44759          FOUND_FREETYPE=no
44760        fi
44761      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
44762        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44763        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44764      fi
44765    fi
44766  fi
44767
44768  if test "x$FOUND_FREETYPE" = xyes; then
44769
44770  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44771
44772  # Input might be given as Windows format, start by converting to
44773  # unix format.
44774  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44775  new_path=`$CYGPATH -u "$path"`
44776
44777  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44778  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44779  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44780  # "foo.exe" is OK but "foo" is an error.
44781  #
44782  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44783  # It is also a way to make sure we got the proper file name for the real test later on.
44784  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44785  if test "x$test_shortpath" = x; then
44786    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44787$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44788    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44789  fi
44790
44791  # Call helper function which possibly converts this using DOS-style short mode.
44792  # If so, the updated path is stored in $new_path.
44793
44794  input_path="$new_path"
44795  # Check if we need to convert this using DOS-style short mode. If the path
44796  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44797  # take no chances and rewrite it.
44798  # Note: m4 eats our [], so we need to use [ and ] instead.
44799  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44800  if test "x$has_forbidden_chars" != x; then
44801    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44802    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44803    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44804    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44805      # Going to short mode and back again did indeed matter. Since short mode is
44806      # case insensitive, let's make it lowercase to improve readability.
44807      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44808      # Now convert it back to Unix-stile (cygpath)
44809      input_path=`$CYGPATH -u "$shortmode_path"`
44810      new_path="$input_path"
44811    fi
44812  fi
44813
44814  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44815  if test "x$test_cygdrive_prefix" = x; then
44816    # As a simple fix, exclude /usr/bin since it's not a real path.
44817    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44818      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44819      # a path prefixed by /cygdrive for fixpath to work.
44820      new_path="$CYGWIN_ROOT_PATH$input_path"
44821    fi
44822  fi
44823
44824
44825  if test "x$path" != "x$new_path"; then
44826    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44827    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44828$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44829  fi
44830
44831  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44832
44833  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44834  has_colon=`$ECHO $path | $GREP ^.:`
44835  new_path="$path"
44836  if test "x$has_colon" = x; then
44837    # Not in mixed or Windows style, start by that.
44838    new_path=`cmd //c echo $path`
44839  fi
44840
44841
44842  input_path="$new_path"
44843  # Check if we need to convert this using DOS-style short mode. If the path
44844  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44845  # take no chances and rewrite it.
44846  # Note: m4 eats our [], so we need to use [ and ] instead.
44847  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44848  if test "x$has_forbidden_chars" != x; then
44849    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44850    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44851  fi
44852
44853
44854  windows_path="$new_path"
44855  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44856    unix_path=`$CYGPATH -u "$windows_path"`
44857    new_path="$unix_path"
44858  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44859    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44860    new_path="$unix_path"
44861  fi
44862
44863  if test "x$path" != "x$new_path"; then
44864    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44865    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44866$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44867  fi
44868
44869  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44870  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44871
44872  else
44873    # We're on a posix platform. Hooray! :)
44874    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44875    has_space=`$ECHO "$path" | $GREP " "`
44876    if test "x$has_space" != x; then
44877      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44878$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44879      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44880    fi
44881
44882    # Use eval to expand a potential ~
44883    eval path="$path"
44884    if test ! -f "$path" && test ! -d "$path"; then
44885      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44886    fi
44887
44888    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44889  fi
44890
44891
44892  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44893
44894  # Input might be given as Windows format, start by converting to
44895  # unix format.
44896  path="$POTENTIAL_FREETYPE_LIB_PATH"
44897  new_path=`$CYGPATH -u "$path"`
44898
44899  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44900  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44901  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44902  # "foo.exe" is OK but "foo" is an error.
44903  #
44904  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44905  # It is also a way to make sure we got the proper file name for the real test later on.
44906  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44907  if test "x$test_shortpath" = x; then
44908    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44909$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44910    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44911  fi
44912
44913  # Call helper function which possibly converts this using DOS-style short mode.
44914  # If so, the updated path is stored in $new_path.
44915
44916  input_path="$new_path"
44917  # Check if we need to convert this using DOS-style short mode. If the path
44918  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44919  # take no chances and rewrite it.
44920  # Note: m4 eats our [], so we need to use [ and ] instead.
44921  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44922  if test "x$has_forbidden_chars" != x; then
44923    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44924    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44925    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44926    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44927      # Going to short mode and back again did indeed matter. Since short mode is
44928      # case insensitive, let's make it lowercase to improve readability.
44929      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44930      # Now convert it back to Unix-stile (cygpath)
44931      input_path=`$CYGPATH -u "$shortmode_path"`
44932      new_path="$input_path"
44933    fi
44934  fi
44935
44936  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44937  if test "x$test_cygdrive_prefix" = x; then
44938    # As a simple fix, exclude /usr/bin since it's not a real path.
44939    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44940      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44941      # a path prefixed by /cygdrive for fixpath to work.
44942      new_path="$CYGWIN_ROOT_PATH$input_path"
44943    fi
44944  fi
44945
44946
44947  if test "x$path" != "x$new_path"; then
44948    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44949    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44950$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44951  fi
44952
44953  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44954
44955  path="$POTENTIAL_FREETYPE_LIB_PATH"
44956  has_colon=`$ECHO $path | $GREP ^.:`
44957  new_path="$path"
44958  if test "x$has_colon" = x; then
44959    # Not in mixed or Windows style, start by that.
44960    new_path=`cmd //c echo $path`
44961  fi
44962
44963
44964  input_path="$new_path"
44965  # Check if we need to convert this using DOS-style short mode. If the path
44966  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44967  # take no chances and rewrite it.
44968  # Note: m4 eats our [], so we need to use [ and ] instead.
44969  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44970  if test "x$has_forbidden_chars" != x; then
44971    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44972    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44973  fi
44974
44975
44976  windows_path="$new_path"
44977  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44978    unix_path=`$CYGPATH -u "$windows_path"`
44979    new_path="$unix_path"
44980  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44981    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44982    new_path="$unix_path"
44983  fi
44984
44985  if test "x$path" != "x$new_path"; then
44986    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44987    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44988$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44989  fi
44990
44991  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44992  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44993
44994  else
44995    # We're on a posix platform. Hooray! :)
44996    path="$POTENTIAL_FREETYPE_LIB_PATH"
44997    has_space=`$ECHO "$path" | $GREP " "`
44998    if test "x$has_space" != x; then
44999      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45000$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45001      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45002    fi
45003
45004    # Use eval to expand a potential ~
45005    eval path="$path"
45006    if test ! -f "$path" && test ! -d "$path"; then
45007      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45008    fi
45009
45010    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45011  fi
45012
45013
45014    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45015    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45016$as_echo_n "checking for freetype includes... " >&6; }
45017    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45018$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45019    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45020    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45021$as_echo_n "checking for freetype libraries... " >&6; }
45022    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45023$as_echo "$FREETYPE_LIB_PATH" >&6; }
45024  fi
45025
45026          fi
45027
45028          if test "x$FOUND_FREETYPE" != xyes; then
45029            FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
45030            if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45031
45032  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45033  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45034  METHOD="well-known location"
45035
45036  # First check if the files exists.
45037  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45038    # We found an arbitrary include file. That's a good sign.
45039    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45040$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45041    FOUND_FREETYPE=yes
45042
45043    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45044    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45045      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45046$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45047      FOUND_FREETYPE=no
45048    else
45049      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45050        # On Windows, we will need both .lib and .dll file.
45051        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45052          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45053$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45054          FOUND_FREETYPE=no
45055        fi
45056      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
45057        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45058        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45059      fi
45060    fi
45061  fi
45062
45063  if test "x$FOUND_FREETYPE" = xyes; then
45064
45065  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45066
45067  # Input might be given as Windows format, start by converting to
45068  # unix format.
45069  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45070  new_path=`$CYGPATH -u "$path"`
45071
45072  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45073  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45074  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45075  # "foo.exe" is OK but "foo" is an error.
45076  #
45077  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45078  # It is also a way to make sure we got the proper file name for the real test later on.
45079  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45080  if test "x$test_shortpath" = x; then
45081    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45082$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45083    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45084  fi
45085
45086  # Call helper function which possibly converts this using DOS-style short mode.
45087  # If so, the updated path is stored in $new_path.
45088
45089  input_path="$new_path"
45090  # Check if we need to convert this using DOS-style short mode. If the path
45091  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45092  # take no chances and rewrite it.
45093  # Note: m4 eats our [], so we need to use [ and ] instead.
45094  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45095  if test "x$has_forbidden_chars" != x; then
45096    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45097    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45098    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45099    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45100      # Going to short mode and back again did indeed matter. Since short mode is
45101      # case insensitive, let's make it lowercase to improve readability.
45102      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45103      # Now convert it back to Unix-stile (cygpath)
45104      input_path=`$CYGPATH -u "$shortmode_path"`
45105      new_path="$input_path"
45106    fi
45107  fi
45108
45109  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45110  if test "x$test_cygdrive_prefix" = x; then
45111    # As a simple fix, exclude /usr/bin since it's not a real path.
45112    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45113      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45114      # a path prefixed by /cygdrive for fixpath to work.
45115      new_path="$CYGWIN_ROOT_PATH$input_path"
45116    fi
45117  fi
45118
45119
45120  if test "x$path" != "x$new_path"; then
45121    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45122    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45123$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45124  fi
45125
45126  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45127
45128  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45129  has_colon=`$ECHO $path | $GREP ^.:`
45130  new_path="$path"
45131  if test "x$has_colon" = x; then
45132    # Not in mixed or Windows style, start by that.
45133    new_path=`cmd //c echo $path`
45134  fi
45135
45136
45137  input_path="$new_path"
45138  # Check if we need to convert this using DOS-style short mode. If the path
45139  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45140  # take no chances and rewrite it.
45141  # Note: m4 eats our [], so we need to use [ and ] instead.
45142  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45143  if test "x$has_forbidden_chars" != x; then
45144    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45145    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45146  fi
45147
45148
45149  windows_path="$new_path"
45150  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45151    unix_path=`$CYGPATH -u "$windows_path"`
45152    new_path="$unix_path"
45153  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45154    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45155    new_path="$unix_path"
45156  fi
45157
45158  if test "x$path" != "x$new_path"; then
45159    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45160    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45161$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45162  fi
45163
45164  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45165  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45166
45167  else
45168    # We're on a posix platform. Hooray! :)
45169    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45170    has_space=`$ECHO "$path" | $GREP " "`
45171    if test "x$has_space" != x; then
45172      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45173$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45174      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45175    fi
45176
45177    # Use eval to expand a potential ~
45178    eval path="$path"
45179    if test ! -f "$path" && test ! -d "$path"; then
45180      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45181    fi
45182
45183    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45184  fi
45185
45186
45187  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45188
45189  # Input might be given as Windows format, start by converting to
45190  # unix format.
45191  path="$POTENTIAL_FREETYPE_LIB_PATH"
45192  new_path=`$CYGPATH -u "$path"`
45193
45194  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45195  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45196  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45197  # "foo.exe" is OK but "foo" is an error.
45198  #
45199  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45200  # It is also a way to make sure we got the proper file name for the real test later on.
45201  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45202  if test "x$test_shortpath" = x; then
45203    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45204$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45205    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45206  fi
45207
45208  # Call helper function which possibly converts this using DOS-style short mode.
45209  # If so, the updated path is stored in $new_path.
45210
45211  input_path="$new_path"
45212  # Check if we need to convert this using DOS-style short mode. If the path
45213  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45214  # take no chances and rewrite it.
45215  # Note: m4 eats our [], so we need to use [ and ] instead.
45216  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45217  if test "x$has_forbidden_chars" != x; then
45218    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45219    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45220    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45221    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45222      # Going to short mode and back again did indeed matter. Since short mode is
45223      # case insensitive, let's make it lowercase to improve readability.
45224      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45225      # Now convert it back to Unix-stile (cygpath)
45226      input_path=`$CYGPATH -u "$shortmode_path"`
45227      new_path="$input_path"
45228    fi
45229  fi
45230
45231  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45232  if test "x$test_cygdrive_prefix" = x; then
45233    # As a simple fix, exclude /usr/bin since it's not a real path.
45234    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45235      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45236      # a path prefixed by /cygdrive for fixpath to work.
45237      new_path="$CYGWIN_ROOT_PATH$input_path"
45238    fi
45239  fi
45240
45241
45242  if test "x$path" != "x$new_path"; then
45243    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45244    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45245$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45246  fi
45247
45248  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45249
45250  path="$POTENTIAL_FREETYPE_LIB_PATH"
45251  has_colon=`$ECHO $path | $GREP ^.:`
45252  new_path="$path"
45253  if test "x$has_colon" = x; then
45254    # Not in mixed or Windows style, start by that.
45255    new_path=`cmd //c echo $path`
45256  fi
45257
45258
45259  input_path="$new_path"
45260  # Check if we need to convert this using DOS-style short mode. If the path
45261  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45262  # take no chances and rewrite it.
45263  # Note: m4 eats our [], so we need to use [ and ] instead.
45264  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45265  if test "x$has_forbidden_chars" != x; then
45266    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45267    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45268  fi
45269
45270
45271  windows_path="$new_path"
45272  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45273    unix_path=`$CYGPATH -u "$windows_path"`
45274    new_path="$unix_path"
45275  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45276    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45277    new_path="$unix_path"
45278  fi
45279
45280  if test "x$path" != "x$new_path"; then
45281    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45282    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45283$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45284  fi
45285
45286  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45287  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45288
45289  else
45290    # We're on a posix platform. Hooray! :)
45291    path="$POTENTIAL_FREETYPE_LIB_PATH"
45292    has_space=`$ECHO "$path" | $GREP " "`
45293    if test "x$has_space" != x; then
45294      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45295$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45296      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45297    fi
45298
45299    # Use eval to expand a potential ~
45300    eval path="$path"
45301    if test ! -f "$path" && test ! -d "$path"; then
45302      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45303    fi
45304
45305    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45306  fi
45307
45308
45309    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45310    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45311$as_echo_n "checking for freetype includes... " >&6; }
45312    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45313$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45314    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45315    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45316$as_echo_n "checking for freetype libraries... " >&6; }
45317    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45318$as_echo "$FREETYPE_LIB_PATH" >&6; }
45319  fi
45320
45321            else
45322
45323  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45324  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
45325  METHOD="well-known location"
45326
45327  # First check if the files exists.
45328  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45329    # We found an arbitrary include file. That's a good sign.
45330    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45331$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45332    FOUND_FREETYPE=yes
45333
45334    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45335    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45336      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45337$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45338      FOUND_FREETYPE=no
45339    else
45340      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45341        # On Windows, we will need both .lib and .dll file.
45342        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45343          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45344$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45345          FOUND_FREETYPE=no
45346        fi
45347      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
45348        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45349        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45350      fi
45351    fi
45352  fi
45353
45354  if test "x$FOUND_FREETYPE" = xyes; then
45355
45356  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45357
45358  # Input might be given as Windows format, start by converting to
45359  # unix format.
45360  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45361  new_path=`$CYGPATH -u "$path"`
45362
45363  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45364  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45365  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45366  # "foo.exe" is OK but "foo" is an error.
45367  #
45368  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45369  # It is also a way to make sure we got the proper file name for the real test later on.
45370  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45371  if test "x$test_shortpath" = x; then
45372    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45373$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45374    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45375  fi
45376
45377  # Call helper function which possibly converts this using DOS-style short mode.
45378  # If so, the updated path is stored in $new_path.
45379
45380  input_path="$new_path"
45381  # Check if we need to convert this using DOS-style short mode. If the path
45382  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45383  # take no chances and rewrite it.
45384  # Note: m4 eats our [], so we need to use [ and ] instead.
45385  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45386  if test "x$has_forbidden_chars" != x; then
45387    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45388    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45389    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45390    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45391      # Going to short mode and back again did indeed matter. Since short mode is
45392      # case insensitive, let's make it lowercase to improve readability.
45393      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45394      # Now convert it back to Unix-stile (cygpath)
45395      input_path=`$CYGPATH -u "$shortmode_path"`
45396      new_path="$input_path"
45397    fi
45398  fi
45399
45400  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45401  if test "x$test_cygdrive_prefix" = x; then
45402    # As a simple fix, exclude /usr/bin since it's not a real path.
45403    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45404      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45405      # a path prefixed by /cygdrive for fixpath to work.
45406      new_path="$CYGWIN_ROOT_PATH$input_path"
45407    fi
45408  fi
45409
45410
45411  if test "x$path" != "x$new_path"; then
45412    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45413    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45414$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45415  fi
45416
45417  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45418
45419  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45420  has_colon=`$ECHO $path | $GREP ^.:`
45421  new_path="$path"
45422  if test "x$has_colon" = x; then
45423    # Not in mixed or Windows style, start by that.
45424    new_path=`cmd //c echo $path`
45425  fi
45426
45427
45428  input_path="$new_path"
45429  # Check if we need to convert this using DOS-style short mode. If the path
45430  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45431  # take no chances and rewrite it.
45432  # Note: m4 eats our [], so we need to use [ and ] instead.
45433  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45434  if test "x$has_forbidden_chars" != x; then
45435    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45436    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45437  fi
45438
45439
45440  windows_path="$new_path"
45441  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45442    unix_path=`$CYGPATH -u "$windows_path"`
45443    new_path="$unix_path"
45444  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45445    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45446    new_path="$unix_path"
45447  fi
45448
45449  if test "x$path" != "x$new_path"; then
45450    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45451    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45452$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45453  fi
45454
45455  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45456  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45457
45458  else
45459    # We're on a posix platform. Hooray! :)
45460    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45461    has_space=`$ECHO "$path" | $GREP " "`
45462    if test "x$has_space" != x; then
45463      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45464$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45465      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45466    fi
45467
45468    # Use eval to expand a potential ~
45469    eval path="$path"
45470    if test ! -f "$path" && test ! -d "$path"; then
45471      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45472    fi
45473
45474    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45475  fi
45476
45477
45478  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45479
45480  # Input might be given as Windows format, start by converting to
45481  # unix format.
45482  path="$POTENTIAL_FREETYPE_LIB_PATH"
45483  new_path=`$CYGPATH -u "$path"`
45484
45485  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45486  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45487  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45488  # "foo.exe" is OK but "foo" is an error.
45489  #
45490  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45491  # It is also a way to make sure we got the proper file name for the real test later on.
45492  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45493  if test "x$test_shortpath" = x; then
45494    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45495$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45496    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45497  fi
45498
45499  # Call helper function which possibly converts this using DOS-style short mode.
45500  # If so, the updated path is stored in $new_path.
45501
45502  input_path="$new_path"
45503  # Check if we need to convert this using DOS-style short mode. If the path
45504  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45505  # take no chances and rewrite it.
45506  # Note: m4 eats our [], so we need to use [ and ] instead.
45507  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45508  if test "x$has_forbidden_chars" != x; then
45509    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45510    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45511    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45512    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45513      # Going to short mode and back again did indeed matter. Since short mode is
45514      # case insensitive, let's make it lowercase to improve readability.
45515      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45516      # Now convert it back to Unix-stile (cygpath)
45517      input_path=`$CYGPATH -u "$shortmode_path"`
45518      new_path="$input_path"
45519    fi
45520  fi
45521
45522  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45523  if test "x$test_cygdrive_prefix" = x; then
45524    # As a simple fix, exclude /usr/bin since it's not a real path.
45525    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45526      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45527      # a path prefixed by /cygdrive for fixpath to work.
45528      new_path="$CYGWIN_ROOT_PATH$input_path"
45529    fi
45530  fi
45531
45532
45533  if test "x$path" != "x$new_path"; then
45534    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45535    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45536$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45537  fi
45538
45539  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45540
45541  path="$POTENTIAL_FREETYPE_LIB_PATH"
45542  has_colon=`$ECHO $path | $GREP ^.:`
45543  new_path="$path"
45544  if test "x$has_colon" = x; then
45545    # Not in mixed or Windows style, start by that.
45546    new_path=`cmd //c echo $path`
45547  fi
45548
45549
45550  input_path="$new_path"
45551  # Check if we need to convert this using DOS-style short mode. If the path
45552  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45553  # take no chances and rewrite it.
45554  # Note: m4 eats our [], so we need to use [ and ] instead.
45555  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45556  if test "x$has_forbidden_chars" != x; then
45557    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45558    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45559  fi
45560
45561
45562  windows_path="$new_path"
45563  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45564    unix_path=`$CYGPATH -u "$windows_path"`
45565    new_path="$unix_path"
45566  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45567    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45568    new_path="$unix_path"
45569  fi
45570
45571  if test "x$path" != "x$new_path"; then
45572    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45573    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45574$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45575  fi
45576
45577  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45578  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45579
45580  else
45581    # We're on a posix platform. Hooray! :)
45582    path="$POTENTIAL_FREETYPE_LIB_PATH"
45583    has_space=`$ECHO "$path" | $GREP " "`
45584    if test "x$has_space" != x; then
45585      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45586$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45587      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45588    fi
45589
45590    # Use eval to expand a potential ~
45591    eval path="$path"
45592    if test ! -f "$path" && test ! -d "$path"; then
45593      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45594    fi
45595
45596    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45597  fi
45598
45599
45600    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45601    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45602$as_echo_n "checking for freetype includes... " >&6; }
45603    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45604$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45605    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45606    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45607$as_echo_n "checking for freetype libraries... " >&6; }
45608    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45609$as_echo "$FREETYPE_LIB_PATH" >&6; }
45610  fi
45611
45612              if test "x$FOUND_FREETYPE" != xyes; then
45613
45614  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45615  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
45616  METHOD="well-known location"
45617
45618  # First check if the files exists.
45619  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45620    # We found an arbitrary include file. That's a good sign.
45621    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45622$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45623    FOUND_FREETYPE=yes
45624
45625    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45626    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45627      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45628$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45629      FOUND_FREETYPE=no
45630    else
45631      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45632        # On Windows, we will need both .lib and .dll file.
45633        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45634          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45635$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45636          FOUND_FREETYPE=no
45637        fi
45638      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
45639        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45640        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45641      fi
45642    fi
45643  fi
45644
45645  if test "x$FOUND_FREETYPE" = xyes; then
45646
45647  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45648
45649  # Input might be given as Windows format, start by converting to
45650  # unix format.
45651  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45652  new_path=`$CYGPATH -u "$path"`
45653
45654  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45655  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45656  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45657  # "foo.exe" is OK but "foo" is an error.
45658  #
45659  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45660  # It is also a way to make sure we got the proper file name for the real test later on.
45661  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45662  if test "x$test_shortpath" = x; then
45663    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45664$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45665    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45666  fi
45667
45668  # Call helper function which possibly converts this using DOS-style short mode.
45669  # If so, the updated path is stored in $new_path.
45670
45671  input_path="$new_path"
45672  # Check if we need to convert this using DOS-style short mode. If the path
45673  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45674  # take no chances and rewrite it.
45675  # Note: m4 eats our [], so we need to use [ and ] instead.
45676  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45677  if test "x$has_forbidden_chars" != x; then
45678    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45679    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45680    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45681    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45682      # Going to short mode and back again did indeed matter. Since short mode is
45683      # case insensitive, let's make it lowercase to improve readability.
45684      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45685      # Now convert it back to Unix-stile (cygpath)
45686      input_path=`$CYGPATH -u "$shortmode_path"`
45687      new_path="$input_path"
45688    fi
45689  fi
45690
45691  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45692  if test "x$test_cygdrive_prefix" = x; then
45693    # As a simple fix, exclude /usr/bin since it's not a real path.
45694    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45695      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45696      # a path prefixed by /cygdrive for fixpath to work.
45697      new_path="$CYGWIN_ROOT_PATH$input_path"
45698    fi
45699  fi
45700
45701
45702  if test "x$path" != "x$new_path"; then
45703    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45704    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45705$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45706  fi
45707
45708  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45709
45710  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45711  has_colon=`$ECHO $path | $GREP ^.:`
45712  new_path="$path"
45713  if test "x$has_colon" = x; then
45714    # Not in mixed or Windows style, start by that.
45715    new_path=`cmd //c echo $path`
45716  fi
45717
45718
45719  input_path="$new_path"
45720  # Check if we need to convert this using DOS-style short mode. If the path
45721  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45722  # take no chances and rewrite it.
45723  # Note: m4 eats our [], so we need to use [ and ] instead.
45724  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45725  if test "x$has_forbidden_chars" != x; then
45726    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45727    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45728  fi
45729
45730
45731  windows_path="$new_path"
45732  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45733    unix_path=`$CYGPATH -u "$windows_path"`
45734    new_path="$unix_path"
45735  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45736    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45737    new_path="$unix_path"
45738  fi
45739
45740  if test "x$path" != "x$new_path"; then
45741    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45742    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45743$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45744  fi
45745
45746  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45747  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45748
45749  else
45750    # We're on a posix platform. Hooray! :)
45751    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45752    has_space=`$ECHO "$path" | $GREP " "`
45753    if test "x$has_space" != x; then
45754      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45755$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45756      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45757    fi
45758
45759    # Use eval to expand a potential ~
45760    eval path="$path"
45761    if test ! -f "$path" && test ! -d "$path"; then
45762      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45763    fi
45764
45765    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45766  fi
45767
45768
45769  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45770
45771  # Input might be given as Windows format, start by converting to
45772  # unix format.
45773  path="$POTENTIAL_FREETYPE_LIB_PATH"
45774  new_path=`$CYGPATH -u "$path"`
45775
45776  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45777  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45778  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45779  # "foo.exe" is OK but "foo" is an error.
45780  #
45781  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45782  # It is also a way to make sure we got the proper file name for the real test later on.
45783  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45784  if test "x$test_shortpath" = x; then
45785    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45786$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45787    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45788  fi
45789
45790  # Call helper function which possibly converts this using DOS-style short mode.
45791  # If so, the updated path is stored in $new_path.
45792
45793  input_path="$new_path"
45794  # Check if we need to convert this using DOS-style short mode. If the path
45795  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45796  # take no chances and rewrite it.
45797  # Note: m4 eats our [], so we need to use [ and ] instead.
45798  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45799  if test "x$has_forbidden_chars" != x; then
45800    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45801    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45802    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45803    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45804      # Going to short mode and back again did indeed matter. Since short mode is
45805      # case insensitive, let's make it lowercase to improve readability.
45806      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45807      # Now convert it back to Unix-stile (cygpath)
45808      input_path=`$CYGPATH -u "$shortmode_path"`
45809      new_path="$input_path"
45810    fi
45811  fi
45812
45813  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45814  if test "x$test_cygdrive_prefix" = x; then
45815    # As a simple fix, exclude /usr/bin since it's not a real path.
45816    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45817      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45818      # a path prefixed by /cygdrive for fixpath to work.
45819      new_path="$CYGWIN_ROOT_PATH$input_path"
45820    fi
45821  fi
45822
45823
45824  if test "x$path" != "x$new_path"; then
45825    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45826    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45827$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45828  fi
45829
45830  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45831
45832  path="$POTENTIAL_FREETYPE_LIB_PATH"
45833  has_colon=`$ECHO $path | $GREP ^.:`
45834  new_path="$path"
45835  if test "x$has_colon" = x; then
45836    # Not in mixed or Windows style, start by that.
45837    new_path=`cmd //c echo $path`
45838  fi
45839
45840
45841  input_path="$new_path"
45842  # Check if we need to convert this using DOS-style short mode. If the path
45843  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45844  # take no chances and rewrite it.
45845  # Note: m4 eats our [], so we need to use [ and ] instead.
45846  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45847  if test "x$has_forbidden_chars" != x; then
45848    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45849    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45850  fi
45851
45852
45853  windows_path="$new_path"
45854  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45855    unix_path=`$CYGPATH -u "$windows_path"`
45856    new_path="$unix_path"
45857  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45858    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45859    new_path="$unix_path"
45860  fi
45861
45862  if test "x$path" != "x$new_path"; then
45863    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45864    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45865$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45866  fi
45867
45868  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45869  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45870
45871  else
45872    # We're on a posix platform. Hooray! :)
45873    path="$POTENTIAL_FREETYPE_LIB_PATH"
45874    has_space=`$ECHO "$path" | $GREP " "`
45875    if test "x$has_space" != x; then
45876      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45877$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45878      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45879    fi
45880
45881    # Use eval to expand a potential ~
45882    eval path="$path"
45883    if test ! -f "$path" && test ! -d "$path"; then
45884      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45885    fi
45886
45887    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45888  fi
45889
45890
45891    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45892    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45893$as_echo_n "checking for freetype includes... " >&6; }
45894    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45895$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45896    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45897    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45898$as_echo_n "checking for freetype libraries... " >&6; }
45899    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45900$as_echo "$FREETYPE_LIB_PATH" >&6; }
45901  fi
45902
45903              fi
45904            fi
45905          fi
45906        fi
45907      fi # end check in well-known locations
45908
45909      if test "x$FOUND_FREETYPE" != xyes; then
45910
45911  # Print a helpful message on how to acquire the necessary build dependency.
45912  # freetype is the help tag: freetype, cups, pulse, alsa etc
45913  MISSING_DEPENDENCY=freetype
45914
45915  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45916    cygwin_help $MISSING_DEPENDENCY
45917  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45918    msys_help $MISSING_DEPENDENCY
45919  else
45920    PKGHANDLER_COMMAND=
45921
45922    case $PKGHANDLER in
45923      apt-get)
45924        apt_help     $MISSING_DEPENDENCY ;;
45925      yum)
45926        yum_help     $MISSING_DEPENDENCY ;;
45927      port)
45928        port_help    $MISSING_DEPENDENCY ;;
45929      pkgutil)
45930        pkgutil_help $MISSING_DEPENDENCY ;;
45931      pkgadd)
45932        pkgadd_help  $MISSING_DEPENDENCY ;;
45933    esac
45934
45935    if test "x$PKGHANDLER_COMMAND" != x; then
45936      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
45937    fi
45938  fi
45939
45940        as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
45941      fi
45942    fi # end user specified settings
45943
45944    # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
45945    if test "x$FREETYPE_CFLAGS" = x; then
45946
45947  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45948
45949  # Input might be given as Windows format, start by converting to
45950  # unix format.
45951  path="$FREETYPE_INCLUDE_PATH"
45952  new_path=`$CYGPATH -u "$path"`
45953
45954  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45955  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45956  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45957  # "foo.exe" is OK but "foo" is an error.
45958  #
45959  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45960  # It is also a way to make sure we got the proper file name for the real test later on.
45961  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45962  if test "x$test_shortpath" = x; then
45963    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45964$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45965    as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
45966  fi
45967
45968  # Call helper function which possibly converts this using DOS-style short mode.
45969  # If so, the updated path is stored in $new_path.
45970
45971  input_path="$new_path"
45972  # Check if we need to convert this using DOS-style short mode. If the path
45973  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45974  # take no chances and rewrite it.
45975  # Note: m4 eats our [], so we need to use [ and ] instead.
45976  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45977  if test "x$has_forbidden_chars" != x; then
45978    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45979    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45980    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45981    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45982      # Going to short mode and back again did indeed matter. Since short mode is
45983      # case insensitive, let's make it lowercase to improve readability.
45984      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45985      # Now convert it back to Unix-stile (cygpath)
45986      input_path=`$CYGPATH -u "$shortmode_path"`
45987      new_path="$input_path"
45988    fi
45989  fi
45990
45991  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45992  if test "x$test_cygdrive_prefix" = x; then
45993    # As a simple fix, exclude /usr/bin since it's not a real path.
45994    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45995      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45996      # a path prefixed by /cygdrive for fixpath to work.
45997      new_path="$CYGWIN_ROOT_PATH$input_path"
45998    fi
45999  fi
46000
46001
46002  if test "x$path" != "x$new_path"; then
46003    FREETYPE_INCLUDE_PATH="$new_path"
46004    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46005$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46006  fi
46007
46008  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46009
46010  path="$FREETYPE_INCLUDE_PATH"
46011  has_colon=`$ECHO $path | $GREP ^.:`
46012  new_path="$path"
46013  if test "x$has_colon" = x; then
46014    # Not in mixed or Windows style, start by that.
46015    new_path=`cmd //c echo $path`
46016  fi
46017
46018
46019  input_path="$new_path"
46020  # Check if we need to convert this using DOS-style short mode. If the path
46021  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46022  # take no chances and rewrite it.
46023  # Note: m4 eats our [], so we need to use [ and ] instead.
46024  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46025  if test "x$has_forbidden_chars" != x; then
46026    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46027    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46028  fi
46029
46030
46031  windows_path="$new_path"
46032  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46033    unix_path=`$CYGPATH -u "$windows_path"`
46034    new_path="$unix_path"
46035  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46036    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46037    new_path="$unix_path"
46038  fi
46039
46040  if test "x$path" != "x$new_path"; then
46041    FREETYPE_INCLUDE_PATH="$new_path"
46042    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46043$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46044  fi
46045
46046  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46047  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46048
46049  else
46050    # We're on a posix platform. Hooray! :)
46051    path="$FREETYPE_INCLUDE_PATH"
46052    has_space=`$ECHO "$path" | $GREP " "`
46053    if test "x$has_space" != x; then
46054      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46055$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46056      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46057    fi
46058
46059    # Use eval to expand a potential ~
46060    eval path="$path"
46061    if test ! -f "$path" && test ! -d "$path"; then
46062      as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46063    fi
46064
46065    FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46066  fi
46067
46068      if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
46069        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
46070      else
46071        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
46072      fi
46073    fi
46074
46075    if test "x$FREETYPE_LIBS" = x; then
46076
46077  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46078
46079  # Input might be given as Windows format, start by converting to
46080  # unix format.
46081  path="$FREETYPE_LIB_PATH"
46082  new_path=`$CYGPATH -u "$path"`
46083
46084  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46085  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46086  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46087  # "foo.exe" is OK but "foo" is an error.
46088  #
46089  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46090  # It is also a way to make sure we got the proper file name for the real test later on.
46091  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46092  if test "x$test_shortpath" = x; then
46093    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46094$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46095    as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
46096  fi
46097
46098  # Call helper function which possibly converts this using DOS-style short mode.
46099  # If so, the updated path is stored in $new_path.
46100
46101  input_path="$new_path"
46102  # Check if we need to convert this using DOS-style short mode. If the path
46103  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46104  # take no chances and rewrite it.
46105  # Note: m4 eats our [], so we need to use [ and ] instead.
46106  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46107  if test "x$has_forbidden_chars" != x; then
46108    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46109    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46110    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46111    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46112      # Going to short mode and back again did indeed matter. Since short mode is
46113      # case insensitive, let's make it lowercase to improve readability.
46114      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46115      # Now convert it back to Unix-stile (cygpath)
46116      input_path=`$CYGPATH -u "$shortmode_path"`
46117      new_path="$input_path"
46118    fi
46119  fi
46120
46121  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46122  if test "x$test_cygdrive_prefix" = x; then
46123    # As a simple fix, exclude /usr/bin since it's not a real path.
46124    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46125      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46126      # a path prefixed by /cygdrive for fixpath to work.
46127      new_path="$CYGWIN_ROOT_PATH$input_path"
46128    fi
46129  fi
46130
46131
46132  if test "x$path" != "x$new_path"; then
46133    FREETYPE_LIB_PATH="$new_path"
46134    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46135$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46136  fi
46137
46138  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46139
46140  path="$FREETYPE_LIB_PATH"
46141  has_colon=`$ECHO $path | $GREP ^.:`
46142  new_path="$path"
46143  if test "x$has_colon" = x; then
46144    # Not in mixed or Windows style, start by that.
46145    new_path=`cmd //c echo $path`
46146  fi
46147
46148
46149  input_path="$new_path"
46150  # Check if we need to convert this using DOS-style short mode. If the path
46151  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46152  # take no chances and rewrite it.
46153  # Note: m4 eats our [], so we need to use [ and ] instead.
46154  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46155  if test "x$has_forbidden_chars" != x; then
46156    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46157    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46158  fi
46159
46160
46161  windows_path="$new_path"
46162  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46163    unix_path=`$CYGPATH -u "$windows_path"`
46164    new_path="$unix_path"
46165  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46166    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46167    new_path="$unix_path"
46168  fi
46169
46170  if test "x$path" != "x$new_path"; then
46171    FREETYPE_LIB_PATH="$new_path"
46172    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46173$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46174  fi
46175
46176  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46177  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46178
46179  else
46180    # We're on a posix platform. Hooray! :)
46181    path="$FREETYPE_LIB_PATH"
46182    has_space=`$ECHO "$path" | $GREP " "`
46183    if test "x$has_space" != x; then
46184      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46185$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46186      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46187    fi
46188
46189    # Use eval to expand a potential ~
46190    eval path="$path"
46191    if test ! -f "$path" && test ! -d "$path"; then
46192      as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46193    fi
46194
46195    FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46196  fi
46197
46198      if test "x$OPENJDK_TARGET_OS" = xwindows; then
46199        FREETYPE_LIBS="$FREETYPE_LIB_PATH/freetype.lib"
46200      else
46201        FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -lfreetype"
46202      fi
46203    fi
46204
46205    # Try to compile it
46206    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
46207$as_echo_n "checking if we can compile and link with freetype... " >&6; }
46208    ac_ext=cpp
46209ac_cpp='$CXXCPP $CPPFLAGS'
46210ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46211ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46212ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46213
46214    PREV_CXXCFLAGS="$CXXFLAGS"
46215    PREV_LIBS="$LIBS"
46216    PREV_CXX="$CXX"
46217    CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
46218    LIBS="$LIBS $FREETYPE_LIBS"
46219    CXX="$FIXPATH $CXX"
46220    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46221/* end confdefs.h.  */
46222
46223          #include<ft2build.h>
46224          #include FT_FREETYPE_H
46225          int main () {
46226            FT_Init_FreeType(NULL);
46227            return 0;
46228          }
46229
46230_ACEOF
46231if ac_fn_cxx_try_link "$LINENO"; then :
46232
46233          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46234$as_echo "yes" >&6; }
46235
46236else
46237
46238          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46239$as_echo "no" >&6; }
46240          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
46241$as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
46242          { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
46243$as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
46244
46245
46246  # Print a helpful message on how to acquire the necessary build dependency.
46247  # freetype is the help tag: freetype, cups, pulse, alsa etc
46248  MISSING_DEPENDENCY=freetype
46249
46250  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46251    cygwin_help $MISSING_DEPENDENCY
46252  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46253    msys_help $MISSING_DEPENDENCY
46254  else
46255    PKGHANDLER_COMMAND=
46256
46257    case $PKGHANDLER in
46258      apt-get)
46259        apt_help     $MISSING_DEPENDENCY ;;
46260      yum)
46261        yum_help     $MISSING_DEPENDENCY ;;
46262      port)
46263        port_help    $MISSING_DEPENDENCY ;;
46264      pkgutil)
46265        pkgutil_help $MISSING_DEPENDENCY ;;
46266      pkgadd)
46267        pkgadd_help  $MISSING_DEPENDENCY ;;
46268    esac
46269
46270    if test "x$PKGHANDLER_COMMAND" != x; then
46271      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46272    fi
46273  fi
46274
46275
46276          as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
46277
46278
46279fi
46280rm -f core conftest.err conftest.$ac_objext \
46281    conftest$ac_exeext conftest.$ac_ext
46282    CXXCFLAGS="$PREV_CXXFLAGS"
46283    LIBS="$PREV_LIBS"
46284    CXX="$PREV_CXX"
46285    ac_ext=cpp
46286ac_cpp='$CXXCPP $CPPFLAGS'
46287ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46288ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46289ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46290
46291
46292    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
46293$as_echo_n "checking if we should bundle freetype... " >&6; }
46294    if test "x$BUNDLE_FREETYPE" = xyes; then
46295      FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
46296    fi
46297    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
46298$as_echo "$BUNDLE_FREETYPE" >&6; }
46299
46300  fi # end freetype needed
46301
46302
46303
46304
46305
46306
46307
46308  ###############################################################################
46309  #
46310  # Check for alsa headers and libraries. Used on Linux/GNU systems.
46311  #
46312
46313# Check whether --with-alsa was given.
46314if test "${with_alsa+set}" = set; then :
46315  withval=$with_alsa;
46316fi
46317
46318
46319# Check whether --with-alsa-include was given.
46320if test "${with_alsa_include+set}" = set; then :
46321  withval=$with_alsa_include;
46322fi
46323
46324
46325# Check whether --with-alsa-lib was given.
46326if test "${with_alsa_lib+set}" = set; then :
46327  withval=$with_alsa_lib;
46328fi
46329
46330
46331  if test "x$ALSA_NOT_NEEDED" = xyes; then
46332    if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
46333      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
46334$as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
46335    fi
46336    ALSA_CFLAGS=
46337    ALSA_LIBS=
46338  else
46339    ALSA_FOUND=no
46340
46341    if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
46342      as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
46343    fi
46344
46345    if test "x${with_alsa}" != x; then
46346      ALSA_LIBS="-L${with_alsa}/lib -lasound"
46347      ALSA_CFLAGS="-I${with_alsa}/include"
46348      ALSA_FOUND=yes
46349    fi
46350    if test "x${with_alsa_include}" != x; then
46351      ALSA_CFLAGS="-I${with_alsa_include}"
46352      ALSA_FOUND=yes
46353    fi
46354    if test "x${with_alsa_lib}" != x; then
46355      ALSA_LIBS="-L${with_alsa_lib} -lasound"
46356      ALSA_FOUND=yes
46357    fi
46358    if test "x$ALSA_FOUND" = xno; then
46359
46360
46361  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
46362    # Source the builddeps file again, to make sure it uses the latest variables!
46363    . $builddepsfile
46364    # Look for a target and build machine specific resource!
46365    eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
46366    if test "x$resource" = x; then
46367      # Ok, lets instead look for a target specific resource
46368      eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
46369    fi
46370    if test "x$resource" = x; then
46371      # Ok, lets instead look for a build specific resource
46372      eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
46373    fi
46374    if test "x$resource" = x; then
46375      # Ok, lets instead look for a generic resource
46376      # (The alsa comes from M4 and not the shell, thus no need for eval here.)
46377      resource=${builddep_alsa}
46378    fi
46379    if test "x$resource" != x; then
46380      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
46381$as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
46382      # If the resource in the builddeps.conf file is an existing directory,
46383      # for example /java/linux/cups
46384      if test -d ${resource}; then
46385        depdir=${resource}
46386      else
46387
46388  # alsa is for example mymodule
46389  # $resource is for example libs/general/libmymod_1_2_3.zip
46390  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
46391  # $with_builddeps_dir is for example /localhome/builddeps
46392  # depdir is the name of the variable into which we store the depdir, eg MYMOD
46393  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
46394  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
46395  filename=`basename $resource`
46396  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
46397  filebase=${filename%%.*}
46398  extension=${filename#*.}
46399  installdir=$with_builddeps_dir/$filebase
46400  if test ! -f $installdir/$filename.unpacked; then
46401    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
46402$as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
46403    if test ! -d $installdir; then
46404      mkdir -p $installdir
46405    fi
46406    if test ! -d $installdir; then
46407      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
46408    fi
46409    tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
46410    touch $tmpfile
46411    if test ! -f $tmpfile; then
46412      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
46413    fi
46414
46415  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
46416  # $tmpfile is the local file name for the downloaded file.
46417  VALID_TOOL=no
46418  if test "x$BDEPS_FTP" = xwget; then
46419    VALID_TOOL=yes
46420    wget -O $tmpfile $with_builddeps_server/$resource
46421  fi
46422  if test "x$BDEPS_FTP" = xlftp; then
46423    VALID_TOOL=yes
46424    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
46425  fi
46426  if test "x$BDEPS_FTP" = xftp; then
46427    VALID_TOOL=yes
46428    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
46429    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
46430    FTPUSERPWD=${FTPSERVER%%@*}
46431    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
46432      FTPUSER=${userpwd%%:*}
46433      FTPPWD=${userpwd#*@}
46434      FTPSERVER=${FTPSERVER#*@}
46435    else
46436      FTPUSER=ftp
46437      FTPPWD=ftp
46438    fi
46439    # the "pass" command does not work on some
46440    # ftp clients (read ftp.exe) but if it works,
46441    # passive mode is better!
46442    ( \
46443        echo "user $FTPUSER $FTPPWD"        ; \
46444        echo "pass"                         ; \
46445        echo "bin"                          ; \
46446        echo "get $FTPPATH $tmpfile"              ; \
46447    ) | ftp -in $FTPSERVER
46448  fi
46449  if test "x$VALID_TOOL" != xyes; then
46450    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
46451  fi
46452
46453    mv $tmpfile $installdir/$filename
46454    if test ! -s $installdir/$filename; then
46455      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
46456    fi
46457    case "$extension" in
46458      zip)  echo "Unzipping $installdir/$filename..."
46459        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
46460        ;;
46461      tar.gz) echo "Untaring $installdir/$filename..."
46462        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46463        ;;
46464      tgz) echo "Untaring $installdir/$filename..."
46465        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46466        ;;
46467      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
46468        ;;
46469    esac
46470  fi
46471  if test -f $installdir/$filename.unpacked; then
46472    depdir=$installdir
46473  fi
46474
46475      fi
46476      # Source the builddeps file again, because in the previous command, the depdir
46477      # was updated to point at the current build dependency install directory.
46478      . $builddepsfile
46479      # Now extract variables from the builddeps.conf files.
46480      theroot=${builddep_alsa_ROOT}
46481      thecflags=${builddep_alsa_CFLAGS}
46482      thelibs=${builddep_alsa_LIBS}
46483      if test "x$depdir" = x; then
46484        as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
46485      fi
46486      ALSA=$depdir
46487      if test "x$theroot" != x; then
46488        ALSA="$theroot"
46489      fi
46490      if test "x$thecflags" != x; then
46491        ALSA_CFLAGS="$thecflags"
46492      fi
46493      if test "x$thelibs" != x; then
46494        ALSA_LIBS="$thelibs"
46495      fi
46496      ALSA_FOUND=yes
46497      else ALSA_FOUND=no
46498
46499    fi
46500    else ALSA_FOUND=no
46501
46502  fi
46503
46504    fi
46505    if test "x$ALSA_FOUND" = xno; then
46506
46507pkg_failed=no
46508{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46509$as_echo_n "checking for ALSA... " >&6; }
46510
46511if test -n "$ALSA_CFLAGS"; then
46512    pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46513 elif test -n "$PKG_CONFIG"; then
46514    if test -n "$PKG_CONFIG" && \
46515    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46516  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46517  ac_status=$?
46518  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46519  test $ac_status = 0; }; then
46520  pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46521else
46522  pkg_failed=yes
46523fi
46524 else
46525    pkg_failed=untried
46526fi
46527if test -n "$ALSA_LIBS"; then
46528    pkg_cv_ALSA_LIBS="$ALSA_LIBS"
46529 elif test -n "$PKG_CONFIG"; then
46530    if test -n "$PKG_CONFIG" && \
46531    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46532  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46533  ac_status=$?
46534  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46535  test $ac_status = 0; }; then
46536  pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
46537else
46538  pkg_failed=yes
46539fi
46540 else
46541    pkg_failed=untried
46542fi
46543
46544
46545
46546if test $pkg_failed = yes; then
46547
46548if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
46549        _pkg_short_errors_supported=yes
46550else
46551        _pkg_short_errors_supported=no
46552fi
46553        if test $_pkg_short_errors_supported = yes; then
46554	        ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
46555        else
46556	        ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
46557        fi
46558	# Put the nasty error message in config.log where it belongs
46559	echo "$ALSA_PKG_ERRORS" >&5
46560
46561	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46562$as_echo "no" >&6; }
46563                ALSA_FOUND=no
46564elif test $pkg_failed = untried; then
46565	ALSA_FOUND=no
46566else
46567	ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
46568	ALSA_LIBS=$pkg_cv_ALSA_LIBS
46569        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46570$as_echo "yes" >&6; }
46571	ALSA_FOUND=yes
46572fi
46573    fi
46574    if test "x$ALSA_FOUND" = xno; then
46575      for ac_header in alsa/asoundlib.h
46576do :
46577  ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
46578if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
46579  cat >>confdefs.h <<_ACEOF
46580#define HAVE_ALSA_ASOUNDLIB_H 1
46581_ACEOF
46582
46583            ALSA_FOUND=yes
46584            ALSA_CFLAGS=-Iignoreme
46585            ALSA_LIBS=-lasound
46586            DEFAULT_ALSA=yes
46587
46588else
46589  ALSA_FOUND=no
46590fi
46591
46592done
46593
46594    fi
46595    if test "x$ALSA_FOUND" = xno; then
46596
46597  # Print a helpful message on how to acquire the necessary build dependency.
46598  # alsa is the help tag: freetype, cups, pulse, alsa etc
46599  MISSING_DEPENDENCY=alsa
46600
46601  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46602    cygwin_help $MISSING_DEPENDENCY
46603  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46604    msys_help $MISSING_DEPENDENCY
46605  else
46606    PKGHANDLER_COMMAND=
46607
46608    case $PKGHANDLER in
46609      apt-get)
46610        apt_help     $MISSING_DEPENDENCY ;;
46611      yum)
46612        yum_help     $MISSING_DEPENDENCY ;;
46613      port)
46614        port_help    $MISSING_DEPENDENCY ;;
46615      pkgutil)
46616        pkgutil_help $MISSING_DEPENDENCY ;;
46617      pkgadd)
46618        pkgadd_help  $MISSING_DEPENDENCY ;;
46619    esac
46620
46621    if test "x$PKGHANDLER_COMMAND" != x; then
46622      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46623    fi
46624  fi
46625
46626      as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
46627    fi
46628  fi
46629
46630
46631
46632
46633
46634
46635  ###############################################################################
46636  #
46637  # Check for the jpeg library
46638  #
46639
46640  USE_EXTERNAL_LIBJPEG=true
46641  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5
46642$as_echo_n "checking for main in -ljpeg... " >&6; }
46643if ${ac_cv_lib_jpeg_main+:} false; then :
46644  $as_echo_n "(cached) " >&6
46645else
46646  ac_check_lib_save_LIBS=$LIBS
46647LIBS="-ljpeg  $LIBS"
46648cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46649/* end confdefs.h.  */
46650
46651
46652int
46653main ()
46654{
46655return main ();
46656  ;
46657  return 0;
46658}
46659_ACEOF
46660if ac_fn_cxx_try_link "$LINENO"; then :
46661  ac_cv_lib_jpeg_main=yes
46662else
46663  ac_cv_lib_jpeg_main=no
46664fi
46665rm -f core conftest.err conftest.$ac_objext \
46666    conftest$ac_exeext conftest.$ac_ext
46667LIBS=$ac_check_lib_save_LIBS
46668fi
46669{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5
46670$as_echo "$ac_cv_lib_jpeg_main" >&6; }
46671if test "x$ac_cv_lib_jpeg_main" = xyes; then :
46672  cat >>confdefs.h <<_ACEOF
46673#define HAVE_LIBJPEG 1
46674_ACEOF
46675
46676  LIBS="-ljpeg $LIBS"
46677
46678else
46679   USE_EXTERNAL_LIBJPEG=false
46680      { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5
46681$as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;}
46682
46683fi
46684
46685
46686
46687  ###############################################################################
46688  #
46689  # Check for the gif library
46690  #
46691
46692
46693# Check whether --with-giflib was given.
46694if test "${with_giflib+set}" = set; then :
46695  withval=$with_giflib;
46696fi
46697
46698
46699
46700  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
46701$as_echo_n "checking for which giflib to use... " >&6; }
46702
46703  # default is bundled
46704  DEFAULT_GIFLIB=bundled
46705
46706  #
46707  # if user didn't specify, use DEFAULT_GIFLIB
46708  #
46709  if test "x${with_giflib}" = "x"; then
46710    with_giflib=${DEFAULT_GIFLIB}
46711  fi
46712
46713  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
46714$as_echo "${with_giflib}" >&6; }
46715
46716  if test "x${with_giflib}" = "xbundled"; then
46717    USE_EXTERNAL_LIBGIF=false
46718  elif test "x${with_giflib}" = "xsystem"; then
46719    ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
46720if test "x$ac_cv_header_gif_lib_h" = xyes; then :
46721
46722else
46723   as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
46724fi
46725
46726
46727    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
46728$as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
46729if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
46730  $as_echo_n "(cached) " >&6
46731else
46732  ac_check_lib_save_LIBS=$LIBS
46733LIBS="-lgif  $LIBS"
46734cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46735/* end confdefs.h.  */
46736
46737/* Override any GCC internal prototype to avoid an error.
46738   Use char because int might match the return type of a GCC
46739   builtin and then its argument prototype would still apply.  */
46740#ifdef __cplusplus
46741extern "C"
46742#endif
46743char DGifGetCode ();
46744int
46745main ()
46746{
46747return DGifGetCode ();
46748  ;
46749  return 0;
46750}
46751_ACEOF
46752if ac_fn_cxx_try_link "$LINENO"; then :
46753  ac_cv_lib_gif_DGifGetCode=yes
46754else
46755  ac_cv_lib_gif_DGifGetCode=no
46756fi
46757rm -f core conftest.err conftest.$ac_objext \
46758    conftest$ac_exeext conftest.$ac_ext
46759LIBS=$ac_check_lib_save_LIBS
46760fi
46761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
46762$as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
46763if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
46764  cat >>confdefs.h <<_ACEOF
46765#define HAVE_LIBGIF 1
46766_ACEOF
46767
46768  LIBS="-lgif $LIBS"
46769
46770else
46771   as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
46772fi
46773
46774
46775    USE_EXTERNAL_LIBGIF=true
46776  else
46777    as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
46778  fi
46779
46780
46781  ###############################################################################
46782  #
46783  # Check for the zlib library
46784  #
46785
46786
46787# Check whether --with-zlib was given.
46788if test "${with_zlib+set}" = set; then :
46789  withval=$with_zlib;
46790fi
46791
46792
46793  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
46794$as_echo_n "checking for compress in -lz... " >&6; }
46795if ${ac_cv_lib_z_compress+:} false; then :
46796  $as_echo_n "(cached) " >&6
46797else
46798  ac_check_lib_save_LIBS=$LIBS
46799LIBS="-lz  $LIBS"
46800cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46801/* end confdefs.h.  */
46802
46803/* Override any GCC internal prototype to avoid an error.
46804   Use char because int might match the return type of a GCC
46805   builtin and then its argument prototype would still apply.  */
46806#ifdef __cplusplus
46807extern "C"
46808#endif
46809char compress ();
46810int
46811main ()
46812{
46813return compress ();
46814  ;
46815  return 0;
46816}
46817_ACEOF
46818if ac_fn_cxx_try_link "$LINENO"; then :
46819  ac_cv_lib_z_compress=yes
46820else
46821  ac_cv_lib_z_compress=no
46822fi
46823rm -f core conftest.err conftest.$ac_objext \
46824    conftest$ac_exeext conftest.$ac_ext
46825LIBS=$ac_check_lib_save_LIBS
46826fi
46827{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
46828$as_echo "$ac_cv_lib_z_compress" >&6; }
46829if test "x$ac_cv_lib_z_compress" = xyes; then :
46830   ZLIB_FOUND=yes
46831else
46832   ZLIB_FOUND=no
46833fi
46834
46835
46836  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
46837$as_echo_n "checking for which zlib to use... " >&6; }
46838
46839  DEFAULT_ZLIB=bundled
46840  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
46841    #
46842    # On macosx default is system...on others default is
46843    #
46844    DEFAULT_ZLIB=system
46845  fi
46846
46847  if test "x${ZLIB_FOUND}" != "xyes"; then
46848    #
46849    # If we don't find any system...set default to bundled
46850    #
46851    DEFAULT_ZLIB=bundled
46852  fi
46853
46854  #
46855  # If user didn't specify, use DEFAULT_ZLIB
46856  #
46857  if test "x${with_zlib}" = "x"; then
46858    with_zlib=${DEFAULT_ZLIB}
46859  fi
46860
46861  if test "x${with_zlib}" = "xbundled"; then
46862    USE_EXTERNAL_LIBZ=false
46863    { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
46864$as_echo "bundled" >&6; }
46865  elif test "x${with_zlib}" = "xsystem"; then
46866    if test "x${ZLIB_FOUND}" = "xyes"; then
46867      USE_EXTERNAL_LIBZ=true
46868      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
46869$as_echo "system" >&6; }
46870    else
46871      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
46872$as_echo "system not found" >&6; }
46873      as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
46874    fi
46875  else
46876    as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
46877  fi
46878
46879
46880
46881  ###############################################################################
46882  LIBZIP_CAN_USE_MMAP=true
46883
46884
46885
46886  ###############################################################################
46887  #
46888  # Check if altzone exists in time.h
46889  #
46890
46891  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46892/* end confdefs.h.  */
46893#include <time.h>
46894int
46895main ()
46896{
46897return (int)altzone;
46898  ;
46899  return 0;
46900}
46901_ACEOF
46902if ac_fn_cxx_try_link "$LINENO"; then :
46903  has_altzone=yes
46904else
46905  has_altzone=no
46906fi
46907rm -f core conftest.err conftest.$ac_objext \
46908    conftest$ac_exeext conftest.$ac_ext
46909  if test "x$has_altzone" = xyes; then
46910
46911$as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
46912
46913  fi
46914
46915  ###############################################################################
46916  #
46917  # Check the maths library
46918  #
46919
46920  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
46921$as_echo_n "checking for cos in -lm... " >&6; }
46922if ${ac_cv_lib_m_cos+:} false; then :
46923  $as_echo_n "(cached) " >&6
46924else
46925  ac_check_lib_save_LIBS=$LIBS
46926LIBS="-lm  $LIBS"
46927cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46928/* end confdefs.h.  */
46929
46930/* Override any GCC internal prototype to avoid an error.
46931   Use char because int might match the return type of a GCC
46932   builtin and then its argument prototype would still apply.  */
46933#ifdef __cplusplus
46934extern "C"
46935#endif
46936char cos ();
46937int
46938main ()
46939{
46940return cos ();
46941  ;
46942  return 0;
46943}
46944_ACEOF
46945if ac_fn_cxx_try_link "$LINENO"; then :
46946  ac_cv_lib_m_cos=yes
46947else
46948  ac_cv_lib_m_cos=no
46949fi
46950rm -f core conftest.err conftest.$ac_objext \
46951    conftest$ac_exeext conftest.$ac_ext
46952LIBS=$ac_check_lib_save_LIBS
46953fi
46954{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
46955$as_echo "$ac_cv_lib_m_cos" >&6; }
46956if test "x$ac_cv_lib_m_cos" = xyes; then :
46957  cat >>confdefs.h <<_ACEOF
46958#define HAVE_LIBM 1
46959_ACEOF
46960
46961  LIBS="-lm $LIBS"
46962
46963else
46964
46965        { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
46966$as_echo "$as_me: Maths library was not found" >&6;}
46967
46968
46969fi
46970
46971
46972
46973  ###############################################################################
46974  #
46975  # Check for libdl.so
46976
46977  save_LIBS="$LIBS"
46978  LIBS=""
46979  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
46980$as_echo_n "checking for dlopen in -ldl... " >&6; }
46981if ${ac_cv_lib_dl_dlopen+:} false; then :
46982  $as_echo_n "(cached) " >&6
46983else
46984  ac_check_lib_save_LIBS=$LIBS
46985LIBS="-ldl  $LIBS"
46986cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46987/* end confdefs.h.  */
46988
46989/* Override any GCC internal prototype to avoid an error.
46990   Use char because int might match the return type of a GCC
46991   builtin and then its argument prototype would still apply.  */
46992#ifdef __cplusplus
46993extern "C"
46994#endif
46995char dlopen ();
46996int
46997main ()
46998{
46999return dlopen ();
47000  ;
47001  return 0;
47002}
47003_ACEOF
47004if ac_fn_cxx_try_link "$LINENO"; then :
47005  ac_cv_lib_dl_dlopen=yes
47006else
47007  ac_cv_lib_dl_dlopen=no
47008fi
47009rm -f core conftest.err conftest.$ac_objext \
47010    conftest$ac_exeext conftest.$ac_ext
47011LIBS=$ac_check_lib_save_LIBS
47012fi
47013{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
47014$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
47015if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
47016  cat >>confdefs.h <<_ACEOF
47017#define HAVE_LIBDL 1
47018_ACEOF
47019
47020  LIBS="-ldl $LIBS"
47021
47022fi
47023
47024  LIBDL="$LIBS"
47025
47026  LIBS="$save_LIBS"
47027
47028
47029  ###############################################################################
47030  #
47031  # statically link libstdc++ before C++ ABI is stablized on Linux unless
47032  # dynamic build is configured on command line.
47033  #
47034
47035# Check whether --with-stdc++lib was given.
47036if test "${with_stdc__lib+set}" = set; then :
47037  withval=$with_stdc__lib;
47038        if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
47039                && test "x$with_stdc__lib" != xdefault; then
47040          as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
47041        fi
47042
47043else
47044  with_stdc__lib=default
47045
47046fi
47047
47048
47049  if test "x$OPENJDK_TARGET_OS" = xlinux; then
47050    # Test if -lstdc++ works.
47051    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
47052$as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
47053    ac_ext=cpp
47054ac_cpp='$CXXCPP $CPPFLAGS'
47055ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47056ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47057ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47058
47059    OLD_CXXFLAGS="$CXXFLAGS"
47060    CXXFLAGS="$CXXFLAGS -lstdc++"
47061    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47062/* end confdefs.h.  */
47063
47064int
47065main ()
47066{
47067return 0;
47068  ;
47069  return 0;
47070}
47071_ACEOF
47072if ac_fn_cxx_try_link "$LINENO"; then :
47073  has_dynamic_libstdcxx=yes
47074else
47075  has_dynamic_libstdcxx=no
47076fi
47077rm -f core conftest.err conftest.$ac_objext \
47078    conftest$ac_exeext conftest.$ac_ext
47079    CXXFLAGS="$OLD_CXXFLAGS"
47080    ac_ext=cpp
47081ac_cpp='$CXXCPP $CPPFLAGS'
47082ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47083ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47084ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47085
47086    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
47087$as_echo "$has_dynamic_libstdcxx" >&6; }
47088
47089    # Test if stdc++ can be linked statically.
47090    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
47091$as_echo_n "checking if static link of stdc++ is possible... " >&6; }
47092    STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
47093    ac_ext=cpp
47094ac_cpp='$CXXCPP $CPPFLAGS'
47095ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47096ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47097ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47098
47099    OLD_LIBS="$LIBS"
47100    OLD_CXX="$CXX"
47101    LIBS="$STATIC_STDCXX_FLAGS"
47102    CXX="$CC"
47103    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47104/* end confdefs.h.  */
47105
47106int
47107main ()
47108{
47109return 0;
47110  ;
47111  return 0;
47112}
47113_ACEOF
47114if ac_fn_cxx_try_link "$LINENO"; then :
47115  has_static_libstdcxx=yes
47116else
47117  has_static_libstdcxx=no
47118fi
47119rm -f core conftest.err conftest.$ac_objext \
47120    conftest$ac_exeext conftest.$ac_ext
47121    LIBS="$OLD_LIBS"
47122    CXX="$OLD_CXX"
47123    ac_ext=cpp
47124ac_cpp='$CXXCPP $CPPFLAGS'
47125ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47126ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47127ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47128
47129    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
47130$as_echo "$has_static_libstdcxx" >&6; }
47131
47132    if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
47133      as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
47134    fi
47135
47136    if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
47137      as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
47138    fi
47139
47140    if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
47141      as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
47142    fi
47143
47144    { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
47145$as_echo_n "checking how to link with libstdc++... " >&6; }
47146    # If dynamic was requested, it's available since it would fail above otherwise.
47147    # If dynamic wasn't requested, go with static unless it isn't available.
47148    if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47149      LIBCXX="$LIBCXX -lstdc++"
47150      LDCXX="$CXX"
47151      STATIC_CXX_SETTING="STATIC_CXX=false"
47152      { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
47153$as_echo "dynamic" >&6; }
47154    else
47155      LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
47156      LDCXX="$CC"
47157      STATIC_CXX_SETTING="STATIC_CXX=true"
47158      { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
47159$as_echo "static" >&6; }
47160    fi
47161  fi
47162
47163
47164  if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47165    # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
47166
47167pkg_failed=no
47168{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
47169$as_echo_n "checking for LIBFFI... " >&6; }
47170
47171if test -n "$LIBFFI_CFLAGS"; then
47172    pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
47173 elif test -n "$PKG_CONFIG"; then
47174    if test -n "$PKG_CONFIG" && \
47175    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47176  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47177  ac_status=$?
47178  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47179  test $ac_status = 0; }; then
47180  pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
47181else
47182  pkg_failed=yes
47183fi
47184 else
47185    pkg_failed=untried
47186fi
47187if test -n "$LIBFFI_LIBS"; then
47188    pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
47189 elif test -n "$PKG_CONFIG"; then
47190    if test -n "$PKG_CONFIG" && \
47191    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47192  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47193  ac_status=$?
47194  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47195  test $ac_status = 0; }; then
47196  pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
47197else
47198  pkg_failed=yes
47199fi
47200 else
47201    pkg_failed=untried
47202fi
47203
47204
47205
47206if test $pkg_failed = yes; then
47207
47208if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47209        _pkg_short_errors_supported=yes
47210else
47211        _pkg_short_errors_supported=no
47212fi
47213        if test $_pkg_short_errors_supported = yes; then
47214	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
47215        else
47216	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
47217        fi
47218	# Put the nasty error message in config.log where it belongs
47219	echo "$LIBFFI_PKG_ERRORS" >&5
47220
47221	as_fn_error $? "Package requirements (libffi) were not met:
47222
47223$LIBFFI_PKG_ERRORS
47224
47225Consider adjusting the PKG_CONFIG_PATH environment variable if you
47226installed software in a non-standard prefix.
47227
47228Alternatively, you may set the environment variables LIBFFI_CFLAGS
47229and LIBFFI_LIBS to avoid the need to call pkg-config.
47230See the pkg-config man page for more details.
47231" "$LINENO" 5
47232elif test $pkg_failed = untried; then
47233	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47234$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
47235as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
47236is in your PATH or set the PKG_CONFIG environment variable to the full
47237path to pkg-config.
47238
47239Alternatively, you may set the environment variables LIBFFI_CFLAGS
47240and LIBFFI_LIBS to avoid the need to call pkg-config.
47241See the pkg-config man page for more details.
47242
47243To get pkg-config, see <http://pkg-config.freedesktop.org/>.
47244See \`config.log' for more details" "$LINENO" 5; }
47245else
47246	LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
47247	LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
47248        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47249$as_echo "yes" >&6; }
47250	:
47251fi
47252
47253  fi
47254
47255  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47256    # Extract the first word of "llvm-config", so it can be a program name with args.
47257set dummy llvm-config; ac_word=$2
47258{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47259$as_echo_n "checking for $ac_word... " >&6; }
47260if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
47261  $as_echo_n "(cached) " >&6
47262else
47263  if test -n "$LLVM_CONFIG"; then
47264  ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
47265else
47266as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47267for as_dir in $PATH
47268do
47269  IFS=$as_save_IFS
47270  test -z "$as_dir" && as_dir=.
47271    for ac_exec_ext in '' $ac_executable_extensions; do
47272  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47273    ac_cv_prog_LLVM_CONFIG="llvm-config"
47274    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47275    break 2
47276  fi
47277done
47278  done
47279IFS=$as_save_IFS
47280
47281fi
47282fi
47283LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
47284if test -n "$LLVM_CONFIG"; then
47285  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
47286$as_echo "$LLVM_CONFIG" >&6; }
47287else
47288  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47289$as_echo "no" >&6; }
47290fi
47291
47292
47293
47294    if test "x$LLVM_CONFIG" != xllvm-config; then
47295      as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
47296    fi
47297
47298    llvm_components="jit mcjit engine nativecodegen native"
47299    unset LLVM_CFLAGS
47300    for flag in $("$LLVM_CONFIG" --cxxflags); do
47301      if echo "${flag}" | grep -q '^-[ID]'; then
47302        if test "${flag}" != "-D_DEBUG" ; then
47303          if test "${LLVM_CFLAGS}" != "" ; then
47304            LLVM_CFLAGS="${LLVM_CFLAGS} "
47305          fi
47306          LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
47307        fi
47308      fi
47309    done
47310    llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
47311    LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
47312
47313    unset LLVM_LDFLAGS
47314    for flag in $("${LLVM_CONFIG}" --ldflags); do
47315      if echo "${flag}" | grep -q '^-L'; then
47316        if test "${LLVM_LDFLAGS}" != ""; then
47317          LLVM_LDFLAGS="${LLVM_LDFLAGS} "
47318        fi
47319        LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
47320      fi
47321    done
47322
47323    unset LLVM_LIBS
47324    for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47325      if echo "${flag}" | grep -q '^-l'; then
47326        if test "${LLVM_LIBS}" != ""; then
47327          LLVM_LIBS="${LLVM_LIBS} "
47328        fi
47329        LLVM_LIBS="${LLVM_LIBS}${flag}"
47330      fi
47331    done
47332
47333
47334
47335
47336  fi
47337
47338  # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47339  if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47340    LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47341  fi
47342
47343  # TODO better (platform agnostic) test
47344  if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47345    LIBCXX="-lstdc++"
47346  fi
47347
47348
47349
47350
47351  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47352
47353
47354# Check whether --with-msvcr-dll was given.
47355if test "${with_msvcr_dll+set}" = set; then :
47356  withval=$with_msvcr_dll;
47357fi
47358
47359
47360  if test "x$with_msvcr_dll" != x; then
47361    # If given explicitely by user, do not probe. If not present, fail directly.
47362
47363  POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
47364  METHOD="--with-msvcr-dll"
47365  if test -e "$POSSIBLE_MSVCR_DLL"; then
47366    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47367$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47368
47369    # Need to check if the found msvcr is correct architecture
47370    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47371$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47372    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47373    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47374      CORRECT_MSVCR_ARCH=386
47375    else
47376      CORRECT_MSVCR_ARCH=x86-64
47377    fi
47378    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47379      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47380$as_echo "ok" >&6; }
47381      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47382      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47383$as_echo_n "checking for msvcr100.dll... " >&6; }
47384      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47385$as_echo "$MSVCR_DLL" >&6; }
47386    else
47387      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47388$as_echo "incorrect, ignoring" >&6; }
47389      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47390$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47391    fi
47392  fi
47393
47394    if test "x$MSVCR_DLL" = x; then
47395      as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
47396    fi
47397  fi
47398
47399  if test "x$MSVCR_DLL" = x; then
47400    # Probe: Using well-known location from Visual Studio 10.0
47401    if test "x$VCINSTALLDIR" != x; then
47402      CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
47403
47404  windows_path="$CYGWIN_VC_INSTALL_DIR"
47405  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47406    unix_path=`$CYGPATH -u "$windows_path"`
47407    CYGWIN_VC_INSTALL_DIR="$unix_path"
47408  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47409    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47410    CYGWIN_VC_INSTALL_DIR="$unix_path"
47411  fi
47412
47413      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47414        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
47415      else
47416        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
47417      fi
47418
47419  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47420  METHOD="well-known location in VCINSTALLDIR"
47421  if test -e "$POSSIBLE_MSVCR_DLL"; then
47422    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47423$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47424
47425    # Need to check if the found msvcr is correct architecture
47426    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47427$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47428    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47429    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47430      CORRECT_MSVCR_ARCH=386
47431    else
47432      CORRECT_MSVCR_ARCH=x86-64
47433    fi
47434    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47435      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47436$as_echo "ok" >&6; }
47437      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47438      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47439$as_echo_n "checking for msvcr100.dll... " >&6; }
47440      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47441$as_echo "$MSVCR_DLL" >&6; }
47442    else
47443      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47444$as_echo "incorrect, ignoring" >&6; }
47445      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47446$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47447    fi
47448  fi
47449
47450    fi
47451  fi
47452
47453  if test "x$MSVCR_DLL" = x; then
47454    # Probe: Check in the Boot JDK directory.
47455    POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
47456
47457  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47458  METHOD="well-known location in Boot JDK"
47459  if test -e "$POSSIBLE_MSVCR_DLL"; then
47460    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47461$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47462
47463    # Need to check if the found msvcr is correct architecture
47464    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47465$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47466    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47467    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47468      CORRECT_MSVCR_ARCH=386
47469    else
47470      CORRECT_MSVCR_ARCH=x86-64
47471    fi
47472    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47473      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47474$as_echo "ok" >&6; }
47475      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47476      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47477$as_echo_n "checking for msvcr100.dll... " >&6; }
47478      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47479$as_echo "$MSVCR_DLL" >&6; }
47480    else
47481      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47482$as_echo "incorrect, ignoring" >&6; }
47483      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47484$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47485    fi
47486  fi
47487
47488  fi
47489
47490  if test "x$MSVCR_DLL" = x; then
47491    # Probe: Look in the Windows system32 directory
47492    CYGWIN_SYSTEMROOT="$SYSTEMROOT"
47493
47494  windows_path="$CYGWIN_SYSTEMROOT"
47495  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47496    unix_path=`$CYGPATH -u "$windows_path"`
47497    CYGWIN_SYSTEMROOT="$unix_path"
47498  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47499    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47500    CYGWIN_SYSTEMROOT="$unix_path"
47501  fi
47502
47503    POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
47504
47505  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47506  METHOD="well-known location in SYSTEMROOT"
47507  if test -e "$POSSIBLE_MSVCR_DLL"; then
47508    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47509$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47510
47511    # Need to check if the found msvcr is correct architecture
47512    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47513$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47514    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47515    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47516      CORRECT_MSVCR_ARCH=386
47517    else
47518      CORRECT_MSVCR_ARCH=x86-64
47519    fi
47520    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47521      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47522$as_echo "ok" >&6; }
47523      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47524      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47525$as_echo_n "checking for msvcr100.dll... " >&6; }
47526      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47527$as_echo "$MSVCR_DLL" >&6; }
47528    else
47529      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47530$as_echo "incorrect, ignoring" >&6; }
47531      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47532$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47533    fi
47534  fi
47535
47536  fi
47537
47538  if test "x$MSVCR_DLL" = x; then
47539    # Probe: If Visual Studio Express is installed, there is usually one with the debugger
47540    if test "x$VS100COMNTOOLS" != x; then
47541      CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
47542
47543  windows_path="$CYGWIN_VS_TOOLS_DIR"
47544  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47545    unix_path=`$CYGPATH -u "$windows_path"`
47546    CYGWIN_VS_TOOLS_DIR="$unix_path"
47547  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47548    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47549    CYGWIN_VS_TOOLS_DIR="$unix_path"
47550  fi
47551
47552      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47553        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
47554      else
47555        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
47556      fi
47557
47558  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47559  METHOD="search of VS100COMNTOOLS"
47560  if test -e "$POSSIBLE_MSVCR_DLL"; then
47561    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47562$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47563
47564    # Need to check if the found msvcr is correct architecture
47565    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47566$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47567    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47568    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47569      CORRECT_MSVCR_ARCH=386
47570    else
47571      CORRECT_MSVCR_ARCH=x86-64
47572    fi
47573    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47574      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47575$as_echo "ok" >&6; }
47576      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47577      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47578$as_echo_n "checking for msvcr100.dll... " >&6; }
47579      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47580$as_echo "$MSVCR_DLL" >&6; }
47581    else
47582      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47583$as_echo "incorrect, ignoring" >&6; }
47584      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47585$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47586    fi
47587  fi
47588
47589    fi
47590  fi
47591
47592  if test "x$MSVCR_DLL" = x; then
47593    # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
47594    # (This was the original behaviour; kept since it might turn up something)
47595    if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
47596      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47597        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
47598      else
47599        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
47600        if test "x$POSSIBLE_MSVCR_DLL" = x; then
47601          # We're grasping at straws now...
47602          POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
47603        fi
47604      fi
47605
47606
47607  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47608  METHOD="search of VCINSTALLDIR"
47609  if test -e "$POSSIBLE_MSVCR_DLL"; then
47610    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47611$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47612
47613    # Need to check if the found msvcr is correct architecture
47614    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47615$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47616    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47617    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47618      CORRECT_MSVCR_ARCH=386
47619    else
47620      CORRECT_MSVCR_ARCH=x86-64
47621    fi
47622    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47623      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47624$as_echo "ok" >&6; }
47625      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47626      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47627$as_echo_n "checking for msvcr100.dll... " >&6; }
47628      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47629$as_echo "$MSVCR_DLL" >&6; }
47630    else
47631      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47632$as_echo "incorrect, ignoring" >&6; }
47633      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47634$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47635    fi
47636  fi
47637
47638    fi
47639  fi
47640
47641  if test "x$MSVCR_DLL" = x; then
47642    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47643$as_echo_n "checking for msvcr100.dll... " >&6; }
47644    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47645$as_echo "no" >&6; }
47646    as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
47647  fi
47648
47649
47650  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47651
47652  # Input might be given as Windows format, start by converting to
47653  # unix format.
47654  path="$MSVCR_DLL"
47655  new_path=`$CYGPATH -u "$path"`
47656
47657  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47658  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47659  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47660  # "foo.exe" is OK but "foo" is an error.
47661  #
47662  # This test is therefore slightly more accurate than "test -f" to check for file precense.
47663  # It is also a way to make sure we got the proper file name for the real test later on.
47664  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47665  if test "x$test_shortpath" = x; then
47666    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47667$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47668    as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
47669  fi
47670
47671  # Call helper function which possibly converts this using DOS-style short mode.
47672  # If so, the updated path is stored in $new_path.
47673
47674  input_path="$new_path"
47675  # Check if we need to convert this using DOS-style short mode. If the path
47676  # contains just simple characters, use it. Otherwise (spaces, weird characters),
47677  # take no chances and rewrite it.
47678  # Note: m4 eats our [], so we need to use [ and ] instead.
47679  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47680  if test "x$has_forbidden_chars" != x; then
47681    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47682    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47683    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47684    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47685      # Going to short mode and back again did indeed matter. Since short mode is
47686      # case insensitive, let's make it lowercase to improve readability.
47687      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47688      # Now convert it back to Unix-stile (cygpath)
47689      input_path=`$CYGPATH -u "$shortmode_path"`
47690      new_path="$input_path"
47691    fi
47692  fi
47693
47694  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47695  if test "x$test_cygdrive_prefix" = x; then
47696    # As a simple fix, exclude /usr/bin since it's not a real path.
47697    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47698      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47699      # a path prefixed by /cygdrive for fixpath to work.
47700      new_path="$CYGWIN_ROOT_PATH$input_path"
47701    fi
47702  fi
47703
47704
47705  if test "x$path" != "x$new_path"; then
47706    MSVCR_DLL="$new_path"
47707    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47708$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47709  fi
47710
47711  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47712
47713  path="$MSVCR_DLL"
47714  has_colon=`$ECHO $path | $GREP ^.:`
47715  new_path="$path"
47716  if test "x$has_colon" = x; then
47717    # Not in mixed or Windows style, start by that.
47718    new_path=`cmd //c echo $path`
47719  fi
47720
47721
47722  input_path="$new_path"
47723  # Check if we need to convert this using DOS-style short mode. If the path
47724  # contains just simple characters, use it. Otherwise (spaces, weird characters),
47725  # take no chances and rewrite it.
47726  # Note: m4 eats our [], so we need to use [ and ] instead.
47727  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47728  if test "x$has_forbidden_chars" != x; then
47729    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47730    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47731  fi
47732
47733
47734  windows_path="$new_path"
47735  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47736    unix_path=`$CYGPATH -u "$windows_path"`
47737    new_path="$unix_path"
47738  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47739    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47740    new_path="$unix_path"
47741  fi
47742
47743  if test "x$path" != "x$new_path"; then
47744    MSVCR_DLL="$new_path"
47745    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47746$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47747  fi
47748
47749  # Save the first 10 bytes of this path to the storage, so fixpath can work.
47750  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47751
47752  else
47753    # We're on a posix platform. Hooray! :)
47754    path="$MSVCR_DLL"
47755    has_space=`$ECHO "$path" | $GREP " "`
47756    if test "x$has_space" != x; then
47757      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47758$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47759      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47760    fi
47761
47762    # Use eval to expand a potential ~
47763    eval path="$path"
47764    if test ! -f "$path" && test ! -d "$path"; then
47765      as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
47766    fi
47767
47768    MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
47769  fi
47770
47771
47772
47773
47774# Check whether --with-dxsdk was given.
47775if test "${with_dxsdk+set}" = set; then :
47776  withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
47777$as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
47778fi
47779
47780
47781
47782
47783# Check whether --with-dxsdk-lib was given.
47784if test "${with_dxsdk_lib+set}" = set; then :
47785  withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
47786$as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
47787fi
47788
47789
47790
47791
47792# Check whether --with-dxsdk-include was given.
47793if test "${with_dxsdk_include+set}" = set; then :
47794  withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
47795$as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
47796fi
47797
47798
47799  fi
47800
47801
47802
47803###############################################################################
47804#
47805# We need to do some final tweaking, when everything else is done.
47806#
47807###############################################################################
47808
47809
47810  HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
47811
47812
47813  # The name of the Service Agent jar.
47814  SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
47815  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47816    SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
47817  fi
47818
47819
47820
47821    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
47822$as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
47823
47824    if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then
47825      ENABLE_INTREE_EC=yes
47826      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47827$as_echo "yes" >&6; }
47828    else
47829      ENABLE_INTREE_EC=no
47830      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47831$as_echo "no" >&6; }
47832    fi
47833
47834
47835
47836
47837###############################################################################
47838#
47839# Configure parts of the build that only affect the build performance,
47840# not the result.
47841#
47842###############################################################################
47843
47844
47845  # How many cores do we have on this build system?
47846
47847# Check whether --with-num-cores was given.
47848if test "${with_num_cores+set}" = set; then :
47849  withval=$with_num_cores;
47850fi
47851
47852  if test "x$with_num_cores" = x; then
47853    # The number of cores were not specified, try to probe them.
47854
47855  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
47856$as_echo_n "checking for number of cores... " >&6; }
47857  NUM_CORES=1
47858  FOUND_CORES=no
47859
47860  if test -f /proc/cpuinfo; then
47861    # Looks like a Linux (or cygwin) system
47862    NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
47863    FOUND_CORES=yes
47864  elif test -x /usr/sbin/psrinfo; then
47865    # Looks like a Solaris system
47866    NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
47867    FOUND_CORES=yes
47868  elif test -x /usr/sbin/system_profiler; then
47869    # Looks like a MacOSX system
47870    NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
47871    FOUND_CORES=yes
47872  elif test "x$OPENJDK_BUILD_OS" = xaix ; then
47873    NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
47874    FOUND_CORES=yes
47875  elif test -n "$NUMBER_OF_PROCESSORS"; then
47876    # On windows, look in the env
47877    NUM_CORES=$NUMBER_OF_PROCESSORS
47878    FOUND_CORES=yes
47879  fi
47880
47881  if test "x$FOUND_CORES" = xyes; then
47882    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
47883$as_echo "$NUM_CORES" >&6; }
47884  else
47885    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
47886$as_echo "could not detect number of cores, defaulting to 1" >&6; }
47887    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
47888$as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
47889  fi
47890
47891  else
47892    NUM_CORES=$with_num_cores
47893  fi
47894
47895
47896
47897  # How much memory do we have on this build system?
47898
47899# Check whether --with-memory-size was given.
47900if test "${with_memory_size+set}" = set; then :
47901  withval=$with_memory_size;
47902fi
47903
47904  if test "x$with_memory_size" = x; then
47905    # The memory size was not specified, try to probe it.
47906
47907  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
47908$as_echo_n "checking for memory size... " >&6; }
47909  # Default to 1024 MB
47910  MEMORY_SIZE=1024
47911  FOUND_MEM=no
47912
47913  if test -f /proc/meminfo; then
47914    # Looks like a Linux (or cygwin) system
47915    MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
47916    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
47917    FOUND_MEM=yes
47918  elif test -x /usr/sbin/prtconf; then
47919    # Looks like a Solaris or AIX system
47920    MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
47921    FOUND_MEM=yes
47922  elif test -x /usr/sbin/system_profiler; then
47923    # Looks like a MacOSX system
47924    MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
47925    MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
47926    FOUND_MEM=yes
47927  elif test "x$OPENJDK_BUILD_OS" = xwindows; then
47928    # Windows, but without cygwin
47929    MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
47930    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
47931    FOUND_MEM=yes
47932  fi
47933
47934  if test "x$FOUND_MEM" = xyes; then
47935    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
47936$as_echo "$MEMORY_SIZE MB" >&6; }
47937  else
47938    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5
47939$as_echo "could not detect memory size, defaulting to 1024 MB" >&6; }
47940    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
47941$as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
47942  fi
47943
47944  else
47945    MEMORY_SIZE=$with_memory_size
47946  fi
47947
47948
47949
47950  # Provide a decent default number of parallel jobs for make depending on
47951  # number of cores, amount of memory and machine architecture.
47952
47953# Check whether --with-jobs was given.
47954if test "${with_jobs+set}" = set; then :
47955  withval=$with_jobs;
47956fi
47957
47958  if test "x$with_jobs" = x; then
47959    # Number of jobs was not specified, calculate.
47960    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
47961$as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
47962    # Approximate memory in GB, rounding up a bit.
47963    memory_gb=`expr $MEMORY_SIZE / 1100`
47964    # Pick the lowest of memory in gb and number of cores.
47965    if test "$memory_gb" -lt "$NUM_CORES"; then
47966      JOBS="$memory_gb"
47967    else
47968      JOBS="$NUM_CORES"
47969      # On bigger machines, leave some room for other processes to run
47970      if test "$JOBS" -gt "4"; then
47971        JOBS=`expr $JOBS '*' 90 / 100`
47972      fi
47973    fi
47974    # Cap number of jobs to 16
47975    if test "$JOBS" -gt "16"; then
47976      JOBS=16
47977    fi
47978    if test "$JOBS" -eq "0"; then
47979      JOBS=1
47980    fi
47981    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
47982$as_echo "$JOBS" >&6; }
47983  else
47984    JOBS=$with_jobs
47985  fi
47986
47987
47988
47989# Setup smart javac (after cores and memory have been setup)
47990
47991
47992# Check whether --with-sjavac-server-java was given.
47993if test "${with_sjavac_server_java+set}" = set; then :
47994  withval=$with_sjavac_server_java;
47995fi
47996
47997
47998  if test "x$with_sjavac_server_java" != x; then
47999    SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
48000    FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
48001    if test "x$FOUND_VERSION" = x; then
48002      as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
48003    fi
48004  else
48005    SJAVAC_SERVER_JAVA=""
48006    # Hotspot specific options.
48007
48008  $ECHO "Check if jvm arg is ok: -verbosegc" >&5
48009  $ECHO "Command: $JAVA -verbosegc -version" >&5
48010  OUTPUT=`$JAVA -verbosegc -version 2>&1`
48011  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48012  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48013  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48014    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc"
48015    JVM_ARG_OK=true
48016  else
48017    $ECHO "Arg failed:" >&5
48018    $ECHO "$OUTPUT" >&5
48019    JVM_ARG_OK=false
48020  fi
48021
48022    # JRockit specific options.
48023
48024  $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5
48025  $ECHO "Command: $JAVA -Xverbose:gc -version" >&5
48026  OUTPUT=`$JAVA -Xverbose:gc -version 2>&1`
48027  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48028  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48029  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48030    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc"
48031    JVM_ARG_OK=true
48032  else
48033    $ECHO "Arg failed:" >&5
48034    $ECHO "$OUTPUT" >&5
48035    JVM_ARG_OK=false
48036  fi
48037
48038    SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA"
48039  fi
48040
48041
48042  if test "$MEMORY_SIZE" -gt "2500"; then
48043
48044  $ECHO "Check if jvm arg is ok: -d64" >&5
48045  $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
48046  OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
48047  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48048  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48049  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48050    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64"
48051    JVM_ARG_OK=true
48052  else
48053    $ECHO "Arg failed:" >&5
48054    $ECHO "$OUTPUT" >&5
48055    JVM_ARG_OK=false
48056  fi
48057
48058    if test "$JVM_ARG_OK" = true; then
48059      JVM_64BIT=true
48060      JVM_ARG_OK=false
48061    fi
48062  fi
48063
48064  if test "$JVM_64BIT" = true; then
48065    if test "$MEMORY_SIZE" -gt "17000"; then
48066
48067  $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5
48068  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5
48069  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1`
48070  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48071  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48072  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48073    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G"
48074    JVM_ARG_OK=true
48075  else
48076    $ECHO "Arg failed:" >&5
48077    $ECHO "$OUTPUT" >&5
48078    JVM_ARG_OK=false
48079  fi
48080
48081    fi
48082    if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then
48083
48084  $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5
48085  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5
48086  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1`
48087  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48088  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48089  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48090    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G"
48091    JVM_ARG_OK=true
48092  else
48093    $ECHO "Arg failed:" >&5
48094    $ECHO "$OUTPUT" >&5
48095    JVM_ARG_OK=false
48096  fi
48097
48098    fi
48099    if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then
48100
48101  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5
48102  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5
48103  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1`
48104  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48105  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48106  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48107    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G"
48108    JVM_ARG_OK=true
48109  else
48110    $ECHO "Arg failed:" >&5
48111    $ECHO "$OUTPUT" >&5
48112    JVM_ARG_OK=false
48113  fi
48114
48115    fi
48116    if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then
48117
48118  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5
48119  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5
48120  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1`
48121  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48122  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48123  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48124    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M"
48125    JVM_ARG_OK=true
48126  else
48127    $ECHO "Arg failed:" >&5
48128    $ECHO "$OUTPUT" >&5
48129    JVM_ARG_OK=false
48130  fi
48131
48132    fi
48133  fi
48134  if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then
48135
48136  $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5
48137  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5
48138  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1`
48139  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48140  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48141  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48142    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M"
48143    JVM_ARG_OK=true
48144  else
48145    $ECHO "Arg failed:" >&5
48146    $ECHO "$OUTPUT" >&5
48147    JVM_ARG_OK=false
48148  fi
48149
48150  fi
48151  if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then
48152
48153  $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5
48154  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5
48155  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1`
48156  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48157  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48158  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48159    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M"
48160    JVM_ARG_OK=true
48161  else
48162    $ECHO "Arg failed:" >&5
48163    $ECHO "$OUTPUT" >&5
48164    JVM_ARG_OK=false
48165  fi
48166
48167  fi
48168  if test "$JVM_ARG_OK" = false; then
48169
48170  $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5
48171  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5
48172  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1`
48173  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48174  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48175  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48176    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M"
48177    JVM_ARG_OK=true
48178  else
48179    $ECHO "Arg failed:" >&5
48180    $ECHO "$OUTPUT" >&5
48181    JVM_ARG_OK=false
48182  fi
48183
48184  fi
48185
48186  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
48187$as_echo_n "checking whether to use sjavac... " >&6; }
48188  # Check whether --enable-sjavac was given.
48189if test "${enable_sjavac+set}" = set; then :
48190  enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
48191else
48192  ENABLE_SJAVAC='no'
48193fi
48194
48195  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
48196$as_echo "$ENABLE_SJAVAC" >&6; }
48197
48198
48199  if test "x$ENABLE_SJAVAC" = xyes; then
48200    SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
48201  else
48202    SJAVAC_SERVER_DIR=
48203  fi
48204
48205
48206
48207# Can the C/C++ compiler use precompiled headers?
48208
48209
48210  ###############################################################################
48211  #
48212  # Can the C/C++ compiler use precompiled headers?
48213  #
48214  # Check whether --enable-precompiled-headers was given.
48215if test "${enable_precompiled_headers+set}" = set; then :
48216  enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
48217else
48218  ENABLE_PRECOMPH=yes
48219fi
48220
48221
48222  USE_PRECOMPILED_HEADER=1
48223  if test "x$ENABLE_PRECOMPH" = xno; then
48224    USE_PRECOMPILED_HEADER=0
48225  fi
48226
48227  if test "x$ENABLE_PRECOMPH" = xyes; then
48228    # Check that the compiler actually supports precomp headers.
48229    if test "x$TOOLCHAIN_TYPE" = xgcc; then
48230      { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
48231$as_echo_n "checking that precompiled headers work... " >&6; }
48232      echo "int alfa();" > conftest.h
48233      $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
48234      if test ! -f conftest.hpp.gch; then
48235        USE_PRECOMPILED_HEADER=0
48236        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48237$as_echo "no" >&6; }
48238      else
48239        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48240$as_echo "yes" >&6; }
48241      fi
48242      rm -f conftest.h conftest.hpp.gch
48243    fi
48244  fi
48245
48246
48247
48248
48249# Setup use of ccache, if available
48250
48251  # Check whether --enable-ccache was given.
48252if test "${enable_ccache+set}" = set; then :
48253  enableval=$enable_ccache;
48254fi
48255
48256
48257  CCACHE=
48258  { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48259$as_echo_n "checking is ccache enabled... " >&6; }
48260  ENABLE_CCACHE=$enable_ccache
48261  if test "x$enable_ccache" = xyes; then
48262    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48263$as_echo "yes" >&6; }
48264    OLD_PATH="$PATH"
48265    if test "x$TOOLS_DIR" != x; then
48266      PATH=$TOOLS_DIR:$PATH
48267    fi
48268
48269
48270
48271  # Publish this variable in the help.
48272
48273
48274  if test "x$CCACHE" = x; then
48275    # The variable is not set by user, try to locate tool using the code snippet
48276    for ac_prog in ccache
48277do
48278  # Extract the first word of "$ac_prog", so it can be a program name with args.
48279set dummy $ac_prog; ac_word=$2
48280{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48281$as_echo_n "checking for $ac_word... " >&6; }
48282if ${ac_cv_path_CCACHE+:} false; then :
48283  $as_echo_n "(cached) " >&6
48284else
48285  case $CCACHE in
48286  [\\/]* | ?:[\\/]*)
48287  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48288  ;;
48289  *)
48290  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48291for as_dir in $PATH
48292do
48293  IFS=$as_save_IFS
48294  test -z "$as_dir" && as_dir=.
48295    for ac_exec_ext in '' $ac_executable_extensions; do
48296  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48297    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48298    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48299    break 2
48300  fi
48301done
48302  done
48303IFS=$as_save_IFS
48304
48305  ;;
48306esac
48307fi
48308CCACHE=$ac_cv_path_CCACHE
48309if test -n "$CCACHE"; then
48310  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48311$as_echo "$CCACHE" >&6; }
48312else
48313  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48314$as_echo "no" >&6; }
48315fi
48316
48317
48318  test -n "$CCACHE" && break
48319done
48320
48321  else
48322    # The variable is set, but is it from the command line or the environment?
48323
48324    # Try to remove the string !CCACHE! from our list.
48325    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
48326    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
48327      # If it failed, the variable was not from the command line. Ignore it,
48328      # but warn the user (except for BASH, which is always set by the calling BASH).
48329      if test "xCCACHE" != xBASH; then
48330        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
48331$as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
48332      fi
48333      # Try to locate tool using the code snippet
48334      for ac_prog in ccache
48335do
48336  # Extract the first word of "$ac_prog", so it can be a program name with args.
48337set dummy $ac_prog; ac_word=$2
48338{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48339$as_echo_n "checking for $ac_word... " >&6; }
48340if ${ac_cv_path_CCACHE+:} false; then :
48341  $as_echo_n "(cached) " >&6
48342else
48343  case $CCACHE in
48344  [\\/]* | ?:[\\/]*)
48345  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48346  ;;
48347  *)
48348  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48349for as_dir in $PATH
48350do
48351  IFS=$as_save_IFS
48352  test -z "$as_dir" && as_dir=.
48353    for ac_exec_ext in '' $ac_executable_extensions; do
48354  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48355    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48356    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48357    break 2
48358  fi
48359done
48360  done
48361IFS=$as_save_IFS
48362
48363  ;;
48364esac
48365fi
48366CCACHE=$ac_cv_path_CCACHE
48367if test -n "$CCACHE"; then
48368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48369$as_echo "$CCACHE" >&6; }
48370else
48371  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48372$as_echo "no" >&6; }
48373fi
48374
48375
48376  test -n "$CCACHE" && break
48377done
48378
48379    else
48380      # If it succeeded, then it was overridden by the user. We will use it
48381      # for the tool.
48382
48383      # First remove it from the list of overridden variables, so we can test
48384      # for unknown variables in the end.
48385      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
48386
48387      # Check if the provided tool contains a complete path.
48388      tool_specified="$CCACHE"
48389      tool_basename="${tool_specified##*/}"
48390      if test "x$tool_basename" = "x$tool_specified"; then
48391        # A command without a complete path is provided, search $PATH.
48392        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
48393$as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
48394        # Extract the first word of "$tool_basename", so it can be a program name with args.
48395set dummy $tool_basename; ac_word=$2
48396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48397$as_echo_n "checking for $ac_word... " >&6; }
48398if ${ac_cv_path_CCACHE+:} false; then :
48399  $as_echo_n "(cached) " >&6
48400else
48401  case $CCACHE in
48402  [\\/]* | ?:[\\/]*)
48403  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48404  ;;
48405  *)
48406  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48407for as_dir in $PATH
48408do
48409  IFS=$as_save_IFS
48410  test -z "$as_dir" && as_dir=.
48411    for ac_exec_ext in '' $ac_executable_extensions; do
48412  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48413    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48414    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48415    break 2
48416  fi
48417done
48418  done
48419IFS=$as_save_IFS
48420
48421  ;;
48422esac
48423fi
48424CCACHE=$ac_cv_path_CCACHE
48425if test -n "$CCACHE"; then
48426  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48427$as_echo "$CCACHE" >&6; }
48428else
48429  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48430$as_echo "no" >&6; }
48431fi
48432
48433
48434        if test "x$CCACHE" = x; then
48435          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
48436        fi
48437      else
48438        # Otherwise we believe it is a complete path. Use it as it is.
48439        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
48440$as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
48441        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
48442$as_echo_n "checking for CCACHE... " >&6; }
48443        if test ! -x "$tool_specified"; then
48444          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
48445$as_echo "not found" >&6; }
48446          as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
48447        fi
48448        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
48449$as_echo "$tool_specified" >&6; }
48450      fi
48451    fi
48452  fi
48453
48454
48455
48456  if test "x$CCACHE" = x; then
48457    as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
48458  fi
48459
48460
48461    CCACHE_STATUS="enabled"
48462    PATH="$OLD_PATH"
48463  elif test "x$enable_ccache" = xno; then
48464    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
48465$as_echo "no, explicitly disabled" >&6; }
48466  elif test "x$enable_ccache" = x; then
48467    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48468$as_echo "no" >&6; }
48469  else
48470    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
48471$as_echo "unknown" >&6; }
48472    as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
48473  fi
48474
48475
48476
48477# Check whether --with-ccache-dir was given.
48478if test "${with_ccache_dir+set}" = set; then :
48479  withval=$with_ccache_dir;
48480fi
48481
48482
48483  if test "x$with_ccache_dir" != x; then
48484    # When using a non home ccache directory, assume the use is to share ccache files
48485    # with other users. Thus change the umask.
48486    SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
48487    if test "x$CCACHE" = x; then
48488      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
48489$as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
48490    fi
48491  fi
48492
48493  if test "x$CCACHE" != x; then
48494
48495  if test "x$CCACHE" != x; then
48496    # Only use ccache if it is 3.1.4 or later, which supports
48497    # precompiled headers.
48498    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
48499$as_echo_n "checking if ccache supports precompiled headers... " >&6; }
48500    HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
48501    if test "x$HAS_GOOD_CCACHE" = x; then
48502      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
48503$as_echo "no, disabling ccache" >&6; }
48504      CCACHE=
48505      CCACHE_STATUS="disabled"
48506    else
48507      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48508$as_echo "yes" >&6; }
48509      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
48510$as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
48511      PUSHED_FLAGS="$CXXFLAGS"
48512      CXXFLAGS="-fpch-preprocess $CXXFLAGS"
48513      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48514/* end confdefs.h.  */
48515
48516int
48517main ()
48518{
48519
48520  ;
48521  return 0;
48522}
48523_ACEOF
48524if ac_fn_cxx_try_compile "$LINENO"; then :
48525  CC_KNOWS_CCACHE_TRICK=yes
48526else
48527  CC_KNOWS_CCACHE_TRICK=no
48528fi
48529rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
48530      CXXFLAGS="$PUSHED_FLAGS"
48531      if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
48532        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48533$as_echo "yes" >&6; }
48534      else
48535        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
48536$as_echo "no, disabling ccaching of precompiled headers" >&6; }
48537        CCACHE=
48538        CCACHE_STATUS="disabled"
48539      fi
48540    fi
48541  fi
48542
48543  if test "x$CCACHE" != x; then
48544    CCACHE_SLOPPINESS=time_macros
48545    CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
48546    CCACHE_FLAGS=-fpch-preprocess
48547
48548    if test "x$SET_CCACHE_DIR" != x; then
48549      mkdir -p $CCACHE_DIR > /dev/null 2>&1
48550      chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
48551    fi
48552  fi
48553
48554  fi
48555
48556
48557###############################################################################
48558#
48559# And now the finish...
48560#
48561###############################################################################
48562
48563# Check for some common pitfalls
48564
48565  if test x"$OPENJDK_BUILD_OS" = xwindows; then
48566    file_to_test="$SRC_ROOT/LICENSE"
48567    if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
48568      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
48569    fi
48570  fi
48571
48572
48573  # Did user specify any unknown variables?
48574
48575  if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
48576    # Replace the separating ! with spaces before presenting for end user.
48577    unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
48578    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
48579$as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
48580  fi
48581
48582
48583  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
48584$as_echo_n "checking if build directory is on local disk... " >&6; }
48585
48586  # df -l lists only local disks; if the given directory is not found then
48587  # a non-zero exit code is given
48588  if test "x$DF" = x; then
48589    if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48590      # msys does not have df; use Windows "net use" instead.
48591      IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
48592      if test "x$IS_NETWORK_DISK" = x; then
48593        OUTPUT_DIR_IS_LOCAL="yes"
48594      else
48595        OUTPUT_DIR_IS_LOCAL="no"
48596      fi
48597    else
48598      # No df here, say it's local
48599      OUTPUT_DIR_IS_LOCAL="yes"
48600    fi
48601  else
48602    if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
48603      OUTPUT_DIR_IS_LOCAL="yes"
48604    else
48605      OUTPUT_DIR_IS_LOCAL="no"
48606    fi
48607  fi
48608
48609  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
48610$as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
48611
48612
48613
48614  # Check if the user has any old-style ALT_ variables set.
48615  FOUND_ALT_VARIABLES=`env | grep ^ALT_`
48616
48617  # Before generating output files, test if they exist. If they do, this is a reconfigure.
48618  # Since we can't properly handle the dependencies for this, warn the user about the situation
48619  if test -e $OUTPUT_ROOT/spec.gmk; then
48620    IS_RECONFIGURE=yes
48621  else
48622    IS_RECONFIGURE=no
48623  fi
48624
48625
48626# At the end, call the custom hook. (Dummy macro if no custom sources available)
48627
48628
48629# We're messing a bit with internal autoconf variables to put the config.status
48630# in the output directory instead of the current directory.
48631CONFIG_STATUS="$OUTPUT_ROOT/config.status"
48632
48633# Create the actual output files. Now the main work of configure is done.
48634cat >confcache <<\_ACEOF
48635# This file is a shell script that caches the results of configure
48636# tests run on this system so they can be shared between configure
48637# scripts and configure runs, see configure's option --config-cache.
48638# It is not useful on other systems.  If it contains results you don't
48639# want to keep, you may remove or edit it.
48640#
48641# config.status only pays attention to the cache file if you give it
48642# the --recheck option to rerun configure.
48643#
48644# `ac_cv_env_foo' variables (set or unset) will be overridden when
48645# loading this file, other *unset* `ac_cv_foo' will be assigned the
48646# following values.
48647
48648_ACEOF
48649
48650# The following way of writing the cache mishandles newlines in values,
48651# but we know of no workaround that is simple, portable, and efficient.
48652# So, we kill variables containing newlines.
48653# Ultrix sh set writes to stderr and can't be redirected directly,
48654# and sets the high bit in the cache file unless we assign to the vars.
48655(
48656  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
48657    eval ac_val=\$$ac_var
48658    case $ac_val in #(
48659    *${as_nl}*)
48660      case $ac_var in #(
48661      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
48662$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
48663      esac
48664      case $ac_var in #(
48665      _ | IFS | as_nl) ;; #(
48666      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
48667      *) { eval $ac_var=; unset $ac_var;} ;;
48668      esac ;;
48669    esac
48670  done
48671
48672  (set) 2>&1 |
48673    case $as_nl`(ac_space=' '; set) 2>&1` in #(
48674    *${as_nl}ac_space=\ *)
48675      # `set' does not quote correctly, so add quotes: double-quote
48676      # substitution turns \\\\ into \\, and sed turns \\ into \.
48677      sed -n \
48678	"s/'/'\\\\''/g;
48679	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
48680      ;; #(
48681    *)
48682      # `set' quotes correctly as required by POSIX, so do not add quotes.
48683      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
48684      ;;
48685    esac |
48686    sort
48687) |
48688  sed '
48689     /^ac_cv_env_/b end
48690     t clear
48691     :clear
48692     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
48693     t end
48694     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
48695     :end' >>confcache
48696if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
48697  if test -w "$cache_file"; then
48698    if test "x$cache_file" != "x/dev/null"; then
48699      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
48700$as_echo "$as_me: updating cache $cache_file" >&6;}
48701      if test ! -f "$cache_file" || test -h "$cache_file"; then
48702	cat confcache >"$cache_file"
48703      else
48704        case $cache_file in #(
48705        */* | ?:*)
48706	  mv -f confcache "$cache_file"$$ &&
48707	  mv -f "$cache_file"$$ "$cache_file" ;; #(
48708        *)
48709	  mv -f confcache "$cache_file" ;;
48710	esac
48711      fi
48712    fi
48713  else
48714    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
48715$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
48716  fi
48717fi
48718rm -f confcache
48719
48720test "x$prefix" = xNONE && prefix=$ac_default_prefix
48721# Let make expand exec_prefix.
48722test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
48723
48724DEFS=-DHAVE_CONFIG_H
48725
48726ac_libobjs=
48727ac_ltlibobjs=
48728U=
48729for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
48730  # 1. Remove the extension, and $U if already installed.
48731  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
48732  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
48733  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
48734  #    will be set to the directory where LIBOBJS objects are built.
48735  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
48736  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
48737done
48738LIBOBJS=$ac_libobjs
48739
48740LTLIBOBJS=$ac_ltlibobjs
48741
48742
48743
48744: "${CONFIG_STATUS=./config.status}"
48745ac_write_fail=0
48746ac_clean_files_save=$ac_clean_files
48747ac_clean_files="$ac_clean_files $CONFIG_STATUS"
48748{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
48749$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
48750as_write_fail=0
48751cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
48752#! $SHELL
48753# Generated by $as_me.
48754# Run this file to recreate the current configuration.
48755# Compiler output produced by configure, useful for debugging
48756# configure, is in config.log if it exists.
48757
48758debug=false
48759ac_cs_recheck=false
48760ac_cs_silent=false
48761
48762SHELL=\${CONFIG_SHELL-$SHELL}
48763export SHELL
48764_ASEOF
48765cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
48766## -------------------- ##
48767## M4sh Initialization. ##
48768## -------------------- ##
48769
48770# Be more Bourne compatible
48771DUALCASE=1; export DUALCASE # for MKS sh
48772if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
48773  emulate sh
48774  NULLCMD=:
48775  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
48776  # is contrary to our usage.  Disable this feature.
48777  alias -g '${1+"$@"}'='"$@"'
48778  setopt NO_GLOB_SUBST
48779else
48780  case `(set -o) 2>/dev/null` in #(
48781  *posix*) :
48782    set -o posix ;; #(
48783  *) :
48784     ;;
48785esac
48786fi
48787
48788
48789as_nl='
48790'
48791export as_nl
48792# Printing a long string crashes Solaris 7 /usr/bin/printf.
48793as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
48794as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
48795as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
48796# Prefer a ksh shell builtin over an external printf program on Solaris,
48797# but without wasting forks for bash or zsh.
48798if test -z "$BASH_VERSION$ZSH_VERSION" \
48799    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
48800  as_echo='print -r --'
48801  as_echo_n='print -rn --'
48802elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48803  as_echo='printf %s\n'
48804  as_echo_n='printf %s'
48805else
48806  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
48807    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
48808    as_echo_n='/usr/ucb/echo -n'
48809  else
48810    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
48811    as_echo_n_body='eval
48812      arg=$1;
48813      case $arg in #(
48814      *"$as_nl"*)
48815	expr "X$arg" : "X\\(.*\\)$as_nl";
48816	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
48817      esac;
48818      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
48819    '
48820    export as_echo_n_body
48821    as_echo_n='sh -c $as_echo_n_body as_echo'
48822  fi
48823  export as_echo_body
48824  as_echo='sh -c $as_echo_body as_echo'
48825fi
48826
48827# The user is always right.
48828if test "${PATH_SEPARATOR+set}" != set; then
48829  PATH_SEPARATOR=:
48830  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
48831    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
48832      PATH_SEPARATOR=';'
48833  }
48834fi
48835
48836
48837# IFS
48838# We need space, tab and new line, in precisely that order.  Quoting is
48839# there to prevent editors from complaining about space-tab.
48840# (If _AS_PATH_WALK were called with IFS unset, it would disable word
48841# splitting by setting IFS to empty value.)
48842IFS=" ""	$as_nl"
48843
48844# Find who we are.  Look in the path if we contain no directory separator.
48845as_myself=
48846case $0 in #((
48847  *[\\/]* ) as_myself=$0 ;;
48848  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48849for as_dir in $PATH
48850do
48851  IFS=$as_save_IFS
48852  test -z "$as_dir" && as_dir=.
48853    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
48854  done
48855IFS=$as_save_IFS
48856
48857     ;;
48858esac
48859# We did not find ourselves, most probably we were run as `sh COMMAND'
48860# in which case we are not to be found in the path.
48861if test "x$as_myself" = x; then
48862  as_myself=$0
48863fi
48864if test ! -f "$as_myself"; then
48865  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
48866  exit 1
48867fi
48868
48869# Unset variables that we do not need and which cause bugs (e.g. in
48870# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
48871# suppresses any "Segmentation fault" message there.  '((' could
48872# trigger a bug in pdksh 5.2.14.
48873for as_var in BASH_ENV ENV MAIL MAILPATH
48874do eval test x\${$as_var+set} = xset \
48875  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
48876done
48877PS1='$ '
48878PS2='> '
48879PS4='+ '
48880
48881# NLS nuisances.
48882LC_ALL=C
48883export LC_ALL
48884LANGUAGE=C
48885export LANGUAGE
48886
48887# CDPATH.
48888(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
48889
48890
48891# as_fn_error STATUS ERROR [LINENO LOG_FD]
48892# ----------------------------------------
48893# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
48894# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
48895# script with STATUS, using 1 if that was 0.
48896as_fn_error ()
48897{
48898  as_status=$1; test $as_status -eq 0 && as_status=1
48899  if test "$4"; then
48900    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
48901    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
48902  fi
48903  $as_echo "$as_me: error: $2" >&2
48904  as_fn_exit $as_status
48905} # as_fn_error
48906
48907
48908# as_fn_set_status STATUS
48909# -----------------------
48910# Set $? to STATUS, without forking.
48911as_fn_set_status ()
48912{
48913  return $1
48914} # as_fn_set_status
48915
48916# as_fn_exit STATUS
48917# -----------------
48918# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
48919as_fn_exit ()
48920{
48921  set +e
48922  as_fn_set_status $1
48923  exit $1
48924} # as_fn_exit
48925
48926# as_fn_unset VAR
48927# ---------------
48928# Portably unset VAR.
48929as_fn_unset ()
48930{
48931  { eval $1=; unset $1;}
48932}
48933as_unset=as_fn_unset
48934# as_fn_append VAR VALUE
48935# ----------------------
48936# Append the text in VALUE to the end of the definition contained in VAR. Take
48937# advantage of any shell optimizations that allow amortized linear growth over
48938# repeated appends, instead of the typical quadratic growth present in naive
48939# implementations.
48940if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
48941  eval 'as_fn_append ()
48942  {
48943    eval $1+=\$2
48944  }'
48945else
48946  as_fn_append ()
48947  {
48948    eval $1=\$$1\$2
48949  }
48950fi # as_fn_append
48951
48952# as_fn_arith ARG...
48953# ------------------
48954# Perform arithmetic evaluation on the ARGs, and store the result in the
48955# global $as_val. Take advantage of shells that can avoid forks. The arguments
48956# must be portable across $(()) and expr.
48957if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
48958  eval 'as_fn_arith ()
48959  {
48960    as_val=$(( $* ))
48961  }'
48962else
48963  as_fn_arith ()
48964  {
48965    as_val=`expr "$@" || test $? -eq 1`
48966  }
48967fi # as_fn_arith
48968
48969
48970if expr a : '\(a\)' >/dev/null 2>&1 &&
48971   test "X`expr 00001 : '.*\(...\)'`" = X001; then
48972  as_expr=expr
48973else
48974  as_expr=false
48975fi
48976
48977if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
48978  as_basename=basename
48979else
48980  as_basename=false
48981fi
48982
48983if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
48984  as_dirname=dirname
48985else
48986  as_dirname=false
48987fi
48988
48989as_me=`$as_basename -- "$0" ||
48990$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
48991	 X"$0" : 'X\(//\)$' \| \
48992	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
48993$as_echo X/"$0" |
48994    sed '/^.*\/\([^/][^/]*\)\/*$/{
48995	    s//\1/
48996	    q
48997	  }
48998	  /^X\/\(\/\/\)$/{
48999	    s//\1/
49000	    q
49001	  }
49002	  /^X\/\(\/\).*/{
49003	    s//\1/
49004	    q
49005	  }
49006	  s/.*/./; q'`
49007
49008# Avoid depending upon Character Ranges.
49009as_cr_letters='abcdefghijklmnopqrstuvwxyz'
49010as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
49011as_cr_Letters=$as_cr_letters$as_cr_LETTERS
49012as_cr_digits='0123456789'
49013as_cr_alnum=$as_cr_Letters$as_cr_digits
49014
49015ECHO_C= ECHO_N= ECHO_T=
49016case `echo -n x` in #(((((
49017-n*)
49018  case `echo 'xy\c'` in
49019  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
49020  xy)  ECHO_C='\c';;
49021  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
49022       ECHO_T='	';;
49023  esac;;
49024*)
49025  ECHO_N='-n';;
49026esac
49027
49028rm -f conf$$ conf$$.exe conf$$.file
49029if test -d conf$$.dir; then
49030  rm -f conf$$.dir/conf$$.file
49031else
49032  rm -f conf$$.dir
49033  mkdir conf$$.dir 2>/dev/null
49034fi
49035if (echo >conf$$.file) 2>/dev/null; then
49036  if ln -s conf$$.file conf$$ 2>/dev/null; then
49037    as_ln_s='ln -s'
49038    # ... but there are two gotchas:
49039    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
49040    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
49041    # In both cases, we have to default to `cp -pR'.
49042    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
49043      as_ln_s='cp -pR'
49044  elif ln conf$$.file conf$$ 2>/dev/null; then
49045    as_ln_s=ln
49046  else
49047    as_ln_s='cp -pR'
49048  fi
49049else
49050  as_ln_s='cp -pR'
49051fi
49052rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
49053rmdir conf$$.dir 2>/dev/null
49054
49055
49056# as_fn_mkdir_p
49057# -------------
49058# Create "$as_dir" as a directory, including parents if necessary.
49059as_fn_mkdir_p ()
49060{
49061
49062  case $as_dir in #(
49063  -*) as_dir=./$as_dir;;
49064  esac
49065  test -d "$as_dir" || eval $as_mkdir_p || {
49066    as_dirs=
49067    while :; do
49068      case $as_dir in #(
49069      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
49070      *) as_qdir=$as_dir;;
49071      esac
49072      as_dirs="'$as_qdir' $as_dirs"
49073      as_dir=`$as_dirname -- "$as_dir" ||
49074$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49075	 X"$as_dir" : 'X\(//\)[^/]' \| \
49076	 X"$as_dir" : 'X\(//\)$' \| \
49077	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
49078$as_echo X"$as_dir" |
49079    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49080	    s//\1/
49081	    q
49082	  }
49083	  /^X\(\/\/\)[^/].*/{
49084	    s//\1/
49085	    q
49086	  }
49087	  /^X\(\/\/\)$/{
49088	    s//\1/
49089	    q
49090	  }
49091	  /^X\(\/\).*/{
49092	    s//\1/
49093	    q
49094	  }
49095	  s/.*/./; q'`
49096      test -d "$as_dir" && break
49097    done
49098    test -z "$as_dirs" || eval "mkdir $as_dirs"
49099  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
49100
49101
49102} # as_fn_mkdir_p
49103if mkdir -p . 2>/dev/null; then
49104  as_mkdir_p='mkdir -p "$as_dir"'
49105else
49106  test -d ./-p && rmdir ./-p
49107  as_mkdir_p=false
49108fi
49109
49110
49111# as_fn_executable_p FILE
49112# -----------------------
49113# Test if FILE is an executable regular file.
49114as_fn_executable_p ()
49115{
49116  test -f "$1" && test -x "$1"
49117} # as_fn_executable_p
49118as_test_x='test -x'
49119as_executable_p=as_fn_executable_p
49120
49121# Sed expression to map a string onto a valid CPP name.
49122as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
49123
49124# Sed expression to map a string onto a valid variable name.
49125as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
49126
49127
49128exec 6>&1
49129## ----------------------------------- ##
49130## Main body of $CONFIG_STATUS script. ##
49131## ----------------------------------- ##
49132_ASEOF
49133test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
49134
49135cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49136# Save the log message, to keep $0 and so on meaningful, and to
49137# report actual input values of CONFIG_FILES etc. instead of their
49138# values after options handling.
49139ac_log="
49140This file was extended by OpenJDK $as_me jdk8, which was
49141generated by GNU Autoconf 2.69.  Invocation command line was
49142
49143  CONFIG_FILES    = $CONFIG_FILES
49144  CONFIG_HEADERS  = $CONFIG_HEADERS
49145  CONFIG_LINKS    = $CONFIG_LINKS
49146  CONFIG_COMMANDS = $CONFIG_COMMANDS
49147  $ $0 $@
49148
49149on `(hostname || uname -n) 2>/dev/null | sed 1q`
49150"
49151
49152_ACEOF
49153
49154case $ac_config_files in *"
49155"*) set x $ac_config_files; shift; ac_config_files=$*;;
49156esac
49157
49158case $ac_config_headers in *"
49159"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
49160esac
49161
49162
49163cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49164# Files that config.status was made for.
49165config_files="$ac_config_files"
49166config_headers="$ac_config_headers"
49167
49168_ACEOF
49169
49170cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49171ac_cs_usage="\
49172\`$as_me' instantiates files and other configuration actions
49173from templates according to the current configuration.  Unless the files
49174and actions are specified as TAGs, all are instantiated by default.
49175
49176Usage: $0 [OPTION]... [TAG]...
49177
49178  -h, --help       print this help, then exit
49179  -V, --version    print version number and configuration settings, then exit
49180      --config     print configuration, then exit
49181  -q, --quiet, --silent
49182                   do not print progress messages
49183  -d, --debug      don't remove temporary files
49184      --recheck    update $as_me by reconfiguring in the same conditions
49185      --file=FILE[:TEMPLATE]
49186                   instantiate the configuration file FILE
49187      --header=FILE[:TEMPLATE]
49188                   instantiate the configuration header FILE
49189
49190Configuration files:
49191$config_files
49192
49193Configuration headers:
49194$config_headers
49195
49196Report bugs to <build-dev@openjdk.java.net>.
49197OpenJDK home page: <http://openjdk.java.net>."
49198
49199_ACEOF
49200cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49201ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
49202ac_cs_version="\\
49203OpenJDK config.status jdk8
49204configured by $0, generated by GNU Autoconf 2.69,
49205  with options \\"\$ac_cs_config\\"
49206
49207Copyright (C) 2012 Free Software Foundation, Inc.
49208This config.status script is free software; the Free Software Foundation
49209gives unlimited permission to copy, distribute and modify it."
49210
49211ac_pwd='$ac_pwd'
49212srcdir='$srcdir'
49213AWK='$AWK'
49214test -n "\$AWK" || AWK=awk
49215_ACEOF
49216
49217cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49218# The default lists apply if the user does not specify any file.
49219ac_need_defaults=:
49220while test $# != 0
49221do
49222  case $1 in
49223  --*=?*)
49224    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49225    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
49226    ac_shift=:
49227    ;;
49228  --*=)
49229    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49230    ac_optarg=
49231    ac_shift=:
49232    ;;
49233  *)
49234    ac_option=$1
49235    ac_optarg=$2
49236    ac_shift=shift
49237    ;;
49238  esac
49239
49240  case $ac_option in
49241  # Handling of the options.
49242  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
49243    ac_cs_recheck=: ;;
49244  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
49245    $as_echo "$ac_cs_version"; exit ;;
49246  --config | --confi | --conf | --con | --co | --c )
49247    $as_echo "$ac_cs_config"; exit ;;
49248  --debug | --debu | --deb | --de | --d | -d )
49249    debug=: ;;
49250  --file | --fil | --fi | --f )
49251    $ac_shift
49252    case $ac_optarg in
49253    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49254    '') as_fn_error $? "missing file argument" ;;
49255    esac
49256    as_fn_append CONFIG_FILES " '$ac_optarg'"
49257    ac_need_defaults=false;;
49258  --header | --heade | --head | --hea )
49259    $ac_shift
49260    case $ac_optarg in
49261    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49262    esac
49263    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
49264    ac_need_defaults=false;;
49265  --he | --h)
49266    # Conflict between --help and --header
49267    as_fn_error $? "ambiguous option: \`$1'
49268Try \`$0 --help' for more information.";;
49269  --help | --hel | -h )
49270    $as_echo "$ac_cs_usage"; exit ;;
49271  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
49272  | -silent | --silent | --silen | --sile | --sil | --si | --s)
49273    ac_cs_silent=: ;;
49274
49275  # This is an error.
49276  -*) as_fn_error $? "unrecognized option: \`$1'
49277Try \`$0 --help' for more information." ;;
49278
49279  *) as_fn_append ac_config_targets " $1"
49280     ac_need_defaults=false ;;
49281
49282  esac
49283  shift
49284done
49285
49286ac_configure_extra_args=
49287
49288if $ac_cs_silent; then
49289  exec 6>/dev/null
49290  ac_configure_extra_args="$ac_configure_extra_args --silent"
49291fi
49292
49293_ACEOF
49294cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49295if \$ac_cs_recheck; then
49296  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
49297  shift
49298  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
49299  CONFIG_SHELL='$SHELL'
49300  export CONFIG_SHELL
49301  exec "\$@"
49302fi
49303
49304_ACEOF
49305cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49306exec 5>>config.log
49307{
49308  echo
49309  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
49310## Running $as_me. ##
49311_ASBOX
49312  $as_echo "$ac_log"
49313} >&5
49314
49315_ACEOF
49316cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49317_ACEOF
49318
49319cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49320
49321# Handling of arguments.
49322for ac_config_target in $ac_config_targets
49323do
49324  case $ac_config_target in
49325    "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;;
49326    "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
49327    "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
49328    "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
49329    "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
49330    "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;;
49331    "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
49332
49333  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
49334  esac
49335done
49336
49337
49338# If the user did not use the arguments to specify the items to instantiate,
49339# then the envvar interface is used.  Set only those that are not.
49340# We use the long form for the default assignment because of an extremely
49341# bizarre bug on SunOS 4.1.3.
49342if $ac_need_defaults; then
49343  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
49344  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
49345fi
49346
49347# Have a temporary directory for convenience.  Make it in the build tree
49348# simply because there is no reason against having it here, and in addition,
49349# creating and moving files from /tmp can sometimes cause problems.
49350# Hook for its removal unless debugging.
49351# Note that there is a small window in which the directory will not be cleaned:
49352# after its creation but before its name has been assigned to `$tmp'.
49353$debug ||
49354{
49355  tmp= ac_tmp=
49356  trap 'exit_status=$?
49357  : "${ac_tmp:=$tmp}"
49358  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
49359' 0
49360  trap 'as_fn_exit 1' 1 2 13 15
49361}
49362# Create a (secure) tmp directory for tmp files.
49363
49364{
49365  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
49366  test -d "$tmp"
49367}  ||
49368{
49369  tmp=./conf$$-$RANDOM
49370  (umask 077 && mkdir "$tmp")
49371} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
49372ac_tmp=$tmp
49373
49374# Set up the scripts for CONFIG_FILES section.
49375# No need to generate them if there are no CONFIG_FILES.
49376# This happens for instance with `./config.status config.h'.
49377if test -n "$CONFIG_FILES"; then
49378
49379
49380ac_cr=`echo X | tr X '\015'`
49381# On cygwin, bash can eat \r inside `` if the user requested igncr.
49382# But we know of no other shell where ac_cr would be empty at this
49383# point, so we can use a bashism as a fallback.
49384if test "x$ac_cr" = x; then
49385  eval ac_cr=\$\'\\r\'
49386fi
49387ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
49388if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
49389  ac_cs_awk_cr='\\r'
49390else
49391  ac_cs_awk_cr=$ac_cr
49392fi
49393
49394echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
49395_ACEOF
49396
49397
49398{
49399  echo "cat >conf$$subs.awk <<_ACEOF" &&
49400  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
49401  echo "_ACEOF"
49402} >conf$$subs.sh ||
49403  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49404ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
49405ac_delim='%!_!# '
49406for ac_last_try in false false false false false :; do
49407  . ./conf$$subs.sh ||
49408    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49409
49410  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
49411  if test $ac_delim_n = $ac_delim_num; then
49412    break
49413  elif $ac_last_try; then
49414    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49415  else
49416    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49417  fi
49418done
49419rm -f conf$$subs.sh
49420
49421cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49422cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
49423_ACEOF
49424sed -n '
49425h
49426s/^/S["/; s/!.*/"]=/
49427p
49428g
49429s/^[^!]*!//
49430:repl
49431t repl
49432s/'"$ac_delim"'$//
49433t delim
49434:nl
49435h
49436s/\(.\{148\}\)..*/\1/
49437t more1
49438s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
49439p
49440n
49441b repl
49442:more1
49443s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49444p
49445g
49446s/.\{148\}//
49447t nl
49448:delim
49449h
49450s/\(.\{148\}\)..*/\1/
49451t more2
49452s/["\\]/\\&/g; s/^/"/; s/$/"/
49453p
49454b
49455:more2
49456s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49457p
49458g
49459s/.\{148\}//
49460t delim
49461' <conf$$subs.awk | sed '
49462/^[^""]/{
49463  N
49464  s/\n//
49465}
49466' >>$CONFIG_STATUS || ac_write_fail=1
49467rm -f conf$$subs.awk
49468cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49469_ACAWK
49470cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
49471  for (key in S) S_is_set[key] = 1
49472  FS = ""
49473
49474}
49475{
49476  line = $ 0
49477  nfields = split(line, field, "@")
49478  substed = 0
49479  len = length(field[1])
49480  for (i = 2; i < nfields; i++) {
49481    key = field[i]
49482    keylen = length(key)
49483    if (S_is_set[key]) {
49484      value = S[key]
49485      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
49486      len += length(value) + length(field[++i])
49487      substed = 1
49488    } else
49489      len += 1 + keylen
49490  }
49491
49492  print line
49493}
49494
49495_ACAWK
49496_ACEOF
49497cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49498if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
49499  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
49500else
49501  cat
49502fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
49503  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
49504_ACEOF
49505
49506# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
49507# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
49508# trailing colons and then remove the whole line if VPATH becomes empty
49509# (actually we leave an empty line to preserve line numbers).
49510if test "x$srcdir" = x.; then
49511  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
49512h
49513s///
49514s/^/:/
49515s/[	 ]*$/:/
49516s/:\$(srcdir):/:/g
49517s/:\${srcdir}:/:/g
49518s/:@srcdir@:/:/g
49519s/^:*//
49520s/:*$//
49521x
49522s/\(=[	 ]*\).*/\1/
49523G
49524s/\n//
49525s/^[^=]*=[	 ]*$//
49526}'
49527fi
49528
49529cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49530fi # test -n "$CONFIG_FILES"
49531
49532# Set up the scripts for CONFIG_HEADERS section.
49533# No need to generate them if there are no CONFIG_HEADERS.
49534# This happens for instance with `./config.status Makefile'.
49535if test -n "$CONFIG_HEADERS"; then
49536cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
49537BEGIN {
49538_ACEOF
49539
49540# Transform confdefs.h into an awk script `defines.awk', embedded as
49541# here-document in config.status, that substitutes the proper values into
49542# config.h.in to produce config.h.
49543
49544# Create a delimiter string that does not exist in confdefs.h, to ease
49545# handling of long lines.
49546ac_delim='%!_!# '
49547for ac_last_try in false false :; do
49548  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
49549  if test -z "$ac_tt"; then
49550    break
49551  elif $ac_last_try; then
49552    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
49553  else
49554    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49555  fi
49556done
49557
49558# For the awk script, D is an array of macro values keyed by name,
49559# likewise P contains macro parameters if any.  Preserve backslash
49560# newline sequences.
49561
49562ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
49563sed -n '
49564s/.\{148\}/&'"$ac_delim"'/g
49565t rset
49566:rset
49567s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
49568t def
49569d
49570:def
49571s/\\$//
49572t bsnl
49573s/["\\]/\\&/g
49574s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
49575D["\1"]=" \3"/p
49576s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
49577d
49578:bsnl
49579s/["\\]/\\&/g
49580s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
49581D["\1"]=" \3\\\\\\n"\\/p
49582t cont
49583s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
49584t cont
49585d
49586:cont
49587n
49588s/.\{148\}/&'"$ac_delim"'/g
49589t clear
49590:clear
49591s/\\$//
49592t bsnlc
49593s/["\\]/\\&/g; s/^/"/; s/$/"/p
49594d
49595:bsnlc
49596s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
49597b cont
49598' <confdefs.h | sed '
49599s/'"$ac_delim"'/"\\\
49600"/g' >>$CONFIG_STATUS || ac_write_fail=1
49601
49602cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49603  for (key in D) D_is_set[key] = 1
49604  FS = ""
49605}
49606/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
49607  line = \$ 0
49608  split(line, arg, " ")
49609  if (arg[1] == "#") {
49610    defundef = arg[2]
49611    mac1 = arg[3]
49612  } else {
49613    defundef = substr(arg[1], 2)
49614    mac1 = arg[2]
49615  }
49616  split(mac1, mac2, "(") #)
49617  macro = mac2[1]
49618  prefix = substr(line, 1, index(line, defundef) - 1)
49619  if (D_is_set[macro]) {
49620    # Preserve the white space surrounding the "#".
49621    print prefix "define", macro P[macro] D[macro]
49622    next
49623  } else {
49624    # Replace #undef with comments.  This is necessary, for example,
49625    # in the case of _POSIX_SOURCE, which is predefined and required
49626    # on some systems where configure will not decide to define it.
49627    if (defundef == "undef") {
49628      print "/*", prefix defundef, macro, "*/"
49629      next
49630    }
49631  }
49632}
49633{ print }
49634_ACAWK
49635_ACEOF
49636cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49637  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
49638fi # test -n "$CONFIG_HEADERS"
49639
49640
49641eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
49642shift
49643for ac_tag
49644do
49645  case $ac_tag in
49646  :[FHLC]) ac_mode=$ac_tag; continue;;
49647  esac
49648  case $ac_mode$ac_tag in
49649  :[FHL]*:*);;
49650  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
49651  :[FH]-) ac_tag=-:-;;
49652  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
49653  esac
49654  ac_save_IFS=$IFS
49655  IFS=:
49656  set x $ac_tag
49657  IFS=$ac_save_IFS
49658  shift
49659  ac_file=$1
49660  shift
49661
49662  case $ac_mode in
49663  :L) ac_source=$1;;
49664  :[FH])
49665    ac_file_inputs=
49666    for ac_f
49667    do
49668      case $ac_f in
49669      -) ac_f="$ac_tmp/stdin";;
49670      *) # Look for the file first in the build tree, then in the source tree
49671	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
49672	 # because $ac_f cannot contain `:'.
49673	 test -f "$ac_f" ||
49674	   case $ac_f in
49675	   [\\/$]*) false;;
49676	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
49677	   esac ||
49678	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
49679      esac
49680      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
49681      as_fn_append ac_file_inputs " '$ac_f'"
49682    done
49683
49684    # Let's still pretend it is `configure' which instantiates (i.e., don't
49685    # use $as_me), people would be surprised to read:
49686    #    /* config.h.  Generated by config.status.  */
49687    configure_input='Generated from '`
49688	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
49689	`' by configure.'
49690    if test x"$ac_file" != x-; then
49691      configure_input="$ac_file.  $configure_input"
49692      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
49693$as_echo "$as_me: creating $ac_file" >&6;}
49694    fi
49695    # Neutralize special characters interpreted by sed in replacement strings.
49696    case $configure_input in #(
49697    *\&* | *\|* | *\\* )
49698       ac_sed_conf_input=`$as_echo "$configure_input" |
49699       sed 's/[\\\\&|]/\\\\&/g'`;; #(
49700    *) ac_sed_conf_input=$configure_input;;
49701    esac
49702
49703    case $ac_tag in
49704    *:-:* | *:-) cat >"$ac_tmp/stdin" \
49705      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
49706    esac
49707    ;;
49708  esac
49709
49710  ac_dir=`$as_dirname -- "$ac_file" ||
49711$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49712	 X"$ac_file" : 'X\(//\)[^/]' \| \
49713	 X"$ac_file" : 'X\(//\)$' \| \
49714	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
49715$as_echo X"$ac_file" |
49716    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49717	    s//\1/
49718	    q
49719	  }
49720	  /^X\(\/\/\)[^/].*/{
49721	    s//\1/
49722	    q
49723	  }
49724	  /^X\(\/\/\)$/{
49725	    s//\1/
49726	    q
49727	  }
49728	  /^X\(\/\).*/{
49729	    s//\1/
49730	    q
49731	  }
49732	  s/.*/./; q'`
49733  as_dir="$ac_dir"; as_fn_mkdir_p
49734  ac_builddir=.
49735
49736case "$ac_dir" in
49737.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
49738*)
49739  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
49740  # A ".." for each directory in $ac_dir_suffix.
49741  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
49742  case $ac_top_builddir_sub in
49743  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
49744  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
49745  esac ;;
49746esac
49747ac_abs_top_builddir=$ac_pwd
49748ac_abs_builddir=$ac_pwd$ac_dir_suffix
49749# for backward compatibility:
49750ac_top_builddir=$ac_top_build_prefix
49751
49752case $srcdir in
49753  .)  # We are building in place.
49754    ac_srcdir=.
49755    ac_top_srcdir=$ac_top_builddir_sub
49756    ac_abs_top_srcdir=$ac_pwd ;;
49757  [\\/]* | ?:[\\/]* )  # Absolute name.
49758    ac_srcdir=$srcdir$ac_dir_suffix;
49759    ac_top_srcdir=$srcdir
49760    ac_abs_top_srcdir=$srcdir ;;
49761  *) # Relative name.
49762    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
49763    ac_top_srcdir=$ac_top_build_prefix$srcdir
49764    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
49765esac
49766ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
49767
49768
49769  case $ac_mode in
49770  :F)
49771  #
49772  # CONFIG_FILE
49773  #
49774
49775_ACEOF
49776
49777cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49778# If the template does not know about datarootdir, expand it.
49779# FIXME: This hack should be removed a few years after 2.60.
49780ac_datarootdir_hack=; ac_datarootdir_seen=
49781ac_sed_dataroot='
49782/datarootdir/ {
49783  p
49784  q
49785}
49786/@datadir@/p
49787/@docdir@/p
49788/@infodir@/p
49789/@localedir@/p
49790/@mandir@/p'
49791case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
49792*datarootdir*) ac_datarootdir_seen=yes;;
49793*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
49794  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
49795$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
49796_ACEOF
49797cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49798  ac_datarootdir_hack='
49799  s&@datadir@&$datadir&g
49800  s&@docdir@&$docdir&g
49801  s&@infodir@&$infodir&g
49802  s&@localedir@&$localedir&g
49803  s&@mandir@&$mandir&g
49804  s&\\\${datarootdir}&$datarootdir&g' ;;
49805esac
49806_ACEOF
49807
49808# Neutralize VPATH when `$srcdir' = `.'.
49809# Shell code in configure.ac might set extrasub.
49810# FIXME: do we really want to maintain this feature?
49811cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49812ac_sed_extra="$ac_vpsub
49813$extrasub
49814_ACEOF
49815cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49816:t
49817/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
49818s|@configure_input@|$ac_sed_conf_input|;t t
49819s&@top_builddir@&$ac_top_builddir_sub&;t t
49820s&@top_build_prefix@&$ac_top_build_prefix&;t t
49821s&@srcdir@&$ac_srcdir&;t t
49822s&@abs_srcdir@&$ac_abs_srcdir&;t t
49823s&@top_srcdir@&$ac_top_srcdir&;t t
49824s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
49825s&@builddir@&$ac_builddir&;t t
49826s&@abs_builddir@&$ac_abs_builddir&;t t
49827s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
49828$ac_datarootdir_hack
49829"
49830eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
49831  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49832
49833test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
49834  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
49835  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
49836      "$ac_tmp/out"`; test -z "$ac_out"; } &&
49837  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49838which seems to be undefined.  Please make sure it is defined" >&5
49839$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49840which seems to be undefined.  Please make sure it is defined" >&2;}
49841
49842  rm -f "$ac_tmp/stdin"
49843  case $ac_file in
49844  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
49845  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
49846  esac \
49847  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49848 ;;
49849  :H)
49850  #
49851  # CONFIG_HEADER
49852  #
49853  if test x"$ac_file" != x-; then
49854    {
49855      $as_echo "/* $configure_input  */" \
49856      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
49857    } >"$ac_tmp/config.h" \
49858      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49859    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
49860      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
49861$as_echo "$as_me: $ac_file is unchanged" >&6;}
49862    else
49863      rm -f "$ac_file"
49864      mv "$ac_tmp/config.h" "$ac_file" \
49865	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
49866    fi
49867  else
49868    $as_echo "/* $configure_input  */" \
49869      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
49870      || as_fn_error $? "could not create -" "$LINENO" 5
49871  fi
49872 ;;
49873
49874
49875  esac
49876
49877done # for ac_tag
49878
49879
49880as_fn_exit 0
49881_ACEOF
49882ac_clean_files=$ac_clean_files_save
49883
49884test $ac_write_fail = 0 ||
49885  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
49886
49887
49888# configure is writing to config.log, and then calls config.status.
49889# config.status does its own redirection, appending to config.log.
49890# Unfortunately, on DOS this fails, as config.log is still kept open
49891# by configure, so config.status won't be able to write to it; its
49892# output is simply discarded.  So we exec the FD to /dev/null,
49893# effectively closing config.log, so it can be properly (re)opened and
49894# appended to by config.status.  When coming back to configure, we
49895# need to make the FD available again.
49896if test "$no_create" != yes; then
49897  ac_cs_success=:
49898  ac_config_status_args=
49899  test "$silent" = yes &&
49900    ac_config_status_args="$ac_config_status_args --quiet"
49901  exec 5>/dev/null
49902  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
49903  exec 5>>config.log
49904  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
49905  # would make configure fail if this is the last instruction.
49906  $ac_cs_success || as_fn_exit 1
49907fi
49908if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
49909  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
49910$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
49911fi
49912
49913
49914# Try to move the config.log file to the output directory.
49915if test -e ./config.log; then
49916  $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
49917fi
49918
49919# Make the compare script executable
49920$CHMOD +x $OUTPUT_ROOT/compare.sh
49921
49922# Finally output some useful information to the user
49923
49924  # Finally output some useful information to the user
49925
49926  printf "\n"
49927  printf "====================================================\n"
49928  if test "x$no_create" != "xyes"; then
49929    if test "x$IS_RECONFIGURE" != "xyes"; then
49930      printf "A new configuration has been successfully created in\n %s\n" "$OUTPUT_ROOT"
49931    else
49932      printf "The existing configuration has been successfully updated in\n %s\n" "$OUTPUT_ROOT"
49933    fi
49934  else
49935    if test "x$IS_RECONFIGURE" != "xyes"; then
49936      printf "A configuration has been successfully checked but not created\n"
49937    else
49938      printf "The existing configuration has been successfully checked in\n %s\n" "$OUTPUT_ROOT"
49939    fi
49940  fi
49941  if test "x$CONFIGURE_COMMAND_LINE" != x; then
49942    printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
49943  else
49944    printf "using default settings.\n"
49945  fi
49946
49947  printf "\n"
49948  printf "Configuration summary:\n"
49949  printf "* Debug level:    $DEBUG_LEVEL\n"
49950  printf "* JDK variant:    $JDK_VARIANT\n"
49951  printf "* JVM variants:   $with_jvm_variants\n"
49952  printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
49953
49954  printf "\n"
49955  printf "Tools summary:\n"
49956  if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
49957    printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
49958  fi
49959  printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
49960  printf "* Toolchain:      $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)\n"
49961  printf "* C Compiler:     Version $CC_VERSION_NUMBER (at $CC)\n"
49962  printf "* C++ Compiler:   Version $CXX_VERSION_NUMBER (at $CXX)\n"
49963
49964  printf "\n"
49965  printf "Build performance summary:\n"
49966  printf "* Cores to use:   $JOBS\n"
49967  printf "* Memory limit:   $MEMORY_SIZE MB\n"
49968  if test "x$CCACHE_STATUS" != "x"; then
49969    printf "* ccache status:  $CCACHE_STATUS\n"
49970  fi
49971  printf "\n"
49972
49973  if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
49974    printf "NOTE: You have requested to build more than one version of the JVM, which\n"
49975    printf "will result in longer build times.\n"
49976    printf "\n"
49977  fi
49978
49979  if test "x$FOUND_ALT_VARIABLES" != "x"; then
49980    printf "WARNING: You have old-style ALT_ environment variables set.\n"
49981    printf "These are not respected, and will be ignored. It is recommended\n"
49982    printf "that you clean your environment. The following variables are set:\n"
49983    printf "$FOUND_ALT_VARIABLES\n"
49984    printf "\n"
49985  fi
49986
49987  if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
49988    printf "WARNING: Your build output directory is not on a local disk.\n"
49989    printf "This will severely degrade build performance!\n"
49990    printf "It is recommended that you create an output directory on a local disk,\n"
49991    printf "and run the configure script again from that directory.\n"
49992    printf "\n"
49993  fi
49994
49995  if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
49996    printf "WARNING: The result of this configuration has overridden an older\n"
49997    printf "configuration. You *should* run 'make clean' to make sure you get a\n"
49998    printf "proper build. Failure to do so might result in strange build problems.\n"
49999    printf "\n"
50000  fi
50001
50002  if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
50003    printf "WARNING: The result of this configuration was not saved.\n"
50004    printf "You should run without '--no-create | -n' to create the configuration.\n"
50005    printf "\n"
50006  fi
50007
50008