generated-configure.sh revision 976:6e29cd9ac2b4
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 common/autoconf/build-aux "$srcdir"/common/autoconf/build-aux; do
3166  if test -f "$ac_dir/install-sh"; then
3167    ac_aux_dir=$ac_dir
3168    ac_install_sh="$ac_aux_dir/install-sh -c"
3169    break
3170  elif test -f "$ac_dir/install.sh"; then
3171    ac_aux_dir=$ac_dir
3172    ac_install_sh="$ac_aux_dir/install.sh -c"
3173    break
3174  elif test -f "$ac_dir/shtool"; then
3175    ac_aux_dir=$ac_dir
3176    ac_install_sh="$ac_aux_dir/shtool install -c"
3177    break
3178  fi
3179done
3180if test -z "$ac_aux_dir"; then
3181  as_fn_error $? "cannot find install-sh, install.sh, or shtool in common/autoconf/build-aux \"$srcdir\"/common/autoconf/build-aux" "$LINENO" 5
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=1393244882
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  # autoconf magic only relies on PATH, so update it if tools dir is specified
26397  OLD_PATH="$PATH"
26398
26399  # For solaris we really need solaris tools, and not the GNU equivalent.
26400  # The build tools on Solaris reside in /usr/ccs (C Compilation System),
26401  # so add that to path before starting to probe.
26402  # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
26403  if test "x$OPENJDK_BUILD_OS" = xsolaris; then
26404    PATH="/usr/ccs/bin:$PATH"
26405  fi
26406
26407  # On Windows, we need to detect the visual studio installation first.
26408  if test "x$OPENJDK_BUILD_OS" = "xwindows" && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then
26409
26410  # Store path to cygwin link.exe to help excluding it when searching for
26411  # VS linker. This must be done before changing the PATH when looking for VS.
26412  # Extract the first word of "link", so it can be a program name with args.
26413set dummy link; ac_word=$2
26414{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26415$as_echo_n "checking for $ac_word... " >&6; }
26416if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26417  $as_echo_n "(cached) " >&6
26418else
26419  case $CYGWIN_LINK in
26420  [\\/]* | ?:[\\/]*)
26421  ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26422  ;;
26423  *)
26424  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26425for as_dir in $PATH
26426do
26427  IFS=$as_save_IFS
26428  test -z "$as_dir" && as_dir=.
26429    for ac_exec_ext in '' $ac_executable_extensions; do
26430  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26431    ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26432    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26433    break 2
26434  fi
26435done
26436  done
26437IFS=$as_save_IFS
26438
26439  ;;
26440esac
26441fi
26442CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26443if test -n "$CYGWIN_LINK"; then
26444  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26445$as_echo "$CYGWIN_LINK" >&6; }
26446else
26447  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26448$as_echo "no" >&6; }
26449fi
26450
26451
26452  if test "x$CYGWIN_LINK" != x; then
26453    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26454$as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26455    "$CYGWIN_LINK" --version > /dev/null
26456    if test $? -eq 0 ; then
26457      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26458$as_echo "yes" >&6; }
26459    else
26460      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26461$as_echo "no" >&6; }
26462      # This might be the VS linker. Don't exclude it later on.
26463      CYGWIN_LINK=""
26464    fi
26465  fi
26466
26467  # First-hand choice is to locate and run the vsvars bat file.
26468
26469  if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26470    VCVARSFILE="vc/bin/vcvars32.bat"
26471  else
26472    VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26473  fi
26474
26475  VS_ENV_CMD=""
26476  VS_ENV_ARGS=""
26477  if test "x$with_toolsdir" != x; then
26478
26479  if test "x$VS_ENV_CMD" = x; then
26480    VS100BASE="$with_toolsdir/../.."
26481    METHOD="--with-tools-dir"
26482
26483  windows_path="$VS100BASE"
26484  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26485    unix_path=`$CYGPATH -u "$windows_path"`
26486    VS100BASE="$unix_path"
26487  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26488    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26489    VS100BASE="$unix_path"
26490  fi
26491
26492    if test -d "$VS100BASE"; then
26493      if test -f "$VS100BASE/$VCVARSFILE"; then
26494        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26495$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26496        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26497      else
26498        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26499$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26500        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26501$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26502      fi
26503    fi
26504  fi
26505
26506  fi
26507
26508  if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26509    # Having specified an argument which is incorrect will produce an instant failure;
26510    # we should not go on looking
26511    { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26512$as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26513    { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26514$as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26515    as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26516  fi
26517
26518  if test "x$VS100COMNTOOLS" != x; then
26519
26520  if test "x$VS_ENV_CMD" = x; then
26521    VS100BASE="$VS100COMNTOOLS/../.."
26522    METHOD="VS100COMNTOOLS variable"
26523
26524  windows_path="$VS100BASE"
26525  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26526    unix_path=`$CYGPATH -u "$windows_path"`
26527    VS100BASE="$unix_path"
26528  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26529    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26530    VS100BASE="$unix_path"
26531  fi
26532
26533    if test -d "$VS100BASE"; then
26534      if test -f "$VS100BASE/$VCVARSFILE"; then
26535        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26536$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26537        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26538      else
26539        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26540$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26541        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26542$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26543      fi
26544    fi
26545  fi
26546
26547  fi
26548  if test "x$PROGRAMFILES" != x; then
26549
26550  if test "x$VS_ENV_CMD" = x; then
26551    VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26552    METHOD="well-known name"
26553
26554  windows_path="$VS100BASE"
26555  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26556    unix_path=`$CYGPATH -u "$windows_path"`
26557    VS100BASE="$unix_path"
26558  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26559    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26560    VS100BASE="$unix_path"
26561  fi
26562
26563    if test -d "$VS100BASE"; then
26564      if test -f "$VS100BASE/$VCVARSFILE"; then
26565        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26566$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26567        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26568      else
26569        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26570$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26571        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26572$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26573      fi
26574    fi
26575  fi
26576
26577  fi
26578
26579  if test "x$VS_ENV_CMD" = x; then
26580    VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26581    METHOD="well-known name"
26582
26583  windows_path="$VS100BASE"
26584  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26585    unix_path=`$CYGPATH -u "$windows_path"`
26586    VS100BASE="$unix_path"
26587  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26588    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26589    VS100BASE="$unix_path"
26590  fi
26591
26592    if test -d "$VS100BASE"; then
26593      if test -f "$VS100BASE/$VCVARSFILE"; then
26594        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26595$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26596        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26597      else
26598        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26599$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26600        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26601$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26602      fi
26603    fi
26604  fi
26605
26606
26607  if test "x$VS_ENV_CMD" = x; then
26608    VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
26609    METHOD="well-known name"
26610
26611  windows_path="$VS100BASE"
26612  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26613    unix_path=`$CYGPATH -u "$windows_path"`
26614    VS100BASE="$unix_path"
26615  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26616    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26617    VS100BASE="$unix_path"
26618  fi
26619
26620    if test -d "$VS100BASE"; then
26621      if test -f "$VS100BASE/$VCVARSFILE"; then
26622        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26623$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26624        VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26625      else
26626        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26627$as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26628        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26629$as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26630      fi
26631    fi
26632  fi
26633
26634
26635  if test "x$ProgramW6432" != x; then
26636
26637  if test "x$VS_ENV_CMD" = x; then
26638    WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
26639    METHOD="well-known name"
26640
26641  windows_path="$WIN_SDK_BASE"
26642  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26643    unix_path=`$CYGPATH -u "$windows_path"`
26644    WIN_SDK_BASE="$unix_path"
26645  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26646    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26647    WIN_SDK_BASE="$unix_path"
26648  fi
26649
26650    if test -d "$WIN_SDK_BASE"; then
26651      # There have been cases of partial or broken SDK installations. A missing
26652      # lib dir is not going to work.
26653      if test ! -d "$WIN_SDK_BASE/../lib"; then
26654        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26655$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26656        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26657$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26658      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26659        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26660$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26661        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26662        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26663          VS_ENV_ARGS="/x86"
26664        else
26665          VS_ENV_ARGS="/x64"
26666        fi
26667      else
26668        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26669$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26670        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26671$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26672      fi
26673    fi
26674  fi
26675
26676  fi
26677  if test "x$PROGRAMW6432" != x; then
26678
26679  if test "x$VS_ENV_CMD" = x; then
26680    WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
26681    METHOD="well-known name"
26682
26683  windows_path="$WIN_SDK_BASE"
26684  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26685    unix_path=`$CYGPATH -u "$windows_path"`
26686    WIN_SDK_BASE="$unix_path"
26687  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26688    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26689    WIN_SDK_BASE="$unix_path"
26690  fi
26691
26692    if test -d "$WIN_SDK_BASE"; then
26693      # There have been cases of partial or broken SDK installations. A missing
26694      # lib dir is not going to work.
26695      if test ! -d "$WIN_SDK_BASE/../lib"; then
26696        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26697$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26698        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26699$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26700      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26701        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26702$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26703        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26704        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26705          VS_ENV_ARGS="/x86"
26706        else
26707          VS_ENV_ARGS="/x64"
26708        fi
26709      else
26710        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26711$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26712        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26713$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26714      fi
26715    fi
26716  fi
26717
26718  fi
26719  if test "x$PROGRAMFILES" != x; then
26720
26721  if test "x$VS_ENV_CMD" = x; then
26722    WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
26723    METHOD="well-known name"
26724
26725  windows_path="$WIN_SDK_BASE"
26726  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26727    unix_path=`$CYGPATH -u "$windows_path"`
26728    WIN_SDK_BASE="$unix_path"
26729  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26730    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26731    WIN_SDK_BASE="$unix_path"
26732  fi
26733
26734    if test -d "$WIN_SDK_BASE"; then
26735      # There have been cases of partial or broken SDK installations. A missing
26736      # lib dir is not going to work.
26737      if test ! -d "$WIN_SDK_BASE/../lib"; then
26738        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26739$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26740        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26741$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26742      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26743        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26744$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26745        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26746        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26747          VS_ENV_ARGS="/x86"
26748        else
26749          VS_ENV_ARGS="/x64"
26750        fi
26751      else
26752        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26753$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26754        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26755$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26756      fi
26757    fi
26758  fi
26759
26760  fi
26761
26762  if test "x$VS_ENV_CMD" = x; then
26763    WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
26764    METHOD="well-known name"
26765
26766  windows_path="$WIN_SDK_BASE"
26767  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26768    unix_path=`$CYGPATH -u "$windows_path"`
26769    WIN_SDK_BASE="$unix_path"
26770  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26771    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26772    WIN_SDK_BASE="$unix_path"
26773  fi
26774
26775    if test -d "$WIN_SDK_BASE"; then
26776      # There have been cases of partial or broken SDK installations. A missing
26777      # lib dir is not going to work.
26778      if test ! -d "$WIN_SDK_BASE/../lib"; then
26779        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26780$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26781        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26782$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26783      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26784        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26785$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26786        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26787        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26788          VS_ENV_ARGS="/x86"
26789        else
26790          VS_ENV_ARGS="/x64"
26791        fi
26792      else
26793        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26794$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26795        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26796$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26797      fi
26798    fi
26799  fi
26800
26801
26802  if test "x$VS_ENV_CMD" = x; then
26803    WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
26804    METHOD="well-known name"
26805
26806  windows_path="$WIN_SDK_BASE"
26807  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26808    unix_path=`$CYGPATH -u "$windows_path"`
26809    WIN_SDK_BASE="$unix_path"
26810  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26811    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26812    WIN_SDK_BASE="$unix_path"
26813  fi
26814
26815    if test -d "$WIN_SDK_BASE"; then
26816      # There have been cases of partial or broken SDK installations. A missing
26817      # lib dir is not going to work.
26818      if test ! -d "$WIN_SDK_BASE/../lib"; then
26819        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26820$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26821        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26822$as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26823      elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26824        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26825$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26826        VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26827        if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26828          VS_ENV_ARGS="/x86"
26829        else
26830          VS_ENV_ARGS="/x64"
26831        fi
26832      else
26833        { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26834$as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26835        { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26836$as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26837      fi
26838    fi
26839  fi
26840
26841
26842  if test "x$VS_ENV_CMD" != x; then
26843    # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
26844
26845  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26846
26847  # First separate the path from the arguments. This will split at the first
26848  # space.
26849  complete="$VS_ENV_CMD"
26850  path="${complete%% *}"
26851  tmp="$complete EOL"
26852  arguments="${tmp#* }"
26853
26854  # Input might be given as Windows format, start by converting to
26855  # unix format.
26856  new_path=`$CYGPATH -u "$path"`
26857
26858  # Now try to locate executable using which
26859  new_path=`$WHICH "$new_path" 2> /dev/null`
26860  # bat and cmd files are not always considered executable in cygwin causing which
26861  # to not find them
26862  if test "x$new_path" = x \
26863      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26864      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26865    new_path=`$CYGPATH -u "$path"`
26866  fi
26867  if test "x$new_path" = x; then
26868    # Oops. Which didn't find the executable.
26869    # The splitting of arguments from the executable at a space might have been incorrect,
26870    # since paths with space are more likely in Windows. Give it another try with the whole
26871    # argument.
26872    path="$complete"
26873    arguments="EOL"
26874    new_path=`$CYGPATH -u "$path"`
26875    new_path=`$WHICH "$new_path" 2> /dev/null`
26876    # bat and cmd files are not always considered executable in cygwin causing which
26877    # to not find them
26878    if test "x$new_path" = x \
26879        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26880        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26881      new_path=`$CYGPATH -u "$path"`
26882    fi
26883    if test "x$new_path" = x; then
26884      # It's still not found. Now this is an unrecoverable error.
26885      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
26886$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
26887      has_space=`$ECHO "$complete" | $GREP " "`
26888      if test "x$has_space" != x; then
26889        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
26890$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
26891      fi
26892      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26893    fi
26894  fi
26895
26896  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
26897  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
26898  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
26899  # "foo.exe" is OK but "foo" is an error.
26900  #
26901  # This test is therefore slightly more accurate than "test -f" to check for file presence.
26902  # It is also a way to make sure we got the proper file name for the real test later on.
26903  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
26904  if test "x$test_shortpath" = x; then
26905    # Short path failed, file does not exist as specified.
26906    # Try adding .exe or .cmd
26907    if test -f "${new_path}.exe"; then
26908      input_to_shortpath="${new_path}.exe"
26909    elif test -f "${new_path}.cmd"; then
26910      input_to_shortpath="${new_path}.cmd"
26911    else
26912      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
26913$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
26914      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
26915$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
26916      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
26917    fi
26918  else
26919    input_to_shortpath="$new_path"
26920  fi
26921
26922  # Call helper function which possibly converts this using DOS-style short mode.
26923  # If so, the updated path is stored in $new_path.
26924  new_path="$input_to_shortpath"
26925
26926  input_path="$input_to_shortpath"
26927  # Check if we need to convert this using DOS-style short mode. If the path
26928  # contains just simple characters, use it. Otherwise (spaces, weird characters),
26929  # take no chances and rewrite it.
26930  # Note: m4 eats our [], so we need to use [ and ] instead.
26931  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
26932  if test "x$has_forbidden_chars" != x; then
26933    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
26934    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
26935    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
26936    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
26937      # Going to short mode and back again did indeed matter. Since short mode is
26938      # case insensitive, let's make it lowercase to improve readability.
26939      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
26940      # Now convert it back to Unix-stile (cygpath)
26941      input_path=`$CYGPATH -u "$shortmode_path"`
26942      new_path="$input_path"
26943    fi
26944  fi
26945
26946  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
26947  if test "x$test_cygdrive_prefix" = x; then
26948    # As a simple fix, exclude /usr/bin since it's not a real path.
26949    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
26950      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
26951      # a path prefixed by /cygdrive for fixpath to work.
26952      new_path="$CYGWIN_ROOT_PATH$input_path"
26953    fi
26954  fi
26955
26956  # remove trailing .exe if any
26957  new_path="${new_path/%.exe/}"
26958
26959  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26960
26961  # First separate the path from the arguments. This will split at the first
26962  # space.
26963  complete="$VS_ENV_CMD"
26964  path="${complete%% *}"
26965  tmp="$complete EOL"
26966  arguments="${tmp#* }"
26967
26968  # Input might be given as Windows format, start by converting to
26969  # unix format.
26970  new_path="$path"
26971
26972  windows_path="$new_path"
26973  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26974    unix_path=`$CYGPATH -u "$windows_path"`
26975    new_path="$unix_path"
26976  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26977    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26978    new_path="$unix_path"
26979  fi
26980
26981
26982  # Now try to locate executable using which
26983  new_path=`$WHICH "$new_path" 2> /dev/null`
26984
26985  if test "x$new_path" = x; then
26986    # Oops. Which didn't find the executable.
26987    # The splitting of arguments from the executable at a space might have been incorrect,
26988    # since paths with space are more likely in Windows. Give it another try with the whole
26989    # argument.
26990    path="$complete"
26991    arguments="EOL"
26992    new_path="$path"
26993
26994  windows_path="$new_path"
26995  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26996    unix_path=`$CYGPATH -u "$windows_path"`
26997    new_path="$unix_path"
26998  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26999    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27000    new_path="$unix_path"
27001  fi
27002
27003
27004    new_path=`$WHICH "$new_path" 2> /dev/null`
27005
27006    if test "x$new_path" = x; then
27007      # It's still not found. Now this is an unrecoverable error.
27008      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27009$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27010      has_space=`$ECHO "$complete" | $GREP " "`
27011      if test "x$has_space" != x; then
27012        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27013$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27014      fi
27015      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27016    fi
27017  fi
27018
27019  # Now new_path has a complete unix path to the binary
27020  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27021    # Keep paths in /bin as-is, but remove trailing .exe if any
27022    new_path="${new_path/%.exe/}"
27023    # Do not save /bin paths to all_fixpath_prefixes!
27024  else
27025    # Not in mixed or Windows style, start by that.
27026    new_path=`cmd //c echo $new_path`
27027
27028  input_path="$new_path"
27029  # Check if we need to convert this using DOS-style short mode. If the path
27030  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27031  # take no chances and rewrite it.
27032  # Note: m4 eats our [], so we need to use [ and ] instead.
27033  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27034  if test "x$has_forbidden_chars" != x; then
27035    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27036    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27037  fi
27038
27039    # Output is in $new_path
27040
27041  windows_path="$new_path"
27042  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27043    unix_path=`$CYGPATH -u "$windows_path"`
27044    new_path="$unix_path"
27045  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27046    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27047    new_path="$unix_path"
27048  fi
27049
27050    # remove trailing .exe if any
27051    new_path="${new_path/%.exe/}"
27052
27053    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27054    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27055  fi
27056
27057  else
27058    # We're on a posix platform. Hooray! :)
27059    # First separate the path from the arguments. This will split at the first
27060    # space.
27061    complete="$VS_ENV_CMD"
27062    path="${complete%% *}"
27063    tmp="$complete EOL"
27064    arguments="${tmp#* }"
27065
27066    # Cannot rely on the command "which" here since it doesn't always work.
27067    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27068    if test -z "$is_absolute_path"; then
27069      # Path to executable is not absolute. Find it.
27070      IFS_save="$IFS"
27071      IFS=:
27072      for p in $PATH; do
27073        if test -f "$p/$path" && test -x "$p/$path"; then
27074          new_path="$p/$path"
27075          break
27076        fi
27077      done
27078      IFS="$IFS_save"
27079    else
27080      # This is an absolute path, we can use it without further modifications.
27081      new_path="$path"
27082    fi
27083
27084    if test "x$new_path" = x; then
27085      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27086$as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27087      has_space=`$ECHO "$complete" | $GREP " "`
27088      if test "x$has_space" != x; then
27089        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27090$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27091      fi
27092      as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27093    fi
27094  fi
27095
27096  # Now join together the path and the arguments once again
27097  if test "x$arguments" != xEOL; then
27098    new_complete="$new_path ${arguments% *}"
27099  else
27100    new_complete="$new_path"
27101  fi
27102
27103  if test "x$complete" != "x$new_complete"; then
27104    VS_ENV_CMD="$new_complete"
27105    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27106$as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27107  fi
27108
27109
27110    # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27111    { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27112$as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27113    cd $OUTPUT_ROOT
27114    # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted
27115    # to autoconf standards.
27116
27117    #----
27118
27119    # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment)
27120    # but calculate the difference in Cygwin environment before/after running it and then
27121    # apply the diff.
27122
27123    if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
27124      _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"`
27125      _dosvs10varsall=`cygpath -a -w -s $_vs10varsall`
27126      _dosbash=`cygpath -a -w -s \`which bash\`.*`
27127    else
27128      _dosvs10varsall=`cmd //c echo $VS_ENV_CMD`
27129      _dosbash=`cmd //c echo \`which bash\``
27130    fi
27131
27132    # generate the set of exported vars before/after the vs10 setup
27133    $ECHO "@echo off"                                           >  localdevenvtmp.bat
27134    $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat
27135    $ECHO "call $_dosvs10varsall $VS_ENV_ARGS"                  >> localdevenvtmp.bat
27136    $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat
27137
27138    # Now execute the newly created bat file.
27139    # The | cat is to stop SetEnv.Cmd to mess with system colors on msys
27140    cmd /c localdevenvtmp.bat | cat
27141
27142    # apply the diff (less some non-vs10 vars named by "!")
27143    $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort
27144    $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort
27145    $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh
27146
27147    # cleanup
27148    $RM localdevenvtmp*
27149    #----
27150    cd $CURDIR
27151    if test ! -s $OUTPUT_ROOT/localdevenv.sh; then
27152      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27153$as_echo "no" >&6; }
27154      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27155$as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27156      { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27157$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27158      { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27159$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27160      as_fn_error $? "Cannot continue" "$LINENO" 5
27161    fi
27162
27163    # Now set all paths and other env variables. This will allow the rest of
27164    # the configure script to find and run the compiler in the proper way.
27165    { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27166$as_echo "$as_me: Setting extracted environment variables" >&6;}
27167    . $OUTPUT_ROOT/localdevenv.sh
27168  else
27169    # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27170    { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27171$as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27172  fi
27173
27174  # At this point, we should have corrent variables in the environment, or we can't continue.
27175  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27176$as_echo_n "checking for Visual Studio variables... " >&6; }
27177
27178  if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27179    if test "x$INCLUDE" = x || test "x$LIB" = x; then
27180      { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27181$as_echo "present but broken" >&6; }
27182      as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27183    else
27184      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27185$as_echo "ok" >&6; }
27186      # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk.
27187      VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'`
27188      VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'`
27189      # Remove any paths containing # (typically F#) as that messes up make
27190      PATH=`$ECHO "$PATH" | $SED 's/[^:#]*#[^:]*://g'`
27191      VS_PATH="$PATH"
27192
27193
27194
27195    fi
27196  else
27197    { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27198$as_echo "not found" >&6; }
27199
27200    if test "x$VS_ENV_CMD" = x; then
27201      { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27202$as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27203      { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27204$as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27205    else
27206      { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27207$as_echo "$as_me: Running the extraction script failed." >&6;}
27208    fi
27209    { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27210$as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27211    { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27212$as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27213    as_fn_error $? "Cannot continue" "$LINENO" 5
27214  fi
27215
27216  fi
27217
27218  # Finally add TOOLS_DIR at the beginning, to allow --with-tools-dir to
27219  # override all other locations.
27220  if test "x$TOOLS_DIR" != x; then
27221    PATH=$TOOLS_DIR:$PATH
27222  fi
27223
27224  # If a devkit is found on the builddeps server, then prepend its path to the
27225  # PATH variable. If there are cross compilers available in the devkit, these
27226  # will be found by AC_PROG_CC et al.
27227  DEVKIT=
27228
27229
27230  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
27231    # Source the builddeps file again, to make sure it uses the latest variables!
27232    . $builddepsfile
27233    # Look for a target and build machine specific resource!
27234    eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
27235    if test "x$resource" = x; then
27236      # Ok, lets instead look for a target specific resource
27237      eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}}
27238    fi
27239    if test "x$resource" = x; then
27240      # Ok, lets instead look for a build specific resource
27241      eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}}
27242    fi
27243    if test "x$resource" = x; then
27244      # Ok, lets instead look for a generic resource
27245      # (The devkit comes from M4 and not the shell, thus no need for eval here.)
27246      resource=${builddep_devkit}
27247    fi
27248    if test "x$resource" != x; then
27249      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5
27250$as_echo "$as_me: Using builddeps $resource for devkit" >&6;}
27251      # If the resource in the builddeps.conf file is an existing directory,
27252      # for example /java/linux/cups
27253      if test -d ${resource}; then
27254        depdir=${resource}
27255      else
27256
27257  # devkit is for example mymodule
27258  # $resource is for example libs/general/libmymod_1_2_3.zip
27259  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
27260  # $with_builddeps_dir is for example /localhome/builddeps
27261  # depdir is the name of the variable into which we store the depdir, eg MYMOD
27262  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
27263  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
27264  filename=`basename $resource`
27265  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
27266  filebase=${filename%%.*}
27267  extension=${filename#*.}
27268  installdir=$with_builddeps_dir/$filebase
27269  if test ! -f $installdir/$filename.unpacked; then
27270    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5
27271$as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;}
27272    if test ! -d $installdir; then
27273      mkdir -p $installdir
27274    fi
27275    if test ! -d $installdir; then
27276      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
27277    fi
27278    tmpfile=`mktemp $installdir/devkit.XXXXXXXXX`
27279    touch $tmpfile
27280    if test ! -f $tmpfile; then
27281      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
27282    fi
27283
27284  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
27285  # $tmpfile is the local file name for the downloaded file.
27286  VALID_TOOL=no
27287  if test "x$BDEPS_FTP" = xwget; then
27288    VALID_TOOL=yes
27289    wget -O $tmpfile $with_builddeps_server/$resource
27290  fi
27291  if test "x$BDEPS_FTP" = xlftp; then
27292    VALID_TOOL=yes
27293    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
27294  fi
27295  if test "x$BDEPS_FTP" = xftp; then
27296    VALID_TOOL=yes
27297    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
27298    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
27299    FTPUSERPWD=${FTPSERVER%%@*}
27300    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
27301      FTPUSER=${userpwd%%:*}
27302      FTPPWD=${userpwd#*@}
27303      FTPSERVER=${FTPSERVER#*@}
27304    else
27305      FTPUSER=ftp
27306      FTPPWD=ftp
27307    fi
27308    # the "pass" command does not work on some
27309    # ftp clients (read ftp.exe) but if it works,
27310    # passive mode is better!
27311    ( \
27312        echo "user $FTPUSER $FTPPWD"        ; \
27313        echo "pass"                         ; \
27314        echo "bin"                          ; \
27315        echo "get $FTPPATH $tmpfile"              ; \
27316    ) | ftp -in $FTPSERVER
27317  fi
27318  if test "x$VALID_TOOL" != xyes; then
27319    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
27320  fi
27321
27322    mv $tmpfile $installdir/$filename
27323    if test ! -s $installdir/$filename; then
27324      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
27325    fi
27326    case "$extension" in
27327      zip)  echo "Unzipping $installdir/$filename..."
27328        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
27329        ;;
27330      tar.gz) echo "Untaring $installdir/$filename..."
27331        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27332        ;;
27333      tgz) echo "Untaring $installdir/$filename..."
27334        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27335        ;;
27336      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
27337        ;;
27338    esac
27339  fi
27340  if test -f $installdir/$filename.unpacked; then
27341    depdir=$installdir
27342  fi
27343
27344      fi
27345      # Source the builddeps file again, because in the previous command, the depdir
27346      # was updated to point at the current build dependency install directory.
27347      . $builddepsfile
27348      # Now extract variables from the builddeps.conf files.
27349      theroot=${builddep_devkit_ROOT}
27350      thecflags=${builddep_devkit_CFLAGS}
27351      thelibs=${builddep_devkit_LIBS}
27352      if test "x$depdir" = x; then
27353        as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5
27354      fi
27355      DEVKIT=$depdir
27356      if test "x$theroot" != x; then
27357        DEVKIT="$theroot"
27358      fi
27359      if test "x$thecflags" != x; then
27360        DEVKIT_CFLAGS="$thecflags"
27361      fi
27362      if test "x$thelibs" != x; then
27363        DEVKIT_LIBS="$thelibs"
27364      fi
27365
27366        # Found devkit
27367        PATH="$DEVKIT/bin:$PATH"
27368        SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root"
27369        if test "x$x_includes" = "xNONE"; then
27370          x_includes="$SYS_ROOT/usr/include/X11"
27371        fi
27372        if test "x$x_libraries" = "xNONE"; then
27373          x_libraries="$SYS_ROOT/usr/lib"
27374        fi
27375
27376
27377    fi
27378
27379  fi
27380
27381
27382
27383  #
27384  # Setup the compilers (CC and CXX)
27385  #
27386
27387  COMPILER_NAME=C
27388  SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27389
27390  if test "x$CC" != x; then
27391    # User has supplied compiler name already, always let that override.
27392    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27393$as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27394    if test "x`basename $CC`" = "x$CC"; then
27395      # A command without a complete path is provided, search $PATH.
27396
27397      for ac_prog in $CC
27398do
27399  # Extract the first word of "$ac_prog", so it can be a program name with args.
27400set dummy $ac_prog; ac_word=$2
27401{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27402$as_echo_n "checking for $ac_word... " >&6; }
27403if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27404  $as_echo_n "(cached) " >&6
27405else
27406  case $POTENTIAL_CC in
27407  [\\/]* | ?:[\\/]*)
27408  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27409  ;;
27410  *)
27411  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27412for as_dir in $PATH
27413do
27414  IFS=$as_save_IFS
27415  test -z "$as_dir" && as_dir=.
27416    for ac_exec_ext in '' $ac_executable_extensions; do
27417  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27418    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27419    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27420    break 2
27421  fi
27422done
27423  done
27424IFS=$as_save_IFS
27425
27426  ;;
27427esac
27428fi
27429POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27430if test -n "$POTENTIAL_CC"; then
27431  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27432$as_echo "$POTENTIAL_CC" >&6; }
27433else
27434  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27435$as_echo "no" >&6; }
27436fi
27437
27438
27439  test -n "$POTENTIAL_CC" && break
27440done
27441
27442      if test "x$POTENTIAL_CC" != x; then
27443        CC=$POTENTIAL_CC
27444      else
27445        as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27446      fi
27447    else
27448      # Otherwise it might already be a complete path
27449      if test ! -x "$CC"; then
27450        as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27451      fi
27452    fi
27453  else
27454    # No user supplied value. Locate compiler ourselves.
27455
27456    # If we are cross compiling, assume cross compilation tools follows the
27457    # cross compilation standard where they are prefixed with the autoconf
27458    # standard name for the target. For example the binary
27459    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27460    # If we are not cross compiling, then the default compiler name will be
27461    # used.
27462
27463    CC=
27464    # If TOOLS_DIR is set, check for all compiler names in there first
27465    # before checking the rest of the PATH.
27466    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27467    # step, this should not be necessary.
27468    if test -n "$TOOLS_DIR"; then
27469      PATH_save="$PATH"
27470      PATH="$TOOLS_DIR"
27471      for ac_prog in $SEARCH_LIST
27472do
27473  # Extract the first word of "$ac_prog", so it can be a program name with args.
27474set dummy $ac_prog; ac_word=$2
27475{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27476$as_echo_n "checking for $ac_word... " >&6; }
27477if ${ac_cv_path_TOOLS_DIR_CC+:} false; then :
27478  $as_echo_n "(cached) " >&6
27479else
27480  case $TOOLS_DIR_CC in
27481  [\\/]* | ?:[\\/]*)
27482  ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path.
27483  ;;
27484  *)
27485  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27486for as_dir in $PATH
27487do
27488  IFS=$as_save_IFS
27489  test -z "$as_dir" && as_dir=.
27490    for ac_exec_ext in '' $ac_executable_extensions; do
27491  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27492    ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext"
27493    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27494    break 2
27495  fi
27496done
27497  done
27498IFS=$as_save_IFS
27499
27500  ;;
27501esac
27502fi
27503TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC
27504if test -n "$TOOLS_DIR_CC"; then
27505  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5
27506$as_echo "$TOOLS_DIR_CC" >&6; }
27507else
27508  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27509$as_echo "no" >&6; }
27510fi
27511
27512
27513  test -n "$TOOLS_DIR_CC" && break
27514done
27515
27516      CC=$TOOLS_DIR_CC
27517      PATH="$PATH_save"
27518    fi
27519
27520    # AC_PATH_PROGS can't be run multiple times with the same variable,
27521    # so create a new name for this run.
27522    if test "x$CC" = x; then
27523      for ac_prog in $SEARCH_LIST
27524do
27525  # Extract the first word of "$ac_prog", so it can be a program name with args.
27526set dummy $ac_prog; ac_word=$2
27527{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27528$as_echo_n "checking for $ac_word... " >&6; }
27529if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27530  $as_echo_n "(cached) " >&6
27531else
27532  case $POTENTIAL_CC in
27533  [\\/]* | ?:[\\/]*)
27534  ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27535  ;;
27536  *)
27537  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27538for as_dir in $PATH
27539do
27540  IFS=$as_save_IFS
27541  test -z "$as_dir" && as_dir=.
27542    for ac_exec_ext in '' $ac_executable_extensions; do
27543  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27544    ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27545    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27546    break 2
27547  fi
27548done
27549  done
27550IFS=$as_save_IFS
27551
27552  ;;
27553esac
27554fi
27555POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27556if test -n "$POTENTIAL_CC"; then
27557  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27558$as_echo "$POTENTIAL_CC" >&6; }
27559else
27560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27561$as_echo "no" >&6; }
27562fi
27563
27564
27565  test -n "$POTENTIAL_CC" && break
27566done
27567
27568      CC=$POTENTIAL_CC
27569    fi
27570
27571    if test "x$CC" = x; then
27572
27573  # Print a helpful message on how to acquire the necessary build dependency.
27574  # devkit is the help tag: freetype, cups, pulse, alsa etc
27575  MISSING_DEPENDENCY=devkit
27576
27577  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27578    cygwin_help $MISSING_DEPENDENCY
27579  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27580    msys_help $MISSING_DEPENDENCY
27581  else
27582    PKGHANDLER_COMMAND=
27583
27584    case $PKGHANDLER in
27585      apt-get)
27586        apt_help     $MISSING_DEPENDENCY ;;
27587      yum)
27588        yum_help     $MISSING_DEPENDENCY ;;
27589      port)
27590        port_help    $MISSING_DEPENDENCY ;;
27591      pkgutil)
27592        pkgutil_help $MISSING_DEPENDENCY ;;
27593      pkgadd)
27594        pkgadd_help  $MISSING_DEPENDENCY ;;
27595    esac
27596
27597    if test "x$PKGHANDLER_COMMAND" != x; then
27598      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
27599    fi
27600  fi
27601
27602      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
27603    fi
27604  fi
27605
27606  # Now we have a compiler binary in CC. Make sure it's okay.
27607
27608  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27609
27610  # First separate the path from the arguments. This will split at the first
27611  # space.
27612  complete="$CC"
27613  path="${complete%% *}"
27614  tmp="$complete EOL"
27615  arguments="${tmp#* }"
27616
27617  # Input might be given as Windows format, start by converting to
27618  # unix format.
27619  new_path=`$CYGPATH -u "$path"`
27620
27621  # Now try to locate executable using which
27622  new_path=`$WHICH "$new_path" 2> /dev/null`
27623  # bat and cmd files are not always considered executable in cygwin causing which
27624  # to not find them
27625  if test "x$new_path" = x \
27626      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27627      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27628    new_path=`$CYGPATH -u "$path"`
27629  fi
27630  if test "x$new_path" = x; then
27631    # Oops. Which didn't find the executable.
27632    # The splitting of arguments from the executable at a space might have been incorrect,
27633    # since paths with space are more likely in Windows. Give it another try with the whole
27634    # argument.
27635    path="$complete"
27636    arguments="EOL"
27637    new_path=`$CYGPATH -u "$path"`
27638    new_path=`$WHICH "$new_path" 2> /dev/null`
27639    # bat and cmd files are not always considered executable in cygwin causing which
27640    # to not find them
27641    if test "x$new_path" = x \
27642        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27643        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27644      new_path=`$CYGPATH -u "$path"`
27645    fi
27646    if test "x$new_path" = x; then
27647      # It's still not found. Now this is an unrecoverable error.
27648      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27649$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27650      has_space=`$ECHO "$complete" | $GREP " "`
27651      if test "x$has_space" != x; then
27652        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27653$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27654      fi
27655      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27656    fi
27657  fi
27658
27659  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27660  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27661  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27662  # "foo.exe" is OK but "foo" is an error.
27663  #
27664  # This test is therefore slightly more accurate than "test -f" to check for file presence.
27665  # It is also a way to make sure we got the proper file name for the real test later on.
27666  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27667  if test "x$test_shortpath" = x; then
27668    # Short path failed, file does not exist as specified.
27669    # Try adding .exe or .cmd
27670    if test -f "${new_path}.exe"; then
27671      input_to_shortpath="${new_path}.exe"
27672    elif test -f "${new_path}.cmd"; then
27673      input_to_shortpath="${new_path}.cmd"
27674    else
27675      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
27676$as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
27677      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27678$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27679      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27680    fi
27681  else
27682    input_to_shortpath="$new_path"
27683  fi
27684
27685  # Call helper function which possibly converts this using DOS-style short mode.
27686  # If so, the updated path is stored in $new_path.
27687  new_path="$input_to_shortpath"
27688
27689  input_path="$input_to_shortpath"
27690  # Check if we need to convert this using DOS-style short mode. If the path
27691  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27692  # take no chances and rewrite it.
27693  # Note: m4 eats our [], so we need to use [ and ] instead.
27694  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27695  if test "x$has_forbidden_chars" != x; then
27696    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27697    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27698    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27699    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27700      # Going to short mode and back again did indeed matter. Since short mode is
27701      # case insensitive, let's make it lowercase to improve readability.
27702      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27703      # Now convert it back to Unix-stile (cygpath)
27704      input_path=`$CYGPATH -u "$shortmode_path"`
27705      new_path="$input_path"
27706    fi
27707  fi
27708
27709  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27710  if test "x$test_cygdrive_prefix" = x; then
27711    # As a simple fix, exclude /usr/bin since it's not a real path.
27712    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27713      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27714      # a path prefixed by /cygdrive for fixpath to work.
27715      new_path="$CYGWIN_ROOT_PATH$input_path"
27716    fi
27717  fi
27718
27719  # remove trailing .exe if any
27720  new_path="${new_path/%.exe/}"
27721
27722  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27723
27724  # First separate the path from the arguments. This will split at the first
27725  # space.
27726  complete="$CC"
27727  path="${complete%% *}"
27728  tmp="$complete EOL"
27729  arguments="${tmp#* }"
27730
27731  # Input might be given as Windows format, start by converting to
27732  # unix format.
27733  new_path="$path"
27734
27735  windows_path="$new_path"
27736  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27737    unix_path=`$CYGPATH -u "$windows_path"`
27738    new_path="$unix_path"
27739  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27740    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27741    new_path="$unix_path"
27742  fi
27743
27744
27745  # Now try to locate executable using which
27746  new_path=`$WHICH "$new_path" 2> /dev/null`
27747
27748  if test "x$new_path" = x; then
27749    # Oops. Which didn't find the executable.
27750    # The splitting of arguments from the executable at a space might have been incorrect,
27751    # since paths with space are more likely in Windows. Give it another try with the whole
27752    # argument.
27753    path="$complete"
27754    arguments="EOL"
27755    new_path="$path"
27756
27757  windows_path="$new_path"
27758  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27759    unix_path=`$CYGPATH -u "$windows_path"`
27760    new_path="$unix_path"
27761  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27762    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27763    new_path="$unix_path"
27764  fi
27765
27766
27767    new_path=`$WHICH "$new_path" 2> /dev/null`
27768
27769    if test "x$new_path" = x; then
27770      # It's still not found. Now this is an unrecoverable error.
27771      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27772$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27773      has_space=`$ECHO "$complete" | $GREP " "`
27774      if test "x$has_space" != x; then
27775        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27776$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27777      fi
27778      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27779    fi
27780  fi
27781
27782  # Now new_path has a complete unix path to the binary
27783  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27784    # Keep paths in /bin as-is, but remove trailing .exe if any
27785    new_path="${new_path/%.exe/}"
27786    # Do not save /bin paths to all_fixpath_prefixes!
27787  else
27788    # Not in mixed or Windows style, start by that.
27789    new_path=`cmd //c echo $new_path`
27790
27791  input_path="$new_path"
27792  # Check if we need to convert this using DOS-style short mode. If the path
27793  # contains just simple characters, use it. Otherwise (spaces, weird characters),
27794  # take no chances and rewrite it.
27795  # Note: m4 eats our [], so we need to use [ and ] instead.
27796  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27797  if test "x$has_forbidden_chars" != x; then
27798    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27799    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27800  fi
27801
27802    # Output is in $new_path
27803
27804  windows_path="$new_path"
27805  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27806    unix_path=`$CYGPATH -u "$windows_path"`
27807    new_path="$unix_path"
27808  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27809    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27810    new_path="$unix_path"
27811  fi
27812
27813    # remove trailing .exe if any
27814    new_path="${new_path/%.exe/}"
27815
27816    # Save the first 10 bytes of this path to the storage, so fixpath can work.
27817    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27818  fi
27819
27820  else
27821    # We're on a posix platform. Hooray! :)
27822    # First separate the path from the arguments. This will split at the first
27823    # space.
27824    complete="$CC"
27825    path="${complete%% *}"
27826    tmp="$complete EOL"
27827    arguments="${tmp#* }"
27828
27829    # Cannot rely on the command "which" here since it doesn't always work.
27830    is_absolute_path=`$ECHO "$path" | $GREP ^/`
27831    if test -z "$is_absolute_path"; then
27832      # Path to executable is not absolute. Find it.
27833      IFS_save="$IFS"
27834      IFS=:
27835      for p in $PATH; do
27836        if test -f "$p/$path" && test -x "$p/$path"; then
27837          new_path="$p/$path"
27838          break
27839        fi
27840      done
27841      IFS="$IFS_save"
27842    else
27843      # This is an absolute path, we can use it without further modifications.
27844      new_path="$path"
27845    fi
27846
27847    if test "x$new_path" = x; then
27848      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27849$as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27850      has_space=`$ECHO "$complete" | $GREP " "`
27851      if test "x$has_space" != x; then
27852        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27853$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27854      fi
27855      as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27856    fi
27857  fi
27858
27859  # Now join together the path and the arguments once again
27860  if test "x$arguments" != xEOL; then
27861    new_complete="$new_path ${arguments% *}"
27862  else
27863    new_complete="$new_path"
27864  fi
27865
27866  if test "x$complete" != "x$new_complete"; then
27867    CC="$new_complete"
27868    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
27869$as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
27870  fi
27871
27872  TEST_COMPILER="$CC"
27873  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
27874  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
27875  if test "x$OPENJDK_BUILD_OS" != xaix; then
27876    # FIXME: This test should not be needed anymore; we don't do that for any platform.
27877    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
27878$as_echo_n "checking resolved symbolic links for CC... " >&6; }
27879
27880  if test "x$OPENJDK_BUILD_OS" != xwindows; then
27881    # Follow a chain of symbolic links. Use readlink
27882    # where it exists, else fall back to horribly
27883    # complicated shell code.
27884    if test "x$READLINK_TESTED" != yes; then
27885      # On MacOSX there is a readlink tool with a different
27886      # purpose than the GNU readlink tool. Check the found readlink.
27887      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
27888      if test "x$ISGNU" = x; then
27889        # A readlink that we do not know how to use.
27890        # Are there other non-GNU readlinks out there?
27891        READLINK_TESTED=yes
27892        READLINK=
27893      fi
27894    fi
27895
27896    if test "x$READLINK" != x; then
27897      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
27898    else
27899      # Save the current directory for restoring afterwards
27900      STARTDIR=$PWD
27901      COUNTER=0
27902      sym_link_dir=`$DIRNAME $TEST_COMPILER`
27903      sym_link_file=`$BASENAME $TEST_COMPILER`
27904      cd $sym_link_dir
27905      # Use -P flag to resolve symlinks in directories.
27906      cd `$THEPWDCMD -P`
27907      sym_link_dir=`$THEPWDCMD -P`
27908      # Resolve file symlinks
27909      while test $COUNTER -lt 20; do
27910        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
27911        if test "x$ISLINK" == x; then
27912          # This is not a symbolic link! We are done!
27913          break
27914        fi
27915        # Again resolve directory symlinks since the target of the just found
27916        # link could be in a different directory
27917        cd `$DIRNAME $ISLINK`
27918        sym_link_dir=`$THEPWDCMD -P`
27919        sym_link_file=`$BASENAME $ISLINK`
27920        let COUNTER=COUNTER+1
27921      done
27922      cd $STARTDIR
27923      TEST_COMPILER=$sym_link_dir/$sym_link_file
27924    fi
27925  fi
27926
27927    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
27928$as_echo "$TEST_COMPILER" >&6; }
27929  fi
27930  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
27931$as_echo_n "checking if CC is disguised ccache... " >&6; }
27932
27933  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
27934  if test "x$COMPILER_BASENAME" = "xccache"; then
27935    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
27936$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
27937    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
27938    # We want to control ccache invocation ourselves, so ignore this cc and try
27939    # searching again.
27940
27941    # Remove the path to the fake ccache cc from the PATH
27942    RETRY_COMPILER_SAVED_PATH="$PATH"
27943    COMPILER_DIRNAME=`$DIRNAME $CC`
27944    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
27945
27946    # Try again looking for our compiler
27947    if test -n "$ac_tool_prefix"; then
27948  for ac_prog in $TOOLCHAIN_CC_BINARY
27949  do
27950    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
27951set dummy $ac_tool_prefix$ac_prog; ac_word=$2
27952{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27953$as_echo_n "checking for $ac_word... " >&6; }
27954if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
27955  $as_echo_n "(cached) " >&6
27956else
27957  if test -n "$PROPER_COMPILER_CC"; then
27958  ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
27959else
27960as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27961for as_dir in $PATH
27962do
27963  IFS=$as_save_IFS
27964  test -z "$as_dir" && as_dir=.
27965    for ac_exec_ext in '' $ac_executable_extensions; do
27966  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27967    ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
27968    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27969    break 2
27970  fi
27971done
27972  done
27973IFS=$as_save_IFS
27974
27975fi
27976fi
27977PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
27978if test -n "$PROPER_COMPILER_CC"; then
27979  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
27980$as_echo "$PROPER_COMPILER_CC" >&6; }
27981else
27982  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27983$as_echo "no" >&6; }
27984fi
27985
27986
27987    test -n "$PROPER_COMPILER_CC" && break
27988  done
27989fi
27990if test -z "$PROPER_COMPILER_CC"; then
27991  ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
27992  for ac_prog in $TOOLCHAIN_CC_BINARY
27993do
27994  # Extract the first word of "$ac_prog", so it can be a program name with args.
27995set dummy $ac_prog; ac_word=$2
27996{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27997$as_echo_n "checking for $ac_word... " >&6; }
27998if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
27999  $as_echo_n "(cached) " >&6
28000else
28001  if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28002  ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
28003else
28004as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28005for as_dir in $PATH
28006do
28007  IFS=$as_save_IFS
28008  test -z "$as_dir" && as_dir=.
28009    for ac_exec_ext in '' $ac_executable_extensions; do
28010  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28011    ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
28012    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28013    break 2
28014  fi
28015done
28016  done
28017IFS=$as_save_IFS
28018
28019fi
28020fi
28021ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
28022if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28023  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
28024$as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
28025else
28026  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28027$as_echo "no" >&6; }
28028fi
28029
28030
28031  test -n "$ac_ct_PROPER_COMPILER_CC" && break
28032done
28033
28034  if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
28035    PROPER_COMPILER_CC=""
28036  else
28037    case $cross_compiling:$ac_tool_warned in
28038yes:)
28039{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28040$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28041ac_tool_warned=yes ;;
28042esac
28043    PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
28044  fi
28045fi
28046
28047
28048  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28049
28050  # First separate the path from the arguments. This will split at the first
28051  # space.
28052  complete="$PROPER_COMPILER_CC"
28053  path="${complete%% *}"
28054  tmp="$complete EOL"
28055  arguments="${tmp#* }"
28056
28057  # Input might be given as Windows format, start by converting to
28058  # unix format.
28059  new_path=`$CYGPATH -u "$path"`
28060
28061  # Now try to locate executable using which
28062  new_path=`$WHICH "$new_path" 2> /dev/null`
28063  # bat and cmd files are not always considered executable in cygwin causing which
28064  # to not find them
28065  if test "x$new_path" = x \
28066      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28067      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28068    new_path=`$CYGPATH -u "$path"`
28069  fi
28070  if test "x$new_path" = x; then
28071    # Oops. Which didn't find the executable.
28072    # The splitting of arguments from the executable at a space might have been incorrect,
28073    # since paths with space are more likely in Windows. Give it another try with the whole
28074    # argument.
28075    path="$complete"
28076    arguments="EOL"
28077    new_path=`$CYGPATH -u "$path"`
28078    new_path=`$WHICH "$new_path" 2> /dev/null`
28079    # bat and cmd files are not always considered executable in cygwin causing which
28080    # to not find them
28081    if test "x$new_path" = x \
28082        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28083        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28084      new_path=`$CYGPATH -u "$path"`
28085    fi
28086    if test "x$new_path" = x; then
28087      # It's still not found. Now this is an unrecoverable error.
28088      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28089$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28090      has_space=`$ECHO "$complete" | $GREP " "`
28091      if test "x$has_space" != x; then
28092        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28093$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28094      fi
28095      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28096    fi
28097  fi
28098
28099  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28100  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28101  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28102  # "foo.exe" is OK but "foo" is an error.
28103  #
28104  # This test is therefore slightly more accurate than "test -f" to check for file presence.
28105  # It is also a way to make sure we got the proper file name for the real test later on.
28106  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28107  if test "x$test_shortpath" = x; then
28108    # Short path failed, file does not exist as specified.
28109    # Try adding .exe or .cmd
28110    if test -f "${new_path}.exe"; then
28111      input_to_shortpath="${new_path}.exe"
28112    elif test -f "${new_path}.cmd"; then
28113      input_to_shortpath="${new_path}.cmd"
28114    else
28115      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
28116$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
28117      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28118$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28119      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28120    fi
28121  else
28122    input_to_shortpath="$new_path"
28123  fi
28124
28125  # Call helper function which possibly converts this using DOS-style short mode.
28126  # If so, the updated path is stored in $new_path.
28127  new_path="$input_to_shortpath"
28128
28129  input_path="$input_to_shortpath"
28130  # Check if we need to convert this using DOS-style short mode. If the path
28131  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28132  # take no chances and rewrite it.
28133  # Note: m4 eats our [], so we need to use [ and ] instead.
28134  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28135  if test "x$has_forbidden_chars" != x; then
28136    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28137    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28138    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28139    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28140      # Going to short mode and back again did indeed matter. Since short mode is
28141      # case insensitive, let's make it lowercase to improve readability.
28142      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28143      # Now convert it back to Unix-stile (cygpath)
28144      input_path=`$CYGPATH -u "$shortmode_path"`
28145      new_path="$input_path"
28146    fi
28147  fi
28148
28149  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28150  if test "x$test_cygdrive_prefix" = x; then
28151    # As a simple fix, exclude /usr/bin since it's not a real path.
28152    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28153      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28154      # a path prefixed by /cygdrive for fixpath to work.
28155      new_path="$CYGWIN_ROOT_PATH$input_path"
28156    fi
28157  fi
28158
28159  # remove trailing .exe if any
28160  new_path="${new_path/%.exe/}"
28161
28162  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28163
28164  # First separate the path from the arguments. This will split at the first
28165  # space.
28166  complete="$PROPER_COMPILER_CC"
28167  path="${complete%% *}"
28168  tmp="$complete EOL"
28169  arguments="${tmp#* }"
28170
28171  # Input might be given as Windows format, start by converting to
28172  # unix format.
28173  new_path="$path"
28174
28175  windows_path="$new_path"
28176  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28177    unix_path=`$CYGPATH -u "$windows_path"`
28178    new_path="$unix_path"
28179  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28180    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28181    new_path="$unix_path"
28182  fi
28183
28184
28185  # Now try to locate executable using which
28186  new_path=`$WHICH "$new_path" 2> /dev/null`
28187
28188  if test "x$new_path" = x; then
28189    # Oops. Which didn't find the executable.
28190    # The splitting of arguments from the executable at a space might have been incorrect,
28191    # since paths with space are more likely in Windows. Give it another try with the whole
28192    # argument.
28193    path="$complete"
28194    arguments="EOL"
28195    new_path="$path"
28196
28197  windows_path="$new_path"
28198  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28199    unix_path=`$CYGPATH -u "$windows_path"`
28200    new_path="$unix_path"
28201  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28202    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28203    new_path="$unix_path"
28204  fi
28205
28206
28207    new_path=`$WHICH "$new_path" 2> /dev/null`
28208
28209    if test "x$new_path" = x; then
28210      # It's still not found. Now this is an unrecoverable error.
28211      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28212$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28213      has_space=`$ECHO "$complete" | $GREP " "`
28214      if test "x$has_space" != x; then
28215        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28216$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28217      fi
28218      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28219    fi
28220  fi
28221
28222  # Now new_path has a complete unix path to the binary
28223  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28224    # Keep paths in /bin as-is, but remove trailing .exe if any
28225    new_path="${new_path/%.exe/}"
28226    # Do not save /bin paths to all_fixpath_prefixes!
28227  else
28228    # Not in mixed or Windows style, start by that.
28229    new_path=`cmd //c echo $new_path`
28230
28231  input_path="$new_path"
28232  # Check if we need to convert this using DOS-style short mode. If the path
28233  # contains just simple characters, use it. Otherwise (spaces, weird characters),
28234  # take no chances and rewrite it.
28235  # Note: m4 eats our [], so we need to use [ and ] instead.
28236  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28237  if test "x$has_forbidden_chars" != x; then
28238    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28239    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28240  fi
28241
28242    # Output is in $new_path
28243
28244  windows_path="$new_path"
28245  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28246    unix_path=`$CYGPATH -u "$windows_path"`
28247    new_path="$unix_path"
28248  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28249    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28250    new_path="$unix_path"
28251  fi
28252
28253    # remove trailing .exe if any
28254    new_path="${new_path/%.exe/}"
28255
28256    # Save the first 10 bytes of this path to the storage, so fixpath can work.
28257    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28258  fi
28259
28260  else
28261    # We're on a posix platform. Hooray! :)
28262    # First separate the path from the arguments. This will split at the first
28263    # space.
28264    complete="$PROPER_COMPILER_CC"
28265    path="${complete%% *}"
28266    tmp="$complete EOL"
28267    arguments="${tmp#* }"
28268
28269    # Cannot rely on the command "which" here since it doesn't always work.
28270    is_absolute_path=`$ECHO "$path" | $GREP ^/`
28271    if test -z "$is_absolute_path"; then
28272      # Path to executable is not absolute. Find it.
28273      IFS_save="$IFS"
28274      IFS=:
28275      for p in $PATH; do
28276        if test -f "$p/$path" && test -x "$p/$path"; then
28277          new_path="$p/$path"
28278          break
28279        fi
28280      done
28281      IFS="$IFS_save"
28282    else
28283      # This is an absolute path, we can use it without further modifications.
28284      new_path="$path"
28285    fi
28286
28287    if test "x$new_path" = x; then
28288      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28289$as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28290      has_space=`$ECHO "$complete" | $GREP " "`
28291      if test "x$has_space" != x; then
28292        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28293$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28294      fi
28295      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28296    fi
28297  fi
28298
28299  # Now join together the path and the arguments once again
28300  if test "x$arguments" != xEOL; then
28301    new_complete="$new_path ${arguments% *}"
28302  else
28303    new_complete="$new_path"
28304  fi
28305
28306  if test "x$complete" != "x$new_complete"; then
28307    PROPER_COMPILER_CC="$new_complete"
28308    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
28309$as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
28310  fi
28311
28312    PATH="$RETRY_COMPILER_SAVED_PATH"
28313
28314    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
28315$as_echo_n "checking for resolved symbolic links for CC... " >&6; }
28316
28317  if test "x$OPENJDK_BUILD_OS" != xwindows; then
28318    # Follow a chain of symbolic links. Use readlink
28319    # where it exists, else fall back to horribly
28320    # complicated shell code.
28321    if test "x$READLINK_TESTED" != yes; then
28322      # On MacOSX there is a readlink tool with a different
28323      # purpose than the GNU readlink tool. Check the found readlink.
28324      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28325      if test "x$ISGNU" = x; then
28326        # A readlink that we do not know how to use.
28327        # Are there other non-GNU readlinks out there?
28328        READLINK_TESTED=yes
28329        READLINK=
28330      fi
28331    fi
28332
28333    if test "x$READLINK" != x; then
28334      PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
28335    else
28336      # Save the current directory for restoring afterwards
28337      STARTDIR=$PWD
28338      COUNTER=0
28339      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
28340      sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
28341      cd $sym_link_dir
28342      # Use -P flag to resolve symlinks in directories.
28343      cd `$THEPWDCMD -P`
28344      sym_link_dir=`$THEPWDCMD -P`
28345      # Resolve file symlinks
28346      while test $COUNTER -lt 20; do
28347        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28348        if test "x$ISLINK" == x; then
28349          # This is not a symbolic link! We are done!
28350          break
28351        fi
28352        # Again resolve directory symlinks since the target of the just found
28353        # link could be in a different directory
28354        cd `$DIRNAME $ISLINK`
28355        sym_link_dir=`$THEPWDCMD -P`
28356        sym_link_file=`$BASENAME $ISLINK`
28357        let COUNTER=COUNTER+1
28358      done
28359      cd $STARTDIR
28360      PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
28361    fi
28362  fi
28363
28364    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28365$as_echo "$PROPER_COMPILER_CC" >&6; }
28366    CC="$PROPER_COMPILER_CC"
28367  else
28368    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
28369$as_echo "no, keeping CC" >&6; }
28370  fi
28371
28372
28373  COMPILER=$CC
28374  COMPILER_NAME=$COMPILER_NAME
28375
28376  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
28377    # cc -V output typically looks like
28378    #     cc: Sun C 5.12 Linux_i386 2011/11/16
28379    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
28380    # Check that this is likely to be the Solaris Studio cc.
28381    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
28382    if test $? -ne 0; then
28383      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28384      { $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
28385$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28386      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28387$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28388      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28389$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28390      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28391    fi
28392    # Remove usage instructions (if present), and
28393    # collapse compiler output into a single line
28394    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28395        $SED -e 's/ *[Uu]sage:.*//'`
28396    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28397        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
28398  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
28399    # xlc -qversion output typically looks like
28400    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
28401    #     Version: 11.01.0000.0015
28402    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
28403    # Check that this is likely to be the IBM XL C compiler.
28404    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
28405    if test $? -ne 0; then
28406      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28407      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28408$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28409      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28410$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28411      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28412$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28413      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28414    fi
28415    # Collapse compiler output into a single line
28416    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28417    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28418        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
28419  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
28420    # There is no specific version flag, but all output starts with a version string.
28421    # First line typically looks something like:
28422    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
28423    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
28424    # Check that this is likely to be Microsoft CL.EXE.
28425    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
28426    if test $? -ne 0; then
28427      { $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
28428$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28429      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28430$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28431      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28432    fi
28433    # Collapse compiler output into a single line
28434    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28435    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28436        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
28437  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
28438    # gcc --version output typically looks like
28439    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
28440    #     Copyright (C) 2013 Free Software Foundation, Inc.
28441    #     This is free software; see the source for copying conditions.  There is NO
28442    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28443    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28444    # Check that this is likely to be GCC.
28445    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
28446    if test $? -ne 0; then
28447      { $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
28448$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28449      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
28450$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
28451      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28452    fi
28453    # Remove Copyright and legalese from version string, and
28454    # collapse into a single line
28455    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28456        $SED -e 's/ *Copyright .*//'`
28457    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28458        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
28459  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
28460    # clang --version output typically looks like
28461    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
28462    #    clang version 3.3 (tags/RELEASE_33/final)
28463    # or
28464    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
28465    #    Target: x86_64-pc-linux-gnu
28466    #    Thread model: posix
28467    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28468    # Check that this is likely to be clang
28469    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
28470    if test $? -ne 0; then
28471      { $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
28472$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28473      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28474$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28475      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28476    fi
28477    # Collapse compiler output into a single line
28478    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28479    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28480        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
28481  else
28482      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
28483  fi
28484  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
28485  CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
28486  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
28487  CC_VERSION_STRING="$COMPILER_VERSION_STRING"
28488
28489  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
28490$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
28491
28492
28493  # Now that we have resolved CC ourself, let autoconf have its go at it
28494  ac_ext=c
28495ac_cpp='$CPP $CPPFLAGS'
28496ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28497ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28498ac_compiler_gnu=$ac_cv_c_compiler_gnu
28499if test -n "$ac_tool_prefix"; then
28500  for ac_prog in $CC
28501  do
28502    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28503set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28504{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28505$as_echo_n "checking for $ac_word... " >&6; }
28506if ${ac_cv_prog_CC+:} false; then :
28507  $as_echo_n "(cached) " >&6
28508else
28509  if test -n "$CC"; then
28510  ac_cv_prog_CC="$CC" # Let the user override the test.
28511else
28512as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28513for as_dir in $PATH
28514do
28515  IFS=$as_save_IFS
28516  test -z "$as_dir" && as_dir=.
28517    for ac_exec_ext in '' $ac_executable_extensions; do
28518  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28519    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
28520    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28521    break 2
28522  fi
28523done
28524  done
28525IFS=$as_save_IFS
28526
28527fi
28528fi
28529CC=$ac_cv_prog_CC
28530if test -n "$CC"; then
28531  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
28532$as_echo "$CC" >&6; }
28533else
28534  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28535$as_echo "no" >&6; }
28536fi
28537
28538
28539    test -n "$CC" && break
28540  done
28541fi
28542if test -z "$CC"; then
28543  ac_ct_CC=$CC
28544  for ac_prog in $CC
28545do
28546  # Extract the first word of "$ac_prog", so it can be a program name with args.
28547set dummy $ac_prog; ac_word=$2
28548{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28549$as_echo_n "checking for $ac_word... " >&6; }
28550if ${ac_cv_prog_ac_ct_CC+:} false; then :
28551  $as_echo_n "(cached) " >&6
28552else
28553  if test -n "$ac_ct_CC"; then
28554  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
28555else
28556as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28557for as_dir in $PATH
28558do
28559  IFS=$as_save_IFS
28560  test -z "$as_dir" && as_dir=.
28561    for ac_exec_ext in '' $ac_executable_extensions; do
28562  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28563    ac_cv_prog_ac_ct_CC="$ac_prog"
28564    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28565    break 2
28566  fi
28567done
28568  done
28569IFS=$as_save_IFS
28570
28571fi
28572fi
28573ac_ct_CC=$ac_cv_prog_ac_ct_CC
28574if test -n "$ac_ct_CC"; then
28575  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
28576$as_echo "$ac_ct_CC" >&6; }
28577else
28578  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28579$as_echo "no" >&6; }
28580fi
28581
28582
28583  test -n "$ac_ct_CC" && break
28584done
28585
28586  if test "x$ac_ct_CC" = x; then
28587    CC=""
28588  else
28589    case $cross_compiling:$ac_tool_warned in
28590yes:)
28591{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28592$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28593ac_tool_warned=yes ;;
28594esac
28595    CC=$ac_ct_CC
28596  fi
28597fi
28598
28599
28600test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28601$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28602as_fn_error $? "no acceptable C compiler found in \$PATH
28603See \`config.log' for more details" "$LINENO" 5; }
28604
28605# Provide some information about the compiler.
28606$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
28607set X $ac_compile
28608ac_compiler=$2
28609for ac_option in --version -v -V -qversion; do
28610  { { ac_try="$ac_compiler $ac_option >&5"
28611case "(($ac_try" in
28612  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28613  *) ac_try_echo=$ac_try;;
28614esac
28615eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28616$as_echo "$ac_try_echo"; } >&5
28617  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
28618  ac_status=$?
28619  if test -s conftest.err; then
28620    sed '10a\
28621... rest of stderr output deleted ...
28622         10q' conftest.err >conftest.er1
28623    cat conftest.er1 >&5
28624  fi
28625  rm -f conftest.er1 conftest.err
28626  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28627  test $ac_status = 0; }
28628done
28629
28630cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28631/* end confdefs.h.  */
28632
28633int
28634main ()
28635{
28636
28637  ;
28638  return 0;
28639}
28640_ACEOF
28641ac_clean_files_save=$ac_clean_files
28642ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
28643# Try to create an executable without -o first, disregard a.out.
28644# It will help us diagnose broken compilers, and finding out an intuition
28645# of exeext.
28646{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
28647$as_echo_n "checking whether the C compiler works... " >&6; }
28648ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
28649
28650# The possible output files:
28651ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
28652
28653ac_rmfiles=
28654for ac_file in $ac_files
28655do
28656  case $ac_file in
28657    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28658    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
28659  esac
28660done
28661rm -f $ac_rmfiles
28662
28663if { { ac_try="$ac_link_default"
28664case "(($ac_try" in
28665  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28666  *) ac_try_echo=$ac_try;;
28667esac
28668eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28669$as_echo "$ac_try_echo"; } >&5
28670  (eval "$ac_link_default") 2>&5
28671  ac_status=$?
28672  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28673  test $ac_status = 0; }; then :
28674  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
28675# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
28676# in a Makefile.  We should not override ac_cv_exeext if it was cached,
28677# so that the user can short-circuit this test for compilers unknown to
28678# Autoconf.
28679for ac_file in $ac_files ''
28680do
28681  test -f "$ac_file" || continue
28682  case $ac_file in
28683    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
28684	;;
28685    [ab].out )
28686	# We found the default executable, but exeext='' is most
28687	# certainly right.
28688	break;;
28689    *.* )
28690	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
28691	then :; else
28692	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28693	fi
28694	# We set ac_cv_exeext here because the later test for it is not
28695	# safe: cross compilers may not add the suffix if given an `-o'
28696	# argument, so we may need to know it at that point already.
28697	# Even if this section looks crufty: it has the advantage of
28698	# actually working.
28699	break;;
28700    * )
28701	break;;
28702  esac
28703done
28704test "$ac_cv_exeext" = no && ac_cv_exeext=
28705
28706else
28707  ac_file=''
28708fi
28709if test -z "$ac_file"; then :
28710  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28711$as_echo "no" >&6; }
28712$as_echo "$as_me: failed program was:" >&5
28713sed 's/^/| /' conftest.$ac_ext >&5
28714
28715{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28716$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28717as_fn_error 77 "C compiler cannot create executables
28718See \`config.log' for more details" "$LINENO" 5; }
28719else
28720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28721$as_echo "yes" >&6; }
28722fi
28723{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
28724$as_echo_n "checking for C compiler default output file name... " >&6; }
28725{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
28726$as_echo "$ac_file" >&6; }
28727ac_exeext=$ac_cv_exeext
28728
28729rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
28730ac_clean_files=$ac_clean_files_save
28731{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
28732$as_echo_n "checking for suffix of executables... " >&6; }
28733if { { ac_try="$ac_link"
28734case "(($ac_try" in
28735  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28736  *) ac_try_echo=$ac_try;;
28737esac
28738eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28739$as_echo "$ac_try_echo"; } >&5
28740  (eval "$ac_link") 2>&5
28741  ac_status=$?
28742  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28743  test $ac_status = 0; }; then :
28744  # If both `conftest.exe' and `conftest' are `present' (well, observable)
28745# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
28746# work properly (i.e., refer to `conftest.exe'), while it won't with
28747# `rm'.
28748for ac_file in conftest.exe conftest conftest.*; do
28749  test -f "$ac_file" || continue
28750  case $ac_file in
28751    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
28752    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
28753	  break;;
28754    * ) break;;
28755  esac
28756done
28757else
28758  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28759$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28760as_fn_error $? "cannot compute suffix of executables: cannot compile and link
28761See \`config.log' for more details" "$LINENO" 5; }
28762fi
28763rm -f conftest conftest$ac_cv_exeext
28764{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
28765$as_echo "$ac_cv_exeext" >&6; }
28766
28767rm -f conftest.$ac_ext
28768EXEEXT=$ac_cv_exeext
28769ac_exeext=$EXEEXT
28770cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28771/* end confdefs.h.  */
28772#include <stdio.h>
28773int
28774main ()
28775{
28776FILE *f = fopen ("conftest.out", "w");
28777 return ferror (f) || fclose (f) != 0;
28778
28779  ;
28780  return 0;
28781}
28782_ACEOF
28783ac_clean_files="$ac_clean_files conftest.out"
28784# Check that the compiler produces executables we can run.  If not, either
28785# the compiler is broken, or we cross compile.
28786{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
28787$as_echo_n "checking whether we are cross compiling... " >&6; }
28788if test "$cross_compiling" != yes; then
28789  { { ac_try="$ac_link"
28790case "(($ac_try" in
28791  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28792  *) ac_try_echo=$ac_try;;
28793esac
28794eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28795$as_echo "$ac_try_echo"; } >&5
28796  (eval "$ac_link") 2>&5
28797  ac_status=$?
28798  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28799  test $ac_status = 0; }
28800  if { ac_try='./conftest$ac_cv_exeext'
28801  { { case "(($ac_try" in
28802  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28803  *) ac_try_echo=$ac_try;;
28804esac
28805eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28806$as_echo "$ac_try_echo"; } >&5
28807  (eval "$ac_try") 2>&5
28808  ac_status=$?
28809  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28810  test $ac_status = 0; }; }; then
28811    cross_compiling=no
28812  else
28813    if test "$cross_compiling" = maybe; then
28814	cross_compiling=yes
28815    else
28816	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28817$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28818as_fn_error $? "cannot run C compiled programs.
28819If you meant to cross compile, use \`--host'.
28820See \`config.log' for more details" "$LINENO" 5; }
28821    fi
28822  fi
28823fi
28824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
28825$as_echo "$cross_compiling" >&6; }
28826
28827rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
28828ac_clean_files=$ac_clean_files_save
28829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
28830$as_echo_n "checking for suffix of object files... " >&6; }
28831if ${ac_cv_objext+:} false; then :
28832  $as_echo_n "(cached) " >&6
28833else
28834  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28835/* end confdefs.h.  */
28836
28837int
28838main ()
28839{
28840
28841  ;
28842  return 0;
28843}
28844_ACEOF
28845rm -f conftest.o conftest.obj
28846if { { ac_try="$ac_compile"
28847case "(($ac_try" in
28848  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28849  *) ac_try_echo=$ac_try;;
28850esac
28851eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28852$as_echo "$ac_try_echo"; } >&5
28853  (eval "$ac_compile") 2>&5
28854  ac_status=$?
28855  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28856  test $ac_status = 0; }; then :
28857  for ac_file in conftest.o conftest.obj conftest.*; do
28858  test -f "$ac_file" || continue;
28859  case $ac_file in
28860    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
28861    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
28862       break;;
28863  esac
28864done
28865else
28866  $as_echo "$as_me: failed program was:" >&5
28867sed 's/^/| /' conftest.$ac_ext >&5
28868
28869{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28870$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28871as_fn_error $? "cannot compute suffix of object files: cannot compile
28872See \`config.log' for more details" "$LINENO" 5; }
28873fi
28874rm -f conftest.$ac_cv_objext conftest.$ac_ext
28875fi
28876{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
28877$as_echo "$ac_cv_objext" >&6; }
28878OBJEXT=$ac_cv_objext
28879ac_objext=$OBJEXT
28880{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
28881$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
28882if ${ac_cv_c_compiler_gnu+:} false; then :
28883  $as_echo_n "(cached) " >&6
28884else
28885  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28886/* end confdefs.h.  */
28887
28888int
28889main ()
28890{
28891#ifndef __GNUC__
28892       choke me
28893#endif
28894
28895  ;
28896  return 0;
28897}
28898_ACEOF
28899if ac_fn_c_try_compile "$LINENO"; then :
28900  ac_compiler_gnu=yes
28901else
28902  ac_compiler_gnu=no
28903fi
28904rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28905ac_cv_c_compiler_gnu=$ac_compiler_gnu
28906
28907fi
28908{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
28909$as_echo "$ac_cv_c_compiler_gnu" >&6; }
28910if test $ac_compiler_gnu = yes; then
28911  GCC=yes
28912else
28913  GCC=
28914fi
28915ac_test_CFLAGS=${CFLAGS+set}
28916ac_save_CFLAGS=$CFLAGS
28917{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
28918$as_echo_n "checking whether $CC accepts -g... " >&6; }
28919if ${ac_cv_prog_cc_g+:} false; then :
28920  $as_echo_n "(cached) " >&6
28921else
28922  ac_save_c_werror_flag=$ac_c_werror_flag
28923   ac_c_werror_flag=yes
28924   ac_cv_prog_cc_g=no
28925   CFLAGS="-g"
28926   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28927/* end confdefs.h.  */
28928
28929int
28930main ()
28931{
28932
28933  ;
28934  return 0;
28935}
28936_ACEOF
28937if ac_fn_c_try_compile "$LINENO"; then :
28938  ac_cv_prog_cc_g=yes
28939else
28940  CFLAGS=""
28941      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28942/* end confdefs.h.  */
28943
28944int
28945main ()
28946{
28947
28948  ;
28949  return 0;
28950}
28951_ACEOF
28952if ac_fn_c_try_compile "$LINENO"; then :
28953
28954else
28955  ac_c_werror_flag=$ac_save_c_werror_flag
28956	 CFLAGS="-g"
28957	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28958/* end confdefs.h.  */
28959
28960int
28961main ()
28962{
28963
28964  ;
28965  return 0;
28966}
28967_ACEOF
28968if ac_fn_c_try_compile "$LINENO"; then :
28969  ac_cv_prog_cc_g=yes
28970fi
28971rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28972fi
28973rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28974fi
28975rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28976   ac_c_werror_flag=$ac_save_c_werror_flag
28977fi
28978{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
28979$as_echo "$ac_cv_prog_cc_g" >&6; }
28980if test "$ac_test_CFLAGS" = set; then
28981  CFLAGS=$ac_save_CFLAGS
28982elif test $ac_cv_prog_cc_g = yes; then
28983  if test "$GCC" = yes; then
28984    CFLAGS="-g -O2"
28985  else
28986    CFLAGS="-g"
28987  fi
28988else
28989  if test "$GCC" = yes; then
28990    CFLAGS="-O2"
28991  else
28992    CFLAGS=
28993  fi
28994fi
28995{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
28996$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
28997if ${ac_cv_prog_cc_c89+:} false; then :
28998  $as_echo_n "(cached) " >&6
28999else
29000  ac_cv_prog_cc_c89=no
29001ac_save_CC=$CC
29002cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29003/* end confdefs.h.  */
29004#include <stdarg.h>
29005#include <stdio.h>
29006struct stat;
29007/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
29008struct buf { int x; };
29009FILE * (*rcsopen) (struct buf *, struct stat *, int);
29010static char *e (p, i)
29011     char **p;
29012     int i;
29013{
29014  return p[i];
29015}
29016static char *f (char * (*g) (char **, int), char **p, ...)
29017{
29018  char *s;
29019  va_list v;
29020  va_start (v,p);
29021  s = g (p, va_arg (v,int));
29022  va_end (v);
29023  return s;
29024}
29025
29026/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
29027   function prototypes and stuff, but not '\xHH' hex character constants.
29028   These don't provoke an error unfortunately, instead are silently treated
29029   as 'x'.  The following induces an error, until -std is added to get
29030   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
29031   array size at least.  It's necessary to write '\x00'==0 to get something
29032   that's true only with -std.  */
29033int osf4_cc_array ['\x00' == 0 ? 1 : -1];
29034
29035/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
29036   inside strings and character constants.  */
29037#define FOO(x) 'x'
29038int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
29039
29040int test (int i, double x);
29041struct s1 {int (*f) (int a);};
29042struct s2 {int (*f) (double a);};
29043int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
29044int argc;
29045char **argv;
29046int
29047main ()
29048{
29049return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
29050  ;
29051  return 0;
29052}
29053_ACEOF
29054for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
29055	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
29056do
29057  CC="$ac_save_CC $ac_arg"
29058  if ac_fn_c_try_compile "$LINENO"; then :
29059  ac_cv_prog_cc_c89=$ac_arg
29060fi
29061rm -f core conftest.err conftest.$ac_objext
29062  test "x$ac_cv_prog_cc_c89" != "xno" && break
29063done
29064rm -f conftest.$ac_ext
29065CC=$ac_save_CC
29066
29067fi
29068# AC_CACHE_VAL
29069case "x$ac_cv_prog_cc_c89" in
29070  x)
29071    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
29072$as_echo "none needed" >&6; } ;;
29073  xno)
29074    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
29075$as_echo "unsupported" >&6; } ;;
29076  *)
29077    CC="$CC $ac_cv_prog_cc_c89"
29078    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
29079$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
29080esac
29081if test "x$ac_cv_prog_cc_c89" != xno; then :
29082
29083fi
29084
29085ac_ext=cpp
29086ac_cpp='$CXXCPP $CPPFLAGS'
29087ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29088ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29089ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29090
29091
29092
29093  COMPILER_NAME=C++
29094  SEARCH_LIST="$TOOLCHAIN_CXX_BINARY"
29095
29096  if test "x$CXX" != x; then
29097    # User has supplied compiler name already, always let that override.
29098    { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
29099$as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
29100    if test "x`basename $CXX`" = "x$CXX"; then
29101      # A command without a complete path is provided, search $PATH.
29102
29103      for ac_prog in $CXX
29104do
29105  # Extract the first word of "$ac_prog", so it can be a program name with args.
29106set dummy $ac_prog; ac_word=$2
29107{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29108$as_echo_n "checking for $ac_word... " >&6; }
29109if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29110  $as_echo_n "(cached) " >&6
29111else
29112  case $POTENTIAL_CXX in
29113  [\\/]* | ?:[\\/]*)
29114  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29115  ;;
29116  *)
29117  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29118for as_dir in $PATH
29119do
29120  IFS=$as_save_IFS
29121  test -z "$as_dir" && as_dir=.
29122    for ac_exec_ext in '' $ac_executable_extensions; do
29123  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29124    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29125    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29126    break 2
29127  fi
29128done
29129  done
29130IFS=$as_save_IFS
29131
29132  ;;
29133esac
29134fi
29135POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29136if test -n "$POTENTIAL_CXX"; then
29137  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29138$as_echo "$POTENTIAL_CXX" >&6; }
29139else
29140  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29141$as_echo "no" >&6; }
29142fi
29143
29144
29145  test -n "$POTENTIAL_CXX" && break
29146done
29147
29148      if test "x$POTENTIAL_CXX" != x; then
29149        CXX=$POTENTIAL_CXX
29150      else
29151        as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29152      fi
29153    else
29154      # Otherwise it might already be a complete path
29155      if test ! -x "$CXX"; then
29156        as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29157      fi
29158    fi
29159  else
29160    # No user supplied value. Locate compiler ourselves.
29161
29162    # If we are cross compiling, assume cross compilation tools follows the
29163    # cross compilation standard where they are prefixed with the autoconf
29164    # standard name for the target. For example the binary
29165    # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29166    # If we are not cross compiling, then the default compiler name will be
29167    # used.
29168
29169    CXX=
29170    # If TOOLS_DIR is set, check for all compiler names in there first
29171    # before checking the rest of the PATH.
29172    # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29173    # step, this should not be necessary.
29174    if test -n "$TOOLS_DIR"; then
29175      PATH_save="$PATH"
29176      PATH="$TOOLS_DIR"
29177      for ac_prog in $SEARCH_LIST
29178do
29179  # Extract the first word of "$ac_prog", so it can be a program name with args.
29180set dummy $ac_prog; ac_word=$2
29181{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29182$as_echo_n "checking for $ac_word... " >&6; }
29183if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then :
29184  $as_echo_n "(cached) " >&6
29185else
29186  case $TOOLS_DIR_CXX in
29187  [\\/]* | ?:[\\/]*)
29188  ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path.
29189  ;;
29190  *)
29191  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29192for as_dir in $PATH
29193do
29194  IFS=$as_save_IFS
29195  test -z "$as_dir" && as_dir=.
29196    for ac_exec_ext in '' $ac_executable_extensions; do
29197  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29198    ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext"
29199    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29200    break 2
29201  fi
29202done
29203  done
29204IFS=$as_save_IFS
29205
29206  ;;
29207esac
29208fi
29209TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX
29210if test -n "$TOOLS_DIR_CXX"; then
29211  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5
29212$as_echo "$TOOLS_DIR_CXX" >&6; }
29213else
29214  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29215$as_echo "no" >&6; }
29216fi
29217
29218
29219  test -n "$TOOLS_DIR_CXX" && break
29220done
29221
29222      CXX=$TOOLS_DIR_CXX
29223      PATH="$PATH_save"
29224    fi
29225
29226    # AC_PATH_PROGS can't be run multiple times with the same variable,
29227    # so create a new name for this run.
29228    if test "x$CXX" = x; then
29229      for ac_prog in $SEARCH_LIST
29230do
29231  # Extract the first word of "$ac_prog", so it can be a program name with args.
29232set dummy $ac_prog; ac_word=$2
29233{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29234$as_echo_n "checking for $ac_word... " >&6; }
29235if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29236  $as_echo_n "(cached) " >&6
29237else
29238  case $POTENTIAL_CXX in
29239  [\\/]* | ?:[\\/]*)
29240  ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29241  ;;
29242  *)
29243  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29244for as_dir in $PATH
29245do
29246  IFS=$as_save_IFS
29247  test -z "$as_dir" && as_dir=.
29248    for ac_exec_ext in '' $ac_executable_extensions; do
29249  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29250    ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29251    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29252    break 2
29253  fi
29254done
29255  done
29256IFS=$as_save_IFS
29257
29258  ;;
29259esac
29260fi
29261POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29262if test -n "$POTENTIAL_CXX"; then
29263  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29264$as_echo "$POTENTIAL_CXX" >&6; }
29265else
29266  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29267$as_echo "no" >&6; }
29268fi
29269
29270
29271  test -n "$POTENTIAL_CXX" && break
29272done
29273
29274      CXX=$POTENTIAL_CXX
29275    fi
29276
29277    if test "x$CXX" = x; then
29278
29279  # Print a helpful message on how to acquire the necessary build dependency.
29280  # devkit is the help tag: freetype, cups, pulse, alsa etc
29281  MISSING_DEPENDENCY=devkit
29282
29283  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29284    cygwin_help $MISSING_DEPENDENCY
29285  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29286    msys_help $MISSING_DEPENDENCY
29287  else
29288    PKGHANDLER_COMMAND=
29289
29290    case $PKGHANDLER in
29291      apt-get)
29292        apt_help     $MISSING_DEPENDENCY ;;
29293      yum)
29294        yum_help     $MISSING_DEPENDENCY ;;
29295      port)
29296        port_help    $MISSING_DEPENDENCY ;;
29297      pkgutil)
29298        pkgutil_help $MISSING_DEPENDENCY ;;
29299      pkgadd)
29300        pkgadd_help  $MISSING_DEPENDENCY ;;
29301    esac
29302
29303    if test "x$PKGHANDLER_COMMAND" != x; then
29304      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29305    fi
29306  fi
29307
29308      as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29309    fi
29310  fi
29311
29312  # Now we have a compiler binary in CXX. Make sure it's okay.
29313
29314  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29315
29316  # First separate the path from the arguments. This will split at the first
29317  # space.
29318  complete="$CXX"
29319  path="${complete%% *}"
29320  tmp="$complete EOL"
29321  arguments="${tmp#* }"
29322
29323  # Input might be given as Windows format, start by converting to
29324  # unix format.
29325  new_path=`$CYGPATH -u "$path"`
29326
29327  # Now try to locate executable using which
29328  new_path=`$WHICH "$new_path" 2> /dev/null`
29329  # bat and cmd files are not always considered executable in cygwin causing which
29330  # to not find them
29331  if test "x$new_path" = x \
29332      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29333      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29334    new_path=`$CYGPATH -u "$path"`
29335  fi
29336  if test "x$new_path" = x; then
29337    # Oops. Which didn't find the executable.
29338    # The splitting of arguments from the executable at a space might have been incorrect,
29339    # since paths with space are more likely in Windows. Give it another try with the whole
29340    # argument.
29341    path="$complete"
29342    arguments="EOL"
29343    new_path=`$CYGPATH -u "$path"`
29344    new_path=`$WHICH "$new_path" 2> /dev/null`
29345    # bat and cmd files are not always considered executable in cygwin causing which
29346    # to not find them
29347    if test "x$new_path" = x \
29348        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29349        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29350      new_path=`$CYGPATH -u "$path"`
29351    fi
29352    if test "x$new_path" = x; then
29353      # It's still not found. Now this is an unrecoverable error.
29354      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29355$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29356      has_space=`$ECHO "$complete" | $GREP " "`
29357      if test "x$has_space" != x; then
29358        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29359$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29360      fi
29361      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29362    fi
29363  fi
29364
29365  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29366  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29367  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29368  # "foo.exe" is OK but "foo" is an error.
29369  #
29370  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29371  # It is also a way to make sure we got the proper file name for the real test later on.
29372  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29373  if test "x$test_shortpath" = x; then
29374    # Short path failed, file does not exist as specified.
29375    # Try adding .exe or .cmd
29376    if test -f "${new_path}.exe"; then
29377      input_to_shortpath="${new_path}.exe"
29378    elif test -f "${new_path}.cmd"; then
29379      input_to_shortpath="${new_path}.cmd"
29380    else
29381      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
29382$as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
29383      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29384$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29385      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29386    fi
29387  else
29388    input_to_shortpath="$new_path"
29389  fi
29390
29391  # Call helper function which possibly converts this using DOS-style short mode.
29392  # If so, the updated path is stored in $new_path.
29393  new_path="$input_to_shortpath"
29394
29395  input_path="$input_to_shortpath"
29396  # Check if we need to convert this using DOS-style short mode. If the path
29397  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29398  # take no chances and rewrite it.
29399  # Note: m4 eats our [], so we need to use [ and ] instead.
29400  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29401  if test "x$has_forbidden_chars" != x; then
29402    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29403    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29404    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29405    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29406      # Going to short mode and back again did indeed matter. Since short mode is
29407      # case insensitive, let's make it lowercase to improve readability.
29408      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29409      # Now convert it back to Unix-stile (cygpath)
29410      input_path=`$CYGPATH -u "$shortmode_path"`
29411      new_path="$input_path"
29412    fi
29413  fi
29414
29415  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29416  if test "x$test_cygdrive_prefix" = x; then
29417    # As a simple fix, exclude /usr/bin since it's not a real path.
29418    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29419      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29420      # a path prefixed by /cygdrive for fixpath to work.
29421      new_path="$CYGWIN_ROOT_PATH$input_path"
29422    fi
29423  fi
29424
29425  # remove trailing .exe if any
29426  new_path="${new_path/%.exe/}"
29427
29428  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29429
29430  # First separate the path from the arguments. This will split at the first
29431  # space.
29432  complete="$CXX"
29433  path="${complete%% *}"
29434  tmp="$complete EOL"
29435  arguments="${tmp#* }"
29436
29437  # Input might be given as Windows format, start by converting to
29438  # unix format.
29439  new_path="$path"
29440
29441  windows_path="$new_path"
29442  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29443    unix_path=`$CYGPATH -u "$windows_path"`
29444    new_path="$unix_path"
29445  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29446    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29447    new_path="$unix_path"
29448  fi
29449
29450
29451  # Now try to locate executable using which
29452  new_path=`$WHICH "$new_path" 2> /dev/null`
29453
29454  if test "x$new_path" = x; then
29455    # Oops. Which didn't find the executable.
29456    # The splitting of arguments from the executable at a space might have been incorrect,
29457    # since paths with space are more likely in Windows. Give it another try with the whole
29458    # argument.
29459    path="$complete"
29460    arguments="EOL"
29461    new_path="$path"
29462
29463  windows_path="$new_path"
29464  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29465    unix_path=`$CYGPATH -u "$windows_path"`
29466    new_path="$unix_path"
29467  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29468    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29469    new_path="$unix_path"
29470  fi
29471
29472
29473    new_path=`$WHICH "$new_path" 2> /dev/null`
29474
29475    if test "x$new_path" = x; then
29476      # It's still not found. Now this is an unrecoverable error.
29477      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29478$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29479      has_space=`$ECHO "$complete" | $GREP " "`
29480      if test "x$has_space" != x; then
29481        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29482$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29483      fi
29484      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29485    fi
29486  fi
29487
29488  # Now new_path has a complete unix path to the binary
29489  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29490    # Keep paths in /bin as-is, but remove trailing .exe if any
29491    new_path="${new_path/%.exe/}"
29492    # Do not save /bin paths to all_fixpath_prefixes!
29493  else
29494    # Not in mixed or Windows style, start by that.
29495    new_path=`cmd //c echo $new_path`
29496
29497  input_path="$new_path"
29498  # Check if we need to convert this using DOS-style short mode. If the path
29499  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29500  # take no chances and rewrite it.
29501  # Note: m4 eats our [], so we need to use [ and ] instead.
29502  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29503  if test "x$has_forbidden_chars" != x; then
29504    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29505    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29506  fi
29507
29508    # Output is in $new_path
29509
29510  windows_path="$new_path"
29511  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29512    unix_path=`$CYGPATH -u "$windows_path"`
29513    new_path="$unix_path"
29514  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29515    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29516    new_path="$unix_path"
29517  fi
29518
29519    # remove trailing .exe if any
29520    new_path="${new_path/%.exe/}"
29521
29522    # Save the first 10 bytes of this path to the storage, so fixpath can work.
29523    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29524  fi
29525
29526  else
29527    # We're on a posix platform. Hooray! :)
29528    # First separate the path from the arguments. This will split at the first
29529    # space.
29530    complete="$CXX"
29531    path="${complete%% *}"
29532    tmp="$complete EOL"
29533    arguments="${tmp#* }"
29534
29535    # Cannot rely on the command "which" here since it doesn't always work.
29536    is_absolute_path=`$ECHO "$path" | $GREP ^/`
29537    if test -z "$is_absolute_path"; then
29538      # Path to executable is not absolute. Find it.
29539      IFS_save="$IFS"
29540      IFS=:
29541      for p in $PATH; do
29542        if test -f "$p/$path" && test -x "$p/$path"; then
29543          new_path="$p/$path"
29544          break
29545        fi
29546      done
29547      IFS="$IFS_save"
29548    else
29549      # This is an absolute path, we can use it without further modifications.
29550      new_path="$path"
29551    fi
29552
29553    if test "x$new_path" = x; then
29554      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29555$as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29556      has_space=`$ECHO "$complete" | $GREP " "`
29557      if test "x$has_space" != x; then
29558        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29559$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29560      fi
29561      as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29562    fi
29563  fi
29564
29565  # Now join together the path and the arguments once again
29566  if test "x$arguments" != xEOL; then
29567    new_complete="$new_path ${arguments% *}"
29568  else
29569    new_complete="$new_path"
29570  fi
29571
29572  if test "x$complete" != "x$new_complete"; then
29573    CXX="$new_complete"
29574    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
29575$as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
29576  fi
29577
29578  TEST_COMPILER="$CXX"
29579  # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29580  # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29581  if test "x$OPENJDK_BUILD_OS" != xaix; then
29582    # FIXME: This test should not be needed anymore; we don't do that for any platform.
29583    { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
29584$as_echo_n "checking resolved symbolic links for CXX... " >&6; }
29585
29586  if test "x$OPENJDK_BUILD_OS" != xwindows; then
29587    # Follow a chain of symbolic links. Use readlink
29588    # where it exists, else fall back to horribly
29589    # complicated shell code.
29590    if test "x$READLINK_TESTED" != yes; then
29591      # On MacOSX there is a readlink tool with a different
29592      # purpose than the GNU readlink tool. Check the found readlink.
29593      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29594      if test "x$ISGNU" = x; then
29595        # A readlink that we do not know how to use.
29596        # Are there other non-GNU readlinks out there?
29597        READLINK_TESTED=yes
29598        READLINK=
29599      fi
29600    fi
29601
29602    if test "x$READLINK" != x; then
29603      TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29604    else
29605      # Save the current directory for restoring afterwards
29606      STARTDIR=$PWD
29607      COUNTER=0
29608      sym_link_dir=`$DIRNAME $TEST_COMPILER`
29609      sym_link_file=`$BASENAME $TEST_COMPILER`
29610      cd $sym_link_dir
29611      # Use -P flag to resolve symlinks in directories.
29612      cd `$THEPWDCMD -P`
29613      sym_link_dir=`$THEPWDCMD -P`
29614      # Resolve file symlinks
29615      while test $COUNTER -lt 20; do
29616        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
29617        if test "x$ISLINK" == x; then
29618          # This is not a symbolic link! We are done!
29619          break
29620        fi
29621        # Again resolve directory symlinks since the target of the just found
29622        # link could be in a different directory
29623        cd `$DIRNAME $ISLINK`
29624        sym_link_dir=`$THEPWDCMD -P`
29625        sym_link_file=`$BASENAME $ISLINK`
29626        let COUNTER=COUNTER+1
29627      done
29628      cd $STARTDIR
29629      TEST_COMPILER=$sym_link_dir/$sym_link_file
29630    fi
29631  fi
29632
29633    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
29634$as_echo "$TEST_COMPILER" >&6; }
29635  fi
29636  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
29637$as_echo_n "checking if CXX is disguised ccache... " >&6; }
29638
29639  COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
29640  if test "x$COMPILER_BASENAME" = "xccache"; then
29641    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
29642$as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
29643    # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
29644    # We want to control ccache invocation ourselves, so ignore this cc and try
29645    # searching again.
29646
29647    # Remove the path to the fake ccache cc from the PATH
29648    RETRY_COMPILER_SAVED_PATH="$PATH"
29649    COMPILER_DIRNAME=`$DIRNAME $CXX`
29650    PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
29651
29652    # Try again looking for our compiler
29653    if test -n "$ac_tool_prefix"; then
29654  for ac_prog in $TOOLCHAIN_CXX_BINARY
29655  do
29656    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
29657set dummy $ac_tool_prefix$ac_prog; ac_word=$2
29658{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29659$as_echo_n "checking for $ac_word... " >&6; }
29660if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
29661  $as_echo_n "(cached) " >&6
29662else
29663  if test -n "$PROPER_COMPILER_CXX"; then
29664  ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
29665else
29666as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29667for as_dir in $PATH
29668do
29669  IFS=$as_save_IFS
29670  test -z "$as_dir" && as_dir=.
29671    for ac_exec_ext in '' $ac_executable_extensions; do
29672  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29673    ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
29674    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29675    break 2
29676  fi
29677done
29678  done
29679IFS=$as_save_IFS
29680
29681fi
29682fi
29683PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
29684if test -n "$PROPER_COMPILER_CXX"; then
29685  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
29686$as_echo "$PROPER_COMPILER_CXX" >&6; }
29687else
29688  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29689$as_echo "no" >&6; }
29690fi
29691
29692
29693    test -n "$PROPER_COMPILER_CXX" && break
29694  done
29695fi
29696if test -z "$PROPER_COMPILER_CXX"; then
29697  ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
29698  for ac_prog in $TOOLCHAIN_CXX_BINARY
29699do
29700  # Extract the first word of "$ac_prog", so it can be a program name with args.
29701set dummy $ac_prog; ac_word=$2
29702{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29703$as_echo_n "checking for $ac_word... " >&6; }
29704if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
29705  $as_echo_n "(cached) " >&6
29706else
29707  if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29708  ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
29709else
29710as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29711for as_dir in $PATH
29712do
29713  IFS=$as_save_IFS
29714  test -z "$as_dir" && as_dir=.
29715    for ac_exec_ext in '' $ac_executable_extensions; do
29716  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29717    ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
29718    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29719    break 2
29720  fi
29721done
29722  done
29723IFS=$as_save_IFS
29724
29725fi
29726fi
29727ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
29728if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
29729  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
29730$as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
29731else
29732  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29733$as_echo "no" >&6; }
29734fi
29735
29736
29737  test -n "$ac_ct_PROPER_COMPILER_CXX" && break
29738done
29739
29740  if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
29741    PROPER_COMPILER_CXX=""
29742  else
29743    case $cross_compiling:$ac_tool_warned in
29744yes:)
29745{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
29746$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
29747ac_tool_warned=yes ;;
29748esac
29749    PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
29750  fi
29751fi
29752
29753
29754  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29755
29756  # First separate the path from the arguments. This will split at the first
29757  # space.
29758  complete="$PROPER_COMPILER_CXX"
29759  path="${complete%% *}"
29760  tmp="$complete EOL"
29761  arguments="${tmp#* }"
29762
29763  # Input might be given as Windows format, start by converting to
29764  # unix format.
29765  new_path=`$CYGPATH -u "$path"`
29766
29767  # Now try to locate executable using which
29768  new_path=`$WHICH "$new_path" 2> /dev/null`
29769  # bat and cmd files are not always considered executable in cygwin causing which
29770  # to not find them
29771  if test "x$new_path" = x \
29772      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29773      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29774    new_path=`$CYGPATH -u "$path"`
29775  fi
29776  if test "x$new_path" = x; then
29777    # Oops. Which didn't find the executable.
29778    # The splitting of arguments from the executable at a space might have been incorrect,
29779    # since paths with space are more likely in Windows. Give it another try with the whole
29780    # argument.
29781    path="$complete"
29782    arguments="EOL"
29783    new_path=`$CYGPATH -u "$path"`
29784    new_path=`$WHICH "$new_path" 2> /dev/null`
29785    # bat and cmd files are not always considered executable in cygwin causing which
29786    # to not find them
29787    if test "x$new_path" = x \
29788        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29789        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29790      new_path=`$CYGPATH -u "$path"`
29791    fi
29792    if test "x$new_path" = x; then
29793      # It's still not found. Now this is an unrecoverable error.
29794      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29795$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29796      has_space=`$ECHO "$complete" | $GREP " "`
29797      if test "x$has_space" != x; then
29798        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29799$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29800      fi
29801      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29802    fi
29803  fi
29804
29805  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29806  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29807  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29808  # "foo.exe" is OK but "foo" is an error.
29809  #
29810  # This test is therefore slightly more accurate than "test -f" to check for file presence.
29811  # It is also a way to make sure we got the proper file name for the real test later on.
29812  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29813  if test "x$test_shortpath" = x; then
29814    # Short path failed, file does not exist as specified.
29815    # Try adding .exe or .cmd
29816    if test -f "${new_path}.exe"; then
29817      input_to_shortpath="${new_path}.exe"
29818    elif test -f "${new_path}.cmd"; then
29819      input_to_shortpath="${new_path}.cmd"
29820    else
29821      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
29822$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
29823      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29824$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29825      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29826    fi
29827  else
29828    input_to_shortpath="$new_path"
29829  fi
29830
29831  # Call helper function which possibly converts this using DOS-style short mode.
29832  # If so, the updated path is stored in $new_path.
29833  new_path="$input_to_shortpath"
29834
29835  input_path="$input_to_shortpath"
29836  # Check if we need to convert this using DOS-style short mode. If the path
29837  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29838  # take no chances and rewrite it.
29839  # Note: m4 eats our [], so we need to use [ and ] instead.
29840  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29841  if test "x$has_forbidden_chars" != x; then
29842    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29843    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29844    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29845    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29846      # Going to short mode and back again did indeed matter. Since short mode is
29847      # case insensitive, let's make it lowercase to improve readability.
29848      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29849      # Now convert it back to Unix-stile (cygpath)
29850      input_path=`$CYGPATH -u "$shortmode_path"`
29851      new_path="$input_path"
29852    fi
29853  fi
29854
29855  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29856  if test "x$test_cygdrive_prefix" = x; then
29857    # As a simple fix, exclude /usr/bin since it's not a real path.
29858    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29859      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29860      # a path prefixed by /cygdrive for fixpath to work.
29861      new_path="$CYGWIN_ROOT_PATH$input_path"
29862    fi
29863  fi
29864
29865  # remove trailing .exe if any
29866  new_path="${new_path/%.exe/}"
29867
29868  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29869
29870  # First separate the path from the arguments. This will split at the first
29871  # space.
29872  complete="$PROPER_COMPILER_CXX"
29873  path="${complete%% *}"
29874  tmp="$complete EOL"
29875  arguments="${tmp#* }"
29876
29877  # Input might be given as Windows format, start by converting to
29878  # unix format.
29879  new_path="$path"
29880
29881  windows_path="$new_path"
29882  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29883    unix_path=`$CYGPATH -u "$windows_path"`
29884    new_path="$unix_path"
29885  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29886    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29887    new_path="$unix_path"
29888  fi
29889
29890
29891  # Now try to locate executable using which
29892  new_path=`$WHICH "$new_path" 2> /dev/null`
29893
29894  if test "x$new_path" = x; then
29895    # Oops. Which didn't find the executable.
29896    # The splitting of arguments from the executable at a space might have been incorrect,
29897    # since paths with space are more likely in Windows. Give it another try with the whole
29898    # argument.
29899    path="$complete"
29900    arguments="EOL"
29901    new_path="$path"
29902
29903  windows_path="$new_path"
29904  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29905    unix_path=`$CYGPATH -u "$windows_path"`
29906    new_path="$unix_path"
29907  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29908    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29909    new_path="$unix_path"
29910  fi
29911
29912
29913    new_path=`$WHICH "$new_path" 2> /dev/null`
29914
29915    if test "x$new_path" = x; then
29916      # It's still not found. Now this is an unrecoverable error.
29917      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29918$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29919      has_space=`$ECHO "$complete" | $GREP " "`
29920      if test "x$has_space" != x; then
29921        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29922$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29923      fi
29924      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
29925    fi
29926  fi
29927
29928  # Now new_path has a complete unix path to the binary
29929  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29930    # Keep paths in /bin as-is, but remove trailing .exe if any
29931    new_path="${new_path/%.exe/}"
29932    # Do not save /bin paths to all_fixpath_prefixes!
29933  else
29934    # Not in mixed or Windows style, start by that.
29935    new_path=`cmd //c echo $new_path`
29936
29937  input_path="$new_path"
29938  # Check if we need to convert this using DOS-style short mode. If the path
29939  # contains just simple characters, use it. Otherwise (spaces, weird characters),
29940  # take no chances and rewrite it.
29941  # Note: m4 eats our [], so we need to use [ and ] instead.
29942  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29943  if test "x$has_forbidden_chars" != x; then
29944    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29945    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29946  fi
29947
29948    # Output is in $new_path
29949
29950  windows_path="$new_path"
29951  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29952    unix_path=`$CYGPATH -u "$windows_path"`
29953    new_path="$unix_path"
29954  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29955    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29956    new_path="$unix_path"
29957  fi
29958
29959    # remove trailing .exe if any
29960    new_path="${new_path/%.exe/}"
29961
29962    # Save the first 10 bytes of this path to the storage, so fixpath can work.
29963    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29964  fi
29965
29966  else
29967    # We're on a posix platform. Hooray! :)
29968    # First separate the path from the arguments. This will split at the first
29969    # space.
29970    complete="$PROPER_COMPILER_CXX"
29971    path="${complete%% *}"
29972    tmp="$complete EOL"
29973    arguments="${tmp#* }"
29974
29975    # Cannot rely on the command "which" here since it doesn't always work.
29976    is_absolute_path=`$ECHO "$path" | $GREP ^/`
29977    if test -z "$is_absolute_path"; then
29978      # Path to executable is not absolute. Find it.
29979      IFS_save="$IFS"
29980      IFS=:
29981      for p in $PATH; do
29982        if test -f "$p/$path" && test -x "$p/$path"; then
29983          new_path="$p/$path"
29984          break
29985        fi
29986      done
29987      IFS="$IFS_save"
29988    else
29989      # This is an absolute path, we can use it without further modifications.
29990      new_path="$path"
29991    fi
29992
29993    if test "x$new_path" = x; then
29994      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
29995$as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
29996      has_space=`$ECHO "$complete" | $GREP " "`
29997      if test "x$has_space" != x; then
29998        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29999$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30000      fi
30001      as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30002    fi
30003  fi
30004
30005  # Now join together the path and the arguments once again
30006  if test "x$arguments" != xEOL; then
30007    new_complete="$new_path ${arguments% *}"
30008  else
30009    new_complete="$new_path"
30010  fi
30011
30012  if test "x$complete" != "x$new_complete"; then
30013    PROPER_COMPILER_CXX="$new_complete"
30014    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
30015$as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
30016  fi
30017
30018    PATH="$RETRY_COMPILER_SAVED_PATH"
30019
30020    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
30021$as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
30022
30023  if test "x$OPENJDK_BUILD_OS" != xwindows; then
30024    # Follow a chain of symbolic links. Use readlink
30025    # where it exists, else fall back to horribly
30026    # complicated shell code.
30027    if test "x$READLINK_TESTED" != yes; then
30028      # On MacOSX there is a readlink tool with a different
30029      # purpose than the GNU readlink tool. Check the found readlink.
30030      ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30031      if test "x$ISGNU" = x; then
30032        # A readlink that we do not know how to use.
30033        # Are there other non-GNU readlinks out there?
30034        READLINK_TESTED=yes
30035        READLINK=
30036      fi
30037    fi
30038
30039    if test "x$READLINK" != x; then
30040      PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
30041    else
30042      # Save the current directory for restoring afterwards
30043      STARTDIR=$PWD
30044      COUNTER=0
30045      sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
30046      sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
30047      cd $sym_link_dir
30048      # Use -P flag to resolve symlinks in directories.
30049      cd `$THEPWDCMD -P`
30050      sym_link_dir=`$THEPWDCMD -P`
30051      # Resolve file symlinks
30052      while test $COUNTER -lt 20; do
30053        ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30054        if test "x$ISLINK" == x; then
30055          # This is not a symbolic link! We are done!
30056          break
30057        fi
30058        # Again resolve directory symlinks since the target of the just found
30059        # link could be in a different directory
30060        cd `$DIRNAME $ISLINK`
30061        sym_link_dir=`$THEPWDCMD -P`
30062        sym_link_file=`$BASENAME $ISLINK`
30063        let COUNTER=COUNTER+1
30064      done
30065      cd $STARTDIR
30066      PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
30067    fi
30068  fi
30069
30070    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30071$as_echo "$PROPER_COMPILER_CXX" >&6; }
30072    CXX="$PROPER_COMPILER_CXX"
30073  else
30074    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
30075$as_echo "no, keeping CXX" >&6; }
30076  fi
30077
30078
30079  COMPILER=$CXX
30080  COMPILER_NAME=$COMPILER_NAME
30081
30082  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
30083    # cc -V output typically looks like
30084    #     cc: Sun C 5.12 Linux_i386 2011/11/16
30085    COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
30086    # Check that this is likely to be the Solaris Studio cc.
30087    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30088    if test $? -ne 0; then
30089      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30090      { $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
30091$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30092      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30093$as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30094      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30095$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30096      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30097    fi
30098    # Remove usage instructions (if present), and
30099    # collapse compiler output into a single line
30100    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30101        $SED -e 's/ *[Uu]sage:.*//'`
30102    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30103        $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
30104  elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
30105    # xlc -qversion output typically looks like
30106    #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
30107    #     Version: 11.01.0000.0015
30108    COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
30109    # Check that this is likely to be the IBM XL C compiler.
30110    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
30111    if test $? -ne 0; then
30112      ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30113      { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30114$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30115      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30116$as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30117      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30118$as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30119      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30120    fi
30121    # Collapse compiler output into a single line
30122    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30123    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30124        $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
30125  elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
30126    # There is no specific version flag, but all output starts with a version string.
30127    # First line typically looks something like:
30128    # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30129    COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30130    # Check that this is likely to be Microsoft CL.EXE.
30131    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
30132    if test $? -ne 0; then
30133      { $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
30134$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30135      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30136$as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30137      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30138    fi
30139    # Collapse compiler output into a single line
30140    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30141    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30142        $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
30143  elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
30144    # gcc --version output typically looks like
30145    #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
30146    #     Copyright (C) 2013 Free Software Foundation, Inc.
30147    #     This is free software; see the source for copying conditions.  There is NO
30148    #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30149    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30150    # Check that this is likely to be GCC.
30151    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
30152    if test $? -ne 0; then
30153      { $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
30154$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30155      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
30156$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
30157      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30158    fi
30159    # Remove Copyright and legalese from version string, and
30160    # collapse into a single line
30161    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30162        $SED -e 's/ *Copyright .*//'`
30163    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30164        $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
30165  elif test  "x$TOOLCHAIN_TYPE" = xclang; then
30166    # clang --version output typically looks like
30167    #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
30168    #    clang version 3.3 (tags/RELEASE_33/final)
30169    # or
30170    #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
30171    #    Target: x86_64-pc-linux-gnu
30172    #    Thread model: posix
30173    COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30174    # Check that this is likely to be clang
30175    $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
30176    if test $? -ne 0; then
30177      { $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
30178$as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30179      { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30180$as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30181      as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30182    fi
30183    # Collapse compiler output into a single line
30184    COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30185    COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30186        $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
30187  else
30188      as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
30189  fi
30190  # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
30191  CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
30192  # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
30193  CXX_VERSION_STRING="$COMPILER_VERSION_STRING"
30194
30195  { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
30196$as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
30197
30198
30199  # Now that we have resolved CXX ourself, let autoconf have its go at it
30200  ac_ext=cpp
30201ac_cpp='$CXXCPP $CPPFLAGS'
30202ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30203ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30204ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30205if test -z "$CXX"; then
30206  if test -n "$CCC"; then
30207    CXX=$CCC
30208  else
30209    if test -n "$ac_tool_prefix"; then
30210  for ac_prog in $CXX
30211  do
30212    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30213set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30214{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30215$as_echo_n "checking for $ac_word... " >&6; }
30216if ${ac_cv_prog_CXX+:} false; then :
30217  $as_echo_n "(cached) " >&6
30218else
30219  if test -n "$CXX"; then
30220  ac_cv_prog_CXX="$CXX" # Let the user override the test.
30221else
30222as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30223for as_dir in $PATH
30224do
30225  IFS=$as_save_IFS
30226  test -z "$as_dir" && as_dir=.
30227    for ac_exec_ext in '' $ac_executable_extensions; do
30228  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30229    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
30230    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30231    break 2
30232  fi
30233done
30234  done
30235IFS=$as_save_IFS
30236
30237fi
30238fi
30239CXX=$ac_cv_prog_CXX
30240if test -n "$CXX"; then
30241  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
30242$as_echo "$CXX" >&6; }
30243else
30244  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30245$as_echo "no" >&6; }
30246fi
30247
30248
30249    test -n "$CXX" && break
30250  done
30251fi
30252if test -z "$CXX"; then
30253  ac_ct_CXX=$CXX
30254  for ac_prog in $CXX
30255do
30256  # Extract the first word of "$ac_prog", so it can be a program name with args.
30257set dummy $ac_prog; ac_word=$2
30258{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30259$as_echo_n "checking for $ac_word... " >&6; }
30260if ${ac_cv_prog_ac_ct_CXX+:} false; then :
30261  $as_echo_n "(cached) " >&6
30262else
30263  if test -n "$ac_ct_CXX"; then
30264  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
30265else
30266as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30267for as_dir in $PATH
30268do
30269  IFS=$as_save_IFS
30270  test -z "$as_dir" && as_dir=.
30271    for ac_exec_ext in '' $ac_executable_extensions; do
30272  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30273    ac_cv_prog_ac_ct_CXX="$ac_prog"
30274    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30275    break 2
30276  fi
30277done
30278  done
30279IFS=$as_save_IFS
30280
30281fi
30282fi
30283ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
30284if test -n "$ac_ct_CXX"; then
30285  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
30286$as_echo "$ac_ct_CXX" >&6; }
30287else
30288  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30289$as_echo "no" >&6; }
30290fi
30291
30292
30293  test -n "$ac_ct_CXX" && break
30294done
30295
30296  if test "x$ac_ct_CXX" = x; then
30297    CXX="g++"
30298  else
30299    case $cross_compiling:$ac_tool_warned in
30300yes:)
30301{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30302$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30303ac_tool_warned=yes ;;
30304esac
30305    CXX=$ac_ct_CXX
30306  fi
30307fi
30308
30309  fi
30310fi
30311# Provide some information about the compiler.
30312$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
30313set X $ac_compile
30314ac_compiler=$2
30315for ac_option in --version -v -V -qversion; do
30316  { { ac_try="$ac_compiler $ac_option >&5"
30317case "(($ac_try" in
30318  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30319  *) ac_try_echo=$ac_try;;
30320esac
30321eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30322$as_echo "$ac_try_echo"; } >&5
30323  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30324  ac_status=$?
30325  if test -s conftest.err; then
30326    sed '10a\
30327... rest of stderr output deleted ...
30328         10q' conftest.err >conftest.er1
30329    cat conftest.er1 >&5
30330  fi
30331  rm -f conftest.er1 conftest.err
30332  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30333  test $ac_status = 0; }
30334done
30335
30336{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
30337$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
30338if ${ac_cv_cxx_compiler_gnu+:} false; then :
30339  $as_echo_n "(cached) " >&6
30340else
30341  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30342/* end confdefs.h.  */
30343
30344int
30345main ()
30346{
30347#ifndef __GNUC__
30348       choke me
30349#endif
30350
30351  ;
30352  return 0;
30353}
30354_ACEOF
30355if ac_fn_cxx_try_compile "$LINENO"; then :
30356  ac_compiler_gnu=yes
30357else
30358  ac_compiler_gnu=no
30359fi
30360rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30361ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
30362
30363fi
30364{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
30365$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
30366if test $ac_compiler_gnu = yes; then
30367  GXX=yes
30368else
30369  GXX=
30370fi
30371ac_test_CXXFLAGS=${CXXFLAGS+set}
30372ac_save_CXXFLAGS=$CXXFLAGS
30373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
30374$as_echo_n "checking whether $CXX accepts -g... " >&6; }
30375if ${ac_cv_prog_cxx_g+:} false; then :
30376  $as_echo_n "(cached) " >&6
30377else
30378  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
30379   ac_cxx_werror_flag=yes
30380   ac_cv_prog_cxx_g=no
30381   CXXFLAGS="-g"
30382   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30383/* end confdefs.h.  */
30384
30385int
30386main ()
30387{
30388
30389  ;
30390  return 0;
30391}
30392_ACEOF
30393if ac_fn_cxx_try_compile "$LINENO"; then :
30394  ac_cv_prog_cxx_g=yes
30395else
30396  CXXFLAGS=""
30397      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30398/* end confdefs.h.  */
30399
30400int
30401main ()
30402{
30403
30404  ;
30405  return 0;
30406}
30407_ACEOF
30408if ac_fn_cxx_try_compile "$LINENO"; then :
30409
30410else
30411  ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30412	 CXXFLAGS="-g"
30413	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30414/* end confdefs.h.  */
30415
30416int
30417main ()
30418{
30419
30420  ;
30421  return 0;
30422}
30423_ACEOF
30424if ac_fn_cxx_try_compile "$LINENO"; then :
30425  ac_cv_prog_cxx_g=yes
30426fi
30427rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30428fi
30429rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30430fi
30431rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30432   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30433fi
30434{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
30435$as_echo "$ac_cv_prog_cxx_g" >&6; }
30436if test "$ac_test_CXXFLAGS" = set; then
30437  CXXFLAGS=$ac_save_CXXFLAGS
30438elif test $ac_cv_prog_cxx_g = yes; then
30439  if test "$GXX" = yes; then
30440    CXXFLAGS="-g -O2"
30441  else
30442    CXXFLAGS="-g"
30443  fi
30444else
30445  if test "$GXX" = yes; then
30446    CXXFLAGS="-O2"
30447  else
30448    CXXFLAGS=
30449  fi
30450fi
30451ac_ext=cpp
30452ac_cpp='$CXXCPP $CPPFLAGS'
30453ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30454ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30455ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30456
30457
30458  #
30459  # Setup the preprocessor (CPP and CXXCPP)
30460  #
30461  ac_ext=c
30462ac_cpp='$CPP $CPPFLAGS'
30463ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30464ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30465ac_compiler_gnu=$ac_cv_c_compiler_gnu
30466{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
30467$as_echo_n "checking how to run the C preprocessor... " >&6; }
30468# On Suns, sometimes $CPP names a directory.
30469if test -n "$CPP" && test -d "$CPP"; then
30470  CPP=
30471fi
30472if test -z "$CPP"; then
30473  if ${ac_cv_prog_CPP+:} false; then :
30474  $as_echo_n "(cached) " >&6
30475else
30476      # Double quotes because CPP needs to be expanded
30477    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
30478    do
30479      ac_preproc_ok=false
30480for ac_c_preproc_warn_flag in '' yes
30481do
30482  # Use a header file that comes with gcc, so configuring glibc
30483  # with a fresh cross-compiler works.
30484  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30485  # <limits.h> exists even on freestanding compilers.
30486  # On the NeXT, cc -E runs the code through the compiler's parser,
30487  # not just through cpp. "Syntax error" is here to catch this case.
30488  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30489/* end confdefs.h.  */
30490#ifdef __STDC__
30491# include <limits.h>
30492#else
30493# include <assert.h>
30494#endif
30495		     Syntax error
30496_ACEOF
30497if ac_fn_c_try_cpp "$LINENO"; then :
30498
30499else
30500  # Broken: fails on valid input.
30501continue
30502fi
30503rm -f conftest.err conftest.i conftest.$ac_ext
30504
30505  # OK, works on sane cases.  Now check whether nonexistent headers
30506  # can be detected and how.
30507  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30508/* end confdefs.h.  */
30509#include <ac_nonexistent.h>
30510_ACEOF
30511if ac_fn_c_try_cpp "$LINENO"; then :
30512  # Broken: success on invalid input.
30513continue
30514else
30515  # Passes both tests.
30516ac_preproc_ok=:
30517break
30518fi
30519rm -f conftest.err conftest.i conftest.$ac_ext
30520
30521done
30522# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30523rm -f conftest.i conftest.err conftest.$ac_ext
30524if $ac_preproc_ok; then :
30525  break
30526fi
30527
30528    done
30529    ac_cv_prog_CPP=$CPP
30530
30531fi
30532  CPP=$ac_cv_prog_CPP
30533else
30534  ac_cv_prog_CPP=$CPP
30535fi
30536{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
30537$as_echo "$CPP" >&6; }
30538ac_preproc_ok=false
30539for ac_c_preproc_warn_flag in '' yes
30540do
30541  # Use a header file that comes with gcc, so configuring glibc
30542  # with a fresh cross-compiler works.
30543  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30544  # <limits.h> exists even on freestanding compilers.
30545  # On the NeXT, cc -E runs the code through the compiler's parser,
30546  # not just through cpp. "Syntax error" is here to catch this case.
30547  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30548/* end confdefs.h.  */
30549#ifdef __STDC__
30550# include <limits.h>
30551#else
30552# include <assert.h>
30553#endif
30554		     Syntax error
30555_ACEOF
30556if ac_fn_c_try_cpp "$LINENO"; then :
30557
30558else
30559  # Broken: fails on valid input.
30560continue
30561fi
30562rm -f conftest.err conftest.i conftest.$ac_ext
30563
30564  # OK, works on sane cases.  Now check whether nonexistent headers
30565  # can be detected and how.
30566  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30567/* end confdefs.h.  */
30568#include <ac_nonexistent.h>
30569_ACEOF
30570if ac_fn_c_try_cpp "$LINENO"; then :
30571  # Broken: success on invalid input.
30572continue
30573else
30574  # Passes both tests.
30575ac_preproc_ok=:
30576break
30577fi
30578rm -f conftest.err conftest.i conftest.$ac_ext
30579
30580done
30581# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30582rm -f conftest.i conftest.err conftest.$ac_ext
30583if $ac_preproc_ok; then :
30584
30585else
30586  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30587$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30588as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
30589See \`config.log' for more details" "$LINENO" 5; }
30590fi
30591
30592ac_ext=cpp
30593ac_cpp='$CXXCPP $CPPFLAGS'
30594ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30595ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30596ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30597
30598
30599  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30600
30601  # First separate the path from the arguments. This will split at the first
30602  # space.
30603  complete="$CPP"
30604  path="${complete%% *}"
30605  tmp="$complete EOL"
30606  arguments="${tmp#* }"
30607
30608  # Input might be given as Windows format, start by converting to
30609  # unix format.
30610  new_path=`$CYGPATH -u "$path"`
30611
30612  # Now try to locate executable using which
30613  new_path=`$WHICH "$new_path" 2> /dev/null`
30614  # bat and cmd files are not always considered executable in cygwin causing which
30615  # to not find them
30616  if test "x$new_path" = x \
30617      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30618      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30619    new_path=`$CYGPATH -u "$path"`
30620  fi
30621  if test "x$new_path" = x; then
30622    # Oops. Which didn't find the executable.
30623    # The splitting of arguments from the executable at a space might have been incorrect,
30624    # since paths with space are more likely in Windows. Give it another try with the whole
30625    # argument.
30626    path="$complete"
30627    arguments="EOL"
30628    new_path=`$CYGPATH -u "$path"`
30629    new_path=`$WHICH "$new_path" 2> /dev/null`
30630    # bat and cmd files are not always considered executable in cygwin causing which
30631    # to not find them
30632    if test "x$new_path" = x \
30633        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30634        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30635      new_path=`$CYGPATH -u "$path"`
30636    fi
30637    if test "x$new_path" = x; then
30638      # It's still not found. Now this is an unrecoverable error.
30639      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30640$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30641      has_space=`$ECHO "$complete" | $GREP " "`
30642      if test "x$has_space" != x; then
30643        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30644$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30645      fi
30646      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30647    fi
30648  fi
30649
30650  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30651  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30652  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30653  # "foo.exe" is OK but "foo" is an error.
30654  #
30655  # This test is therefore slightly more accurate than "test -f" to check for file presence.
30656  # It is also a way to make sure we got the proper file name for the real test later on.
30657  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30658  if test "x$test_shortpath" = x; then
30659    # Short path failed, file does not exist as specified.
30660    # Try adding .exe or .cmd
30661    if test -f "${new_path}.exe"; then
30662      input_to_shortpath="${new_path}.exe"
30663    elif test -f "${new_path}.cmd"; then
30664      input_to_shortpath="${new_path}.cmd"
30665    else
30666      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
30667$as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
30668      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30669$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30670      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30671    fi
30672  else
30673    input_to_shortpath="$new_path"
30674  fi
30675
30676  # Call helper function which possibly converts this using DOS-style short mode.
30677  # If so, the updated path is stored in $new_path.
30678  new_path="$input_to_shortpath"
30679
30680  input_path="$input_to_shortpath"
30681  # Check if we need to convert this using DOS-style short mode. If the path
30682  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30683  # take no chances and rewrite it.
30684  # Note: m4 eats our [], so we need to use [ and ] instead.
30685  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30686  if test "x$has_forbidden_chars" != x; then
30687    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30688    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30689    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30690    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30691      # Going to short mode and back again did indeed matter. Since short mode is
30692      # case insensitive, let's make it lowercase to improve readability.
30693      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30694      # Now convert it back to Unix-stile (cygpath)
30695      input_path=`$CYGPATH -u "$shortmode_path"`
30696      new_path="$input_path"
30697    fi
30698  fi
30699
30700  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30701  if test "x$test_cygdrive_prefix" = x; then
30702    # As a simple fix, exclude /usr/bin since it's not a real path.
30703    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30704      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30705      # a path prefixed by /cygdrive for fixpath to work.
30706      new_path="$CYGWIN_ROOT_PATH$input_path"
30707    fi
30708  fi
30709
30710  # remove trailing .exe if any
30711  new_path="${new_path/%.exe/}"
30712
30713  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30714
30715  # First separate the path from the arguments. This will split at the first
30716  # space.
30717  complete="$CPP"
30718  path="${complete%% *}"
30719  tmp="$complete EOL"
30720  arguments="${tmp#* }"
30721
30722  # Input might be given as Windows format, start by converting to
30723  # unix format.
30724  new_path="$path"
30725
30726  windows_path="$new_path"
30727  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30728    unix_path=`$CYGPATH -u "$windows_path"`
30729    new_path="$unix_path"
30730  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30731    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30732    new_path="$unix_path"
30733  fi
30734
30735
30736  # Now try to locate executable using which
30737  new_path=`$WHICH "$new_path" 2> /dev/null`
30738
30739  if test "x$new_path" = x; then
30740    # Oops. Which didn't find the executable.
30741    # The splitting of arguments from the executable at a space might have been incorrect,
30742    # since paths with space are more likely in Windows. Give it another try with the whole
30743    # argument.
30744    path="$complete"
30745    arguments="EOL"
30746    new_path="$path"
30747
30748  windows_path="$new_path"
30749  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30750    unix_path=`$CYGPATH -u "$windows_path"`
30751    new_path="$unix_path"
30752  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30753    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30754    new_path="$unix_path"
30755  fi
30756
30757
30758    new_path=`$WHICH "$new_path" 2> /dev/null`
30759
30760    if test "x$new_path" = x; then
30761      # It's still not found. Now this is an unrecoverable error.
30762      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30763$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30764      has_space=`$ECHO "$complete" | $GREP " "`
30765      if test "x$has_space" != x; then
30766        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30767$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30768      fi
30769      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30770    fi
30771  fi
30772
30773  # Now new_path has a complete unix path to the binary
30774  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30775    # Keep paths in /bin as-is, but remove trailing .exe if any
30776    new_path="${new_path/%.exe/}"
30777    # Do not save /bin paths to all_fixpath_prefixes!
30778  else
30779    # Not in mixed or Windows style, start by that.
30780    new_path=`cmd //c echo $new_path`
30781
30782  input_path="$new_path"
30783  # Check if we need to convert this using DOS-style short mode. If the path
30784  # contains just simple characters, use it. Otherwise (spaces, weird characters),
30785  # take no chances and rewrite it.
30786  # Note: m4 eats our [], so we need to use [ and ] instead.
30787  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30788  if test "x$has_forbidden_chars" != x; then
30789    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30790    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30791  fi
30792
30793    # Output is in $new_path
30794
30795  windows_path="$new_path"
30796  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30797    unix_path=`$CYGPATH -u "$windows_path"`
30798    new_path="$unix_path"
30799  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30800    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30801    new_path="$unix_path"
30802  fi
30803
30804    # remove trailing .exe if any
30805    new_path="${new_path/%.exe/}"
30806
30807    # Save the first 10 bytes of this path to the storage, so fixpath can work.
30808    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30809  fi
30810
30811  else
30812    # We're on a posix platform. Hooray! :)
30813    # First separate the path from the arguments. This will split at the first
30814    # space.
30815    complete="$CPP"
30816    path="${complete%% *}"
30817    tmp="$complete EOL"
30818    arguments="${tmp#* }"
30819
30820    # Cannot rely on the command "which" here since it doesn't always work.
30821    is_absolute_path=`$ECHO "$path" | $GREP ^/`
30822    if test -z "$is_absolute_path"; then
30823      # Path to executable is not absolute. Find it.
30824      IFS_save="$IFS"
30825      IFS=:
30826      for p in $PATH; do
30827        if test -f "$p/$path" && test -x "$p/$path"; then
30828          new_path="$p/$path"
30829          break
30830        fi
30831      done
30832      IFS="$IFS_save"
30833    else
30834      # This is an absolute path, we can use it without further modifications.
30835      new_path="$path"
30836    fi
30837
30838    if test "x$new_path" = x; then
30839      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
30840$as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
30841      has_space=`$ECHO "$complete" | $GREP " "`
30842      if test "x$has_space" != x; then
30843        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30844$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30845      fi
30846      as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
30847    fi
30848  fi
30849
30850  # Now join together the path and the arguments once again
30851  if test "x$arguments" != xEOL; then
30852    new_complete="$new_path ${arguments% *}"
30853  else
30854    new_complete="$new_path"
30855  fi
30856
30857  if test "x$complete" != "x$new_complete"; then
30858    CPP="$new_complete"
30859    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
30860$as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
30861  fi
30862
30863  ac_ext=cpp
30864ac_cpp='$CXXCPP $CPPFLAGS'
30865ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30866ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30867ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30868{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
30869$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
30870if test -z "$CXXCPP"; then
30871  if ${ac_cv_prog_CXXCPP+:} false; then :
30872  $as_echo_n "(cached) " >&6
30873else
30874      # Double quotes because CXXCPP needs to be expanded
30875    for CXXCPP in "$CXX -E" "/lib/cpp"
30876    do
30877      ac_preproc_ok=false
30878for ac_cxx_preproc_warn_flag in '' yes
30879do
30880  # Use a header file that comes with gcc, so configuring glibc
30881  # with a fresh cross-compiler works.
30882  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30883  # <limits.h> exists even on freestanding compilers.
30884  # On the NeXT, cc -E runs the code through the compiler's parser,
30885  # not just through cpp. "Syntax error" is here to catch this case.
30886  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30887/* end confdefs.h.  */
30888#ifdef __STDC__
30889# include <limits.h>
30890#else
30891# include <assert.h>
30892#endif
30893		     Syntax error
30894_ACEOF
30895if ac_fn_cxx_try_cpp "$LINENO"; then :
30896
30897else
30898  # Broken: fails on valid input.
30899continue
30900fi
30901rm -f conftest.err conftest.i conftest.$ac_ext
30902
30903  # OK, works on sane cases.  Now check whether nonexistent headers
30904  # can be detected and how.
30905  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30906/* end confdefs.h.  */
30907#include <ac_nonexistent.h>
30908_ACEOF
30909if ac_fn_cxx_try_cpp "$LINENO"; then :
30910  # Broken: success on invalid input.
30911continue
30912else
30913  # Passes both tests.
30914ac_preproc_ok=:
30915break
30916fi
30917rm -f conftest.err conftest.i conftest.$ac_ext
30918
30919done
30920# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30921rm -f conftest.i conftest.err conftest.$ac_ext
30922if $ac_preproc_ok; then :
30923  break
30924fi
30925
30926    done
30927    ac_cv_prog_CXXCPP=$CXXCPP
30928
30929fi
30930  CXXCPP=$ac_cv_prog_CXXCPP
30931else
30932  ac_cv_prog_CXXCPP=$CXXCPP
30933fi
30934{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
30935$as_echo "$CXXCPP" >&6; }
30936ac_preproc_ok=false
30937for ac_cxx_preproc_warn_flag in '' yes
30938do
30939  # Use a header file that comes with gcc, so configuring glibc
30940  # with a fresh cross-compiler works.
30941  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30942  # <limits.h> exists even on freestanding compilers.
30943  # On the NeXT, cc -E runs the code through the compiler's parser,
30944  # not just through cpp. "Syntax error" is here to catch this case.
30945  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30946/* end confdefs.h.  */
30947#ifdef __STDC__
30948# include <limits.h>
30949#else
30950# include <assert.h>
30951#endif
30952		     Syntax error
30953_ACEOF
30954if ac_fn_cxx_try_cpp "$LINENO"; then :
30955
30956else
30957  # Broken: fails on valid input.
30958continue
30959fi
30960rm -f conftest.err conftest.i conftest.$ac_ext
30961
30962  # OK, works on sane cases.  Now check whether nonexistent headers
30963  # can be detected and how.
30964  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30965/* end confdefs.h.  */
30966#include <ac_nonexistent.h>
30967_ACEOF
30968if ac_fn_cxx_try_cpp "$LINENO"; then :
30969  # Broken: success on invalid input.
30970continue
30971else
30972  # Passes both tests.
30973ac_preproc_ok=:
30974break
30975fi
30976rm -f conftest.err conftest.i conftest.$ac_ext
30977
30978done
30979# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30980rm -f conftest.i conftest.err conftest.$ac_ext
30981if $ac_preproc_ok; then :
30982
30983else
30984  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30985$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30986as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
30987See \`config.log' for more details" "$LINENO" 5; }
30988fi
30989
30990ac_ext=cpp
30991ac_cpp='$CXXCPP $CPPFLAGS'
30992ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30993ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30994ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30995
30996
30997  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30998
30999  # First separate the path from the arguments. This will split at the first
31000  # space.
31001  complete="$CXXCPP"
31002  path="${complete%% *}"
31003  tmp="$complete EOL"
31004  arguments="${tmp#* }"
31005
31006  # Input might be given as Windows format, start by converting to
31007  # unix format.
31008  new_path=`$CYGPATH -u "$path"`
31009
31010  # Now try to locate executable using which
31011  new_path=`$WHICH "$new_path" 2> /dev/null`
31012  # bat and cmd files are not always considered executable in cygwin causing which
31013  # to not find them
31014  if test "x$new_path" = x \
31015      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31016      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31017    new_path=`$CYGPATH -u "$path"`
31018  fi
31019  if test "x$new_path" = x; then
31020    # Oops. Which didn't find the executable.
31021    # The splitting of arguments from the executable at a space might have been incorrect,
31022    # since paths with space are more likely in Windows. Give it another try with the whole
31023    # argument.
31024    path="$complete"
31025    arguments="EOL"
31026    new_path=`$CYGPATH -u "$path"`
31027    new_path=`$WHICH "$new_path" 2> /dev/null`
31028    # bat and cmd files are not always considered executable in cygwin causing which
31029    # to not find them
31030    if test "x$new_path" = x \
31031        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31032        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31033      new_path=`$CYGPATH -u "$path"`
31034    fi
31035    if test "x$new_path" = x; then
31036      # It's still not found. Now this is an unrecoverable error.
31037      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31038$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31039      has_space=`$ECHO "$complete" | $GREP " "`
31040      if test "x$has_space" != x; then
31041        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31042$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31043      fi
31044      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31045    fi
31046  fi
31047
31048  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31049  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31050  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31051  # "foo.exe" is OK but "foo" is an error.
31052  #
31053  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31054  # It is also a way to make sure we got the proper file name for the real test later on.
31055  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31056  if test "x$test_shortpath" = x; then
31057    # Short path failed, file does not exist as specified.
31058    # Try adding .exe or .cmd
31059    if test -f "${new_path}.exe"; then
31060      input_to_shortpath="${new_path}.exe"
31061    elif test -f "${new_path}.cmd"; then
31062      input_to_shortpath="${new_path}.cmd"
31063    else
31064      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
31065$as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
31066      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31067$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31068      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31069    fi
31070  else
31071    input_to_shortpath="$new_path"
31072  fi
31073
31074  # Call helper function which possibly converts this using DOS-style short mode.
31075  # If so, the updated path is stored in $new_path.
31076  new_path="$input_to_shortpath"
31077
31078  input_path="$input_to_shortpath"
31079  # Check if we need to convert this using DOS-style short mode. If the path
31080  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31081  # take no chances and rewrite it.
31082  # Note: m4 eats our [], so we need to use [ and ] instead.
31083  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31084  if test "x$has_forbidden_chars" != x; then
31085    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31086    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31087    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31088    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31089      # Going to short mode and back again did indeed matter. Since short mode is
31090      # case insensitive, let's make it lowercase to improve readability.
31091      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31092      # Now convert it back to Unix-stile (cygpath)
31093      input_path=`$CYGPATH -u "$shortmode_path"`
31094      new_path="$input_path"
31095    fi
31096  fi
31097
31098  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31099  if test "x$test_cygdrive_prefix" = x; then
31100    # As a simple fix, exclude /usr/bin since it's not a real path.
31101    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31102      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31103      # a path prefixed by /cygdrive for fixpath to work.
31104      new_path="$CYGWIN_ROOT_PATH$input_path"
31105    fi
31106  fi
31107
31108  # remove trailing .exe if any
31109  new_path="${new_path/%.exe/}"
31110
31111  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31112
31113  # First separate the path from the arguments. This will split at the first
31114  # space.
31115  complete="$CXXCPP"
31116  path="${complete%% *}"
31117  tmp="$complete EOL"
31118  arguments="${tmp#* }"
31119
31120  # Input might be given as Windows format, start by converting to
31121  # unix format.
31122  new_path="$path"
31123
31124  windows_path="$new_path"
31125  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31126    unix_path=`$CYGPATH -u "$windows_path"`
31127    new_path="$unix_path"
31128  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31129    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31130    new_path="$unix_path"
31131  fi
31132
31133
31134  # Now try to locate executable using which
31135  new_path=`$WHICH "$new_path" 2> /dev/null`
31136
31137  if test "x$new_path" = x; then
31138    # Oops. Which didn't find the executable.
31139    # The splitting of arguments from the executable at a space might have been incorrect,
31140    # since paths with space are more likely in Windows. Give it another try with the whole
31141    # argument.
31142    path="$complete"
31143    arguments="EOL"
31144    new_path="$path"
31145
31146  windows_path="$new_path"
31147  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31148    unix_path=`$CYGPATH -u "$windows_path"`
31149    new_path="$unix_path"
31150  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31151    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31152    new_path="$unix_path"
31153  fi
31154
31155
31156    new_path=`$WHICH "$new_path" 2> /dev/null`
31157
31158    if test "x$new_path" = x; then
31159      # It's still not found. Now this is an unrecoverable error.
31160      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31161$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31162      has_space=`$ECHO "$complete" | $GREP " "`
31163      if test "x$has_space" != x; then
31164        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31165$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31166      fi
31167      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31168    fi
31169  fi
31170
31171  # Now new_path has a complete unix path to the binary
31172  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31173    # Keep paths in /bin as-is, but remove trailing .exe if any
31174    new_path="${new_path/%.exe/}"
31175    # Do not save /bin paths to all_fixpath_prefixes!
31176  else
31177    # Not in mixed or Windows style, start by that.
31178    new_path=`cmd //c echo $new_path`
31179
31180  input_path="$new_path"
31181  # Check if we need to convert this using DOS-style short mode. If the path
31182  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31183  # take no chances and rewrite it.
31184  # Note: m4 eats our [], so we need to use [ and ] instead.
31185  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31186  if test "x$has_forbidden_chars" != x; then
31187    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31188    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31189  fi
31190
31191    # Output is in $new_path
31192
31193  windows_path="$new_path"
31194  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31195    unix_path=`$CYGPATH -u "$windows_path"`
31196    new_path="$unix_path"
31197  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31198    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31199    new_path="$unix_path"
31200  fi
31201
31202    # remove trailing .exe if any
31203    new_path="${new_path/%.exe/}"
31204
31205    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31206    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31207  fi
31208
31209  else
31210    # We're on a posix platform. Hooray! :)
31211    # First separate the path from the arguments. This will split at the first
31212    # space.
31213    complete="$CXXCPP"
31214    path="${complete%% *}"
31215    tmp="$complete EOL"
31216    arguments="${tmp#* }"
31217
31218    # Cannot rely on the command "which" here since it doesn't always work.
31219    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31220    if test -z "$is_absolute_path"; then
31221      # Path to executable is not absolute. Find it.
31222      IFS_save="$IFS"
31223      IFS=:
31224      for p in $PATH; do
31225        if test -f "$p/$path" && test -x "$p/$path"; then
31226          new_path="$p/$path"
31227          break
31228        fi
31229      done
31230      IFS="$IFS_save"
31231    else
31232      # This is an absolute path, we can use it without further modifications.
31233      new_path="$path"
31234    fi
31235
31236    if test "x$new_path" = x; then
31237      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31238$as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31239      has_space=`$ECHO "$complete" | $GREP " "`
31240      if test "x$has_space" != x; then
31241        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31242$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31243      fi
31244      as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31245    fi
31246  fi
31247
31248  # Now join together the path and the arguments once again
31249  if test "x$arguments" != xEOL; then
31250    new_complete="$new_path ${arguments% *}"
31251  else
31252    new_complete="$new_path"
31253  fi
31254
31255  if test "x$complete" != "x$new_complete"; then
31256    CXXCPP="$new_complete"
31257    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
31258$as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
31259  fi
31260
31261
31262  #
31263  # Setup the linker (LD)
31264  #
31265  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
31266    # In the Microsoft toolchain we have a separate LD command "link".
31267    # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is
31268    # a cygwin program for something completely different.
31269    # Extract the first word of "link", so it can be a program name with args.
31270set dummy link; ac_word=$2
31271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31272$as_echo_n "checking for $ac_word... " >&6; }
31273if ${ac_cv_prog_LD+:} false; then :
31274  $as_echo_n "(cached) " >&6
31275else
31276  if test -n "$LD"; then
31277  ac_cv_prog_LD="$LD" # Let the user override the test.
31278else
31279  ac_prog_rejected=no
31280as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31281for as_dir in $PATH
31282do
31283  IFS=$as_save_IFS
31284  test -z "$as_dir" && as_dir=.
31285    for ac_exec_ext in '' $ac_executable_extensions; do
31286  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31287    if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
31288       ac_prog_rejected=yes
31289       continue
31290     fi
31291    ac_cv_prog_LD="link"
31292    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31293    break 2
31294  fi
31295done
31296  done
31297IFS=$as_save_IFS
31298
31299if test $ac_prog_rejected = yes; then
31300  # We found a bogon in the path, so make sure we never use it.
31301  set dummy $ac_cv_prog_LD
31302  shift
31303  if test $# != 0; then
31304    # We chose a different compiler from the bogus one.
31305    # However, it has the same basename, so the bogon will be chosen
31306    # first if we set LD to just the basename; use the full file name.
31307    shift
31308    ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@"
31309  fi
31310fi
31311fi
31312fi
31313LD=$ac_cv_prog_LD
31314if test -n "$LD"; then
31315  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
31316$as_echo "$LD" >&6; }
31317else
31318  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31319$as_echo "no" >&6; }
31320fi
31321
31322
31323
31324  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31325
31326  # First separate the path from the arguments. This will split at the first
31327  # space.
31328  complete="$LD"
31329  path="${complete%% *}"
31330  tmp="$complete EOL"
31331  arguments="${tmp#* }"
31332
31333  # Input might be given as Windows format, start by converting to
31334  # unix format.
31335  new_path=`$CYGPATH -u "$path"`
31336
31337  # Now try to locate executable using which
31338  new_path=`$WHICH "$new_path" 2> /dev/null`
31339  # bat and cmd files are not always considered executable in cygwin causing which
31340  # to not find them
31341  if test "x$new_path" = x \
31342      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31343      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31344    new_path=`$CYGPATH -u "$path"`
31345  fi
31346  if test "x$new_path" = x; then
31347    # Oops. Which didn't find the executable.
31348    # The splitting of arguments from the executable at a space might have been incorrect,
31349    # since paths with space are more likely in Windows. Give it another try with the whole
31350    # argument.
31351    path="$complete"
31352    arguments="EOL"
31353    new_path=`$CYGPATH -u "$path"`
31354    new_path=`$WHICH "$new_path" 2> /dev/null`
31355    # bat and cmd files are not always considered executable in cygwin causing which
31356    # to not find them
31357    if test "x$new_path" = x \
31358        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31359        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31360      new_path=`$CYGPATH -u "$path"`
31361    fi
31362    if test "x$new_path" = x; then
31363      # It's still not found. Now this is an unrecoverable error.
31364      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31365$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31366      has_space=`$ECHO "$complete" | $GREP " "`
31367      if test "x$has_space" != x; then
31368        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31369$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31370      fi
31371      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31372    fi
31373  fi
31374
31375  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31376  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31377  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31378  # "foo.exe" is OK but "foo" is an error.
31379  #
31380  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31381  # It is also a way to make sure we got the proper file name for the real test later on.
31382  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31383  if test "x$test_shortpath" = x; then
31384    # Short path failed, file does not exist as specified.
31385    # Try adding .exe or .cmd
31386    if test -f "${new_path}.exe"; then
31387      input_to_shortpath="${new_path}.exe"
31388    elif test -f "${new_path}.cmd"; then
31389      input_to_shortpath="${new_path}.cmd"
31390    else
31391      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5
31392$as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;}
31393      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31394$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31395      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31396    fi
31397  else
31398    input_to_shortpath="$new_path"
31399  fi
31400
31401  # Call helper function which possibly converts this using DOS-style short mode.
31402  # If so, the updated path is stored in $new_path.
31403  new_path="$input_to_shortpath"
31404
31405  input_path="$input_to_shortpath"
31406  # Check if we need to convert this using DOS-style short mode. If the path
31407  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31408  # take no chances and rewrite it.
31409  # Note: m4 eats our [], so we need to use [ and ] instead.
31410  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31411  if test "x$has_forbidden_chars" != x; then
31412    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31413    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31414    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31415    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31416      # Going to short mode and back again did indeed matter. Since short mode is
31417      # case insensitive, let's make it lowercase to improve readability.
31418      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31419      # Now convert it back to Unix-stile (cygpath)
31420      input_path=`$CYGPATH -u "$shortmode_path"`
31421      new_path="$input_path"
31422    fi
31423  fi
31424
31425  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31426  if test "x$test_cygdrive_prefix" = x; then
31427    # As a simple fix, exclude /usr/bin since it's not a real path.
31428    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31429      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31430      # a path prefixed by /cygdrive for fixpath to work.
31431      new_path="$CYGWIN_ROOT_PATH$input_path"
31432    fi
31433  fi
31434
31435  # remove trailing .exe if any
31436  new_path="${new_path/%.exe/}"
31437
31438  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31439
31440  # First separate the path from the arguments. This will split at the first
31441  # space.
31442  complete="$LD"
31443  path="${complete%% *}"
31444  tmp="$complete EOL"
31445  arguments="${tmp#* }"
31446
31447  # Input might be given as Windows format, start by converting to
31448  # unix format.
31449  new_path="$path"
31450
31451  windows_path="$new_path"
31452  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31453    unix_path=`$CYGPATH -u "$windows_path"`
31454    new_path="$unix_path"
31455  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31456    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31457    new_path="$unix_path"
31458  fi
31459
31460
31461  # Now try to locate executable using which
31462  new_path=`$WHICH "$new_path" 2> /dev/null`
31463
31464  if test "x$new_path" = x; then
31465    # Oops. Which didn't find the executable.
31466    # The splitting of arguments from the executable at a space might have been incorrect,
31467    # since paths with space are more likely in Windows. Give it another try with the whole
31468    # argument.
31469    path="$complete"
31470    arguments="EOL"
31471    new_path="$path"
31472
31473  windows_path="$new_path"
31474  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31475    unix_path=`$CYGPATH -u "$windows_path"`
31476    new_path="$unix_path"
31477  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31478    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31479    new_path="$unix_path"
31480  fi
31481
31482
31483    new_path=`$WHICH "$new_path" 2> /dev/null`
31484
31485    if test "x$new_path" = x; then
31486      # It's still not found. Now this is an unrecoverable error.
31487      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31488$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31489      has_space=`$ECHO "$complete" | $GREP " "`
31490      if test "x$has_space" != x; then
31491        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31492$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31493      fi
31494      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31495    fi
31496  fi
31497
31498  # Now new_path has a complete unix path to the binary
31499  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31500    # Keep paths in /bin as-is, but remove trailing .exe if any
31501    new_path="${new_path/%.exe/}"
31502    # Do not save /bin paths to all_fixpath_prefixes!
31503  else
31504    # Not in mixed or Windows style, start by that.
31505    new_path=`cmd //c echo $new_path`
31506
31507  input_path="$new_path"
31508  # Check if we need to convert this using DOS-style short mode. If the path
31509  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31510  # take no chances and rewrite it.
31511  # Note: m4 eats our [], so we need to use [ and ] instead.
31512  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31513  if test "x$has_forbidden_chars" != x; then
31514    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31515    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31516  fi
31517
31518    # Output is in $new_path
31519
31520  windows_path="$new_path"
31521  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31522    unix_path=`$CYGPATH -u "$windows_path"`
31523    new_path="$unix_path"
31524  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31525    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31526    new_path="$unix_path"
31527  fi
31528
31529    # remove trailing .exe if any
31530    new_path="${new_path/%.exe/}"
31531
31532    # Save the first 10 bytes of this path to the storage, so fixpath can work.
31533    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31534  fi
31535
31536  else
31537    # We're on a posix platform. Hooray! :)
31538    # First separate the path from the arguments. This will split at the first
31539    # space.
31540    complete="$LD"
31541    path="${complete%% *}"
31542    tmp="$complete EOL"
31543    arguments="${tmp#* }"
31544
31545    # Cannot rely on the command "which" here since it doesn't always work.
31546    is_absolute_path=`$ECHO "$path" | $GREP ^/`
31547    if test -z "$is_absolute_path"; then
31548      # Path to executable is not absolute. Find it.
31549      IFS_save="$IFS"
31550      IFS=:
31551      for p in $PATH; do
31552        if test -f "$p/$path" && test -x "$p/$path"; then
31553          new_path="$p/$path"
31554          break
31555        fi
31556      done
31557      IFS="$IFS_save"
31558    else
31559      # This is an absolute path, we can use it without further modifications.
31560      new_path="$path"
31561    fi
31562
31563    if test "x$new_path" = x; then
31564      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31565$as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31566      has_space=`$ECHO "$complete" | $GREP " "`
31567      if test "x$has_space" != x; then
31568        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31569$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31570      fi
31571      as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31572    fi
31573  fi
31574
31575  # Now join together the path and the arguments once again
31576  if test "x$arguments" != xEOL; then
31577    new_complete="$new_path ${arguments% *}"
31578  else
31579    new_complete="$new_path"
31580  fi
31581
31582  if test "x$complete" != "x$new_complete"; then
31583    LD="$new_complete"
31584    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5
31585$as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;}
31586  fi
31587
31588    # Verify that we indeed succeeded with this trick.
31589    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
31590$as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
31591    "$LD" --version > /dev/null
31592    if test $? -eq 0 ; then
31593      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31594$as_echo "no" >&6; }
31595      as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
31596    else
31597      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31598$as_echo "yes" >&6; }
31599    fi
31600    LDCXX="$LD"
31601  else
31602    # All other toolchains use the compiler to link.
31603    LD="$CC"
31604    LDCXX="$CXX"
31605  fi
31606
31607  # FIXME: it should be CXXLD, according to standard (cf CXXCPP)
31608
31609
31610  #
31611  # Setup the assembler (AS)
31612  #
31613  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
31614    # FIXME: should this really be solaris, or solstudio?
31615
31616
31617  # Publish this variable in the help.
31618
31619
31620  if test "x$AS" = x; then
31621    # The variable is not set by user, try to locate tool using the code snippet
31622    for ac_prog in as
31623do
31624  # Extract the first word of "$ac_prog", so it can be a program name with args.
31625set dummy $ac_prog; ac_word=$2
31626{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31627$as_echo_n "checking for $ac_word... " >&6; }
31628if ${ac_cv_path_AS+:} false; then :
31629  $as_echo_n "(cached) " >&6
31630else
31631  case $AS in
31632  [\\/]* | ?:[\\/]*)
31633  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31634  ;;
31635  *)
31636  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31637for as_dir in $PATH
31638do
31639  IFS=$as_save_IFS
31640  test -z "$as_dir" && as_dir=.
31641    for ac_exec_ext in '' $ac_executable_extensions; do
31642  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31643    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31644    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31645    break 2
31646  fi
31647done
31648  done
31649IFS=$as_save_IFS
31650
31651  ;;
31652esac
31653fi
31654AS=$ac_cv_path_AS
31655if test -n "$AS"; then
31656  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31657$as_echo "$AS" >&6; }
31658else
31659  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31660$as_echo "no" >&6; }
31661fi
31662
31663
31664  test -n "$AS" && break
31665done
31666
31667  else
31668    # The variable is set, but is it from the command line or the environment?
31669
31670    # Try to remove the string !AS! from our list.
31671    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
31672    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
31673      # If it failed, the variable was not from the command line. Ignore it,
31674      # but warn the user (except for BASH, which is always set by the calling BASH).
31675      if test "xAS" != xBASH; then
31676        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
31677$as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
31678      fi
31679      # Try to locate tool using the code snippet
31680      for ac_prog in as
31681do
31682  # Extract the first word of "$ac_prog", so it can be a program name with args.
31683set dummy $ac_prog; ac_word=$2
31684{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31685$as_echo_n "checking for $ac_word... " >&6; }
31686if ${ac_cv_path_AS+:} false; then :
31687  $as_echo_n "(cached) " >&6
31688else
31689  case $AS in
31690  [\\/]* | ?:[\\/]*)
31691  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31692  ;;
31693  *)
31694  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31695for as_dir in $PATH
31696do
31697  IFS=$as_save_IFS
31698  test -z "$as_dir" && as_dir=.
31699    for ac_exec_ext in '' $ac_executable_extensions; do
31700  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31701    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31702    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31703    break 2
31704  fi
31705done
31706  done
31707IFS=$as_save_IFS
31708
31709  ;;
31710esac
31711fi
31712AS=$ac_cv_path_AS
31713if test -n "$AS"; then
31714  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31715$as_echo "$AS" >&6; }
31716else
31717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31718$as_echo "no" >&6; }
31719fi
31720
31721
31722  test -n "$AS" && break
31723done
31724
31725    else
31726      # If it succeeded, then it was overridden by the user. We will use it
31727      # for the tool.
31728
31729      # First remove it from the list of overridden variables, so we can test
31730      # for unknown variables in the end.
31731      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
31732
31733      # Check if the provided tool contains a complete path.
31734      tool_specified="$AS"
31735      tool_basename="${tool_specified##*/}"
31736      if test "x$tool_basename" = "x$tool_specified"; then
31737        # A command without a complete path is provided, search $PATH.
31738        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
31739$as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
31740        # Extract the first word of "$tool_basename", so it can be a program name with args.
31741set dummy $tool_basename; ac_word=$2
31742{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31743$as_echo_n "checking for $ac_word... " >&6; }
31744if ${ac_cv_path_AS+:} false; then :
31745  $as_echo_n "(cached) " >&6
31746else
31747  case $AS in
31748  [\\/]* | ?:[\\/]*)
31749  ac_cv_path_AS="$AS" # Let the user override the test with a path.
31750  ;;
31751  *)
31752  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31753for as_dir in $PATH
31754do
31755  IFS=$as_save_IFS
31756  test -z "$as_dir" && as_dir=.
31757    for ac_exec_ext in '' $ac_executable_extensions; do
31758  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31759    ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
31760    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31761    break 2
31762  fi
31763done
31764  done
31765IFS=$as_save_IFS
31766
31767  ;;
31768esac
31769fi
31770AS=$ac_cv_path_AS
31771if test -n "$AS"; then
31772  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
31773$as_echo "$AS" >&6; }
31774else
31775  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31776$as_echo "no" >&6; }
31777fi
31778
31779
31780        if test "x$AS" = x; then
31781          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
31782        fi
31783      else
31784        # Otherwise we believe it is a complete path. Use it as it is.
31785        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
31786$as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
31787        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
31788$as_echo_n "checking for AS... " >&6; }
31789        if test ! -x "$tool_specified"; then
31790          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
31791$as_echo "not found" >&6; }
31792          as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
31793        fi
31794        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
31795$as_echo "$tool_specified" >&6; }
31796      fi
31797    fi
31798  fi
31799
31800
31801
31802  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31803
31804  # First separate the path from the arguments. This will split at the first
31805  # space.
31806  complete="$AS"
31807  path="${complete%% *}"
31808  tmp="$complete EOL"
31809  arguments="${tmp#* }"
31810
31811  # Input might be given as Windows format, start by converting to
31812  # unix format.
31813  new_path=`$CYGPATH -u "$path"`
31814
31815  # Now try to locate executable using which
31816  new_path=`$WHICH "$new_path" 2> /dev/null`
31817  # bat and cmd files are not always considered executable in cygwin causing which
31818  # to not find them
31819  if test "x$new_path" = x \
31820      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31821      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31822    new_path=`$CYGPATH -u "$path"`
31823  fi
31824  if test "x$new_path" = x; then
31825    # Oops. Which didn't find the executable.
31826    # The splitting of arguments from the executable at a space might have been incorrect,
31827    # since paths with space are more likely in Windows. Give it another try with the whole
31828    # argument.
31829    path="$complete"
31830    arguments="EOL"
31831    new_path=`$CYGPATH -u "$path"`
31832    new_path=`$WHICH "$new_path" 2> /dev/null`
31833    # bat and cmd files are not always considered executable in cygwin causing which
31834    # to not find them
31835    if test "x$new_path" = x \
31836        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31837        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31838      new_path=`$CYGPATH -u "$path"`
31839    fi
31840    if test "x$new_path" = x; then
31841      # It's still not found. Now this is an unrecoverable error.
31842      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31843$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31844      has_space=`$ECHO "$complete" | $GREP " "`
31845      if test "x$has_space" != x; then
31846        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31847$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31848      fi
31849      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31850    fi
31851  fi
31852
31853  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31854  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31855  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31856  # "foo.exe" is OK but "foo" is an error.
31857  #
31858  # This test is therefore slightly more accurate than "test -f" to check for file presence.
31859  # It is also a way to make sure we got the proper file name for the real test later on.
31860  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31861  if test "x$test_shortpath" = x; then
31862    # Short path failed, file does not exist as specified.
31863    # Try adding .exe or .cmd
31864    if test -f "${new_path}.exe"; then
31865      input_to_shortpath="${new_path}.exe"
31866    elif test -f "${new_path}.cmd"; then
31867      input_to_shortpath="${new_path}.cmd"
31868    else
31869      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
31870$as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
31871      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31872$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31873      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31874    fi
31875  else
31876    input_to_shortpath="$new_path"
31877  fi
31878
31879  # Call helper function which possibly converts this using DOS-style short mode.
31880  # If so, the updated path is stored in $new_path.
31881  new_path="$input_to_shortpath"
31882
31883  input_path="$input_to_shortpath"
31884  # Check if we need to convert this using DOS-style short mode. If the path
31885  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31886  # take no chances and rewrite it.
31887  # Note: m4 eats our [], so we need to use [ and ] instead.
31888  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31889  if test "x$has_forbidden_chars" != x; then
31890    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31891    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31892    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31893    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31894      # Going to short mode and back again did indeed matter. Since short mode is
31895      # case insensitive, let's make it lowercase to improve readability.
31896      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31897      # Now convert it back to Unix-stile (cygpath)
31898      input_path=`$CYGPATH -u "$shortmode_path"`
31899      new_path="$input_path"
31900    fi
31901  fi
31902
31903  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31904  if test "x$test_cygdrive_prefix" = x; then
31905    # As a simple fix, exclude /usr/bin since it's not a real path.
31906    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31907      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31908      # a path prefixed by /cygdrive for fixpath to work.
31909      new_path="$CYGWIN_ROOT_PATH$input_path"
31910    fi
31911  fi
31912
31913  # remove trailing .exe if any
31914  new_path="${new_path/%.exe/}"
31915
31916  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31917
31918  # First separate the path from the arguments. This will split at the first
31919  # space.
31920  complete="$AS"
31921  path="${complete%% *}"
31922  tmp="$complete EOL"
31923  arguments="${tmp#* }"
31924
31925  # Input might be given as Windows format, start by converting to
31926  # unix format.
31927  new_path="$path"
31928
31929  windows_path="$new_path"
31930  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31931    unix_path=`$CYGPATH -u "$windows_path"`
31932    new_path="$unix_path"
31933  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31934    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31935    new_path="$unix_path"
31936  fi
31937
31938
31939  # Now try to locate executable using which
31940  new_path=`$WHICH "$new_path" 2> /dev/null`
31941
31942  if test "x$new_path" = x; then
31943    # Oops. Which didn't find the executable.
31944    # The splitting of arguments from the executable at a space might have been incorrect,
31945    # since paths with space are more likely in Windows. Give it another try with the whole
31946    # argument.
31947    path="$complete"
31948    arguments="EOL"
31949    new_path="$path"
31950
31951  windows_path="$new_path"
31952  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31953    unix_path=`$CYGPATH -u "$windows_path"`
31954    new_path="$unix_path"
31955  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31956    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31957    new_path="$unix_path"
31958  fi
31959
31960
31961    new_path=`$WHICH "$new_path" 2> /dev/null`
31962
31963    if test "x$new_path" = x; then
31964      # It's still not found. Now this is an unrecoverable error.
31965      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
31966$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
31967      has_space=`$ECHO "$complete" | $GREP " "`
31968      if test "x$has_space" != x; then
31969        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31970$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31971      fi
31972      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
31973    fi
31974  fi
31975
31976  # Now new_path has a complete unix path to the binary
31977  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31978    # Keep paths in /bin as-is, but remove trailing .exe if any
31979    new_path="${new_path/%.exe/}"
31980    # Do not save /bin paths to all_fixpath_prefixes!
31981  else
31982    # Not in mixed or Windows style, start by that.
31983    new_path=`cmd //c echo $new_path`
31984
31985  input_path="$new_path"
31986  # Check if we need to convert this using DOS-style short mode. If the path
31987  # contains just simple characters, use it. Otherwise (spaces, weird characters),
31988  # take no chances and rewrite it.
31989  # Note: m4 eats our [], so we need to use [ and ] instead.
31990  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31991  if test "x$has_forbidden_chars" != x; then
31992    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31993    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31994  fi
31995
31996    # Output is in $new_path
31997
31998  windows_path="$new_path"
31999  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32000    unix_path=`$CYGPATH -u "$windows_path"`
32001    new_path="$unix_path"
32002  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32003    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32004    new_path="$unix_path"
32005  fi
32006
32007    # remove trailing .exe if any
32008    new_path="${new_path/%.exe/}"
32009
32010    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32011    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32012  fi
32013
32014  else
32015    # We're on a posix platform. Hooray! :)
32016    # First separate the path from the arguments. This will split at the first
32017    # space.
32018    complete="$AS"
32019    path="${complete%% *}"
32020    tmp="$complete EOL"
32021    arguments="${tmp#* }"
32022
32023    # Cannot rely on the command "which" here since it doesn't always work.
32024    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32025    if test -z "$is_absolute_path"; then
32026      # Path to executable is not absolute. Find it.
32027      IFS_save="$IFS"
32028      IFS=:
32029      for p in $PATH; do
32030        if test -f "$p/$path" && test -x "$p/$path"; then
32031          new_path="$p/$path"
32032          break
32033        fi
32034      done
32035      IFS="$IFS_save"
32036    else
32037      # This is an absolute path, we can use it without further modifications.
32038      new_path="$path"
32039    fi
32040
32041    if test "x$new_path" = x; then
32042      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32043$as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32044      has_space=`$ECHO "$complete" | $GREP " "`
32045      if test "x$has_space" != x; then
32046        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32047$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32048      fi
32049      as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32050    fi
32051  fi
32052
32053  # Now join together the path and the arguments once again
32054  if test "x$arguments" != xEOL; then
32055    new_complete="$new_path ${arguments% *}"
32056  else
32057    new_complete="$new_path"
32058  fi
32059
32060  if test "x$complete" != "x$new_complete"; then
32061    AS="$new_complete"
32062    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
32063$as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
32064  fi
32065
32066  else
32067    # FIXME: is this correct for microsoft?
32068    AS="$CC -c"
32069  fi
32070
32071
32072  #
32073  # Setup the archiver (AR)
32074  #
32075  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
32076    # The corresponding ar tool is lib.exe (used to create static libraries)
32077    # Extract the first word of "lib", so it can be a program name with args.
32078set dummy lib; ac_word=$2
32079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32080$as_echo_n "checking for $ac_word... " >&6; }
32081if ${ac_cv_prog_AR+:} false; then :
32082  $as_echo_n "(cached) " >&6
32083else
32084  if test -n "$AR"; then
32085  ac_cv_prog_AR="$AR" # Let the user override the test.
32086else
32087as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32088for as_dir in $PATH
32089do
32090  IFS=$as_save_IFS
32091  test -z "$as_dir" && as_dir=.
32092    for ac_exec_ext in '' $ac_executable_extensions; do
32093  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32094    ac_cv_prog_AR="lib"
32095    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32096    break 2
32097  fi
32098done
32099  done
32100IFS=$as_save_IFS
32101
32102fi
32103fi
32104AR=$ac_cv_prog_AR
32105if test -n "$AR"; then
32106  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32107$as_echo "$AR" >&6; }
32108else
32109  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32110$as_echo "no" >&6; }
32111fi
32112
32113
32114  else
32115
32116
32117  # Publish this variable in the help.
32118
32119
32120  if test "x$AR" = x; then
32121    # The variable is not set by user, try to locate tool using the code snippet
32122    if test -n "$ac_tool_prefix"; then
32123  for ac_prog in ar
32124  do
32125    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32126set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32127{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32128$as_echo_n "checking for $ac_word... " >&6; }
32129if ${ac_cv_prog_AR+:} false; then :
32130  $as_echo_n "(cached) " >&6
32131else
32132  if test -n "$AR"; then
32133  ac_cv_prog_AR="$AR" # Let the user override the test.
32134else
32135as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32136for as_dir in $PATH
32137do
32138  IFS=$as_save_IFS
32139  test -z "$as_dir" && as_dir=.
32140    for ac_exec_ext in '' $ac_executable_extensions; do
32141  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32142    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32143    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32144    break 2
32145  fi
32146done
32147  done
32148IFS=$as_save_IFS
32149
32150fi
32151fi
32152AR=$ac_cv_prog_AR
32153if test -n "$AR"; then
32154  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32155$as_echo "$AR" >&6; }
32156else
32157  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32158$as_echo "no" >&6; }
32159fi
32160
32161
32162    test -n "$AR" && break
32163  done
32164fi
32165if test -z "$AR"; then
32166  ac_ct_AR=$AR
32167  for ac_prog in ar
32168do
32169  # Extract the first word of "$ac_prog", so it can be a program name with args.
32170set dummy $ac_prog; ac_word=$2
32171{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32172$as_echo_n "checking for $ac_word... " >&6; }
32173if ${ac_cv_prog_ac_ct_AR+:} false; then :
32174  $as_echo_n "(cached) " >&6
32175else
32176  if test -n "$ac_ct_AR"; then
32177  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32178else
32179as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32180for as_dir in $PATH
32181do
32182  IFS=$as_save_IFS
32183  test -z "$as_dir" && as_dir=.
32184    for ac_exec_ext in '' $ac_executable_extensions; do
32185  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32186    ac_cv_prog_ac_ct_AR="$ac_prog"
32187    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32188    break 2
32189  fi
32190done
32191  done
32192IFS=$as_save_IFS
32193
32194fi
32195fi
32196ac_ct_AR=$ac_cv_prog_ac_ct_AR
32197if test -n "$ac_ct_AR"; then
32198  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32199$as_echo "$ac_ct_AR" >&6; }
32200else
32201  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32202$as_echo "no" >&6; }
32203fi
32204
32205
32206  test -n "$ac_ct_AR" && break
32207done
32208
32209  if test "x$ac_ct_AR" = x; then
32210    AR=""
32211  else
32212    case $cross_compiling:$ac_tool_warned in
32213yes:)
32214{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32215$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32216ac_tool_warned=yes ;;
32217esac
32218    AR=$ac_ct_AR
32219  fi
32220fi
32221
32222  else
32223    # The variable is set, but is it from the command line or the environment?
32224
32225    # Try to remove the string !AR! from our list.
32226    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32227    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32228      # If it failed, the variable was not from the command line. Ignore it,
32229      # but warn the user (except for BASH, which is always set by the calling BASH).
32230      if test "xAR" != xBASH; then
32231        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32232$as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32233      fi
32234      # Try to locate tool using the code snippet
32235      if test -n "$ac_tool_prefix"; then
32236  for ac_prog in ar
32237  do
32238    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32239set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32240{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32241$as_echo_n "checking for $ac_word... " >&6; }
32242if ${ac_cv_prog_AR+:} false; then :
32243  $as_echo_n "(cached) " >&6
32244else
32245  if test -n "$AR"; then
32246  ac_cv_prog_AR="$AR" # Let the user override the test.
32247else
32248as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32249for as_dir in $PATH
32250do
32251  IFS=$as_save_IFS
32252  test -z "$as_dir" && as_dir=.
32253    for ac_exec_ext in '' $ac_executable_extensions; do
32254  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32255    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32256    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32257    break 2
32258  fi
32259done
32260  done
32261IFS=$as_save_IFS
32262
32263fi
32264fi
32265AR=$ac_cv_prog_AR
32266if test -n "$AR"; then
32267  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32268$as_echo "$AR" >&6; }
32269else
32270  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32271$as_echo "no" >&6; }
32272fi
32273
32274
32275    test -n "$AR" && break
32276  done
32277fi
32278if test -z "$AR"; then
32279  ac_ct_AR=$AR
32280  for ac_prog in ar
32281do
32282  # Extract the first word of "$ac_prog", so it can be a program name with args.
32283set dummy $ac_prog; ac_word=$2
32284{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32285$as_echo_n "checking for $ac_word... " >&6; }
32286if ${ac_cv_prog_ac_ct_AR+:} false; then :
32287  $as_echo_n "(cached) " >&6
32288else
32289  if test -n "$ac_ct_AR"; then
32290  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32291else
32292as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32293for as_dir in $PATH
32294do
32295  IFS=$as_save_IFS
32296  test -z "$as_dir" && as_dir=.
32297    for ac_exec_ext in '' $ac_executable_extensions; do
32298  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32299    ac_cv_prog_ac_ct_AR="$ac_prog"
32300    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32301    break 2
32302  fi
32303done
32304  done
32305IFS=$as_save_IFS
32306
32307fi
32308fi
32309ac_ct_AR=$ac_cv_prog_ac_ct_AR
32310if test -n "$ac_ct_AR"; then
32311  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32312$as_echo "$ac_ct_AR" >&6; }
32313else
32314  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32315$as_echo "no" >&6; }
32316fi
32317
32318
32319  test -n "$ac_ct_AR" && break
32320done
32321
32322  if test "x$ac_ct_AR" = x; then
32323    AR=""
32324  else
32325    case $cross_compiling:$ac_tool_warned in
32326yes:)
32327{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32328$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32329ac_tool_warned=yes ;;
32330esac
32331    AR=$ac_ct_AR
32332  fi
32333fi
32334
32335    else
32336      # If it succeeded, then it was overridden by the user. We will use it
32337      # for the tool.
32338
32339      # First remove it from the list of overridden variables, so we can test
32340      # for unknown variables in the end.
32341      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32342
32343      # Check if the provided tool contains a complete path.
32344      tool_specified="$AR"
32345      tool_basename="${tool_specified##*/}"
32346      if test "x$tool_basename" = "x$tool_specified"; then
32347        # A command without a complete path is provided, search $PATH.
32348        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
32349$as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
32350        # Extract the first word of "$tool_basename", so it can be a program name with args.
32351set dummy $tool_basename; ac_word=$2
32352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32353$as_echo_n "checking for $ac_word... " >&6; }
32354if ${ac_cv_path_AR+:} false; then :
32355  $as_echo_n "(cached) " >&6
32356else
32357  case $AR in
32358  [\\/]* | ?:[\\/]*)
32359  ac_cv_path_AR="$AR" # Let the user override the test with a path.
32360  ;;
32361  *)
32362  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32363for as_dir in $PATH
32364do
32365  IFS=$as_save_IFS
32366  test -z "$as_dir" && as_dir=.
32367    for ac_exec_ext in '' $ac_executable_extensions; do
32368  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32369    ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
32370    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32371    break 2
32372  fi
32373done
32374  done
32375IFS=$as_save_IFS
32376
32377  ;;
32378esac
32379fi
32380AR=$ac_cv_path_AR
32381if test -n "$AR"; then
32382  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32383$as_echo "$AR" >&6; }
32384else
32385  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32386$as_echo "no" >&6; }
32387fi
32388
32389
32390        if test "x$AR" = x; then
32391          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32392        fi
32393      else
32394        # Otherwise we believe it is a complete path. Use it as it is.
32395        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
32396$as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
32397        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
32398$as_echo_n "checking for AR... " >&6; }
32399        if test ! -x "$tool_specified"; then
32400          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32401$as_echo "not found" >&6; }
32402          as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
32403        fi
32404        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32405$as_echo "$tool_specified" >&6; }
32406      fi
32407    fi
32408  fi
32409
32410
32411  fi
32412
32413  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32414
32415  # First separate the path from the arguments. This will split at the first
32416  # space.
32417  complete="$AR"
32418  path="${complete%% *}"
32419  tmp="$complete EOL"
32420  arguments="${tmp#* }"
32421
32422  # Input might be given as Windows format, start by converting to
32423  # unix format.
32424  new_path=`$CYGPATH -u "$path"`
32425
32426  # Now try to locate executable using which
32427  new_path=`$WHICH "$new_path" 2> /dev/null`
32428  # bat and cmd files are not always considered executable in cygwin causing which
32429  # to not find them
32430  if test "x$new_path" = x \
32431      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32432      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32433    new_path=`$CYGPATH -u "$path"`
32434  fi
32435  if test "x$new_path" = x; then
32436    # Oops. Which didn't find the executable.
32437    # The splitting of arguments from the executable at a space might have been incorrect,
32438    # since paths with space are more likely in Windows. Give it another try with the whole
32439    # argument.
32440    path="$complete"
32441    arguments="EOL"
32442    new_path=`$CYGPATH -u "$path"`
32443    new_path=`$WHICH "$new_path" 2> /dev/null`
32444    # bat and cmd files are not always considered executable in cygwin causing which
32445    # to not find them
32446    if test "x$new_path" = x \
32447        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32448        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32449      new_path=`$CYGPATH -u "$path"`
32450    fi
32451    if test "x$new_path" = x; then
32452      # It's still not found. Now this is an unrecoverable error.
32453      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32454$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32455      has_space=`$ECHO "$complete" | $GREP " "`
32456      if test "x$has_space" != x; then
32457        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32458$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32459      fi
32460      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32461    fi
32462  fi
32463
32464  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32465  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32466  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32467  # "foo.exe" is OK but "foo" is an error.
32468  #
32469  # This test is therefore slightly more accurate than "test -f" to check for file presence.
32470  # It is also a way to make sure we got the proper file name for the real test later on.
32471  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32472  if test "x$test_shortpath" = x; then
32473    # Short path failed, file does not exist as specified.
32474    # Try adding .exe or .cmd
32475    if test -f "${new_path}.exe"; then
32476      input_to_shortpath="${new_path}.exe"
32477    elif test -f "${new_path}.cmd"; then
32478      input_to_shortpath="${new_path}.cmd"
32479    else
32480      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
32481$as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
32482      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32483$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32484      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32485    fi
32486  else
32487    input_to_shortpath="$new_path"
32488  fi
32489
32490  # Call helper function which possibly converts this using DOS-style short mode.
32491  # If so, the updated path is stored in $new_path.
32492  new_path="$input_to_shortpath"
32493
32494  input_path="$input_to_shortpath"
32495  # Check if we need to convert this using DOS-style short mode. If the path
32496  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32497  # take no chances and rewrite it.
32498  # Note: m4 eats our [], so we need to use [ and ] instead.
32499  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32500  if test "x$has_forbidden_chars" != x; then
32501    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32502    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32503    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32504    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32505      # Going to short mode and back again did indeed matter. Since short mode is
32506      # case insensitive, let's make it lowercase to improve readability.
32507      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32508      # Now convert it back to Unix-stile (cygpath)
32509      input_path=`$CYGPATH -u "$shortmode_path"`
32510      new_path="$input_path"
32511    fi
32512  fi
32513
32514  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32515  if test "x$test_cygdrive_prefix" = x; then
32516    # As a simple fix, exclude /usr/bin since it's not a real path.
32517    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32518      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32519      # a path prefixed by /cygdrive for fixpath to work.
32520      new_path="$CYGWIN_ROOT_PATH$input_path"
32521    fi
32522  fi
32523
32524  # remove trailing .exe if any
32525  new_path="${new_path/%.exe/}"
32526
32527  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32528
32529  # First separate the path from the arguments. This will split at the first
32530  # space.
32531  complete="$AR"
32532  path="${complete%% *}"
32533  tmp="$complete EOL"
32534  arguments="${tmp#* }"
32535
32536  # Input might be given as Windows format, start by converting to
32537  # unix format.
32538  new_path="$path"
32539
32540  windows_path="$new_path"
32541  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32542    unix_path=`$CYGPATH -u "$windows_path"`
32543    new_path="$unix_path"
32544  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32545    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32546    new_path="$unix_path"
32547  fi
32548
32549
32550  # Now try to locate executable using which
32551  new_path=`$WHICH "$new_path" 2> /dev/null`
32552
32553  if test "x$new_path" = x; then
32554    # Oops. Which didn't find the executable.
32555    # The splitting of arguments from the executable at a space might have been incorrect,
32556    # since paths with space are more likely in Windows. Give it another try with the whole
32557    # argument.
32558    path="$complete"
32559    arguments="EOL"
32560    new_path="$path"
32561
32562  windows_path="$new_path"
32563  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32564    unix_path=`$CYGPATH -u "$windows_path"`
32565    new_path="$unix_path"
32566  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32567    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32568    new_path="$unix_path"
32569  fi
32570
32571
32572    new_path=`$WHICH "$new_path" 2> /dev/null`
32573
32574    if test "x$new_path" = x; then
32575      # It's still not found. Now this is an unrecoverable error.
32576      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32577$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32578      has_space=`$ECHO "$complete" | $GREP " "`
32579      if test "x$has_space" != x; then
32580        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32581$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32582      fi
32583      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32584    fi
32585  fi
32586
32587  # Now new_path has a complete unix path to the binary
32588  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32589    # Keep paths in /bin as-is, but remove trailing .exe if any
32590    new_path="${new_path/%.exe/}"
32591    # Do not save /bin paths to all_fixpath_prefixes!
32592  else
32593    # Not in mixed or Windows style, start by that.
32594    new_path=`cmd //c echo $new_path`
32595
32596  input_path="$new_path"
32597  # Check if we need to convert this using DOS-style short mode. If the path
32598  # contains just simple characters, use it. Otherwise (spaces, weird characters),
32599  # take no chances and rewrite it.
32600  # Note: m4 eats our [], so we need to use [ and ] instead.
32601  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32602  if test "x$has_forbidden_chars" != x; then
32603    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32604    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32605  fi
32606
32607    # Output is in $new_path
32608
32609  windows_path="$new_path"
32610  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32611    unix_path=`$CYGPATH -u "$windows_path"`
32612    new_path="$unix_path"
32613  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32614    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32615    new_path="$unix_path"
32616  fi
32617
32618    # remove trailing .exe if any
32619    new_path="${new_path/%.exe/}"
32620
32621    # Save the first 10 bytes of this path to the storage, so fixpath can work.
32622    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32623  fi
32624
32625  else
32626    # We're on a posix platform. Hooray! :)
32627    # First separate the path from the arguments. This will split at the first
32628    # space.
32629    complete="$AR"
32630    path="${complete%% *}"
32631    tmp="$complete EOL"
32632    arguments="${tmp#* }"
32633
32634    # Cannot rely on the command "which" here since it doesn't always work.
32635    is_absolute_path=`$ECHO "$path" | $GREP ^/`
32636    if test -z "$is_absolute_path"; then
32637      # Path to executable is not absolute. Find it.
32638      IFS_save="$IFS"
32639      IFS=:
32640      for p in $PATH; do
32641        if test -f "$p/$path" && test -x "$p/$path"; then
32642          new_path="$p/$path"
32643          break
32644        fi
32645      done
32646      IFS="$IFS_save"
32647    else
32648      # This is an absolute path, we can use it without further modifications.
32649      new_path="$path"
32650    fi
32651
32652    if test "x$new_path" = x; then
32653      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32654$as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32655      has_space=`$ECHO "$complete" | $GREP " "`
32656      if test "x$has_space" != x; then
32657        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32658$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32659      fi
32660      as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32661    fi
32662  fi
32663
32664  # Now join together the path and the arguments once again
32665  if test "x$arguments" != xEOL; then
32666    new_complete="$new_path ${arguments% *}"
32667  else
32668    new_complete="$new_path"
32669  fi
32670
32671  if test "x$complete" != "x$new_complete"; then
32672    AR="$new_complete"
32673    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
32674$as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
32675  fi
32676
32677
32678
32679  if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
32680    ac_ext=m
32681ac_cpp='$OBJCPP $CPPFLAGS'
32682ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32683ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32684ac_compiler_gnu=$ac_cv_objc_compiler_gnu
32685if test -n "$ac_tool_prefix"; then
32686  for ac_prog in gcc objcc objc cc CC
32687  do
32688    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32689set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32690{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32691$as_echo_n "checking for $ac_word... " >&6; }
32692if ${ac_cv_prog_OBJC+:} false; then :
32693  $as_echo_n "(cached) " >&6
32694else
32695  if test -n "$OBJC"; then
32696  ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
32697else
32698as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32699for as_dir in $PATH
32700do
32701  IFS=$as_save_IFS
32702  test -z "$as_dir" && as_dir=.
32703    for ac_exec_ext in '' $ac_executable_extensions; do
32704  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32705    ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
32706    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32707    break 2
32708  fi
32709done
32710  done
32711IFS=$as_save_IFS
32712
32713fi
32714fi
32715OBJC=$ac_cv_prog_OBJC
32716if test -n "$OBJC"; then
32717  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
32718$as_echo "$OBJC" >&6; }
32719else
32720  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32721$as_echo "no" >&6; }
32722fi
32723
32724
32725    test -n "$OBJC" && break
32726  done
32727fi
32728if test -z "$OBJC"; then
32729  ac_ct_OBJC=$OBJC
32730  for ac_prog in gcc objcc objc cc CC
32731do
32732  # Extract the first word of "$ac_prog", so it can be a program name with args.
32733set dummy $ac_prog; ac_word=$2
32734{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32735$as_echo_n "checking for $ac_word... " >&6; }
32736if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
32737  $as_echo_n "(cached) " >&6
32738else
32739  if test -n "$ac_ct_OBJC"; then
32740  ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
32741else
32742as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32743for as_dir in $PATH
32744do
32745  IFS=$as_save_IFS
32746  test -z "$as_dir" && as_dir=.
32747    for ac_exec_ext in '' $ac_executable_extensions; do
32748  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32749    ac_cv_prog_ac_ct_OBJC="$ac_prog"
32750    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32751    break 2
32752  fi
32753done
32754  done
32755IFS=$as_save_IFS
32756
32757fi
32758fi
32759ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
32760if test -n "$ac_ct_OBJC"; then
32761  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
32762$as_echo "$ac_ct_OBJC" >&6; }
32763else
32764  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32765$as_echo "no" >&6; }
32766fi
32767
32768
32769  test -n "$ac_ct_OBJC" && break
32770done
32771
32772  if test "x$ac_ct_OBJC" = x; then
32773    OBJC="gcc"
32774  else
32775    case $cross_compiling:$ac_tool_warned in
32776yes:)
32777{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32778$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32779ac_tool_warned=yes ;;
32780esac
32781    OBJC=$ac_ct_OBJC
32782  fi
32783fi
32784
32785# Provide some information about the compiler.
32786$as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
32787set X $ac_compile
32788ac_compiler=$2
32789for ac_option in --version -v -V -qversion; do
32790  { { ac_try="$ac_compiler $ac_option >&5"
32791case "(($ac_try" in
32792  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32793  *) ac_try_echo=$ac_try;;
32794esac
32795eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32796$as_echo "$ac_try_echo"; } >&5
32797  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32798  ac_status=$?
32799  if test -s conftest.err; then
32800    sed '10a\
32801... rest of stderr output deleted ...
32802         10q' conftest.err >conftest.er1
32803    cat conftest.er1 >&5
32804  fi
32805  rm -f conftest.er1 conftest.err
32806  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32807  test $ac_status = 0; }
32808done
32809
32810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
32811$as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
32812if ${ac_cv_objc_compiler_gnu+:} false; then :
32813  $as_echo_n "(cached) " >&6
32814else
32815  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32816/* end confdefs.h.  */
32817
32818int
32819main ()
32820{
32821#ifndef __GNUC__
32822       choke me
32823#endif
32824
32825  ;
32826  return 0;
32827}
32828_ACEOF
32829if ac_fn_objc_try_compile "$LINENO"; then :
32830  ac_compiler_gnu=yes
32831else
32832  ac_compiler_gnu=no
32833fi
32834rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32835ac_cv_objc_compiler_gnu=$ac_compiler_gnu
32836
32837fi
32838{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
32839$as_echo "$ac_cv_objc_compiler_gnu" >&6; }
32840if test $ac_compiler_gnu = yes; then
32841  GOBJC=yes
32842else
32843  GOBJC=
32844fi
32845ac_test_OBJCFLAGS=${OBJCFLAGS+set}
32846ac_save_OBJCFLAGS=$OBJCFLAGS
32847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
32848$as_echo_n "checking whether $OBJC accepts -g... " >&6; }
32849if ${ac_cv_prog_objc_g+:} false; then :
32850  $as_echo_n "(cached) " >&6
32851else
32852  ac_save_objc_werror_flag=$ac_objc_werror_flag
32853   ac_objc_werror_flag=yes
32854   ac_cv_prog_objc_g=no
32855   OBJCFLAGS="-g"
32856   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32857/* end confdefs.h.  */
32858
32859int
32860main ()
32861{
32862
32863  ;
32864  return 0;
32865}
32866_ACEOF
32867if ac_fn_objc_try_compile "$LINENO"; then :
32868  ac_cv_prog_objc_g=yes
32869else
32870  OBJCFLAGS=""
32871      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32872/* end confdefs.h.  */
32873
32874int
32875main ()
32876{
32877
32878  ;
32879  return 0;
32880}
32881_ACEOF
32882if ac_fn_objc_try_compile "$LINENO"; then :
32883
32884else
32885  ac_objc_werror_flag=$ac_save_objc_werror_flag
32886	 OBJCFLAGS="-g"
32887	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32888/* end confdefs.h.  */
32889
32890int
32891main ()
32892{
32893
32894  ;
32895  return 0;
32896}
32897_ACEOF
32898if ac_fn_objc_try_compile "$LINENO"; then :
32899  ac_cv_prog_objc_g=yes
32900fi
32901rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32902fi
32903rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32904fi
32905rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32906   ac_objc_werror_flag=$ac_save_objc_werror_flag
32907fi
32908{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
32909$as_echo "$ac_cv_prog_objc_g" >&6; }
32910if test "$ac_test_OBJCFLAGS" = set; then
32911  OBJCFLAGS=$ac_save_OBJCFLAGS
32912elif test $ac_cv_prog_objc_g = yes; then
32913  if test "$GOBJC" = yes; then
32914    OBJCFLAGS="-g -O2"
32915  else
32916    OBJCFLAGS="-g"
32917  fi
32918else
32919  if test "$GOBJC" = yes; then
32920    OBJCFLAGS="-O2"
32921  else
32922    OBJCFLAGS=
32923  fi
32924fi
32925ac_ext=cpp
32926ac_cpp='$CXXCPP $CPPFLAGS'
32927ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32928ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32929ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32930
32931
32932  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32933
32934  # First separate the path from the arguments. This will split at the first
32935  # space.
32936  complete="$OBJC"
32937  path="${complete%% *}"
32938  tmp="$complete EOL"
32939  arguments="${tmp#* }"
32940
32941  # Input might be given as Windows format, start by converting to
32942  # unix format.
32943  new_path=`$CYGPATH -u "$path"`
32944
32945  # Now try to locate executable using which
32946  new_path=`$WHICH "$new_path" 2> /dev/null`
32947  # bat and cmd files are not always considered executable in cygwin causing which
32948  # to not find them
32949  if test "x$new_path" = x \
32950      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32951      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32952    new_path=`$CYGPATH -u "$path"`
32953  fi
32954  if test "x$new_path" = x; then
32955    # Oops. Which didn't find the executable.
32956    # The splitting of arguments from the executable at a space might have been incorrect,
32957    # since paths with space are more likely in Windows. Give it another try with the whole
32958    # argument.
32959    path="$complete"
32960    arguments="EOL"
32961    new_path=`$CYGPATH -u "$path"`
32962    new_path=`$WHICH "$new_path" 2> /dev/null`
32963    # bat and cmd files are not always considered executable in cygwin causing which
32964    # to not find them
32965    if test "x$new_path" = x \
32966        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32967        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32968      new_path=`$CYGPATH -u "$path"`
32969    fi
32970    if test "x$new_path" = x; then
32971      # It's still not found. Now this is an unrecoverable error.
32972      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32973$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32974      has_space=`$ECHO "$complete" | $GREP " "`
32975      if test "x$has_space" != x; then
32976        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32977$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32978      fi
32979      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32980    fi
32981  fi
32982
32983  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32984  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32985  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32986  # "foo.exe" is OK but "foo" is an error.
32987  #
32988  # This test is therefore slightly more accurate than "test -f" to check for file presence.
32989  # It is also a way to make sure we got the proper file name for the real test later on.
32990  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32991  if test "x$test_shortpath" = x; then
32992    # Short path failed, file does not exist as specified.
32993    # Try adding .exe or .cmd
32994    if test -f "${new_path}.exe"; then
32995      input_to_shortpath="${new_path}.exe"
32996    elif test -f "${new_path}.cmd"; then
32997      input_to_shortpath="${new_path}.cmd"
32998    else
32999      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
33000$as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
33001      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33002$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33003      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33004    fi
33005  else
33006    input_to_shortpath="$new_path"
33007  fi
33008
33009  # Call helper function which possibly converts this using DOS-style short mode.
33010  # If so, the updated path is stored in $new_path.
33011  new_path="$input_to_shortpath"
33012
33013  input_path="$input_to_shortpath"
33014  # Check if we need to convert this using DOS-style short mode. If the path
33015  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33016  # take no chances and rewrite it.
33017  # Note: m4 eats our [], so we need to use [ and ] instead.
33018  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33019  if test "x$has_forbidden_chars" != x; then
33020    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33021    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33022    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33023    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33024      # Going to short mode and back again did indeed matter. Since short mode is
33025      # case insensitive, let's make it lowercase to improve readability.
33026      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33027      # Now convert it back to Unix-stile (cygpath)
33028      input_path=`$CYGPATH -u "$shortmode_path"`
33029      new_path="$input_path"
33030    fi
33031  fi
33032
33033  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33034  if test "x$test_cygdrive_prefix" = x; then
33035    # As a simple fix, exclude /usr/bin since it's not a real path.
33036    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33037      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33038      # a path prefixed by /cygdrive for fixpath to work.
33039      new_path="$CYGWIN_ROOT_PATH$input_path"
33040    fi
33041  fi
33042
33043  # remove trailing .exe if any
33044  new_path="${new_path/%.exe/}"
33045
33046  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33047
33048  # First separate the path from the arguments. This will split at the first
33049  # space.
33050  complete="$OBJC"
33051  path="${complete%% *}"
33052  tmp="$complete EOL"
33053  arguments="${tmp#* }"
33054
33055  # Input might be given as Windows format, start by converting to
33056  # unix format.
33057  new_path="$path"
33058
33059  windows_path="$new_path"
33060  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33061    unix_path=`$CYGPATH -u "$windows_path"`
33062    new_path="$unix_path"
33063  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33064    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33065    new_path="$unix_path"
33066  fi
33067
33068
33069  # Now try to locate executable using which
33070  new_path=`$WHICH "$new_path" 2> /dev/null`
33071
33072  if test "x$new_path" = x; then
33073    # Oops. Which didn't find the executable.
33074    # The splitting of arguments from the executable at a space might have been incorrect,
33075    # since paths with space are more likely in Windows. Give it another try with the whole
33076    # argument.
33077    path="$complete"
33078    arguments="EOL"
33079    new_path="$path"
33080
33081  windows_path="$new_path"
33082  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33083    unix_path=`$CYGPATH -u "$windows_path"`
33084    new_path="$unix_path"
33085  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33086    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33087    new_path="$unix_path"
33088  fi
33089
33090
33091    new_path=`$WHICH "$new_path" 2> /dev/null`
33092
33093    if test "x$new_path" = x; then
33094      # It's still not found. Now this is an unrecoverable error.
33095      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33096$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33097      has_space=`$ECHO "$complete" | $GREP " "`
33098      if test "x$has_space" != x; then
33099        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33100$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33101      fi
33102      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33103    fi
33104  fi
33105
33106  # Now new_path has a complete unix path to the binary
33107  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33108    # Keep paths in /bin as-is, but remove trailing .exe if any
33109    new_path="${new_path/%.exe/}"
33110    # Do not save /bin paths to all_fixpath_prefixes!
33111  else
33112    # Not in mixed or Windows style, start by that.
33113    new_path=`cmd //c echo $new_path`
33114
33115  input_path="$new_path"
33116  # Check if we need to convert this using DOS-style short mode. If the path
33117  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33118  # take no chances and rewrite it.
33119  # Note: m4 eats our [], so we need to use [ and ] instead.
33120  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33121  if test "x$has_forbidden_chars" != x; then
33122    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33123    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33124  fi
33125
33126    # Output is in $new_path
33127
33128  windows_path="$new_path"
33129  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33130    unix_path=`$CYGPATH -u "$windows_path"`
33131    new_path="$unix_path"
33132  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33133    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33134    new_path="$unix_path"
33135  fi
33136
33137    # remove trailing .exe if any
33138    new_path="${new_path/%.exe/}"
33139
33140    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33141    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33142  fi
33143
33144  else
33145    # We're on a posix platform. Hooray! :)
33146    # First separate the path from the arguments. This will split at the first
33147    # space.
33148    complete="$OBJC"
33149    path="${complete%% *}"
33150    tmp="$complete EOL"
33151    arguments="${tmp#* }"
33152
33153    # Cannot rely on the command "which" here since it doesn't always work.
33154    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33155    if test -z "$is_absolute_path"; then
33156      # Path to executable is not absolute. Find it.
33157      IFS_save="$IFS"
33158      IFS=:
33159      for p in $PATH; do
33160        if test -f "$p/$path" && test -x "$p/$path"; then
33161          new_path="$p/$path"
33162          break
33163        fi
33164      done
33165      IFS="$IFS_save"
33166    else
33167      # This is an absolute path, we can use it without further modifications.
33168      new_path="$path"
33169    fi
33170
33171    if test "x$new_path" = x; then
33172      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33173$as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33174      has_space=`$ECHO "$complete" | $GREP " "`
33175      if test "x$has_space" != x; then
33176        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33177$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33178      fi
33179      as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33180    fi
33181  fi
33182
33183  # Now join together the path and the arguments once again
33184  if test "x$arguments" != xEOL; then
33185    new_complete="$new_path ${arguments% *}"
33186  else
33187    new_complete="$new_path"
33188  fi
33189
33190  if test "x$complete" != "x$new_complete"; then
33191    OBJC="$new_complete"
33192    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
33193$as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
33194  fi
33195
33196
33197
33198  # Publish this variable in the help.
33199
33200
33201  if test "x$LIPO" = x; then
33202    # The variable is not set by user, try to locate tool using the code snippet
33203    for ac_prog in lipo
33204do
33205  # Extract the first word of "$ac_prog", so it can be a program name with args.
33206set dummy $ac_prog; ac_word=$2
33207{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33208$as_echo_n "checking for $ac_word... " >&6; }
33209if ${ac_cv_path_LIPO+:} false; then :
33210  $as_echo_n "(cached) " >&6
33211else
33212  case $LIPO in
33213  [\\/]* | ?:[\\/]*)
33214  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33215  ;;
33216  *)
33217  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33218for as_dir in $PATH
33219do
33220  IFS=$as_save_IFS
33221  test -z "$as_dir" && as_dir=.
33222    for ac_exec_ext in '' $ac_executable_extensions; do
33223  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33224    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33225    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33226    break 2
33227  fi
33228done
33229  done
33230IFS=$as_save_IFS
33231
33232  ;;
33233esac
33234fi
33235LIPO=$ac_cv_path_LIPO
33236if test -n "$LIPO"; then
33237  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33238$as_echo "$LIPO" >&6; }
33239else
33240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33241$as_echo "no" >&6; }
33242fi
33243
33244
33245  test -n "$LIPO" && break
33246done
33247
33248  else
33249    # The variable is set, but is it from the command line or the environment?
33250
33251    # Try to remove the string !LIPO! from our list.
33252    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
33253    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
33254      # If it failed, the variable was not from the command line. Ignore it,
33255      # but warn the user (except for BASH, which is always set by the calling BASH).
33256      if test "xLIPO" != xBASH; then
33257        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
33258$as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
33259      fi
33260      # Try to locate tool using the code snippet
33261      for ac_prog in lipo
33262do
33263  # Extract the first word of "$ac_prog", so it can be a program name with args.
33264set dummy $ac_prog; ac_word=$2
33265{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33266$as_echo_n "checking for $ac_word... " >&6; }
33267if ${ac_cv_path_LIPO+:} false; then :
33268  $as_echo_n "(cached) " >&6
33269else
33270  case $LIPO in
33271  [\\/]* | ?:[\\/]*)
33272  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33273  ;;
33274  *)
33275  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33276for as_dir in $PATH
33277do
33278  IFS=$as_save_IFS
33279  test -z "$as_dir" && as_dir=.
33280    for ac_exec_ext in '' $ac_executable_extensions; do
33281  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33282    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33283    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33284    break 2
33285  fi
33286done
33287  done
33288IFS=$as_save_IFS
33289
33290  ;;
33291esac
33292fi
33293LIPO=$ac_cv_path_LIPO
33294if test -n "$LIPO"; then
33295  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33296$as_echo "$LIPO" >&6; }
33297else
33298  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33299$as_echo "no" >&6; }
33300fi
33301
33302
33303  test -n "$LIPO" && break
33304done
33305
33306    else
33307      # If it succeeded, then it was overridden by the user. We will use it
33308      # for the tool.
33309
33310      # First remove it from the list of overridden variables, so we can test
33311      # for unknown variables in the end.
33312      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33313
33314      # Check if the provided tool contains a complete path.
33315      tool_specified="$LIPO"
33316      tool_basename="${tool_specified##*/}"
33317      if test "x$tool_basename" = "x$tool_specified"; then
33318        # A command without a complete path is provided, search $PATH.
33319        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
33320$as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
33321        # Extract the first word of "$tool_basename", so it can be a program name with args.
33322set dummy $tool_basename; ac_word=$2
33323{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33324$as_echo_n "checking for $ac_word... " >&6; }
33325if ${ac_cv_path_LIPO+:} false; then :
33326  $as_echo_n "(cached) " >&6
33327else
33328  case $LIPO in
33329  [\\/]* | ?:[\\/]*)
33330  ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33331  ;;
33332  *)
33333  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33334for as_dir in $PATH
33335do
33336  IFS=$as_save_IFS
33337  test -z "$as_dir" && as_dir=.
33338    for ac_exec_ext in '' $ac_executable_extensions; do
33339  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33340    ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33341    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33342    break 2
33343  fi
33344done
33345  done
33346IFS=$as_save_IFS
33347
33348  ;;
33349esac
33350fi
33351LIPO=$ac_cv_path_LIPO
33352if test -n "$LIPO"; then
33353  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33354$as_echo "$LIPO" >&6; }
33355else
33356  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33357$as_echo "no" >&6; }
33358fi
33359
33360
33361        if test "x$LIPO" = x; then
33362          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33363        fi
33364      else
33365        # Otherwise we believe it is a complete path. Use it as it is.
33366        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
33367$as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
33368        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
33369$as_echo_n "checking for LIPO... " >&6; }
33370        if test ! -x "$tool_specified"; then
33371          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33372$as_echo "not found" >&6; }
33373          as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
33374        fi
33375        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33376$as_echo "$tool_specified" >&6; }
33377      fi
33378    fi
33379  fi
33380
33381
33382
33383  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33384
33385  # First separate the path from the arguments. This will split at the first
33386  # space.
33387  complete="$LIPO"
33388  path="${complete%% *}"
33389  tmp="$complete EOL"
33390  arguments="${tmp#* }"
33391
33392  # Input might be given as Windows format, start by converting to
33393  # unix format.
33394  new_path=`$CYGPATH -u "$path"`
33395
33396  # Now try to locate executable using which
33397  new_path=`$WHICH "$new_path" 2> /dev/null`
33398  # bat and cmd files are not always considered executable in cygwin causing which
33399  # to not find them
33400  if test "x$new_path" = x \
33401      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33402      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33403    new_path=`$CYGPATH -u "$path"`
33404  fi
33405  if test "x$new_path" = x; then
33406    # Oops. Which didn't find the executable.
33407    # The splitting of arguments from the executable at a space might have been incorrect,
33408    # since paths with space are more likely in Windows. Give it another try with the whole
33409    # argument.
33410    path="$complete"
33411    arguments="EOL"
33412    new_path=`$CYGPATH -u "$path"`
33413    new_path=`$WHICH "$new_path" 2> /dev/null`
33414    # bat and cmd files are not always considered executable in cygwin causing which
33415    # to not find them
33416    if test "x$new_path" = x \
33417        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33418        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33419      new_path=`$CYGPATH -u "$path"`
33420    fi
33421    if test "x$new_path" = x; then
33422      # It's still not found. Now this is an unrecoverable error.
33423      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33424$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33425      has_space=`$ECHO "$complete" | $GREP " "`
33426      if test "x$has_space" != x; then
33427        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33428$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33429      fi
33430      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33431    fi
33432  fi
33433
33434  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33435  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33436  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33437  # "foo.exe" is OK but "foo" is an error.
33438  #
33439  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33440  # It is also a way to make sure we got the proper file name for the real test later on.
33441  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33442  if test "x$test_shortpath" = x; then
33443    # Short path failed, file does not exist as specified.
33444    # Try adding .exe or .cmd
33445    if test -f "${new_path}.exe"; then
33446      input_to_shortpath="${new_path}.exe"
33447    elif test -f "${new_path}.cmd"; then
33448      input_to_shortpath="${new_path}.cmd"
33449    else
33450      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
33451$as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
33452      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33453$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33454      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33455    fi
33456  else
33457    input_to_shortpath="$new_path"
33458  fi
33459
33460  # Call helper function which possibly converts this using DOS-style short mode.
33461  # If so, the updated path is stored in $new_path.
33462  new_path="$input_to_shortpath"
33463
33464  input_path="$input_to_shortpath"
33465  # Check if we need to convert this using DOS-style short mode. If the path
33466  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33467  # take no chances and rewrite it.
33468  # Note: m4 eats our [], so we need to use [ and ] instead.
33469  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33470  if test "x$has_forbidden_chars" != x; then
33471    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33472    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33473    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33474    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33475      # Going to short mode and back again did indeed matter. Since short mode is
33476      # case insensitive, let's make it lowercase to improve readability.
33477      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33478      # Now convert it back to Unix-stile (cygpath)
33479      input_path=`$CYGPATH -u "$shortmode_path"`
33480      new_path="$input_path"
33481    fi
33482  fi
33483
33484  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33485  if test "x$test_cygdrive_prefix" = x; then
33486    # As a simple fix, exclude /usr/bin since it's not a real path.
33487    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33488      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33489      # a path prefixed by /cygdrive for fixpath to work.
33490      new_path="$CYGWIN_ROOT_PATH$input_path"
33491    fi
33492  fi
33493
33494  # remove trailing .exe if any
33495  new_path="${new_path/%.exe/}"
33496
33497  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33498
33499  # First separate the path from the arguments. This will split at the first
33500  # space.
33501  complete="$LIPO"
33502  path="${complete%% *}"
33503  tmp="$complete EOL"
33504  arguments="${tmp#* }"
33505
33506  # Input might be given as Windows format, start by converting to
33507  # unix format.
33508  new_path="$path"
33509
33510  windows_path="$new_path"
33511  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33512    unix_path=`$CYGPATH -u "$windows_path"`
33513    new_path="$unix_path"
33514  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33515    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33516    new_path="$unix_path"
33517  fi
33518
33519
33520  # Now try to locate executable using which
33521  new_path=`$WHICH "$new_path" 2> /dev/null`
33522
33523  if test "x$new_path" = x; then
33524    # Oops. Which didn't find the executable.
33525    # The splitting of arguments from the executable at a space might have been incorrect,
33526    # since paths with space are more likely in Windows. Give it another try with the whole
33527    # argument.
33528    path="$complete"
33529    arguments="EOL"
33530    new_path="$path"
33531
33532  windows_path="$new_path"
33533  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33534    unix_path=`$CYGPATH -u "$windows_path"`
33535    new_path="$unix_path"
33536  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33537    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33538    new_path="$unix_path"
33539  fi
33540
33541
33542    new_path=`$WHICH "$new_path" 2> /dev/null`
33543
33544    if test "x$new_path" = x; then
33545      # It's still not found. Now this is an unrecoverable error.
33546      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33547$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33548      has_space=`$ECHO "$complete" | $GREP " "`
33549      if test "x$has_space" != x; then
33550        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33551$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33552      fi
33553      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33554    fi
33555  fi
33556
33557  # Now new_path has a complete unix path to the binary
33558  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33559    # Keep paths in /bin as-is, but remove trailing .exe if any
33560    new_path="${new_path/%.exe/}"
33561    # Do not save /bin paths to all_fixpath_prefixes!
33562  else
33563    # Not in mixed or Windows style, start by that.
33564    new_path=`cmd //c echo $new_path`
33565
33566  input_path="$new_path"
33567  # Check if we need to convert this using DOS-style short mode. If the path
33568  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33569  # take no chances and rewrite it.
33570  # Note: m4 eats our [], so we need to use [ and ] instead.
33571  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33572  if test "x$has_forbidden_chars" != x; then
33573    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33574    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33575  fi
33576
33577    # Output is in $new_path
33578
33579  windows_path="$new_path"
33580  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33581    unix_path=`$CYGPATH -u "$windows_path"`
33582    new_path="$unix_path"
33583  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33584    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33585    new_path="$unix_path"
33586  fi
33587
33588    # remove trailing .exe if any
33589    new_path="${new_path/%.exe/}"
33590
33591    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33592    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33593  fi
33594
33595  else
33596    # We're on a posix platform. Hooray! :)
33597    # First separate the path from the arguments. This will split at the first
33598    # space.
33599    complete="$LIPO"
33600    path="${complete%% *}"
33601    tmp="$complete EOL"
33602    arguments="${tmp#* }"
33603
33604    # Cannot rely on the command "which" here since it doesn't always work.
33605    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33606    if test -z "$is_absolute_path"; then
33607      # Path to executable is not absolute. Find it.
33608      IFS_save="$IFS"
33609      IFS=:
33610      for p in $PATH; do
33611        if test -f "$p/$path" && test -x "$p/$path"; then
33612          new_path="$p/$path"
33613          break
33614        fi
33615      done
33616      IFS="$IFS_save"
33617    else
33618      # This is an absolute path, we can use it without further modifications.
33619      new_path="$path"
33620    fi
33621
33622    if test "x$new_path" = x; then
33623      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33624$as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33625      has_space=`$ECHO "$complete" | $GREP " "`
33626      if test "x$has_space" != x; then
33627        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33628$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33629      fi
33630      as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33631    fi
33632  fi
33633
33634  # Now join together the path and the arguments once again
33635  if test "x$arguments" != xEOL; then
33636    new_complete="$new_path ${arguments% *}"
33637  else
33638    new_complete="$new_path"
33639  fi
33640
33641  if test "x$complete" != "x$new_complete"; then
33642    LIPO="$new_complete"
33643    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
33644$as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
33645  fi
33646
33647  else
33648    OBJC=
33649  fi
33650
33651  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
33652    # Extract the first word of "mt", so it can be a program name with args.
33653set dummy mt; ac_word=$2
33654{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33655$as_echo_n "checking for $ac_word... " >&6; }
33656if ${ac_cv_prog_MT+:} false; then :
33657  $as_echo_n "(cached) " >&6
33658else
33659  if test -n "$MT"; then
33660  ac_cv_prog_MT="$MT" # Let the user override the test.
33661else
33662  ac_prog_rejected=no
33663as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33664for as_dir in $PATH
33665do
33666  IFS=$as_save_IFS
33667  test -z "$as_dir" && as_dir=.
33668    for ac_exec_ext in '' $ac_executable_extensions; do
33669  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33670    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
33671       ac_prog_rejected=yes
33672       continue
33673     fi
33674    ac_cv_prog_MT="mt"
33675    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33676    break 2
33677  fi
33678done
33679  done
33680IFS=$as_save_IFS
33681
33682if test $ac_prog_rejected = yes; then
33683  # We found a bogon in the path, so make sure we never use it.
33684  set dummy $ac_cv_prog_MT
33685  shift
33686  if test $# != 0; then
33687    # We chose a different compiler from the bogus one.
33688    # However, it has the same basename, so the bogon will be chosen
33689    # first if we set MT to just the basename; use the full file name.
33690    shift
33691    ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
33692  fi
33693fi
33694fi
33695fi
33696MT=$ac_cv_prog_MT
33697if test -n "$MT"; then
33698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
33699$as_echo "$MT" >&6; }
33700else
33701  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33702$as_echo "no" >&6; }
33703fi
33704
33705
33706
33707  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33708
33709  # First separate the path from the arguments. This will split at the first
33710  # space.
33711  complete="$MT"
33712  path="${complete%% *}"
33713  tmp="$complete EOL"
33714  arguments="${tmp#* }"
33715
33716  # Input might be given as Windows format, start by converting to
33717  # unix format.
33718  new_path=`$CYGPATH -u "$path"`
33719
33720  # Now try to locate executable using which
33721  new_path=`$WHICH "$new_path" 2> /dev/null`
33722  # bat and cmd files are not always considered executable in cygwin causing which
33723  # to not find them
33724  if test "x$new_path" = x \
33725      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33726      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33727    new_path=`$CYGPATH -u "$path"`
33728  fi
33729  if test "x$new_path" = x; then
33730    # Oops. Which didn't find the executable.
33731    # The splitting of arguments from the executable at a space might have been incorrect,
33732    # since paths with space are more likely in Windows. Give it another try with the whole
33733    # argument.
33734    path="$complete"
33735    arguments="EOL"
33736    new_path=`$CYGPATH -u "$path"`
33737    new_path=`$WHICH "$new_path" 2> /dev/null`
33738    # bat and cmd files are not always considered executable in cygwin causing which
33739    # to not find them
33740    if test "x$new_path" = x \
33741        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33742        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33743      new_path=`$CYGPATH -u "$path"`
33744    fi
33745    if test "x$new_path" = x; then
33746      # It's still not found. Now this is an unrecoverable error.
33747      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33748$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33749      has_space=`$ECHO "$complete" | $GREP " "`
33750      if test "x$has_space" != x; then
33751        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33752$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33753      fi
33754      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33755    fi
33756  fi
33757
33758  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33759  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33760  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33761  # "foo.exe" is OK but "foo" is an error.
33762  #
33763  # This test is therefore slightly more accurate than "test -f" to check for file presence.
33764  # It is also a way to make sure we got the proper file name for the real test later on.
33765  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33766  if test "x$test_shortpath" = x; then
33767    # Short path failed, file does not exist as specified.
33768    # Try adding .exe or .cmd
33769    if test -f "${new_path}.exe"; then
33770      input_to_shortpath="${new_path}.exe"
33771    elif test -f "${new_path}.cmd"; then
33772      input_to_shortpath="${new_path}.cmd"
33773    else
33774      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
33775$as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
33776      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33777$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33778      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33779    fi
33780  else
33781    input_to_shortpath="$new_path"
33782  fi
33783
33784  # Call helper function which possibly converts this using DOS-style short mode.
33785  # If so, the updated path is stored in $new_path.
33786  new_path="$input_to_shortpath"
33787
33788  input_path="$input_to_shortpath"
33789  # Check if we need to convert this using DOS-style short mode. If the path
33790  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33791  # take no chances and rewrite it.
33792  # Note: m4 eats our [], so we need to use [ and ] instead.
33793  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33794  if test "x$has_forbidden_chars" != x; then
33795    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33796    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33797    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33798    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33799      # Going to short mode and back again did indeed matter. Since short mode is
33800      # case insensitive, let's make it lowercase to improve readability.
33801      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33802      # Now convert it back to Unix-stile (cygpath)
33803      input_path=`$CYGPATH -u "$shortmode_path"`
33804      new_path="$input_path"
33805    fi
33806  fi
33807
33808  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33809  if test "x$test_cygdrive_prefix" = x; then
33810    # As a simple fix, exclude /usr/bin since it's not a real path.
33811    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33812      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33813      # a path prefixed by /cygdrive for fixpath to work.
33814      new_path="$CYGWIN_ROOT_PATH$input_path"
33815    fi
33816  fi
33817
33818  # remove trailing .exe if any
33819  new_path="${new_path/%.exe/}"
33820
33821  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33822
33823  # First separate the path from the arguments. This will split at the first
33824  # space.
33825  complete="$MT"
33826  path="${complete%% *}"
33827  tmp="$complete EOL"
33828  arguments="${tmp#* }"
33829
33830  # Input might be given as Windows format, start by converting to
33831  # unix format.
33832  new_path="$path"
33833
33834  windows_path="$new_path"
33835  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33836    unix_path=`$CYGPATH -u "$windows_path"`
33837    new_path="$unix_path"
33838  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33839    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33840    new_path="$unix_path"
33841  fi
33842
33843
33844  # Now try to locate executable using which
33845  new_path=`$WHICH "$new_path" 2> /dev/null`
33846
33847  if test "x$new_path" = x; then
33848    # Oops. Which didn't find the executable.
33849    # The splitting of arguments from the executable at a space might have been incorrect,
33850    # since paths with space are more likely in Windows. Give it another try with the whole
33851    # argument.
33852    path="$complete"
33853    arguments="EOL"
33854    new_path="$path"
33855
33856  windows_path="$new_path"
33857  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33858    unix_path=`$CYGPATH -u "$windows_path"`
33859    new_path="$unix_path"
33860  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33861    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33862    new_path="$unix_path"
33863  fi
33864
33865
33866    new_path=`$WHICH "$new_path" 2> /dev/null`
33867
33868    if test "x$new_path" = x; then
33869      # It's still not found. Now this is an unrecoverable error.
33870      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33871$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33872      has_space=`$ECHO "$complete" | $GREP " "`
33873      if test "x$has_space" != x; then
33874        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33875$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33876      fi
33877      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33878    fi
33879  fi
33880
33881  # Now new_path has a complete unix path to the binary
33882  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33883    # Keep paths in /bin as-is, but remove trailing .exe if any
33884    new_path="${new_path/%.exe/}"
33885    # Do not save /bin paths to all_fixpath_prefixes!
33886  else
33887    # Not in mixed or Windows style, start by that.
33888    new_path=`cmd //c echo $new_path`
33889
33890  input_path="$new_path"
33891  # Check if we need to convert this using DOS-style short mode. If the path
33892  # contains just simple characters, use it. Otherwise (spaces, weird characters),
33893  # take no chances and rewrite it.
33894  # Note: m4 eats our [], so we need to use [ and ] instead.
33895  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33896  if test "x$has_forbidden_chars" != x; then
33897    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33898    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33899  fi
33900
33901    # Output is in $new_path
33902
33903  windows_path="$new_path"
33904  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33905    unix_path=`$CYGPATH -u "$windows_path"`
33906    new_path="$unix_path"
33907  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33908    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33909    new_path="$unix_path"
33910  fi
33911
33912    # remove trailing .exe if any
33913    new_path="${new_path/%.exe/}"
33914
33915    # Save the first 10 bytes of this path to the storage, so fixpath can work.
33916    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33917  fi
33918
33919  else
33920    # We're on a posix platform. Hooray! :)
33921    # First separate the path from the arguments. This will split at the first
33922    # space.
33923    complete="$MT"
33924    path="${complete%% *}"
33925    tmp="$complete EOL"
33926    arguments="${tmp#* }"
33927
33928    # Cannot rely on the command "which" here since it doesn't always work.
33929    is_absolute_path=`$ECHO "$path" | $GREP ^/`
33930    if test -z "$is_absolute_path"; then
33931      # Path to executable is not absolute. Find it.
33932      IFS_save="$IFS"
33933      IFS=:
33934      for p in $PATH; do
33935        if test -f "$p/$path" && test -x "$p/$path"; then
33936          new_path="$p/$path"
33937          break
33938        fi
33939      done
33940      IFS="$IFS_save"
33941    else
33942      # This is an absolute path, we can use it without further modifications.
33943      new_path="$path"
33944    fi
33945
33946    if test "x$new_path" = x; then
33947      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33948$as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33949      has_space=`$ECHO "$complete" | $GREP " "`
33950      if test "x$has_space" != x; then
33951        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33952$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33953      fi
33954      as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33955    fi
33956  fi
33957
33958  # Now join together the path and the arguments once again
33959  if test "x$arguments" != xEOL; then
33960    new_complete="$new_path ${arguments% *}"
33961  else
33962    new_complete="$new_path"
33963  fi
33964
33965  if test "x$complete" != "x$new_complete"; then
33966    MT="$new_complete"
33967    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
33968$as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
33969  fi
33970
33971    # Setup the resource compiler (RC)
33972    # Extract the first word of "rc", so it can be a program name with args.
33973set dummy rc; ac_word=$2
33974{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33975$as_echo_n "checking for $ac_word... " >&6; }
33976if ${ac_cv_prog_RC+:} false; then :
33977  $as_echo_n "(cached) " >&6
33978else
33979  if test -n "$RC"; then
33980  ac_cv_prog_RC="$RC" # Let the user override the test.
33981else
33982  ac_prog_rejected=no
33983as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33984for as_dir in $PATH
33985do
33986  IFS=$as_save_IFS
33987  test -z "$as_dir" && as_dir=.
33988    for ac_exec_ext in '' $ac_executable_extensions; do
33989  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33990    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
33991       ac_prog_rejected=yes
33992       continue
33993     fi
33994    ac_cv_prog_RC="rc"
33995    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33996    break 2
33997  fi
33998done
33999  done
34000IFS=$as_save_IFS
34001
34002if test $ac_prog_rejected = yes; then
34003  # We found a bogon in the path, so make sure we never use it.
34004  set dummy $ac_cv_prog_RC
34005  shift
34006  if test $# != 0; then
34007    # We chose a different compiler from the bogus one.
34008    # However, it has the same basename, so the bogon will be chosen
34009    # first if we set RC to just the basename; use the full file name.
34010    shift
34011    ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34012  fi
34013fi
34014fi
34015fi
34016RC=$ac_cv_prog_RC
34017if test -n "$RC"; then
34018  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34019$as_echo "$RC" >&6; }
34020else
34021  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34022$as_echo "no" >&6; }
34023fi
34024
34025
34026
34027  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34028
34029  # First separate the path from the arguments. This will split at the first
34030  # space.
34031  complete="$RC"
34032  path="${complete%% *}"
34033  tmp="$complete EOL"
34034  arguments="${tmp#* }"
34035
34036  # Input might be given as Windows format, start by converting to
34037  # unix format.
34038  new_path=`$CYGPATH -u "$path"`
34039
34040  # Now try to locate executable using which
34041  new_path=`$WHICH "$new_path" 2> /dev/null`
34042  # bat and cmd files are not always considered executable in cygwin causing which
34043  # to not find them
34044  if test "x$new_path" = x \
34045      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34046      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34047    new_path=`$CYGPATH -u "$path"`
34048  fi
34049  if test "x$new_path" = x; then
34050    # Oops. Which didn't find the executable.
34051    # The splitting of arguments from the executable at a space might have been incorrect,
34052    # since paths with space are more likely in Windows. Give it another try with the whole
34053    # argument.
34054    path="$complete"
34055    arguments="EOL"
34056    new_path=`$CYGPATH -u "$path"`
34057    new_path=`$WHICH "$new_path" 2> /dev/null`
34058    # bat and cmd files are not always considered executable in cygwin causing which
34059    # to not find them
34060    if test "x$new_path" = x \
34061        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34062        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34063      new_path=`$CYGPATH -u "$path"`
34064    fi
34065    if test "x$new_path" = x; then
34066      # It's still not found. Now this is an unrecoverable error.
34067      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34068$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34069      has_space=`$ECHO "$complete" | $GREP " "`
34070      if test "x$has_space" != x; then
34071        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34072$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34073      fi
34074      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34075    fi
34076  fi
34077
34078  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34079  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34080  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34081  # "foo.exe" is OK but "foo" is an error.
34082  #
34083  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34084  # It is also a way to make sure we got the proper file name for the real test later on.
34085  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34086  if test "x$test_shortpath" = x; then
34087    # Short path failed, file does not exist as specified.
34088    # Try adding .exe or .cmd
34089    if test -f "${new_path}.exe"; then
34090      input_to_shortpath="${new_path}.exe"
34091    elif test -f "${new_path}.cmd"; then
34092      input_to_shortpath="${new_path}.cmd"
34093    else
34094      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34095$as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34096      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34097$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34098      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34099    fi
34100  else
34101    input_to_shortpath="$new_path"
34102  fi
34103
34104  # Call helper function which possibly converts this using DOS-style short mode.
34105  # If so, the updated path is stored in $new_path.
34106  new_path="$input_to_shortpath"
34107
34108  input_path="$input_to_shortpath"
34109  # Check if we need to convert this using DOS-style short mode. If the path
34110  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34111  # take no chances and rewrite it.
34112  # Note: m4 eats our [], so we need to use [ and ] instead.
34113  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34114  if test "x$has_forbidden_chars" != x; then
34115    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34116    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34117    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34118    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34119      # Going to short mode and back again did indeed matter. Since short mode is
34120      # case insensitive, let's make it lowercase to improve readability.
34121      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34122      # Now convert it back to Unix-stile (cygpath)
34123      input_path=`$CYGPATH -u "$shortmode_path"`
34124      new_path="$input_path"
34125    fi
34126  fi
34127
34128  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34129  if test "x$test_cygdrive_prefix" = x; then
34130    # As a simple fix, exclude /usr/bin since it's not a real path.
34131    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34132      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34133      # a path prefixed by /cygdrive for fixpath to work.
34134      new_path="$CYGWIN_ROOT_PATH$input_path"
34135    fi
34136  fi
34137
34138  # remove trailing .exe if any
34139  new_path="${new_path/%.exe/}"
34140
34141  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34142
34143  # First separate the path from the arguments. This will split at the first
34144  # space.
34145  complete="$RC"
34146  path="${complete%% *}"
34147  tmp="$complete EOL"
34148  arguments="${tmp#* }"
34149
34150  # Input might be given as Windows format, start by converting to
34151  # unix format.
34152  new_path="$path"
34153
34154  windows_path="$new_path"
34155  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34156    unix_path=`$CYGPATH -u "$windows_path"`
34157    new_path="$unix_path"
34158  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34159    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34160    new_path="$unix_path"
34161  fi
34162
34163
34164  # Now try to locate executable using which
34165  new_path=`$WHICH "$new_path" 2> /dev/null`
34166
34167  if test "x$new_path" = x; then
34168    # Oops. Which didn't find the executable.
34169    # The splitting of arguments from the executable at a space might have been incorrect,
34170    # since paths with space are more likely in Windows. Give it another try with the whole
34171    # argument.
34172    path="$complete"
34173    arguments="EOL"
34174    new_path="$path"
34175
34176  windows_path="$new_path"
34177  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34178    unix_path=`$CYGPATH -u "$windows_path"`
34179    new_path="$unix_path"
34180  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34181    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34182    new_path="$unix_path"
34183  fi
34184
34185
34186    new_path=`$WHICH "$new_path" 2> /dev/null`
34187
34188    if test "x$new_path" = x; then
34189      # It's still not found. Now this is an unrecoverable error.
34190      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34191$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34192      has_space=`$ECHO "$complete" | $GREP " "`
34193      if test "x$has_space" != x; then
34194        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34195$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34196      fi
34197      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34198    fi
34199  fi
34200
34201  # Now new_path has a complete unix path to the binary
34202  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34203    # Keep paths in /bin as-is, but remove trailing .exe if any
34204    new_path="${new_path/%.exe/}"
34205    # Do not save /bin paths to all_fixpath_prefixes!
34206  else
34207    # Not in mixed or Windows style, start by that.
34208    new_path=`cmd //c echo $new_path`
34209
34210  input_path="$new_path"
34211  # Check if we need to convert this using DOS-style short mode. If the path
34212  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34213  # take no chances and rewrite it.
34214  # Note: m4 eats our [], so we need to use [ and ] instead.
34215  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34216  if test "x$has_forbidden_chars" != x; then
34217    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34218    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34219  fi
34220
34221    # Output is in $new_path
34222
34223  windows_path="$new_path"
34224  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34225    unix_path=`$CYGPATH -u "$windows_path"`
34226    new_path="$unix_path"
34227  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34228    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34229    new_path="$unix_path"
34230  fi
34231
34232    # remove trailing .exe if any
34233    new_path="${new_path/%.exe/}"
34234
34235    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34236    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34237  fi
34238
34239  else
34240    # We're on a posix platform. Hooray! :)
34241    # First separate the path from the arguments. This will split at the first
34242    # space.
34243    complete="$RC"
34244    path="${complete%% *}"
34245    tmp="$complete EOL"
34246    arguments="${tmp#* }"
34247
34248    # Cannot rely on the command "which" here since it doesn't always work.
34249    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34250    if test -z "$is_absolute_path"; then
34251      # Path to executable is not absolute. Find it.
34252      IFS_save="$IFS"
34253      IFS=:
34254      for p in $PATH; do
34255        if test -f "$p/$path" && test -x "$p/$path"; then
34256          new_path="$p/$path"
34257          break
34258        fi
34259      done
34260      IFS="$IFS_save"
34261    else
34262      # This is an absolute path, we can use it without further modifications.
34263      new_path="$path"
34264    fi
34265
34266    if test "x$new_path" = x; then
34267      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34268$as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34269      has_space=`$ECHO "$complete" | $GREP " "`
34270      if test "x$has_space" != x; then
34271        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34272$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34273      fi
34274      as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34275    fi
34276  fi
34277
34278  # Now join together the path and the arguments once again
34279  if test "x$arguments" != xEOL; then
34280    new_complete="$new_path ${arguments% *}"
34281  else
34282    new_complete="$new_path"
34283  fi
34284
34285  if test "x$complete" != "x$new_complete"; then
34286    RC="$new_complete"
34287    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34288$as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34289  fi
34290
34291    # Extract the first word of "dumpbin", so it can be a program name with args.
34292set dummy dumpbin; ac_word=$2
34293{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34294$as_echo_n "checking for $ac_word... " >&6; }
34295if ${ac_cv_prog_DUMPBIN+:} false; then :
34296  $as_echo_n "(cached) " >&6
34297else
34298  if test -n "$DUMPBIN"; then
34299  ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34300else
34301as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34302for as_dir in $PATH
34303do
34304  IFS=$as_save_IFS
34305  test -z "$as_dir" && as_dir=.
34306    for ac_exec_ext in '' $ac_executable_extensions; do
34307  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34308    ac_cv_prog_DUMPBIN="dumpbin"
34309    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34310    break 2
34311  fi
34312done
34313  done
34314IFS=$as_save_IFS
34315
34316fi
34317fi
34318DUMPBIN=$ac_cv_prog_DUMPBIN
34319if test -n "$DUMPBIN"; then
34320  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34321$as_echo "$DUMPBIN" >&6; }
34322else
34323  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34324$as_echo "no" >&6; }
34325fi
34326
34327
34328
34329  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34330
34331  # First separate the path from the arguments. This will split at the first
34332  # space.
34333  complete="$DUMPBIN"
34334  path="${complete%% *}"
34335  tmp="$complete EOL"
34336  arguments="${tmp#* }"
34337
34338  # Input might be given as Windows format, start by converting to
34339  # unix format.
34340  new_path=`$CYGPATH -u "$path"`
34341
34342  # Now try to locate executable using which
34343  new_path=`$WHICH "$new_path" 2> /dev/null`
34344  # bat and cmd files are not always considered executable in cygwin causing which
34345  # to not find them
34346  if test "x$new_path" = x \
34347      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34348      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34349    new_path=`$CYGPATH -u "$path"`
34350  fi
34351  if test "x$new_path" = x; then
34352    # Oops. Which didn't find the executable.
34353    # The splitting of arguments from the executable at a space might have been incorrect,
34354    # since paths with space are more likely in Windows. Give it another try with the whole
34355    # argument.
34356    path="$complete"
34357    arguments="EOL"
34358    new_path=`$CYGPATH -u "$path"`
34359    new_path=`$WHICH "$new_path" 2> /dev/null`
34360    # bat and cmd files are not always considered executable in cygwin causing which
34361    # to not find them
34362    if test "x$new_path" = x \
34363        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34364        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34365      new_path=`$CYGPATH -u "$path"`
34366    fi
34367    if test "x$new_path" = x; then
34368      # It's still not found. Now this is an unrecoverable error.
34369      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34370$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34371      has_space=`$ECHO "$complete" | $GREP " "`
34372      if test "x$has_space" != x; then
34373        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34374$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34375      fi
34376      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34377    fi
34378  fi
34379
34380  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34381  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34382  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34383  # "foo.exe" is OK but "foo" is an error.
34384  #
34385  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34386  # It is also a way to make sure we got the proper file name for the real test later on.
34387  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34388  if test "x$test_shortpath" = x; then
34389    # Short path failed, file does not exist as specified.
34390    # Try adding .exe or .cmd
34391    if test -f "${new_path}.exe"; then
34392      input_to_shortpath="${new_path}.exe"
34393    elif test -f "${new_path}.cmd"; then
34394      input_to_shortpath="${new_path}.cmd"
34395    else
34396      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34397$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34398      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34399$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34400      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34401    fi
34402  else
34403    input_to_shortpath="$new_path"
34404  fi
34405
34406  # Call helper function which possibly converts this using DOS-style short mode.
34407  # If so, the updated path is stored in $new_path.
34408  new_path="$input_to_shortpath"
34409
34410  input_path="$input_to_shortpath"
34411  # Check if we need to convert this using DOS-style short mode. If the path
34412  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34413  # take no chances and rewrite it.
34414  # Note: m4 eats our [], so we need to use [ and ] instead.
34415  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34416  if test "x$has_forbidden_chars" != x; then
34417    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34418    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34419    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34420    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34421      # Going to short mode and back again did indeed matter. Since short mode is
34422      # case insensitive, let's make it lowercase to improve readability.
34423      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34424      # Now convert it back to Unix-stile (cygpath)
34425      input_path=`$CYGPATH -u "$shortmode_path"`
34426      new_path="$input_path"
34427    fi
34428  fi
34429
34430  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34431  if test "x$test_cygdrive_prefix" = x; then
34432    # As a simple fix, exclude /usr/bin since it's not a real path.
34433    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34434      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34435      # a path prefixed by /cygdrive for fixpath to work.
34436      new_path="$CYGWIN_ROOT_PATH$input_path"
34437    fi
34438  fi
34439
34440  # remove trailing .exe if any
34441  new_path="${new_path/%.exe/}"
34442
34443  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34444
34445  # First separate the path from the arguments. This will split at the first
34446  # space.
34447  complete="$DUMPBIN"
34448  path="${complete%% *}"
34449  tmp="$complete EOL"
34450  arguments="${tmp#* }"
34451
34452  # Input might be given as Windows format, start by converting to
34453  # unix format.
34454  new_path="$path"
34455
34456  windows_path="$new_path"
34457  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34458    unix_path=`$CYGPATH -u "$windows_path"`
34459    new_path="$unix_path"
34460  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34461    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34462    new_path="$unix_path"
34463  fi
34464
34465
34466  # Now try to locate executable using which
34467  new_path=`$WHICH "$new_path" 2> /dev/null`
34468
34469  if test "x$new_path" = x; then
34470    # Oops. Which didn't find the executable.
34471    # The splitting of arguments from the executable at a space might have been incorrect,
34472    # since paths with space are more likely in Windows. Give it another try with the whole
34473    # argument.
34474    path="$complete"
34475    arguments="EOL"
34476    new_path="$path"
34477
34478  windows_path="$new_path"
34479  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34480    unix_path=`$CYGPATH -u "$windows_path"`
34481    new_path="$unix_path"
34482  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34483    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34484    new_path="$unix_path"
34485  fi
34486
34487
34488    new_path=`$WHICH "$new_path" 2> /dev/null`
34489
34490    if test "x$new_path" = x; then
34491      # It's still not found. Now this is an unrecoverable error.
34492      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34493$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34494      has_space=`$ECHO "$complete" | $GREP " "`
34495      if test "x$has_space" != x; then
34496        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34497$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34498      fi
34499      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34500    fi
34501  fi
34502
34503  # Now new_path has a complete unix path to the binary
34504  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34505    # Keep paths in /bin as-is, but remove trailing .exe if any
34506    new_path="${new_path/%.exe/}"
34507    # Do not save /bin paths to all_fixpath_prefixes!
34508  else
34509    # Not in mixed or Windows style, start by that.
34510    new_path=`cmd //c echo $new_path`
34511
34512  input_path="$new_path"
34513  # Check if we need to convert this using DOS-style short mode. If the path
34514  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34515  # take no chances and rewrite it.
34516  # Note: m4 eats our [], so we need to use [ and ] instead.
34517  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34518  if test "x$has_forbidden_chars" != x; then
34519    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34520    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34521  fi
34522
34523    # Output is in $new_path
34524
34525  windows_path="$new_path"
34526  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34527    unix_path=`$CYGPATH -u "$windows_path"`
34528    new_path="$unix_path"
34529  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34530    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34531    new_path="$unix_path"
34532  fi
34533
34534    # remove trailing .exe if any
34535    new_path="${new_path/%.exe/}"
34536
34537    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34538    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34539  fi
34540
34541  else
34542    # We're on a posix platform. Hooray! :)
34543    # First separate the path from the arguments. This will split at the first
34544    # space.
34545    complete="$DUMPBIN"
34546    path="${complete%% *}"
34547    tmp="$complete EOL"
34548    arguments="${tmp#* }"
34549
34550    # Cannot rely on the command "which" here since it doesn't always work.
34551    is_absolute_path=`$ECHO "$path" | $GREP ^/`
34552    if test -z "$is_absolute_path"; then
34553      # Path to executable is not absolute. Find it.
34554      IFS_save="$IFS"
34555      IFS=:
34556      for p in $PATH; do
34557        if test -f "$p/$path" && test -x "$p/$path"; then
34558          new_path="$p/$path"
34559          break
34560        fi
34561      done
34562      IFS="$IFS_save"
34563    else
34564      # This is an absolute path, we can use it without further modifications.
34565      new_path="$path"
34566    fi
34567
34568    if test "x$new_path" = x; then
34569      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34570$as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34571      has_space=`$ECHO "$complete" | $GREP " "`
34572      if test "x$has_space" != x; then
34573        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34574$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34575      fi
34576      as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34577    fi
34578  fi
34579
34580  # Now join together the path and the arguments once again
34581  if test "x$arguments" != xEOL; then
34582    new_complete="$new_path ${arguments% *}"
34583  else
34584    new_complete="$new_path"
34585  fi
34586
34587  if test "x$complete" != "x$new_complete"; then
34588    DUMPBIN="$new_complete"
34589    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
34590$as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
34591  fi
34592
34593  fi
34594
34595  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
34596
34597
34598  # Publish this variable in the help.
34599
34600
34601  if test "x$STRIP" = x; then
34602    # The variable is not set by user, try to locate tool using the code snippet
34603    for ac_prog in strip
34604do
34605  # Extract the first word of "$ac_prog", so it can be a program name with args.
34606set dummy $ac_prog; ac_word=$2
34607{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34608$as_echo_n "checking for $ac_word... " >&6; }
34609if ${ac_cv_path_STRIP+:} false; then :
34610  $as_echo_n "(cached) " >&6
34611else
34612  case $STRIP in
34613  [\\/]* | ?:[\\/]*)
34614  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34615  ;;
34616  *)
34617  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34618for as_dir in $PATH
34619do
34620  IFS=$as_save_IFS
34621  test -z "$as_dir" && as_dir=.
34622    for ac_exec_ext in '' $ac_executable_extensions; do
34623  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34624    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34625    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34626    break 2
34627  fi
34628done
34629  done
34630IFS=$as_save_IFS
34631
34632  ;;
34633esac
34634fi
34635STRIP=$ac_cv_path_STRIP
34636if test -n "$STRIP"; then
34637  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34638$as_echo "$STRIP" >&6; }
34639else
34640  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34641$as_echo "no" >&6; }
34642fi
34643
34644
34645  test -n "$STRIP" && break
34646done
34647
34648  else
34649    # The variable is set, but is it from the command line or the environment?
34650
34651    # Try to remove the string !STRIP! from our list.
34652    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
34653    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
34654      # If it failed, the variable was not from the command line. Ignore it,
34655      # but warn the user (except for BASH, which is always set by the calling BASH).
34656      if test "xSTRIP" != xBASH; then
34657        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
34658$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
34659      fi
34660      # Try to locate tool using the code snippet
34661      for ac_prog in strip
34662do
34663  # Extract the first word of "$ac_prog", so it can be a program name with args.
34664set dummy $ac_prog; ac_word=$2
34665{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34666$as_echo_n "checking for $ac_word... " >&6; }
34667if ${ac_cv_path_STRIP+:} false; then :
34668  $as_echo_n "(cached) " >&6
34669else
34670  case $STRIP in
34671  [\\/]* | ?:[\\/]*)
34672  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34673  ;;
34674  *)
34675  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34676for as_dir in $PATH
34677do
34678  IFS=$as_save_IFS
34679  test -z "$as_dir" && as_dir=.
34680    for ac_exec_ext in '' $ac_executable_extensions; do
34681  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34682    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34683    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34684    break 2
34685  fi
34686done
34687  done
34688IFS=$as_save_IFS
34689
34690  ;;
34691esac
34692fi
34693STRIP=$ac_cv_path_STRIP
34694if test -n "$STRIP"; then
34695  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34696$as_echo "$STRIP" >&6; }
34697else
34698  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34699$as_echo "no" >&6; }
34700fi
34701
34702
34703  test -n "$STRIP" && break
34704done
34705
34706    else
34707      # If it succeeded, then it was overridden by the user. We will use it
34708      # for the tool.
34709
34710      # First remove it from the list of overridden variables, so we can test
34711      # for unknown variables in the end.
34712      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
34713
34714      # Check if the provided tool contains a complete path.
34715      tool_specified="$STRIP"
34716      tool_basename="${tool_specified##*/}"
34717      if test "x$tool_basename" = "x$tool_specified"; then
34718        # A command without a complete path is provided, search $PATH.
34719        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
34720$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
34721        # Extract the first word of "$tool_basename", so it can be a program name with args.
34722set dummy $tool_basename; ac_word=$2
34723{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34724$as_echo_n "checking for $ac_word... " >&6; }
34725if ${ac_cv_path_STRIP+:} false; then :
34726  $as_echo_n "(cached) " >&6
34727else
34728  case $STRIP in
34729  [\\/]* | ?:[\\/]*)
34730  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
34731  ;;
34732  *)
34733  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34734for as_dir in $PATH
34735do
34736  IFS=$as_save_IFS
34737  test -z "$as_dir" && as_dir=.
34738    for ac_exec_ext in '' $ac_executable_extensions; do
34739  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34740    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
34741    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34742    break 2
34743  fi
34744done
34745  done
34746IFS=$as_save_IFS
34747
34748  ;;
34749esac
34750fi
34751STRIP=$ac_cv_path_STRIP
34752if test -n "$STRIP"; then
34753  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
34754$as_echo "$STRIP" >&6; }
34755else
34756  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34757$as_echo "no" >&6; }
34758fi
34759
34760
34761        if test "x$STRIP" = x; then
34762          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
34763        fi
34764      else
34765        # Otherwise we believe it is a complete path. Use it as it is.
34766        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
34767$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
34768        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
34769$as_echo_n "checking for STRIP... " >&6; }
34770        if test ! -x "$tool_specified"; then
34771          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
34772$as_echo "not found" >&6; }
34773          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
34774        fi
34775        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
34776$as_echo "$tool_specified" >&6; }
34777      fi
34778    fi
34779  fi
34780
34781
34782
34783  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34784
34785  # First separate the path from the arguments. This will split at the first
34786  # space.
34787  complete="$STRIP"
34788  path="${complete%% *}"
34789  tmp="$complete EOL"
34790  arguments="${tmp#* }"
34791
34792  # Input might be given as Windows format, start by converting to
34793  # unix format.
34794  new_path=`$CYGPATH -u "$path"`
34795
34796  # Now try to locate executable using which
34797  new_path=`$WHICH "$new_path" 2> /dev/null`
34798  # bat and cmd files are not always considered executable in cygwin causing which
34799  # to not find them
34800  if test "x$new_path" = x \
34801      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34802      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34803    new_path=`$CYGPATH -u "$path"`
34804  fi
34805  if test "x$new_path" = x; then
34806    # Oops. Which didn't find the executable.
34807    # The splitting of arguments from the executable at a space might have been incorrect,
34808    # since paths with space are more likely in Windows. Give it another try with the whole
34809    # argument.
34810    path="$complete"
34811    arguments="EOL"
34812    new_path=`$CYGPATH -u "$path"`
34813    new_path=`$WHICH "$new_path" 2> /dev/null`
34814    # bat and cmd files are not always considered executable in cygwin causing which
34815    # to not find them
34816    if test "x$new_path" = x \
34817        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34818        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34819      new_path=`$CYGPATH -u "$path"`
34820    fi
34821    if test "x$new_path" = x; then
34822      # It's still not found. Now this is an unrecoverable error.
34823      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34824$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34825      has_space=`$ECHO "$complete" | $GREP " "`
34826      if test "x$has_space" != x; then
34827        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34828$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34829      fi
34830      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34831    fi
34832  fi
34833
34834  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34835  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34836  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34837  # "foo.exe" is OK but "foo" is an error.
34838  #
34839  # This test is therefore slightly more accurate than "test -f" to check for file presence.
34840  # It is also a way to make sure we got the proper file name for the real test later on.
34841  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34842  if test "x$test_shortpath" = x; then
34843    # Short path failed, file does not exist as specified.
34844    # Try adding .exe or .cmd
34845    if test -f "${new_path}.exe"; then
34846      input_to_shortpath="${new_path}.exe"
34847    elif test -f "${new_path}.cmd"; then
34848      input_to_shortpath="${new_path}.cmd"
34849    else
34850      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
34851$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
34852      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34853$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34854      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34855    fi
34856  else
34857    input_to_shortpath="$new_path"
34858  fi
34859
34860  # Call helper function which possibly converts this using DOS-style short mode.
34861  # If so, the updated path is stored in $new_path.
34862  new_path="$input_to_shortpath"
34863
34864  input_path="$input_to_shortpath"
34865  # Check if we need to convert this using DOS-style short mode. If the path
34866  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34867  # take no chances and rewrite it.
34868  # Note: m4 eats our [], so we need to use [ and ] instead.
34869  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34870  if test "x$has_forbidden_chars" != x; then
34871    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34872    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34873    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34874    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34875      # Going to short mode and back again did indeed matter. Since short mode is
34876      # case insensitive, let's make it lowercase to improve readability.
34877      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34878      # Now convert it back to Unix-stile (cygpath)
34879      input_path=`$CYGPATH -u "$shortmode_path"`
34880      new_path="$input_path"
34881    fi
34882  fi
34883
34884  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34885  if test "x$test_cygdrive_prefix" = x; then
34886    # As a simple fix, exclude /usr/bin since it's not a real path.
34887    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34888      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34889      # a path prefixed by /cygdrive for fixpath to work.
34890      new_path="$CYGWIN_ROOT_PATH$input_path"
34891    fi
34892  fi
34893
34894  # remove trailing .exe if any
34895  new_path="${new_path/%.exe/}"
34896
34897  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34898
34899  # First separate the path from the arguments. This will split at the first
34900  # space.
34901  complete="$STRIP"
34902  path="${complete%% *}"
34903  tmp="$complete EOL"
34904  arguments="${tmp#* }"
34905
34906  # Input might be given as Windows format, start by converting to
34907  # unix format.
34908  new_path="$path"
34909
34910  windows_path="$new_path"
34911  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34912    unix_path=`$CYGPATH -u "$windows_path"`
34913    new_path="$unix_path"
34914  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34915    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34916    new_path="$unix_path"
34917  fi
34918
34919
34920  # Now try to locate executable using which
34921  new_path=`$WHICH "$new_path" 2> /dev/null`
34922
34923  if test "x$new_path" = x; then
34924    # Oops. Which didn't find the executable.
34925    # The splitting of arguments from the executable at a space might have been incorrect,
34926    # since paths with space are more likely in Windows. Give it another try with the whole
34927    # argument.
34928    path="$complete"
34929    arguments="EOL"
34930    new_path="$path"
34931
34932  windows_path="$new_path"
34933  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34934    unix_path=`$CYGPATH -u "$windows_path"`
34935    new_path="$unix_path"
34936  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34937    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34938    new_path="$unix_path"
34939  fi
34940
34941
34942    new_path=`$WHICH "$new_path" 2> /dev/null`
34943
34944    if test "x$new_path" = x; then
34945      # It's still not found. Now this is an unrecoverable error.
34946      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
34947$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
34948      has_space=`$ECHO "$complete" | $GREP " "`
34949      if test "x$has_space" != x; then
34950        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34951$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34952      fi
34953      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
34954    fi
34955  fi
34956
34957  # Now new_path has a complete unix path to the binary
34958  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34959    # Keep paths in /bin as-is, but remove trailing .exe if any
34960    new_path="${new_path/%.exe/}"
34961    # Do not save /bin paths to all_fixpath_prefixes!
34962  else
34963    # Not in mixed or Windows style, start by that.
34964    new_path=`cmd //c echo $new_path`
34965
34966  input_path="$new_path"
34967  # Check if we need to convert this using DOS-style short mode. If the path
34968  # contains just simple characters, use it. Otherwise (spaces, weird characters),
34969  # take no chances and rewrite it.
34970  # Note: m4 eats our [], so we need to use [ and ] instead.
34971  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34972  if test "x$has_forbidden_chars" != x; then
34973    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34974    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34975  fi
34976
34977    # Output is in $new_path
34978
34979  windows_path="$new_path"
34980  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34981    unix_path=`$CYGPATH -u "$windows_path"`
34982    new_path="$unix_path"
34983  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34984    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34985    new_path="$unix_path"
34986  fi
34987
34988    # remove trailing .exe if any
34989    new_path="${new_path/%.exe/}"
34990
34991    # Save the first 10 bytes of this path to the storage, so fixpath can work.
34992    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34993  fi
34994
34995  else
34996    # We're on a posix platform. Hooray! :)
34997    # First separate the path from the arguments. This will split at the first
34998    # space.
34999    complete="$STRIP"
35000    path="${complete%% *}"
35001    tmp="$complete EOL"
35002    arguments="${tmp#* }"
35003
35004    # Cannot rely on the command "which" here since it doesn't always work.
35005    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35006    if test -z "$is_absolute_path"; then
35007      # Path to executable is not absolute. Find it.
35008      IFS_save="$IFS"
35009      IFS=:
35010      for p in $PATH; do
35011        if test -f "$p/$path" && test -x "$p/$path"; then
35012          new_path="$p/$path"
35013          break
35014        fi
35015      done
35016      IFS="$IFS_save"
35017    else
35018      # This is an absolute path, we can use it without further modifications.
35019      new_path="$path"
35020    fi
35021
35022    if test "x$new_path" = x; then
35023      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35024$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35025      has_space=`$ECHO "$complete" | $GREP " "`
35026      if test "x$has_space" != x; then
35027        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35028$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35029      fi
35030      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35031    fi
35032  fi
35033
35034  # Now join together the path and the arguments once again
35035  if test "x$arguments" != xEOL; then
35036    new_complete="$new_path ${arguments% *}"
35037  else
35038    new_complete="$new_path"
35039  fi
35040
35041  if test "x$complete" != "x$new_complete"; then
35042    STRIP="$new_complete"
35043    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
35044$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
35045  fi
35046
35047
35048
35049  # Publish this variable in the help.
35050
35051
35052  if test "x$NM" = x; then
35053    # The variable is not set by user, try to locate tool using the code snippet
35054    for ac_prog in nm
35055do
35056  # Extract the first word of "$ac_prog", so it can be a program name with args.
35057set dummy $ac_prog; ac_word=$2
35058{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35059$as_echo_n "checking for $ac_word... " >&6; }
35060if ${ac_cv_path_NM+:} false; then :
35061  $as_echo_n "(cached) " >&6
35062else
35063  case $NM in
35064  [\\/]* | ?:[\\/]*)
35065  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35066  ;;
35067  *)
35068  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35069for as_dir in $PATH
35070do
35071  IFS=$as_save_IFS
35072  test -z "$as_dir" && as_dir=.
35073    for ac_exec_ext in '' $ac_executable_extensions; do
35074  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35075    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35076    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35077    break 2
35078  fi
35079done
35080  done
35081IFS=$as_save_IFS
35082
35083  ;;
35084esac
35085fi
35086NM=$ac_cv_path_NM
35087if test -n "$NM"; then
35088  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35089$as_echo "$NM" >&6; }
35090else
35091  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35092$as_echo "no" >&6; }
35093fi
35094
35095
35096  test -n "$NM" && break
35097done
35098
35099  else
35100    # The variable is set, but is it from the command line or the environment?
35101
35102    # Try to remove the string !NM! from our list.
35103    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
35104    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35105      # If it failed, the variable was not from the command line. Ignore it,
35106      # but warn the user (except for BASH, which is always set by the calling BASH).
35107      if test "xNM" != xBASH; then
35108        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
35109$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
35110      fi
35111      # Try to locate tool using the code snippet
35112      for ac_prog in nm
35113do
35114  # Extract the first word of "$ac_prog", so it can be a program name with args.
35115set dummy $ac_prog; ac_word=$2
35116{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35117$as_echo_n "checking for $ac_word... " >&6; }
35118if ${ac_cv_path_NM+:} false; then :
35119  $as_echo_n "(cached) " >&6
35120else
35121  case $NM in
35122  [\\/]* | ?:[\\/]*)
35123  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35124  ;;
35125  *)
35126  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35127for as_dir in $PATH
35128do
35129  IFS=$as_save_IFS
35130  test -z "$as_dir" && as_dir=.
35131    for ac_exec_ext in '' $ac_executable_extensions; do
35132  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35133    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35134    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35135    break 2
35136  fi
35137done
35138  done
35139IFS=$as_save_IFS
35140
35141  ;;
35142esac
35143fi
35144NM=$ac_cv_path_NM
35145if test -n "$NM"; then
35146  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35147$as_echo "$NM" >&6; }
35148else
35149  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35150$as_echo "no" >&6; }
35151fi
35152
35153
35154  test -n "$NM" && break
35155done
35156
35157    else
35158      # If it succeeded, then it was overridden by the user. We will use it
35159      # for the tool.
35160
35161      # First remove it from the list of overridden variables, so we can test
35162      # for unknown variables in the end.
35163      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35164
35165      # Check if the provided tool contains a complete path.
35166      tool_specified="$NM"
35167      tool_basename="${tool_specified##*/}"
35168      if test "x$tool_basename" = "x$tool_specified"; then
35169        # A command without a complete path is provided, search $PATH.
35170        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
35171$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
35172        # Extract the first word of "$tool_basename", so it can be a program name with args.
35173set dummy $tool_basename; ac_word=$2
35174{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35175$as_echo_n "checking for $ac_word... " >&6; }
35176if ${ac_cv_path_NM+:} false; then :
35177  $as_echo_n "(cached) " >&6
35178else
35179  case $NM in
35180  [\\/]* | ?:[\\/]*)
35181  ac_cv_path_NM="$NM" # Let the user override the test with a path.
35182  ;;
35183  *)
35184  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35185for as_dir in $PATH
35186do
35187  IFS=$as_save_IFS
35188  test -z "$as_dir" && as_dir=.
35189    for ac_exec_ext in '' $ac_executable_extensions; do
35190  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35191    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35192    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35193    break 2
35194  fi
35195done
35196  done
35197IFS=$as_save_IFS
35198
35199  ;;
35200esac
35201fi
35202NM=$ac_cv_path_NM
35203if test -n "$NM"; then
35204  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35205$as_echo "$NM" >&6; }
35206else
35207  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35208$as_echo "no" >&6; }
35209fi
35210
35211
35212        if test "x$NM" = x; then
35213          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35214        fi
35215      else
35216        # Otherwise we believe it is a complete path. Use it as it is.
35217        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
35218$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
35219        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
35220$as_echo_n "checking for NM... " >&6; }
35221        if test ! -x "$tool_specified"; then
35222          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35223$as_echo "not found" >&6; }
35224          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
35225        fi
35226        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35227$as_echo "$tool_specified" >&6; }
35228      fi
35229    fi
35230  fi
35231
35232
35233
35234  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35235
35236  # First separate the path from the arguments. This will split at the first
35237  # space.
35238  complete="$NM"
35239  path="${complete%% *}"
35240  tmp="$complete EOL"
35241  arguments="${tmp#* }"
35242
35243  # Input might be given as Windows format, start by converting to
35244  # unix format.
35245  new_path=`$CYGPATH -u "$path"`
35246
35247  # Now try to locate executable using which
35248  new_path=`$WHICH "$new_path" 2> /dev/null`
35249  # bat and cmd files are not always considered executable in cygwin causing which
35250  # to not find them
35251  if test "x$new_path" = x \
35252      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35253      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35254    new_path=`$CYGPATH -u "$path"`
35255  fi
35256  if test "x$new_path" = x; then
35257    # Oops. Which didn't find the executable.
35258    # The splitting of arguments from the executable at a space might have been incorrect,
35259    # since paths with space are more likely in Windows. Give it another try with the whole
35260    # argument.
35261    path="$complete"
35262    arguments="EOL"
35263    new_path=`$CYGPATH -u "$path"`
35264    new_path=`$WHICH "$new_path" 2> /dev/null`
35265    # bat and cmd files are not always considered executable in cygwin causing which
35266    # to not find them
35267    if test "x$new_path" = x \
35268        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35269        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35270      new_path=`$CYGPATH -u "$path"`
35271    fi
35272    if test "x$new_path" = x; then
35273      # It's still not found. Now this is an unrecoverable error.
35274      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35275$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35276      has_space=`$ECHO "$complete" | $GREP " "`
35277      if test "x$has_space" != x; then
35278        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35279$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35280      fi
35281      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35282    fi
35283  fi
35284
35285  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35286  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35287  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35288  # "foo.exe" is OK but "foo" is an error.
35289  #
35290  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35291  # It is also a way to make sure we got the proper file name for the real test later on.
35292  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35293  if test "x$test_shortpath" = x; then
35294    # Short path failed, file does not exist as specified.
35295    # Try adding .exe or .cmd
35296    if test -f "${new_path}.exe"; then
35297      input_to_shortpath="${new_path}.exe"
35298    elif test -f "${new_path}.cmd"; then
35299      input_to_shortpath="${new_path}.cmd"
35300    else
35301      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
35302$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
35303      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35304$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35305      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35306    fi
35307  else
35308    input_to_shortpath="$new_path"
35309  fi
35310
35311  # Call helper function which possibly converts this using DOS-style short mode.
35312  # If so, the updated path is stored in $new_path.
35313  new_path="$input_to_shortpath"
35314
35315  input_path="$input_to_shortpath"
35316  # Check if we need to convert this using DOS-style short mode. If the path
35317  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35318  # take no chances and rewrite it.
35319  # Note: m4 eats our [], so we need to use [ and ] instead.
35320  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35321  if test "x$has_forbidden_chars" != x; then
35322    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35323    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35324    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35325    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35326      # Going to short mode and back again did indeed matter. Since short mode is
35327      # case insensitive, let's make it lowercase to improve readability.
35328      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35329      # Now convert it back to Unix-stile (cygpath)
35330      input_path=`$CYGPATH -u "$shortmode_path"`
35331      new_path="$input_path"
35332    fi
35333  fi
35334
35335  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35336  if test "x$test_cygdrive_prefix" = x; then
35337    # As a simple fix, exclude /usr/bin since it's not a real path.
35338    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35339      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35340      # a path prefixed by /cygdrive for fixpath to work.
35341      new_path="$CYGWIN_ROOT_PATH$input_path"
35342    fi
35343  fi
35344
35345  # remove trailing .exe if any
35346  new_path="${new_path/%.exe/}"
35347
35348  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35349
35350  # First separate the path from the arguments. This will split at the first
35351  # space.
35352  complete="$NM"
35353  path="${complete%% *}"
35354  tmp="$complete EOL"
35355  arguments="${tmp#* }"
35356
35357  # Input might be given as Windows format, start by converting to
35358  # unix format.
35359  new_path="$path"
35360
35361  windows_path="$new_path"
35362  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35363    unix_path=`$CYGPATH -u "$windows_path"`
35364    new_path="$unix_path"
35365  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35366    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35367    new_path="$unix_path"
35368  fi
35369
35370
35371  # Now try to locate executable using which
35372  new_path=`$WHICH "$new_path" 2> /dev/null`
35373
35374  if test "x$new_path" = x; then
35375    # Oops. Which didn't find the executable.
35376    # The splitting of arguments from the executable at a space might have been incorrect,
35377    # since paths with space are more likely in Windows. Give it another try with the whole
35378    # argument.
35379    path="$complete"
35380    arguments="EOL"
35381    new_path="$path"
35382
35383  windows_path="$new_path"
35384  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35385    unix_path=`$CYGPATH -u "$windows_path"`
35386    new_path="$unix_path"
35387  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35388    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35389    new_path="$unix_path"
35390  fi
35391
35392
35393    new_path=`$WHICH "$new_path" 2> /dev/null`
35394
35395    if test "x$new_path" = x; then
35396      # It's still not found. Now this is an unrecoverable error.
35397      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35398$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35399      has_space=`$ECHO "$complete" | $GREP " "`
35400      if test "x$has_space" != x; then
35401        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35402$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35403      fi
35404      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35405    fi
35406  fi
35407
35408  # Now new_path has a complete unix path to the binary
35409  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35410    # Keep paths in /bin as-is, but remove trailing .exe if any
35411    new_path="${new_path/%.exe/}"
35412    # Do not save /bin paths to all_fixpath_prefixes!
35413  else
35414    # Not in mixed or Windows style, start by that.
35415    new_path=`cmd //c echo $new_path`
35416
35417  input_path="$new_path"
35418  # Check if we need to convert this using DOS-style short mode. If the path
35419  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35420  # take no chances and rewrite it.
35421  # Note: m4 eats our [], so we need to use [ and ] instead.
35422  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35423  if test "x$has_forbidden_chars" != x; then
35424    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35425    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35426  fi
35427
35428    # Output is in $new_path
35429
35430  windows_path="$new_path"
35431  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35432    unix_path=`$CYGPATH -u "$windows_path"`
35433    new_path="$unix_path"
35434  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35435    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35436    new_path="$unix_path"
35437  fi
35438
35439    # remove trailing .exe if any
35440    new_path="${new_path/%.exe/}"
35441
35442    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35443    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35444  fi
35445
35446  else
35447    # We're on a posix platform. Hooray! :)
35448    # First separate the path from the arguments. This will split at the first
35449    # space.
35450    complete="$NM"
35451    path="${complete%% *}"
35452    tmp="$complete EOL"
35453    arguments="${tmp#* }"
35454
35455    # Cannot rely on the command "which" here since it doesn't always work.
35456    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35457    if test -z "$is_absolute_path"; then
35458      # Path to executable is not absolute. Find it.
35459      IFS_save="$IFS"
35460      IFS=:
35461      for p in $PATH; do
35462        if test -f "$p/$path" && test -x "$p/$path"; then
35463          new_path="$p/$path"
35464          break
35465        fi
35466      done
35467      IFS="$IFS_save"
35468    else
35469      # This is an absolute path, we can use it without further modifications.
35470      new_path="$path"
35471    fi
35472
35473    if test "x$new_path" = x; then
35474      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35475$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35476      has_space=`$ECHO "$complete" | $GREP " "`
35477      if test "x$has_space" != x; then
35478        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35479$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35480      fi
35481      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35482    fi
35483  fi
35484
35485  # Now join together the path and the arguments once again
35486  if test "x$arguments" != xEOL; then
35487    new_complete="$new_path ${arguments% *}"
35488  else
35489    new_complete="$new_path"
35490  fi
35491
35492  if test "x$complete" != "x$new_complete"; then
35493    NM="$new_complete"
35494    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
35495$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
35496  fi
35497
35498
35499
35500  # Publish this variable in the help.
35501
35502
35503  if test "x$GNM" = x; then
35504    # The variable is not set by user, try to locate tool using the code snippet
35505    for ac_prog in gnm
35506do
35507  # Extract the first word of "$ac_prog", so it can be a program name with args.
35508set dummy $ac_prog; ac_word=$2
35509{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35510$as_echo_n "checking for $ac_word... " >&6; }
35511if ${ac_cv_path_GNM+:} false; then :
35512  $as_echo_n "(cached) " >&6
35513else
35514  case $GNM in
35515  [\\/]* | ?:[\\/]*)
35516  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35517  ;;
35518  *)
35519  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35520for as_dir in $PATH
35521do
35522  IFS=$as_save_IFS
35523  test -z "$as_dir" && as_dir=.
35524    for ac_exec_ext in '' $ac_executable_extensions; do
35525  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35526    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35527    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35528    break 2
35529  fi
35530done
35531  done
35532IFS=$as_save_IFS
35533
35534  ;;
35535esac
35536fi
35537GNM=$ac_cv_path_GNM
35538if test -n "$GNM"; then
35539  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35540$as_echo "$GNM" >&6; }
35541else
35542  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35543$as_echo "no" >&6; }
35544fi
35545
35546
35547  test -n "$GNM" && break
35548done
35549
35550  else
35551    # The variable is set, but is it from the command line or the environment?
35552
35553    # Try to remove the string !GNM! from our list.
35554    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
35555    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35556      # If it failed, the variable was not from the command line. Ignore it,
35557      # but warn the user (except for BASH, which is always set by the calling BASH).
35558      if test "xGNM" != xBASH; then
35559        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
35560$as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
35561      fi
35562      # Try to locate tool using the code snippet
35563      for ac_prog in gnm
35564do
35565  # Extract the first word of "$ac_prog", so it can be a program name with args.
35566set dummy $ac_prog; ac_word=$2
35567{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35568$as_echo_n "checking for $ac_word... " >&6; }
35569if ${ac_cv_path_GNM+:} false; then :
35570  $as_echo_n "(cached) " >&6
35571else
35572  case $GNM in
35573  [\\/]* | ?:[\\/]*)
35574  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35575  ;;
35576  *)
35577  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35578for as_dir in $PATH
35579do
35580  IFS=$as_save_IFS
35581  test -z "$as_dir" && as_dir=.
35582    for ac_exec_ext in '' $ac_executable_extensions; do
35583  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35584    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35585    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35586    break 2
35587  fi
35588done
35589  done
35590IFS=$as_save_IFS
35591
35592  ;;
35593esac
35594fi
35595GNM=$ac_cv_path_GNM
35596if test -n "$GNM"; then
35597  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35598$as_echo "$GNM" >&6; }
35599else
35600  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35601$as_echo "no" >&6; }
35602fi
35603
35604
35605  test -n "$GNM" && break
35606done
35607
35608    else
35609      # If it succeeded, then it was overridden by the user. We will use it
35610      # for the tool.
35611
35612      # First remove it from the list of overridden variables, so we can test
35613      # for unknown variables in the end.
35614      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35615
35616      # Check if the provided tool contains a complete path.
35617      tool_specified="$GNM"
35618      tool_basename="${tool_specified##*/}"
35619      if test "x$tool_basename" = "x$tool_specified"; then
35620        # A command without a complete path is provided, search $PATH.
35621        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
35622$as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
35623        # Extract the first word of "$tool_basename", so it can be a program name with args.
35624set dummy $tool_basename; ac_word=$2
35625{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35626$as_echo_n "checking for $ac_word... " >&6; }
35627if ${ac_cv_path_GNM+:} false; then :
35628  $as_echo_n "(cached) " >&6
35629else
35630  case $GNM in
35631  [\\/]* | ?:[\\/]*)
35632  ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
35633  ;;
35634  *)
35635  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35636for as_dir in $PATH
35637do
35638  IFS=$as_save_IFS
35639  test -z "$as_dir" && as_dir=.
35640    for ac_exec_ext in '' $ac_executable_extensions; do
35641  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35642    ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
35643    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35644    break 2
35645  fi
35646done
35647  done
35648IFS=$as_save_IFS
35649
35650  ;;
35651esac
35652fi
35653GNM=$ac_cv_path_GNM
35654if test -n "$GNM"; then
35655  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
35656$as_echo "$GNM" >&6; }
35657else
35658  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35659$as_echo "no" >&6; }
35660fi
35661
35662
35663        if test "x$GNM" = x; then
35664          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35665        fi
35666      else
35667        # Otherwise we believe it is a complete path. Use it as it is.
35668        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
35669$as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
35670        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
35671$as_echo_n "checking for GNM... " >&6; }
35672        if test ! -x "$tool_specified"; then
35673          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35674$as_echo "not found" >&6; }
35675          as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
35676        fi
35677        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35678$as_echo "$tool_specified" >&6; }
35679      fi
35680    fi
35681  fi
35682
35683
35684
35685  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35686
35687  # First separate the path from the arguments. This will split at the first
35688  # space.
35689  complete="$GNM"
35690  path="${complete%% *}"
35691  tmp="$complete EOL"
35692  arguments="${tmp#* }"
35693
35694  # Input might be given as Windows format, start by converting to
35695  # unix format.
35696  new_path=`$CYGPATH -u "$path"`
35697
35698  # Now try to locate executable using which
35699  new_path=`$WHICH "$new_path" 2> /dev/null`
35700  # bat and cmd files are not always considered executable in cygwin causing which
35701  # to not find them
35702  if test "x$new_path" = x \
35703      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35704      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35705    new_path=`$CYGPATH -u "$path"`
35706  fi
35707  if test "x$new_path" = x; then
35708    # Oops. Which didn't find the executable.
35709    # The splitting of arguments from the executable at a space might have been incorrect,
35710    # since paths with space are more likely in Windows. Give it another try with the whole
35711    # argument.
35712    path="$complete"
35713    arguments="EOL"
35714    new_path=`$CYGPATH -u "$path"`
35715    new_path=`$WHICH "$new_path" 2> /dev/null`
35716    # bat and cmd files are not always considered executable in cygwin causing which
35717    # to not find them
35718    if test "x$new_path" = x \
35719        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35720        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35721      new_path=`$CYGPATH -u "$path"`
35722    fi
35723    if test "x$new_path" = x; then
35724      # It's still not found. Now this is an unrecoverable error.
35725      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35726$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35727      has_space=`$ECHO "$complete" | $GREP " "`
35728      if test "x$has_space" != x; then
35729        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35730$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35731      fi
35732      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35733    fi
35734  fi
35735
35736  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35737  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35738  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35739  # "foo.exe" is OK but "foo" is an error.
35740  #
35741  # This test is therefore slightly more accurate than "test -f" to check for file presence.
35742  # It is also a way to make sure we got the proper file name for the real test later on.
35743  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35744  if test "x$test_shortpath" = x; then
35745    # Short path failed, file does not exist as specified.
35746    # Try adding .exe or .cmd
35747    if test -f "${new_path}.exe"; then
35748      input_to_shortpath="${new_path}.exe"
35749    elif test -f "${new_path}.cmd"; then
35750      input_to_shortpath="${new_path}.cmd"
35751    else
35752      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
35753$as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
35754      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35755$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35756      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35757    fi
35758  else
35759    input_to_shortpath="$new_path"
35760  fi
35761
35762  # Call helper function which possibly converts this using DOS-style short mode.
35763  # If so, the updated path is stored in $new_path.
35764  new_path="$input_to_shortpath"
35765
35766  input_path="$input_to_shortpath"
35767  # Check if we need to convert this using DOS-style short mode. If the path
35768  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35769  # take no chances and rewrite it.
35770  # Note: m4 eats our [], so we need to use [ and ] instead.
35771  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35772  if test "x$has_forbidden_chars" != x; then
35773    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35774    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35775    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35776    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35777      # Going to short mode and back again did indeed matter. Since short mode is
35778      # case insensitive, let's make it lowercase to improve readability.
35779      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35780      # Now convert it back to Unix-stile (cygpath)
35781      input_path=`$CYGPATH -u "$shortmode_path"`
35782      new_path="$input_path"
35783    fi
35784  fi
35785
35786  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35787  if test "x$test_cygdrive_prefix" = x; then
35788    # As a simple fix, exclude /usr/bin since it's not a real path.
35789    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35790      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35791      # a path prefixed by /cygdrive for fixpath to work.
35792      new_path="$CYGWIN_ROOT_PATH$input_path"
35793    fi
35794  fi
35795
35796  # remove trailing .exe if any
35797  new_path="${new_path/%.exe/}"
35798
35799  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35800
35801  # First separate the path from the arguments. This will split at the first
35802  # space.
35803  complete="$GNM"
35804  path="${complete%% *}"
35805  tmp="$complete EOL"
35806  arguments="${tmp#* }"
35807
35808  # Input might be given as Windows format, start by converting to
35809  # unix format.
35810  new_path="$path"
35811
35812  windows_path="$new_path"
35813  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35814    unix_path=`$CYGPATH -u "$windows_path"`
35815    new_path="$unix_path"
35816  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35817    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35818    new_path="$unix_path"
35819  fi
35820
35821
35822  # Now try to locate executable using which
35823  new_path=`$WHICH "$new_path" 2> /dev/null`
35824
35825  if test "x$new_path" = x; then
35826    # Oops. Which didn't find the executable.
35827    # The splitting of arguments from the executable at a space might have been incorrect,
35828    # since paths with space are more likely in Windows. Give it another try with the whole
35829    # argument.
35830    path="$complete"
35831    arguments="EOL"
35832    new_path="$path"
35833
35834  windows_path="$new_path"
35835  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35836    unix_path=`$CYGPATH -u "$windows_path"`
35837    new_path="$unix_path"
35838  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35839    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35840    new_path="$unix_path"
35841  fi
35842
35843
35844    new_path=`$WHICH "$new_path" 2> /dev/null`
35845
35846    if test "x$new_path" = x; then
35847      # It's still not found. Now this is an unrecoverable error.
35848      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35849$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35850      has_space=`$ECHO "$complete" | $GREP " "`
35851      if test "x$has_space" != x; then
35852        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35853$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35854      fi
35855      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35856    fi
35857  fi
35858
35859  # Now new_path has a complete unix path to the binary
35860  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35861    # Keep paths in /bin as-is, but remove trailing .exe if any
35862    new_path="${new_path/%.exe/}"
35863    # Do not save /bin paths to all_fixpath_prefixes!
35864  else
35865    # Not in mixed or Windows style, start by that.
35866    new_path=`cmd //c echo $new_path`
35867
35868  input_path="$new_path"
35869  # Check if we need to convert this using DOS-style short mode. If the path
35870  # contains just simple characters, use it. Otherwise (spaces, weird characters),
35871  # take no chances and rewrite it.
35872  # Note: m4 eats our [], so we need to use [ and ] instead.
35873  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35874  if test "x$has_forbidden_chars" != x; then
35875    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35876    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35877  fi
35878
35879    # Output is in $new_path
35880
35881  windows_path="$new_path"
35882  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35883    unix_path=`$CYGPATH -u "$windows_path"`
35884    new_path="$unix_path"
35885  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35886    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35887    new_path="$unix_path"
35888  fi
35889
35890    # remove trailing .exe if any
35891    new_path="${new_path/%.exe/}"
35892
35893    # Save the first 10 bytes of this path to the storage, so fixpath can work.
35894    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35895  fi
35896
35897  else
35898    # We're on a posix platform. Hooray! :)
35899    # First separate the path from the arguments. This will split at the first
35900    # space.
35901    complete="$GNM"
35902    path="${complete%% *}"
35903    tmp="$complete EOL"
35904    arguments="${tmp#* }"
35905
35906    # Cannot rely on the command "which" here since it doesn't always work.
35907    is_absolute_path=`$ECHO "$path" | $GREP ^/`
35908    if test -z "$is_absolute_path"; then
35909      # Path to executable is not absolute. Find it.
35910      IFS_save="$IFS"
35911      IFS=:
35912      for p in $PATH; do
35913        if test -f "$p/$path" && test -x "$p/$path"; then
35914          new_path="$p/$path"
35915          break
35916        fi
35917      done
35918      IFS="$IFS_save"
35919    else
35920      # This is an absolute path, we can use it without further modifications.
35921      new_path="$path"
35922    fi
35923
35924    if test "x$new_path" = x; then
35925      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
35926$as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
35927      has_space=`$ECHO "$complete" | $GREP " "`
35928      if test "x$has_space" != x; then
35929        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35930$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35931      fi
35932      as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
35933    fi
35934  fi
35935
35936  # Now join together the path and the arguments once again
35937  if test "x$arguments" != xEOL; then
35938    new_complete="$new_path ${arguments% *}"
35939  else
35940    new_complete="$new_path"
35941  fi
35942
35943  if test "x$complete" != "x$new_complete"; then
35944    GNM="$new_complete"
35945    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
35946$as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
35947  fi
35948
35949
35950
35951
35952  # Publish this variable in the help.
35953
35954
35955  if test "x$MCS" = x; then
35956    # The variable is not set by user, try to locate tool using the code snippet
35957    for ac_prog in mcs
35958do
35959  # Extract the first word of "$ac_prog", so it can be a program name with args.
35960set dummy $ac_prog; ac_word=$2
35961{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35962$as_echo_n "checking for $ac_word... " >&6; }
35963if ${ac_cv_path_MCS+:} false; then :
35964  $as_echo_n "(cached) " >&6
35965else
35966  case $MCS in
35967  [\\/]* | ?:[\\/]*)
35968  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
35969  ;;
35970  *)
35971  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35972for as_dir in $PATH
35973do
35974  IFS=$as_save_IFS
35975  test -z "$as_dir" && as_dir=.
35976    for ac_exec_ext in '' $ac_executable_extensions; do
35977  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35978    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
35979    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35980    break 2
35981  fi
35982done
35983  done
35984IFS=$as_save_IFS
35985
35986  ;;
35987esac
35988fi
35989MCS=$ac_cv_path_MCS
35990if test -n "$MCS"; then
35991  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
35992$as_echo "$MCS" >&6; }
35993else
35994  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35995$as_echo "no" >&6; }
35996fi
35997
35998
35999  test -n "$MCS" && break
36000done
36001
36002  else
36003    # The variable is set, but is it from the command line or the environment?
36004
36005    # Try to remove the string !MCS! from our list.
36006    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
36007    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36008      # If it failed, the variable was not from the command line. Ignore it,
36009      # but warn the user (except for BASH, which is always set by the calling BASH).
36010      if test "xMCS" != xBASH; then
36011        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
36012$as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
36013      fi
36014      # Try to locate tool using the code snippet
36015      for ac_prog in mcs
36016do
36017  # Extract the first word of "$ac_prog", so it can be a program name with args.
36018set dummy $ac_prog; ac_word=$2
36019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36020$as_echo_n "checking for $ac_word... " >&6; }
36021if ${ac_cv_path_MCS+:} false; then :
36022  $as_echo_n "(cached) " >&6
36023else
36024  case $MCS in
36025  [\\/]* | ?:[\\/]*)
36026  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36027  ;;
36028  *)
36029  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36030for as_dir in $PATH
36031do
36032  IFS=$as_save_IFS
36033  test -z "$as_dir" && as_dir=.
36034    for ac_exec_ext in '' $ac_executable_extensions; do
36035  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36036    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36037    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36038    break 2
36039  fi
36040done
36041  done
36042IFS=$as_save_IFS
36043
36044  ;;
36045esac
36046fi
36047MCS=$ac_cv_path_MCS
36048if test -n "$MCS"; then
36049  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36050$as_echo "$MCS" >&6; }
36051else
36052  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36053$as_echo "no" >&6; }
36054fi
36055
36056
36057  test -n "$MCS" && break
36058done
36059
36060    else
36061      # If it succeeded, then it was overridden by the user. We will use it
36062      # for the tool.
36063
36064      # First remove it from the list of overridden variables, so we can test
36065      # for unknown variables in the end.
36066      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36067
36068      # Check if the provided tool contains a complete path.
36069      tool_specified="$MCS"
36070      tool_basename="${tool_specified##*/}"
36071      if test "x$tool_basename" = "x$tool_specified"; then
36072        # A command without a complete path is provided, search $PATH.
36073        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
36074$as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
36075        # Extract the first word of "$tool_basename", so it can be a program name with args.
36076set dummy $tool_basename; ac_word=$2
36077{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36078$as_echo_n "checking for $ac_word... " >&6; }
36079if ${ac_cv_path_MCS+:} false; then :
36080  $as_echo_n "(cached) " >&6
36081else
36082  case $MCS in
36083  [\\/]* | ?:[\\/]*)
36084  ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36085  ;;
36086  *)
36087  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36088for as_dir in $PATH
36089do
36090  IFS=$as_save_IFS
36091  test -z "$as_dir" && as_dir=.
36092    for ac_exec_ext in '' $ac_executable_extensions; do
36093  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36094    ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36095    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36096    break 2
36097  fi
36098done
36099  done
36100IFS=$as_save_IFS
36101
36102  ;;
36103esac
36104fi
36105MCS=$ac_cv_path_MCS
36106if test -n "$MCS"; then
36107  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36108$as_echo "$MCS" >&6; }
36109else
36110  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36111$as_echo "no" >&6; }
36112fi
36113
36114
36115        if test "x$MCS" = x; then
36116          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36117        fi
36118      else
36119        # Otherwise we believe it is a complete path. Use it as it is.
36120        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
36121$as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
36122        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
36123$as_echo_n "checking for MCS... " >&6; }
36124        if test ! -x "$tool_specified"; then
36125          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36126$as_echo "not found" >&6; }
36127          as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
36128        fi
36129        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36130$as_echo "$tool_specified" >&6; }
36131      fi
36132    fi
36133  fi
36134
36135
36136
36137  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36138
36139  # First separate the path from the arguments. This will split at the first
36140  # space.
36141  complete="$MCS"
36142  path="${complete%% *}"
36143  tmp="$complete EOL"
36144  arguments="${tmp#* }"
36145
36146  # Input might be given as Windows format, start by converting to
36147  # unix format.
36148  new_path=`$CYGPATH -u "$path"`
36149
36150  # Now try to locate executable using which
36151  new_path=`$WHICH "$new_path" 2> /dev/null`
36152  # bat and cmd files are not always considered executable in cygwin causing which
36153  # to not find them
36154  if test "x$new_path" = x \
36155      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36156      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36157    new_path=`$CYGPATH -u "$path"`
36158  fi
36159  if test "x$new_path" = x; then
36160    # Oops. Which didn't find the executable.
36161    # The splitting of arguments from the executable at a space might have been incorrect,
36162    # since paths with space are more likely in Windows. Give it another try with the whole
36163    # argument.
36164    path="$complete"
36165    arguments="EOL"
36166    new_path=`$CYGPATH -u "$path"`
36167    new_path=`$WHICH "$new_path" 2> /dev/null`
36168    # bat and cmd files are not always considered executable in cygwin causing which
36169    # to not find them
36170    if test "x$new_path" = x \
36171        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36172        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36173      new_path=`$CYGPATH -u "$path"`
36174    fi
36175    if test "x$new_path" = x; then
36176      # It's still not found. Now this is an unrecoverable error.
36177      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36178$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36179      has_space=`$ECHO "$complete" | $GREP " "`
36180      if test "x$has_space" != x; then
36181        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36182$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36183      fi
36184      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36185    fi
36186  fi
36187
36188  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36189  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36190  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36191  # "foo.exe" is OK but "foo" is an error.
36192  #
36193  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36194  # It is also a way to make sure we got the proper file name for the real test later on.
36195  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36196  if test "x$test_shortpath" = x; then
36197    # Short path failed, file does not exist as specified.
36198    # Try adding .exe or .cmd
36199    if test -f "${new_path}.exe"; then
36200      input_to_shortpath="${new_path}.exe"
36201    elif test -f "${new_path}.cmd"; then
36202      input_to_shortpath="${new_path}.cmd"
36203    else
36204      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
36205$as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
36206      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36207$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36208      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36209    fi
36210  else
36211    input_to_shortpath="$new_path"
36212  fi
36213
36214  # Call helper function which possibly converts this using DOS-style short mode.
36215  # If so, the updated path is stored in $new_path.
36216  new_path="$input_to_shortpath"
36217
36218  input_path="$input_to_shortpath"
36219  # Check if we need to convert this using DOS-style short mode. If the path
36220  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36221  # take no chances and rewrite it.
36222  # Note: m4 eats our [], so we need to use [ and ] instead.
36223  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36224  if test "x$has_forbidden_chars" != x; then
36225    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36226    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36227    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36228    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36229      # Going to short mode and back again did indeed matter. Since short mode is
36230      # case insensitive, let's make it lowercase to improve readability.
36231      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36232      # Now convert it back to Unix-stile (cygpath)
36233      input_path=`$CYGPATH -u "$shortmode_path"`
36234      new_path="$input_path"
36235    fi
36236  fi
36237
36238  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36239  if test "x$test_cygdrive_prefix" = x; then
36240    # As a simple fix, exclude /usr/bin since it's not a real path.
36241    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36242      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36243      # a path prefixed by /cygdrive for fixpath to work.
36244      new_path="$CYGWIN_ROOT_PATH$input_path"
36245    fi
36246  fi
36247
36248  # remove trailing .exe if any
36249  new_path="${new_path/%.exe/}"
36250
36251  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36252
36253  # First separate the path from the arguments. This will split at the first
36254  # space.
36255  complete="$MCS"
36256  path="${complete%% *}"
36257  tmp="$complete EOL"
36258  arguments="${tmp#* }"
36259
36260  # Input might be given as Windows format, start by converting to
36261  # unix format.
36262  new_path="$path"
36263
36264  windows_path="$new_path"
36265  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36266    unix_path=`$CYGPATH -u "$windows_path"`
36267    new_path="$unix_path"
36268  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36269    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36270    new_path="$unix_path"
36271  fi
36272
36273
36274  # Now try to locate executable using which
36275  new_path=`$WHICH "$new_path" 2> /dev/null`
36276
36277  if test "x$new_path" = x; then
36278    # Oops. Which didn't find the executable.
36279    # The splitting of arguments from the executable at a space might have been incorrect,
36280    # since paths with space are more likely in Windows. Give it another try with the whole
36281    # argument.
36282    path="$complete"
36283    arguments="EOL"
36284    new_path="$path"
36285
36286  windows_path="$new_path"
36287  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36288    unix_path=`$CYGPATH -u "$windows_path"`
36289    new_path="$unix_path"
36290  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36291    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36292    new_path="$unix_path"
36293  fi
36294
36295
36296    new_path=`$WHICH "$new_path" 2> /dev/null`
36297
36298    if test "x$new_path" = x; then
36299      # It's still not found. Now this is an unrecoverable error.
36300      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36301$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36302      has_space=`$ECHO "$complete" | $GREP " "`
36303      if test "x$has_space" != x; then
36304        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36305$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36306      fi
36307      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36308    fi
36309  fi
36310
36311  # Now new_path has a complete unix path to the binary
36312  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36313    # Keep paths in /bin as-is, but remove trailing .exe if any
36314    new_path="${new_path/%.exe/}"
36315    # Do not save /bin paths to all_fixpath_prefixes!
36316  else
36317    # Not in mixed or Windows style, start by that.
36318    new_path=`cmd //c echo $new_path`
36319
36320  input_path="$new_path"
36321  # Check if we need to convert this using DOS-style short mode. If the path
36322  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36323  # take no chances and rewrite it.
36324  # Note: m4 eats our [], so we need to use [ and ] instead.
36325  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36326  if test "x$has_forbidden_chars" != x; then
36327    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36328    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36329  fi
36330
36331    # Output is in $new_path
36332
36333  windows_path="$new_path"
36334  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36335    unix_path=`$CYGPATH -u "$windows_path"`
36336    new_path="$unix_path"
36337  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36338    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36339    new_path="$unix_path"
36340  fi
36341
36342    # remove trailing .exe if any
36343    new_path="${new_path/%.exe/}"
36344
36345    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36346    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36347  fi
36348
36349  else
36350    # We're on a posix platform. Hooray! :)
36351    # First separate the path from the arguments. This will split at the first
36352    # space.
36353    complete="$MCS"
36354    path="${complete%% *}"
36355    tmp="$complete EOL"
36356    arguments="${tmp#* }"
36357
36358    # Cannot rely on the command "which" here since it doesn't always work.
36359    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36360    if test -z "$is_absolute_path"; then
36361      # Path to executable is not absolute. Find it.
36362      IFS_save="$IFS"
36363      IFS=:
36364      for p in $PATH; do
36365        if test -f "$p/$path" && test -x "$p/$path"; then
36366          new_path="$p/$path"
36367          break
36368        fi
36369      done
36370      IFS="$IFS_save"
36371    else
36372      # This is an absolute path, we can use it without further modifications.
36373      new_path="$path"
36374    fi
36375
36376    if test "x$new_path" = x; then
36377      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36378$as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36379      has_space=`$ECHO "$complete" | $GREP " "`
36380      if test "x$has_space" != x; then
36381        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36382$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36383      fi
36384      as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36385    fi
36386  fi
36387
36388  # Now join together the path and the arguments once again
36389  if test "x$arguments" != xEOL; then
36390    new_complete="$new_path ${arguments% *}"
36391  else
36392    new_complete="$new_path"
36393  fi
36394
36395  if test "x$complete" != "x$new_complete"; then
36396    MCS="$new_complete"
36397    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
36398$as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
36399  fi
36400
36401  elif test "x$OPENJDK_TARGET_OS" != xwindows; then
36402    # FIXME: we should unify this with the solaris case above.
36403
36404
36405  # Publish this variable in the help.
36406
36407
36408  if test "x$STRIP" = x; then
36409    # The variable is not set by user, try to locate tool using the code snippet
36410    if test -n "$ac_tool_prefix"; then
36411  for ac_prog in strip
36412  do
36413    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36414set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36416$as_echo_n "checking for $ac_word... " >&6; }
36417if ${ac_cv_prog_STRIP+:} false; then :
36418  $as_echo_n "(cached) " >&6
36419else
36420  if test -n "$STRIP"; then
36421  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36422else
36423as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36424for as_dir in $PATH
36425do
36426  IFS=$as_save_IFS
36427  test -z "$as_dir" && as_dir=.
36428    for ac_exec_ext in '' $ac_executable_extensions; do
36429  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36430    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36431    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36432    break 2
36433  fi
36434done
36435  done
36436IFS=$as_save_IFS
36437
36438fi
36439fi
36440STRIP=$ac_cv_prog_STRIP
36441if test -n "$STRIP"; then
36442  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36443$as_echo "$STRIP" >&6; }
36444else
36445  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36446$as_echo "no" >&6; }
36447fi
36448
36449
36450    test -n "$STRIP" && break
36451  done
36452fi
36453if test -z "$STRIP"; then
36454  ac_ct_STRIP=$STRIP
36455  for ac_prog in strip
36456do
36457  # Extract the first word of "$ac_prog", so it can be a program name with args.
36458set dummy $ac_prog; ac_word=$2
36459{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36460$as_echo_n "checking for $ac_word... " >&6; }
36461if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36462  $as_echo_n "(cached) " >&6
36463else
36464  if test -n "$ac_ct_STRIP"; then
36465  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36466else
36467as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36468for as_dir in $PATH
36469do
36470  IFS=$as_save_IFS
36471  test -z "$as_dir" && as_dir=.
36472    for ac_exec_ext in '' $ac_executable_extensions; do
36473  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36474    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36475    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36476    break 2
36477  fi
36478done
36479  done
36480IFS=$as_save_IFS
36481
36482fi
36483fi
36484ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36485if test -n "$ac_ct_STRIP"; then
36486  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36487$as_echo "$ac_ct_STRIP" >&6; }
36488else
36489  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36490$as_echo "no" >&6; }
36491fi
36492
36493
36494  test -n "$ac_ct_STRIP" && break
36495done
36496
36497  if test "x$ac_ct_STRIP" = x; then
36498    STRIP=""
36499  else
36500    case $cross_compiling:$ac_tool_warned in
36501yes:)
36502{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36503$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36504ac_tool_warned=yes ;;
36505esac
36506    STRIP=$ac_ct_STRIP
36507  fi
36508fi
36509
36510  else
36511    # The variable is set, but is it from the command line or the environment?
36512
36513    # Try to remove the string !STRIP! from our list.
36514    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
36515    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36516      # If it failed, the variable was not from the command line. Ignore it,
36517      # but warn the user (except for BASH, which is always set by the calling BASH).
36518      if test "xSTRIP" != xBASH; then
36519        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
36520$as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
36521      fi
36522      # Try to locate tool using the code snippet
36523      if test -n "$ac_tool_prefix"; then
36524  for ac_prog in strip
36525  do
36526    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36527set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36529$as_echo_n "checking for $ac_word... " >&6; }
36530if ${ac_cv_prog_STRIP+:} false; then :
36531  $as_echo_n "(cached) " >&6
36532else
36533  if test -n "$STRIP"; then
36534  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
36535else
36536as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36537for as_dir in $PATH
36538do
36539  IFS=$as_save_IFS
36540  test -z "$as_dir" && as_dir=.
36541    for ac_exec_ext in '' $ac_executable_extensions; do
36542  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36543    ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
36544    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36545    break 2
36546  fi
36547done
36548  done
36549IFS=$as_save_IFS
36550
36551fi
36552fi
36553STRIP=$ac_cv_prog_STRIP
36554if test -n "$STRIP"; then
36555  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36556$as_echo "$STRIP" >&6; }
36557else
36558  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36559$as_echo "no" >&6; }
36560fi
36561
36562
36563    test -n "$STRIP" && break
36564  done
36565fi
36566if test -z "$STRIP"; then
36567  ac_ct_STRIP=$STRIP
36568  for ac_prog in strip
36569do
36570  # Extract the first word of "$ac_prog", so it can be a program name with args.
36571set dummy $ac_prog; ac_word=$2
36572{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36573$as_echo_n "checking for $ac_word... " >&6; }
36574if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
36575  $as_echo_n "(cached) " >&6
36576else
36577  if test -n "$ac_ct_STRIP"; then
36578  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
36579else
36580as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36581for as_dir in $PATH
36582do
36583  IFS=$as_save_IFS
36584  test -z "$as_dir" && as_dir=.
36585    for ac_exec_ext in '' $ac_executable_extensions; do
36586  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36587    ac_cv_prog_ac_ct_STRIP="$ac_prog"
36588    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36589    break 2
36590  fi
36591done
36592  done
36593IFS=$as_save_IFS
36594
36595fi
36596fi
36597ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
36598if test -n "$ac_ct_STRIP"; then
36599  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
36600$as_echo "$ac_ct_STRIP" >&6; }
36601else
36602  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36603$as_echo "no" >&6; }
36604fi
36605
36606
36607  test -n "$ac_ct_STRIP" && break
36608done
36609
36610  if test "x$ac_ct_STRIP" = x; then
36611    STRIP=""
36612  else
36613    case $cross_compiling:$ac_tool_warned in
36614yes:)
36615{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
36616$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
36617ac_tool_warned=yes ;;
36618esac
36619    STRIP=$ac_ct_STRIP
36620  fi
36621fi
36622
36623    else
36624      # If it succeeded, then it was overridden by the user. We will use it
36625      # for the tool.
36626
36627      # First remove it from the list of overridden variables, so we can test
36628      # for unknown variables in the end.
36629      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36630
36631      # Check if the provided tool contains a complete path.
36632      tool_specified="$STRIP"
36633      tool_basename="${tool_specified##*/}"
36634      if test "x$tool_basename" = "x$tool_specified"; then
36635        # A command without a complete path is provided, search $PATH.
36636        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
36637$as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
36638        # Extract the first word of "$tool_basename", so it can be a program name with args.
36639set dummy $tool_basename; ac_word=$2
36640{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36641$as_echo_n "checking for $ac_word... " >&6; }
36642if ${ac_cv_path_STRIP+:} false; then :
36643  $as_echo_n "(cached) " >&6
36644else
36645  case $STRIP in
36646  [\\/]* | ?:[\\/]*)
36647  ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
36648  ;;
36649  *)
36650  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36651for as_dir in $PATH
36652do
36653  IFS=$as_save_IFS
36654  test -z "$as_dir" && as_dir=.
36655    for ac_exec_ext in '' $ac_executable_extensions; do
36656  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36657    ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
36658    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36659    break 2
36660  fi
36661done
36662  done
36663IFS=$as_save_IFS
36664
36665  ;;
36666esac
36667fi
36668STRIP=$ac_cv_path_STRIP
36669if test -n "$STRIP"; then
36670  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
36671$as_echo "$STRIP" >&6; }
36672else
36673  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36674$as_echo "no" >&6; }
36675fi
36676
36677
36678        if test "x$STRIP" = x; then
36679          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36680        fi
36681      else
36682        # Otherwise we believe it is a complete path. Use it as it is.
36683        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
36684$as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
36685        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
36686$as_echo_n "checking for STRIP... " >&6; }
36687        if test ! -x "$tool_specified"; then
36688          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36689$as_echo "not found" >&6; }
36690          as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
36691        fi
36692        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36693$as_echo "$tool_specified" >&6; }
36694      fi
36695    fi
36696  fi
36697
36698
36699
36700  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36701
36702  # First separate the path from the arguments. This will split at the first
36703  # space.
36704  complete="$STRIP"
36705  path="${complete%% *}"
36706  tmp="$complete EOL"
36707  arguments="${tmp#* }"
36708
36709  # Input might be given as Windows format, start by converting to
36710  # unix format.
36711  new_path=`$CYGPATH -u "$path"`
36712
36713  # Now try to locate executable using which
36714  new_path=`$WHICH "$new_path" 2> /dev/null`
36715  # bat and cmd files are not always considered executable in cygwin causing which
36716  # to not find them
36717  if test "x$new_path" = x \
36718      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36719      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36720    new_path=`$CYGPATH -u "$path"`
36721  fi
36722  if test "x$new_path" = x; then
36723    # Oops. Which didn't find the executable.
36724    # The splitting of arguments from the executable at a space might have been incorrect,
36725    # since paths with space are more likely in Windows. Give it another try with the whole
36726    # argument.
36727    path="$complete"
36728    arguments="EOL"
36729    new_path=`$CYGPATH -u "$path"`
36730    new_path=`$WHICH "$new_path" 2> /dev/null`
36731    # bat and cmd files are not always considered executable in cygwin causing which
36732    # to not find them
36733    if test "x$new_path" = x \
36734        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36735        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36736      new_path=`$CYGPATH -u "$path"`
36737    fi
36738    if test "x$new_path" = x; then
36739      # It's still not found. Now this is an unrecoverable error.
36740      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36741$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36742      has_space=`$ECHO "$complete" | $GREP " "`
36743      if test "x$has_space" != x; then
36744        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36745$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36746      fi
36747      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36748    fi
36749  fi
36750
36751  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36752  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36753  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36754  # "foo.exe" is OK but "foo" is an error.
36755  #
36756  # This test is therefore slightly more accurate than "test -f" to check for file presence.
36757  # It is also a way to make sure we got the proper file name for the real test later on.
36758  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36759  if test "x$test_shortpath" = x; then
36760    # Short path failed, file does not exist as specified.
36761    # Try adding .exe or .cmd
36762    if test -f "${new_path}.exe"; then
36763      input_to_shortpath="${new_path}.exe"
36764    elif test -f "${new_path}.cmd"; then
36765      input_to_shortpath="${new_path}.cmd"
36766    else
36767      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
36768$as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
36769      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36770$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36771      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36772    fi
36773  else
36774    input_to_shortpath="$new_path"
36775  fi
36776
36777  # Call helper function which possibly converts this using DOS-style short mode.
36778  # If so, the updated path is stored in $new_path.
36779  new_path="$input_to_shortpath"
36780
36781  input_path="$input_to_shortpath"
36782  # Check if we need to convert this using DOS-style short mode. If the path
36783  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36784  # take no chances and rewrite it.
36785  # Note: m4 eats our [], so we need to use [ and ] instead.
36786  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36787  if test "x$has_forbidden_chars" != x; then
36788    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36789    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36790    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36791    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36792      # Going to short mode and back again did indeed matter. Since short mode is
36793      # case insensitive, let's make it lowercase to improve readability.
36794      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36795      # Now convert it back to Unix-stile (cygpath)
36796      input_path=`$CYGPATH -u "$shortmode_path"`
36797      new_path="$input_path"
36798    fi
36799  fi
36800
36801  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36802  if test "x$test_cygdrive_prefix" = x; then
36803    # As a simple fix, exclude /usr/bin since it's not a real path.
36804    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36805      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36806      # a path prefixed by /cygdrive for fixpath to work.
36807      new_path="$CYGWIN_ROOT_PATH$input_path"
36808    fi
36809  fi
36810
36811  # remove trailing .exe if any
36812  new_path="${new_path/%.exe/}"
36813
36814  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36815
36816  # First separate the path from the arguments. This will split at the first
36817  # space.
36818  complete="$STRIP"
36819  path="${complete%% *}"
36820  tmp="$complete EOL"
36821  arguments="${tmp#* }"
36822
36823  # Input might be given as Windows format, start by converting to
36824  # unix format.
36825  new_path="$path"
36826
36827  windows_path="$new_path"
36828  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36829    unix_path=`$CYGPATH -u "$windows_path"`
36830    new_path="$unix_path"
36831  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36832    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36833    new_path="$unix_path"
36834  fi
36835
36836
36837  # Now try to locate executable using which
36838  new_path=`$WHICH "$new_path" 2> /dev/null`
36839
36840  if test "x$new_path" = x; then
36841    # Oops. Which didn't find the executable.
36842    # The splitting of arguments from the executable at a space might have been incorrect,
36843    # since paths with space are more likely in Windows. Give it another try with the whole
36844    # argument.
36845    path="$complete"
36846    arguments="EOL"
36847    new_path="$path"
36848
36849  windows_path="$new_path"
36850  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36851    unix_path=`$CYGPATH -u "$windows_path"`
36852    new_path="$unix_path"
36853  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36854    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36855    new_path="$unix_path"
36856  fi
36857
36858
36859    new_path=`$WHICH "$new_path" 2> /dev/null`
36860
36861    if test "x$new_path" = x; then
36862      # It's still not found. Now this is an unrecoverable error.
36863      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36864$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36865      has_space=`$ECHO "$complete" | $GREP " "`
36866      if test "x$has_space" != x; then
36867        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36868$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36869      fi
36870      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36871    fi
36872  fi
36873
36874  # Now new_path has a complete unix path to the binary
36875  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36876    # Keep paths in /bin as-is, but remove trailing .exe if any
36877    new_path="${new_path/%.exe/}"
36878    # Do not save /bin paths to all_fixpath_prefixes!
36879  else
36880    # Not in mixed or Windows style, start by that.
36881    new_path=`cmd //c echo $new_path`
36882
36883  input_path="$new_path"
36884  # Check if we need to convert this using DOS-style short mode. If the path
36885  # contains just simple characters, use it. Otherwise (spaces, weird characters),
36886  # take no chances and rewrite it.
36887  # Note: m4 eats our [], so we need to use [ and ] instead.
36888  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36889  if test "x$has_forbidden_chars" != x; then
36890    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36891    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36892  fi
36893
36894    # Output is in $new_path
36895
36896  windows_path="$new_path"
36897  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36898    unix_path=`$CYGPATH -u "$windows_path"`
36899    new_path="$unix_path"
36900  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36901    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36902    new_path="$unix_path"
36903  fi
36904
36905    # remove trailing .exe if any
36906    new_path="${new_path/%.exe/}"
36907
36908    # Save the first 10 bytes of this path to the storage, so fixpath can work.
36909    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36910  fi
36911
36912  else
36913    # We're on a posix platform. Hooray! :)
36914    # First separate the path from the arguments. This will split at the first
36915    # space.
36916    complete="$STRIP"
36917    path="${complete%% *}"
36918    tmp="$complete EOL"
36919    arguments="${tmp#* }"
36920
36921    # Cannot rely on the command "which" here since it doesn't always work.
36922    is_absolute_path=`$ECHO "$path" | $GREP ^/`
36923    if test -z "$is_absolute_path"; then
36924      # Path to executable is not absolute. Find it.
36925      IFS_save="$IFS"
36926      IFS=:
36927      for p in $PATH; do
36928        if test -f "$p/$path" && test -x "$p/$path"; then
36929          new_path="$p/$path"
36930          break
36931        fi
36932      done
36933      IFS="$IFS_save"
36934    else
36935      # This is an absolute path, we can use it without further modifications.
36936      new_path="$path"
36937    fi
36938
36939    if test "x$new_path" = x; then
36940      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
36941$as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
36942      has_space=`$ECHO "$complete" | $GREP " "`
36943      if test "x$has_space" != x; then
36944        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36945$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36946      fi
36947      as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
36948    fi
36949  fi
36950
36951  # Now join together the path and the arguments once again
36952  if test "x$arguments" != xEOL; then
36953    new_complete="$new_path ${arguments% *}"
36954  else
36955    new_complete="$new_path"
36956  fi
36957
36958  if test "x$complete" != "x$new_complete"; then
36959    STRIP="$new_complete"
36960    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
36961$as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
36962  fi
36963
36964
36965
36966  # Publish this variable in the help.
36967
36968
36969  if test "x$NM" = x; then
36970    # The variable is not set by user, try to locate tool using the code snippet
36971    if test -n "$ac_tool_prefix"; then
36972  for ac_prog in nm
36973  do
36974    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
36975set dummy $ac_tool_prefix$ac_prog; ac_word=$2
36976{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36977$as_echo_n "checking for $ac_word... " >&6; }
36978if ${ac_cv_prog_NM+:} false; then :
36979  $as_echo_n "(cached) " >&6
36980else
36981  if test -n "$NM"; then
36982  ac_cv_prog_NM="$NM" # Let the user override the test.
36983else
36984as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36985for as_dir in $PATH
36986do
36987  IFS=$as_save_IFS
36988  test -z "$as_dir" && as_dir=.
36989    for ac_exec_ext in '' $ac_executable_extensions; do
36990  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36991    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
36992    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36993    break 2
36994  fi
36995done
36996  done
36997IFS=$as_save_IFS
36998
36999fi
37000fi
37001NM=$ac_cv_prog_NM
37002if test -n "$NM"; then
37003  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37004$as_echo "$NM" >&6; }
37005else
37006  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37007$as_echo "no" >&6; }
37008fi
37009
37010
37011    test -n "$NM" && break
37012  done
37013fi
37014if test -z "$NM"; then
37015  ac_ct_NM=$NM
37016  for ac_prog in nm
37017do
37018  # Extract the first word of "$ac_prog", so it can be a program name with args.
37019set dummy $ac_prog; ac_word=$2
37020{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37021$as_echo_n "checking for $ac_word... " >&6; }
37022if ${ac_cv_prog_ac_ct_NM+:} false; then :
37023  $as_echo_n "(cached) " >&6
37024else
37025  if test -n "$ac_ct_NM"; then
37026  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37027else
37028as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37029for as_dir in $PATH
37030do
37031  IFS=$as_save_IFS
37032  test -z "$as_dir" && as_dir=.
37033    for ac_exec_ext in '' $ac_executable_extensions; do
37034  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37035    ac_cv_prog_ac_ct_NM="$ac_prog"
37036    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37037    break 2
37038  fi
37039done
37040  done
37041IFS=$as_save_IFS
37042
37043fi
37044fi
37045ac_ct_NM=$ac_cv_prog_ac_ct_NM
37046if test -n "$ac_ct_NM"; then
37047  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37048$as_echo "$ac_ct_NM" >&6; }
37049else
37050  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37051$as_echo "no" >&6; }
37052fi
37053
37054
37055  test -n "$ac_ct_NM" && break
37056done
37057
37058  if test "x$ac_ct_NM" = x; then
37059    NM=""
37060  else
37061    case $cross_compiling:$ac_tool_warned in
37062yes:)
37063{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37064$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37065ac_tool_warned=yes ;;
37066esac
37067    NM=$ac_ct_NM
37068  fi
37069fi
37070
37071  else
37072    # The variable is set, but is it from the command line or the environment?
37073
37074    # Try to remove the string !NM! from our list.
37075    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
37076    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37077      # If it failed, the variable was not from the command line. Ignore it,
37078      # but warn the user (except for BASH, which is always set by the calling BASH).
37079      if test "xNM" != xBASH; then
37080        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
37081$as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
37082      fi
37083      # Try to locate tool using the code snippet
37084      if test -n "$ac_tool_prefix"; then
37085  for ac_prog in nm
37086  do
37087    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37088set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37089{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37090$as_echo_n "checking for $ac_word... " >&6; }
37091if ${ac_cv_prog_NM+:} false; then :
37092  $as_echo_n "(cached) " >&6
37093else
37094  if test -n "$NM"; then
37095  ac_cv_prog_NM="$NM" # Let the user override the test.
37096else
37097as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37098for as_dir in $PATH
37099do
37100  IFS=$as_save_IFS
37101  test -z "$as_dir" && as_dir=.
37102    for ac_exec_ext in '' $ac_executable_extensions; do
37103  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37104    ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37105    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37106    break 2
37107  fi
37108done
37109  done
37110IFS=$as_save_IFS
37111
37112fi
37113fi
37114NM=$ac_cv_prog_NM
37115if test -n "$NM"; then
37116  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37117$as_echo "$NM" >&6; }
37118else
37119  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37120$as_echo "no" >&6; }
37121fi
37122
37123
37124    test -n "$NM" && break
37125  done
37126fi
37127if test -z "$NM"; then
37128  ac_ct_NM=$NM
37129  for ac_prog in nm
37130do
37131  # Extract the first word of "$ac_prog", so it can be a program name with args.
37132set dummy $ac_prog; ac_word=$2
37133{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37134$as_echo_n "checking for $ac_word... " >&6; }
37135if ${ac_cv_prog_ac_ct_NM+:} false; then :
37136  $as_echo_n "(cached) " >&6
37137else
37138  if test -n "$ac_ct_NM"; then
37139  ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37140else
37141as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37142for as_dir in $PATH
37143do
37144  IFS=$as_save_IFS
37145  test -z "$as_dir" && as_dir=.
37146    for ac_exec_ext in '' $ac_executable_extensions; do
37147  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37148    ac_cv_prog_ac_ct_NM="$ac_prog"
37149    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37150    break 2
37151  fi
37152done
37153  done
37154IFS=$as_save_IFS
37155
37156fi
37157fi
37158ac_ct_NM=$ac_cv_prog_ac_ct_NM
37159if test -n "$ac_ct_NM"; then
37160  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37161$as_echo "$ac_ct_NM" >&6; }
37162else
37163  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37164$as_echo "no" >&6; }
37165fi
37166
37167
37168  test -n "$ac_ct_NM" && break
37169done
37170
37171  if test "x$ac_ct_NM" = x; then
37172    NM=""
37173  else
37174    case $cross_compiling:$ac_tool_warned in
37175yes:)
37176{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37177$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37178ac_tool_warned=yes ;;
37179esac
37180    NM=$ac_ct_NM
37181  fi
37182fi
37183
37184    else
37185      # If it succeeded, then it was overridden by the user. We will use it
37186      # for the tool.
37187
37188      # First remove it from the list of overridden variables, so we can test
37189      # for unknown variables in the end.
37190      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37191
37192      # Check if the provided tool contains a complete path.
37193      tool_specified="$NM"
37194      tool_basename="${tool_specified##*/}"
37195      if test "x$tool_basename" = "x$tool_specified"; then
37196        # A command without a complete path is provided, search $PATH.
37197        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
37198$as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
37199        # Extract the first word of "$tool_basename", so it can be a program name with args.
37200set dummy $tool_basename; ac_word=$2
37201{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37202$as_echo_n "checking for $ac_word... " >&6; }
37203if ${ac_cv_path_NM+:} false; then :
37204  $as_echo_n "(cached) " >&6
37205else
37206  case $NM in
37207  [\\/]* | ?:[\\/]*)
37208  ac_cv_path_NM="$NM" # Let the user override the test with a path.
37209  ;;
37210  *)
37211  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37212for as_dir in $PATH
37213do
37214  IFS=$as_save_IFS
37215  test -z "$as_dir" && as_dir=.
37216    for ac_exec_ext in '' $ac_executable_extensions; do
37217  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37218    ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
37219    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37220    break 2
37221  fi
37222done
37223  done
37224IFS=$as_save_IFS
37225
37226  ;;
37227esac
37228fi
37229NM=$ac_cv_path_NM
37230if test -n "$NM"; then
37231  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37232$as_echo "$NM" >&6; }
37233else
37234  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37235$as_echo "no" >&6; }
37236fi
37237
37238
37239        if test "x$NM" = x; then
37240          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37241        fi
37242      else
37243        # Otherwise we believe it is a complete path. Use it as it is.
37244        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
37245$as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
37246        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
37247$as_echo_n "checking for NM... " >&6; }
37248        if test ! -x "$tool_specified"; then
37249          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37250$as_echo "not found" >&6; }
37251          as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
37252        fi
37253        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37254$as_echo "$tool_specified" >&6; }
37255      fi
37256    fi
37257  fi
37258
37259
37260
37261  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37262
37263  # First separate the path from the arguments. This will split at the first
37264  # space.
37265  complete="$NM"
37266  path="${complete%% *}"
37267  tmp="$complete EOL"
37268  arguments="${tmp#* }"
37269
37270  # Input might be given as Windows format, start by converting to
37271  # unix format.
37272  new_path=`$CYGPATH -u "$path"`
37273
37274  # Now try to locate executable using which
37275  new_path=`$WHICH "$new_path" 2> /dev/null`
37276  # bat and cmd files are not always considered executable in cygwin causing which
37277  # to not find them
37278  if test "x$new_path" = x \
37279      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37280      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37281    new_path=`$CYGPATH -u "$path"`
37282  fi
37283  if test "x$new_path" = x; then
37284    # Oops. Which didn't find the executable.
37285    # The splitting of arguments from the executable at a space might have been incorrect,
37286    # since paths with space are more likely in Windows. Give it another try with the whole
37287    # argument.
37288    path="$complete"
37289    arguments="EOL"
37290    new_path=`$CYGPATH -u "$path"`
37291    new_path=`$WHICH "$new_path" 2> /dev/null`
37292    # bat and cmd files are not always considered executable in cygwin causing which
37293    # to not find them
37294    if test "x$new_path" = x \
37295        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37296        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37297      new_path=`$CYGPATH -u "$path"`
37298    fi
37299    if test "x$new_path" = x; then
37300      # It's still not found. Now this is an unrecoverable error.
37301      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37302$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37303      has_space=`$ECHO "$complete" | $GREP " "`
37304      if test "x$has_space" != x; then
37305        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37306$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37307      fi
37308      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37309    fi
37310  fi
37311
37312  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37313  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37314  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37315  # "foo.exe" is OK but "foo" is an error.
37316  #
37317  # This test is therefore slightly more accurate than "test -f" to check for file presence.
37318  # It is also a way to make sure we got the proper file name for the real test later on.
37319  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37320  if test "x$test_shortpath" = x; then
37321    # Short path failed, file does not exist as specified.
37322    # Try adding .exe or .cmd
37323    if test -f "${new_path}.exe"; then
37324      input_to_shortpath="${new_path}.exe"
37325    elif test -f "${new_path}.cmd"; then
37326      input_to_shortpath="${new_path}.cmd"
37327    else
37328      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
37329$as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
37330      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37331$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37332      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37333    fi
37334  else
37335    input_to_shortpath="$new_path"
37336  fi
37337
37338  # Call helper function which possibly converts this using DOS-style short mode.
37339  # If so, the updated path is stored in $new_path.
37340  new_path="$input_to_shortpath"
37341
37342  input_path="$input_to_shortpath"
37343  # Check if we need to convert this using DOS-style short mode. If the path
37344  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37345  # take no chances and rewrite it.
37346  # Note: m4 eats our [], so we need to use [ and ] instead.
37347  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37348  if test "x$has_forbidden_chars" != x; then
37349    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37350    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37351    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37352    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37353      # Going to short mode and back again did indeed matter. Since short mode is
37354      # case insensitive, let's make it lowercase to improve readability.
37355      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37356      # Now convert it back to Unix-stile (cygpath)
37357      input_path=`$CYGPATH -u "$shortmode_path"`
37358      new_path="$input_path"
37359    fi
37360  fi
37361
37362  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37363  if test "x$test_cygdrive_prefix" = x; then
37364    # As a simple fix, exclude /usr/bin since it's not a real path.
37365    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37366      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37367      # a path prefixed by /cygdrive for fixpath to work.
37368      new_path="$CYGWIN_ROOT_PATH$input_path"
37369    fi
37370  fi
37371
37372  # remove trailing .exe if any
37373  new_path="${new_path/%.exe/}"
37374
37375  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37376
37377  # First separate the path from the arguments. This will split at the first
37378  # space.
37379  complete="$NM"
37380  path="${complete%% *}"
37381  tmp="$complete EOL"
37382  arguments="${tmp#* }"
37383
37384  # Input might be given as Windows format, start by converting to
37385  # unix format.
37386  new_path="$path"
37387
37388  windows_path="$new_path"
37389  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37390    unix_path=`$CYGPATH -u "$windows_path"`
37391    new_path="$unix_path"
37392  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37393    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37394    new_path="$unix_path"
37395  fi
37396
37397
37398  # Now try to locate executable using which
37399  new_path=`$WHICH "$new_path" 2> /dev/null`
37400
37401  if test "x$new_path" = x; then
37402    # Oops. Which didn't find the executable.
37403    # The splitting of arguments from the executable at a space might have been incorrect,
37404    # since paths with space are more likely in Windows. Give it another try with the whole
37405    # argument.
37406    path="$complete"
37407    arguments="EOL"
37408    new_path="$path"
37409
37410  windows_path="$new_path"
37411  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37412    unix_path=`$CYGPATH -u "$windows_path"`
37413    new_path="$unix_path"
37414  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37415    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37416    new_path="$unix_path"
37417  fi
37418
37419
37420    new_path=`$WHICH "$new_path" 2> /dev/null`
37421
37422    if test "x$new_path" = x; then
37423      # It's still not found. Now this is an unrecoverable error.
37424      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37425$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37426      has_space=`$ECHO "$complete" | $GREP " "`
37427      if test "x$has_space" != x; then
37428        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37429$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37430      fi
37431      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37432    fi
37433  fi
37434
37435  # Now new_path has a complete unix path to the binary
37436  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37437    # Keep paths in /bin as-is, but remove trailing .exe if any
37438    new_path="${new_path/%.exe/}"
37439    # Do not save /bin paths to all_fixpath_prefixes!
37440  else
37441    # Not in mixed or Windows style, start by that.
37442    new_path=`cmd //c echo $new_path`
37443
37444  input_path="$new_path"
37445  # Check if we need to convert this using DOS-style short mode. If the path
37446  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37447  # take no chances and rewrite it.
37448  # Note: m4 eats our [], so we need to use [ and ] instead.
37449  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37450  if test "x$has_forbidden_chars" != x; then
37451    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37452    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37453  fi
37454
37455    # Output is in $new_path
37456
37457  windows_path="$new_path"
37458  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37459    unix_path=`$CYGPATH -u "$windows_path"`
37460    new_path="$unix_path"
37461  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37462    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37463    new_path="$unix_path"
37464  fi
37465
37466    # remove trailing .exe if any
37467    new_path="${new_path/%.exe/}"
37468
37469    # Save the first 10 bytes of this path to the storage, so fixpath can work.
37470    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37471  fi
37472
37473  else
37474    # We're on a posix platform. Hooray! :)
37475    # First separate the path from the arguments. This will split at the first
37476    # space.
37477    complete="$NM"
37478    path="${complete%% *}"
37479    tmp="$complete EOL"
37480    arguments="${tmp#* }"
37481
37482    # Cannot rely on the command "which" here since it doesn't always work.
37483    is_absolute_path=`$ECHO "$path" | $GREP ^/`
37484    if test -z "$is_absolute_path"; then
37485      # Path to executable is not absolute. Find it.
37486      IFS_save="$IFS"
37487      IFS=:
37488      for p in $PATH; do
37489        if test -f "$p/$path" && test -x "$p/$path"; then
37490          new_path="$p/$path"
37491          break
37492        fi
37493      done
37494      IFS="$IFS_save"
37495    else
37496      # This is an absolute path, we can use it without further modifications.
37497      new_path="$path"
37498    fi
37499
37500    if test "x$new_path" = x; then
37501      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
37502$as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
37503      has_space=`$ECHO "$complete" | $GREP " "`
37504      if test "x$has_space" != x; then
37505        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37506$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37507      fi
37508      as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
37509    fi
37510  fi
37511
37512  # Now join together the path and the arguments once again
37513  if test "x$arguments" != xEOL; then
37514    new_complete="$new_path ${arguments% *}"
37515  else
37516    new_complete="$new_path"
37517  fi
37518
37519  if test "x$complete" != "x$new_complete"; then
37520    NM="$new_complete"
37521    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
37522$as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
37523  fi
37524
37525    GNM="$NM"
37526
37527  fi
37528
37529  # objcopy is used for moving debug symbols to separate files when
37530  # full debug symbols are enabled.
37531  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
37532
37533
37534  # Publish this variable in the help.
37535
37536
37537  if test "x$OBJCOPY" = x; then
37538    # The variable is not set by user, try to locate tool using the code snippet
37539    if test -n "$ac_tool_prefix"; then
37540  for ac_prog in gobjcopy objcopy
37541  do
37542    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37543set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37545$as_echo_n "checking for $ac_word... " >&6; }
37546if ${ac_cv_prog_OBJCOPY+:} false; then :
37547  $as_echo_n "(cached) " >&6
37548else
37549  if test -n "$OBJCOPY"; then
37550  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37551else
37552as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37553for as_dir in $PATH
37554do
37555  IFS=$as_save_IFS
37556  test -z "$as_dir" && as_dir=.
37557    for ac_exec_ext in '' $ac_executable_extensions; do
37558  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37559    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37560    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37561    break 2
37562  fi
37563done
37564  done
37565IFS=$as_save_IFS
37566
37567fi
37568fi
37569OBJCOPY=$ac_cv_prog_OBJCOPY
37570if test -n "$OBJCOPY"; then
37571  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37572$as_echo "$OBJCOPY" >&6; }
37573else
37574  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37575$as_echo "no" >&6; }
37576fi
37577
37578
37579    test -n "$OBJCOPY" && break
37580  done
37581fi
37582if test -z "$OBJCOPY"; then
37583  ac_ct_OBJCOPY=$OBJCOPY
37584  for ac_prog in gobjcopy objcopy
37585do
37586  # Extract the first word of "$ac_prog", so it can be a program name with args.
37587set dummy $ac_prog; ac_word=$2
37588{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37589$as_echo_n "checking for $ac_word... " >&6; }
37590if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37591  $as_echo_n "(cached) " >&6
37592else
37593  if test -n "$ac_ct_OBJCOPY"; then
37594  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37595else
37596as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37597for as_dir in $PATH
37598do
37599  IFS=$as_save_IFS
37600  test -z "$as_dir" && as_dir=.
37601    for ac_exec_ext in '' $ac_executable_extensions; do
37602  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37603    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37604    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37605    break 2
37606  fi
37607done
37608  done
37609IFS=$as_save_IFS
37610
37611fi
37612fi
37613ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37614if test -n "$ac_ct_OBJCOPY"; then
37615  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37616$as_echo "$ac_ct_OBJCOPY" >&6; }
37617else
37618  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37619$as_echo "no" >&6; }
37620fi
37621
37622
37623  test -n "$ac_ct_OBJCOPY" && break
37624done
37625
37626  if test "x$ac_ct_OBJCOPY" = x; then
37627    OBJCOPY=""
37628  else
37629    case $cross_compiling:$ac_tool_warned in
37630yes:)
37631{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37632$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37633ac_tool_warned=yes ;;
37634esac
37635    OBJCOPY=$ac_ct_OBJCOPY
37636  fi
37637fi
37638
37639  else
37640    # The variable is set, but is it from the command line or the environment?
37641
37642    # Try to remove the string !OBJCOPY! from our list.
37643    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
37644    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37645      # If it failed, the variable was not from the command line. Ignore it,
37646      # but warn the user (except for BASH, which is always set by the calling BASH).
37647      if test "xOBJCOPY" != xBASH; then
37648        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
37649$as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
37650      fi
37651      # Try to locate tool using the code snippet
37652      if test -n "$ac_tool_prefix"; then
37653  for ac_prog in gobjcopy objcopy
37654  do
37655    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37656set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37658$as_echo_n "checking for $ac_word... " >&6; }
37659if ${ac_cv_prog_OBJCOPY+:} false; then :
37660  $as_echo_n "(cached) " >&6
37661else
37662  if test -n "$OBJCOPY"; then
37663  ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
37664else
37665as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37666for as_dir in $PATH
37667do
37668  IFS=$as_save_IFS
37669  test -z "$as_dir" && as_dir=.
37670    for ac_exec_ext in '' $ac_executable_extensions; do
37671  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37672    ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
37673    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37674    break 2
37675  fi
37676done
37677  done
37678IFS=$as_save_IFS
37679
37680fi
37681fi
37682OBJCOPY=$ac_cv_prog_OBJCOPY
37683if test -n "$OBJCOPY"; then
37684  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37685$as_echo "$OBJCOPY" >&6; }
37686else
37687  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37688$as_echo "no" >&6; }
37689fi
37690
37691
37692    test -n "$OBJCOPY" && break
37693  done
37694fi
37695if test -z "$OBJCOPY"; then
37696  ac_ct_OBJCOPY=$OBJCOPY
37697  for ac_prog in gobjcopy objcopy
37698do
37699  # Extract the first word of "$ac_prog", so it can be a program name with args.
37700set dummy $ac_prog; ac_word=$2
37701{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37702$as_echo_n "checking for $ac_word... " >&6; }
37703if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
37704  $as_echo_n "(cached) " >&6
37705else
37706  if test -n "$ac_ct_OBJCOPY"; then
37707  ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
37708else
37709as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37710for as_dir in $PATH
37711do
37712  IFS=$as_save_IFS
37713  test -z "$as_dir" && as_dir=.
37714    for ac_exec_ext in '' $ac_executable_extensions; do
37715  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37716    ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
37717    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37718    break 2
37719  fi
37720done
37721  done
37722IFS=$as_save_IFS
37723
37724fi
37725fi
37726ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
37727if test -n "$ac_ct_OBJCOPY"; then
37728  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
37729$as_echo "$ac_ct_OBJCOPY" >&6; }
37730else
37731  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37732$as_echo "no" >&6; }
37733fi
37734
37735
37736  test -n "$ac_ct_OBJCOPY" && break
37737done
37738
37739  if test "x$ac_ct_OBJCOPY" = x; then
37740    OBJCOPY=""
37741  else
37742    case $cross_compiling:$ac_tool_warned in
37743yes:)
37744{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37745$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37746ac_tool_warned=yes ;;
37747esac
37748    OBJCOPY=$ac_ct_OBJCOPY
37749  fi
37750fi
37751
37752    else
37753      # If it succeeded, then it was overridden by the user. We will use it
37754      # for the tool.
37755
37756      # First remove it from the list of overridden variables, so we can test
37757      # for unknown variables in the end.
37758      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37759
37760      # Check if the provided tool contains a complete path.
37761      tool_specified="$OBJCOPY"
37762      tool_basename="${tool_specified##*/}"
37763      if test "x$tool_basename" = "x$tool_specified"; then
37764        # A command without a complete path is provided, search $PATH.
37765        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
37766$as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
37767        # Extract the first word of "$tool_basename", so it can be a program name with args.
37768set dummy $tool_basename; ac_word=$2
37769{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37770$as_echo_n "checking for $ac_word... " >&6; }
37771if ${ac_cv_path_OBJCOPY+:} false; then :
37772  $as_echo_n "(cached) " >&6
37773else
37774  case $OBJCOPY in
37775  [\\/]* | ?:[\\/]*)
37776  ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
37777  ;;
37778  *)
37779  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37780for as_dir in $PATH
37781do
37782  IFS=$as_save_IFS
37783  test -z "$as_dir" && as_dir=.
37784    for ac_exec_ext in '' $ac_executable_extensions; do
37785  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37786    ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
37787    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37788    break 2
37789  fi
37790done
37791  done
37792IFS=$as_save_IFS
37793
37794  ;;
37795esac
37796fi
37797OBJCOPY=$ac_cv_path_OBJCOPY
37798if test -n "$OBJCOPY"; then
37799  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
37800$as_echo "$OBJCOPY" >&6; }
37801else
37802  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37803$as_echo "no" >&6; }
37804fi
37805
37806
37807        if test "x$OBJCOPY" = x; then
37808          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37809        fi
37810      else
37811        # Otherwise we believe it is a complete path. Use it as it is.
37812        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
37813$as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
37814        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
37815$as_echo_n "checking for OBJCOPY... " >&6; }
37816        if test ! -x "$tool_specified"; then
37817          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37818$as_echo "not found" >&6; }
37819          as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
37820        fi
37821        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37822$as_echo "$tool_specified" >&6; }
37823      fi
37824    fi
37825  fi
37826
37827
37828    # Only call fixup if objcopy was found.
37829    if test -n "$OBJCOPY"; then
37830
37831  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37832
37833  # First separate the path from the arguments. This will split at the first
37834  # space.
37835  complete="$OBJCOPY"
37836  path="${complete%% *}"
37837  tmp="$complete EOL"
37838  arguments="${tmp#* }"
37839
37840  # Input might be given as Windows format, start by converting to
37841  # unix format.
37842  new_path=`$CYGPATH -u "$path"`
37843
37844  # Now try to locate executable using which
37845  new_path=`$WHICH "$new_path" 2> /dev/null`
37846  # bat and cmd files are not always considered executable in cygwin causing which
37847  # to not find them
37848  if test "x$new_path" = x \
37849      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37850      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37851    new_path=`$CYGPATH -u "$path"`
37852  fi
37853  if test "x$new_path" = x; then
37854    # Oops. Which didn't find the executable.
37855    # The splitting of arguments from the executable at a space might have been incorrect,
37856    # since paths with space are more likely in Windows. Give it another try with the whole
37857    # argument.
37858    path="$complete"
37859    arguments="EOL"
37860    new_path=`$CYGPATH -u "$path"`
37861    new_path=`$WHICH "$new_path" 2> /dev/null`
37862    # bat and cmd files are not always considered executable in cygwin causing which
37863    # to not find them
37864    if test "x$new_path" = x \
37865        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37866        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37867      new_path=`$CYGPATH -u "$path"`
37868    fi
37869    if test "x$new_path" = x; then
37870      # It's still not found. Now this is an unrecoverable error.
37871      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37872$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37873      has_space=`$ECHO "$complete" | $GREP " "`
37874      if test "x$has_space" != x; then
37875        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37876$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37877      fi
37878      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37879    fi
37880  fi
37881
37882  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37883  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37884  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37885  # "foo.exe" is OK but "foo" is an error.
37886  #
37887  # This test is therefore slightly more accurate than "test -f" to check for file presence.
37888  # It is also a way to make sure we got the proper file name for the real test later on.
37889  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37890  if test "x$test_shortpath" = x; then
37891    # Short path failed, file does not exist as specified.
37892    # Try adding .exe or .cmd
37893    if test -f "${new_path}.exe"; then
37894      input_to_shortpath="${new_path}.exe"
37895    elif test -f "${new_path}.cmd"; then
37896      input_to_shortpath="${new_path}.cmd"
37897    else
37898      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
37899$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
37900      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37901$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37902      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
37903    fi
37904  else
37905    input_to_shortpath="$new_path"
37906  fi
37907
37908  # Call helper function which possibly converts this using DOS-style short mode.
37909  # If so, the updated path is stored in $new_path.
37910  new_path="$input_to_shortpath"
37911
37912  input_path="$input_to_shortpath"
37913  # Check if we need to convert this using DOS-style short mode. If the path
37914  # contains just simple characters, use it. Otherwise (spaces, weird characters),
37915  # take no chances and rewrite it.
37916  # Note: m4 eats our [], so we need to use [ and ] instead.
37917  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37918  if test "x$has_forbidden_chars" != x; then
37919    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37920    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37921    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37922    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37923      # Going to short mode and back again did indeed matter. Since short mode is
37924      # case insensitive, let's make it lowercase to improve readability.
37925      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37926      # Now convert it back to Unix-stile (cygpath)
37927      input_path=`$CYGPATH -u "$shortmode_path"`
37928      new_path="$input_path"
37929    fi
37930  fi
37931
37932  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37933  if test "x$test_cygdrive_prefix" = x; then
37934    # As a simple fix, exclude /usr/bin since it's not a real path.
37935    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37936      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37937      # a path prefixed by /cygdrive for fixpath to work.
37938      new_path="$CYGWIN_ROOT_PATH$input_path"
37939    fi
37940  fi
37941
37942  # remove trailing .exe if any
37943  new_path="${new_path/%.exe/}"
37944
37945  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37946
37947  # First separate the path from the arguments. This will split at the first
37948  # space.
37949  complete="$OBJCOPY"
37950  path="${complete%% *}"
37951  tmp="$complete EOL"
37952  arguments="${tmp#* }"
37953
37954  # Input might be given as Windows format, start by converting to
37955  # unix format.
37956  new_path="$path"
37957
37958  windows_path="$new_path"
37959  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37960    unix_path=`$CYGPATH -u "$windows_path"`
37961    new_path="$unix_path"
37962  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37963    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37964    new_path="$unix_path"
37965  fi
37966
37967
37968  # Now try to locate executable using which
37969  new_path=`$WHICH "$new_path" 2> /dev/null`
37970
37971  if test "x$new_path" = x; then
37972    # Oops. Which didn't find the executable.
37973    # The splitting of arguments from the executable at a space might have been incorrect,
37974    # since paths with space are more likely in Windows. Give it another try with the whole
37975    # argument.
37976    path="$complete"
37977    arguments="EOL"
37978    new_path="$path"
37979
37980  windows_path="$new_path"
37981  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37982    unix_path=`$CYGPATH -u "$windows_path"`
37983    new_path="$unix_path"
37984  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37985    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37986    new_path="$unix_path"
37987  fi
37988
37989
37990    new_path=`$WHICH "$new_path" 2> /dev/null`
37991
37992    if test "x$new_path" = x; then
37993      # It's still not found. Now this is an unrecoverable error.
37994      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
37995$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
37996      has_space=`$ECHO "$complete" | $GREP " "`
37997      if test "x$has_space" != x; then
37998        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37999$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38000      fi
38001      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38002    fi
38003  fi
38004
38005  # Now new_path has a complete unix path to the binary
38006  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38007    # Keep paths in /bin as-is, but remove trailing .exe if any
38008    new_path="${new_path/%.exe/}"
38009    # Do not save /bin paths to all_fixpath_prefixes!
38010  else
38011    # Not in mixed or Windows style, start by that.
38012    new_path=`cmd //c echo $new_path`
38013
38014  input_path="$new_path"
38015  # Check if we need to convert this using DOS-style short mode. If the path
38016  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38017  # take no chances and rewrite it.
38018  # Note: m4 eats our [], so we need to use [ and ] instead.
38019  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38020  if test "x$has_forbidden_chars" != x; then
38021    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38022    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38023  fi
38024
38025    # Output is in $new_path
38026
38027  windows_path="$new_path"
38028  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38029    unix_path=`$CYGPATH -u "$windows_path"`
38030    new_path="$unix_path"
38031  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38032    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38033    new_path="$unix_path"
38034  fi
38035
38036    # remove trailing .exe if any
38037    new_path="${new_path/%.exe/}"
38038
38039    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38040    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38041  fi
38042
38043  else
38044    # We're on a posix platform. Hooray! :)
38045    # First separate the path from the arguments. This will split at the first
38046    # space.
38047    complete="$OBJCOPY"
38048    path="${complete%% *}"
38049    tmp="$complete EOL"
38050    arguments="${tmp#* }"
38051
38052    # Cannot rely on the command "which" here since it doesn't always work.
38053    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38054    if test -z "$is_absolute_path"; then
38055      # Path to executable is not absolute. Find it.
38056      IFS_save="$IFS"
38057      IFS=:
38058      for p in $PATH; do
38059        if test -f "$p/$path" && test -x "$p/$path"; then
38060          new_path="$p/$path"
38061          break
38062        fi
38063      done
38064      IFS="$IFS_save"
38065    else
38066      # This is an absolute path, we can use it without further modifications.
38067      new_path="$path"
38068    fi
38069
38070    if test "x$new_path" = x; then
38071      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38072$as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38073      has_space=`$ECHO "$complete" | $GREP " "`
38074      if test "x$has_space" != x; then
38075        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38076$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38077      fi
38078      as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38079    fi
38080  fi
38081
38082  # Now join together the path and the arguments once again
38083  if test "x$arguments" != xEOL; then
38084    new_complete="$new_path ${arguments% *}"
38085  else
38086    new_complete="$new_path"
38087  fi
38088
38089  if test "x$complete" != "x$new_complete"; then
38090    OBJCOPY="$new_complete"
38091    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
38092$as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
38093  fi
38094
38095    fi
38096  fi
38097
38098
38099
38100  # Publish this variable in the help.
38101
38102
38103  if test "x$OBJDUMP" = x; then
38104    # The variable is not set by user, try to locate tool using the code snippet
38105    if test -n "$ac_tool_prefix"; then
38106  for ac_prog in gobjdump objdump
38107  do
38108    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38109set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38110{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38111$as_echo_n "checking for $ac_word... " >&6; }
38112if ${ac_cv_prog_OBJDUMP+:} false; then :
38113  $as_echo_n "(cached) " >&6
38114else
38115  if test -n "$OBJDUMP"; then
38116  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38117else
38118as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38119for as_dir in $PATH
38120do
38121  IFS=$as_save_IFS
38122  test -z "$as_dir" && as_dir=.
38123    for ac_exec_ext in '' $ac_executable_extensions; do
38124  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38125    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38126    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38127    break 2
38128  fi
38129done
38130  done
38131IFS=$as_save_IFS
38132
38133fi
38134fi
38135OBJDUMP=$ac_cv_prog_OBJDUMP
38136if test -n "$OBJDUMP"; then
38137  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38138$as_echo "$OBJDUMP" >&6; }
38139else
38140  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38141$as_echo "no" >&6; }
38142fi
38143
38144
38145    test -n "$OBJDUMP" && break
38146  done
38147fi
38148if test -z "$OBJDUMP"; then
38149  ac_ct_OBJDUMP=$OBJDUMP
38150  for ac_prog in gobjdump objdump
38151do
38152  # Extract the first word of "$ac_prog", so it can be a program name with args.
38153set dummy $ac_prog; ac_word=$2
38154{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38155$as_echo_n "checking for $ac_word... " >&6; }
38156if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38157  $as_echo_n "(cached) " >&6
38158else
38159  if test -n "$ac_ct_OBJDUMP"; then
38160  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38161else
38162as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38163for as_dir in $PATH
38164do
38165  IFS=$as_save_IFS
38166  test -z "$as_dir" && as_dir=.
38167    for ac_exec_ext in '' $ac_executable_extensions; do
38168  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38169    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38170    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38171    break 2
38172  fi
38173done
38174  done
38175IFS=$as_save_IFS
38176
38177fi
38178fi
38179ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38180if test -n "$ac_ct_OBJDUMP"; then
38181  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38182$as_echo "$ac_ct_OBJDUMP" >&6; }
38183else
38184  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38185$as_echo "no" >&6; }
38186fi
38187
38188
38189  test -n "$ac_ct_OBJDUMP" && break
38190done
38191
38192  if test "x$ac_ct_OBJDUMP" = x; then
38193    OBJDUMP=""
38194  else
38195    case $cross_compiling:$ac_tool_warned in
38196yes:)
38197{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38198$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38199ac_tool_warned=yes ;;
38200esac
38201    OBJDUMP=$ac_ct_OBJDUMP
38202  fi
38203fi
38204
38205  else
38206    # The variable is set, but is it from the command line or the environment?
38207
38208    # Try to remove the string !OBJDUMP! from our list.
38209    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
38210    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38211      # If it failed, the variable was not from the command line. Ignore it,
38212      # but warn the user (except for BASH, which is always set by the calling BASH).
38213      if test "xOBJDUMP" != xBASH; then
38214        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
38215$as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
38216      fi
38217      # Try to locate tool using the code snippet
38218      if test -n "$ac_tool_prefix"; then
38219  for ac_prog in gobjdump objdump
38220  do
38221    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38222set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38223{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38224$as_echo_n "checking for $ac_word... " >&6; }
38225if ${ac_cv_prog_OBJDUMP+:} false; then :
38226  $as_echo_n "(cached) " >&6
38227else
38228  if test -n "$OBJDUMP"; then
38229  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38230else
38231as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38232for as_dir in $PATH
38233do
38234  IFS=$as_save_IFS
38235  test -z "$as_dir" && as_dir=.
38236    for ac_exec_ext in '' $ac_executable_extensions; do
38237  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38238    ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38239    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38240    break 2
38241  fi
38242done
38243  done
38244IFS=$as_save_IFS
38245
38246fi
38247fi
38248OBJDUMP=$ac_cv_prog_OBJDUMP
38249if test -n "$OBJDUMP"; then
38250  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38251$as_echo "$OBJDUMP" >&6; }
38252else
38253  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38254$as_echo "no" >&6; }
38255fi
38256
38257
38258    test -n "$OBJDUMP" && break
38259  done
38260fi
38261if test -z "$OBJDUMP"; then
38262  ac_ct_OBJDUMP=$OBJDUMP
38263  for ac_prog in gobjdump objdump
38264do
38265  # Extract the first word of "$ac_prog", so it can be a program name with args.
38266set dummy $ac_prog; ac_word=$2
38267{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38268$as_echo_n "checking for $ac_word... " >&6; }
38269if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38270  $as_echo_n "(cached) " >&6
38271else
38272  if test -n "$ac_ct_OBJDUMP"; then
38273  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38274else
38275as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38276for as_dir in $PATH
38277do
38278  IFS=$as_save_IFS
38279  test -z "$as_dir" && as_dir=.
38280    for ac_exec_ext in '' $ac_executable_extensions; do
38281  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38282    ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38283    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38284    break 2
38285  fi
38286done
38287  done
38288IFS=$as_save_IFS
38289
38290fi
38291fi
38292ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38293if test -n "$ac_ct_OBJDUMP"; then
38294  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38295$as_echo "$ac_ct_OBJDUMP" >&6; }
38296else
38297  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38298$as_echo "no" >&6; }
38299fi
38300
38301
38302  test -n "$ac_ct_OBJDUMP" && break
38303done
38304
38305  if test "x$ac_ct_OBJDUMP" = x; then
38306    OBJDUMP=""
38307  else
38308    case $cross_compiling:$ac_tool_warned in
38309yes:)
38310{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38311$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38312ac_tool_warned=yes ;;
38313esac
38314    OBJDUMP=$ac_ct_OBJDUMP
38315  fi
38316fi
38317
38318    else
38319      # If it succeeded, then it was overridden by the user. We will use it
38320      # for the tool.
38321
38322      # First remove it from the list of overridden variables, so we can test
38323      # for unknown variables in the end.
38324      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38325
38326      # Check if the provided tool contains a complete path.
38327      tool_specified="$OBJDUMP"
38328      tool_basename="${tool_specified##*/}"
38329      if test "x$tool_basename" = "x$tool_specified"; then
38330        # A command without a complete path is provided, search $PATH.
38331        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
38332$as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
38333        # Extract the first word of "$tool_basename", so it can be a program name with args.
38334set dummy $tool_basename; ac_word=$2
38335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38336$as_echo_n "checking for $ac_word... " >&6; }
38337if ${ac_cv_path_OBJDUMP+:} false; then :
38338  $as_echo_n "(cached) " >&6
38339else
38340  case $OBJDUMP in
38341  [\\/]* | ?:[\\/]*)
38342  ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
38343  ;;
38344  *)
38345  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38346for as_dir in $PATH
38347do
38348  IFS=$as_save_IFS
38349  test -z "$as_dir" && as_dir=.
38350    for ac_exec_ext in '' $ac_executable_extensions; do
38351  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38352    ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
38353    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38354    break 2
38355  fi
38356done
38357  done
38358IFS=$as_save_IFS
38359
38360  ;;
38361esac
38362fi
38363OBJDUMP=$ac_cv_path_OBJDUMP
38364if test -n "$OBJDUMP"; then
38365  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38366$as_echo "$OBJDUMP" >&6; }
38367else
38368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38369$as_echo "no" >&6; }
38370fi
38371
38372
38373        if test "x$OBJDUMP" = x; then
38374          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38375        fi
38376      else
38377        # Otherwise we believe it is a complete path. Use it as it is.
38378        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
38379$as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
38380        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
38381$as_echo_n "checking for OBJDUMP... " >&6; }
38382        if test ! -x "$tool_specified"; then
38383          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38384$as_echo "not found" >&6; }
38385          as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
38386        fi
38387        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38388$as_echo "$tool_specified" >&6; }
38389      fi
38390    fi
38391  fi
38392
38393
38394  if test "x$OBJDUMP" != x; then
38395    # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE
38396    # bails if argument is missing.
38397
38398  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38399
38400  # First separate the path from the arguments. This will split at the first
38401  # space.
38402  complete="$OBJDUMP"
38403  path="${complete%% *}"
38404  tmp="$complete EOL"
38405  arguments="${tmp#* }"
38406
38407  # Input might be given as Windows format, start by converting to
38408  # unix format.
38409  new_path=`$CYGPATH -u "$path"`
38410
38411  # Now try to locate executable using which
38412  new_path=`$WHICH "$new_path" 2> /dev/null`
38413  # bat and cmd files are not always considered executable in cygwin causing which
38414  # to not find them
38415  if test "x$new_path" = x \
38416      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38417      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38418    new_path=`$CYGPATH -u "$path"`
38419  fi
38420  if test "x$new_path" = x; then
38421    # Oops. Which didn't find the executable.
38422    # The splitting of arguments from the executable at a space might have been incorrect,
38423    # since paths with space are more likely in Windows. Give it another try with the whole
38424    # argument.
38425    path="$complete"
38426    arguments="EOL"
38427    new_path=`$CYGPATH -u "$path"`
38428    new_path=`$WHICH "$new_path" 2> /dev/null`
38429    # bat and cmd files are not always considered executable in cygwin causing which
38430    # to not find them
38431    if test "x$new_path" = x \
38432        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38433        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38434      new_path=`$CYGPATH -u "$path"`
38435    fi
38436    if test "x$new_path" = x; then
38437      # It's still not found. Now this is an unrecoverable error.
38438      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38439$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38440      has_space=`$ECHO "$complete" | $GREP " "`
38441      if test "x$has_space" != x; then
38442        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38443$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38444      fi
38445      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38446    fi
38447  fi
38448
38449  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38450  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38451  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38452  # "foo.exe" is OK but "foo" is an error.
38453  #
38454  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38455  # It is also a way to make sure we got the proper file name for the real test later on.
38456  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38457  if test "x$test_shortpath" = x; then
38458    # Short path failed, file does not exist as specified.
38459    # Try adding .exe or .cmd
38460    if test -f "${new_path}.exe"; then
38461      input_to_shortpath="${new_path}.exe"
38462    elif test -f "${new_path}.cmd"; then
38463      input_to_shortpath="${new_path}.cmd"
38464    else
38465      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
38466$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
38467      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38468$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38469      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38470    fi
38471  else
38472    input_to_shortpath="$new_path"
38473  fi
38474
38475  # Call helper function which possibly converts this using DOS-style short mode.
38476  # If so, the updated path is stored in $new_path.
38477  new_path="$input_to_shortpath"
38478
38479  input_path="$input_to_shortpath"
38480  # Check if we need to convert this using DOS-style short mode. If the path
38481  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38482  # take no chances and rewrite it.
38483  # Note: m4 eats our [], so we need to use [ and ] instead.
38484  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38485  if test "x$has_forbidden_chars" != x; then
38486    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38487    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38488    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38489    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38490      # Going to short mode and back again did indeed matter. Since short mode is
38491      # case insensitive, let's make it lowercase to improve readability.
38492      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38493      # Now convert it back to Unix-stile (cygpath)
38494      input_path=`$CYGPATH -u "$shortmode_path"`
38495      new_path="$input_path"
38496    fi
38497  fi
38498
38499  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38500  if test "x$test_cygdrive_prefix" = x; then
38501    # As a simple fix, exclude /usr/bin since it's not a real path.
38502    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38503      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38504      # a path prefixed by /cygdrive for fixpath to work.
38505      new_path="$CYGWIN_ROOT_PATH$input_path"
38506    fi
38507  fi
38508
38509  # remove trailing .exe if any
38510  new_path="${new_path/%.exe/}"
38511
38512  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38513
38514  # First separate the path from the arguments. This will split at the first
38515  # space.
38516  complete="$OBJDUMP"
38517  path="${complete%% *}"
38518  tmp="$complete EOL"
38519  arguments="${tmp#* }"
38520
38521  # Input might be given as Windows format, start by converting to
38522  # unix format.
38523  new_path="$path"
38524
38525  windows_path="$new_path"
38526  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38527    unix_path=`$CYGPATH -u "$windows_path"`
38528    new_path="$unix_path"
38529  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38530    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38531    new_path="$unix_path"
38532  fi
38533
38534
38535  # Now try to locate executable using which
38536  new_path=`$WHICH "$new_path" 2> /dev/null`
38537
38538  if test "x$new_path" = x; then
38539    # Oops. Which didn't find the executable.
38540    # The splitting of arguments from the executable at a space might have been incorrect,
38541    # since paths with space are more likely in Windows. Give it another try with the whole
38542    # argument.
38543    path="$complete"
38544    arguments="EOL"
38545    new_path="$path"
38546
38547  windows_path="$new_path"
38548  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38549    unix_path=`$CYGPATH -u "$windows_path"`
38550    new_path="$unix_path"
38551  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38552    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38553    new_path="$unix_path"
38554  fi
38555
38556
38557    new_path=`$WHICH "$new_path" 2> /dev/null`
38558
38559    if test "x$new_path" = x; then
38560      # It's still not found. Now this is an unrecoverable error.
38561      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38562$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38563      has_space=`$ECHO "$complete" | $GREP " "`
38564      if test "x$has_space" != x; then
38565        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38566$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38567      fi
38568      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38569    fi
38570  fi
38571
38572  # Now new_path has a complete unix path to the binary
38573  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38574    # Keep paths in /bin as-is, but remove trailing .exe if any
38575    new_path="${new_path/%.exe/}"
38576    # Do not save /bin paths to all_fixpath_prefixes!
38577  else
38578    # Not in mixed or Windows style, start by that.
38579    new_path=`cmd //c echo $new_path`
38580
38581  input_path="$new_path"
38582  # Check if we need to convert this using DOS-style short mode. If the path
38583  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38584  # take no chances and rewrite it.
38585  # Note: m4 eats our [], so we need to use [ and ] instead.
38586  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38587  if test "x$has_forbidden_chars" != x; then
38588    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38589    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38590  fi
38591
38592    # Output is in $new_path
38593
38594  windows_path="$new_path"
38595  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38596    unix_path=`$CYGPATH -u "$windows_path"`
38597    new_path="$unix_path"
38598  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38599    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38600    new_path="$unix_path"
38601  fi
38602
38603    # remove trailing .exe if any
38604    new_path="${new_path/%.exe/}"
38605
38606    # Save the first 10 bytes of this path to the storage, so fixpath can work.
38607    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38608  fi
38609
38610  else
38611    # We're on a posix platform. Hooray! :)
38612    # First separate the path from the arguments. This will split at the first
38613    # space.
38614    complete="$OBJDUMP"
38615    path="${complete%% *}"
38616    tmp="$complete EOL"
38617    arguments="${tmp#* }"
38618
38619    # Cannot rely on the command "which" here since it doesn't always work.
38620    is_absolute_path=`$ECHO "$path" | $GREP ^/`
38621    if test -z "$is_absolute_path"; then
38622      # Path to executable is not absolute. Find it.
38623      IFS_save="$IFS"
38624      IFS=:
38625      for p in $PATH; do
38626        if test -f "$p/$path" && test -x "$p/$path"; then
38627          new_path="$p/$path"
38628          break
38629        fi
38630      done
38631      IFS="$IFS_save"
38632    else
38633      # This is an absolute path, we can use it without further modifications.
38634      new_path="$path"
38635    fi
38636
38637    if test "x$new_path" = x; then
38638      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
38639$as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
38640      has_space=`$ECHO "$complete" | $GREP " "`
38641      if test "x$has_space" != x; then
38642        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38643$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38644      fi
38645      as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
38646    fi
38647  fi
38648
38649  # Now join together the path and the arguments once again
38650  if test "x$arguments" != xEOL; then
38651    new_complete="$new_path ${arguments% *}"
38652  else
38653    new_complete="$new_path"
38654  fi
38655
38656  if test "x$complete" != "x$new_complete"; then
38657    OBJDUMP="$new_complete"
38658    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
38659$as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
38660  fi
38661
38662  fi
38663
38664
38665  # Restore old path.
38666  PATH="$OLD_PATH"
38667
38668  # Restore the flags to the user specified values.
38669  # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
38670  CFLAGS="$ORG_CFLAGS"
38671  CXXFLAGS="$ORG_CXXFLAGS"
38672  OBJCFLAGS="$ORG_OBJCFLAGS"
38673
38674
38675# Finally do some processing after the detection phase
38676
38677  if test "x$COMPILE_TYPE" = "xcross"; then
38678    # Now we need to find a C/C++ compiler that can build executables for the
38679    # build platform. We can't use the AC_PROG_CC macro, since it can only be
38680    # used once. Also, we need to do this without adding a tools dir to the
38681    # path, otherwise we might pick up cross-compilers which don't use standard
38682    # naming.
38683
38684    # FIXME: we should list the discovered compilers as an exclude pattern!
38685    # If we do that, we can do this detection before POST_DETECTION, and still
38686    # find the build compilers in the tools dir, if needed.
38687
38688
38689  # Publish this variable in the help.
38690
38691
38692  if test "x$BUILD_CC" = x; then
38693    # The variable is not set by user, try to locate tool using the code snippet
38694    for ac_prog in cl cc gcc
38695do
38696  # Extract the first word of "$ac_prog", so it can be a program name with args.
38697set dummy $ac_prog; ac_word=$2
38698{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38699$as_echo_n "checking for $ac_word... " >&6; }
38700if ${ac_cv_path_BUILD_CC+:} false; then :
38701  $as_echo_n "(cached) " >&6
38702else
38703  case $BUILD_CC in
38704  [\\/]* | ?:[\\/]*)
38705  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38706  ;;
38707  *)
38708  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38709for as_dir in $PATH
38710do
38711  IFS=$as_save_IFS
38712  test -z "$as_dir" && as_dir=.
38713    for ac_exec_ext in '' $ac_executable_extensions; do
38714  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38715    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38716    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38717    break 2
38718  fi
38719done
38720  done
38721IFS=$as_save_IFS
38722
38723  ;;
38724esac
38725fi
38726BUILD_CC=$ac_cv_path_BUILD_CC
38727if test -n "$BUILD_CC"; then
38728  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38729$as_echo "$BUILD_CC" >&6; }
38730else
38731  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38732$as_echo "no" >&6; }
38733fi
38734
38735
38736  test -n "$BUILD_CC" && break
38737done
38738
38739  else
38740    # The variable is set, but is it from the command line or the environment?
38741
38742    # Try to remove the string !BUILD_CC! from our list.
38743    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
38744    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38745      # If it failed, the variable was not from the command line. Ignore it,
38746      # but warn the user (except for BASH, which is always set by the calling BASH).
38747      if test "xBUILD_CC" != xBASH; then
38748        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
38749$as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
38750      fi
38751      # Try to locate tool using the code snippet
38752      for ac_prog in cl cc gcc
38753do
38754  # Extract the first word of "$ac_prog", so it can be a program name with args.
38755set dummy $ac_prog; ac_word=$2
38756{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38757$as_echo_n "checking for $ac_word... " >&6; }
38758if ${ac_cv_path_BUILD_CC+:} false; then :
38759  $as_echo_n "(cached) " >&6
38760else
38761  case $BUILD_CC in
38762  [\\/]* | ?:[\\/]*)
38763  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38764  ;;
38765  *)
38766  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38767for as_dir in $PATH
38768do
38769  IFS=$as_save_IFS
38770  test -z "$as_dir" && as_dir=.
38771    for ac_exec_ext in '' $ac_executable_extensions; do
38772  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38773    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38774    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38775    break 2
38776  fi
38777done
38778  done
38779IFS=$as_save_IFS
38780
38781  ;;
38782esac
38783fi
38784BUILD_CC=$ac_cv_path_BUILD_CC
38785if test -n "$BUILD_CC"; then
38786  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38787$as_echo "$BUILD_CC" >&6; }
38788else
38789  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38790$as_echo "no" >&6; }
38791fi
38792
38793
38794  test -n "$BUILD_CC" && break
38795done
38796
38797    else
38798      # If it succeeded, then it was overridden by the user. We will use it
38799      # for the tool.
38800
38801      # First remove it from the list of overridden variables, so we can test
38802      # for unknown variables in the end.
38803      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38804
38805      # Check if the provided tool contains a complete path.
38806      tool_specified="$BUILD_CC"
38807      tool_basename="${tool_specified##*/}"
38808      if test "x$tool_basename" = "x$tool_specified"; then
38809        # A command without a complete path is provided, search $PATH.
38810        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
38811$as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
38812        # Extract the first word of "$tool_basename", so it can be a program name with args.
38813set dummy $tool_basename; ac_word=$2
38814{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38815$as_echo_n "checking for $ac_word... " >&6; }
38816if ${ac_cv_path_BUILD_CC+:} false; then :
38817  $as_echo_n "(cached) " >&6
38818else
38819  case $BUILD_CC in
38820  [\\/]* | ?:[\\/]*)
38821  ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
38822  ;;
38823  *)
38824  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38825for as_dir in $PATH
38826do
38827  IFS=$as_save_IFS
38828  test -z "$as_dir" && as_dir=.
38829    for ac_exec_ext in '' $ac_executable_extensions; do
38830  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38831    ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
38832    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38833    break 2
38834  fi
38835done
38836  done
38837IFS=$as_save_IFS
38838
38839  ;;
38840esac
38841fi
38842BUILD_CC=$ac_cv_path_BUILD_CC
38843if test -n "$BUILD_CC"; then
38844  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
38845$as_echo "$BUILD_CC" >&6; }
38846else
38847  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38848$as_echo "no" >&6; }
38849fi
38850
38851
38852        if test "x$BUILD_CC" = x; then
38853          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38854        fi
38855      else
38856        # Otherwise we believe it is a complete path. Use it as it is.
38857        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
38858$as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
38859        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
38860$as_echo_n "checking for BUILD_CC... " >&6; }
38861        if test ! -x "$tool_specified"; then
38862          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38863$as_echo "not found" >&6; }
38864          as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
38865        fi
38866        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38867$as_echo "$tool_specified" >&6; }
38868      fi
38869    fi
38870  fi
38871
38872
38873
38874  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38875
38876  # First separate the path from the arguments. This will split at the first
38877  # space.
38878  complete="$BUILD_CC"
38879  path="${complete%% *}"
38880  tmp="$complete EOL"
38881  arguments="${tmp#* }"
38882
38883  # Input might be given as Windows format, start by converting to
38884  # unix format.
38885  new_path=`$CYGPATH -u "$path"`
38886
38887  # Now try to locate executable using which
38888  new_path=`$WHICH "$new_path" 2> /dev/null`
38889  # bat and cmd files are not always considered executable in cygwin causing which
38890  # to not find them
38891  if test "x$new_path" = x \
38892      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38893      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38894    new_path=`$CYGPATH -u "$path"`
38895  fi
38896  if test "x$new_path" = x; then
38897    # Oops. Which didn't find the executable.
38898    # The splitting of arguments from the executable at a space might have been incorrect,
38899    # since paths with space are more likely in Windows. Give it another try with the whole
38900    # argument.
38901    path="$complete"
38902    arguments="EOL"
38903    new_path=`$CYGPATH -u "$path"`
38904    new_path=`$WHICH "$new_path" 2> /dev/null`
38905    # bat and cmd files are not always considered executable in cygwin causing which
38906    # to not find them
38907    if test "x$new_path" = x \
38908        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38909        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38910      new_path=`$CYGPATH -u "$path"`
38911    fi
38912    if test "x$new_path" = x; then
38913      # It's still not found. Now this is an unrecoverable error.
38914      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
38915$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
38916      has_space=`$ECHO "$complete" | $GREP " "`
38917      if test "x$has_space" != x; then
38918        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38919$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38920      fi
38921      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38922    fi
38923  fi
38924
38925  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38926  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38927  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38928  # "foo.exe" is OK but "foo" is an error.
38929  #
38930  # This test is therefore slightly more accurate than "test -f" to check for file presence.
38931  # It is also a way to make sure we got the proper file name for the real test later on.
38932  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38933  if test "x$test_shortpath" = x; then
38934    # Short path failed, file does not exist as specified.
38935    # Try adding .exe or .cmd
38936    if test -f "${new_path}.exe"; then
38937      input_to_shortpath="${new_path}.exe"
38938    elif test -f "${new_path}.cmd"; then
38939      input_to_shortpath="${new_path}.cmd"
38940    else
38941      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
38942$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
38943      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38944$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38945      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
38946    fi
38947  else
38948    input_to_shortpath="$new_path"
38949  fi
38950
38951  # Call helper function which possibly converts this using DOS-style short mode.
38952  # If so, the updated path is stored in $new_path.
38953  new_path="$input_to_shortpath"
38954
38955  input_path="$input_to_shortpath"
38956  # Check if we need to convert this using DOS-style short mode. If the path
38957  # contains just simple characters, use it. Otherwise (spaces, weird characters),
38958  # take no chances and rewrite it.
38959  # Note: m4 eats our [], so we need to use [ and ] instead.
38960  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38961  if test "x$has_forbidden_chars" != x; then
38962    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38963    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38964    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38965    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38966      # Going to short mode and back again did indeed matter. Since short mode is
38967      # case insensitive, let's make it lowercase to improve readability.
38968      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38969      # Now convert it back to Unix-stile (cygpath)
38970      input_path=`$CYGPATH -u "$shortmode_path"`
38971      new_path="$input_path"
38972    fi
38973  fi
38974
38975  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38976  if test "x$test_cygdrive_prefix" = x; then
38977    # As a simple fix, exclude /usr/bin since it's not a real path.
38978    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38979      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38980      # a path prefixed by /cygdrive for fixpath to work.
38981      new_path="$CYGWIN_ROOT_PATH$input_path"
38982    fi
38983  fi
38984
38985  # remove trailing .exe if any
38986  new_path="${new_path/%.exe/}"
38987
38988  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38989
38990  # First separate the path from the arguments. This will split at the first
38991  # space.
38992  complete="$BUILD_CC"
38993  path="${complete%% *}"
38994  tmp="$complete EOL"
38995  arguments="${tmp#* }"
38996
38997  # Input might be given as Windows format, start by converting to
38998  # unix format.
38999  new_path="$path"
39000
39001  windows_path="$new_path"
39002  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39003    unix_path=`$CYGPATH -u "$windows_path"`
39004    new_path="$unix_path"
39005  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39006    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39007    new_path="$unix_path"
39008  fi
39009
39010
39011  # Now try to locate executable using which
39012  new_path=`$WHICH "$new_path" 2> /dev/null`
39013
39014  if test "x$new_path" = x; then
39015    # Oops. Which didn't find the executable.
39016    # The splitting of arguments from the executable at a space might have been incorrect,
39017    # since paths with space are more likely in Windows. Give it another try with the whole
39018    # argument.
39019    path="$complete"
39020    arguments="EOL"
39021    new_path="$path"
39022
39023  windows_path="$new_path"
39024  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39025    unix_path=`$CYGPATH -u "$windows_path"`
39026    new_path="$unix_path"
39027  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39028    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39029    new_path="$unix_path"
39030  fi
39031
39032
39033    new_path=`$WHICH "$new_path" 2> /dev/null`
39034
39035    if test "x$new_path" = x; then
39036      # It's still not found. Now this is an unrecoverable error.
39037      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39038$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39039      has_space=`$ECHO "$complete" | $GREP " "`
39040      if test "x$has_space" != x; then
39041        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39042$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39043      fi
39044      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39045    fi
39046  fi
39047
39048  # Now new_path has a complete unix path to the binary
39049  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39050    # Keep paths in /bin as-is, but remove trailing .exe if any
39051    new_path="${new_path/%.exe/}"
39052    # Do not save /bin paths to all_fixpath_prefixes!
39053  else
39054    # Not in mixed or Windows style, start by that.
39055    new_path=`cmd //c echo $new_path`
39056
39057  input_path="$new_path"
39058  # Check if we need to convert this using DOS-style short mode. If the path
39059  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39060  # take no chances and rewrite it.
39061  # Note: m4 eats our [], so we need to use [ and ] instead.
39062  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39063  if test "x$has_forbidden_chars" != x; then
39064    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39065    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39066  fi
39067
39068    # Output is in $new_path
39069
39070  windows_path="$new_path"
39071  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39072    unix_path=`$CYGPATH -u "$windows_path"`
39073    new_path="$unix_path"
39074  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39075    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39076    new_path="$unix_path"
39077  fi
39078
39079    # remove trailing .exe if any
39080    new_path="${new_path/%.exe/}"
39081
39082    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39083    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39084  fi
39085
39086  else
39087    # We're on a posix platform. Hooray! :)
39088    # First separate the path from the arguments. This will split at the first
39089    # space.
39090    complete="$BUILD_CC"
39091    path="${complete%% *}"
39092    tmp="$complete EOL"
39093    arguments="${tmp#* }"
39094
39095    # Cannot rely on the command "which" here since it doesn't always work.
39096    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39097    if test -z "$is_absolute_path"; then
39098      # Path to executable is not absolute. Find it.
39099      IFS_save="$IFS"
39100      IFS=:
39101      for p in $PATH; do
39102        if test -f "$p/$path" && test -x "$p/$path"; then
39103          new_path="$p/$path"
39104          break
39105        fi
39106      done
39107      IFS="$IFS_save"
39108    else
39109      # This is an absolute path, we can use it without further modifications.
39110      new_path="$path"
39111    fi
39112
39113    if test "x$new_path" = x; then
39114      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39115$as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39116      has_space=`$ECHO "$complete" | $GREP " "`
39117      if test "x$has_space" != x; then
39118        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39119$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39120      fi
39121      as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39122    fi
39123  fi
39124
39125  # Now join together the path and the arguments once again
39126  if test "x$arguments" != xEOL; then
39127    new_complete="$new_path ${arguments% *}"
39128  else
39129    new_complete="$new_path"
39130  fi
39131
39132  if test "x$complete" != "x$new_complete"; then
39133    BUILD_CC="$new_complete"
39134    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
39135$as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
39136  fi
39137
39138
39139
39140  # Publish this variable in the help.
39141
39142
39143  if test "x$BUILD_CXX" = x; then
39144    # The variable is not set by user, try to locate tool using the code snippet
39145    for ac_prog in cl CC g++
39146do
39147  # Extract the first word of "$ac_prog", so it can be a program name with args.
39148set dummy $ac_prog; ac_word=$2
39149{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39150$as_echo_n "checking for $ac_word... " >&6; }
39151if ${ac_cv_path_BUILD_CXX+:} false; then :
39152  $as_echo_n "(cached) " >&6
39153else
39154  case $BUILD_CXX in
39155  [\\/]* | ?:[\\/]*)
39156  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39157  ;;
39158  *)
39159  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39160for as_dir in $PATH
39161do
39162  IFS=$as_save_IFS
39163  test -z "$as_dir" && as_dir=.
39164    for ac_exec_ext in '' $ac_executable_extensions; do
39165  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39166    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39167    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39168    break 2
39169  fi
39170done
39171  done
39172IFS=$as_save_IFS
39173
39174  ;;
39175esac
39176fi
39177BUILD_CXX=$ac_cv_path_BUILD_CXX
39178if test -n "$BUILD_CXX"; then
39179  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39180$as_echo "$BUILD_CXX" >&6; }
39181else
39182  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39183$as_echo "no" >&6; }
39184fi
39185
39186
39187  test -n "$BUILD_CXX" && break
39188done
39189
39190  else
39191    # The variable is set, but is it from the command line or the environment?
39192
39193    # Try to remove the string !BUILD_CXX! from our list.
39194    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
39195    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39196      # If it failed, the variable was not from the command line. Ignore it,
39197      # but warn the user (except for BASH, which is always set by the calling BASH).
39198      if test "xBUILD_CXX" != xBASH; then
39199        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
39200$as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
39201      fi
39202      # Try to locate tool using the code snippet
39203      for ac_prog in cl CC g++
39204do
39205  # Extract the first word of "$ac_prog", so it can be a program name with args.
39206set dummy $ac_prog; ac_word=$2
39207{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39208$as_echo_n "checking for $ac_word... " >&6; }
39209if ${ac_cv_path_BUILD_CXX+:} false; then :
39210  $as_echo_n "(cached) " >&6
39211else
39212  case $BUILD_CXX in
39213  [\\/]* | ?:[\\/]*)
39214  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39215  ;;
39216  *)
39217  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39218for as_dir in $PATH
39219do
39220  IFS=$as_save_IFS
39221  test -z "$as_dir" && as_dir=.
39222    for ac_exec_ext in '' $ac_executable_extensions; do
39223  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39224    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39225    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39226    break 2
39227  fi
39228done
39229  done
39230IFS=$as_save_IFS
39231
39232  ;;
39233esac
39234fi
39235BUILD_CXX=$ac_cv_path_BUILD_CXX
39236if test -n "$BUILD_CXX"; then
39237  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39238$as_echo "$BUILD_CXX" >&6; }
39239else
39240  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39241$as_echo "no" >&6; }
39242fi
39243
39244
39245  test -n "$BUILD_CXX" && break
39246done
39247
39248    else
39249      # If it succeeded, then it was overridden by the user. We will use it
39250      # for the tool.
39251
39252      # First remove it from the list of overridden variables, so we can test
39253      # for unknown variables in the end.
39254      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39255
39256      # Check if the provided tool contains a complete path.
39257      tool_specified="$BUILD_CXX"
39258      tool_basename="${tool_specified##*/}"
39259      if test "x$tool_basename" = "x$tool_specified"; then
39260        # A command without a complete path is provided, search $PATH.
39261        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
39262$as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
39263        # Extract the first word of "$tool_basename", so it can be a program name with args.
39264set dummy $tool_basename; ac_word=$2
39265{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39266$as_echo_n "checking for $ac_word... " >&6; }
39267if ${ac_cv_path_BUILD_CXX+:} false; then :
39268  $as_echo_n "(cached) " >&6
39269else
39270  case $BUILD_CXX in
39271  [\\/]* | ?:[\\/]*)
39272  ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39273  ;;
39274  *)
39275  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39276for as_dir in $PATH
39277do
39278  IFS=$as_save_IFS
39279  test -z "$as_dir" && as_dir=.
39280    for ac_exec_ext in '' $ac_executable_extensions; do
39281  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39282    ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39283    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39284    break 2
39285  fi
39286done
39287  done
39288IFS=$as_save_IFS
39289
39290  ;;
39291esac
39292fi
39293BUILD_CXX=$ac_cv_path_BUILD_CXX
39294if test -n "$BUILD_CXX"; then
39295  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39296$as_echo "$BUILD_CXX" >&6; }
39297else
39298  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39299$as_echo "no" >&6; }
39300fi
39301
39302
39303        if test "x$BUILD_CXX" = x; then
39304          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39305        fi
39306      else
39307        # Otherwise we believe it is a complete path. Use it as it is.
39308        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
39309$as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
39310        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
39311$as_echo_n "checking for BUILD_CXX... " >&6; }
39312        if test ! -x "$tool_specified"; then
39313          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39314$as_echo "not found" >&6; }
39315          as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
39316        fi
39317        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39318$as_echo "$tool_specified" >&6; }
39319      fi
39320    fi
39321  fi
39322
39323
39324
39325  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39326
39327  # First separate the path from the arguments. This will split at the first
39328  # space.
39329  complete="$BUILD_CXX"
39330  path="${complete%% *}"
39331  tmp="$complete EOL"
39332  arguments="${tmp#* }"
39333
39334  # Input might be given as Windows format, start by converting to
39335  # unix format.
39336  new_path=`$CYGPATH -u "$path"`
39337
39338  # Now try to locate executable using which
39339  new_path=`$WHICH "$new_path" 2> /dev/null`
39340  # bat and cmd files are not always considered executable in cygwin causing which
39341  # to not find them
39342  if test "x$new_path" = x \
39343      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39344      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39345    new_path=`$CYGPATH -u "$path"`
39346  fi
39347  if test "x$new_path" = x; then
39348    # Oops. Which didn't find the executable.
39349    # The splitting of arguments from the executable at a space might have been incorrect,
39350    # since paths with space are more likely in Windows. Give it another try with the whole
39351    # argument.
39352    path="$complete"
39353    arguments="EOL"
39354    new_path=`$CYGPATH -u "$path"`
39355    new_path=`$WHICH "$new_path" 2> /dev/null`
39356    # bat and cmd files are not always considered executable in cygwin causing which
39357    # to not find them
39358    if test "x$new_path" = x \
39359        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39360        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39361      new_path=`$CYGPATH -u "$path"`
39362    fi
39363    if test "x$new_path" = x; then
39364      # It's still not found. Now this is an unrecoverable error.
39365      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39366$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39367      has_space=`$ECHO "$complete" | $GREP " "`
39368      if test "x$has_space" != x; then
39369        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39370$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39371      fi
39372      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39373    fi
39374  fi
39375
39376  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39377  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39378  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39379  # "foo.exe" is OK but "foo" is an error.
39380  #
39381  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39382  # It is also a way to make sure we got the proper file name for the real test later on.
39383  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39384  if test "x$test_shortpath" = x; then
39385    # Short path failed, file does not exist as specified.
39386    # Try adding .exe or .cmd
39387    if test -f "${new_path}.exe"; then
39388      input_to_shortpath="${new_path}.exe"
39389    elif test -f "${new_path}.cmd"; then
39390      input_to_shortpath="${new_path}.cmd"
39391    else
39392      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
39393$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
39394      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39395$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39396      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39397    fi
39398  else
39399    input_to_shortpath="$new_path"
39400  fi
39401
39402  # Call helper function which possibly converts this using DOS-style short mode.
39403  # If so, the updated path is stored in $new_path.
39404  new_path="$input_to_shortpath"
39405
39406  input_path="$input_to_shortpath"
39407  # Check if we need to convert this using DOS-style short mode. If the path
39408  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39409  # take no chances and rewrite it.
39410  # Note: m4 eats our [], so we need to use [ and ] instead.
39411  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39412  if test "x$has_forbidden_chars" != x; then
39413    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39414    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39415    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39416    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39417      # Going to short mode and back again did indeed matter. Since short mode is
39418      # case insensitive, let's make it lowercase to improve readability.
39419      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39420      # Now convert it back to Unix-stile (cygpath)
39421      input_path=`$CYGPATH -u "$shortmode_path"`
39422      new_path="$input_path"
39423    fi
39424  fi
39425
39426  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39427  if test "x$test_cygdrive_prefix" = x; then
39428    # As a simple fix, exclude /usr/bin since it's not a real path.
39429    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39430      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39431      # a path prefixed by /cygdrive for fixpath to work.
39432      new_path="$CYGWIN_ROOT_PATH$input_path"
39433    fi
39434  fi
39435
39436  # remove trailing .exe if any
39437  new_path="${new_path/%.exe/}"
39438
39439  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39440
39441  # First separate the path from the arguments. This will split at the first
39442  # space.
39443  complete="$BUILD_CXX"
39444  path="${complete%% *}"
39445  tmp="$complete EOL"
39446  arguments="${tmp#* }"
39447
39448  # Input might be given as Windows format, start by converting to
39449  # unix format.
39450  new_path="$path"
39451
39452  windows_path="$new_path"
39453  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39454    unix_path=`$CYGPATH -u "$windows_path"`
39455    new_path="$unix_path"
39456  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39457    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39458    new_path="$unix_path"
39459  fi
39460
39461
39462  # Now try to locate executable using which
39463  new_path=`$WHICH "$new_path" 2> /dev/null`
39464
39465  if test "x$new_path" = x; then
39466    # Oops. Which didn't find the executable.
39467    # The splitting of arguments from the executable at a space might have been incorrect,
39468    # since paths with space are more likely in Windows. Give it another try with the whole
39469    # argument.
39470    path="$complete"
39471    arguments="EOL"
39472    new_path="$path"
39473
39474  windows_path="$new_path"
39475  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39476    unix_path=`$CYGPATH -u "$windows_path"`
39477    new_path="$unix_path"
39478  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39479    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39480    new_path="$unix_path"
39481  fi
39482
39483
39484    new_path=`$WHICH "$new_path" 2> /dev/null`
39485
39486    if test "x$new_path" = x; then
39487      # It's still not found. Now this is an unrecoverable error.
39488      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39489$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39490      has_space=`$ECHO "$complete" | $GREP " "`
39491      if test "x$has_space" != x; then
39492        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39493$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39494      fi
39495      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39496    fi
39497  fi
39498
39499  # Now new_path has a complete unix path to the binary
39500  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39501    # Keep paths in /bin as-is, but remove trailing .exe if any
39502    new_path="${new_path/%.exe/}"
39503    # Do not save /bin paths to all_fixpath_prefixes!
39504  else
39505    # Not in mixed or Windows style, start by that.
39506    new_path=`cmd //c echo $new_path`
39507
39508  input_path="$new_path"
39509  # Check if we need to convert this using DOS-style short mode. If the path
39510  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39511  # take no chances and rewrite it.
39512  # Note: m4 eats our [], so we need to use [ and ] instead.
39513  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39514  if test "x$has_forbidden_chars" != x; then
39515    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39516    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39517  fi
39518
39519    # Output is in $new_path
39520
39521  windows_path="$new_path"
39522  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39523    unix_path=`$CYGPATH -u "$windows_path"`
39524    new_path="$unix_path"
39525  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39526    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39527    new_path="$unix_path"
39528  fi
39529
39530    # remove trailing .exe if any
39531    new_path="${new_path/%.exe/}"
39532
39533    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39534    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39535  fi
39536
39537  else
39538    # We're on a posix platform. Hooray! :)
39539    # First separate the path from the arguments. This will split at the first
39540    # space.
39541    complete="$BUILD_CXX"
39542    path="${complete%% *}"
39543    tmp="$complete EOL"
39544    arguments="${tmp#* }"
39545
39546    # Cannot rely on the command "which" here since it doesn't always work.
39547    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39548    if test -z "$is_absolute_path"; then
39549      # Path to executable is not absolute. Find it.
39550      IFS_save="$IFS"
39551      IFS=:
39552      for p in $PATH; do
39553        if test -f "$p/$path" && test -x "$p/$path"; then
39554          new_path="$p/$path"
39555          break
39556        fi
39557      done
39558      IFS="$IFS_save"
39559    else
39560      # This is an absolute path, we can use it without further modifications.
39561      new_path="$path"
39562    fi
39563
39564    if test "x$new_path" = x; then
39565      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
39566$as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
39567      has_space=`$ECHO "$complete" | $GREP " "`
39568      if test "x$has_space" != x; then
39569        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39570$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39571      fi
39572      as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
39573    fi
39574  fi
39575
39576  # Now join together the path and the arguments once again
39577  if test "x$arguments" != xEOL; then
39578    new_complete="$new_path ${arguments% *}"
39579  else
39580    new_complete="$new_path"
39581  fi
39582
39583  if test "x$complete" != "x$new_complete"; then
39584    BUILD_CXX="$new_complete"
39585    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
39586$as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
39587  fi
39588
39589
39590
39591  # Publish this variable in the help.
39592
39593
39594  if test "x$BUILD_LD" = x; then
39595    # The variable is not set by user, try to locate tool using the code snippet
39596    for ac_prog in ld
39597do
39598  # Extract the first word of "$ac_prog", so it can be a program name with args.
39599set dummy $ac_prog; ac_word=$2
39600{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39601$as_echo_n "checking for $ac_word... " >&6; }
39602if ${ac_cv_path_BUILD_LD+:} false; then :
39603  $as_echo_n "(cached) " >&6
39604else
39605  case $BUILD_LD in
39606  [\\/]* | ?:[\\/]*)
39607  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39608  ;;
39609  *)
39610  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39611for as_dir in $PATH
39612do
39613  IFS=$as_save_IFS
39614  test -z "$as_dir" && as_dir=.
39615    for ac_exec_ext in '' $ac_executable_extensions; do
39616  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39617    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39618    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39619    break 2
39620  fi
39621done
39622  done
39623IFS=$as_save_IFS
39624
39625  ;;
39626esac
39627fi
39628BUILD_LD=$ac_cv_path_BUILD_LD
39629if test -n "$BUILD_LD"; then
39630  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39631$as_echo "$BUILD_LD" >&6; }
39632else
39633  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39634$as_echo "no" >&6; }
39635fi
39636
39637
39638  test -n "$BUILD_LD" && break
39639done
39640
39641  else
39642    # The variable is set, but is it from the command line or the environment?
39643
39644    # Try to remove the string !BUILD_LD! from our list.
39645    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
39646    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39647      # If it failed, the variable was not from the command line. Ignore it,
39648      # but warn the user (except for BASH, which is always set by the calling BASH).
39649      if test "xBUILD_LD" != xBASH; then
39650        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
39651$as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
39652      fi
39653      # Try to locate tool using the code snippet
39654      for ac_prog in ld
39655do
39656  # Extract the first word of "$ac_prog", so it can be a program name with args.
39657set dummy $ac_prog; ac_word=$2
39658{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39659$as_echo_n "checking for $ac_word... " >&6; }
39660if ${ac_cv_path_BUILD_LD+:} false; then :
39661  $as_echo_n "(cached) " >&6
39662else
39663  case $BUILD_LD in
39664  [\\/]* | ?:[\\/]*)
39665  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39666  ;;
39667  *)
39668  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39669for as_dir in $PATH
39670do
39671  IFS=$as_save_IFS
39672  test -z "$as_dir" && as_dir=.
39673    for ac_exec_ext in '' $ac_executable_extensions; do
39674  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39675    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39676    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39677    break 2
39678  fi
39679done
39680  done
39681IFS=$as_save_IFS
39682
39683  ;;
39684esac
39685fi
39686BUILD_LD=$ac_cv_path_BUILD_LD
39687if test -n "$BUILD_LD"; then
39688  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39689$as_echo "$BUILD_LD" >&6; }
39690else
39691  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39692$as_echo "no" >&6; }
39693fi
39694
39695
39696  test -n "$BUILD_LD" && break
39697done
39698
39699    else
39700      # If it succeeded, then it was overridden by the user. We will use it
39701      # for the tool.
39702
39703      # First remove it from the list of overridden variables, so we can test
39704      # for unknown variables in the end.
39705      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39706
39707      # Check if the provided tool contains a complete path.
39708      tool_specified="$BUILD_LD"
39709      tool_basename="${tool_specified##*/}"
39710      if test "x$tool_basename" = "x$tool_specified"; then
39711        # A command without a complete path is provided, search $PATH.
39712        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
39713$as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
39714        # Extract the first word of "$tool_basename", so it can be a program name with args.
39715set dummy $tool_basename; ac_word=$2
39716{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39717$as_echo_n "checking for $ac_word... " >&6; }
39718if ${ac_cv_path_BUILD_LD+:} false; then :
39719  $as_echo_n "(cached) " >&6
39720else
39721  case $BUILD_LD in
39722  [\\/]* | ?:[\\/]*)
39723  ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
39724  ;;
39725  *)
39726  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39727for as_dir in $PATH
39728do
39729  IFS=$as_save_IFS
39730  test -z "$as_dir" && as_dir=.
39731    for ac_exec_ext in '' $ac_executable_extensions; do
39732  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39733    ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
39734    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39735    break 2
39736  fi
39737done
39738  done
39739IFS=$as_save_IFS
39740
39741  ;;
39742esac
39743fi
39744BUILD_LD=$ac_cv_path_BUILD_LD
39745if test -n "$BUILD_LD"; then
39746  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
39747$as_echo "$BUILD_LD" >&6; }
39748else
39749  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39750$as_echo "no" >&6; }
39751fi
39752
39753
39754        if test "x$BUILD_LD" = x; then
39755          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39756        fi
39757      else
39758        # Otherwise we believe it is a complete path. Use it as it is.
39759        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
39760$as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
39761        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
39762$as_echo_n "checking for BUILD_LD... " >&6; }
39763        if test ! -x "$tool_specified"; then
39764          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39765$as_echo "not found" >&6; }
39766          as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
39767        fi
39768        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39769$as_echo "$tool_specified" >&6; }
39770      fi
39771    fi
39772  fi
39773
39774
39775
39776  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39777
39778  # First separate the path from the arguments. This will split at the first
39779  # space.
39780  complete="$BUILD_LD"
39781  path="${complete%% *}"
39782  tmp="$complete EOL"
39783  arguments="${tmp#* }"
39784
39785  # Input might be given as Windows format, start by converting to
39786  # unix format.
39787  new_path=`$CYGPATH -u "$path"`
39788
39789  # Now try to locate executable using which
39790  new_path=`$WHICH "$new_path" 2> /dev/null`
39791  # bat and cmd files are not always considered executable in cygwin causing which
39792  # to not find them
39793  if test "x$new_path" = x \
39794      && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39795      && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39796    new_path=`$CYGPATH -u "$path"`
39797  fi
39798  if test "x$new_path" = x; then
39799    # Oops. Which didn't find the executable.
39800    # The splitting of arguments from the executable at a space might have been incorrect,
39801    # since paths with space are more likely in Windows. Give it another try with the whole
39802    # argument.
39803    path="$complete"
39804    arguments="EOL"
39805    new_path=`$CYGPATH -u "$path"`
39806    new_path=`$WHICH "$new_path" 2> /dev/null`
39807    # bat and cmd files are not always considered executable in cygwin causing which
39808    # to not find them
39809    if test "x$new_path" = x \
39810        && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39811        && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39812      new_path=`$CYGPATH -u "$path"`
39813    fi
39814    if test "x$new_path" = x; then
39815      # It's still not found. Now this is an unrecoverable error.
39816      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39817$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39818      has_space=`$ECHO "$complete" | $GREP " "`
39819      if test "x$has_space" != x; then
39820        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39821$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39822      fi
39823      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39824    fi
39825  fi
39826
39827  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39828  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39829  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39830  # "foo.exe" is OK but "foo" is an error.
39831  #
39832  # This test is therefore slightly more accurate than "test -f" to check for file presence.
39833  # It is also a way to make sure we got the proper file name for the real test later on.
39834  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39835  if test "x$test_shortpath" = x; then
39836    # Short path failed, file does not exist as specified.
39837    # Try adding .exe or .cmd
39838    if test -f "${new_path}.exe"; then
39839      input_to_shortpath="${new_path}.exe"
39840    elif test -f "${new_path}.cmd"; then
39841      input_to_shortpath="${new_path}.cmd"
39842    else
39843      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
39844$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
39845      { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39846$as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39847      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39848    fi
39849  else
39850    input_to_shortpath="$new_path"
39851  fi
39852
39853  # Call helper function which possibly converts this using DOS-style short mode.
39854  # If so, the updated path is stored in $new_path.
39855  new_path="$input_to_shortpath"
39856
39857  input_path="$input_to_shortpath"
39858  # Check if we need to convert this using DOS-style short mode. If the path
39859  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39860  # take no chances and rewrite it.
39861  # Note: m4 eats our [], so we need to use [ and ] instead.
39862  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39863  if test "x$has_forbidden_chars" != x; then
39864    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39865    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39866    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39867    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39868      # Going to short mode and back again did indeed matter. Since short mode is
39869      # case insensitive, let's make it lowercase to improve readability.
39870      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39871      # Now convert it back to Unix-stile (cygpath)
39872      input_path=`$CYGPATH -u "$shortmode_path"`
39873      new_path="$input_path"
39874    fi
39875  fi
39876
39877  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39878  if test "x$test_cygdrive_prefix" = x; then
39879    # As a simple fix, exclude /usr/bin since it's not a real path.
39880    if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39881      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39882      # a path prefixed by /cygdrive for fixpath to work.
39883      new_path="$CYGWIN_ROOT_PATH$input_path"
39884    fi
39885  fi
39886
39887  # remove trailing .exe if any
39888  new_path="${new_path/%.exe/}"
39889
39890  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39891
39892  # First separate the path from the arguments. This will split at the first
39893  # space.
39894  complete="$BUILD_LD"
39895  path="${complete%% *}"
39896  tmp="$complete EOL"
39897  arguments="${tmp#* }"
39898
39899  # Input might be given as Windows format, start by converting to
39900  # unix format.
39901  new_path="$path"
39902
39903  windows_path="$new_path"
39904  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39905    unix_path=`$CYGPATH -u "$windows_path"`
39906    new_path="$unix_path"
39907  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39908    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39909    new_path="$unix_path"
39910  fi
39911
39912
39913  # Now try to locate executable using which
39914  new_path=`$WHICH "$new_path" 2> /dev/null`
39915
39916  if test "x$new_path" = x; then
39917    # Oops. Which didn't find the executable.
39918    # The splitting of arguments from the executable at a space might have been incorrect,
39919    # since paths with space are more likely in Windows. Give it another try with the whole
39920    # argument.
39921    path="$complete"
39922    arguments="EOL"
39923    new_path="$path"
39924
39925  windows_path="$new_path"
39926  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39927    unix_path=`$CYGPATH -u "$windows_path"`
39928    new_path="$unix_path"
39929  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39930    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39931    new_path="$unix_path"
39932  fi
39933
39934
39935    new_path=`$WHICH "$new_path" 2> /dev/null`
39936
39937    if test "x$new_path" = x; then
39938      # It's still not found. Now this is an unrecoverable error.
39939      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
39940$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
39941      has_space=`$ECHO "$complete" | $GREP " "`
39942      if test "x$has_space" != x; then
39943        { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39944$as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39945      fi
39946      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
39947    fi
39948  fi
39949
39950  # Now new_path has a complete unix path to the binary
39951  if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39952    # Keep paths in /bin as-is, but remove trailing .exe if any
39953    new_path="${new_path/%.exe/}"
39954    # Do not save /bin paths to all_fixpath_prefixes!
39955  else
39956    # Not in mixed or Windows style, start by that.
39957    new_path=`cmd //c echo $new_path`
39958
39959  input_path="$new_path"
39960  # Check if we need to convert this using DOS-style short mode. If the path
39961  # contains just simple characters, use it. Otherwise (spaces, weird characters),
39962  # take no chances and rewrite it.
39963  # Note: m4 eats our [], so we need to use [ and ] instead.
39964  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39965  if test "x$has_forbidden_chars" != x; then
39966    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39967    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39968  fi
39969
39970    # Output is in $new_path
39971
39972  windows_path="$new_path"
39973  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39974    unix_path=`$CYGPATH -u "$windows_path"`
39975    new_path="$unix_path"
39976  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39977    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39978    new_path="$unix_path"
39979  fi
39980
39981    # remove trailing .exe if any
39982    new_path="${new_path/%.exe/}"
39983
39984    # Save the first 10 bytes of this path to the storage, so fixpath can work.
39985    all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39986  fi
39987
39988  else
39989    # We're on a posix platform. Hooray! :)
39990    # First separate the path from the arguments. This will split at the first
39991    # space.
39992    complete="$BUILD_LD"
39993    path="${complete%% *}"
39994    tmp="$complete EOL"
39995    arguments="${tmp#* }"
39996
39997    # Cannot rely on the command "which" here since it doesn't always work.
39998    is_absolute_path=`$ECHO "$path" | $GREP ^/`
39999    if test -z "$is_absolute_path"; then
40000      # Path to executable is not absolute. Find it.
40001      IFS_save="$IFS"
40002      IFS=:
40003      for p in $PATH; do
40004        if test -f "$p/$path" && test -x "$p/$path"; then
40005          new_path="$p/$path"
40006          break
40007        fi
40008      done
40009      IFS="$IFS_save"
40010    else
40011      # This is an absolute path, we can use it without further modifications.
40012      new_path="$path"
40013    fi
40014
40015    if test "x$new_path" = x; then
40016      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40017$as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40018      has_space=`$ECHO "$complete" | $GREP " "`
40019      if test "x$has_space" != x; then
40020        { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40021$as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40022      fi
40023      as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40024    fi
40025  fi
40026
40027  # Now join together the path and the arguments once again
40028  if test "x$arguments" != xEOL; then
40029    new_complete="$new_path ${arguments% *}"
40030  else
40031    new_complete="$new_path"
40032  fi
40033
40034  if test "x$complete" != "x$new_complete"; then
40035    BUILD_LD="$new_complete"
40036    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
40037$as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
40038  fi
40039
40040  else
40041    # If we are not cross compiling, use the normal target compilers for
40042    # building the build platform executables.
40043    BUILD_CC="$CC"
40044    BUILD_CXX="$CXX"
40045    BUILD_LD="$LD"
40046  fi
40047
40048
40049
40050
40051
40052
40053  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40054    # For hotspot, we need these in Windows mixed path,
40055    # so rewrite them all. Need added .exe suffix.
40056    HOTSPOT_CXX="$CXX.exe"
40057    HOTSPOT_LD="$LD.exe"
40058    HOTSPOT_MT="$MT.exe"
40059    HOTSPOT_RC="$RC.exe"
40060
40061  unix_path="$HOTSPOT_CXX"
40062  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40063    windows_path=`$CYGPATH -m "$unix_path"`
40064    HOTSPOT_CXX="$windows_path"
40065  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40066    windows_path=`cmd //c echo $unix_path`
40067    HOTSPOT_CXX="$windows_path"
40068  fi
40069
40070
40071  unix_path="$HOTSPOT_LD"
40072  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40073    windows_path=`$CYGPATH -m "$unix_path"`
40074    HOTSPOT_LD="$windows_path"
40075  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40076    windows_path=`cmd //c echo $unix_path`
40077    HOTSPOT_LD="$windows_path"
40078  fi
40079
40080
40081  unix_path="$HOTSPOT_MT"
40082  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40083    windows_path=`$CYGPATH -m "$unix_path"`
40084    HOTSPOT_MT="$windows_path"
40085  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40086    windows_path=`cmd //c echo $unix_path`
40087    HOTSPOT_MT="$windows_path"
40088  fi
40089
40090
40091  unix_path="$HOTSPOT_RC"
40092  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40093    windows_path=`$CYGPATH -m "$unix_path"`
40094    HOTSPOT_RC="$windows_path"
40095  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40096    windows_path=`cmd //c echo $unix_path`
40097    HOTSPOT_RC="$windows_path"
40098  fi
40099
40100
40101
40102  else
40103    HOTSPOT_CXX="$CXX"
40104    HOTSPOT_LD="$LD"
40105  fi
40106
40107
40108
40109  if test  "x$TOOLCHAIN_TYPE" = xclang; then
40110    USE_CLANG=true
40111  fi
40112
40113
40114  # LDEXE is the linker to use, when creating executables. Not really used.
40115  # FIXME: These should just be removed!
40116  LDEXE="$LD"
40117  LDEXECXX="$LDCXX"
40118
40119
40120
40121
40122  # The package path is used only on macosx?
40123  # FIXME: clean this up, and/or move it elsewhere.
40124  PACKAGE_PATH=/opt/local
40125
40126
40127  # Check for extra potential brokenness.
40128  if test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40129    # On Windows, double-check that we got the right compiler.
40130    CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'`
40131    COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"`
40132    if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
40133      if test "x$COMPILER_CPU_TEST" != "x80x86"; then
40134        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
40135      fi
40136    elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
40137      if test "x$COMPILER_CPU_TEST" != "xx64"; then
40138        as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
40139      fi
40140    fi
40141  fi
40142
40143  if test "x$TOOLCHAIN_TYPE" = xgcc; then
40144    # If this is a --hash-style=gnu system, use --hash-style=both, why?
40145    HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
40146    # This is later checked when setting flags.
40147  fi
40148
40149  # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed
40150  # in executable.'
40151  USING_BROKEN_SUSE_LD=no
40152  if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then
40153    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
40154$as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
40155    echo "SUNWprivate_1.1 { local: *; };" > version-script.map
40156    echo "int main() { }" > main.c
40157    if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
40158      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40159$as_echo "no" >&6; }
40160      USING_BROKEN_SUSE_LD=no
40161    else
40162      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40163$as_echo "yes" >&6; }
40164      USING_BROKEN_SUSE_LD=yes
40165    fi
40166    rm -rf version-script.map main.c a.out
40167  fi
40168
40169
40170
40171# Setup the JTReg Regression Test Harness.
40172
40173
40174# Check whether --with-jtreg was given.
40175if test "${with_jtreg+set}" = set; then :
40176  withval=$with_jtreg;
40177else
40178  with_jtreg=no
40179fi
40180
40181
40182  if test "x$with_jtreg" = xno; then
40183    # jtreg disabled
40184    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40185$as_echo_n "checking for jtreg... " >&6; }
40186    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40187$as_echo "no" >&6; }
40188  else
40189    if test "x$with_jtreg" != xyes; then
40190      # with path specified.
40191      JT_HOME="$with_jtreg"
40192    fi
40193
40194    if test "x$JT_HOME" != x; then
40195      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
40196$as_echo_n "checking for jtreg... " >&6; }
40197
40198      # use JT_HOME enviroment var.
40199
40200  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40201
40202  # Input might be given as Windows format, start by converting to
40203  # unix format.
40204  path="$JT_HOME"
40205  new_path=`$CYGPATH -u "$path"`
40206
40207  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40208  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40209  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40210  # "foo.exe" is OK but "foo" is an error.
40211  #
40212  # This test is therefore slightly more accurate than "test -f" to check for file precense.
40213  # It is also a way to make sure we got the proper file name for the real test later on.
40214  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40215  if test "x$test_shortpath" = x; then
40216    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40217$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40218    as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
40219  fi
40220
40221  # Call helper function which possibly converts this using DOS-style short mode.
40222  # If so, the updated path is stored in $new_path.
40223
40224  input_path="$new_path"
40225  # Check if we need to convert this using DOS-style short mode. If the path
40226  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40227  # take no chances and rewrite it.
40228  # Note: m4 eats our [], so we need to use [ and ] instead.
40229  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40230  if test "x$has_forbidden_chars" != x; then
40231    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40232    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40233    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40234    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40235      # Going to short mode and back again did indeed matter. Since short mode is
40236      # case insensitive, let's make it lowercase to improve readability.
40237      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40238      # Now convert it back to Unix-stile (cygpath)
40239      input_path=`$CYGPATH -u "$shortmode_path"`
40240      new_path="$input_path"
40241    fi
40242  fi
40243
40244  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40245  if test "x$test_cygdrive_prefix" = x; then
40246    # As a simple fix, exclude /usr/bin since it's not a real path.
40247    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
40248      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40249      # a path prefixed by /cygdrive for fixpath to work.
40250      new_path="$CYGWIN_ROOT_PATH$input_path"
40251    fi
40252  fi
40253
40254
40255  if test "x$path" != "x$new_path"; then
40256    JT_HOME="$new_path"
40257    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40258$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40259  fi
40260
40261  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40262
40263  path="$JT_HOME"
40264  has_colon=`$ECHO $path | $GREP ^.:`
40265  new_path="$path"
40266  if test "x$has_colon" = x; then
40267    # Not in mixed or Windows style, start by that.
40268    new_path=`cmd //c echo $path`
40269  fi
40270
40271
40272  input_path="$new_path"
40273  # Check if we need to convert this using DOS-style short mode. If the path
40274  # contains just simple characters, use it. Otherwise (spaces, weird characters),
40275  # take no chances and rewrite it.
40276  # Note: m4 eats our [], so we need to use [ and ] instead.
40277  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40278  if test "x$has_forbidden_chars" != x; then
40279    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40280    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40281  fi
40282
40283
40284  windows_path="$new_path"
40285  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40286    unix_path=`$CYGPATH -u "$windows_path"`
40287    new_path="$unix_path"
40288  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40289    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40290    new_path="$unix_path"
40291  fi
40292
40293  if test "x$path" != "x$new_path"; then
40294    JT_HOME="$new_path"
40295    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
40296$as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
40297  fi
40298
40299  # Save the first 10 bytes of this path to the storage, so fixpath can work.
40300  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40301
40302  else
40303    # We're on a posix platform. Hooray! :)
40304    path="$JT_HOME"
40305    has_space=`$ECHO "$path" | $GREP " "`
40306    if test "x$has_space" != x; then
40307      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
40308$as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
40309      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
40310    fi
40311
40312    # Use eval to expand a potential ~
40313    eval path="$path"
40314    if test ! -f "$path" && test ! -d "$path"; then
40315      as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
40316    fi
40317
40318    JT_HOME="`cd "$path"; $THEPWDCMD -L`"
40319  fi
40320
40321
40322      # jtreg win32 script works for everybody
40323      JTREGEXE="$JT_HOME/win32/bin/jtreg"
40324
40325      if test ! -f "$JTREGEXE"; then
40326        as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
40327      fi
40328
40329      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40330$as_echo "$JTREGEXE" >&6; }
40331    else
40332      # try to find jtreg on path
40333
40334
40335
40336  # Publish this variable in the help.
40337
40338
40339  if test "x$JTREGEXE" = x; then
40340    # The variable is not set by user, try to locate tool using the code snippet
40341    for ac_prog in jtreg
40342do
40343  # Extract the first word of "$ac_prog", so it can be a program name with args.
40344set dummy $ac_prog; ac_word=$2
40345{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40346$as_echo_n "checking for $ac_word... " >&6; }
40347if ${ac_cv_path_JTREGEXE+:} false; then :
40348  $as_echo_n "(cached) " >&6
40349else
40350  case $JTREGEXE in
40351  [\\/]* | ?:[\\/]*)
40352  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40353  ;;
40354  *)
40355  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40356for as_dir in $PATH
40357do
40358  IFS=$as_save_IFS
40359  test -z "$as_dir" && as_dir=.
40360    for ac_exec_ext in '' $ac_executable_extensions; do
40361  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40362    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40363    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40364    break 2
40365  fi
40366done
40367  done
40368IFS=$as_save_IFS
40369
40370  ;;
40371esac
40372fi
40373JTREGEXE=$ac_cv_path_JTREGEXE
40374if test -n "$JTREGEXE"; then
40375  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40376$as_echo "$JTREGEXE" >&6; }
40377else
40378  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40379$as_echo "no" >&6; }
40380fi
40381
40382
40383  test -n "$JTREGEXE" && break
40384done
40385
40386  else
40387    # The variable is set, but is it from the command line or the environment?
40388
40389    # Try to remove the string !JTREGEXE! from our list.
40390    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
40391    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40392      # If it failed, the variable was not from the command line. Ignore it,
40393      # but warn the user (except for BASH, which is always set by the calling BASH).
40394      if test "xJTREGEXE" != xBASH; then
40395        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
40396$as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
40397      fi
40398      # Try to locate tool using the code snippet
40399      for ac_prog in jtreg
40400do
40401  # Extract the first word of "$ac_prog", so it can be a program name with args.
40402set dummy $ac_prog; ac_word=$2
40403{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40404$as_echo_n "checking for $ac_word... " >&6; }
40405if ${ac_cv_path_JTREGEXE+:} false; then :
40406  $as_echo_n "(cached) " >&6
40407else
40408  case $JTREGEXE in
40409  [\\/]* | ?:[\\/]*)
40410  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40411  ;;
40412  *)
40413  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40414for as_dir in $PATH
40415do
40416  IFS=$as_save_IFS
40417  test -z "$as_dir" && as_dir=.
40418    for ac_exec_ext in '' $ac_executable_extensions; do
40419  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40420    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40421    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40422    break 2
40423  fi
40424done
40425  done
40426IFS=$as_save_IFS
40427
40428  ;;
40429esac
40430fi
40431JTREGEXE=$ac_cv_path_JTREGEXE
40432if test -n "$JTREGEXE"; then
40433  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40434$as_echo "$JTREGEXE" >&6; }
40435else
40436  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40437$as_echo "no" >&6; }
40438fi
40439
40440
40441  test -n "$JTREGEXE" && break
40442done
40443
40444    else
40445      # If it succeeded, then it was overridden by the user. We will use it
40446      # for the tool.
40447
40448      # First remove it from the list of overridden variables, so we can test
40449      # for unknown variables in the end.
40450      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40451
40452      # Check if the provided tool contains a complete path.
40453      tool_specified="$JTREGEXE"
40454      tool_basename="${tool_specified##*/}"
40455      if test "x$tool_basename" = "x$tool_specified"; then
40456        # A command without a complete path is provided, search $PATH.
40457        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
40458$as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
40459        # Extract the first word of "$tool_basename", so it can be a program name with args.
40460set dummy $tool_basename; ac_word=$2
40461{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40462$as_echo_n "checking for $ac_word... " >&6; }
40463if ${ac_cv_path_JTREGEXE+:} false; then :
40464  $as_echo_n "(cached) " >&6
40465else
40466  case $JTREGEXE in
40467  [\\/]* | ?:[\\/]*)
40468  ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
40469  ;;
40470  *)
40471  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40472for as_dir in $PATH
40473do
40474  IFS=$as_save_IFS
40475  test -z "$as_dir" && as_dir=.
40476    for ac_exec_ext in '' $ac_executable_extensions; do
40477  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40478    ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
40479    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40480    break 2
40481  fi
40482done
40483  done
40484IFS=$as_save_IFS
40485
40486  ;;
40487esac
40488fi
40489JTREGEXE=$ac_cv_path_JTREGEXE
40490if test -n "$JTREGEXE"; then
40491  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
40492$as_echo "$JTREGEXE" >&6; }
40493else
40494  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40495$as_echo "no" >&6; }
40496fi
40497
40498
40499        if test "x$JTREGEXE" = x; then
40500          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40501        fi
40502      else
40503        # Otherwise we believe it is a complete path. Use it as it is.
40504        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
40505$as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
40506        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
40507$as_echo_n "checking for JTREGEXE... " >&6; }
40508        if test ! -x "$tool_specified"; then
40509          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40510$as_echo "not found" >&6; }
40511          as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
40512        fi
40513        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40514$as_echo "$tool_specified" >&6; }
40515      fi
40516    fi
40517  fi
40518
40519
40520
40521  if test "x$JTREGEXE" = x; then
40522    as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
40523  fi
40524
40525
40526      JT_HOME="`$DIRNAME $JTREGEXE`"
40527    fi
40528  fi
40529
40530
40531
40532
40533
40534
40535  # Option used to tell the compiler whether to create 32- or 64-bit executables
40536  if test "x$TOOLCHAIN_TYPE" = xxlc; then
40537    COMPILER_TARGET_BITS_FLAG="-q"
40538  else
40539    COMPILER_TARGET_BITS_FLAG="-m"
40540  fi
40541
40542
40543  # FIXME: figure out if we should select AR flags depending on OS or toolchain.
40544  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
40545    ARFLAGS="-r"
40546  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40547    ARFLAGS="-X64"
40548  elif test "x$OPENJDK_TARGET_OS" = xwindows; then
40549    # lib.exe is used as AR to create static libraries.
40550    ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
40551  else
40552    ARFLAGS=""
40553  fi
40554
40555
40556  ## Setup strip.
40557  # FIXME: should this really be per platform, or should it be per toolchain type?
40558  # strip is not provided by clang or solstudio; so guessing platform makes most sense.
40559  # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD.
40560  if test "x$OPENJDK_TARGET_OS" = xlinux; then
40561    STRIPFLAGS="-g"
40562  elif test "x$OPENJDK_TARGET_OS" = xsolaris; then
40563    STRIPFLAGS="-x"
40564  elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
40565    STRIPFLAGS="-S"
40566  elif test "x$OPENJDK_TARGET_OS" = xaix; then
40567    STRIPFLAGS="-X32_64"
40568  fi
40569
40570  if test "x$OPENJDK_TARGET_OS" != xwindows; then
40571    POST_STRIP_CMD="$STRIP $STRIPFLAGS"
40572  fi
40573
40574
40575  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40576    # FIXME: break out into MCSFLAGS
40577    POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
40578  fi
40579
40580
40581  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40582    CC_OUT_OPTION=-Fo
40583    EXE_OUT_OPTION=-out:
40584    LD_OUT_OPTION=-out:
40585    AR_OUT_OPTION=-out:
40586  else
40587    # The option used to specify the target .o,.a or .so file.
40588    # When compiling, how to specify the to be created object file.
40589    CC_OUT_OPTION='-o$(SPACE)'
40590    # When linking, how to specify the to be created executable.
40591    EXE_OUT_OPTION='-o$(SPACE)'
40592    # When linking, how to specify the to be created dynamically linkable library.
40593    LD_OUT_OPTION='-o$(SPACE)'
40594    # When archiving, how to specify the to be create static archive for object files.
40595    AR_OUT_OPTION='rcs$(SPACE)'
40596  fi
40597
40598
40599
40600
40601
40602  # On Windows, we need to set RC flags.
40603  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40604    RC_FLAGS="-nologo -l 0x409 -r"
40605    if test "x$VARIANT" = xOPT; then
40606      RC_FLAGS="$RC_FLAGS -d NDEBUG"
40607    fi
40608
40609    # The version variables used to create RC_FLAGS may be overridden
40610    # in a custom configure script, or possibly the command line.
40611    # Let those variables be expanded at make time in spec.gmk.
40612    # The \$ are escaped to the shell, and the $(...) variables
40613    # are evaluated by make.
40614    RC_FLAGS="$RC_FLAGS \
40615        -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40616        -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40617        -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40618        -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40619        -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40620        -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40621        -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40622  fi
40623
40624
40625  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40626    # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40627    CCXXFLAGS="$CCXXFLAGS -nologo"
40628  fi
40629
40630
40631# FIXME: Currently we must test this after toolchain but before flags. Fix!
40632
40633# Now we can test some aspects on the target using configure macros.
40634
40635
40636{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40637$as_echo_n "checking for ANSI C header files... " >&6; }
40638if ${ac_cv_header_stdc+:} false; then :
40639  $as_echo_n "(cached) " >&6
40640else
40641  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40642/* end confdefs.h.  */
40643#include <stdlib.h>
40644#include <stdarg.h>
40645#include <string.h>
40646#include <float.h>
40647
40648int
40649main ()
40650{
40651
40652  ;
40653  return 0;
40654}
40655_ACEOF
40656if ac_fn_cxx_try_compile "$LINENO"; then :
40657  ac_cv_header_stdc=yes
40658else
40659  ac_cv_header_stdc=no
40660fi
40661rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40662
40663if test $ac_cv_header_stdc = yes; then
40664  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
40665  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40666/* end confdefs.h.  */
40667#include <string.h>
40668
40669_ACEOF
40670if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40671  $EGREP "memchr" >/dev/null 2>&1; then :
40672
40673else
40674  ac_cv_header_stdc=no
40675fi
40676rm -f conftest*
40677
40678fi
40679
40680if test $ac_cv_header_stdc = yes; then
40681  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
40682  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40683/* end confdefs.h.  */
40684#include <stdlib.h>
40685
40686_ACEOF
40687if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40688  $EGREP "free" >/dev/null 2>&1; then :
40689
40690else
40691  ac_cv_header_stdc=no
40692fi
40693rm -f conftest*
40694
40695fi
40696
40697if test $ac_cv_header_stdc = yes; then
40698  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
40699  if test "$cross_compiling" = yes; then :
40700  :
40701else
40702  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40703/* end confdefs.h.  */
40704#include <ctype.h>
40705#include <stdlib.h>
40706#if ((' ' & 0x0FF) == 0x020)
40707# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
40708# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
40709#else
40710# define ISLOWER(c) \
40711		   (('a' <= (c) && (c) <= 'i') \
40712		     || ('j' <= (c) && (c) <= 'r') \
40713		     || ('s' <= (c) && (c) <= 'z'))
40714# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
40715#endif
40716
40717#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
40718int
40719main ()
40720{
40721  int i;
40722  for (i = 0; i < 256; i++)
40723    if (XOR (islower (i), ISLOWER (i))
40724	|| toupper (i) != TOUPPER (i))
40725      return 2;
40726  return 0;
40727}
40728_ACEOF
40729if ac_fn_cxx_try_run "$LINENO"; then :
40730
40731else
40732  ac_cv_header_stdc=no
40733fi
40734rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40735  conftest.$ac_objext conftest.beam conftest.$ac_ext
40736fi
40737
40738fi
40739fi
40740{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
40741$as_echo "$ac_cv_header_stdc" >&6; }
40742if test $ac_cv_header_stdc = yes; then
40743
40744$as_echo "#define STDC_HEADERS 1" >>confdefs.h
40745
40746fi
40747
40748# On IRIX 5.3, sys/types and inttypes.h are conflicting.
40749for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
40750		  inttypes.h stdint.h unistd.h
40751do :
40752  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
40753ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
40754"
40755if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
40756  cat >>confdefs.h <<_ACEOF
40757#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
40758_ACEOF
40759
40760fi
40761
40762done
40763
40764
40765
40766  ###############################################################################
40767  #
40768  # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
40769  # (The JVM can use 32 or 64 bit Java pointers but that decision
40770  # is made at runtime.)
40771  #
40772
40773  if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
40774    # Always specify -m flag on Solaris
40775    # And -q on AIX because otherwise the compiler produces 32-bit objects by default
40776
40777  # When we add flags to the "official" CFLAGS etc, we need to
40778  # keep track of these additions in ADDED_CFLAGS etc. These
40779  # will later be checked to make sure only controlled additions
40780  # have been made to CFLAGS etc.
40781  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40782  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40783  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40784
40785  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40786  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40787  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40788
40789  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40790  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40791  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40792
40793  elif test "x$COMPILE_TYPE" = xreduced; then
40794    if test "x$OPENJDK_TARGET_OS" != xwindows; then
40795      # Specify -m if running reduced on other Posix platforms
40796
40797  # When we add flags to the "official" CFLAGS etc, we need to
40798  # keep track of these additions in ADDED_CFLAGS etc. These
40799  # will later be checked to make sure only controlled additions
40800  # have been made to CFLAGS etc.
40801  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40802  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40803  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40804
40805  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40806  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40807  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40808
40809  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40810  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40811  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40812
40813    fi
40814  fi
40815
40816  # Make compilation sanity check
40817  for ac_header in stdio.h
40818do :
40819  ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
40820if test "x$ac_cv_header_stdio_h" = xyes; then :
40821  cat >>confdefs.h <<_ACEOF
40822#define HAVE_STDIO_H 1
40823_ACEOF
40824
40825else
40826
40827    { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
40828$as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
40829    if test "x$COMPILE_TYPE" = xreduced; then
40830      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
40831$as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
40832    elif test "x$COMPILE_TYPE" = xcross; then
40833      { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
40834$as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
40835    fi
40836    as_fn_error $? "Cannot continue." "$LINENO" 5
40837
40838fi
40839
40840done
40841
40842
40843  # The cast to long int works around a bug in the HP C Compiler
40844# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40845# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40846# This bug is HP SR number 8606223364.
40847{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40848$as_echo_n "checking size of int *... " >&6; }
40849if ${ac_cv_sizeof_int_p+:} false; then :
40850  $as_echo_n "(cached) " >&6
40851else
40852  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40853
40854else
40855  if test "$ac_cv_type_int_p" = yes; then
40856     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40857$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40858as_fn_error 77 "cannot compute sizeof (int *)
40859See \`config.log' for more details" "$LINENO" 5; }
40860   else
40861     ac_cv_sizeof_int_p=0
40862   fi
40863fi
40864
40865fi
40866{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40867$as_echo "$ac_cv_sizeof_int_p" >&6; }
40868
40869
40870
40871cat >>confdefs.h <<_ACEOF
40872#define SIZEOF_INT_P $ac_cv_sizeof_int_p
40873_ACEOF
40874
40875
40876
40877  # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
40878  if test "x$ac_cv_sizeof_int_p" = x; then
40879    # The test failed, lets stick to the assumed value.
40880    { $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
40881$as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
40882  else
40883    TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40884
40885    if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40886      # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
40887      # Let's try to implicitely set the compilers target architecture and retry the test
40888      { $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
40889$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;}
40890      { $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
40891$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;}
40892
40893  # When we add flags to the "official" CFLAGS etc, we need to
40894  # keep track of these additions in ADDED_CFLAGS etc. These
40895  # will later be checked to make sure only controlled additions
40896  # have been made to CFLAGS etc.
40897  ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40898  ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40899  ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
40900
40901  CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
40902  CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
40903  LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
40904
40905  CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
40906  CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
40907  LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
40908
40909
40910      # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
40911      unset ac_cv_sizeof_int_p
40912      # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
40913      cat >>confdefs.h <<_ACEOF
40914#undef SIZEOF_INT_P
40915_ACEOF
40916
40917      # The cast to long int works around a bug in the HP C Compiler
40918# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
40919# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
40920# This bug is HP SR number 8606223364.
40921{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
40922$as_echo_n "checking size of int *... " >&6; }
40923if ${ac_cv_sizeof_int_p+:} false; then :
40924  $as_echo_n "(cached) " >&6
40925else
40926  if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
40927
40928else
40929  if test "$ac_cv_type_int_p" = yes; then
40930     { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
40931$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
40932as_fn_error 77 "cannot compute sizeof (int *)
40933See \`config.log' for more details" "$LINENO" 5; }
40934   else
40935     ac_cv_sizeof_int_p=0
40936   fi
40937fi
40938
40939fi
40940{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
40941$as_echo "$ac_cv_sizeof_int_p" >&6; }
40942
40943
40944
40945cat >>confdefs.h <<_ACEOF
40946#define SIZEOF_INT_P $ac_cv_sizeof_int_p
40947_ACEOF
40948
40949
40950
40951      TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
40952
40953      if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
40954        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
40955      fi
40956    fi
40957  fi
40958
40959  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
40960$as_echo_n "checking for target address size... " >&6; }
40961  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
40962$as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
40963
40964
40965  ###############################################################################
40966  #
40967  # Is the target little of big endian?
40968  #
40969   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
40970$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
40971if ${ac_cv_c_bigendian+:} false; then :
40972  $as_echo_n "(cached) " >&6
40973else
40974  ac_cv_c_bigendian=unknown
40975    # See if we're dealing with a universal compiler.
40976    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40977/* end confdefs.h.  */
40978#ifndef __APPLE_CC__
40979	       not a universal capable compiler
40980	     #endif
40981	     typedef int dummy;
40982
40983_ACEOF
40984if ac_fn_cxx_try_compile "$LINENO"; then :
40985
40986	# Check for potential -arch flags.  It is not universal unless
40987	# there are at least two -arch flags with different values.
40988	ac_arch=
40989	ac_prev=
40990	for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
40991	 if test -n "$ac_prev"; then
40992	   case $ac_word in
40993	     i?86 | x86_64 | ppc | ppc64)
40994	       if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
40995		 ac_arch=$ac_word
40996	       else
40997		 ac_cv_c_bigendian=universal
40998		 break
40999	       fi
41000	       ;;
41001	   esac
41002	   ac_prev=
41003	 elif test "x$ac_word" = "x-arch"; then
41004	   ac_prev=arch
41005	 fi
41006       done
41007fi
41008rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41009    if test $ac_cv_c_bigendian = unknown; then
41010      # See if sys/param.h defines the BYTE_ORDER macro.
41011      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41012/* end confdefs.h.  */
41013#include <sys/types.h>
41014	     #include <sys/param.h>
41015
41016int
41017main ()
41018{
41019#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
41020		     && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
41021		     && LITTLE_ENDIAN)
41022	      bogus endian macros
41023	     #endif
41024
41025  ;
41026  return 0;
41027}
41028_ACEOF
41029if ac_fn_cxx_try_compile "$LINENO"; then :
41030  # It does; now see whether it defined to BIG_ENDIAN or not.
41031	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41032/* end confdefs.h.  */
41033#include <sys/types.h>
41034		#include <sys/param.h>
41035
41036int
41037main ()
41038{
41039#if BYTE_ORDER != BIG_ENDIAN
41040		 not big endian
41041		#endif
41042
41043  ;
41044  return 0;
41045}
41046_ACEOF
41047if ac_fn_cxx_try_compile "$LINENO"; then :
41048  ac_cv_c_bigendian=yes
41049else
41050  ac_cv_c_bigendian=no
41051fi
41052rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41053fi
41054rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41055    fi
41056    if test $ac_cv_c_bigendian = unknown; then
41057      # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
41058      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41059/* end confdefs.h.  */
41060#include <limits.h>
41061
41062int
41063main ()
41064{
41065#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
41066	      bogus endian macros
41067	     #endif
41068
41069  ;
41070  return 0;
41071}
41072_ACEOF
41073if ac_fn_cxx_try_compile "$LINENO"; then :
41074  # It does; now see whether it defined to _BIG_ENDIAN or not.
41075	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41076/* end confdefs.h.  */
41077#include <limits.h>
41078
41079int
41080main ()
41081{
41082#ifndef _BIG_ENDIAN
41083		 not big endian
41084		#endif
41085
41086  ;
41087  return 0;
41088}
41089_ACEOF
41090if ac_fn_cxx_try_compile "$LINENO"; then :
41091  ac_cv_c_bigendian=yes
41092else
41093  ac_cv_c_bigendian=no
41094fi
41095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41096fi
41097rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41098    fi
41099    if test $ac_cv_c_bigendian = unknown; then
41100      # Compile a test program.
41101      if test "$cross_compiling" = yes; then :
41102  # Try to guess by grepping values from an object file.
41103	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41104/* end confdefs.h.  */
41105short int ascii_mm[] =
41106		  { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
41107		short int ascii_ii[] =
41108		  { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
41109		int use_ascii (int i) {
41110		  return ascii_mm[i] + ascii_ii[i];
41111		}
41112		short int ebcdic_ii[] =
41113		  { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
41114		short int ebcdic_mm[] =
41115		  { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
41116		int use_ebcdic (int i) {
41117		  return ebcdic_mm[i] + ebcdic_ii[i];
41118		}
41119		extern int foo;
41120
41121int
41122main ()
41123{
41124return use_ascii (foo) == use_ebcdic (foo);
41125  ;
41126  return 0;
41127}
41128_ACEOF
41129if ac_fn_cxx_try_compile "$LINENO"; then :
41130  if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
41131	      ac_cv_c_bigendian=yes
41132	    fi
41133	    if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
41134	      if test "$ac_cv_c_bigendian" = unknown; then
41135		ac_cv_c_bigendian=no
41136	      else
41137		# finding both strings is unlikely to happen, but who knows?
41138		ac_cv_c_bigendian=unknown
41139	      fi
41140	    fi
41141fi
41142rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41143else
41144  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41145/* end confdefs.h.  */
41146$ac_includes_default
41147int
41148main ()
41149{
41150
41151	     /* Are we little or big endian?  From Harbison&Steele.  */
41152	     union
41153	     {
41154	       long int l;
41155	       char c[sizeof (long int)];
41156	     } u;
41157	     u.l = 1;
41158	     return u.c[sizeof (long int) - 1] == 1;
41159
41160  ;
41161  return 0;
41162}
41163_ACEOF
41164if ac_fn_cxx_try_run "$LINENO"; then :
41165  ac_cv_c_bigendian=no
41166else
41167  ac_cv_c_bigendian=yes
41168fi
41169rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41170  conftest.$ac_objext conftest.beam conftest.$ac_ext
41171fi
41172
41173    fi
41174fi
41175{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
41176$as_echo "$ac_cv_c_bigendian" >&6; }
41177 case $ac_cv_c_bigendian in #(
41178   yes)
41179     ENDIAN="big";; #(
41180   no)
41181     ENDIAN="little" ;; #(
41182   universal)
41183     ENDIAN="universal_endianness"
41184     ;; #(
41185   *)
41186     ENDIAN="unknown" ;;
41187 esac
41188
41189
41190  if test "x$ENDIAN" = xuniversal_endianness; then
41191    as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
41192  fi
41193  if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
41194    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
41195  fi
41196
41197
41198# Configure flags for the tools
41199
41200  ###############################################################################
41201  #
41202  # How to compile shared libraries.
41203  #
41204
41205  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41206    PICFLAG="-fPIC"
41207    C_FLAG_REORDER=''
41208    CXX_FLAG_REORDER=''
41209
41210    if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41211      # Linking is different on MacOSX
41212      SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41213      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41214      SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41215      SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41216      SET_SHARED_LIBRARY_MAPFILE=''
41217    else
41218      # Default works for linux, might work on other platforms as well.
41219      SHARED_LIBRARY_FLAGS='-shared'
41220      SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41221      SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
41222      SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41223      SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41224    fi
41225  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41226    PICFLAG="-KPIC"
41227    C_FLAG_REORDER='-xF'
41228    CXX_FLAG_REORDER='-xF'
41229    SHARED_LIBRARY_FLAGS="-G"
41230    SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1'
41231    SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
41232    SET_SHARED_LIBRARY_NAME=''
41233    SET_SHARED_LIBRARY_MAPFILE='-M$1'
41234  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41235    PICFLAG="-qpic=large"
41236    C_FLAG_REORDER=''
41237    CXX_FLAG_REORDER=''
41238    SHARED_LIBRARY_FLAGS="-qmkshrobj"
41239    SET_EXECUTABLE_ORIGIN=""
41240    SET_SHARED_LIBRARY_ORIGIN=''
41241    SET_SHARED_LIBRARY_NAME=''
41242    SET_SHARED_LIBRARY_MAPFILE=''
41243  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41244    PICFLAG=""
41245    C_FLAG_REORDER=''
41246    CXX_FLAG_REORDER=''
41247    SHARED_LIBRARY_FLAGS="-LD"
41248    SET_EXECUTABLE_ORIGIN=''
41249    SET_SHARED_LIBRARY_ORIGIN=''
41250    SET_SHARED_LIBRARY_NAME=''
41251    SET_SHARED_LIBRARY_MAPFILE=''
41252  fi
41253
41254
41255
41256
41257
41258
41259
41260
41261
41262  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41263    CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
41264    CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
41265    CFLAGS_JDKLIB_EXTRA='-xstrconst'
41266  fi
41267  # The (cross) compiler is now configured, we can now test capabilities
41268  # of the target platform.
41269
41270
41271
41272  ###############################################################################
41273  #
41274  # Setup the opt flags for different compilers
41275  # and different operating systems.
41276  #
41277
41278  # FIXME: this was indirectly the old default, but just inherited.
41279  # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41280  #   C_FLAG_DEPS="-MMD -MF"
41281  # fi
41282
41283  # Generate make dependency files
41284  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41285    C_FLAG_DEPS="-MMD -MF"
41286  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41287    C_FLAG_DEPS="-xMMD -xMF"
41288  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41289    C_FLAG_DEPS="-qmakedep=gcc -MF"
41290  fi
41291  CXX_FLAG_DEPS="$C_FLAG_DEPS"
41292
41293
41294
41295  # Debug symbols
41296  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41297    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
41298      CFLAGS_DEBUG_SYMBOLS="-g1"
41299      CXXFLAGS_DEBUG_SYMBOLS="-g1"
41300    else
41301      CFLAGS_DEBUG_SYMBOLS="-g"
41302      CXXFLAGS_DEBUG_SYMBOLS="-g"
41303    fi
41304  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41305    CFLAGS_DEBUG_SYMBOLS="-g -xs"
41306    CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
41307  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41308    CFLAGS_DEBUG_SYMBOLS="-g"
41309    CXXFLAGS_DEBUG_SYMBOLS="-g"
41310  fi
41311
41312
41313
41314  # Optimization levels
41315  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41316    CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xalias_level=basic -xbuiltin=%all -xdepend -xrestrict -xlibmil"
41317
41318    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
41319      # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global?
41320      C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr"
41321      C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
41322      C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
41323      C_O_FLAG_NONE="-xregs=no%frameptr"
41324      CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
41325      CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
41326      CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
41327      CXX_O_FLAG_NONE="-xregs=no%frameptr"
41328      if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41329        C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
41330        CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
41331      fi
41332    elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41333      C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41334      C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41335      C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41336      C_O_FLAG_NONE=""
41337      CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41338      CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41339      CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41340      CXX_O_FLAG_NONE=""
41341    fi
41342  else
41343    # The remaining toolchains share opt flags between CC and CXX;
41344    # setup for C and duplicate afterwards.
41345    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41346      if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41347        # On MacOSX we optimize for size, something
41348        # we should do for all platforms?
41349        C_O_FLAG_HIGHEST="-Os"
41350        C_O_FLAG_HI="-Os"
41351        C_O_FLAG_NORM="-Os"
41352        C_O_FLAG_NONE=""
41353      else
41354        C_O_FLAG_HIGHEST="-O3"
41355        C_O_FLAG_HI="-O3"
41356        C_O_FLAG_NORM="-O2"
41357        C_O_FLAG_NONE="-O0"
41358      fi
41359    elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41360      C_O_FLAG_HIGHEST="-O3"
41361      C_O_FLAG_HI="-O3 -qstrict"
41362      C_O_FLAG_NORM="-O2"
41363      C_O_FLAG_NONE=""
41364    elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41365      C_O_FLAG_HIGHEST="-O2"
41366      C_O_FLAG_HI="-O1"
41367      C_O_FLAG_NORM="-O1"
41368      C_O_FLAG_NONE="-Od"
41369    fi
41370    CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
41371    CXX_O_FLAG_HI="$C_O_FLAG_HI"
41372    CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41373    CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41374  fi
41375
41376
41377
41378
41379
41380
41381
41382
41383
41384
41385
41386  # Special extras...
41387  if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41388    if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
41389      CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41390      CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41391    fi
41392  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41393    LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
41394    CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41395    CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41396  fi
41397
41398  if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
41399    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
41400$as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
41401  fi
41402
41403  if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
41404    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
41405$as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
41406  fi
41407
41408  if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
41409    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
41410$as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
41411  fi
41412
41413
41414# Check whether --with-extra-cflags was given.
41415if test "${with_extra_cflags+set}" = set; then :
41416  withval=$with_extra_cflags;
41417fi
41418
41419
41420
41421# Check whether --with-extra-cxxflags was given.
41422if test "${with_extra_cxxflags+set}" = set; then :
41423  withval=$with_extra_cxxflags;
41424fi
41425
41426
41427
41428# Check whether --with-extra-ldflags was given.
41429if test "${with_extra_ldflags+set}" = set; then :
41430  withval=$with_extra_ldflags;
41431fi
41432
41433
41434  CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41435  CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41436  LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41437
41438  # Hotspot needs these set in their legacy form
41439  LEGACY_EXTRA_CFLAGS=$with_extra_cflags
41440  LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags
41441  LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags
41442
41443
41444
41445
41446
41447  ###############################################################################
41448  #
41449  # Now setup the CFLAGS and LDFLAGS for the JDK build.
41450  # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41451  #
41452
41453  # Setup compiler/platform specific flags to CFLAGS_JDK,
41454  # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41455  if test "x$TOOLCHAIN_TYPE" = xgcc; then
41456    # these options are used for both C and C++ compiles
41457    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41458        -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41459    case $OPENJDK_TARGET_CPU_ARCH in
41460      arm )
41461        # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
41462        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41463        ;;
41464      ppc )
41465        # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing
41466        ;;
41467      * )
41468        CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer"
41469        CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41470        ;;
41471    esac
41472  elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41473    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
41474    if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
41475      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
41476      CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
41477    fi
41478
41479    CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
41480    CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
41481  elif test "x$TOOLCHAIN_TYPE" = xxlc; then
41482    CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41483    CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41484  elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41485    CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
41486    -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
41487    -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
41488    -DWIN32 -DIAL"
41489    if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
41490      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64"
41491    else
41492      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86"
41493    fi
41494  fi
41495
41496  ###############################################################################
41497
41498  # Adjust flags according to debug level.
41499  case $DEBUG_LEVEL in
41500    fastdebug )
41501      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41502      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41503      C_O_FLAG_HI="$C_O_FLAG_NORM"
41504      C_O_FLAG_NORM="$C_O_FLAG_NORM"
41505      CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
41506      CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM"
41507      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41508      ;;
41509    slowdebug )
41510      CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41511      CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41512      C_O_FLAG_HI="$C_O_FLAG_NONE"
41513      C_O_FLAG_NORM="$C_O_FLAG_NONE"
41514      CXX_O_FLAG_HI="$CXX_O_FLAG_NONE"
41515      CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE"
41516      JAVAC_FLAGS="$JAVAC_FLAGS -g"
41517      ;;
41518  esac
41519
41520  # Setup LP64
41521  CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41522
41523  # Set some common defines. These works for all compilers, but assume
41524  # -D is universally accepted.
41525
41526  # Setup endianness
41527  if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41528    # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41529    #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41530    #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41531    #   Note: -Dmacro         is the same as    #define macro 1
41532    #         -Dmacro=        is the same as    #define macro
41533    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41534      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41535    else
41536      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41537    fi
41538  else
41539    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41540  fi
41541
41542  # Setup target OS define. Use OS target name but in upper case.
41543  OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41544  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41545
41546  # Setup target CPU
41547  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41548
41549  # Setup debug/release defines
41550  if test "x$DEBUG_LEVEL" = xrelease; then
41551    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41552    if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41553      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41554    fi
41555  else
41556    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41557  fi
41558
41559  # Setup release name
41560  CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
41561
41562
41563  # Set some additional per-OS defines.
41564  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41565    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
41566  elif test "x$OPENJDK_TARGET_OS" = xaix; then
41567    # FIXME: PPC64 should not be here.
41568    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DPPC64"
41569  elif test "x$OPENJDK_TARGET_OS" = xbsd; then
41570    CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
41571  fi
41572
41573  # Additional macosx handling
41574  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41575    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41576      # FIXME: This needs to be exported in spec.gmk due to closed legacy code.
41577      # FIXME: clean this up, and/or move it elsewhere.
41578
41579      # Setting these parameters makes it an error to link to macosx APIs that are
41580      # newer than the given OS version and makes the linked binaries compatible
41581      # even if built on a newer version of the OS.
41582      # The expected format is X.Y.Z
41583      MACOSX_VERSION_MIN=10.7.0
41584
41585
41586      # The macro takes the version with no dots, ex: 1070
41587      # Let the flags variables get resolved in make for easier override on make
41588      # command line.
41589      CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41590      LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
41591    fi
41592  fi
41593
41594  # Setup some hard coded includes
41595  CCXXFLAGS_JDK="$CCXXFLAGS_JDK \
41596      -I${JDK_OUTPUTDIR}/include \
41597      -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \
41598      -I${JDK_TOPDIR}/src/share/javavm/export \
41599      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_EXPORT_DIR/javavm/export \
41600      -I${JDK_TOPDIR}/src/share/native/common \
41601      -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common"
41602
41603  # The shared libraries are compiled using the picflag.
41604  CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
41605  CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
41606
41607  # Executable flags
41608  CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK"
41609  CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK"
41610
41611
41612
41613
41614
41615
41616  # Setup LDFLAGS et al.
41617  #
41618  # Now this is odd. The JDK native libraries have to link against libjvm.so
41619  # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
41620  # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
41621  # is identical for client and server? Yes. Which is picked at runtime (client or server)?
41622  # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
41623  # libraries will link to whatever is in memory. Yuck.
41624  #
41625  # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
41626  if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41627    LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
41628    if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
41629      LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
41630    fi
41631    # TODO: make -debug optional "--disable-full-debug-symbols"
41632    LDFLAGS_JDK="$LDFLAGS_JDK -debug"
41633    LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib"
41634    LDFLAGS_JDKLIB_SUFFIX=""
41635    if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
41636      LDFLAGS_STACK_SIZE=1048576
41637    else
41638      LDFLAGS_STACK_SIZE=327680
41639    fi
41640    LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE"
41641  else
41642    if test "x$TOOLCHAIN_TYPE" = xgcc; then
41643      # If this is a --hash-style=gnu system, use --hash-style=both, why?
41644      # We have previously set HAS_GNU_HASH if this is the case
41645      if test -n "$HAS_GNU_HASH"; then
41646        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both "
41647      fi
41648      if test "x$OPENJDK_TARGET_OS" = xlinux; then
41649        # And since we now know that the linker is gnu, then add -z defs, to forbid
41650        # undefined symbols in object files.
41651        LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
41652        if test "x$DEBUG_LEVEL" = "xrelease"; then
41653          # When building release libraries, tell the linker optimize them.
41654          # Should this be supplied to the OSS linker as well?
41655          LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
41656        fi
41657      fi
41658    fi
41659
41660    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41661      LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
41662      LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
41663    fi
41664
41665    LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \
41666        -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
41667
41668    # On some platforms (mac) the linker warns about non existing -L dirs.
41669    # Add server first if available. Linking aginst client does not always produce the same results.
41670    # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
41671    # Default to server for other variants.
41672    if test "x$JVM_VARIANT_SERVER" = xtrue; then
41673      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41674    elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
41675      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
41676    elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
41677      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
41678    else
41679      LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
41680    fi
41681
41682    LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
41683    if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41684      LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
41685    fi
41686
41687    LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
41688    if test "x$OPENJDK_TARGET_OS" = xlinux; then
41689      LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
41690    fi
41691  fi
41692
41693
41694
41695
41696
41697
41698
41699
41700  # Some Zero and Shark settings.
41701  # ZERO_ARCHFLAG tells the compiler which mode to build for
41702  case "${OPENJDK_TARGET_CPU}" in
41703    s390)
41704      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
41705      ;;
41706    *)
41707      ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41708  esac
41709
41710  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
41711$as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
41712  supports=yes
41713
41714  saved_cflags="$CFLAGS"
41715  CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
41716  ac_ext=c
41717ac_cpp='$CPP $CPPFLAGS'
41718ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41719ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41720ac_compiler_gnu=$ac_cv_c_compiler_gnu
41721
41722  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41723/* end confdefs.h.  */
41724int i;
41725_ACEOF
41726if ac_fn_c_try_compile "$LINENO"; then :
41727
41728else
41729  supports=no
41730fi
41731rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41732  ac_ext=cpp
41733ac_cpp='$CXXCPP $CPPFLAGS'
41734ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41735ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41736ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41737
41738  CFLAGS="$saved_cflags"
41739
41740  saved_cxxflags="$CXXFLAGS"
41741  CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
41742  ac_ext=cpp
41743ac_cpp='$CXXCPP $CPPFLAGS'
41744ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41745ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41746ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41747
41748  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41749/* end confdefs.h.  */
41750int i;
41751_ACEOF
41752if ac_fn_cxx_try_compile "$LINENO"; then :
41753
41754else
41755  supports=no
41756fi
41757rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41758  ac_ext=cpp
41759ac_cpp='$CXXCPP $CPPFLAGS'
41760ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41761ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41762ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41763
41764  CXXFLAGS="$saved_cxxflags"
41765
41766  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41767$as_echo "$supports" >&6; }
41768  if test "x$supports" = "xyes" ; then
41769    :
41770  else
41771    ZERO_ARCHFLAG=""
41772  fi
41773
41774
41775
41776  # Check that the compiler supports -mX (or -qX on AIX) flags
41777  # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
41778
41779  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
41780$as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
41781  supports=yes
41782
41783  saved_cflags="$CFLAGS"
41784  CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41785  ac_ext=c
41786ac_cpp='$CPP $CPPFLAGS'
41787ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41788ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41789ac_compiler_gnu=$ac_cv_c_compiler_gnu
41790
41791  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41792/* end confdefs.h.  */
41793int i;
41794_ACEOF
41795if ac_fn_c_try_compile "$LINENO"; then :
41796
41797else
41798  supports=no
41799fi
41800rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41801  ac_ext=cpp
41802ac_cpp='$CXXCPP $CPPFLAGS'
41803ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41804ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41805ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41806
41807  CFLAGS="$saved_cflags"
41808
41809  saved_cxxflags="$CXXFLAGS"
41810  CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41811  ac_ext=cpp
41812ac_cpp='$CXXCPP $CPPFLAGS'
41813ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41814ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41815ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41816
41817  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41818/* end confdefs.h.  */
41819int i;
41820_ACEOF
41821if ac_fn_cxx_try_compile "$LINENO"; then :
41822
41823else
41824  supports=no
41825fi
41826rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41827  ac_ext=cpp
41828ac_cpp='$CXXCPP $CPPFLAGS'
41829ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41830ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41831ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41832
41833  CXXFLAGS="$saved_cxxflags"
41834
41835  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41836$as_echo "$supports" >&6; }
41837  if test "x$supports" = "xyes" ; then
41838    COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
41839  else
41840    COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
41841  fi
41842
41843
41844
41845
41846# Setup debug symbols (need objcopy from the toolchain for that)
41847
41848  #
41849  # ENABLE_DEBUG_SYMBOLS
41850  # This must be done after the toolchain is setup, since we're looking at objcopy.
41851  #
41852  # Check whether --enable-debug-symbols was given.
41853if test "${enable_debug_symbols+set}" = set; then :
41854  enableval=$enable_debug_symbols;
41855fi
41856
41857
41858  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
41859$as_echo_n "checking if we should generate debug symbols... " >&6; }
41860
41861  if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
41862    # explicit enabling of enable-debug-symbols and can't find objcopy
41863    #   this is an error
41864    as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
41865  fi
41866
41867  if test "x$enable_debug_symbols" = "xyes"; then
41868    ENABLE_DEBUG_SYMBOLS=true
41869  elif test "x$enable_debug_symbols" = "xno"; then
41870    ENABLE_DEBUG_SYMBOLS=false
41871  else
41872    # Default is on if objcopy is found
41873    if test "x$OBJCOPY" != x; then
41874      ENABLE_DEBUG_SYMBOLS=true
41875    # MacOS X and Windows don't use objcopy but default is on for those OSes
41876    elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
41877      ENABLE_DEBUG_SYMBOLS=true
41878    else
41879      ENABLE_DEBUG_SYMBOLS=false
41880    fi
41881  fi
41882
41883  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
41884$as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
41885
41886  #
41887  # ZIP_DEBUGINFO_FILES
41888  #
41889  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
41890$as_echo_n "checking if we should zip debug-info files... " >&6; }
41891  # Check whether --enable-zip-debug-info was given.
41892if test "${enable_zip_debug_info+set}" = set; then :
41893  enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
41894else
41895  enable_zip_debug_info="yes"
41896fi
41897
41898  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
41899$as_echo "${enable_zip_debug_info}" >&6; }
41900
41901  if test "x${enable_zip_debug_info}" = "xno"; then
41902    ZIP_DEBUGINFO_FILES=false
41903  else
41904    ZIP_DEBUGINFO_FILES=true
41905  fi
41906
41907
41908
41909
41910
41911###############################################################################
41912#
41913# Check dependencies for external and internal libraries.
41914#
41915###############################################################################
41916
41917# After we have toolchain, we can compile fixpath. It's needed by the lib checks.
41918
41919  # When using cygwin or msys, we need a wrapper binary that renames
41920  # /cygdrive/c/ arguments into c:/ arguments and peeks into
41921  # @files and rewrites these too! This wrapper binary is
41922  # called fixpath.
41923  FIXPATH=
41924  if test "x$OPENJDK_BUILD_OS" = xwindows; then
41925    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
41926$as_echo_n "checking if fixpath can be created... " >&6; }
41927    FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
41928    FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
41929    if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
41930      FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
41931      FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
41932      # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
41933      FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
41934    elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
41935      FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
41936      FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
41937
41938      # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
41939      # @ was chosen as separator to minimize risk of other tools messing around with it
41940      all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
41941      fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
41942
41943      FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
41944    fi
41945    rm -f $OUTPUT_ROOT/fixpath*
41946    cd $OUTPUT_ROOT
41947    $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
41948    cd $CURDIR
41949
41950    if test ! -x $OUTPUT_ROOT/fixpath.exe; then
41951      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41952$as_echo "no" >&6; }
41953      cat $OUTPUT_ROOT/fixpath1.log
41954      as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
41955    fi
41956    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41957$as_echo "yes" >&6; }
41958    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
41959$as_echo_n "checking if fixpath.exe works... " >&6; }
41960    cd $OUTPUT_ROOT
41961    $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
41962    cd $CURDIR
41963    if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
41964      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41965$as_echo "no" >&6; }
41966      cat $OUTPUT_ROOT/fixpath2.log
41967      as_fn_error $? "fixpath did not work!" "$LINENO" 5
41968    fi
41969    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41970$as_echo "yes" >&6; }
41971    rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
41972  fi
41973
41974
41975
41976
41977
41978
41979  ###############################################################################
41980  #
41981  # OS specific settings that we never will need to probe.
41982  #
41983  if test "x$OPENJDK_TARGET_OS" = xlinux; then
41984    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
41985$as_echo_n "checking what is not needed on Linux?... " >&6; }
41986    PULSE_NOT_NEEDED=yes
41987    { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
41988$as_echo "pulse" >&6; }
41989  fi
41990
41991  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41992    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
41993$as_echo_n "checking what is not needed on Solaris?... " >&6; }
41994    ALSA_NOT_NEEDED=yes
41995    PULSE_NOT_NEEDED=yes
41996    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
41997$as_echo "alsa pulse" >&6; }
41998  fi
41999
42000  if test "x$OPENJDK_TARGET_OS" = xaix; then
42001    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
42002$as_echo_n "checking what is not needed on AIX?... " >&6; }
42003    ALSA_NOT_NEEDED=yes
42004    PULSE_NOT_NEEDED=yes
42005    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42006$as_echo "alsa pulse" >&6; }
42007  fi
42008
42009
42010  if test "x$OPENJDK_TARGET_OS" = xwindows; then
42011    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
42012$as_echo_n "checking what is not needed on Windows?... " >&6; }
42013    CUPS_NOT_NEEDED=yes
42014    ALSA_NOT_NEEDED=yes
42015    PULSE_NOT_NEEDED=yes
42016    X11_NOT_NEEDED=yes
42017    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
42018$as_echo "alsa cups pulse x11" >&6; }
42019  fi
42020
42021  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42022    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
42023$as_echo_n "checking what is not needed on MacOSX?... " >&6; }
42024    ALSA_NOT_NEEDED=yes
42025    PULSE_NOT_NEEDED=yes
42026    X11_NOT_NEEDED=yes
42027    # If the java runtime framework is disabled, then we need X11.
42028    # This will be adjusted below.
42029    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
42030$as_echo "alsa pulse x11" >&6; }
42031  fi
42032
42033  if test "x$OPENJDK_TARGET_OS" = xbsd; then
42034    { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
42035$as_echo_n "checking what is not needed on bsd?... " >&6; }
42036    ALSA_NOT_NEEDED=yes
42037    { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
42038$as_echo "alsa" >&6; }
42039  fi
42040
42041  if test "x$OPENJDK" = "xfalse"; then
42042    FREETYPE_NOT_NEEDED=yes
42043  fi
42044
42045  if test "x$SUPPORT_HEADFUL" = xno; then
42046    X11_NOT_NEEDED=yes
42047  fi
42048
42049  ###############################################################################
42050  #
42051  # Check for MacOSX support for OpenJDK.
42052  #
42053
42054
42055  # Check whether --enable-macosx-runtime-support was given.
42056if test "${enable_macosx_runtime_support+set}" = set; then :
42057  enableval=$enable_macosx_runtime_support;
42058fi
42059
42060  if test "x$enable_macosx_runtime_support" != x; then
42061    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&5
42062$as_echo "$as_me: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&2;}
42063  fi
42064
42065
42066  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42067$as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42068  if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42069    { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42070$as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42071  else
42072    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42073$as_echo "no" >&6; }
42074  fi
42075
42076
42077
42078  ###############################################################################
42079  #
42080  # Check for X Windows
42081  #
42082
42083  # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42084  # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42085  # --x-libraries for the sysroot, if that seems to be correct.
42086  if test "x$SYS_ROOT" != "x/"; then
42087    if test "x$x_includes" = xNONE; then
42088      if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then
42089        x_includes="$SYS_ROOT/usr/X11R6/include"
42090      elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then
42091        x_includes="$SYS_ROOT/usr/include"
42092      fi
42093    fi
42094    if test "x$x_libraries" = xNONE; then
42095      if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then
42096        x_libraries="$SYS_ROOT/usr/X11R6/lib"
42097      elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42098        x_libraries="$SYS_ROOT/usr/lib64"
42099      elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then
42100        x_libraries="$SYS_ROOT/usr/lib"
42101      fi
42102    fi
42103  fi
42104
42105  # Now let autoconf do it's magic
42106  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42107$as_echo_n "checking for X... " >&6; }
42108
42109
42110# Check whether --with-x was given.
42111if test "${with_x+set}" = set; then :
42112  withval=$with_x;
42113fi
42114
42115# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42116if test "x$with_x" = xno; then
42117  # The user explicitly disabled X.
42118  have_x=disabled
42119else
42120  case $x_includes,$x_libraries in #(
42121    *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
42122    *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
42123  $as_echo_n "(cached) " >&6
42124else
42125  # One or both of the vars are not set, and there is no cached value.
42126ac_x_includes=no ac_x_libraries=no
42127rm -f -r conftest.dir
42128if mkdir conftest.dir; then
42129  cd conftest.dir
42130  cat >Imakefile <<'_ACEOF'
42131incroot:
42132	@echo incroot='${INCROOT}'
42133usrlibdir:
42134	@echo usrlibdir='${USRLIBDIR}'
42135libdir:
42136	@echo libdir='${LIBDIR}'
42137_ACEOF
42138  if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
42139    # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
42140    for ac_var in incroot usrlibdir libdir; do
42141      eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
42142    done
42143    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
42144    for ac_extension in a so sl dylib la dll; do
42145      if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
42146	 test -f "$ac_im_libdir/libX11.$ac_extension"; then
42147	ac_im_usrlibdir=$ac_im_libdir; break
42148      fi
42149    done
42150    # Screen out bogus values from the imake configuration.  They are
42151    # bogus both because they are the default anyway, and because
42152    # using them would break gcc on systems where it needs fixed includes.
42153    case $ac_im_incroot in
42154	/usr/include) ac_x_includes= ;;
42155	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
42156    esac
42157    case $ac_im_usrlibdir in
42158	/usr/lib | /usr/lib64 | /lib | /lib64) ;;
42159	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
42160    esac
42161  fi
42162  cd ..
42163  rm -f -r conftest.dir
42164fi
42165
42166# Standard set of common directories for X headers.
42167# Check X11 before X11Rn because it is often a symlink to the current release.
42168ac_x_header_dirs='
42169/usr/X11/include
42170/usr/X11R7/include
42171/usr/X11R6/include
42172/usr/X11R5/include
42173/usr/X11R4/include
42174
42175/usr/include/X11
42176/usr/include/X11R7
42177/usr/include/X11R6
42178/usr/include/X11R5
42179/usr/include/X11R4
42180
42181/usr/local/X11/include
42182/usr/local/X11R7/include
42183/usr/local/X11R6/include
42184/usr/local/X11R5/include
42185/usr/local/X11R4/include
42186
42187/usr/local/include/X11
42188/usr/local/include/X11R7
42189/usr/local/include/X11R6
42190/usr/local/include/X11R5
42191/usr/local/include/X11R4
42192
42193/usr/X386/include
42194/usr/x386/include
42195/usr/XFree86/include/X11
42196
42197/usr/include
42198/usr/local/include
42199/usr/unsupported/include
42200/usr/athena/include
42201/usr/local/x11r5/include
42202/usr/lpp/Xamples/include
42203
42204/usr/openwin/include
42205/usr/openwin/share/include'
42206
42207if test "$ac_x_includes" = no; then
42208  # Guess where to find include files, by looking for Xlib.h.
42209  # First, try using that file with no special directory specified.
42210  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42211/* end confdefs.h.  */
42212#include <X11/Xlib.h>
42213_ACEOF
42214if ac_fn_cxx_try_cpp "$LINENO"; then :
42215  # We can compile using X headers with no special include directory.
42216ac_x_includes=
42217else
42218  for ac_dir in $ac_x_header_dirs; do
42219  if test -r "$ac_dir/X11/Xlib.h"; then
42220    ac_x_includes=$ac_dir
42221    break
42222  fi
42223done
42224fi
42225rm -f conftest.err conftest.i conftest.$ac_ext
42226fi # $ac_x_includes = no
42227
42228if test "$ac_x_libraries" = no; then
42229  # Check for the libraries.
42230  # See if we find them without any special options.
42231  # Don't add to $LIBS permanently.
42232  ac_save_LIBS=$LIBS
42233  LIBS="-lX11 $LIBS"
42234  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42235/* end confdefs.h.  */
42236#include <X11/Xlib.h>
42237int
42238main ()
42239{
42240XrmInitialize ()
42241  ;
42242  return 0;
42243}
42244_ACEOF
42245if ac_fn_cxx_try_link "$LINENO"; then :
42246  LIBS=$ac_save_LIBS
42247# We can link X programs with no special library path.
42248ac_x_libraries=
42249else
42250  LIBS=$ac_save_LIBS
42251for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
42252do
42253  # Don't even attempt the hair of trying to link an X program!
42254  for ac_extension in a so sl dylib la dll; do
42255    if test -r "$ac_dir/libX11.$ac_extension"; then
42256      ac_x_libraries=$ac_dir
42257      break 2
42258    fi
42259  done
42260done
42261fi
42262rm -f core conftest.err conftest.$ac_objext \
42263    conftest$ac_exeext conftest.$ac_ext
42264fi # $ac_x_libraries = no
42265
42266case $ac_x_includes,$ac_x_libraries in #(
42267  no,* | *,no | *\'*)
42268    # Didn't find X, or a directory has "'" in its name.
42269    ac_cv_have_x="have_x=no";; #(
42270  *)
42271    # Record where we found X for the cache.
42272    ac_cv_have_x="have_x=yes\
42273	ac_x_includes='$ac_x_includes'\
42274	ac_x_libraries='$ac_x_libraries'"
42275esac
42276fi
42277;; #(
42278    *) have_x=yes;;
42279  esac
42280  eval "$ac_cv_have_x"
42281fi # $with_x != no
42282
42283if test "$have_x" != yes; then
42284  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
42285$as_echo "$have_x" >&6; }
42286  no_x=yes
42287else
42288  # If each of the values was on the command line, it overrides each guess.
42289  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
42290  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
42291  # Update the cache value to reflect the command line values.
42292  ac_cv_have_x="have_x=yes\
42293	ac_x_includes='$x_includes'\
42294	ac_x_libraries='$x_libraries'"
42295  { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
42296$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
42297fi
42298
42299  if test "$no_x" = yes; then
42300  # Not all programs may use this symbol, but it does not hurt to define it.
42301
42302$as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
42303
42304  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
42305else
42306  if test -n "$x_includes"; then
42307    X_CFLAGS="$X_CFLAGS -I$x_includes"
42308  fi
42309
42310  # It would also be nice to do this for all -L options, not just this one.
42311  if test -n "$x_libraries"; then
42312    X_LIBS="$X_LIBS -L$x_libraries"
42313    # For Solaris; some versions of Sun CC require a space after -R and
42314    # others require no space.  Words are not sufficient . . . .
42315    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
42316$as_echo_n "checking whether -R must be followed by a space... " >&6; }
42317    ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
42318    ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
42319    ac_cxx_werror_flag=yes
42320    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42321/* end confdefs.h.  */
42322
42323int
42324main ()
42325{
42326
42327  ;
42328  return 0;
42329}
42330_ACEOF
42331if ac_fn_cxx_try_link "$LINENO"; then :
42332  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42333$as_echo "no" >&6; }
42334       X_LIBS="$X_LIBS -R$x_libraries"
42335else
42336  LIBS="$ac_xsave_LIBS -R $x_libraries"
42337       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42338/* end confdefs.h.  */
42339
42340int
42341main ()
42342{
42343
42344  ;
42345  return 0;
42346}
42347_ACEOF
42348if ac_fn_cxx_try_link "$LINENO"; then :
42349  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42350$as_echo "yes" >&6; }
42351	  X_LIBS="$X_LIBS -R $x_libraries"
42352else
42353  { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
42354$as_echo "neither works" >&6; }
42355fi
42356rm -f core conftest.err conftest.$ac_objext \
42357    conftest$ac_exeext conftest.$ac_ext
42358fi
42359rm -f core conftest.err conftest.$ac_objext \
42360    conftest$ac_exeext conftest.$ac_ext
42361    ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
42362    LIBS=$ac_xsave_LIBS
42363  fi
42364
42365  # Check for system-dependent libraries X programs must link with.
42366  # Do this before checking for the system-independent R6 libraries
42367  # (-lICE), since we may need -lsocket or whatever for X linking.
42368
42369  if test "$ISC" = yes; then
42370    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
42371  else
42372    # Martyn Johnson says this is needed for Ultrix, if the X
42373    # libraries were built with DECnet support.  And Karl Berry says
42374    # the Alpha needs dnet_stub (dnet does not exist).
42375    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
42376    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42377/* end confdefs.h.  */
42378
42379/* Override any GCC internal prototype to avoid an error.
42380   Use char because int might match the return type of a GCC
42381   builtin and then its argument prototype would still apply.  */
42382#ifdef __cplusplus
42383extern "C"
42384#endif
42385char XOpenDisplay ();
42386int
42387main ()
42388{
42389return XOpenDisplay ();
42390  ;
42391  return 0;
42392}
42393_ACEOF
42394if ac_fn_cxx_try_link "$LINENO"; then :
42395
42396else
42397  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
42398$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
42399if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
42400  $as_echo_n "(cached) " >&6
42401else
42402  ac_check_lib_save_LIBS=$LIBS
42403LIBS="-ldnet  $LIBS"
42404cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42405/* end confdefs.h.  */
42406
42407/* Override any GCC internal prototype to avoid an error.
42408   Use char because int might match the return type of a GCC
42409   builtin and then its argument prototype would still apply.  */
42410#ifdef __cplusplus
42411extern "C"
42412#endif
42413char dnet_ntoa ();
42414int
42415main ()
42416{
42417return dnet_ntoa ();
42418  ;
42419  return 0;
42420}
42421_ACEOF
42422if ac_fn_cxx_try_link "$LINENO"; then :
42423  ac_cv_lib_dnet_dnet_ntoa=yes
42424else
42425  ac_cv_lib_dnet_dnet_ntoa=no
42426fi
42427rm -f core conftest.err conftest.$ac_objext \
42428    conftest$ac_exeext conftest.$ac_ext
42429LIBS=$ac_check_lib_save_LIBS
42430fi
42431{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
42432$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
42433if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
42434  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
42435fi
42436
42437    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
42438      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
42439$as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
42440if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
42441  $as_echo_n "(cached) " >&6
42442else
42443  ac_check_lib_save_LIBS=$LIBS
42444LIBS="-ldnet_stub  $LIBS"
42445cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42446/* end confdefs.h.  */
42447
42448/* Override any GCC internal prototype to avoid an error.
42449   Use char because int might match the return type of a GCC
42450   builtin and then its argument prototype would still apply.  */
42451#ifdef __cplusplus
42452extern "C"
42453#endif
42454char dnet_ntoa ();
42455int
42456main ()
42457{
42458return dnet_ntoa ();
42459  ;
42460  return 0;
42461}
42462_ACEOF
42463if ac_fn_cxx_try_link "$LINENO"; then :
42464  ac_cv_lib_dnet_stub_dnet_ntoa=yes
42465else
42466  ac_cv_lib_dnet_stub_dnet_ntoa=no
42467fi
42468rm -f core conftest.err conftest.$ac_objext \
42469    conftest$ac_exeext conftest.$ac_ext
42470LIBS=$ac_check_lib_save_LIBS
42471fi
42472{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
42473$as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
42474if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
42475  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
42476fi
42477
42478    fi
42479fi
42480rm -f core conftest.err conftest.$ac_objext \
42481    conftest$ac_exeext conftest.$ac_ext
42482    LIBS="$ac_xsave_LIBS"
42483
42484    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
42485    # to get the SysV transport functions.
42486    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
42487    # needs -lnsl.
42488    # The nsl library prevents programs from opening the X display
42489    # on Irix 5.2, according to T.E. Dickey.
42490    # The functions gethostbyname, getservbyname, and inet_addr are
42491    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
42492    ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
42493if test "x$ac_cv_func_gethostbyname" = xyes; then :
42494
42495fi
42496
42497    if test $ac_cv_func_gethostbyname = no; then
42498      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
42499$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
42500if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
42501  $as_echo_n "(cached) " >&6
42502else
42503  ac_check_lib_save_LIBS=$LIBS
42504LIBS="-lnsl  $LIBS"
42505cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42506/* end confdefs.h.  */
42507
42508/* Override any GCC internal prototype to avoid an error.
42509   Use char because int might match the return type of a GCC
42510   builtin and then its argument prototype would still apply.  */
42511#ifdef __cplusplus
42512extern "C"
42513#endif
42514char gethostbyname ();
42515int
42516main ()
42517{
42518return gethostbyname ();
42519  ;
42520  return 0;
42521}
42522_ACEOF
42523if ac_fn_cxx_try_link "$LINENO"; then :
42524  ac_cv_lib_nsl_gethostbyname=yes
42525else
42526  ac_cv_lib_nsl_gethostbyname=no
42527fi
42528rm -f core conftest.err conftest.$ac_objext \
42529    conftest$ac_exeext conftest.$ac_ext
42530LIBS=$ac_check_lib_save_LIBS
42531fi
42532{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
42533$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
42534if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
42535  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
42536fi
42537
42538      if test $ac_cv_lib_nsl_gethostbyname = no; then
42539	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
42540$as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
42541if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
42542  $as_echo_n "(cached) " >&6
42543else
42544  ac_check_lib_save_LIBS=$LIBS
42545LIBS="-lbsd  $LIBS"
42546cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42547/* end confdefs.h.  */
42548
42549/* Override any GCC internal prototype to avoid an error.
42550   Use char because int might match the return type of a GCC
42551   builtin and then its argument prototype would still apply.  */
42552#ifdef __cplusplus
42553extern "C"
42554#endif
42555char gethostbyname ();
42556int
42557main ()
42558{
42559return gethostbyname ();
42560  ;
42561  return 0;
42562}
42563_ACEOF
42564if ac_fn_cxx_try_link "$LINENO"; then :
42565  ac_cv_lib_bsd_gethostbyname=yes
42566else
42567  ac_cv_lib_bsd_gethostbyname=no
42568fi
42569rm -f core conftest.err conftest.$ac_objext \
42570    conftest$ac_exeext conftest.$ac_ext
42571LIBS=$ac_check_lib_save_LIBS
42572fi
42573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
42574$as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
42575if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
42576  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
42577fi
42578
42579      fi
42580    fi
42581
42582    # lieder@skyler.mavd.honeywell.com says without -lsocket,
42583    # socket/setsockopt and other routines are undefined under SCO ODT
42584    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
42585    # on later versions), says Simon Leinen: it contains gethostby*
42586    # variants that don't use the name server (or something).  -lsocket
42587    # must be given before -lnsl if both are needed.  We assume that
42588    # if connect needs -lnsl, so does gethostbyname.
42589    ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
42590if test "x$ac_cv_func_connect" = xyes; then :
42591
42592fi
42593
42594    if test $ac_cv_func_connect = no; then
42595      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
42596$as_echo_n "checking for connect in -lsocket... " >&6; }
42597if ${ac_cv_lib_socket_connect+:} false; then :
42598  $as_echo_n "(cached) " >&6
42599else
42600  ac_check_lib_save_LIBS=$LIBS
42601LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
42602cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42603/* end confdefs.h.  */
42604
42605/* Override any GCC internal prototype to avoid an error.
42606   Use char because int might match the return type of a GCC
42607   builtin and then its argument prototype would still apply.  */
42608#ifdef __cplusplus
42609extern "C"
42610#endif
42611char connect ();
42612int
42613main ()
42614{
42615return connect ();
42616  ;
42617  return 0;
42618}
42619_ACEOF
42620if ac_fn_cxx_try_link "$LINENO"; then :
42621  ac_cv_lib_socket_connect=yes
42622else
42623  ac_cv_lib_socket_connect=no
42624fi
42625rm -f core conftest.err conftest.$ac_objext \
42626    conftest$ac_exeext conftest.$ac_ext
42627LIBS=$ac_check_lib_save_LIBS
42628fi
42629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
42630$as_echo "$ac_cv_lib_socket_connect" >&6; }
42631if test "x$ac_cv_lib_socket_connect" = xyes; then :
42632  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
42633fi
42634
42635    fi
42636
42637    # Guillermo Gomez says -lposix is necessary on A/UX.
42638    ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
42639if test "x$ac_cv_func_remove" = xyes; then :
42640
42641fi
42642
42643    if test $ac_cv_func_remove = no; then
42644      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
42645$as_echo_n "checking for remove in -lposix... " >&6; }
42646if ${ac_cv_lib_posix_remove+:} false; then :
42647  $as_echo_n "(cached) " >&6
42648else
42649  ac_check_lib_save_LIBS=$LIBS
42650LIBS="-lposix  $LIBS"
42651cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42652/* end confdefs.h.  */
42653
42654/* Override any GCC internal prototype to avoid an error.
42655   Use char because int might match the return type of a GCC
42656   builtin and then its argument prototype would still apply.  */
42657#ifdef __cplusplus
42658extern "C"
42659#endif
42660char remove ();
42661int
42662main ()
42663{
42664return remove ();
42665  ;
42666  return 0;
42667}
42668_ACEOF
42669if ac_fn_cxx_try_link "$LINENO"; then :
42670  ac_cv_lib_posix_remove=yes
42671else
42672  ac_cv_lib_posix_remove=no
42673fi
42674rm -f core conftest.err conftest.$ac_objext \
42675    conftest$ac_exeext conftest.$ac_ext
42676LIBS=$ac_check_lib_save_LIBS
42677fi
42678{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
42679$as_echo "$ac_cv_lib_posix_remove" >&6; }
42680if test "x$ac_cv_lib_posix_remove" = xyes; then :
42681  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
42682fi
42683
42684    fi
42685
42686    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
42687    ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
42688if test "x$ac_cv_func_shmat" = xyes; then :
42689
42690fi
42691
42692    if test $ac_cv_func_shmat = no; then
42693      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
42694$as_echo_n "checking for shmat in -lipc... " >&6; }
42695if ${ac_cv_lib_ipc_shmat+:} false; then :
42696  $as_echo_n "(cached) " >&6
42697else
42698  ac_check_lib_save_LIBS=$LIBS
42699LIBS="-lipc  $LIBS"
42700cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42701/* end confdefs.h.  */
42702
42703/* Override any GCC internal prototype to avoid an error.
42704   Use char because int might match the return type of a GCC
42705   builtin and then its argument prototype would still apply.  */
42706#ifdef __cplusplus
42707extern "C"
42708#endif
42709char shmat ();
42710int
42711main ()
42712{
42713return shmat ();
42714  ;
42715  return 0;
42716}
42717_ACEOF
42718if ac_fn_cxx_try_link "$LINENO"; then :
42719  ac_cv_lib_ipc_shmat=yes
42720else
42721  ac_cv_lib_ipc_shmat=no
42722fi
42723rm -f core conftest.err conftest.$ac_objext \
42724    conftest$ac_exeext conftest.$ac_ext
42725LIBS=$ac_check_lib_save_LIBS
42726fi
42727{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
42728$as_echo "$ac_cv_lib_ipc_shmat" >&6; }
42729if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
42730  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
42731fi
42732
42733    fi
42734  fi
42735
42736  # Check for libraries that X11R6 Xt/Xaw programs need.
42737  ac_save_LDFLAGS=$LDFLAGS
42738  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
42739  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
42740  # check for ICE first), but we must link in the order -lSM -lICE or
42741  # we get undefined symbols.  So assume we have SM if we have ICE.
42742  # These have to be linked with before -lX11, unlike the other
42743  # libraries we check for below, so use a different variable.
42744  # John Interrante, Karl Berry
42745  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
42746$as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
42747if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
42748  $as_echo_n "(cached) " >&6
42749else
42750  ac_check_lib_save_LIBS=$LIBS
42751LIBS="-lICE $X_EXTRA_LIBS $LIBS"
42752cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42753/* end confdefs.h.  */
42754
42755/* Override any GCC internal prototype to avoid an error.
42756   Use char because int might match the return type of a GCC
42757   builtin and then its argument prototype would still apply.  */
42758#ifdef __cplusplus
42759extern "C"
42760#endif
42761char IceConnectionNumber ();
42762int
42763main ()
42764{
42765return IceConnectionNumber ();
42766  ;
42767  return 0;
42768}
42769_ACEOF
42770if ac_fn_cxx_try_link "$LINENO"; then :
42771  ac_cv_lib_ICE_IceConnectionNumber=yes
42772else
42773  ac_cv_lib_ICE_IceConnectionNumber=no
42774fi
42775rm -f core conftest.err conftest.$ac_objext \
42776    conftest$ac_exeext conftest.$ac_ext
42777LIBS=$ac_check_lib_save_LIBS
42778fi
42779{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
42780$as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
42781if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
42782  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
42783fi
42784
42785  LDFLAGS=$ac_save_LDFLAGS
42786
42787fi
42788
42789
42790  # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
42791  # this doesn't make sense so we remove it.
42792  if test "x$COMPILE_TYPE" = xcross; then
42793    X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
42794  fi
42795
42796  if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then
42797
42798  # Print a helpful message on how to acquire the necessary build dependency.
42799  # x11 is the help tag: freetype, cups, pulse, alsa etc
42800  MISSING_DEPENDENCY=x11
42801
42802  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42803    cygwin_help $MISSING_DEPENDENCY
42804  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42805    msys_help $MISSING_DEPENDENCY
42806  else
42807    PKGHANDLER_COMMAND=
42808
42809    case $PKGHANDLER in
42810      apt-get)
42811        apt_help     $MISSING_DEPENDENCY ;;
42812      yum)
42813        yum_help     $MISSING_DEPENDENCY ;;
42814      port)
42815        port_help    $MISSING_DEPENDENCY ;;
42816      pkgutil)
42817        pkgutil_help $MISSING_DEPENDENCY ;;
42818      pkgadd)
42819        pkgadd_help  $MISSING_DEPENDENCY ;;
42820    esac
42821
42822    if test "x$PKGHANDLER_COMMAND" != x; then
42823      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42824    fi
42825  fi
42826
42827    as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
42828  fi
42829
42830  if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42831    OPENWIN_HOME="/usr/openwin"
42832  fi
42833
42834
42835
42836  #
42837  # Weird Sol10 something check...TODO change to try compile
42838  #
42839  if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
42840    if test "`uname -r`" = "5.10"; then
42841      if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
42842        X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
42843      fi
42844    fi
42845  fi
42846
42847  ac_ext=c
42848ac_cpp='$CPP $CPPFLAGS'
42849ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42850ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42851ac_compiler_gnu=$ac_cv_c_compiler_gnu
42852
42853  OLD_CFLAGS="$CFLAGS"
42854  CFLAGS="$CFLAGS $X_CFLAGS"
42855
42856  # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
42857  for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
42858do :
42859  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
42860ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
42861        # include <X11/Xlib.h>
42862        # include <X11/Xutil.h>
42863
42864
42865"
42866if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
42867  cat >>confdefs.h <<_ACEOF
42868#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
42869_ACEOF
42870 X11_A_OK=yes
42871else
42872  X11_A_OK=no; break
42873fi
42874
42875done
42876
42877
42878  CFLAGS="$OLD_CFLAGS"
42879  ac_ext=cpp
42880ac_cpp='$CXXCPP $CPPFLAGS'
42881ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42882ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42883ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42884
42885
42886  if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then
42887
42888  # Print a helpful message on how to acquire the necessary build dependency.
42889  # x11 is the help tag: freetype, cups, pulse, alsa etc
42890  MISSING_DEPENDENCY=x11
42891
42892  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
42893    cygwin_help $MISSING_DEPENDENCY
42894  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
42895    msys_help $MISSING_DEPENDENCY
42896  else
42897    PKGHANDLER_COMMAND=
42898
42899    case $PKGHANDLER in
42900      apt-get)
42901        apt_help     $MISSING_DEPENDENCY ;;
42902      yum)
42903        yum_help     $MISSING_DEPENDENCY ;;
42904      port)
42905        port_help    $MISSING_DEPENDENCY ;;
42906      pkgutil)
42907        pkgutil_help $MISSING_DEPENDENCY ;;
42908      pkgadd)
42909        pkgadd_help  $MISSING_DEPENDENCY ;;
42910    esac
42911
42912    if test "x$PKGHANDLER_COMMAND" != x; then
42913      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
42914    fi
42915  fi
42916
42917    as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
42918  fi
42919
42920
42921
42922
42923
42924
42925  ###############################################################################
42926  #
42927  # The common unix printing system cups is used to print from java.
42928  #
42929
42930# Check whether --with-cups was given.
42931if test "${with_cups+set}" = set; then :
42932  withval=$with_cups;
42933fi
42934
42935
42936# Check whether --with-cups-include was given.
42937if test "${with_cups_include+set}" = set; then :
42938  withval=$with_cups_include;
42939fi
42940
42941
42942  if test "x$CUPS_NOT_NEEDED" = xyes; then
42943    if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
42944      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
42945$as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
42946    fi
42947    CUPS_CFLAGS=
42948  else
42949    CUPS_FOUND=no
42950
42951    if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
42952      as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
42953    fi
42954
42955    if test "x${with_cups}" != x; then
42956      CUPS_CFLAGS="-I${with_cups}/include"
42957      CUPS_FOUND=yes
42958    fi
42959    if test "x${with_cups_include}" != x; then
42960      CUPS_CFLAGS="-I${with_cups_include}"
42961      CUPS_FOUND=yes
42962    fi
42963    if test "x$CUPS_FOUND" = xno; then
42964
42965
42966  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
42967    # Source the builddeps file again, to make sure it uses the latest variables!
42968    . $builddepsfile
42969    # Look for a target and build machine specific resource!
42970    eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
42971    if test "x$resource" = x; then
42972      # Ok, lets instead look for a target specific resource
42973      eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
42974    fi
42975    if test "x$resource" = x; then
42976      # Ok, lets instead look for a build specific resource
42977      eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
42978    fi
42979    if test "x$resource" = x; then
42980      # Ok, lets instead look for a generic resource
42981      # (The cups comes from M4 and not the shell, thus no need for eval here.)
42982      resource=${builddep_cups}
42983    fi
42984    if test "x$resource" != x; then
42985      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
42986$as_echo "$as_me: Using builddeps $resource for cups" >&6;}
42987      # If the resource in the builddeps.conf file is an existing directory,
42988      # for example /java/linux/cups
42989      if test -d ${resource}; then
42990        depdir=${resource}
42991      else
42992
42993  # cups is for example mymodule
42994  # $resource is for example libs/general/libmymod_1_2_3.zip
42995  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
42996  # $with_builddeps_dir is for example /localhome/builddeps
42997  # depdir is the name of the variable into which we store the depdir, eg MYMOD
42998  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
42999  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43000  filename=`basename $resource`
43001  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43002  filebase=${filename%%.*}
43003  extension=${filename#*.}
43004  installdir=$with_builddeps_dir/$filebase
43005  if test ! -f $installdir/$filename.unpacked; then
43006    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
43007$as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43008    if test ! -d $installdir; then
43009      mkdir -p $installdir
43010    fi
43011    if test ! -d $installdir; then
43012      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43013    fi
43014    tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
43015    touch $tmpfile
43016    if test ! -f $tmpfile; then
43017      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43018    fi
43019
43020  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43021  # $tmpfile is the local file name for the downloaded file.
43022  VALID_TOOL=no
43023  if test "x$BDEPS_FTP" = xwget; then
43024    VALID_TOOL=yes
43025    wget -O $tmpfile $with_builddeps_server/$resource
43026  fi
43027  if test "x$BDEPS_FTP" = xlftp; then
43028    VALID_TOOL=yes
43029    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43030  fi
43031  if test "x$BDEPS_FTP" = xftp; then
43032    VALID_TOOL=yes
43033    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43034    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43035    FTPUSERPWD=${FTPSERVER%%@*}
43036    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43037      FTPUSER=${userpwd%%:*}
43038      FTPPWD=${userpwd#*@}
43039      FTPSERVER=${FTPSERVER#*@}
43040    else
43041      FTPUSER=ftp
43042      FTPPWD=ftp
43043    fi
43044    # the "pass" command does not work on some
43045    # ftp clients (read ftp.exe) but if it works,
43046    # passive mode is better!
43047    ( \
43048        echo "user $FTPUSER $FTPPWD"        ; \
43049        echo "pass"                         ; \
43050        echo "bin"                          ; \
43051        echo "get $FTPPATH $tmpfile"              ; \
43052    ) | ftp -in $FTPSERVER
43053  fi
43054  if test "x$VALID_TOOL" != xyes; then
43055    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43056  fi
43057
43058    mv $tmpfile $installdir/$filename
43059    if test ! -s $installdir/$filename; then
43060      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43061    fi
43062    case "$extension" in
43063      zip)  echo "Unzipping $installdir/$filename..."
43064        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43065        ;;
43066      tar.gz) echo "Untaring $installdir/$filename..."
43067        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43068        ;;
43069      tgz) echo "Untaring $installdir/$filename..."
43070        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43071        ;;
43072      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43073        ;;
43074    esac
43075  fi
43076  if test -f $installdir/$filename.unpacked; then
43077    depdir=$installdir
43078  fi
43079
43080      fi
43081      # Source the builddeps file again, because in the previous command, the depdir
43082      # was updated to point at the current build dependency install directory.
43083      . $builddepsfile
43084      # Now extract variables from the builddeps.conf files.
43085      theroot=${builddep_cups_ROOT}
43086      thecflags=${builddep_cups_CFLAGS}
43087      thelibs=${builddep_cups_LIBS}
43088      if test "x$depdir" = x; then
43089        as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
43090      fi
43091      CUPS=$depdir
43092      if test "x$theroot" != x; then
43093        CUPS="$theroot"
43094      fi
43095      if test "x$thecflags" != x; then
43096        CUPS_CFLAGS="$thecflags"
43097      fi
43098      if test "x$thelibs" != x; then
43099        CUPS_LIBS="$thelibs"
43100      fi
43101      CUPS_FOUND=yes
43102
43103    fi
43104
43105  fi
43106
43107    fi
43108    if test "x$CUPS_FOUND" = xno; then
43109      # Are the cups headers installed in the default /usr/include location?
43110      for ac_header in cups/cups.h cups/ppd.h
43111do :
43112  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43113ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
43114if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43115  cat >>confdefs.h <<_ACEOF
43116#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43117_ACEOF
43118
43119            CUPS_FOUND=yes
43120            CUPS_CFLAGS=
43121            DEFAULT_CUPS=yes
43122
43123
43124fi
43125
43126done
43127
43128    fi
43129    if test "x$CUPS_FOUND" = xno; then
43130      # Getting nervous now? Lets poke around for standard Solaris third-party
43131      # package installation locations.
43132      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43133$as_echo_n "checking for cups headers... " >&6; }
43134      if test -s /opt/sfw/cups/include/cups/cups.h; then
43135        # An SFW package seems to be installed!
43136        CUPS_FOUND=yes
43137        CUPS_CFLAGS="-I/opt/sfw/cups/include"
43138      elif test -s /opt/csw/include/cups/cups.h; then
43139        # A CSW package seems to be installed!
43140        CUPS_FOUND=yes
43141        CUPS_CFLAGS="-I/opt/csw/include"
43142      fi
43143      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43144$as_echo "$CUPS_FOUND" >&6; }
43145    fi
43146    if test "x$CUPS_FOUND" = xno; then
43147
43148  # Print a helpful message on how to acquire the necessary build dependency.
43149  # cups is the help tag: freetype, cups, pulse, alsa etc
43150  MISSING_DEPENDENCY=cups
43151
43152  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43153    cygwin_help $MISSING_DEPENDENCY
43154  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43155    msys_help $MISSING_DEPENDENCY
43156  else
43157    PKGHANDLER_COMMAND=
43158
43159    case $PKGHANDLER in
43160      apt-get)
43161        apt_help     $MISSING_DEPENDENCY ;;
43162      yum)
43163        yum_help     $MISSING_DEPENDENCY ;;
43164      port)
43165        port_help    $MISSING_DEPENDENCY ;;
43166      pkgutil)
43167        pkgutil_help $MISSING_DEPENDENCY ;;
43168      pkgadd)
43169        pkgadd_help  $MISSING_DEPENDENCY ;;
43170    esac
43171
43172    if test "x$PKGHANDLER_COMMAND" != x; then
43173      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43174    fi
43175  fi
43176
43177      as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
43178    fi
43179  fi
43180
43181
43182
43183
43184
43185
43186  ###############################################################################
43187  #
43188  # The ubiquitous freetype library is used to render fonts.
43189  #
43190
43191# Check whether --with-freetype was given.
43192if test "${with_freetype+set}" = set; then :
43193  withval=$with_freetype;
43194fi
43195
43196
43197# Check whether --with-freetype-include was given.
43198if test "${with_freetype_include+set}" = set; then :
43199  withval=$with_freetype_include;
43200fi
43201
43202
43203# Check whether --with-freetype-lib was given.
43204if test "${with_freetype_lib+set}" = set; then :
43205  withval=$with_freetype_lib;
43206fi
43207
43208  # Check whether --enable-freetype-bundling was given.
43209if test "${enable_freetype_bundling+set}" = set; then :
43210  enableval=$enable_freetype_bundling;
43211fi
43212
43213
43214  FREETYPE_CFLAGS=
43215  FREETYPE_LIBS=
43216  FREETYPE_BUNDLE_LIB_PATH=
43217
43218  if test "x$FREETYPE_NOT_NEEDED" = xyes; then
43219    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43220      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
43221$as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
43222    fi
43223    if test "x$enable_freetype_bundling" != x; then
43224      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
43225$as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
43226    fi
43227  else
43228    # freetype is needed to build; go get it!
43229
43230    BUNDLE_FREETYPE="$enable_freetype_bundling"
43231
43232    if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43233      # User has specified settings
43234
43235      if test "x$BUNDLE_FREETYPE" = x; then
43236        # If not specified, default is to bundle freetype
43237        BUNDLE_FREETYPE=yes
43238      fi
43239
43240      if test "x$with_freetype" != x; then
43241        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
43242        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
43243      fi
43244
43245      # Allow --with-freetype-lib and --with-freetype-include to override
43246      if test "x$with_freetype_include" != x; then
43247        POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
43248      fi
43249      if test "x$with_freetype_lib" != x; then
43250        POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
43251      fi
43252
43253      if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
43254        # Okay, we got it. Check that it works.
43255
43256  POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43257  POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43258  METHOD="--with-freetype"
43259
43260  # First check if the files exists.
43261  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43262    # We found an arbitrary include file. That's a good sign.
43263    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43264$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43265    FOUND_FREETYPE=yes
43266
43267    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43268    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43269      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43270$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43271      FOUND_FREETYPE=no
43272    else
43273      if test "x$OPENJDK_TARGET_OS" = xwindows; then
43274        # On Windows, we will need both .lib and .dll file.
43275        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43276          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43277$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43278          FOUND_FREETYPE=no
43279        fi
43280      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
43281        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43282        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43283      fi
43284    fi
43285  fi
43286
43287  if test "x$FOUND_FREETYPE" = xyes; then
43288
43289  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43290
43291  # Input might be given as Windows format, start by converting to
43292  # unix format.
43293  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43294  new_path=`$CYGPATH -u "$path"`
43295
43296  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43297  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43298  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43299  # "foo.exe" is OK but "foo" is an error.
43300  #
43301  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43302  # It is also a way to make sure we got the proper file name for the real test later on.
43303  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43304  if test "x$test_shortpath" = x; then
43305    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43306$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43307    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43308  fi
43309
43310  # Call helper function which possibly converts this using DOS-style short mode.
43311  # If so, the updated path is stored in $new_path.
43312
43313  input_path="$new_path"
43314  # Check if we need to convert this using DOS-style short mode. If the path
43315  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43316  # take no chances and rewrite it.
43317  # Note: m4 eats our [], so we need to use [ and ] instead.
43318  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43319  if test "x$has_forbidden_chars" != x; then
43320    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43321    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43322    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43323    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43324      # Going to short mode and back again did indeed matter. Since short mode is
43325      # case insensitive, let's make it lowercase to improve readability.
43326      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43327      # Now convert it back to Unix-stile (cygpath)
43328      input_path=`$CYGPATH -u "$shortmode_path"`
43329      new_path="$input_path"
43330    fi
43331  fi
43332
43333  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43334  if test "x$test_cygdrive_prefix" = x; then
43335    # As a simple fix, exclude /usr/bin since it's not a real path.
43336    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43337      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43338      # a path prefixed by /cygdrive for fixpath to work.
43339      new_path="$CYGWIN_ROOT_PATH$input_path"
43340    fi
43341  fi
43342
43343
43344  if test "x$path" != "x$new_path"; then
43345    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43346    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43347$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43348  fi
43349
43350  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43351
43352  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43353  has_colon=`$ECHO $path | $GREP ^.:`
43354  new_path="$path"
43355  if test "x$has_colon" = x; then
43356    # Not in mixed or Windows style, start by that.
43357    new_path=`cmd //c echo $path`
43358  fi
43359
43360
43361  input_path="$new_path"
43362  # Check if we need to convert this using DOS-style short mode. If the path
43363  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43364  # take no chances and rewrite it.
43365  # Note: m4 eats our [], so we need to use [ and ] instead.
43366  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43367  if test "x$has_forbidden_chars" != x; then
43368    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43369    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43370  fi
43371
43372
43373  windows_path="$new_path"
43374  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43375    unix_path=`$CYGPATH -u "$windows_path"`
43376    new_path="$unix_path"
43377  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43378    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43379    new_path="$unix_path"
43380  fi
43381
43382  if test "x$path" != "x$new_path"; then
43383    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43384    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43385$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43386  fi
43387
43388  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43389  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43390
43391  else
43392    # We're on a posix platform. Hooray! :)
43393    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43394    has_space=`$ECHO "$path" | $GREP " "`
43395    if test "x$has_space" != x; then
43396      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43397$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43398      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43399    fi
43400
43401    # Use eval to expand a potential ~
43402    eval path="$path"
43403    if test ! -f "$path" && test ! -d "$path"; then
43404      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43405    fi
43406
43407    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43408  fi
43409
43410
43411  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43412
43413  # Input might be given as Windows format, start by converting to
43414  # unix format.
43415  path="$POTENTIAL_FREETYPE_LIB_PATH"
43416  new_path=`$CYGPATH -u "$path"`
43417
43418  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43419  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43420  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43421  # "foo.exe" is OK but "foo" is an error.
43422  #
43423  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43424  # It is also a way to make sure we got the proper file name for the real test later on.
43425  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43426  if test "x$test_shortpath" = x; then
43427    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43428$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43429    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
43430  fi
43431
43432  # Call helper function which possibly converts this using DOS-style short mode.
43433  # If so, the updated path is stored in $new_path.
43434
43435  input_path="$new_path"
43436  # Check if we need to convert this using DOS-style short mode. If the path
43437  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43438  # take no chances and rewrite it.
43439  # Note: m4 eats our [], so we need to use [ and ] instead.
43440  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43441  if test "x$has_forbidden_chars" != x; then
43442    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43443    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43444    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43445    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43446      # Going to short mode and back again did indeed matter. Since short mode is
43447      # case insensitive, let's make it lowercase to improve readability.
43448      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43449      # Now convert it back to Unix-stile (cygpath)
43450      input_path=`$CYGPATH -u "$shortmode_path"`
43451      new_path="$input_path"
43452    fi
43453  fi
43454
43455  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43456  if test "x$test_cygdrive_prefix" = x; then
43457    # As a simple fix, exclude /usr/bin since it's not a real path.
43458    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43459      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43460      # a path prefixed by /cygdrive for fixpath to work.
43461      new_path="$CYGWIN_ROOT_PATH$input_path"
43462    fi
43463  fi
43464
43465
43466  if test "x$path" != "x$new_path"; then
43467    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43468    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43469$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43470  fi
43471
43472  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43473
43474  path="$POTENTIAL_FREETYPE_LIB_PATH"
43475  has_colon=`$ECHO $path | $GREP ^.:`
43476  new_path="$path"
43477  if test "x$has_colon" = x; then
43478    # Not in mixed or Windows style, start by that.
43479    new_path=`cmd //c echo $path`
43480  fi
43481
43482
43483  input_path="$new_path"
43484  # Check if we need to convert this using DOS-style short mode. If the path
43485  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43486  # take no chances and rewrite it.
43487  # Note: m4 eats our [], so we need to use [ and ] instead.
43488  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43489  if test "x$has_forbidden_chars" != x; then
43490    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43491    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43492  fi
43493
43494
43495  windows_path="$new_path"
43496  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43497    unix_path=`$CYGPATH -u "$windows_path"`
43498    new_path="$unix_path"
43499  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43500    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43501    new_path="$unix_path"
43502  fi
43503
43504  if test "x$path" != "x$new_path"; then
43505    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43506    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43507$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43508  fi
43509
43510  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43511  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43512
43513  else
43514    # We're on a posix platform. Hooray! :)
43515    path="$POTENTIAL_FREETYPE_LIB_PATH"
43516    has_space=`$ECHO "$path" | $GREP " "`
43517    if test "x$has_space" != x; then
43518      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43519$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43520      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43521    fi
43522
43523    # Use eval to expand a potential ~
43524    eval path="$path"
43525    if test ! -f "$path" && test ! -d "$path"; then
43526      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43527    fi
43528
43529    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
43530  fi
43531
43532
43533    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43534    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
43535$as_echo_n "checking for freetype includes... " >&6; }
43536    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
43537$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
43538    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43539    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
43540$as_echo_n "checking for freetype libraries... " >&6; }
43541    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
43542$as_echo "$FREETYPE_LIB_PATH" >&6; }
43543  fi
43544
43545        if test "x$FOUND_FREETYPE" != xyes; then
43546          as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
43547        fi
43548      else
43549        # User specified only one of lib or include. This is an error.
43550        if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
43551          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
43552$as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
43553          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43554        else
43555          { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
43556$as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
43557          as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
43558        fi
43559      fi
43560    else
43561      # User did not specify settings, but we need freetype. Try to locate it.
43562
43563      if test "x$BUNDLE_FREETYPE" = x; then
43564        # If not specified, default is to bundle freetype only on windows
43565        if test "x$OPENJDK_TARGET_OS" = xwindows; then
43566          BUNDLE_FREETYPE=yes
43567        else
43568          BUNDLE_FREETYPE=no
43569        fi
43570      fi
43571
43572      if test "x$FOUND_FREETYPE" != xyes; then
43573        # Check builddeps
43574
43575
43576  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43577    # Source the builddeps file again, to make sure it uses the latest variables!
43578    . $builddepsfile
43579    # Look for a target and build machine specific resource!
43580    eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43581    if test "x$resource" = x; then
43582      # Ok, lets instead look for a target specific resource
43583      eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
43584    fi
43585    if test "x$resource" = x; then
43586      # Ok, lets instead look for a build specific resource
43587      eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
43588    fi
43589    if test "x$resource" = x; then
43590      # Ok, lets instead look for a generic resource
43591      # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
43592      resource=${builddep_freetype2}
43593    fi
43594    if test "x$resource" != x; then
43595      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
43596$as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
43597      # If the resource in the builddeps.conf file is an existing directory,
43598      # for example /java/linux/cups
43599      if test -d ${resource}; then
43600        depdir=${resource}
43601      else
43602
43603  # freetype2 is for example mymodule
43604  # $resource is for example libs/general/libmymod_1_2_3.zip
43605  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43606  # $with_builddeps_dir is for example /localhome/builddeps
43607  # depdir is the name of the variable into which we store the depdir, eg MYMOD
43608  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43609  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43610  filename=`basename $resource`
43611  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43612  filebase=${filename%%.*}
43613  extension=${filename#*.}
43614  installdir=$with_builddeps_dir/$filebase
43615  if test ! -f $installdir/$filename.unpacked; then
43616    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
43617$as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43618    if test ! -d $installdir; then
43619      mkdir -p $installdir
43620    fi
43621    if test ! -d $installdir; then
43622      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43623    fi
43624    tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
43625    touch $tmpfile
43626    if test ! -f $tmpfile; then
43627      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43628    fi
43629
43630  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43631  # $tmpfile is the local file name for the downloaded file.
43632  VALID_TOOL=no
43633  if test "x$BDEPS_FTP" = xwget; then
43634    VALID_TOOL=yes
43635    wget -O $tmpfile $with_builddeps_server/$resource
43636  fi
43637  if test "x$BDEPS_FTP" = xlftp; then
43638    VALID_TOOL=yes
43639    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43640  fi
43641  if test "x$BDEPS_FTP" = xftp; then
43642    VALID_TOOL=yes
43643    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43644    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43645    FTPUSERPWD=${FTPSERVER%%@*}
43646    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43647      FTPUSER=${userpwd%%:*}
43648      FTPPWD=${userpwd#*@}
43649      FTPSERVER=${FTPSERVER#*@}
43650    else
43651      FTPUSER=ftp
43652      FTPPWD=ftp
43653    fi
43654    # the "pass" command does not work on some
43655    # ftp clients (read ftp.exe) but if it works,
43656    # passive mode is better!
43657    ( \
43658        echo "user $FTPUSER $FTPPWD"        ; \
43659        echo "pass"                         ; \
43660        echo "bin"                          ; \
43661        echo "get $FTPPATH $tmpfile"              ; \
43662    ) | ftp -in $FTPSERVER
43663  fi
43664  if test "x$VALID_TOOL" != xyes; then
43665    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43666  fi
43667
43668    mv $tmpfile $installdir/$filename
43669    if test ! -s $installdir/$filename; then
43670      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43671    fi
43672    case "$extension" in
43673      zip)  echo "Unzipping $installdir/$filename..."
43674        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43675        ;;
43676      tar.gz) echo "Untaring $installdir/$filename..."
43677        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43678        ;;
43679      tgz) echo "Untaring $installdir/$filename..."
43680        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43681        ;;
43682      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43683        ;;
43684    esac
43685  fi
43686  if test -f $installdir/$filename.unpacked; then
43687    depdir=$installdir
43688  fi
43689
43690      fi
43691      # Source the builddeps file again, because in the previous command, the depdir
43692      # was updated to point at the current build dependency install directory.
43693      . $builddepsfile
43694      # Now extract variables from the builddeps.conf files.
43695      theroot=${builddep_freetype2_ROOT}
43696      thecflags=${builddep_freetype2_CFLAGS}
43697      thelibs=${builddep_freetype2_LIBS}
43698      if test "x$depdir" = x; then
43699        as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
43700      fi
43701      FREETYPE=$depdir
43702      if test "x$theroot" != x; then
43703        FREETYPE="$theroot"
43704      fi
43705      if test "x$thecflags" != x; then
43706        FREETYPE_CFLAGS="$thecflags"
43707      fi
43708      if test "x$thelibs" != x; then
43709        FREETYPE_LIBS="$thelibs"
43710      fi
43711      FOUND_FREETYPE=yes
43712      else FOUND_FREETYPE=no
43713
43714    fi
43715    else FOUND_FREETYPE=no
43716
43717  fi
43718
43719        # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43720        if test "x$FOUND_FREETYPE" = xyes; then
43721          if test "x$BUNDLE_FREETYPE" = xyes; then
43722            { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43723$as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43724            FOUND_FREETYPE=no
43725          else
43726            { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43727$as_echo_n "checking for freetype... " >&6; }
43728            { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43729$as_echo "yes (using builddeps)" >&6; }
43730          fi
43731        fi
43732      fi
43733
43734      if test "x$FOUND_FREETYPE" != xyes; then
43735        # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43736        if test "x$PKG_CONFIG" != x; then
43737
43738pkg_failed=no
43739{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43740$as_echo_n "checking for FREETYPE... " >&6; }
43741
43742if test -n "$FREETYPE_CFLAGS"; then
43743    pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43744 elif test -n "$PKG_CONFIG"; then
43745    if test -n "$PKG_CONFIG" && \
43746    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43747  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43748  ac_status=$?
43749  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43750  test $ac_status = 0; }; then
43751  pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43752else
43753  pkg_failed=yes
43754fi
43755 else
43756    pkg_failed=untried
43757fi
43758if test -n "$FREETYPE_LIBS"; then
43759    pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
43760 elif test -n "$PKG_CONFIG"; then
43761    if test -n "$PKG_CONFIG" && \
43762    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43763  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43764  ac_status=$?
43765  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43766  test $ac_status = 0; }; then
43767  pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
43768else
43769  pkg_failed=yes
43770fi
43771 else
43772    pkg_failed=untried
43773fi
43774
43775
43776
43777if test $pkg_failed = yes; then
43778
43779if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
43780        _pkg_short_errors_supported=yes
43781else
43782        _pkg_short_errors_supported=no
43783fi
43784        if test $_pkg_short_errors_supported = yes; then
43785	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
43786        else
43787	        FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
43788        fi
43789	# Put the nasty error message in config.log where it belongs
43790	echo "$FREETYPE_PKG_ERRORS" >&5
43791
43792	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43793$as_echo "no" >&6; }
43794                FOUND_FREETYPE=no
43795elif test $pkg_failed = untried; then
43796	FOUND_FREETYPE=no
43797else
43798	FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
43799	FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
43800        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43801$as_echo "yes" >&6; }
43802	FOUND_FREETYPE=yes
43803fi
43804          if test "x$FOUND_FREETYPE" = xyes; then
43805            # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
43806            FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
43807            # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
43808            if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
43809              FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
43810            fi
43811            # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43812            if test "x$BUNDLE_FREETYPE" = xyes; then
43813              { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
43814$as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
43815              FOUND_FREETYPE=no
43816            else
43817              { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43818$as_echo_n "checking for freetype... " >&6; }
43819              { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
43820$as_echo "yes (using pkg-config)" >&6; }
43821            fi
43822          fi
43823        fi
43824      fi
43825
43826      if test "x$FOUND_FREETYPE" != xyes; then
43827        # Check in well-known locations
43828        if test "x$OPENJDK_TARGET_OS" = xwindows; then
43829          FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
43830
43831  windows_path="$FREETYPE_BASE_DIR"
43832  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43833    unix_path=`$CYGPATH -u "$windows_path"`
43834    FREETYPE_BASE_DIR="$unix_path"
43835  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43836    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43837    FREETYPE_BASE_DIR="$unix_path"
43838  fi
43839
43840
43841  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
43842  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
43843  METHOD="well-known location"
43844
43845  # First check if the files exists.
43846  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43847    # We found an arbitrary include file. That's a good sign.
43848    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43849$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43850    FOUND_FREETYPE=yes
43851
43852    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43853    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43854      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43855$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43856      FOUND_FREETYPE=no
43857    else
43858      if test "x$OPENJDK_TARGET_OS" = xwindows; then
43859        # On Windows, we will need both .lib and .dll file.
43860        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43861          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43862$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43863          FOUND_FREETYPE=no
43864        fi
43865      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
43866        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43867        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43868      fi
43869    fi
43870  fi
43871
43872  if test "x$FOUND_FREETYPE" = xyes; then
43873
43874  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43875
43876  # Input might be given as Windows format, start by converting to
43877  # unix format.
43878  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43879  new_path=`$CYGPATH -u "$path"`
43880
43881  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43882  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43883  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43884  # "foo.exe" is OK but "foo" is an error.
43885  #
43886  # This test is therefore slightly more accurate than "test -f" to check for file precense.
43887  # It is also a way to make sure we got the proper file name for the real test later on.
43888  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43889  if test "x$test_shortpath" = x; then
43890    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43891$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43892    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43893  fi
43894
43895  # Call helper function which possibly converts this using DOS-style short mode.
43896  # If so, the updated path is stored in $new_path.
43897
43898  input_path="$new_path"
43899  # Check if we need to convert this using DOS-style short mode. If the path
43900  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43901  # take no chances and rewrite it.
43902  # Note: m4 eats our [], so we need to use [ and ] instead.
43903  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43904  if test "x$has_forbidden_chars" != x; then
43905    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43906    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43907    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43908    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43909      # Going to short mode and back again did indeed matter. Since short mode is
43910      # case insensitive, let's make it lowercase to improve readability.
43911      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43912      # Now convert it back to Unix-stile (cygpath)
43913      input_path=`$CYGPATH -u "$shortmode_path"`
43914      new_path="$input_path"
43915    fi
43916  fi
43917
43918  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43919  if test "x$test_cygdrive_prefix" = x; then
43920    # As a simple fix, exclude /usr/bin since it's not a real path.
43921    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43922      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43923      # a path prefixed by /cygdrive for fixpath to work.
43924      new_path="$CYGWIN_ROOT_PATH$input_path"
43925    fi
43926  fi
43927
43928
43929  if test "x$path" != "x$new_path"; then
43930    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43931    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43932$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43933  fi
43934
43935  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43936
43937  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43938  has_colon=`$ECHO $path | $GREP ^.:`
43939  new_path="$path"
43940  if test "x$has_colon" = x; then
43941    # Not in mixed or Windows style, start by that.
43942    new_path=`cmd //c echo $path`
43943  fi
43944
43945
43946  input_path="$new_path"
43947  # Check if we need to convert this using DOS-style short mode. If the path
43948  # contains just simple characters, use it. Otherwise (spaces, weird characters),
43949  # take no chances and rewrite it.
43950  # Note: m4 eats our [], so we need to use [ and ] instead.
43951  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43952  if test "x$has_forbidden_chars" != x; then
43953    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43954    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43955  fi
43956
43957
43958  windows_path="$new_path"
43959  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43960    unix_path=`$CYGPATH -u "$windows_path"`
43961    new_path="$unix_path"
43962  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43963    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43964    new_path="$unix_path"
43965  fi
43966
43967  if test "x$path" != "x$new_path"; then
43968    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43969    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43970$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43971  fi
43972
43973  # Save the first 10 bytes of this path to the storage, so fixpath can work.
43974  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43975
43976  else
43977    # We're on a posix platform. Hooray! :)
43978    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43979    has_space=`$ECHO "$path" | $GREP " "`
43980    if test "x$has_space" != x; then
43981      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43982$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43983      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43984    fi
43985
43986    # Use eval to expand a potential ~
43987    eval path="$path"
43988    if test ! -f "$path" && test ! -d "$path"; then
43989      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43990    fi
43991
43992    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43993  fi
43994
43995
43996  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43997
43998  # Input might be given as Windows format, start by converting to
43999  # unix format.
44000  path="$POTENTIAL_FREETYPE_LIB_PATH"
44001  new_path=`$CYGPATH -u "$path"`
44002
44003  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44004  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44005  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44006  # "foo.exe" is OK but "foo" is an error.
44007  #
44008  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44009  # It is also a way to make sure we got the proper file name for the real test later on.
44010  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44011  if test "x$test_shortpath" = x; then
44012    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44013$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44014    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44015  fi
44016
44017  # Call helper function which possibly converts this using DOS-style short mode.
44018  # If so, the updated path is stored in $new_path.
44019
44020  input_path="$new_path"
44021  # Check if we need to convert this using DOS-style short mode. If the path
44022  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44023  # take no chances and rewrite it.
44024  # Note: m4 eats our [], so we need to use [ and ] instead.
44025  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44026  if test "x$has_forbidden_chars" != x; then
44027    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44028    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44029    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44030    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44031      # Going to short mode and back again did indeed matter. Since short mode is
44032      # case insensitive, let's make it lowercase to improve readability.
44033      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44034      # Now convert it back to Unix-stile (cygpath)
44035      input_path=`$CYGPATH -u "$shortmode_path"`
44036      new_path="$input_path"
44037    fi
44038  fi
44039
44040  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44041  if test "x$test_cygdrive_prefix" = x; then
44042    # As a simple fix, exclude /usr/bin since it's not a real path.
44043    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44044      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44045      # a path prefixed by /cygdrive for fixpath to work.
44046      new_path="$CYGWIN_ROOT_PATH$input_path"
44047    fi
44048  fi
44049
44050
44051  if test "x$path" != "x$new_path"; then
44052    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44053    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44054$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44055  fi
44056
44057  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44058
44059  path="$POTENTIAL_FREETYPE_LIB_PATH"
44060  has_colon=`$ECHO $path | $GREP ^.:`
44061  new_path="$path"
44062  if test "x$has_colon" = x; then
44063    # Not in mixed or Windows style, start by that.
44064    new_path=`cmd //c echo $path`
44065  fi
44066
44067
44068  input_path="$new_path"
44069  # Check if we need to convert this using DOS-style short mode. If the path
44070  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44071  # take no chances and rewrite it.
44072  # Note: m4 eats our [], so we need to use [ and ] instead.
44073  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44074  if test "x$has_forbidden_chars" != x; then
44075    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44076    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44077  fi
44078
44079
44080  windows_path="$new_path"
44081  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44082    unix_path=`$CYGPATH -u "$windows_path"`
44083    new_path="$unix_path"
44084  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44085    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44086    new_path="$unix_path"
44087  fi
44088
44089  if test "x$path" != "x$new_path"; then
44090    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44091    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44092$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44093  fi
44094
44095  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44096  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44097
44098  else
44099    # We're on a posix platform. Hooray! :)
44100    path="$POTENTIAL_FREETYPE_LIB_PATH"
44101    has_space=`$ECHO "$path" | $GREP " "`
44102    if test "x$has_space" != x; then
44103      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44104$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44105      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44106    fi
44107
44108    # Use eval to expand a potential ~
44109    eval path="$path"
44110    if test ! -f "$path" && test ! -d "$path"; then
44111      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44112    fi
44113
44114    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44115  fi
44116
44117
44118    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44119    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44120$as_echo_n "checking for freetype includes... " >&6; }
44121    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44122$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44123    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44124    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44125$as_echo_n "checking for freetype libraries... " >&6; }
44126    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44127$as_echo "$FREETYPE_LIB_PATH" >&6; }
44128  fi
44129
44130          if test "x$FOUND_FREETYPE" != xyes; then
44131            FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
44132
44133  windows_path="$FREETYPE_BASE_DIR"
44134  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44135    unix_path=`$CYGPATH -u "$windows_path"`
44136    FREETYPE_BASE_DIR="$unix_path"
44137  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44138    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44139    FREETYPE_BASE_DIR="$unix_path"
44140  fi
44141
44142
44143  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44144  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44145  METHOD="well-known location"
44146
44147  # First check if the files exists.
44148  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44149    # We found an arbitrary include file. That's a good sign.
44150    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44151$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44152    FOUND_FREETYPE=yes
44153
44154    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44155    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44156      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44157$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44158      FOUND_FREETYPE=no
44159    else
44160      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44161        # On Windows, we will need both .lib and .dll file.
44162        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44163          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44164$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44165          FOUND_FREETYPE=no
44166        fi
44167      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
44168        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44169        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44170      fi
44171    fi
44172  fi
44173
44174  if test "x$FOUND_FREETYPE" = xyes; then
44175
44176  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44177
44178  # Input might be given as Windows format, start by converting to
44179  # unix format.
44180  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44181  new_path=`$CYGPATH -u "$path"`
44182
44183  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44184  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44185  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44186  # "foo.exe" is OK but "foo" is an error.
44187  #
44188  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44189  # It is also a way to make sure we got the proper file name for the real test later on.
44190  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44191  if test "x$test_shortpath" = x; then
44192    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44193$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44194    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44195  fi
44196
44197  # Call helper function which possibly converts this using DOS-style short mode.
44198  # If so, the updated path is stored in $new_path.
44199
44200  input_path="$new_path"
44201  # Check if we need to convert this using DOS-style short mode. If the path
44202  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44203  # take no chances and rewrite it.
44204  # Note: m4 eats our [], so we need to use [ and ] instead.
44205  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44206  if test "x$has_forbidden_chars" != x; then
44207    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44208    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44209    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44210    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44211      # Going to short mode and back again did indeed matter. Since short mode is
44212      # case insensitive, let's make it lowercase to improve readability.
44213      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44214      # Now convert it back to Unix-stile (cygpath)
44215      input_path=`$CYGPATH -u "$shortmode_path"`
44216      new_path="$input_path"
44217    fi
44218  fi
44219
44220  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44221  if test "x$test_cygdrive_prefix" = x; then
44222    # As a simple fix, exclude /usr/bin since it's not a real path.
44223    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44224      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44225      # a path prefixed by /cygdrive for fixpath to work.
44226      new_path="$CYGWIN_ROOT_PATH$input_path"
44227    fi
44228  fi
44229
44230
44231  if test "x$path" != "x$new_path"; then
44232    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44233    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44234$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44235  fi
44236
44237  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44238
44239  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44240  has_colon=`$ECHO $path | $GREP ^.:`
44241  new_path="$path"
44242  if test "x$has_colon" = x; then
44243    # Not in mixed or Windows style, start by that.
44244    new_path=`cmd //c echo $path`
44245  fi
44246
44247
44248  input_path="$new_path"
44249  # Check if we need to convert this using DOS-style short mode. If the path
44250  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44251  # take no chances and rewrite it.
44252  # Note: m4 eats our [], so we need to use [ and ] instead.
44253  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44254  if test "x$has_forbidden_chars" != x; then
44255    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44256    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44257  fi
44258
44259
44260  windows_path="$new_path"
44261  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44262    unix_path=`$CYGPATH -u "$windows_path"`
44263    new_path="$unix_path"
44264  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44265    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44266    new_path="$unix_path"
44267  fi
44268
44269  if test "x$path" != "x$new_path"; then
44270    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44271    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44272$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44273  fi
44274
44275  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44276  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44277
44278  else
44279    # We're on a posix platform. Hooray! :)
44280    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44281    has_space=`$ECHO "$path" | $GREP " "`
44282    if test "x$has_space" != x; then
44283      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44284$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44285      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44286    fi
44287
44288    # Use eval to expand a potential ~
44289    eval path="$path"
44290    if test ! -f "$path" && test ! -d "$path"; then
44291      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44292    fi
44293
44294    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44295  fi
44296
44297
44298  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44299
44300  # Input might be given as Windows format, start by converting to
44301  # unix format.
44302  path="$POTENTIAL_FREETYPE_LIB_PATH"
44303  new_path=`$CYGPATH -u "$path"`
44304
44305  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44306  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44307  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44308  # "foo.exe" is OK but "foo" is an error.
44309  #
44310  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44311  # It is also a way to make sure we got the proper file name for the real test later on.
44312  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44313  if test "x$test_shortpath" = x; then
44314    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44315$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44316    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44317  fi
44318
44319  # Call helper function which possibly converts this using DOS-style short mode.
44320  # If so, the updated path is stored in $new_path.
44321
44322  input_path="$new_path"
44323  # Check if we need to convert this using DOS-style short mode. If the path
44324  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44325  # take no chances and rewrite it.
44326  # Note: m4 eats our [], so we need to use [ and ] instead.
44327  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44328  if test "x$has_forbidden_chars" != x; then
44329    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44330    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44331    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44332    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44333      # Going to short mode and back again did indeed matter. Since short mode is
44334      # case insensitive, let's make it lowercase to improve readability.
44335      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44336      # Now convert it back to Unix-stile (cygpath)
44337      input_path=`$CYGPATH -u "$shortmode_path"`
44338      new_path="$input_path"
44339    fi
44340  fi
44341
44342  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44343  if test "x$test_cygdrive_prefix" = x; then
44344    # As a simple fix, exclude /usr/bin since it's not a real path.
44345    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44346      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44347      # a path prefixed by /cygdrive for fixpath to work.
44348      new_path="$CYGWIN_ROOT_PATH$input_path"
44349    fi
44350  fi
44351
44352
44353  if test "x$path" != "x$new_path"; then
44354    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44355    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44356$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44357  fi
44358
44359  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44360
44361  path="$POTENTIAL_FREETYPE_LIB_PATH"
44362  has_colon=`$ECHO $path | $GREP ^.:`
44363  new_path="$path"
44364  if test "x$has_colon" = x; then
44365    # Not in mixed or Windows style, start by that.
44366    new_path=`cmd //c echo $path`
44367  fi
44368
44369
44370  input_path="$new_path"
44371  # Check if we need to convert this using DOS-style short mode. If the path
44372  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44373  # take no chances and rewrite it.
44374  # Note: m4 eats our [], so we need to use [ and ] instead.
44375  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44376  if test "x$has_forbidden_chars" != x; then
44377    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44378    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44379  fi
44380
44381
44382  windows_path="$new_path"
44383  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44384    unix_path=`$CYGPATH -u "$windows_path"`
44385    new_path="$unix_path"
44386  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44387    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44388    new_path="$unix_path"
44389  fi
44390
44391  if test "x$path" != "x$new_path"; then
44392    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44393    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44394$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44395  fi
44396
44397  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44398  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44399
44400  else
44401    # We're on a posix platform. Hooray! :)
44402    path="$POTENTIAL_FREETYPE_LIB_PATH"
44403    has_space=`$ECHO "$path" | $GREP " "`
44404    if test "x$has_space" != x; then
44405      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44406$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44407      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44408    fi
44409
44410    # Use eval to expand a potential ~
44411    eval path="$path"
44412    if test ! -f "$path" && test ! -d "$path"; then
44413      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44414    fi
44415
44416    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44417  fi
44418
44419
44420    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44421    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44422$as_echo_n "checking for freetype includes... " >&6; }
44423    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44424$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44425    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44426    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44427$as_echo_n "checking for freetype libraries... " >&6; }
44428    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44429$as_echo "$FREETYPE_LIB_PATH" >&6; }
44430  fi
44431
44432          fi
44433        else
44434          if test "x$SYS_ROOT" = "x/"; then
44435            FREETYPE_ROOT=
44436          else
44437            FREETYPE_ROOT="$SYS_ROOT"
44438          fi
44439          FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
44440
44441  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44442  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44443  METHOD="well-known location"
44444
44445  # First check if the files exists.
44446  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44447    # We found an arbitrary include file. That's a good sign.
44448    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44449$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44450    FOUND_FREETYPE=yes
44451
44452    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44453    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44454      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44455$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44456      FOUND_FREETYPE=no
44457    else
44458      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44459        # On Windows, we will need both .lib and .dll file.
44460        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44461          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44462$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44463          FOUND_FREETYPE=no
44464        fi
44465      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
44466        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44467        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44468      fi
44469    fi
44470  fi
44471
44472  if test "x$FOUND_FREETYPE" = xyes; then
44473
44474  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44475
44476  # Input might be given as Windows format, start by converting to
44477  # unix format.
44478  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44479  new_path=`$CYGPATH -u "$path"`
44480
44481  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44482  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44483  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44484  # "foo.exe" is OK but "foo" is an error.
44485  #
44486  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44487  # It is also a way to make sure we got the proper file name for the real test later on.
44488  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44489  if test "x$test_shortpath" = x; then
44490    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44491$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44492    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44493  fi
44494
44495  # Call helper function which possibly converts this using DOS-style short mode.
44496  # If so, the updated path is stored in $new_path.
44497
44498  input_path="$new_path"
44499  # Check if we need to convert this using DOS-style short mode. If the path
44500  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44501  # take no chances and rewrite it.
44502  # Note: m4 eats our [], so we need to use [ and ] instead.
44503  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44504  if test "x$has_forbidden_chars" != x; then
44505    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44506    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44507    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44508    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44509      # Going to short mode and back again did indeed matter. Since short mode is
44510      # case insensitive, let's make it lowercase to improve readability.
44511      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44512      # Now convert it back to Unix-stile (cygpath)
44513      input_path=`$CYGPATH -u "$shortmode_path"`
44514      new_path="$input_path"
44515    fi
44516  fi
44517
44518  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44519  if test "x$test_cygdrive_prefix" = x; then
44520    # As a simple fix, exclude /usr/bin since it's not a real path.
44521    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44522      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44523      # a path prefixed by /cygdrive for fixpath to work.
44524      new_path="$CYGWIN_ROOT_PATH$input_path"
44525    fi
44526  fi
44527
44528
44529  if test "x$path" != "x$new_path"; then
44530    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44531    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44532$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44533  fi
44534
44535  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44536
44537  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44538  has_colon=`$ECHO $path | $GREP ^.:`
44539  new_path="$path"
44540  if test "x$has_colon" = x; then
44541    # Not in mixed or Windows style, start by that.
44542    new_path=`cmd //c echo $path`
44543  fi
44544
44545
44546  input_path="$new_path"
44547  # Check if we need to convert this using DOS-style short mode. If the path
44548  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44549  # take no chances and rewrite it.
44550  # Note: m4 eats our [], so we need to use [ and ] instead.
44551  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44552  if test "x$has_forbidden_chars" != x; then
44553    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44554    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44555  fi
44556
44557
44558  windows_path="$new_path"
44559  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44560    unix_path=`$CYGPATH -u "$windows_path"`
44561    new_path="$unix_path"
44562  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44563    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44564    new_path="$unix_path"
44565  fi
44566
44567  if test "x$path" != "x$new_path"; then
44568    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44569    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44570$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44571  fi
44572
44573  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44574  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44575
44576  else
44577    # We're on a posix platform. Hooray! :)
44578    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44579    has_space=`$ECHO "$path" | $GREP " "`
44580    if test "x$has_space" != x; then
44581      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44582$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44583      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44584    fi
44585
44586    # Use eval to expand a potential ~
44587    eval path="$path"
44588    if test ! -f "$path" && test ! -d "$path"; then
44589      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44590    fi
44591
44592    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44593  fi
44594
44595
44596  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44597
44598  # Input might be given as Windows format, start by converting to
44599  # unix format.
44600  path="$POTENTIAL_FREETYPE_LIB_PATH"
44601  new_path=`$CYGPATH -u "$path"`
44602
44603  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44604  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44605  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44606  # "foo.exe" is OK but "foo" is an error.
44607  #
44608  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44609  # It is also a way to make sure we got the proper file name for the real test later on.
44610  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44611  if test "x$test_shortpath" = x; then
44612    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44613$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44614    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44615  fi
44616
44617  # Call helper function which possibly converts this using DOS-style short mode.
44618  # If so, the updated path is stored in $new_path.
44619
44620  input_path="$new_path"
44621  # Check if we need to convert this using DOS-style short mode. If the path
44622  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44623  # take no chances and rewrite it.
44624  # Note: m4 eats our [], so we need to use [ and ] instead.
44625  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44626  if test "x$has_forbidden_chars" != x; then
44627    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44628    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44629    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44630    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44631      # Going to short mode and back again did indeed matter. Since short mode is
44632      # case insensitive, let's make it lowercase to improve readability.
44633      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44634      # Now convert it back to Unix-stile (cygpath)
44635      input_path=`$CYGPATH -u "$shortmode_path"`
44636      new_path="$input_path"
44637    fi
44638  fi
44639
44640  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44641  if test "x$test_cygdrive_prefix" = x; then
44642    # As a simple fix, exclude /usr/bin since it's not a real path.
44643    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44644      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44645      # a path prefixed by /cygdrive for fixpath to work.
44646      new_path="$CYGWIN_ROOT_PATH$input_path"
44647    fi
44648  fi
44649
44650
44651  if test "x$path" != "x$new_path"; then
44652    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44653    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44654$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44655  fi
44656
44657  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44658
44659  path="$POTENTIAL_FREETYPE_LIB_PATH"
44660  has_colon=`$ECHO $path | $GREP ^.:`
44661  new_path="$path"
44662  if test "x$has_colon" = x; then
44663    # Not in mixed or Windows style, start by that.
44664    new_path=`cmd //c echo $path`
44665  fi
44666
44667
44668  input_path="$new_path"
44669  # Check if we need to convert this using DOS-style short mode. If the path
44670  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44671  # take no chances and rewrite it.
44672  # Note: m4 eats our [], so we need to use [ and ] instead.
44673  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44674  if test "x$has_forbidden_chars" != x; then
44675    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44676    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44677  fi
44678
44679
44680  windows_path="$new_path"
44681  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44682    unix_path=`$CYGPATH -u "$windows_path"`
44683    new_path="$unix_path"
44684  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44685    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44686    new_path="$unix_path"
44687  fi
44688
44689  if test "x$path" != "x$new_path"; then
44690    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44691    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44692$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44693  fi
44694
44695  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44696  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44697
44698  else
44699    # We're on a posix platform. Hooray! :)
44700    path="$POTENTIAL_FREETYPE_LIB_PATH"
44701    has_space=`$ECHO "$path" | $GREP " "`
44702    if test "x$has_space" != x; then
44703      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44704$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44705      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44706    fi
44707
44708    # Use eval to expand a potential ~
44709    eval path="$path"
44710    if test ! -f "$path" && test ! -d "$path"; then
44711      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44712    fi
44713
44714    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44715  fi
44716
44717
44718    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44719    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44720$as_echo_n "checking for freetype includes... " >&6; }
44721    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44722$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44723    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44724    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44725$as_echo_n "checking for freetype libraries... " >&6; }
44726    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44727$as_echo "$FREETYPE_LIB_PATH" >&6; }
44728  fi
44729
44730
44731          if test "x$FOUND_FREETYPE" != xyes; then
44732            FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr/X11"
44733
44734  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44735  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44736  METHOD="well-known location"
44737
44738  # First check if the files exists.
44739  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44740    # We found an arbitrary include file. That's a good sign.
44741    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44742$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44743    FOUND_FREETYPE=yes
44744
44745    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44746    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44747      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44748$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44749      FOUND_FREETYPE=no
44750    else
44751      if test "x$OPENJDK_TARGET_OS" = xwindows; then
44752        # On Windows, we will need both .lib and .dll file.
44753        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44754          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44755$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44756          FOUND_FREETYPE=no
44757        fi
44758      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
44759        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44760        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44761      fi
44762    fi
44763  fi
44764
44765  if test "x$FOUND_FREETYPE" = xyes; then
44766
44767  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44768
44769  # Input might be given as Windows format, start by converting to
44770  # unix format.
44771  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44772  new_path=`$CYGPATH -u "$path"`
44773
44774  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44775  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44776  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44777  # "foo.exe" is OK but "foo" is an error.
44778  #
44779  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44780  # It is also a way to make sure we got the proper file name for the real test later on.
44781  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44782  if test "x$test_shortpath" = x; then
44783    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44784$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44785    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44786  fi
44787
44788  # Call helper function which possibly converts this using DOS-style short mode.
44789  # If so, the updated path is stored in $new_path.
44790
44791  input_path="$new_path"
44792  # Check if we need to convert this using DOS-style short mode. If the path
44793  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44794  # take no chances and rewrite it.
44795  # Note: m4 eats our [], so we need to use [ and ] instead.
44796  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44797  if test "x$has_forbidden_chars" != x; then
44798    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44799    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44800    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44801    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44802      # Going to short mode and back again did indeed matter. Since short mode is
44803      # case insensitive, let's make it lowercase to improve readability.
44804      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44805      # Now convert it back to Unix-stile (cygpath)
44806      input_path=`$CYGPATH -u "$shortmode_path"`
44807      new_path="$input_path"
44808    fi
44809  fi
44810
44811  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44812  if test "x$test_cygdrive_prefix" = x; then
44813    # As a simple fix, exclude /usr/bin since it's not a real path.
44814    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44815      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44816      # a path prefixed by /cygdrive for fixpath to work.
44817      new_path="$CYGWIN_ROOT_PATH$input_path"
44818    fi
44819  fi
44820
44821
44822  if test "x$path" != "x$new_path"; then
44823    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44824    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44825$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44826  fi
44827
44828  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44829
44830  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44831  has_colon=`$ECHO $path | $GREP ^.:`
44832  new_path="$path"
44833  if test "x$has_colon" = x; then
44834    # Not in mixed or Windows style, start by that.
44835    new_path=`cmd //c echo $path`
44836  fi
44837
44838
44839  input_path="$new_path"
44840  # Check if we need to convert this using DOS-style short mode. If the path
44841  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44842  # take no chances and rewrite it.
44843  # Note: m4 eats our [], so we need to use [ and ] instead.
44844  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44845  if test "x$has_forbidden_chars" != x; then
44846    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44847    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44848  fi
44849
44850
44851  windows_path="$new_path"
44852  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44853    unix_path=`$CYGPATH -u "$windows_path"`
44854    new_path="$unix_path"
44855  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44856    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44857    new_path="$unix_path"
44858  fi
44859
44860  if test "x$path" != "x$new_path"; then
44861    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44862    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44863$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44864  fi
44865
44866  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44867  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44868
44869  else
44870    # We're on a posix platform. Hooray! :)
44871    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44872    has_space=`$ECHO "$path" | $GREP " "`
44873    if test "x$has_space" != x; then
44874      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44875$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44876      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44877    fi
44878
44879    # Use eval to expand a potential ~
44880    eval path="$path"
44881    if test ! -f "$path" && test ! -d "$path"; then
44882      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44883    fi
44884
44885    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44886  fi
44887
44888
44889  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44890
44891  # Input might be given as Windows format, start by converting to
44892  # unix format.
44893  path="$POTENTIAL_FREETYPE_LIB_PATH"
44894  new_path=`$CYGPATH -u "$path"`
44895
44896  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44897  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44898  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44899  # "foo.exe" is OK but "foo" is an error.
44900  #
44901  # This test is therefore slightly more accurate than "test -f" to check for file precense.
44902  # It is also a way to make sure we got the proper file name for the real test later on.
44903  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44904  if test "x$test_shortpath" = x; then
44905    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44906$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44907    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44908  fi
44909
44910  # Call helper function which possibly converts this using DOS-style short mode.
44911  # If so, the updated path is stored in $new_path.
44912
44913  input_path="$new_path"
44914  # Check if we need to convert this using DOS-style short mode. If the path
44915  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44916  # take no chances and rewrite it.
44917  # Note: m4 eats our [], so we need to use [ and ] instead.
44918  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44919  if test "x$has_forbidden_chars" != x; then
44920    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44921    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44922    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44923    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44924      # Going to short mode and back again did indeed matter. Since short mode is
44925      # case insensitive, let's make it lowercase to improve readability.
44926      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44927      # Now convert it back to Unix-stile (cygpath)
44928      input_path=`$CYGPATH -u "$shortmode_path"`
44929      new_path="$input_path"
44930    fi
44931  fi
44932
44933  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44934  if test "x$test_cygdrive_prefix" = x; then
44935    # As a simple fix, exclude /usr/bin since it's not a real path.
44936    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44937      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44938      # a path prefixed by /cygdrive for fixpath to work.
44939      new_path="$CYGWIN_ROOT_PATH$input_path"
44940    fi
44941  fi
44942
44943
44944  if test "x$path" != "x$new_path"; then
44945    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44946    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44947$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44948  fi
44949
44950  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44951
44952  path="$POTENTIAL_FREETYPE_LIB_PATH"
44953  has_colon=`$ECHO $path | $GREP ^.:`
44954  new_path="$path"
44955  if test "x$has_colon" = x; then
44956    # Not in mixed or Windows style, start by that.
44957    new_path=`cmd //c echo $path`
44958  fi
44959
44960
44961  input_path="$new_path"
44962  # Check if we need to convert this using DOS-style short mode. If the path
44963  # contains just simple characters, use it. Otherwise (spaces, weird characters),
44964  # take no chances and rewrite it.
44965  # Note: m4 eats our [], so we need to use [ and ] instead.
44966  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44967  if test "x$has_forbidden_chars" != x; then
44968    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44969    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44970  fi
44971
44972
44973  windows_path="$new_path"
44974  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44975    unix_path=`$CYGPATH -u "$windows_path"`
44976    new_path="$unix_path"
44977  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44978    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44979    new_path="$unix_path"
44980  fi
44981
44982  if test "x$path" != "x$new_path"; then
44983    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44984    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44985$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44986  fi
44987
44988  # Save the first 10 bytes of this path to the storage, so fixpath can work.
44989  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44990
44991  else
44992    # We're on a posix platform. Hooray! :)
44993    path="$POTENTIAL_FREETYPE_LIB_PATH"
44994    has_space=`$ECHO "$path" | $GREP " "`
44995    if test "x$has_space" != x; then
44996      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44997$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44998      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44999    fi
45000
45001    # Use eval to expand a potential ~
45002    eval path="$path"
45003    if test ! -f "$path" && test ! -d "$path"; then
45004      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45005    fi
45006
45007    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45008  fi
45009
45010
45011    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45012    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45013$as_echo_n "checking for freetype includes... " >&6; }
45014    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45015$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45016    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45017    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45018$as_echo_n "checking for freetype libraries... " >&6; }
45019    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45020$as_echo "$FREETYPE_LIB_PATH" >&6; }
45021  fi
45022
45023          fi
45024
45025          if test "x$FOUND_FREETYPE" != xyes; then
45026            FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
45027            if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45028
45029  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45030  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45031  METHOD="well-known location"
45032
45033  # First check if the files exists.
45034  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45035    # We found an arbitrary include file. That's a good sign.
45036    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45037$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45038    FOUND_FREETYPE=yes
45039
45040    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45041    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45042      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45043$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45044      FOUND_FREETYPE=no
45045    else
45046      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45047        # On Windows, we will need both .lib and .dll file.
45048        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45049          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45050$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45051          FOUND_FREETYPE=no
45052        fi
45053      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
45054        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45055        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45056      fi
45057    fi
45058  fi
45059
45060  if test "x$FOUND_FREETYPE" = xyes; then
45061
45062  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45063
45064  # Input might be given as Windows format, start by converting to
45065  # unix format.
45066  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45067  new_path=`$CYGPATH -u "$path"`
45068
45069  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45070  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45071  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45072  # "foo.exe" is OK but "foo" is an error.
45073  #
45074  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45075  # It is also a way to make sure we got the proper file name for the real test later on.
45076  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45077  if test "x$test_shortpath" = x; then
45078    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45079$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45080    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45081  fi
45082
45083  # Call helper function which possibly converts this using DOS-style short mode.
45084  # If so, the updated path is stored in $new_path.
45085
45086  input_path="$new_path"
45087  # Check if we need to convert this using DOS-style short mode. If the path
45088  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45089  # take no chances and rewrite it.
45090  # Note: m4 eats our [], so we need to use [ and ] instead.
45091  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45092  if test "x$has_forbidden_chars" != x; then
45093    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45094    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45095    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45096    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45097      # Going to short mode and back again did indeed matter. Since short mode is
45098      # case insensitive, let's make it lowercase to improve readability.
45099      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45100      # Now convert it back to Unix-stile (cygpath)
45101      input_path=`$CYGPATH -u "$shortmode_path"`
45102      new_path="$input_path"
45103    fi
45104  fi
45105
45106  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45107  if test "x$test_cygdrive_prefix" = x; then
45108    # As a simple fix, exclude /usr/bin since it's not a real path.
45109    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45110      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45111      # a path prefixed by /cygdrive for fixpath to work.
45112      new_path="$CYGWIN_ROOT_PATH$input_path"
45113    fi
45114  fi
45115
45116
45117  if test "x$path" != "x$new_path"; then
45118    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45119    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45120$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45121  fi
45122
45123  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45124
45125  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45126  has_colon=`$ECHO $path | $GREP ^.:`
45127  new_path="$path"
45128  if test "x$has_colon" = x; then
45129    # Not in mixed or Windows style, start by that.
45130    new_path=`cmd //c echo $path`
45131  fi
45132
45133
45134  input_path="$new_path"
45135  # Check if we need to convert this using DOS-style short mode. If the path
45136  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45137  # take no chances and rewrite it.
45138  # Note: m4 eats our [], so we need to use [ and ] instead.
45139  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45140  if test "x$has_forbidden_chars" != x; then
45141    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45142    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45143  fi
45144
45145
45146  windows_path="$new_path"
45147  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45148    unix_path=`$CYGPATH -u "$windows_path"`
45149    new_path="$unix_path"
45150  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45151    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45152    new_path="$unix_path"
45153  fi
45154
45155  if test "x$path" != "x$new_path"; then
45156    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45157    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45158$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45159  fi
45160
45161  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45162  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45163
45164  else
45165    # We're on a posix platform. Hooray! :)
45166    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45167    has_space=`$ECHO "$path" | $GREP " "`
45168    if test "x$has_space" != x; then
45169      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45170$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45171      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45172    fi
45173
45174    # Use eval to expand a potential ~
45175    eval path="$path"
45176    if test ! -f "$path" && test ! -d "$path"; then
45177      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45178    fi
45179
45180    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45181  fi
45182
45183
45184  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45185
45186  # Input might be given as Windows format, start by converting to
45187  # unix format.
45188  path="$POTENTIAL_FREETYPE_LIB_PATH"
45189  new_path=`$CYGPATH -u "$path"`
45190
45191  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45192  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45193  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45194  # "foo.exe" is OK but "foo" is an error.
45195  #
45196  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45197  # It is also a way to make sure we got the proper file name for the real test later on.
45198  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45199  if test "x$test_shortpath" = x; then
45200    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45201$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45202    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45203  fi
45204
45205  # Call helper function which possibly converts this using DOS-style short mode.
45206  # If so, the updated path is stored in $new_path.
45207
45208  input_path="$new_path"
45209  # Check if we need to convert this using DOS-style short mode. If the path
45210  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45211  # take no chances and rewrite it.
45212  # Note: m4 eats our [], so we need to use [ and ] instead.
45213  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45214  if test "x$has_forbidden_chars" != x; then
45215    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45216    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45217    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45218    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45219      # Going to short mode and back again did indeed matter. Since short mode is
45220      # case insensitive, let's make it lowercase to improve readability.
45221      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45222      # Now convert it back to Unix-stile (cygpath)
45223      input_path=`$CYGPATH -u "$shortmode_path"`
45224      new_path="$input_path"
45225    fi
45226  fi
45227
45228  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45229  if test "x$test_cygdrive_prefix" = x; then
45230    # As a simple fix, exclude /usr/bin since it's not a real path.
45231    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45232      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45233      # a path prefixed by /cygdrive for fixpath to work.
45234      new_path="$CYGWIN_ROOT_PATH$input_path"
45235    fi
45236  fi
45237
45238
45239  if test "x$path" != "x$new_path"; then
45240    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45241    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45242$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45243  fi
45244
45245  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45246
45247  path="$POTENTIAL_FREETYPE_LIB_PATH"
45248  has_colon=`$ECHO $path | $GREP ^.:`
45249  new_path="$path"
45250  if test "x$has_colon" = x; then
45251    # Not in mixed or Windows style, start by that.
45252    new_path=`cmd //c echo $path`
45253  fi
45254
45255
45256  input_path="$new_path"
45257  # Check if we need to convert this using DOS-style short mode. If the path
45258  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45259  # take no chances and rewrite it.
45260  # Note: m4 eats our [], so we need to use [ and ] instead.
45261  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45262  if test "x$has_forbidden_chars" != x; then
45263    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45264    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45265  fi
45266
45267
45268  windows_path="$new_path"
45269  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45270    unix_path=`$CYGPATH -u "$windows_path"`
45271    new_path="$unix_path"
45272  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45273    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45274    new_path="$unix_path"
45275  fi
45276
45277  if test "x$path" != "x$new_path"; then
45278    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45279    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45280$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45281  fi
45282
45283  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45284  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45285
45286  else
45287    # We're on a posix platform. Hooray! :)
45288    path="$POTENTIAL_FREETYPE_LIB_PATH"
45289    has_space=`$ECHO "$path" | $GREP " "`
45290    if test "x$has_space" != x; then
45291      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45292$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45293      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45294    fi
45295
45296    # Use eval to expand a potential ~
45297    eval path="$path"
45298    if test ! -f "$path" && test ! -d "$path"; then
45299      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45300    fi
45301
45302    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45303  fi
45304
45305
45306    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45307    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45308$as_echo_n "checking for freetype includes... " >&6; }
45309    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45310$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45311    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45312    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45313$as_echo_n "checking for freetype libraries... " >&6; }
45314    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45315$as_echo "$FREETYPE_LIB_PATH" >&6; }
45316  fi
45317
45318            else
45319
45320  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45321  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
45322  METHOD="well-known location"
45323
45324  # First check if the files exists.
45325  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45326    # We found an arbitrary include file. That's a good sign.
45327    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45328$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45329    FOUND_FREETYPE=yes
45330
45331    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45332    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45333      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45334$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45335      FOUND_FREETYPE=no
45336    else
45337      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45338        # On Windows, we will need both .lib and .dll file.
45339        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45340          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45341$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45342          FOUND_FREETYPE=no
45343        fi
45344      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
45345        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45346        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45347      fi
45348    fi
45349  fi
45350
45351  if test "x$FOUND_FREETYPE" = xyes; then
45352
45353  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45354
45355  # Input might be given as Windows format, start by converting to
45356  # unix format.
45357  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45358  new_path=`$CYGPATH -u "$path"`
45359
45360  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45361  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45362  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45363  # "foo.exe" is OK but "foo" is an error.
45364  #
45365  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45366  # It is also a way to make sure we got the proper file name for the real test later on.
45367  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45368  if test "x$test_shortpath" = x; then
45369    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45370$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45371    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45372  fi
45373
45374  # Call helper function which possibly converts this using DOS-style short mode.
45375  # If so, the updated path is stored in $new_path.
45376
45377  input_path="$new_path"
45378  # Check if we need to convert this using DOS-style short mode. If the path
45379  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45380  # take no chances and rewrite it.
45381  # Note: m4 eats our [], so we need to use [ and ] instead.
45382  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45383  if test "x$has_forbidden_chars" != x; then
45384    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45385    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45386    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45387    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45388      # Going to short mode and back again did indeed matter. Since short mode is
45389      # case insensitive, let's make it lowercase to improve readability.
45390      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45391      # Now convert it back to Unix-stile (cygpath)
45392      input_path=`$CYGPATH -u "$shortmode_path"`
45393      new_path="$input_path"
45394    fi
45395  fi
45396
45397  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45398  if test "x$test_cygdrive_prefix" = x; then
45399    # As a simple fix, exclude /usr/bin since it's not a real path.
45400    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45401      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45402      # a path prefixed by /cygdrive for fixpath to work.
45403      new_path="$CYGWIN_ROOT_PATH$input_path"
45404    fi
45405  fi
45406
45407
45408  if test "x$path" != "x$new_path"; then
45409    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45410    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45411$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45412  fi
45413
45414  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45415
45416  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45417  has_colon=`$ECHO $path | $GREP ^.:`
45418  new_path="$path"
45419  if test "x$has_colon" = x; then
45420    # Not in mixed or Windows style, start by that.
45421    new_path=`cmd //c echo $path`
45422  fi
45423
45424
45425  input_path="$new_path"
45426  # Check if we need to convert this using DOS-style short mode. If the path
45427  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45428  # take no chances and rewrite it.
45429  # Note: m4 eats our [], so we need to use [ and ] instead.
45430  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45431  if test "x$has_forbidden_chars" != x; then
45432    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45433    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45434  fi
45435
45436
45437  windows_path="$new_path"
45438  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45439    unix_path=`$CYGPATH -u "$windows_path"`
45440    new_path="$unix_path"
45441  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45442    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45443    new_path="$unix_path"
45444  fi
45445
45446  if test "x$path" != "x$new_path"; then
45447    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45448    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45449$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45450  fi
45451
45452  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45453  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45454
45455  else
45456    # We're on a posix platform. Hooray! :)
45457    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45458    has_space=`$ECHO "$path" | $GREP " "`
45459    if test "x$has_space" != x; then
45460      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45461$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45462      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45463    fi
45464
45465    # Use eval to expand a potential ~
45466    eval path="$path"
45467    if test ! -f "$path" && test ! -d "$path"; then
45468      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45469    fi
45470
45471    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45472  fi
45473
45474
45475  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45476
45477  # Input might be given as Windows format, start by converting to
45478  # unix format.
45479  path="$POTENTIAL_FREETYPE_LIB_PATH"
45480  new_path=`$CYGPATH -u "$path"`
45481
45482  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45483  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45484  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45485  # "foo.exe" is OK but "foo" is an error.
45486  #
45487  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45488  # It is also a way to make sure we got the proper file name for the real test later on.
45489  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45490  if test "x$test_shortpath" = x; then
45491    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45492$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45493    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45494  fi
45495
45496  # Call helper function which possibly converts this using DOS-style short mode.
45497  # If so, the updated path is stored in $new_path.
45498
45499  input_path="$new_path"
45500  # Check if we need to convert this using DOS-style short mode. If the path
45501  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45502  # take no chances and rewrite it.
45503  # Note: m4 eats our [], so we need to use [ and ] instead.
45504  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45505  if test "x$has_forbidden_chars" != x; then
45506    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45507    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45508    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45509    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45510      # Going to short mode and back again did indeed matter. Since short mode is
45511      # case insensitive, let's make it lowercase to improve readability.
45512      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45513      # Now convert it back to Unix-stile (cygpath)
45514      input_path=`$CYGPATH -u "$shortmode_path"`
45515      new_path="$input_path"
45516    fi
45517  fi
45518
45519  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45520  if test "x$test_cygdrive_prefix" = x; then
45521    # As a simple fix, exclude /usr/bin since it's not a real path.
45522    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45523      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45524      # a path prefixed by /cygdrive for fixpath to work.
45525      new_path="$CYGWIN_ROOT_PATH$input_path"
45526    fi
45527  fi
45528
45529
45530  if test "x$path" != "x$new_path"; then
45531    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45532    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45533$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45534  fi
45535
45536  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45537
45538  path="$POTENTIAL_FREETYPE_LIB_PATH"
45539  has_colon=`$ECHO $path | $GREP ^.:`
45540  new_path="$path"
45541  if test "x$has_colon" = x; then
45542    # Not in mixed or Windows style, start by that.
45543    new_path=`cmd //c echo $path`
45544  fi
45545
45546
45547  input_path="$new_path"
45548  # Check if we need to convert this using DOS-style short mode. If the path
45549  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45550  # take no chances and rewrite it.
45551  # Note: m4 eats our [], so we need to use [ and ] instead.
45552  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45553  if test "x$has_forbidden_chars" != x; then
45554    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45555    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45556  fi
45557
45558
45559  windows_path="$new_path"
45560  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45561    unix_path=`$CYGPATH -u "$windows_path"`
45562    new_path="$unix_path"
45563  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45564    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45565    new_path="$unix_path"
45566  fi
45567
45568  if test "x$path" != "x$new_path"; then
45569    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45570    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45571$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45572  fi
45573
45574  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45575  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45576
45577  else
45578    # We're on a posix platform. Hooray! :)
45579    path="$POTENTIAL_FREETYPE_LIB_PATH"
45580    has_space=`$ECHO "$path" | $GREP " "`
45581    if test "x$has_space" != x; then
45582      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45583$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45584      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45585    fi
45586
45587    # Use eval to expand a potential ~
45588    eval path="$path"
45589    if test ! -f "$path" && test ! -d "$path"; then
45590      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45591    fi
45592
45593    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45594  fi
45595
45596
45597    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45598    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45599$as_echo_n "checking for freetype includes... " >&6; }
45600    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45601$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45602    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45603    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45604$as_echo_n "checking for freetype libraries... " >&6; }
45605    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45606$as_echo "$FREETYPE_LIB_PATH" >&6; }
45607  fi
45608
45609              if test "x$FOUND_FREETYPE" != xyes; then
45610
45611  POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45612  POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
45613  METHOD="well-known location"
45614
45615  # First check if the files exists.
45616  if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45617    # We found an arbitrary include file. That's a good sign.
45618    { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45619$as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45620    FOUND_FREETYPE=yes
45621
45622    FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45623    if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45624      { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45625$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45626      FOUND_FREETYPE=no
45627    else
45628      if test "x$OPENJDK_TARGET_OS" = xwindows; then
45629        # On Windows, we will need both .lib and .dll file.
45630        if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45631          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45632$as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45633          FOUND_FREETYPE=no
45634        fi
45635      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
45636        # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45637        POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45638      fi
45639    fi
45640  fi
45641
45642  if test "x$FOUND_FREETYPE" = xyes; then
45643
45644  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45645
45646  # Input might be given as Windows format, start by converting to
45647  # unix format.
45648  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45649  new_path=`$CYGPATH -u "$path"`
45650
45651  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45652  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45653  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45654  # "foo.exe" is OK but "foo" is an error.
45655  #
45656  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45657  # It is also a way to make sure we got the proper file name for the real test later on.
45658  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45659  if test "x$test_shortpath" = x; then
45660    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45661$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45662    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45663  fi
45664
45665  # Call helper function which possibly converts this using DOS-style short mode.
45666  # If so, the updated path is stored in $new_path.
45667
45668  input_path="$new_path"
45669  # Check if we need to convert this using DOS-style short mode. If the path
45670  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45671  # take no chances and rewrite it.
45672  # Note: m4 eats our [], so we need to use [ and ] instead.
45673  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45674  if test "x$has_forbidden_chars" != x; then
45675    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45676    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45677    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45678    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45679      # Going to short mode and back again did indeed matter. Since short mode is
45680      # case insensitive, let's make it lowercase to improve readability.
45681      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45682      # Now convert it back to Unix-stile (cygpath)
45683      input_path=`$CYGPATH -u "$shortmode_path"`
45684      new_path="$input_path"
45685    fi
45686  fi
45687
45688  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45689  if test "x$test_cygdrive_prefix" = x; then
45690    # As a simple fix, exclude /usr/bin since it's not a real path.
45691    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45692      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45693      # a path prefixed by /cygdrive for fixpath to work.
45694      new_path="$CYGWIN_ROOT_PATH$input_path"
45695    fi
45696  fi
45697
45698
45699  if test "x$path" != "x$new_path"; then
45700    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45701    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45702$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45703  fi
45704
45705  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45706
45707  path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45708  has_colon=`$ECHO $path | $GREP ^.:`
45709  new_path="$path"
45710  if test "x$has_colon" = x; then
45711    # Not in mixed or Windows style, start by that.
45712    new_path=`cmd //c echo $path`
45713  fi
45714
45715
45716  input_path="$new_path"
45717  # Check if we need to convert this using DOS-style short mode. If the path
45718  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45719  # take no chances and rewrite it.
45720  # Note: m4 eats our [], so we need to use [ and ] instead.
45721  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45722  if test "x$has_forbidden_chars" != x; then
45723    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45724    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45725  fi
45726
45727
45728  windows_path="$new_path"
45729  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45730    unix_path=`$CYGPATH -u "$windows_path"`
45731    new_path="$unix_path"
45732  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45733    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45734    new_path="$unix_path"
45735  fi
45736
45737  if test "x$path" != "x$new_path"; then
45738    POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45739    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45740$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45741  fi
45742
45743  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45744  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45745
45746  else
45747    # We're on a posix platform. Hooray! :)
45748    path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45749    has_space=`$ECHO "$path" | $GREP " "`
45750    if test "x$has_space" != x; then
45751      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45752$as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45753      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45754    fi
45755
45756    # Use eval to expand a potential ~
45757    eval path="$path"
45758    if test ! -f "$path" && test ! -d "$path"; then
45759      as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45760    fi
45761
45762    POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45763  fi
45764
45765
45766  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45767
45768  # Input might be given as Windows format, start by converting to
45769  # unix format.
45770  path="$POTENTIAL_FREETYPE_LIB_PATH"
45771  new_path=`$CYGPATH -u "$path"`
45772
45773  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45774  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45775  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45776  # "foo.exe" is OK but "foo" is an error.
45777  #
45778  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45779  # It is also a way to make sure we got the proper file name for the real test later on.
45780  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45781  if test "x$test_shortpath" = x; then
45782    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45783$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45784    as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45785  fi
45786
45787  # Call helper function which possibly converts this using DOS-style short mode.
45788  # If so, the updated path is stored in $new_path.
45789
45790  input_path="$new_path"
45791  # Check if we need to convert this using DOS-style short mode. If the path
45792  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45793  # take no chances and rewrite it.
45794  # Note: m4 eats our [], so we need to use [ and ] instead.
45795  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45796  if test "x$has_forbidden_chars" != x; then
45797    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45798    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45799    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45800    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45801      # Going to short mode and back again did indeed matter. Since short mode is
45802      # case insensitive, let's make it lowercase to improve readability.
45803      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45804      # Now convert it back to Unix-stile (cygpath)
45805      input_path=`$CYGPATH -u "$shortmode_path"`
45806      new_path="$input_path"
45807    fi
45808  fi
45809
45810  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45811  if test "x$test_cygdrive_prefix" = x; then
45812    # As a simple fix, exclude /usr/bin since it's not a real path.
45813    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45814      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45815      # a path prefixed by /cygdrive for fixpath to work.
45816      new_path="$CYGWIN_ROOT_PATH$input_path"
45817    fi
45818  fi
45819
45820
45821  if test "x$path" != "x$new_path"; then
45822    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45823    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45824$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45825  fi
45826
45827  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45828
45829  path="$POTENTIAL_FREETYPE_LIB_PATH"
45830  has_colon=`$ECHO $path | $GREP ^.:`
45831  new_path="$path"
45832  if test "x$has_colon" = x; then
45833    # Not in mixed or Windows style, start by that.
45834    new_path=`cmd //c echo $path`
45835  fi
45836
45837
45838  input_path="$new_path"
45839  # Check if we need to convert this using DOS-style short mode. If the path
45840  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45841  # take no chances and rewrite it.
45842  # Note: m4 eats our [], so we need to use [ and ] instead.
45843  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45844  if test "x$has_forbidden_chars" != x; then
45845    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45846    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45847  fi
45848
45849
45850  windows_path="$new_path"
45851  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45852    unix_path=`$CYGPATH -u "$windows_path"`
45853    new_path="$unix_path"
45854  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45855    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45856    new_path="$unix_path"
45857  fi
45858
45859  if test "x$path" != "x$new_path"; then
45860    POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45861    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45862$as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45863  fi
45864
45865  # Save the first 10 bytes of this path to the storage, so fixpath can work.
45866  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45867
45868  else
45869    # We're on a posix platform. Hooray! :)
45870    path="$POTENTIAL_FREETYPE_LIB_PATH"
45871    has_space=`$ECHO "$path" | $GREP " "`
45872    if test "x$has_space" != x; then
45873      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45874$as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45875      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45876    fi
45877
45878    # Use eval to expand a potential ~
45879    eval path="$path"
45880    if test ! -f "$path" && test ! -d "$path"; then
45881      as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45882    fi
45883
45884    POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45885  fi
45886
45887
45888    FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45889    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45890$as_echo_n "checking for freetype includes... " >&6; }
45891    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45892$as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45893    FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45894    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45895$as_echo_n "checking for freetype libraries... " >&6; }
45896    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45897$as_echo "$FREETYPE_LIB_PATH" >&6; }
45898  fi
45899
45900              fi
45901            fi
45902          fi
45903        fi
45904      fi # end check in well-known locations
45905
45906      if test "x$FOUND_FREETYPE" != xyes; then
45907
45908  # Print a helpful message on how to acquire the necessary build dependency.
45909  # freetype is the help tag: freetype, cups, pulse, alsa etc
45910  MISSING_DEPENDENCY=freetype
45911
45912  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45913    cygwin_help $MISSING_DEPENDENCY
45914  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45915    msys_help $MISSING_DEPENDENCY
45916  else
45917    PKGHANDLER_COMMAND=
45918
45919    case $PKGHANDLER in
45920      apt-get)
45921        apt_help     $MISSING_DEPENDENCY ;;
45922      yum)
45923        yum_help     $MISSING_DEPENDENCY ;;
45924      port)
45925        port_help    $MISSING_DEPENDENCY ;;
45926      pkgutil)
45927        pkgutil_help $MISSING_DEPENDENCY ;;
45928      pkgadd)
45929        pkgadd_help  $MISSING_DEPENDENCY ;;
45930    esac
45931
45932    if test "x$PKGHANDLER_COMMAND" != x; then
45933      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
45934    fi
45935  fi
45936
45937        as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
45938      fi
45939    fi # end user specified settings
45940
45941    # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
45942    if test "x$FREETYPE_CFLAGS" = x; then
45943
45944  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45945
45946  # Input might be given as Windows format, start by converting to
45947  # unix format.
45948  path="$FREETYPE_INCLUDE_PATH"
45949  new_path=`$CYGPATH -u "$path"`
45950
45951  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45952  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45953  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45954  # "foo.exe" is OK but "foo" is an error.
45955  #
45956  # This test is therefore slightly more accurate than "test -f" to check for file precense.
45957  # It is also a way to make sure we got the proper file name for the real test later on.
45958  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45959  if test "x$test_shortpath" = x; then
45960    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45961$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45962    as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
45963  fi
45964
45965  # Call helper function which possibly converts this using DOS-style short mode.
45966  # If so, the updated path is stored in $new_path.
45967
45968  input_path="$new_path"
45969  # Check if we need to convert this using DOS-style short mode. If the path
45970  # contains just simple characters, use it. Otherwise (spaces, weird characters),
45971  # take no chances and rewrite it.
45972  # Note: m4 eats our [], so we need to use [ and ] instead.
45973  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45974  if test "x$has_forbidden_chars" != x; then
45975    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45976    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45977    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45978    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45979      # Going to short mode and back again did indeed matter. Since short mode is
45980      # case insensitive, let's make it lowercase to improve readability.
45981      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45982      # Now convert it back to Unix-stile (cygpath)
45983      input_path=`$CYGPATH -u "$shortmode_path"`
45984      new_path="$input_path"
45985    fi
45986  fi
45987
45988  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45989  if test "x$test_cygdrive_prefix" = x; then
45990    # As a simple fix, exclude /usr/bin since it's not a real path.
45991    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45992      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45993      # a path prefixed by /cygdrive for fixpath to work.
45994      new_path="$CYGWIN_ROOT_PATH$input_path"
45995    fi
45996  fi
45997
45998
45999  if test "x$path" != "x$new_path"; then
46000    FREETYPE_INCLUDE_PATH="$new_path"
46001    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46002$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46003  fi
46004
46005  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46006
46007  path="$FREETYPE_INCLUDE_PATH"
46008  has_colon=`$ECHO $path | $GREP ^.:`
46009  new_path="$path"
46010  if test "x$has_colon" = x; then
46011    # Not in mixed or Windows style, start by that.
46012    new_path=`cmd //c echo $path`
46013  fi
46014
46015
46016  input_path="$new_path"
46017  # Check if we need to convert this using DOS-style short mode. If the path
46018  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46019  # take no chances and rewrite it.
46020  # Note: m4 eats our [], so we need to use [ and ] instead.
46021  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46022  if test "x$has_forbidden_chars" != x; then
46023    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46024    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46025  fi
46026
46027
46028  windows_path="$new_path"
46029  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46030    unix_path=`$CYGPATH -u "$windows_path"`
46031    new_path="$unix_path"
46032  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46033    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46034    new_path="$unix_path"
46035  fi
46036
46037  if test "x$path" != "x$new_path"; then
46038    FREETYPE_INCLUDE_PATH="$new_path"
46039    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46040$as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46041  fi
46042
46043  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46044  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46045
46046  else
46047    # We're on a posix platform. Hooray! :)
46048    path="$FREETYPE_INCLUDE_PATH"
46049    has_space=`$ECHO "$path" | $GREP " "`
46050    if test "x$has_space" != x; then
46051      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46052$as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46053      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46054    fi
46055
46056    # Use eval to expand a potential ~
46057    eval path="$path"
46058    if test ! -f "$path" && test ! -d "$path"; then
46059      as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46060    fi
46061
46062    FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46063  fi
46064
46065      if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
46066        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
46067      else
46068        FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
46069      fi
46070    fi
46071
46072    if test "x$FREETYPE_LIBS" = x; then
46073
46074  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46075
46076  # Input might be given as Windows format, start by converting to
46077  # unix format.
46078  path="$FREETYPE_LIB_PATH"
46079  new_path=`$CYGPATH -u "$path"`
46080
46081  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46082  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46083  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46084  # "foo.exe" is OK but "foo" is an error.
46085  #
46086  # This test is therefore slightly more accurate than "test -f" to check for file precense.
46087  # It is also a way to make sure we got the proper file name for the real test later on.
46088  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46089  if test "x$test_shortpath" = x; then
46090    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46091$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46092    as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
46093  fi
46094
46095  # Call helper function which possibly converts this using DOS-style short mode.
46096  # If so, the updated path is stored in $new_path.
46097
46098  input_path="$new_path"
46099  # Check if we need to convert this using DOS-style short mode. If the path
46100  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46101  # take no chances and rewrite it.
46102  # Note: m4 eats our [], so we need to use [ and ] instead.
46103  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46104  if test "x$has_forbidden_chars" != x; then
46105    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46106    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46107    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46108    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46109      # Going to short mode and back again did indeed matter. Since short mode is
46110      # case insensitive, let's make it lowercase to improve readability.
46111      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46112      # Now convert it back to Unix-stile (cygpath)
46113      input_path=`$CYGPATH -u "$shortmode_path"`
46114      new_path="$input_path"
46115    fi
46116  fi
46117
46118  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46119  if test "x$test_cygdrive_prefix" = x; then
46120    # As a simple fix, exclude /usr/bin since it's not a real path.
46121    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46122      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46123      # a path prefixed by /cygdrive for fixpath to work.
46124      new_path="$CYGWIN_ROOT_PATH$input_path"
46125    fi
46126  fi
46127
46128
46129  if test "x$path" != "x$new_path"; then
46130    FREETYPE_LIB_PATH="$new_path"
46131    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46132$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46133  fi
46134
46135  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46136
46137  path="$FREETYPE_LIB_PATH"
46138  has_colon=`$ECHO $path | $GREP ^.:`
46139  new_path="$path"
46140  if test "x$has_colon" = x; then
46141    # Not in mixed or Windows style, start by that.
46142    new_path=`cmd //c echo $path`
46143  fi
46144
46145
46146  input_path="$new_path"
46147  # Check if we need to convert this using DOS-style short mode. If the path
46148  # contains just simple characters, use it. Otherwise (spaces, weird characters),
46149  # take no chances and rewrite it.
46150  # Note: m4 eats our [], so we need to use [ and ] instead.
46151  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46152  if test "x$has_forbidden_chars" != x; then
46153    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46154    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46155  fi
46156
46157
46158  windows_path="$new_path"
46159  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46160    unix_path=`$CYGPATH -u "$windows_path"`
46161    new_path="$unix_path"
46162  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46163    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46164    new_path="$unix_path"
46165  fi
46166
46167  if test "x$path" != "x$new_path"; then
46168    FREETYPE_LIB_PATH="$new_path"
46169    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46170$as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46171  fi
46172
46173  # Save the first 10 bytes of this path to the storage, so fixpath can work.
46174  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46175
46176  else
46177    # We're on a posix platform. Hooray! :)
46178    path="$FREETYPE_LIB_PATH"
46179    has_space=`$ECHO "$path" | $GREP " "`
46180    if test "x$has_space" != x; then
46181      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46182$as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46183      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46184    fi
46185
46186    # Use eval to expand a potential ~
46187    eval path="$path"
46188    if test ! -f "$path" && test ! -d "$path"; then
46189      as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46190    fi
46191
46192    FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46193  fi
46194
46195      if test "x$OPENJDK_TARGET_OS" = xwindows; then
46196        FREETYPE_LIBS="$FREETYPE_LIB_PATH/freetype.lib"
46197      else
46198        FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -lfreetype"
46199      fi
46200    fi
46201
46202    # Try to compile it
46203    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
46204$as_echo_n "checking if we can compile and link with freetype... " >&6; }
46205    ac_ext=cpp
46206ac_cpp='$CXXCPP $CPPFLAGS'
46207ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46208ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46209ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46210
46211    PREV_CXXCFLAGS="$CXXFLAGS"
46212    PREV_LIBS="$LIBS"
46213    PREV_CXX="$CXX"
46214    CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
46215    LIBS="$LIBS $FREETYPE_LIBS"
46216    CXX="$FIXPATH $CXX"
46217    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46218/* end confdefs.h.  */
46219
46220          #include<ft2build.h>
46221          #include FT_FREETYPE_H
46222          int main () {
46223            FT_Init_FreeType(NULL);
46224            return 0;
46225          }
46226
46227_ACEOF
46228if ac_fn_cxx_try_link "$LINENO"; then :
46229
46230          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46231$as_echo "yes" >&6; }
46232
46233else
46234
46235          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46236$as_echo "no" >&6; }
46237          { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
46238$as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
46239          { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
46240$as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
46241
46242
46243  # Print a helpful message on how to acquire the necessary build dependency.
46244  # freetype is the help tag: freetype, cups, pulse, alsa etc
46245  MISSING_DEPENDENCY=freetype
46246
46247  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46248    cygwin_help $MISSING_DEPENDENCY
46249  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46250    msys_help $MISSING_DEPENDENCY
46251  else
46252    PKGHANDLER_COMMAND=
46253
46254    case $PKGHANDLER in
46255      apt-get)
46256        apt_help     $MISSING_DEPENDENCY ;;
46257      yum)
46258        yum_help     $MISSING_DEPENDENCY ;;
46259      port)
46260        port_help    $MISSING_DEPENDENCY ;;
46261      pkgutil)
46262        pkgutil_help $MISSING_DEPENDENCY ;;
46263      pkgadd)
46264        pkgadd_help  $MISSING_DEPENDENCY ;;
46265    esac
46266
46267    if test "x$PKGHANDLER_COMMAND" != x; then
46268      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46269    fi
46270  fi
46271
46272
46273          as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
46274
46275
46276fi
46277rm -f core conftest.err conftest.$ac_objext \
46278    conftest$ac_exeext conftest.$ac_ext
46279    CXXCFLAGS="$PREV_CXXFLAGS"
46280    LIBS="$PREV_LIBS"
46281    CXX="$PREV_CXX"
46282    ac_ext=cpp
46283ac_cpp='$CXXCPP $CPPFLAGS'
46284ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46285ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46286ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46287
46288
46289    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
46290$as_echo_n "checking if we should bundle freetype... " >&6; }
46291    if test "x$BUNDLE_FREETYPE" = xyes; then
46292      FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
46293    fi
46294    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
46295$as_echo "$BUNDLE_FREETYPE" >&6; }
46296
46297  fi # end freetype needed
46298
46299
46300
46301
46302
46303
46304
46305  ###############################################################################
46306  #
46307  # Check for alsa headers and libraries. Used on Linux/GNU systems.
46308  #
46309
46310# Check whether --with-alsa was given.
46311if test "${with_alsa+set}" = set; then :
46312  withval=$with_alsa;
46313fi
46314
46315
46316# Check whether --with-alsa-include was given.
46317if test "${with_alsa_include+set}" = set; then :
46318  withval=$with_alsa_include;
46319fi
46320
46321
46322# Check whether --with-alsa-lib was given.
46323if test "${with_alsa_lib+set}" = set; then :
46324  withval=$with_alsa_lib;
46325fi
46326
46327
46328  if test "x$ALSA_NOT_NEEDED" = xyes; then
46329    if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
46330      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
46331$as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
46332    fi
46333    ALSA_CFLAGS=
46334    ALSA_LIBS=
46335  else
46336    ALSA_FOUND=no
46337
46338    if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
46339      as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
46340    fi
46341
46342    if test "x${with_alsa}" != x; then
46343      ALSA_LIBS="-L${with_alsa}/lib -lasound"
46344      ALSA_CFLAGS="-I${with_alsa}/include"
46345      ALSA_FOUND=yes
46346    fi
46347    if test "x${with_alsa_include}" != x; then
46348      ALSA_CFLAGS="-I${with_alsa_include}"
46349      ALSA_FOUND=yes
46350    fi
46351    if test "x${with_alsa_lib}" != x; then
46352      ALSA_LIBS="-L${with_alsa_lib} -lasound"
46353      ALSA_FOUND=yes
46354    fi
46355    if test "x$ALSA_FOUND" = xno; then
46356
46357
46358  if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
46359    # Source the builddeps file again, to make sure it uses the latest variables!
46360    . $builddepsfile
46361    # Look for a target and build machine specific resource!
46362    eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
46363    if test "x$resource" = x; then
46364      # Ok, lets instead look for a target specific resource
46365      eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
46366    fi
46367    if test "x$resource" = x; then
46368      # Ok, lets instead look for a build specific resource
46369      eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
46370    fi
46371    if test "x$resource" = x; then
46372      # Ok, lets instead look for a generic resource
46373      # (The alsa comes from M4 and not the shell, thus no need for eval here.)
46374      resource=${builddep_alsa}
46375    fi
46376    if test "x$resource" != x; then
46377      { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
46378$as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
46379      # If the resource in the builddeps.conf file is an existing directory,
46380      # for example /java/linux/cups
46381      if test -d ${resource}; then
46382        depdir=${resource}
46383      else
46384
46385  # alsa is for example mymodule
46386  # $resource is for example libs/general/libmymod_1_2_3.zip
46387  # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
46388  # $with_builddeps_dir is for example /localhome/builddeps
46389  # depdir is the name of the variable into which we store the depdir, eg MYMOD
46390  # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
46391  # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
46392  filename=`basename $resource`
46393  filebase=`echo $filename | sed 's/\.[^\.]*$//'`
46394  filebase=${filename%%.*}
46395  extension=${filename#*.}
46396  installdir=$with_builddeps_dir/$filebase
46397  if test ! -f $installdir/$filename.unpacked; then
46398    { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
46399$as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
46400    if test ! -d $installdir; then
46401      mkdir -p $installdir
46402    fi
46403    if test ! -d $installdir; then
46404      as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
46405    fi
46406    tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
46407    touch $tmpfile
46408    if test ! -f $tmpfile; then
46409      as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
46410    fi
46411
46412  # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
46413  # $tmpfile is the local file name for the downloaded file.
46414  VALID_TOOL=no
46415  if test "x$BDEPS_FTP" = xwget; then
46416    VALID_TOOL=yes
46417    wget -O $tmpfile $with_builddeps_server/$resource
46418  fi
46419  if test "x$BDEPS_FTP" = xlftp; then
46420    VALID_TOOL=yes
46421    lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
46422  fi
46423  if test "x$BDEPS_FTP" = xftp; then
46424    VALID_TOOL=yes
46425    FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
46426    FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
46427    FTPUSERPWD=${FTPSERVER%%@*}
46428    if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
46429      FTPUSER=${userpwd%%:*}
46430      FTPPWD=${userpwd#*@}
46431      FTPSERVER=${FTPSERVER#*@}
46432    else
46433      FTPUSER=ftp
46434      FTPPWD=ftp
46435    fi
46436    # the "pass" command does not work on some
46437    # ftp clients (read ftp.exe) but if it works,
46438    # passive mode is better!
46439    ( \
46440        echo "user $FTPUSER $FTPPWD"        ; \
46441        echo "pass"                         ; \
46442        echo "bin"                          ; \
46443        echo "get $FTPPATH $tmpfile"              ; \
46444    ) | ftp -in $FTPSERVER
46445  fi
46446  if test "x$VALID_TOOL" != xyes; then
46447    as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
46448  fi
46449
46450    mv $tmpfile $installdir/$filename
46451    if test ! -s $installdir/$filename; then
46452      as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
46453    fi
46454    case "$extension" in
46455      zip)  echo "Unzipping $installdir/$filename..."
46456        (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
46457        ;;
46458      tar.gz) echo "Untaring $installdir/$filename..."
46459        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46460        ;;
46461      tgz) echo "Untaring $installdir/$filename..."
46462        (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46463        ;;
46464      *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
46465        ;;
46466    esac
46467  fi
46468  if test -f $installdir/$filename.unpacked; then
46469    depdir=$installdir
46470  fi
46471
46472      fi
46473      # Source the builddeps file again, because in the previous command, the depdir
46474      # was updated to point at the current build dependency install directory.
46475      . $builddepsfile
46476      # Now extract variables from the builddeps.conf files.
46477      theroot=${builddep_alsa_ROOT}
46478      thecflags=${builddep_alsa_CFLAGS}
46479      thelibs=${builddep_alsa_LIBS}
46480      if test "x$depdir" = x; then
46481        as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
46482      fi
46483      ALSA=$depdir
46484      if test "x$theroot" != x; then
46485        ALSA="$theroot"
46486      fi
46487      if test "x$thecflags" != x; then
46488        ALSA_CFLAGS="$thecflags"
46489      fi
46490      if test "x$thelibs" != x; then
46491        ALSA_LIBS="$thelibs"
46492      fi
46493      ALSA_FOUND=yes
46494      else ALSA_FOUND=no
46495
46496    fi
46497    else ALSA_FOUND=no
46498
46499  fi
46500
46501    fi
46502    if test "x$ALSA_FOUND" = xno; then
46503
46504pkg_failed=no
46505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46506$as_echo_n "checking for ALSA... " >&6; }
46507
46508if test -n "$ALSA_CFLAGS"; then
46509    pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46510 elif test -n "$PKG_CONFIG"; then
46511    if test -n "$PKG_CONFIG" && \
46512    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46513  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46514  ac_status=$?
46515  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46516  test $ac_status = 0; }; then
46517  pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46518else
46519  pkg_failed=yes
46520fi
46521 else
46522    pkg_failed=untried
46523fi
46524if test -n "$ALSA_LIBS"; then
46525    pkg_cv_ALSA_LIBS="$ALSA_LIBS"
46526 elif test -n "$PKG_CONFIG"; then
46527    if test -n "$PKG_CONFIG" && \
46528    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46529  ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46530  ac_status=$?
46531  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46532  test $ac_status = 0; }; then
46533  pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
46534else
46535  pkg_failed=yes
46536fi
46537 else
46538    pkg_failed=untried
46539fi
46540
46541
46542
46543if test $pkg_failed = yes; then
46544
46545if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
46546        _pkg_short_errors_supported=yes
46547else
46548        _pkg_short_errors_supported=no
46549fi
46550        if test $_pkg_short_errors_supported = yes; then
46551	        ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
46552        else
46553	        ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
46554        fi
46555	# Put the nasty error message in config.log where it belongs
46556	echo "$ALSA_PKG_ERRORS" >&5
46557
46558	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46559$as_echo "no" >&6; }
46560                ALSA_FOUND=no
46561elif test $pkg_failed = untried; then
46562	ALSA_FOUND=no
46563else
46564	ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
46565	ALSA_LIBS=$pkg_cv_ALSA_LIBS
46566        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46567$as_echo "yes" >&6; }
46568	ALSA_FOUND=yes
46569fi
46570    fi
46571    if test "x$ALSA_FOUND" = xno; then
46572      for ac_header in alsa/asoundlib.h
46573do :
46574  ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
46575if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
46576  cat >>confdefs.h <<_ACEOF
46577#define HAVE_ALSA_ASOUNDLIB_H 1
46578_ACEOF
46579
46580            ALSA_FOUND=yes
46581            ALSA_CFLAGS=-Iignoreme
46582            ALSA_LIBS=-lasound
46583            DEFAULT_ALSA=yes
46584
46585else
46586  ALSA_FOUND=no
46587fi
46588
46589done
46590
46591    fi
46592    if test "x$ALSA_FOUND" = xno; then
46593
46594  # Print a helpful message on how to acquire the necessary build dependency.
46595  # alsa is the help tag: freetype, cups, pulse, alsa etc
46596  MISSING_DEPENDENCY=alsa
46597
46598  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46599    cygwin_help $MISSING_DEPENDENCY
46600  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46601    msys_help $MISSING_DEPENDENCY
46602  else
46603    PKGHANDLER_COMMAND=
46604
46605    case $PKGHANDLER in
46606      apt-get)
46607        apt_help     $MISSING_DEPENDENCY ;;
46608      yum)
46609        yum_help     $MISSING_DEPENDENCY ;;
46610      port)
46611        port_help    $MISSING_DEPENDENCY ;;
46612      pkgutil)
46613        pkgutil_help $MISSING_DEPENDENCY ;;
46614      pkgadd)
46615        pkgadd_help  $MISSING_DEPENDENCY ;;
46616    esac
46617
46618    if test "x$PKGHANDLER_COMMAND" != x; then
46619      HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46620    fi
46621  fi
46622
46623      as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
46624    fi
46625  fi
46626
46627
46628
46629
46630
46631
46632  ###############################################################################
46633  #
46634  # Check for the jpeg library
46635  #
46636
46637  USE_EXTERNAL_LIBJPEG=true
46638  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5
46639$as_echo_n "checking for main in -ljpeg... " >&6; }
46640if ${ac_cv_lib_jpeg_main+:} false; then :
46641  $as_echo_n "(cached) " >&6
46642else
46643  ac_check_lib_save_LIBS=$LIBS
46644LIBS="-ljpeg  $LIBS"
46645cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46646/* end confdefs.h.  */
46647
46648
46649int
46650main ()
46651{
46652return main ();
46653  ;
46654  return 0;
46655}
46656_ACEOF
46657if ac_fn_cxx_try_link "$LINENO"; then :
46658  ac_cv_lib_jpeg_main=yes
46659else
46660  ac_cv_lib_jpeg_main=no
46661fi
46662rm -f core conftest.err conftest.$ac_objext \
46663    conftest$ac_exeext conftest.$ac_ext
46664LIBS=$ac_check_lib_save_LIBS
46665fi
46666{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5
46667$as_echo "$ac_cv_lib_jpeg_main" >&6; }
46668if test "x$ac_cv_lib_jpeg_main" = xyes; then :
46669  cat >>confdefs.h <<_ACEOF
46670#define HAVE_LIBJPEG 1
46671_ACEOF
46672
46673  LIBS="-ljpeg $LIBS"
46674
46675else
46676   USE_EXTERNAL_LIBJPEG=false
46677      { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5
46678$as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;}
46679
46680fi
46681
46682
46683
46684  ###############################################################################
46685  #
46686  # Check for the gif library
46687  #
46688
46689
46690# Check whether --with-giflib was given.
46691if test "${with_giflib+set}" = set; then :
46692  withval=$with_giflib;
46693fi
46694
46695
46696
46697  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
46698$as_echo_n "checking for which giflib to use... " >&6; }
46699
46700  # default is bundled
46701  DEFAULT_GIFLIB=bundled
46702
46703  #
46704  # if user didn't specify, use DEFAULT_GIFLIB
46705  #
46706  if test "x${with_giflib}" = "x"; then
46707    with_giflib=${DEFAULT_GIFLIB}
46708  fi
46709
46710  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
46711$as_echo "${with_giflib}" >&6; }
46712
46713  if test "x${with_giflib}" = "xbundled"; then
46714    USE_EXTERNAL_LIBGIF=false
46715  elif test "x${with_giflib}" = "xsystem"; then
46716    ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
46717if test "x$ac_cv_header_gif_lib_h" = xyes; then :
46718
46719else
46720   as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
46721fi
46722
46723
46724    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
46725$as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
46726if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
46727  $as_echo_n "(cached) " >&6
46728else
46729  ac_check_lib_save_LIBS=$LIBS
46730LIBS="-lgif  $LIBS"
46731cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46732/* end confdefs.h.  */
46733
46734/* Override any GCC internal prototype to avoid an error.
46735   Use char because int might match the return type of a GCC
46736   builtin and then its argument prototype would still apply.  */
46737#ifdef __cplusplus
46738extern "C"
46739#endif
46740char DGifGetCode ();
46741int
46742main ()
46743{
46744return DGifGetCode ();
46745  ;
46746  return 0;
46747}
46748_ACEOF
46749if ac_fn_cxx_try_link "$LINENO"; then :
46750  ac_cv_lib_gif_DGifGetCode=yes
46751else
46752  ac_cv_lib_gif_DGifGetCode=no
46753fi
46754rm -f core conftest.err conftest.$ac_objext \
46755    conftest$ac_exeext conftest.$ac_ext
46756LIBS=$ac_check_lib_save_LIBS
46757fi
46758{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
46759$as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
46760if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
46761  cat >>confdefs.h <<_ACEOF
46762#define HAVE_LIBGIF 1
46763_ACEOF
46764
46765  LIBS="-lgif $LIBS"
46766
46767else
46768   as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
46769fi
46770
46771
46772    USE_EXTERNAL_LIBGIF=true
46773  else
46774    as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
46775  fi
46776
46777
46778  ###############################################################################
46779  #
46780  # Check for the zlib library
46781  #
46782
46783
46784# Check whether --with-zlib was given.
46785if test "${with_zlib+set}" = set; then :
46786  withval=$with_zlib;
46787fi
46788
46789
46790  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
46791$as_echo_n "checking for compress in -lz... " >&6; }
46792if ${ac_cv_lib_z_compress+:} false; then :
46793  $as_echo_n "(cached) " >&6
46794else
46795  ac_check_lib_save_LIBS=$LIBS
46796LIBS="-lz  $LIBS"
46797cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46798/* end confdefs.h.  */
46799
46800/* Override any GCC internal prototype to avoid an error.
46801   Use char because int might match the return type of a GCC
46802   builtin and then its argument prototype would still apply.  */
46803#ifdef __cplusplus
46804extern "C"
46805#endif
46806char compress ();
46807int
46808main ()
46809{
46810return compress ();
46811  ;
46812  return 0;
46813}
46814_ACEOF
46815if ac_fn_cxx_try_link "$LINENO"; then :
46816  ac_cv_lib_z_compress=yes
46817else
46818  ac_cv_lib_z_compress=no
46819fi
46820rm -f core conftest.err conftest.$ac_objext \
46821    conftest$ac_exeext conftest.$ac_ext
46822LIBS=$ac_check_lib_save_LIBS
46823fi
46824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
46825$as_echo "$ac_cv_lib_z_compress" >&6; }
46826if test "x$ac_cv_lib_z_compress" = xyes; then :
46827   ZLIB_FOUND=yes
46828else
46829   ZLIB_FOUND=no
46830fi
46831
46832
46833  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
46834$as_echo_n "checking for which zlib to use... " >&6; }
46835
46836  DEFAULT_ZLIB=bundled
46837  if test "x$OPENJDK_TARGET_OS" = xmacosx; then
46838    #
46839    # On macosx default is system...on others default is
46840    #
46841    DEFAULT_ZLIB=system
46842  fi
46843
46844  if test "x${ZLIB_FOUND}" != "xyes"; then
46845    #
46846    # If we don't find any system...set default to bundled
46847    #
46848    DEFAULT_ZLIB=bundled
46849  fi
46850
46851  #
46852  # If user didn't specify, use DEFAULT_ZLIB
46853  #
46854  if test "x${with_zlib}" = "x"; then
46855    with_zlib=${DEFAULT_ZLIB}
46856  fi
46857
46858  if test "x${with_zlib}" = "xbundled"; then
46859    USE_EXTERNAL_LIBZ=false
46860    { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
46861$as_echo "bundled" >&6; }
46862  elif test "x${with_zlib}" = "xsystem"; then
46863    if test "x${ZLIB_FOUND}" = "xyes"; then
46864      USE_EXTERNAL_LIBZ=true
46865      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
46866$as_echo "system" >&6; }
46867    else
46868      { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
46869$as_echo "system not found" >&6; }
46870      as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
46871    fi
46872  else
46873    as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
46874  fi
46875
46876
46877
46878  ###############################################################################
46879  LIBZIP_CAN_USE_MMAP=true
46880
46881
46882
46883  ###############################################################################
46884  #
46885  # Check if altzone exists in time.h
46886  #
46887
46888  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46889/* end confdefs.h.  */
46890#include <time.h>
46891int
46892main ()
46893{
46894return (int)altzone;
46895  ;
46896  return 0;
46897}
46898_ACEOF
46899if ac_fn_cxx_try_link "$LINENO"; then :
46900  has_altzone=yes
46901else
46902  has_altzone=no
46903fi
46904rm -f core conftest.err conftest.$ac_objext \
46905    conftest$ac_exeext conftest.$ac_ext
46906  if test "x$has_altzone" = xyes; then
46907
46908$as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
46909
46910  fi
46911
46912  ###############################################################################
46913  #
46914  # Check the maths library
46915  #
46916
46917  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
46918$as_echo_n "checking for cos in -lm... " >&6; }
46919if ${ac_cv_lib_m_cos+:} false; then :
46920  $as_echo_n "(cached) " >&6
46921else
46922  ac_check_lib_save_LIBS=$LIBS
46923LIBS="-lm  $LIBS"
46924cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46925/* end confdefs.h.  */
46926
46927/* Override any GCC internal prototype to avoid an error.
46928   Use char because int might match the return type of a GCC
46929   builtin and then its argument prototype would still apply.  */
46930#ifdef __cplusplus
46931extern "C"
46932#endif
46933char cos ();
46934int
46935main ()
46936{
46937return cos ();
46938  ;
46939  return 0;
46940}
46941_ACEOF
46942if ac_fn_cxx_try_link "$LINENO"; then :
46943  ac_cv_lib_m_cos=yes
46944else
46945  ac_cv_lib_m_cos=no
46946fi
46947rm -f core conftest.err conftest.$ac_objext \
46948    conftest$ac_exeext conftest.$ac_ext
46949LIBS=$ac_check_lib_save_LIBS
46950fi
46951{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
46952$as_echo "$ac_cv_lib_m_cos" >&6; }
46953if test "x$ac_cv_lib_m_cos" = xyes; then :
46954  cat >>confdefs.h <<_ACEOF
46955#define HAVE_LIBM 1
46956_ACEOF
46957
46958  LIBS="-lm $LIBS"
46959
46960else
46961
46962        { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
46963$as_echo "$as_me: Maths library was not found" >&6;}
46964
46965
46966fi
46967
46968
46969
46970  ###############################################################################
46971  #
46972  # Check for libdl.so
46973
46974  save_LIBS="$LIBS"
46975  LIBS=""
46976  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
46977$as_echo_n "checking for dlopen in -ldl... " >&6; }
46978if ${ac_cv_lib_dl_dlopen+:} false; then :
46979  $as_echo_n "(cached) " >&6
46980else
46981  ac_check_lib_save_LIBS=$LIBS
46982LIBS="-ldl  $LIBS"
46983cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46984/* end confdefs.h.  */
46985
46986/* Override any GCC internal prototype to avoid an error.
46987   Use char because int might match the return type of a GCC
46988   builtin and then its argument prototype would still apply.  */
46989#ifdef __cplusplus
46990extern "C"
46991#endif
46992char dlopen ();
46993int
46994main ()
46995{
46996return dlopen ();
46997  ;
46998  return 0;
46999}
47000_ACEOF
47001if ac_fn_cxx_try_link "$LINENO"; then :
47002  ac_cv_lib_dl_dlopen=yes
47003else
47004  ac_cv_lib_dl_dlopen=no
47005fi
47006rm -f core conftest.err conftest.$ac_objext \
47007    conftest$ac_exeext conftest.$ac_ext
47008LIBS=$ac_check_lib_save_LIBS
47009fi
47010{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
47011$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
47012if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
47013  cat >>confdefs.h <<_ACEOF
47014#define HAVE_LIBDL 1
47015_ACEOF
47016
47017  LIBS="-ldl $LIBS"
47018
47019fi
47020
47021  LIBDL="$LIBS"
47022
47023  LIBS="$save_LIBS"
47024
47025
47026  ###############################################################################
47027  #
47028  # statically link libstdc++ before C++ ABI is stablized on Linux unless
47029  # dynamic build is configured on command line.
47030  #
47031
47032# Check whether --with-stdc++lib was given.
47033if test "${with_stdc__lib+set}" = set; then :
47034  withval=$with_stdc__lib;
47035        if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
47036                && test "x$with_stdc__lib" != xdefault; then
47037          as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
47038        fi
47039
47040else
47041  with_stdc__lib=default
47042
47043fi
47044
47045
47046  if test "x$OPENJDK_TARGET_OS" = xlinux; then
47047    # Test if -lstdc++ works.
47048    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
47049$as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
47050    ac_ext=cpp
47051ac_cpp='$CXXCPP $CPPFLAGS'
47052ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47053ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47054ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47055
47056    OLD_CXXFLAGS="$CXXFLAGS"
47057    CXXFLAGS="$CXXFLAGS -lstdc++"
47058    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47059/* end confdefs.h.  */
47060
47061int
47062main ()
47063{
47064return 0;
47065  ;
47066  return 0;
47067}
47068_ACEOF
47069if ac_fn_cxx_try_link "$LINENO"; then :
47070  has_dynamic_libstdcxx=yes
47071else
47072  has_dynamic_libstdcxx=no
47073fi
47074rm -f core conftest.err conftest.$ac_objext \
47075    conftest$ac_exeext conftest.$ac_ext
47076    CXXFLAGS="$OLD_CXXFLAGS"
47077    ac_ext=cpp
47078ac_cpp='$CXXCPP $CPPFLAGS'
47079ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47080ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47081ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47082
47083    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
47084$as_echo "$has_dynamic_libstdcxx" >&6; }
47085
47086    # Test if stdc++ can be linked statically.
47087    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
47088$as_echo_n "checking if static link of stdc++ is possible... " >&6; }
47089    STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
47090    ac_ext=cpp
47091ac_cpp='$CXXCPP $CPPFLAGS'
47092ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47093ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47094ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47095
47096    OLD_LIBS="$LIBS"
47097    OLD_CXX="$CXX"
47098    LIBS="$STATIC_STDCXX_FLAGS"
47099    CXX="$CC"
47100    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47101/* end confdefs.h.  */
47102
47103int
47104main ()
47105{
47106return 0;
47107  ;
47108  return 0;
47109}
47110_ACEOF
47111if ac_fn_cxx_try_link "$LINENO"; then :
47112  has_static_libstdcxx=yes
47113else
47114  has_static_libstdcxx=no
47115fi
47116rm -f core conftest.err conftest.$ac_objext \
47117    conftest$ac_exeext conftest.$ac_ext
47118    LIBS="$OLD_LIBS"
47119    CXX="$OLD_CXX"
47120    ac_ext=cpp
47121ac_cpp='$CXXCPP $CPPFLAGS'
47122ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47123ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47124ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47125
47126    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
47127$as_echo "$has_static_libstdcxx" >&6; }
47128
47129    if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
47130      as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
47131    fi
47132
47133    if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
47134      as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
47135    fi
47136
47137    if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
47138      as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
47139    fi
47140
47141    { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
47142$as_echo_n "checking how to link with libstdc++... " >&6; }
47143    # If dynamic was requested, it's available since it would fail above otherwise.
47144    # If dynamic wasn't requested, go with static unless it isn't available.
47145    if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47146      LIBCXX="$LIBCXX -lstdc++"
47147      LDCXX="$CXX"
47148      STATIC_CXX_SETTING="STATIC_CXX=false"
47149      { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
47150$as_echo "dynamic" >&6; }
47151    else
47152      LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
47153      LDCXX="$CC"
47154      STATIC_CXX_SETTING="STATIC_CXX=true"
47155      { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
47156$as_echo "static" >&6; }
47157    fi
47158  fi
47159
47160
47161  if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47162    # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
47163
47164pkg_failed=no
47165{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
47166$as_echo_n "checking for LIBFFI... " >&6; }
47167
47168if test -n "$LIBFFI_CFLAGS"; then
47169    pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
47170 elif test -n "$PKG_CONFIG"; then
47171    if test -n "$PKG_CONFIG" && \
47172    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47173  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47174  ac_status=$?
47175  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47176  test $ac_status = 0; }; then
47177  pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
47178else
47179  pkg_failed=yes
47180fi
47181 else
47182    pkg_failed=untried
47183fi
47184if test -n "$LIBFFI_LIBS"; then
47185    pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
47186 elif test -n "$PKG_CONFIG"; then
47187    if test -n "$PKG_CONFIG" && \
47188    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47189  ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47190  ac_status=$?
47191  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47192  test $ac_status = 0; }; then
47193  pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
47194else
47195  pkg_failed=yes
47196fi
47197 else
47198    pkg_failed=untried
47199fi
47200
47201
47202
47203if test $pkg_failed = yes; then
47204
47205if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47206        _pkg_short_errors_supported=yes
47207else
47208        _pkg_short_errors_supported=no
47209fi
47210        if test $_pkg_short_errors_supported = yes; then
47211	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
47212        else
47213	        LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
47214        fi
47215	# Put the nasty error message in config.log where it belongs
47216	echo "$LIBFFI_PKG_ERRORS" >&5
47217
47218	as_fn_error $? "Package requirements (libffi) were not met:
47219
47220$LIBFFI_PKG_ERRORS
47221
47222Consider adjusting the PKG_CONFIG_PATH environment variable if you
47223installed software in a non-standard prefix.
47224
47225Alternatively, you may set the environment variables LIBFFI_CFLAGS
47226and LIBFFI_LIBS to avoid the need to call pkg-config.
47227See the pkg-config man page for more details.
47228" "$LINENO" 5
47229elif test $pkg_failed = untried; then
47230	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47231$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
47232as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
47233is in your PATH or set the PKG_CONFIG environment variable to the full
47234path to pkg-config.
47235
47236Alternatively, you may set the environment variables LIBFFI_CFLAGS
47237and LIBFFI_LIBS to avoid the need to call pkg-config.
47238See the pkg-config man page for more details.
47239
47240To get pkg-config, see <http://pkg-config.freedesktop.org/>.
47241See \`config.log' for more details" "$LINENO" 5; }
47242else
47243	LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
47244	LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
47245        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47246$as_echo "yes" >&6; }
47247	:
47248fi
47249
47250  fi
47251
47252  if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47253    # Extract the first word of "llvm-config", so it can be a program name with args.
47254set dummy llvm-config; ac_word=$2
47255{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47256$as_echo_n "checking for $ac_word... " >&6; }
47257if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
47258  $as_echo_n "(cached) " >&6
47259else
47260  if test -n "$LLVM_CONFIG"; then
47261  ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
47262else
47263as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47264for as_dir in $PATH
47265do
47266  IFS=$as_save_IFS
47267  test -z "$as_dir" && as_dir=.
47268    for ac_exec_ext in '' $ac_executable_extensions; do
47269  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47270    ac_cv_prog_LLVM_CONFIG="llvm-config"
47271    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47272    break 2
47273  fi
47274done
47275  done
47276IFS=$as_save_IFS
47277
47278fi
47279fi
47280LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
47281if test -n "$LLVM_CONFIG"; then
47282  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
47283$as_echo "$LLVM_CONFIG" >&6; }
47284else
47285  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47286$as_echo "no" >&6; }
47287fi
47288
47289
47290
47291    if test "x$LLVM_CONFIG" != xllvm-config; then
47292      as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
47293    fi
47294
47295    llvm_components="jit mcjit engine nativecodegen native"
47296    unset LLVM_CFLAGS
47297    for flag in $("$LLVM_CONFIG" --cxxflags); do
47298      if echo "${flag}" | grep -q '^-[ID]'; then
47299        if test "${flag}" != "-D_DEBUG" ; then
47300          if test "${LLVM_CFLAGS}" != "" ; then
47301            LLVM_CFLAGS="${LLVM_CFLAGS} "
47302          fi
47303          LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
47304        fi
47305      fi
47306    done
47307    llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
47308    LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
47309
47310    unset LLVM_LDFLAGS
47311    for flag in $("${LLVM_CONFIG}" --ldflags); do
47312      if echo "${flag}" | grep -q '^-L'; then
47313        if test "${LLVM_LDFLAGS}" != ""; then
47314          LLVM_LDFLAGS="${LLVM_LDFLAGS} "
47315        fi
47316        LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
47317      fi
47318    done
47319
47320    unset LLVM_LIBS
47321    for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47322      if echo "${flag}" | grep -q '^-l'; then
47323        if test "${LLVM_LIBS}" != ""; then
47324          LLVM_LIBS="${LLVM_LIBS} "
47325        fi
47326        LLVM_LIBS="${LLVM_LIBS}${flag}"
47327      fi
47328    done
47329
47330
47331
47332
47333  fi
47334
47335  # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47336  if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47337    LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47338  fi
47339
47340  # TODO better (platform agnostic) test
47341  if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47342    LIBCXX="-lstdc++"
47343  fi
47344
47345
47346
47347
47348  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47349
47350
47351# Check whether --with-msvcr-dll was given.
47352if test "${with_msvcr_dll+set}" = set; then :
47353  withval=$with_msvcr_dll;
47354fi
47355
47356
47357  if test "x$with_msvcr_dll" != x; then
47358    # If given explicitely by user, do not probe. If not present, fail directly.
47359
47360  POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
47361  METHOD="--with-msvcr-dll"
47362  if test -e "$POSSIBLE_MSVCR_DLL"; then
47363    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47364$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47365
47366    # Need to check if the found msvcr is correct architecture
47367    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47368$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47369    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47370    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47371      CORRECT_MSVCR_ARCH=386
47372    else
47373      CORRECT_MSVCR_ARCH=x86-64
47374    fi
47375    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47376      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47377$as_echo "ok" >&6; }
47378      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47379      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47380$as_echo_n "checking for msvcr100.dll... " >&6; }
47381      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47382$as_echo "$MSVCR_DLL" >&6; }
47383    else
47384      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47385$as_echo "incorrect, ignoring" >&6; }
47386      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47387$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47388    fi
47389  fi
47390
47391    if test "x$MSVCR_DLL" = x; then
47392      as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
47393    fi
47394  fi
47395
47396  if test "x$MSVCR_DLL" = x; then
47397    # Probe: Using well-known location from Visual Studio 10.0
47398    if test "x$VCINSTALLDIR" != x; then
47399      CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
47400
47401  windows_path="$CYGWIN_VC_INSTALL_DIR"
47402  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47403    unix_path=`$CYGPATH -u "$windows_path"`
47404    CYGWIN_VC_INSTALL_DIR="$unix_path"
47405  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47406    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47407    CYGWIN_VC_INSTALL_DIR="$unix_path"
47408  fi
47409
47410      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47411        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
47412      else
47413        POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
47414      fi
47415
47416  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47417  METHOD="well-known location in VCINSTALLDIR"
47418  if test -e "$POSSIBLE_MSVCR_DLL"; then
47419    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47420$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47421
47422    # Need to check if the found msvcr is correct architecture
47423    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47424$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47425    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47426    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47427      CORRECT_MSVCR_ARCH=386
47428    else
47429      CORRECT_MSVCR_ARCH=x86-64
47430    fi
47431    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47432      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47433$as_echo "ok" >&6; }
47434      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47435      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47436$as_echo_n "checking for msvcr100.dll... " >&6; }
47437      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47438$as_echo "$MSVCR_DLL" >&6; }
47439    else
47440      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47441$as_echo "incorrect, ignoring" >&6; }
47442      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47443$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47444    fi
47445  fi
47446
47447    fi
47448  fi
47449
47450  if test "x$MSVCR_DLL" = x; then
47451    # Probe: Check in the Boot JDK directory.
47452    POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
47453
47454  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47455  METHOD="well-known location in Boot JDK"
47456  if test -e "$POSSIBLE_MSVCR_DLL"; then
47457    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47458$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47459
47460    # Need to check if the found msvcr is correct architecture
47461    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47462$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47463    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47464    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47465      CORRECT_MSVCR_ARCH=386
47466    else
47467      CORRECT_MSVCR_ARCH=x86-64
47468    fi
47469    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47470      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47471$as_echo "ok" >&6; }
47472      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47473      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47474$as_echo_n "checking for msvcr100.dll... " >&6; }
47475      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47476$as_echo "$MSVCR_DLL" >&6; }
47477    else
47478      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47479$as_echo "incorrect, ignoring" >&6; }
47480      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47481$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47482    fi
47483  fi
47484
47485  fi
47486
47487  if test "x$MSVCR_DLL" = x; then
47488    # Probe: Look in the Windows system32 directory
47489    CYGWIN_SYSTEMROOT="$SYSTEMROOT"
47490
47491  windows_path="$CYGWIN_SYSTEMROOT"
47492  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47493    unix_path=`$CYGPATH -u "$windows_path"`
47494    CYGWIN_SYSTEMROOT="$unix_path"
47495  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47496    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47497    CYGWIN_SYSTEMROOT="$unix_path"
47498  fi
47499
47500    POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
47501
47502  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47503  METHOD="well-known location in SYSTEMROOT"
47504  if test -e "$POSSIBLE_MSVCR_DLL"; then
47505    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47506$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47507
47508    # Need to check if the found msvcr is correct architecture
47509    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47510$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47511    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47512    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47513      CORRECT_MSVCR_ARCH=386
47514    else
47515      CORRECT_MSVCR_ARCH=x86-64
47516    fi
47517    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47518      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47519$as_echo "ok" >&6; }
47520      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47521      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47522$as_echo_n "checking for msvcr100.dll... " >&6; }
47523      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47524$as_echo "$MSVCR_DLL" >&6; }
47525    else
47526      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47527$as_echo "incorrect, ignoring" >&6; }
47528      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47529$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47530    fi
47531  fi
47532
47533  fi
47534
47535  if test "x$MSVCR_DLL" = x; then
47536    # Probe: If Visual Studio Express is installed, there is usually one with the debugger
47537    if test "x$VS100COMNTOOLS" != x; then
47538      CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
47539
47540  windows_path="$CYGWIN_VS_TOOLS_DIR"
47541  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47542    unix_path=`$CYGPATH -u "$windows_path"`
47543    CYGWIN_VS_TOOLS_DIR="$unix_path"
47544  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47545    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47546    CYGWIN_VS_TOOLS_DIR="$unix_path"
47547  fi
47548
47549      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47550        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
47551      else
47552        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
47553      fi
47554
47555  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47556  METHOD="search of VS100COMNTOOLS"
47557  if test -e "$POSSIBLE_MSVCR_DLL"; then
47558    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47559$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47560
47561    # Need to check if the found msvcr is correct architecture
47562    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47563$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47564    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47565    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47566      CORRECT_MSVCR_ARCH=386
47567    else
47568      CORRECT_MSVCR_ARCH=x86-64
47569    fi
47570    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47571      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47572$as_echo "ok" >&6; }
47573      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47574      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47575$as_echo_n "checking for msvcr100.dll... " >&6; }
47576      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47577$as_echo "$MSVCR_DLL" >&6; }
47578    else
47579      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47580$as_echo "incorrect, ignoring" >&6; }
47581      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47582$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47583    fi
47584  fi
47585
47586    fi
47587  fi
47588
47589  if test "x$MSVCR_DLL" = x; then
47590    # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
47591    # (This was the original behaviour; kept since it might turn up something)
47592    if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
47593      if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47594        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
47595      else
47596        POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
47597        if test "x$POSSIBLE_MSVCR_DLL" = x; then
47598          # We're grasping at straws now...
47599          POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
47600        fi
47601      fi
47602
47603
47604  POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47605  METHOD="search of VCINSTALLDIR"
47606  if test -e "$POSSIBLE_MSVCR_DLL"; then
47607    { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
47608$as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
47609
47610    # Need to check if the found msvcr is correct architecture
47611    { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
47612$as_echo_n "checking found msvcr100.dll architecture... " >&6; }
47613    MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
47614    if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
47615      CORRECT_MSVCR_ARCH=386
47616    else
47617      CORRECT_MSVCR_ARCH=x86-64
47618    fi
47619    if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
47620      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
47621$as_echo "ok" >&6; }
47622      MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
47623      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47624$as_echo_n "checking for msvcr100.dll... " >&6; }
47625      { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
47626$as_echo "$MSVCR_DLL" >&6; }
47627    else
47628      { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
47629$as_echo "incorrect, ignoring" >&6; }
47630      { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
47631$as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
47632    fi
47633  fi
47634
47635    fi
47636  fi
47637
47638  if test "x$MSVCR_DLL" = x; then
47639    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
47640$as_echo_n "checking for msvcr100.dll... " >&6; }
47641    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47642$as_echo "no" >&6; }
47643    as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
47644  fi
47645
47646
47647  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47648
47649  # Input might be given as Windows format, start by converting to
47650  # unix format.
47651  path="$MSVCR_DLL"
47652  new_path=`$CYGPATH -u "$path"`
47653
47654  # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47655  # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47656  # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47657  # "foo.exe" is OK but "foo" is an error.
47658  #
47659  # This test is therefore slightly more accurate than "test -f" to check for file precense.
47660  # It is also a way to make sure we got the proper file name for the real test later on.
47661  test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47662  if test "x$test_shortpath" = x; then
47663    { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47664$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47665    as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
47666  fi
47667
47668  # Call helper function which possibly converts this using DOS-style short mode.
47669  # If so, the updated path is stored in $new_path.
47670
47671  input_path="$new_path"
47672  # Check if we need to convert this using DOS-style short mode. If the path
47673  # contains just simple characters, use it. Otherwise (spaces, weird characters),
47674  # take no chances and rewrite it.
47675  # Note: m4 eats our [], so we need to use [ and ] instead.
47676  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47677  if test "x$has_forbidden_chars" != x; then
47678    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47679    shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47680    path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47681    if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47682      # Going to short mode and back again did indeed matter. Since short mode is
47683      # case insensitive, let's make it lowercase to improve readability.
47684      shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47685      # Now convert it back to Unix-stile (cygpath)
47686      input_path=`$CYGPATH -u "$shortmode_path"`
47687      new_path="$input_path"
47688    fi
47689  fi
47690
47691  test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47692  if test "x$test_cygdrive_prefix" = x; then
47693    # As a simple fix, exclude /usr/bin since it's not a real path.
47694    if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47695      # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47696      # a path prefixed by /cygdrive for fixpath to work.
47697      new_path="$CYGWIN_ROOT_PATH$input_path"
47698    fi
47699  fi
47700
47701
47702  if test "x$path" != "x$new_path"; then
47703    MSVCR_DLL="$new_path"
47704    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47705$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47706  fi
47707
47708  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47709
47710  path="$MSVCR_DLL"
47711  has_colon=`$ECHO $path | $GREP ^.:`
47712  new_path="$path"
47713  if test "x$has_colon" = x; then
47714    # Not in mixed or Windows style, start by that.
47715    new_path=`cmd //c echo $path`
47716  fi
47717
47718
47719  input_path="$new_path"
47720  # Check if we need to convert this using DOS-style short mode. If the path
47721  # contains just simple characters, use it. Otherwise (spaces, weird characters),
47722  # take no chances and rewrite it.
47723  # Note: m4 eats our [], so we need to use [ and ] instead.
47724  has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47725  if test "x$has_forbidden_chars" != x; then
47726    # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47727    new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47728  fi
47729
47730
47731  windows_path="$new_path"
47732  if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47733    unix_path=`$CYGPATH -u "$windows_path"`
47734    new_path="$unix_path"
47735  elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47736    unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47737    new_path="$unix_path"
47738  fi
47739
47740  if test "x$path" != "x$new_path"; then
47741    MSVCR_DLL="$new_path"
47742    { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
47743$as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
47744  fi
47745
47746  # Save the first 10 bytes of this path to the storage, so fixpath can work.
47747  all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47748
47749  else
47750    # We're on a posix platform. Hooray! :)
47751    path="$MSVCR_DLL"
47752    has_space=`$ECHO "$path" | $GREP " "`
47753    if test "x$has_space" != x; then
47754      { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
47755$as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
47756      as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47757    fi
47758
47759    # Use eval to expand a potential ~
47760    eval path="$path"
47761    if test ! -f "$path" && test ! -d "$path"; then
47762      as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
47763    fi
47764
47765    MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
47766  fi
47767
47768
47769
47770
47771# Check whether --with-dxsdk was given.
47772if test "${with_dxsdk+set}" = set; then :
47773  withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
47774$as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
47775fi
47776
47777
47778
47779
47780# Check whether --with-dxsdk-lib was given.
47781if test "${with_dxsdk_lib+set}" = set; then :
47782  withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
47783$as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
47784fi
47785
47786
47787
47788
47789# Check whether --with-dxsdk-include was given.
47790if test "${with_dxsdk_include+set}" = set; then :
47791  withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
47792$as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
47793fi
47794
47795
47796  fi
47797
47798
47799
47800###############################################################################
47801#
47802# We need to do some final tweaking, when everything else is done.
47803#
47804###############################################################################
47805
47806
47807  HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
47808
47809
47810  # The name of the Service Agent jar.
47811  SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
47812  if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47813    SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
47814  fi
47815
47816
47817
47818    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
47819$as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
47820
47821    if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then
47822      ENABLE_INTREE_EC=yes
47823      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47824$as_echo "yes" >&6; }
47825    else
47826      ENABLE_INTREE_EC=no
47827      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47828$as_echo "no" >&6; }
47829    fi
47830
47831
47832
47833
47834###############################################################################
47835#
47836# Configure parts of the build that only affect the build performance,
47837# not the result.
47838#
47839###############################################################################
47840
47841
47842  # How many cores do we have on this build system?
47843
47844# Check whether --with-num-cores was given.
47845if test "${with_num_cores+set}" = set; then :
47846  withval=$with_num_cores;
47847fi
47848
47849  if test "x$with_num_cores" = x; then
47850    # The number of cores were not specified, try to probe them.
47851
47852  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
47853$as_echo_n "checking for number of cores... " >&6; }
47854  NUM_CORES=1
47855  FOUND_CORES=no
47856
47857  if test -f /proc/cpuinfo; then
47858    # Looks like a Linux (or cygwin) system
47859    NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
47860    FOUND_CORES=yes
47861  elif test -x /usr/sbin/psrinfo; then
47862    # Looks like a Solaris system
47863    NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
47864    FOUND_CORES=yes
47865  elif test -x /usr/sbin/system_profiler; then
47866    # Looks like a MacOSX system
47867    NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
47868    FOUND_CORES=yes
47869  elif test "x$OPENJDK_BUILD_OS" = xaix ; then
47870    NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
47871    FOUND_CORES=yes
47872  elif test -n "$NUMBER_OF_PROCESSORS"; then
47873    # On windows, look in the env
47874    NUM_CORES=$NUMBER_OF_PROCESSORS
47875    FOUND_CORES=yes
47876  fi
47877
47878  if test "x$FOUND_CORES" = xyes; then
47879    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
47880$as_echo "$NUM_CORES" >&6; }
47881  else
47882    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
47883$as_echo "could not detect number of cores, defaulting to 1" >&6; }
47884    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
47885$as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
47886  fi
47887
47888  else
47889    NUM_CORES=$with_num_cores
47890  fi
47891
47892
47893
47894  # How much memory do we have on this build system?
47895
47896# Check whether --with-memory-size was given.
47897if test "${with_memory_size+set}" = set; then :
47898  withval=$with_memory_size;
47899fi
47900
47901  if test "x$with_memory_size" = x; then
47902    # The memory size was not specified, try to probe it.
47903
47904  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
47905$as_echo_n "checking for memory size... " >&6; }
47906  # Default to 1024 MB
47907  MEMORY_SIZE=1024
47908  FOUND_MEM=no
47909
47910  if test -f /proc/meminfo; then
47911    # Looks like a Linux (or cygwin) system
47912    MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
47913    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
47914    FOUND_MEM=yes
47915  elif test -x /usr/sbin/prtconf; then
47916    # Looks like a Solaris or AIX system
47917    MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
47918    FOUND_MEM=yes
47919  elif test -x /usr/sbin/system_profiler; then
47920    # Looks like a MacOSX system
47921    MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
47922    MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
47923    FOUND_MEM=yes
47924  elif test "x$OPENJDK_BUILD_OS" = xwindows; then
47925    # Windows, but without cygwin
47926    MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
47927    MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
47928    FOUND_MEM=yes
47929  fi
47930
47931  if test "x$FOUND_MEM" = xyes; then
47932    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
47933$as_echo "$MEMORY_SIZE MB" >&6; }
47934  else
47935    { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5
47936$as_echo "could not detect memory size, defaulting to 1024 MB" >&6; }
47937    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
47938$as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
47939  fi
47940
47941  else
47942    MEMORY_SIZE=$with_memory_size
47943  fi
47944
47945
47946
47947  # Provide a decent default number of parallel jobs for make depending on
47948  # number of cores, amount of memory and machine architecture.
47949
47950# Check whether --with-jobs was given.
47951if test "${with_jobs+set}" = set; then :
47952  withval=$with_jobs;
47953fi
47954
47955  if test "x$with_jobs" = x; then
47956    # Number of jobs was not specified, calculate.
47957    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
47958$as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
47959    # Approximate memory in GB, rounding up a bit.
47960    memory_gb=`expr $MEMORY_SIZE / 1100`
47961    # Pick the lowest of memory in gb and number of cores.
47962    if test "$memory_gb" -lt "$NUM_CORES"; then
47963      JOBS="$memory_gb"
47964    else
47965      JOBS="$NUM_CORES"
47966      # On bigger machines, leave some room for other processes to run
47967      if test "$JOBS" -gt "4"; then
47968        JOBS=`expr $JOBS '*' 90 / 100`
47969      fi
47970    fi
47971    # Cap number of jobs to 16
47972    if test "$JOBS" -gt "16"; then
47973      JOBS=16
47974    fi
47975    if test "$JOBS" -eq "0"; then
47976      JOBS=1
47977    fi
47978    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
47979$as_echo "$JOBS" >&6; }
47980  else
47981    JOBS=$with_jobs
47982  fi
47983
47984
47985
47986# Setup smart javac (after cores and memory have been setup)
47987
47988
47989# Check whether --with-sjavac-server-java was given.
47990if test "${with_sjavac_server_java+set}" = set; then :
47991  withval=$with_sjavac_server_java;
47992fi
47993
47994
47995  if test "x$with_sjavac_server_java" != x; then
47996    SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
47997    FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
47998    if test "x$FOUND_VERSION" = x; then
47999      as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
48000    fi
48001  else
48002    SJAVAC_SERVER_JAVA=""
48003    # Hotspot specific options.
48004
48005  $ECHO "Check if jvm arg is ok: -verbosegc" >&5
48006  $ECHO "Command: $JAVA -verbosegc -version" >&5
48007  OUTPUT=`$JAVA -verbosegc -version 2>&1`
48008  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48009  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48010  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48011    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc"
48012    JVM_ARG_OK=true
48013  else
48014    $ECHO "Arg failed:" >&5
48015    $ECHO "$OUTPUT" >&5
48016    JVM_ARG_OK=false
48017  fi
48018
48019    # JRockit specific options.
48020
48021  $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5
48022  $ECHO "Command: $JAVA -Xverbose:gc -version" >&5
48023  OUTPUT=`$JAVA -Xverbose:gc -version 2>&1`
48024  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48025  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48026  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48027    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc"
48028    JVM_ARG_OK=true
48029  else
48030    $ECHO "Arg failed:" >&5
48031    $ECHO "$OUTPUT" >&5
48032    JVM_ARG_OK=false
48033  fi
48034
48035    SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA"
48036  fi
48037
48038
48039  if test "$MEMORY_SIZE" -gt "2500"; then
48040
48041  $ECHO "Check if jvm arg is ok: -d64" >&5
48042  $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
48043  OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
48044  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48045  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48046  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48047    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64"
48048    JVM_ARG_OK=true
48049  else
48050    $ECHO "Arg failed:" >&5
48051    $ECHO "$OUTPUT" >&5
48052    JVM_ARG_OK=false
48053  fi
48054
48055    if test "$JVM_ARG_OK" = true; then
48056      JVM_64BIT=true
48057      JVM_ARG_OK=false
48058    fi
48059  fi
48060
48061  if test "$JVM_64BIT" = true; then
48062    if test "$MEMORY_SIZE" -gt "17000"; then
48063
48064  $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5
48065  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5
48066  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1`
48067  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48068  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48069  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48070    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G"
48071    JVM_ARG_OK=true
48072  else
48073    $ECHO "Arg failed:" >&5
48074    $ECHO "$OUTPUT" >&5
48075    JVM_ARG_OK=false
48076  fi
48077
48078    fi
48079    if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then
48080
48081  $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5
48082  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5
48083  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1`
48084  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48085  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48086  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48087    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G"
48088    JVM_ARG_OK=true
48089  else
48090    $ECHO "Arg failed:" >&5
48091    $ECHO "$OUTPUT" >&5
48092    JVM_ARG_OK=false
48093  fi
48094
48095    fi
48096    if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then
48097
48098  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5
48099  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5
48100  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1`
48101  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48102  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48103  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48104    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G"
48105    JVM_ARG_OK=true
48106  else
48107    $ECHO "Arg failed:" >&5
48108    $ECHO "$OUTPUT" >&5
48109    JVM_ARG_OK=false
48110  fi
48111
48112    fi
48113    if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then
48114
48115  $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5
48116  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5
48117  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1`
48118  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48119  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48120  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48121    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M"
48122    JVM_ARG_OK=true
48123  else
48124    $ECHO "Arg failed:" >&5
48125    $ECHO "$OUTPUT" >&5
48126    JVM_ARG_OK=false
48127  fi
48128
48129    fi
48130  fi
48131  if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then
48132
48133  $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5
48134  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5
48135  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1`
48136  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48137  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48138  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48139    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M"
48140    JVM_ARG_OK=true
48141  else
48142    $ECHO "Arg failed:" >&5
48143    $ECHO "$OUTPUT" >&5
48144    JVM_ARG_OK=false
48145  fi
48146
48147  fi
48148  if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then
48149
48150  $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5
48151  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5
48152  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1`
48153  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48154  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48155  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48156    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M"
48157    JVM_ARG_OK=true
48158  else
48159    $ECHO "Arg failed:" >&5
48160    $ECHO "$OUTPUT" >&5
48161    JVM_ARG_OK=false
48162  fi
48163
48164  fi
48165  if test "$JVM_ARG_OK" = false; then
48166
48167  $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5
48168  $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5
48169  OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1`
48170  FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48171  FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48172  if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48173    SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M"
48174    JVM_ARG_OK=true
48175  else
48176    $ECHO "Arg failed:" >&5
48177    $ECHO "$OUTPUT" >&5
48178    JVM_ARG_OK=false
48179  fi
48180
48181  fi
48182
48183  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
48184$as_echo_n "checking whether to use sjavac... " >&6; }
48185  # Check whether --enable-sjavac was given.
48186if test "${enable_sjavac+set}" = set; then :
48187  enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
48188else
48189  ENABLE_SJAVAC='no'
48190fi
48191
48192  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
48193$as_echo "$ENABLE_SJAVAC" >&6; }
48194
48195
48196  if test "x$ENABLE_SJAVAC" = xyes; then
48197    SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
48198  else
48199    SJAVAC_SERVER_DIR=
48200  fi
48201
48202
48203
48204# Can the C/C++ compiler use precompiled headers?
48205
48206
48207  ###############################################################################
48208  #
48209  # Can the C/C++ compiler use precompiled headers?
48210  #
48211  # Check whether --enable-precompiled-headers was given.
48212if test "${enable_precompiled_headers+set}" = set; then :
48213  enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
48214else
48215  ENABLE_PRECOMPH=yes
48216fi
48217
48218
48219  USE_PRECOMPILED_HEADER=1
48220  if test "x$ENABLE_PRECOMPH" = xno; then
48221    USE_PRECOMPILED_HEADER=0
48222  fi
48223
48224  if test "x$ENABLE_PRECOMPH" = xyes; then
48225    # Check that the compiler actually supports precomp headers.
48226    if test "x$TOOLCHAIN_TYPE" = xgcc; then
48227      { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
48228$as_echo_n "checking that precompiled headers work... " >&6; }
48229      echo "int alfa();" > conftest.h
48230      $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
48231      if test ! -f conftest.hpp.gch; then
48232        USE_PRECOMPILED_HEADER=0
48233        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48234$as_echo "no" >&6; }
48235      else
48236        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48237$as_echo "yes" >&6; }
48238      fi
48239      rm -f conftest.h conftest.hpp.gch
48240    fi
48241  fi
48242
48243
48244
48245
48246# Setup use of ccache, if available
48247
48248  # Check whether --enable-ccache was given.
48249if test "${enable_ccache+set}" = set; then :
48250  enableval=$enable_ccache;
48251fi
48252
48253
48254  CCACHE=
48255  { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48256$as_echo_n "checking is ccache enabled... " >&6; }
48257  ENABLE_CCACHE=$enable_ccache
48258  if test "x$enable_ccache" = xyes; then
48259    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48260$as_echo "yes" >&6; }
48261    OLD_PATH="$PATH"
48262    if test "x$TOOLS_DIR" != x; then
48263      PATH=$TOOLS_DIR:$PATH
48264    fi
48265
48266
48267
48268  # Publish this variable in the help.
48269
48270
48271  if test "x$CCACHE" = x; then
48272    # The variable is not set by user, try to locate tool using the code snippet
48273    for ac_prog in ccache
48274do
48275  # Extract the first word of "$ac_prog", so it can be a program name with args.
48276set dummy $ac_prog; ac_word=$2
48277{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48278$as_echo_n "checking for $ac_word... " >&6; }
48279if ${ac_cv_path_CCACHE+:} false; then :
48280  $as_echo_n "(cached) " >&6
48281else
48282  case $CCACHE in
48283  [\\/]* | ?:[\\/]*)
48284  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48285  ;;
48286  *)
48287  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48288for as_dir in $PATH
48289do
48290  IFS=$as_save_IFS
48291  test -z "$as_dir" && as_dir=.
48292    for ac_exec_ext in '' $ac_executable_extensions; do
48293  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48294    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48295    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48296    break 2
48297  fi
48298done
48299  done
48300IFS=$as_save_IFS
48301
48302  ;;
48303esac
48304fi
48305CCACHE=$ac_cv_path_CCACHE
48306if test -n "$CCACHE"; then
48307  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48308$as_echo "$CCACHE" >&6; }
48309else
48310  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48311$as_echo "no" >&6; }
48312fi
48313
48314
48315  test -n "$CCACHE" && break
48316done
48317
48318  else
48319    # The variable is set, but is it from the command line or the environment?
48320
48321    # Try to remove the string !CCACHE! from our list.
48322    try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
48323    if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
48324      # If it failed, the variable was not from the command line. Ignore it,
48325      # but warn the user (except for BASH, which is always set by the calling BASH).
48326      if test "xCCACHE" != xBASH; then
48327        { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
48328$as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
48329      fi
48330      # Try to locate tool using the code snippet
48331      for ac_prog in ccache
48332do
48333  # Extract the first word of "$ac_prog", so it can be a program name with args.
48334set dummy $ac_prog; ac_word=$2
48335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48336$as_echo_n "checking for $ac_word... " >&6; }
48337if ${ac_cv_path_CCACHE+:} false; then :
48338  $as_echo_n "(cached) " >&6
48339else
48340  case $CCACHE in
48341  [\\/]* | ?:[\\/]*)
48342  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48343  ;;
48344  *)
48345  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48346for as_dir in $PATH
48347do
48348  IFS=$as_save_IFS
48349  test -z "$as_dir" && as_dir=.
48350    for ac_exec_ext in '' $ac_executable_extensions; do
48351  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48352    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48353    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48354    break 2
48355  fi
48356done
48357  done
48358IFS=$as_save_IFS
48359
48360  ;;
48361esac
48362fi
48363CCACHE=$ac_cv_path_CCACHE
48364if test -n "$CCACHE"; then
48365  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48366$as_echo "$CCACHE" >&6; }
48367else
48368  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48369$as_echo "no" >&6; }
48370fi
48371
48372
48373  test -n "$CCACHE" && break
48374done
48375
48376    else
48377      # If it succeeded, then it was overridden by the user. We will use it
48378      # for the tool.
48379
48380      # First remove it from the list of overridden variables, so we can test
48381      # for unknown variables in the end.
48382      CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
48383
48384      # Check if the provided tool contains a complete path.
48385      tool_specified="$CCACHE"
48386      tool_basename="${tool_specified##*/}"
48387      if test "x$tool_basename" = "x$tool_specified"; then
48388        # A command without a complete path is provided, search $PATH.
48389        { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
48390$as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
48391        # Extract the first word of "$tool_basename", so it can be a program name with args.
48392set dummy $tool_basename; ac_word=$2
48393{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48394$as_echo_n "checking for $ac_word... " >&6; }
48395if ${ac_cv_path_CCACHE+:} false; then :
48396  $as_echo_n "(cached) " >&6
48397else
48398  case $CCACHE in
48399  [\\/]* | ?:[\\/]*)
48400  ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48401  ;;
48402  *)
48403  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48404for as_dir in $PATH
48405do
48406  IFS=$as_save_IFS
48407  test -z "$as_dir" && as_dir=.
48408    for ac_exec_ext in '' $ac_executable_extensions; do
48409  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48410    ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48411    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48412    break 2
48413  fi
48414done
48415  done
48416IFS=$as_save_IFS
48417
48418  ;;
48419esac
48420fi
48421CCACHE=$ac_cv_path_CCACHE
48422if test -n "$CCACHE"; then
48423  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48424$as_echo "$CCACHE" >&6; }
48425else
48426  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48427$as_echo "no" >&6; }
48428fi
48429
48430
48431        if test "x$CCACHE" = x; then
48432          as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
48433        fi
48434      else
48435        # Otherwise we believe it is a complete path. Use it as it is.
48436        { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
48437$as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
48438        { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
48439$as_echo_n "checking for CCACHE... " >&6; }
48440        if test ! -x "$tool_specified"; then
48441          { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
48442$as_echo "not found" >&6; }
48443          as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
48444        fi
48445        { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
48446$as_echo "$tool_specified" >&6; }
48447      fi
48448    fi
48449  fi
48450
48451
48452
48453  if test "x$CCACHE" = x; then
48454    as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
48455  fi
48456
48457
48458    CCACHE_STATUS="enabled"
48459    PATH="$OLD_PATH"
48460  elif test "x$enable_ccache" = xno; then
48461    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
48462$as_echo "no, explicitly disabled" >&6; }
48463  elif test "x$enable_ccache" = x; then
48464    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48465$as_echo "no" >&6; }
48466  else
48467    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
48468$as_echo "unknown" >&6; }
48469    as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
48470  fi
48471
48472
48473
48474# Check whether --with-ccache-dir was given.
48475if test "${with_ccache_dir+set}" = set; then :
48476  withval=$with_ccache_dir;
48477fi
48478
48479
48480  if test "x$with_ccache_dir" != x; then
48481    # When using a non home ccache directory, assume the use is to share ccache files
48482    # with other users. Thus change the umask.
48483    SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
48484    if test "x$CCACHE" = x; then
48485      { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
48486$as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
48487    fi
48488  fi
48489
48490  if test "x$CCACHE" != x; then
48491
48492  if test "x$CCACHE" != x; then
48493    # Only use ccache if it is 3.1.4 or later, which supports
48494    # precompiled headers.
48495    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
48496$as_echo_n "checking if ccache supports precompiled headers... " >&6; }
48497    HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
48498    if test "x$HAS_GOOD_CCACHE" = x; then
48499      { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
48500$as_echo "no, disabling ccache" >&6; }
48501      CCACHE=
48502      CCACHE_STATUS="disabled"
48503    else
48504      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48505$as_echo "yes" >&6; }
48506      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
48507$as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
48508      PUSHED_FLAGS="$CXXFLAGS"
48509      CXXFLAGS="-fpch-preprocess $CXXFLAGS"
48510      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48511/* end confdefs.h.  */
48512
48513int
48514main ()
48515{
48516
48517  ;
48518  return 0;
48519}
48520_ACEOF
48521if ac_fn_cxx_try_compile "$LINENO"; then :
48522  CC_KNOWS_CCACHE_TRICK=yes
48523else
48524  CC_KNOWS_CCACHE_TRICK=no
48525fi
48526rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
48527      CXXFLAGS="$PUSHED_FLAGS"
48528      if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
48529        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48530$as_echo "yes" >&6; }
48531      else
48532        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
48533$as_echo "no, disabling ccaching of precompiled headers" >&6; }
48534        CCACHE=
48535        CCACHE_STATUS="disabled"
48536      fi
48537    fi
48538  fi
48539
48540  if test "x$CCACHE" != x; then
48541    CCACHE_SLOPPINESS=time_macros
48542    CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
48543    CCACHE_FLAGS=-fpch-preprocess
48544
48545    if test "x$SET_CCACHE_DIR" != x; then
48546      mkdir -p $CCACHE_DIR > /dev/null 2>&1
48547      chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
48548    fi
48549  fi
48550
48551  fi
48552
48553
48554###############################################################################
48555#
48556# And now the finish...
48557#
48558###############################################################################
48559
48560# Check for some common pitfalls
48561
48562  if test x"$OPENJDK_BUILD_OS" = xwindows; then
48563    file_to_test="$SRC_ROOT/LICENSE"
48564    if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
48565      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
48566    fi
48567  fi
48568
48569
48570  # Did user specify any unknown variables?
48571
48572  if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
48573    # Replace the separating ! with spaces before presenting for end user.
48574    unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
48575    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
48576$as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
48577  fi
48578
48579
48580  { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
48581$as_echo_n "checking if build directory is on local disk... " >&6; }
48582
48583  # df -l lists only local disks; if the given directory is not found then
48584  # a non-zero exit code is given
48585  if test "x$DF" = x; then
48586    if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48587      # msys does not have df; use Windows "net use" instead.
48588      IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
48589      if test "x$IS_NETWORK_DISK" = x; then
48590        OUTPUT_DIR_IS_LOCAL="yes"
48591      else
48592        OUTPUT_DIR_IS_LOCAL="no"
48593      fi
48594    else
48595      # No df here, say it's local
48596      OUTPUT_DIR_IS_LOCAL="yes"
48597    fi
48598  else
48599    if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
48600      OUTPUT_DIR_IS_LOCAL="yes"
48601    else
48602      OUTPUT_DIR_IS_LOCAL="no"
48603    fi
48604  fi
48605
48606  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
48607$as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
48608
48609
48610
48611  # Check if the user has any old-style ALT_ variables set.
48612  FOUND_ALT_VARIABLES=`env | grep ^ALT_`
48613
48614  # Before generating output files, test if they exist. If they do, this is a reconfigure.
48615  # Since we can't properly handle the dependencies for this, warn the user about the situation
48616  if test -e $OUTPUT_ROOT/spec.gmk; then
48617    IS_RECONFIGURE=yes
48618  else
48619    IS_RECONFIGURE=no
48620  fi
48621
48622
48623# At the end, call the custom hook. (Dummy macro if no custom sources available)
48624
48625
48626# We're messing a bit with internal autoconf variables to put the config.status
48627# in the output directory instead of the current directory.
48628CONFIG_STATUS="$OUTPUT_ROOT/config.status"
48629
48630# Create the actual output files. Now the main work of configure is done.
48631cat >confcache <<\_ACEOF
48632# This file is a shell script that caches the results of configure
48633# tests run on this system so they can be shared between configure
48634# scripts and configure runs, see configure's option --config-cache.
48635# It is not useful on other systems.  If it contains results you don't
48636# want to keep, you may remove or edit it.
48637#
48638# config.status only pays attention to the cache file if you give it
48639# the --recheck option to rerun configure.
48640#
48641# `ac_cv_env_foo' variables (set or unset) will be overridden when
48642# loading this file, other *unset* `ac_cv_foo' will be assigned the
48643# following values.
48644
48645_ACEOF
48646
48647# The following way of writing the cache mishandles newlines in values,
48648# but we know of no workaround that is simple, portable, and efficient.
48649# So, we kill variables containing newlines.
48650# Ultrix sh set writes to stderr and can't be redirected directly,
48651# and sets the high bit in the cache file unless we assign to the vars.
48652(
48653  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
48654    eval ac_val=\$$ac_var
48655    case $ac_val in #(
48656    *${as_nl}*)
48657      case $ac_var in #(
48658      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
48659$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
48660      esac
48661      case $ac_var in #(
48662      _ | IFS | as_nl) ;; #(
48663      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
48664      *) { eval $ac_var=; unset $ac_var;} ;;
48665      esac ;;
48666    esac
48667  done
48668
48669  (set) 2>&1 |
48670    case $as_nl`(ac_space=' '; set) 2>&1` in #(
48671    *${as_nl}ac_space=\ *)
48672      # `set' does not quote correctly, so add quotes: double-quote
48673      # substitution turns \\\\ into \\, and sed turns \\ into \.
48674      sed -n \
48675	"s/'/'\\\\''/g;
48676	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
48677      ;; #(
48678    *)
48679      # `set' quotes correctly as required by POSIX, so do not add quotes.
48680      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
48681      ;;
48682    esac |
48683    sort
48684) |
48685  sed '
48686     /^ac_cv_env_/b end
48687     t clear
48688     :clear
48689     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
48690     t end
48691     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
48692     :end' >>confcache
48693if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
48694  if test -w "$cache_file"; then
48695    if test "x$cache_file" != "x/dev/null"; then
48696      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
48697$as_echo "$as_me: updating cache $cache_file" >&6;}
48698      if test ! -f "$cache_file" || test -h "$cache_file"; then
48699	cat confcache >"$cache_file"
48700      else
48701        case $cache_file in #(
48702        */* | ?:*)
48703	  mv -f confcache "$cache_file"$$ &&
48704	  mv -f "$cache_file"$$ "$cache_file" ;; #(
48705        *)
48706	  mv -f confcache "$cache_file" ;;
48707	esac
48708      fi
48709    fi
48710  else
48711    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
48712$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
48713  fi
48714fi
48715rm -f confcache
48716
48717test "x$prefix" = xNONE && prefix=$ac_default_prefix
48718# Let make expand exec_prefix.
48719test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
48720
48721DEFS=-DHAVE_CONFIG_H
48722
48723ac_libobjs=
48724ac_ltlibobjs=
48725U=
48726for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
48727  # 1. Remove the extension, and $U if already installed.
48728  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
48729  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
48730  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
48731  #    will be set to the directory where LIBOBJS objects are built.
48732  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
48733  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
48734done
48735LIBOBJS=$ac_libobjs
48736
48737LTLIBOBJS=$ac_ltlibobjs
48738
48739
48740
48741: "${CONFIG_STATUS=./config.status}"
48742ac_write_fail=0
48743ac_clean_files_save=$ac_clean_files
48744ac_clean_files="$ac_clean_files $CONFIG_STATUS"
48745{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
48746$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
48747as_write_fail=0
48748cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
48749#! $SHELL
48750# Generated by $as_me.
48751# Run this file to recreate the current configuration.
48752# Compiler output produced by configure, useful for debugging
48753# configure, is in config.log if it exists.
48754
48755debug=false
48756ac_cs_recheck=false
48757ac_cs_silent=false
48758
48759SHELL=\${CONFIG_SHELL-$SHELL}
48760export SHELL
48761_ASEOF
48762cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
48763## -------------------- ##
48764## M4sh Initialization. ##
48765## -------------------- ##
48766
48767# Be more Bourne compatible
48768DUALCASE=1; export DUALCASE # for MKS sh
48769if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
48770  emulate sh
48771  NULLCMD=:
48772  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
48773  # is contrary to our usage.  Disable this feature.
48774  alias -g '${1+"$@"}'='"$@"'
48775  setopt NO_GLOB_SUBST
48776else
48777  case `(set -o) 2>/dev/null` in #(
48778  *posix*) :
48779    set -o posix ;; #(
48780  *) :
48781     ;;
48782esac
48783fi
48784
48785
48786as_nl='
48787'
48788export as_nl
48789# Printing a long string crashes Solaris 7 /usr/bin/printf.
48790as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
48791as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
48792as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
48793# Prefer a ksh shell builtin over an external printf program on Solaris,
48794# but without wasting forks for bash or zsh.
48795if test -z "$BASH_VERSION$ZSH_VERSION" \
48796    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
48797  as_echo='print -r --'
48798  as_echo_n='print -rn --'
48799elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48800  as_echo='printf %s\n'
48801  as_echo_n='printf %s'
48802else
48803  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
48804    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
48805    as_echo_n='/usr/ucb/echo -n'
48806  else
48807    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
48808    as_echo_n_body='eval
48809      arg=$1;
48810      case $arg in #(
48811      *"$as_nl"*)
48812	expr "X$arg" : "X\\(.*\\)$as_nl";
48813	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
48814      esac;
48815      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
48816    '
48817    export as_echo_n_body
48818    as_echo_n='sh -c $as_echo_n_body as_echo'
48819  fi
48820  export as_echo_body
48821  as_echo='sh -c $as_echo_body as_echo'
48822fi
48823
48824# The user is always right.
48825if test "${PATH_SEPARATOR+set}" != set; then
48826  PATH_SEPARATOR=:
48827  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
48828    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
48829      PATH_SEPARATOR=';'
48830  }
48831fi
48832
48833
48834# IFS
48835# We need space, tab and new line, in precisely that order.  Quoting is
48836# there to prevent editors from complaining about space-tab.
48837# (If _AS_PATH_WALK were called with IFS unset, it would disable word
48838# splitting by setting IFS to empty value.)
48839IFS=" ""	$as_nl"
48840
48841# Find who we are.  Look in the path if we contain no directory separator.
48842as_myself=
48843case $0 in #((
48844  *[\\/]* ) as_myself=$0 ;;
48845  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48846for as_dir in $PATH
48847do
48848  IFS=$as_save_IFS
48849  test -z "$as_dir" && as_dir=.
48850    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
48851  done
48852IFS=$as_save_IFS
48853
48854     ;;
48855esac
48856# We did not find ourselves, most probably we were run as `sh COMMAND'
48857# in which case we are not to be found in the path.
48858if test "x$as_myself" = x; then
48859  as_myself=$0
48860fi
48861if test ! -f "$as_myself"; then
48862  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
48863  exit 1
48864fi
48865
48866# Unset variables that we do not need and which cause bugs (e.g. in
48867# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
48868# suppresses any "Segmentation fault" message there.  '((' could
48869# trigger a bug in pdksh 5.2.14.
48870for as_var in BASH_ENV ENV MAIL MAILPATH
48871do eval test x\${$as_var+set} = xset \
48872  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
48873done
48874PS1='$ '
48875PS2='> '
48876PS4='+ '
48877
48878# NLS nuisances.
48879LC_ALL=C
48880export LC_ALL
48881LANGUAGE=C
48882export LANGUAGE
48883
48884# CDPATH.
48885(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
48886
48887
48888# as_fn_error STATUS ERROR [LINENO LOG_FD]
48889# ----------------------------------------
48890# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
48891# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
48892# script with STATUS, using 1 if that was 0.
48893as_fn_error ()
48894{
48895  as_status=$1; test $as_status -eq 0 && as_status=1
48896  if test "$4"; then
48897    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
48898    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
48899  fi
48900  $as_echo "$as_me: error: $2" >&2
48901  as_fn_exit $as_status
48902} # as_fn_error
48903
48904
48905# as_fn_set_status STATUS
48906# -----------------------
48907# Set $? to STATUS, without forking.
48908as_fn_set_status ()
48909{
48910  return $1
48911} # as_fn_set_status
48912
48913# as_fn_exit STATUS
48914# -----------------
48915# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
48916as_fn_exit ()
48917{
48918  set +e
48919  as_fn_set_status $1
48920  exit $1
48921} # as_fn_exit
48922
48923# as_fn_unset VAR
48924# ---------------
48925# Portably unset VAR.
48926as_fn_unset ()
48927{
48928  { eval $1=; unset $1;}
48929}
48930as_unset=as_fn_unset
48931# as_fn_append VAR VALUE
48932# ----------------------
48933# Append the text in VALUE to the end of the definition contained in VAR. Take
48934# advantage of any shell optimizations that allow amortized linear growth over
48935# repeated appends, instead of the typical quadratic growth present in naive
48936# implementations.
48937if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
48938  eval 'as_fn_append ()
48939  {
48940    eval $1+=\$2
48941  }'
48942else
48943  as_fn_append ()
48944  {
48945    eval $1=\$$1\$2
48946  }
48947fi # as_fn_append
48948
48949# as_fn_arith ARG...
48950# ------------------
48951# Perform arithmetic evaluation on the ARGs, and store the result in the
48952# global $as_val. Take advantage of shells that can avoid forks. The arguments
48953# must be portable across $(()) and expr.
48954if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
48955  eval 'as_fn_arith ()
48956  {
48957    as_val=$(( $* ))
48958  }'
48959else
48960  as_fn_arith ()
48961  {
48962    as_val=`expr "$@" || test $? -eq 1`
48963  }
48964fi # as_fn_arith
48965
48966
48967if expr a : '\(a\)' >/dev/null 2>&1 &&
48968   test "X`expr 00001 : '.*\(...\)'`" = X001; then
48969  as_expr=expr
48970else
48971  as_expr=false
48972fi
48973
48974if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
48975  as_basename=basename
48976else
48977  as_basename=false
48978fi
48979
48980if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
48981  as_dirname=dirname
48982else
48983  as_dirname=false
48984fi
48985
48986as_me=`$as_basename -- "$0" ||
48987$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
48988	 X"$0" : 'X\(//\)$' \| \
48989	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
48990$as_echo X/"$0" |
48991    sed '/^.*\/\([^/][^/]*\)\/*$/{
48992	    s//\1/
48993	    q
48994	  }
48995	  /^X\/\(\/\/\)$/{
48996	    s//\1/
48997	    q
48998	  }
48999	  /^X\/\(\/\).*/{
49000	    s//\1/
49001	    q
49002	  }
49003	  s/.*/./; q'`
49004
49005# Avoid depending upon Character Ranges.
49006as_cr_letters='abcdefghijklmnopqrstuvwxyz'
49007as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
49008as_cr_Letters=$as_cr_letters$as_cr_LETTERS
49009as_cr_digits='0123456789'
49010as_cr_alnum=$as_cr_Letters$as_cr_digits
49011
49012ECHO_C= ECHO_N= ECHO_T=
49013case `echo -n x` in #(((((
49014-n*)
49015  case `echo 'xy\c'` in
49016  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
49017  xy)  ECHO_C='\c';;
49018  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
49019       ECHO_T='	';;
49020  esac;;
49021*)
49022  ECHO_N='-n';;
49023esac
49024
49025rm -f conf$$ conf$$.exe conf$$.file
49026if test -d conf$$.dir; then
49027  rm -f conf$$.dir/conf$$.file
49028else
49029  rm -f conf$$.dir
49030  mkdir conf$$.dir 2>/dev/null
49031fi
49032if (echo >conf$$.file) 2>/dev/null; then
49033  if ln -s conf$$.file conf$$ 2>/dev/null; then
49034    as_ln_s='ln -s'
49035    # ... but there are two gotchas:
49036    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
49037    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
49038    # In both cases, we have to default to `cp -pR'.
49039    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
49040      as_ln_s='cp -pR'
49041  elif ln conf$$.file conf$$ 2>/dev/null; then
49042    as_ln_s=ln
49043  else
49044    as_ln_s='cp -pR'
49045  fi
49046else
49047  as_ln_s='cp -pR'
49048fi
49049rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
49050rmdir conf$$.dir 2>/dev/null
49051
49052
49053# as_fn_mkdir_p
49054# -------------
49055# Create "$as_dir" as a directory, including parents if necessary.
49056as_fn_mkdir_p ()
49057{
49058
49059  case $as_dir in #(
49060  -*) as_dir=./$as_dir;;
49061  esac
49062  test -d "$as_dir" || eval $as_mkdir_p || {
49063    as_dirs=
49064    while :; do
49065      case $as_dir in #(
49066      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
49067      *) as_qdir=$as_dir;;
49068      esac
49069      as_dirs="'$as_qdir' $as_dirs"
49070      as_dir=`$as_dirname -- "$as_dir" ||
49071$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49072	 X"$as_dir" : 'X\(//\)[^/]' \| \
49073	 X"$as_dir" : 'X\(//\)$' \| \
49074	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
49075$as_echo X"$as_dir" |
49076    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49077	    s//\1/
49078	    q
49079	  }
49080	  /^X\(\/\/\)[^/].*/{
49081	    s//\1/
49082	    q
49083	  }
49084	  /^X\(\/\/\)$/{
49085	    s//\1/
49086	    q
49087	  }
49088	  /^X\(\/\).*/{
49089	    s//\1/
49090	    q
49091	  }
49092	  s/.*/./; q'`
49093      test -d "$as_dir" && break
49094    done
49095    test -z "$as_dirs" || eval "mkdir $as_dirs"
49096  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
49097
49098
49099} # as_fn_mkdir_p
49100if mkdir -p . 2>/dev/null; then
49101  as_mkdir_p='mkdir -p "$as_dir"'
49102else
49103  test -d ./-p && rmdir ./-p
49104  as_mkdir_p=false
49105fi
49106
49107
49108# as_fn_executable_p FILE
49109# -----------------------
49110# Test if FILE is an executable regular file.
49111as_fn_executable_p ()
49112{
49113  test -f "$1" && test -x "$1"
49114} # as_fn_executable_p
49115as_test_x='test -x'
49116as_executable_p=as_fn_executable_p
49117
49118# Sed expression to map a string onto a valid CPP name.
49119as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
49120
49121# Sed expression to map a string onto a valid variable name.
49122as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
49123
49124
49125exec 6>&1
49126## ----------------------------------- ##
49127## Main body of $CONFIG_STATUS script. ##
49128## ----------------------------------- ##
49129_ASEOF
49130test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
49131
49132cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49133# Save the log message, to keep $0 and so on meaningful, and to
49134# report actual input values of CONFIG_FILES etc. instead of their
49135# values after options handling.
49136ac_log="
49137This file was extended by OpenJDK $as_me jdk8, which was
49138generated by GNU Autoconf 2.69.  Invocation command line was
49139
49140  CONFIG_FILES    = $CONFIG_FILES
49141  CONFIG_HEADERS  = $CONFIG_HEADERS
49142  CONFIG_LINKS    = $CONFIG_LINKS
49143  CONFIG_COMMANDS = $CONFIG_COMMANDS
49144  $ $0 $@
49145
49146on `(hostname || uname -n) 2>/dev/null | sed 1q`
49147"
49148
49149_ACEOF
49150
49151case $ac_config_files in *"
49152"*) set x $ac_config_files; shift; ac_config_files=$*;;
49153esac
49154
49155case $ac_config_headers in *"
49156"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
49157esac
49158
49159
49160cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49161# Files that config.status was made for.
49162config_files="$ac_config_files"
49163config_headers="$ac_config_headers"
49164
49165_ACEOF
49166
49167cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49168ac_cs_usage="\
49169\`$as_me' instantiates files and other configuration actions
49170from templates according to the current configuration.  Unless the files
49171and actions are specified as TAGs, all are instantiated by default.
49172
49173Usage: $0 [OPTION]... [TAG]...
49174
49175  -h, --help       print this help, then exit
49176  -V, --version    print version number and configuration settings, then exit
49177      --config     print configuration, then exit
49178  -q, --quiet, --silent
49179                   do not print progress messages
49180  -d, --debug      don't remove temporary files
49181      --recheck    update $as_me by reconfiguring in the same conditions
49182      --file=FILE[:TEMPLATE]
49183                   instantiate the configuration file FILE
49184      --header=FILE[:TEMPLATE]
49185                   instantiate the configuration header FILE
49186
49187Configuration files:
49188$config_files
49189
49190Configuration headers:
49191$config_headers
49192
49193Report bugs to <build-dev@openjdk.java.net>.
49194OpenJDK home page: <http://openjdk.java.net>."
49195
49196_ACEOF
49197cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49198ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
49199ac_cs_version="\\
49200OpenJDK config.status jdk8
49201configured by $0, generated by GNU Autoconf 2.69,
49202  with options \\"\$ac_cs_config\\"
49203
49204Copyright (C) 2012 Free Software Foundation, Inc.
49205This config.status script is free software; the Free Software Foundation
49206gives unlimited permission to copy, distribute and modify it."
49207
49208ac_pwd='$ac_pwd'
49209srcdir='$srcdir'
49210AWK='$AWK'
49211test -n "\$AWK" || AWK=awk
49212_ACEOF
49213
49214cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49215# The default lists apply if the user does not specify any file.
49216ac_need_defaults=:
49217while test $# != 0
49218do
49219  case $1 in
49220  --*=?*)
49221    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49222    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
49223    ac_shift=:
49224    ;;
49225  --*=)
49226    ac_option=`expr "X$1" : 'X\([^=]*\)='`
49227    ac_optarg=
49228    ac_shift=:
49229    ;;
49230  *)
49231    ac_option=$1
49232    ac_optarg=$2
49233    ac_shift=shift
49234    ;;
49235  esac
49236
49237  case $ac_option in
49238  # Handling of the options.
49239  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
49240    ac_cs_recheck=: ;;
49241  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
49242    $as_echo "$ac_cs_version"; exit ;;
49243  --config | --confi | --conf | --con | --co | --c )
49244    $as_echo "$ac_cs_config"; exit ;;
49245  --debug | --debu | --deb | --de | --d | -d )
49246    debug=: ;;
49247  --file | --fil | --fi | --f )
49248    $ac_shift
49249    case $ac_optarg in
49250    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49251    '') as_fn_error $? "missing file argument" ;;
49252    esac
49253    as_fn_append CONFIG_FILES " '$ac_optarg'"
49254    ac_need_defaults=false;;
49255  --header | --heade | --head | --hea )
49256    $ac_shift
49257    case $ac_optarg in
49258    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49259    esac
49260    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
49261    ac_need_defaults=false;;
49262  --he | --h)
49263    # Conflict between --help and --header
49264    as_fn_error $? "ambiguous option: \`$1'
49265Try \`$0 --help' for more information.";;
49266  --help | --hel | -h )
49267    $as_echo "$ac_cs_usage"; exit ;;
49268  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
49269  | -silent | --silent | --silen | --sile | --sil | --si | --s)
49270    ac_cs_silent=: ;;
49271
49272  # This is an error.
49273  -*) as_fn_error $? "unrecognized option: \`$1'
49274Try \`$0 --help' for more information." ;;
49275
49276  *) as_fn_append ac_config_targets " $1"
49277     ac_need_defaults=false ;;
49278
49279  esac
49280  shift
49281done
49282
49283ac_configure_extra_args=
49284
49285if $ac_cs_silent; then
49286  exec 6>/dev/null
49287  ac_configure_extra_args="$ac_configure_extra_args --silent"
49288fi
49289
49290_ACEOF
49291cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49292if \$ac_cs_recheck; then
49293  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
49294  shift
49295  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
49296  CONFIG_SHELL='$SHELL'
49297  export CONFIG_SHELL
49298  exec "\$@"
49299fi
49300
49301_ACEOF
49302cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49303exec 5>>config.log
49304{
49305  echo
49306  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
49307## Running $as_me. ##
49308_ASBOX
49309  $as_echo "$ac_log"
49310} >&5
49311
49312_ACEOF
49313cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49314_ACEOF
49315
49316cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49317
49318# Handling of arguments.
49319for ac_config_target in $ac_config_targets
49320do
49321  case $ac_config_target in
49322    "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;;
49323    "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
49324    "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
49325    "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
49326    "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
49327    "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;;
49328    "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
49329
49330  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
49331  esac
49332done
49333
49334
49335# If the user did not use the arguments to specify the items to instantiate,
49336# then the envvar interface is used.  Set only those that are not.
49337# We use the long form for the default assignment because of an extremely
49338# bizarre bug on SunOS 4.1.3.
49339if $ac_need_defaults; then
49340  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
49341  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
49342fi
49343
49344# Have a temporary directory for convenience.  Make it in the build tree
49345# simply because there is no reason against having it here, and in addition,
49346# creating and moving files from /tmp can sometimes cause problems.
49347# Hook for its removal unless debugging.
49348# Note that there is a small window in which the directory will not be cleaned:
49349# after its creation but before its name has been assigned to `$tmp'.
49350$debug ||
49351{
49352  tmp= ac_tmp=
49353  trap 'exit_status=$?
49354  : "${ac_tmp:=$tmp}"
49355  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
49356' 0
49357  trap 'as_fn_exit 1' 1 2 13 15
49358}
49359# Create a (secure) tmp directory for tmp files.
49360
49361{
49362  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
49363  test -d "$tmp"
49364}  ||
49365{
49366  tmp=./conf$$-$RANDOM
49367  (umask 077 && mkdir "$tmp")
49368} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
49369ac_tmp=$tmp
49370
49371# Set up the scripts for CONFIG_FILES section.
49372# No need to generate them if there are no CONFIG_FILES.
49373# This happens for instance with `./config.status config.h'.
49374if test -n "$CONFIG_FILES"; then
49375
49376
49377ac_cr=`echo X | tr X '\015'`
49378# On cygwin, bash can eat \r inside `` if the user requested igncr.
49379# But we know of no other shell where ac_cr would be empty at this
49380# point, so we can use a bashism as a fallback.
49381if test "x$ac_cr" = x; then
49382  eval ac_cr=\$\'\\r\'
49383fi
49384ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
49385if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
49386  ac_cs_awk_cr='\\r'
49387else
49388  ac_cs_awk_cr=$ac_cr
49389fi
49390
49391echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
49392_ACEOF
49393
49394
49395{
49396  echo "cat >conf$$subs.awk <<_ACEOF" &&
49397  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
49398  echo "_ACEOF"
49399} >conf$$subs.sh ||
49400  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49401ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
49402ac_delim='%!_!# '
49403for ac_last_try in false false false false false :; do
49404  . ./conf$$subs.sh ||
49405    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49406
49407  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
49408  if test $ac_delim_n = $ac_delim_num; then
49409    break
49410  elif $ac_last_try; then
49411    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49412  else
49413    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49414  fi
49415done
49416rm -f conf$$subs.sh
49417
49418cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49419cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
49420_ACEOF
49421sed -n '
49422h
49423s/^/S["/; s/!.*/"]=/
49424p
49425g
49426s/^[^!]*!//
49427:repl
49428t repl
49429s/'"$ac_delim"'$//
49430t delim
49431:nl
49432h
49433s/\(.\{148\}\)..*/\1/
49434t more1
49435s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
49436p
49437n
49438b repl
49439:more1
49440s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49441p
49442g
49443s/.\{148\}//
49444t nl
49445:delim
49446h
49447s/\(.\{148\}\)..*/\1/
49448t more2
49449s/["\\]/\\&/g; s/^/"/; s/$/"/
49450p
49451b
49452:more2
49453s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49454p
49455g
49456s/.\{148\}//
49457t delim
49458' <conf$$subs.awk | sed '
49459/^[^""]/{
49460  N
49461  s/\n//
49462}
49463' >>$CONFIG_STATUS || ac_write_fail=1
49464rm -f conf$$subs.awk
49465cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49466_ACAWK
49467cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
49468  for (key in S) S_is_set[key] = 1
49469  FS = ""
49470
49471}
49472{
49473  line = $ 0
49474  nfields = split(line, field, "@")
49475  substed = 0
49476  len = length(field[1])
49477  for (i = 2; i < nfields; i++) {
49478    key = field[i]
49479    keylen = length(key)
49480    if (S_is_set[key]) {
49481      value = S[key]
49482      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
49483      len += length(value) + length(field[++i])
49484      substed = 1
49485    } else
49486      len += 1 + keylen
49487  }
49488
49489  print line
49490}
49491
49492_ACAWK
49493_ACEOF
49494cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49495if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
49496  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
49497else
49498  cat
49499fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
49500  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
49501_ACEOF
49502
49503# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
49504# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
49505# trailing colons and then remove the whole line if VPATH becomes empty
49506# (actually we leave an empty line to preserve line numbers).
49507if test "x$srcdir" = x.; then
49508  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
49509h
49510s///
49511s/^/:/
49512s/[	 ]*$/:/
49513s/:\$(srcdir):/:/g
49514s/:\${srcdir}:/:/g
49515s/:@srcdir@:/:/g
49516s/^:*//
49517s/:*$//
49518x
49519s/\(=[	 ]*\).*/\1/
49520G
49521s/\n//
49522s/^[^=]*=[	 ]*$//
49523}'
49524fi
49525
49526cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49527fi # test -n "$CONFIG_FILES"
49528
49529# Set up the scripts for CONFIG_HEADERS section.
49530# No need to generate them if there are no CONFIG_HEADERS.
49531# This happens for instance with `./config.status Makefile'.
49532if test -n "$CONFIG_HEADERS"; then
49533cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
49534BEGIN {
49535_ACEOF
49536
49537# Transform confdefs.h into an awk script `defines.awk', embedded as
49538# here-document in config.status, that substitutes the proper values into
49539# config.h.in to produce config.h.
49540
49541# Create a delimiter string that does not exist in confdefs.h, to ease
49542# handling of long lines.
49543ac_delim='%!_!# '
49544for ac_last_try in false false :; do
49545  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
49546  if test -z "$ac_tt"; then
49547    break
49548  elif $ac_last_try; then
49549    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
49550  else
49551    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49552  fi
49553done
49554
49555# For the awk script, D is an array of macro values keyed by name,
49556# likewise P contains macro parameters if any.  Preserve backslash
49557# newline sequences.
49558
49559ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
49560sed -n '
49561s/.\{148\}/&'"$ac_delim"'/g
49562t rset
49563:rset
49564s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
49565t def
49566d
49567:def
49568s/\\$//
49569t bsnl
49570s/["\\]/\\&/g
49571s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
49572D["\1"]=" \3"/p
49573s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
49574d
49575:bsnl
49576s/["\\]/\\&/g
49577s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
49578D["\1"]=" \3\\\\\\n"\\/p
49579t cont
49580s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
49581t cont
49582d
49583:cont
49584n
49585s/.\{148\}/&'"$ac_delim"'/g
49586t clear
49587:clear
49588s/\\$//
49589t bsnlc
49590s/["\\]/\\&/g; s/^/"/; s/$/"/p
49591d
49592:bsnlc
49593s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
49594b cont
49595' <confdefs.h | sed '
49596s/'"$ac_delim"'/"\\\
49597"/g' >>$CONFIG_STATUS || ac_write_fail=1
49598
49599cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49600  for (key in D) D_is_set[key] = 1
49601  FS = ""
49602}
49603/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
49604  line = \$ 0
49605  split(line, arg, " ")
49606  if (arg[1] == "#") {
49607    defundef = arg[2]
49608    mac1 = arg[3]
49609  } else {
49610    defundef = substr(arg[1], 2)
49611    mac1 = arg[2]
49612  }
49613  split(mac1, mac2, "(") #)
49614  macro = mac2[1]
49615  prefix = substr(line, 1, index(line, defundef) - 1)
49616  if (D_is_set[macro]) {
49617    # Preserve the white space surrounding the "#".
49618    print prefix "define", macro P[macro] D[macro]
49619    next
49620  } else {
49621    # Replace #undef with comments.  This is necessary, for example,
49622    # in the case of _POSIX_SOURCE, which is predefined and required
49623    # on some systems where configure will not decide to define it.
49624    if (defundef == "undef") {
49625      print "/*", prefix defundef, macro, "*/"
49626      next
49627    }
49628  }
49629}
49630{ print }
49631_ACAWK
49632_ACEOF
49633cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49634  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
49635fi # test -n "$CONFIG_HEADERS"
49636
49637
49638eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
49639shift
49640for ac_tag
49641do
49642  case $ac_tag in
49643  :[FHLC]) ac_mode=$ac_tag; continue;;
49644  esac
49645  case $ac_mode$ac_tag in
49646  :[FHL]*:*);;
49647  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
49648  :[FH]-) ac_tag=-:-;;
49649  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
49650  esac
49651  ac_save_IFS=$IFS
49652  IFS=:
49653  set x $ac_tag
49654  IFS=$ac_save_IFS
49655  shift
49656  ac_file=$1
49657  shift
49658
49659  case $ac_mode in
49660  :L) ac_source=$1;;
49661  :[FH])
49662    ac_file_inputs=
49663    for ac_f
49664    do
49665      case $ac_f in
49666      -) ac_f="$ac_tmp/stdin";;
49667      *) # Look for the file first in the build tree, then in the source tree
49668	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
49669	 # because $ac_f cannot contain `:'.
49670	 test -f "$ac_f" ||
49671	   case $ac_f in
49672	   [\\/$]*) false;;
49673	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
49674	   esac ||
49675	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
49676      esac
49677      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
49678      as_fn_append ac_file_inputs " '$ac_f'"
49679    done
49680
49681    # Let's still pretend it is `configure' which instantiates (i.e., don't
49682    # use $as_me), people would be surprised to read:
49683    #    /* config.h.  Generated by config.status.  */
49684    configure_input='Generated from '`
49685	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
49686	`' by configure.'
49687    if test x"$ac_file" != x-; then
49688      configure_input="$ac_file.  $configure_input"
49689      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
49690$as_echo "$as_me: creating $ac_file" >&6;}
49691    fi
49692    # Neutralize special characters interpreted by sed in replacement strings.
49693    case $configure_input in #(
49694    *\&* | *\|* | *\\* )
49695       ac_sed_conf_input=`$as_echo "$configure_input" |
49696       sed 's/[\\\\&|]/\\\\&/g'`;; #(
49697    *) ac_sed_conf_input=$configure_input;;
49698    esac
49699
49700    case $ac_tag in
49701    *:-:* | *:-) cat >"$ac_tmp/stdin" \
49702      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
49703    esac
49704    ;;
49705  esac
49706
49707  ac_dir=`$as_dirname -- "$ac_file" ||
49708$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49709	 X"$ac_file" : 'X\(//\)[^/]' \| \
49710	 X"$ac_file" : 'X\(//\)$' \| \
49711	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
49712$as_echo X"$ac_file" |
49713    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49714	    s//\1/
49715	    q
49716	  }
49717	  /^X\(\/\/\)[^/].*/{
49718	    s//\1/
49719	    q
49720	  }
49721	  /^X\(\/\/\)$/{
49722	    s//\1/
49723	    q
49724	  }
49725	  /^X\(\/\).*/{
49726	    s//\1/
49727	    q
49728	  }
49729	  s/.*/./; q'`
49730  as_dir="$ac_dir"; as_fn_mkdir_p
49731  ac_builddir=.
49732
49733case "$ac_dir" in
49734.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
49735*)
49736  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
49737  # A ".." for each directory in $ac_dir_suffix.
49738  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
49739  case $ac_top_builddir_sub in
49740  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
49741  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
49742  esac ;;
49743esac
49744ac_abs_top_builddir=$ac_pwd
49745ac_abs_builddir=$ac_pwd$ac_dir_suffix
49746# for backward compatibility:
49747ac_top_builddir=$ac_top_build_prefix
49748
49749case $srcdir in
49750  .)  # We are building in place.
49751    ac_srcdir=.
49752    ac_top_srcdir=$ac_top_builddir_sub
49753    ac_abs_top_srcdir=$ac_pwd ;;
49754  [\\/]* | ?:[\\/]* )  # Absolute name.
49755    ac_srcdir=$srcdir$ac_dir_suffix;
49756    ac_top_srcdir=$srcdir
49757    ac_abs_top_srcdir=$srcdir ;;
49758  *) # Relative name.
49759    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
49760    ac_top_srcdir=$ac_top_build_prefix$srcdir
49761    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
49762esac
49763ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
49764
49765
49766  case $ac_mode in
49767  :F)
49768  #
49769  # CONFIG_FILE
49770  #
49771
49772_ACEOF
49773
49774cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49775# If the template does not know about datarootdir, expand it.
49776# FIXME: This hack should be removed a few years after 2.60.
49777ac_datarootdir_hack=; ac_datarootdir_seen=
49778ac_sed_dataroot='
49779/datarootdir/ {
49780  p
49781  q
49782}
49783/@datadir@/p
49784/@docdir@/p
49785/@infodir@/p
49786/@localedir@/p
49787/@mandir@/p'
49788case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
49789*datarootdir*) ac_datarootdir_seen=yes;;
49790*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
49791  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
49792$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
49793_ACEOF
49794cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49795  ac_datarootdir_hack='
49796  s&@datadir@&$datadir&g
49797  s&@docdir@&$docdir&g
49798  s&@infodir@&$infodir&g
49799  s&@localedir@&$localedir&g
49800  s&@mandir@&$mandir&g
49801  s&\\\${datarootdir}&$datarootdir&g' ;;
49802esac
49803_ACEOF
49804
49805# Neutralize VPATH when `$srcdir' = `.'.
49806# Shell code in configure.ac might set extrasub.
49807# FIXME: do we really want to maintain this feature?
49808cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49809ac_sed_extra="$ac_vpsub
49810$extrasub
49811_ACEOF
49812cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49813:t
49814/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
49815s|@configure_input@|$ac_sed_conf_input|;t t
49816s&@top_builddir@&$ac_top_builddir_sub&;t t
49817s&@top_build_prefix@&$ac_top_build_prefix&;t t
49818s&@srcdir@&$ac_srcdir&;t t
49819s&@abs_srcdir@&$ac_abs_srcdir&;t t
49820s&@top_srcdir@&$ac_top_srcdir&;t t
49821s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
49822s&@builddir@&$ac_builddir&;t t
49823s&@abs_builddir@&$ac_abs_builddir&;t t
49824s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
49825$ac_datarootdir_hack
49826"
49827eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
49828  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49829
49830test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
49831  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
49832  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
49833      "$ac_tmp/out"`; test -z "$ac_out"; } &&
49834  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49835which seems to be undefined.  Please make sure it is defined" >&5
49836$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49837which seems to be undefined.  Please make sure it is defined" >&2;}
49838
49839  rm -f "$ac_tmp/stdin"
49840  case $ac_file in
49841  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
49842  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
49843  esac \
49844  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49845 ;;
49846  :H)
49847  #
49848  # CONFIG_HEADER
49849  #
49850  if test x"$ac_file" != x-; then
49851    {
49852      $as_echo "/* $configure_input  */" \
49853      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
49854    } >"$ac_tmp/config.h" \
49855      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49856    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
49857      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
49858$as_echo "$as_me: $ac_file is unchanged" >&6;}
49859    else
49860      rm -f "$ac_file"
49861      mv "$ac_tmp/config.h" "$ac_file" \
49862	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
49863    fi
49864  else
49865    $as_echo "/* $configure_input  */" \
49866      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
49867      || as_fn_error $? "could not create -" "$LINENO" 5
49868  fi
49869 ;;
49870
49871
49872  esac
49873
49874done # for ac_tag
49875
49876
49877as_fn_exit 0
49878_ACEOF
49879ac_clean_files=$ac_clean_files_save
49880
49881test $ac_write_fail = 0 ||
49882  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
49883
49884
49885# configure is writing to config.log, and then calls config.status.
49886# config.status does its own redirection, appending to config.log.
49887# Unfortunately, on DOS this fails, as config.log is still kept open
49888# by configure, so config.status won't be able to write to it; its
49889# output is simply discarded.  So we exec the FD to /dev/null,
49890# effectively closing config.log, so it can be properly (re)opened and
49891# appended to by config.status.  When coming back to configure, we
49892# need to make the FD available again.
49893if test "$no_create" != yes; then
49894  ac_cs_success=:
49895  ac_config_status_args=
49896  test "$silent" = yes &&
49897    ac_config_status_args="$ac_config_status_args --quiet"
49898  exec 5>/dev/null
49899  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
49900  exec 5>>config.log
49901  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
49902  # would make configure fail if this is the last instruction.
49903  $ac_cs_success || as_fn_exit 1
49904fi
49905if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
49906  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
49907$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
49908fi
49909
49910
49911# Try to move the config.log file to the output directory.
49912if test -e ./config.log; then
49913  $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
49914fi
49915
49916# Make the compare script executable
49917$CHMOD +x $OUTPUT_ROOT/compare.sh
49918
49919# Finally output some useful information to the user
49920
49921  # Finally output some useful information to the user
49922
49923  printf "\n"
49924  printf "====================================================\n"
49925  if test "x$no_create" != "xyes"; then
49926    if test "x$IS_RECONFIGURE" != "xyes"; then
49927      printf "A new configuration has been successfully created in\n %s\n" "$OUTPUT_ROOT"
49928    else
49929      printf "The existing configuration has been successfully updated in\n %s\n" "$OUTPUT_ROOT"
49930    fi
49931  else
49932    if test "x$IS_RECONFIGURE" != "xyes"; then
49933      printf "A configuration has been successfully checked but not created\n"
49934    else
49935      printf "The existing configuration has been successfully checked in\n %s\n" "$OUTPUT_ROOT"
49936    fi
49937  fi
49938  if test "x$CONFIGURE_COMMAND_LINE" != x; then
49939    printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
49940  else
49941    printf "using default settings.\n"
49942  fi
49943
49944  printf "\n"
49945  printf "Configuration summary:\n"
49946  printf "* Debug level:    $DEBUG_LEVEL\n"
49947  printf "* JDK variant:    $JDK_VARIANT\n"
49948  printf "* JVM variants:   $with_jvm_variants\n"
49949  printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
49950
49951  printf "\n"
49952  printf "Tools summary:\n"
49953  if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
49954    printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
49955  fi
49956  printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
49957  printf "* Toolchain:      $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)\n"
49958  printf "* C Compiler:     Version $CC_VERSION_NUMBER (at $CC)\n"
49959  printf "* C++ Compiler:   Version $CXX_VERSION_NUMBER (at $CXX)\n"
49960
49961  printf "\n"
49962  printf "Build performance summary:\n"
49963  printf "* Cores to use:   $JOBS\n"
49964  printf "* Memory limit:   $MEMORY_SIZE MB\n"
49965  if test "x$CCACHE_STATUS" != "x"; then
49966    printf "* ccache status:  $CCACHE_STATUS\n"
49967  fi
49968  printf "\n"
49969
49970  if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
49971    printf "NOTE: You have requested to build more than one version of the JVM, which\n"
49972    printf "will result in longer build times.\n"
49973    printf "\n"
49974  fi
49975
49976  if test "x$FOUND_ALT_VARIABLES" != "x"; then
49977    printf "WARNING: You have old-style ALT_ environment variables set.\n"
49978    printf "These are not respected, and will be ignored. It is recommended\n"
49979    printf "that you clean your environment. The following variables are set:\n"
49980    printf "$FOUND_ALT_VARIABLES\n"
49981    printf "\n"
49982  fi
49983
49984  if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
49985    printf "WARNING: Your build output directory is not on a local disk.\n"
49986    printf "This will severely degrade build performance!\n"
49987    printf "It is recommended that you create an output directory on a local disk,\n"
49988    printf "and run the configure script again from that directory.\n"
49989    printf "\n"
49990  fi
49991
49992  if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
49993    printf "WARNING: The result of this configuration has overridden an older\n"
49994    printf "configuration. You *should* run 'make clean' to make sure you get a\n"
49995    printf "proper build. Failure to do so might result in strange build problems.\n"
49996    printf "\n"
49997  fi
49998
49999  if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
50000    printf "WARNING: The result of this configuration was not saved.\n"
50001    printf "You should run without '--no-create | -n' to create the configuration.\n"
50002    printf "\n"
50003  fi
50004
50005