1 #!/bin/bash 2 # 3 # Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. 4 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5 # 6 # This code is free software; you can redistribute it and/or modify it 7 # under the terms of the GNU General Public License version 2 only, as 8 # published by the Free Software Foundation. 9 # 10 # This code is distributed in the hope that it will be useful, but WITHOUT 11 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 13 # version 2 for more details (a copy is included in the LICENSE file that 14 # accompanied this code). 15 # 16 # You should have received a copy of the GNU General Public License version 17 # 2 along with this work; if not, write to the Free Software Foundation, 18 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 19 # 20 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 21 # or visit www.oracle.com if you need additional information or have any 22 # questions. 23 # 24 25 if test "x$BASH_VERSION" = x; then 26 echo This script needs bash to run. 27 echo It is recommended to use the configure script in the source tree root instead. 28 exit 1 29 fi 30 31 CONFIGURE_COMMAND_LINE="$@" 32 conf_script_dir=`dirname $0` 33 34 if [ "$CUSTOM_CONFIG_DIR" = "" ]; then 35 conf_custom_script_dir="$conf_script_dir/../../jdk/make/closed/autoconf" 36 else 37 conf_custom_script_dir=$CUSTOM_CONFIG_DIR 38 fi 39 40 ### 41 ### Test that the generated configure is up-to-date 42 ### 43 44 run_autogen_or_fail() { 45 if test "x`which autoconf 2> /dev/null`" = x; then 46 echo "Cannot locate autoconf, unable to correct situation." 47 echo "Please install autoconf and run 'bash autogen.sh' to update the generated files." 48 echo "Error: Cannot continue" 1>&2 49 exit 1 50 else 51 echo "Running autogen.sh to correct the situation" 52 bash $conf_script_dir/autogen.sh 53 fi 54 } 55 56 check_autoconf_timestamps() { 57 for file in $conf_script_dir/configure.ac $conf_script_dir/*.m4 ; do 58 if test $file -nt $conf_script_dir/generated-configure.sh; then 59 echo "Warning: The configure source files is newer than the generated files." 60 run_autogen_or_fail 61 fi 62 done 63 64 if test -e $conf_custom_script_dir/generated-configure.sh; then 65 # If custom source configure is available, make sure it is up-to-date as well. 66 for file in $conf_script_dir/configure.ac $conf_script_dir/*.m4 $conf_custom_script_dir/*.m4; do 67 if test $file -nt $conf_custom_script_dir/generated-configure.sh; then 68 echo "Warning: The configure source files is newer than the custom generated files." 69 run_autogen_or_fail 70 fi 71 done 72 fi 73 } 74 75 check_hg_updates() { 76 if test "x`which hg 2> /dev/null`" != x; then 77 conf_updated_autoconf_files=`cd $conf_script_dir && hg status -mard 2> /dev/null | grep autoconf` 78 if test "x$conf_updated_autoconf_files" != x; then 79 echo "Configure source code has been updated, checking time stamps" 80 check_autoconf_timestamps 81 fi 82 83 if test -e $conf_custom_script_dir; then 84 # If custom source configure is available, make sure it is up-to-date as well. 85 conf_custom_updated_autoconf_files=`cd $conf_custom_script_dir && hg status -mard 2> /dev/null | grep autoconf` 86 if test "x$conf_custom_updated_autoconf_files" != x; then 87 echo "Configure custom source code has been updated, checking time stamps" 88 check_autoconf_timestamps 89 fi 90 fi 91 92 fi 93 } 94 95 # Check for local changes 96 check_hg_updates 97 98 if test -e $conf_custom_script_dir/generated-configure.sh; then 99 # Test if open configure is newer than custom configure, if so, custom needs to 100 # be regenerated. This test is required to ensure consistency with custom source. 101 conf_open_configure_timestamp=`grep DATE_WHEN_GENERATED= $conf_script_dir/generated-configure.sh | cut -d"=" -f 2` 102 conf_custom_configure_timestamp=`grep DATE_WHEN_GENERATED= $conf_custom_script_dir/generated-configure.sh | cut -d"=" -f 2` 103 if test $conf_open_configure_timestamp -gt $conf_custom_configure_timestamp; then 104 echo "Warning: The generated configure file contains changes not present in the custom generated file." 105 run_autogen_or_fail 106 fi 107 fi 108 109 # Autoconf calls the configure script recursively sometimes. 110 # Don't start logging twice in that case 111 if test "x$conf_debug_configure" = xtrue; then 112 conf_debug_configure=recursive 113 fi 114 ### 115 ### Process command-line arguments 116 ### 117 conf_processed_arguments=() 118 conf_openjdk_target= 119 120 for conf_option 121 do 122 case $conf_option in 123 --openjdk-target=*) 124 conf_openjdk_target=`expr "X$conf_option" : '[^=]*=\(.*\)'` 125 continue ;; 126 --debug-configure) 127 if test "x$conf_debug_configure" != xrecursive; then 128 conf_debug_configure=true 129 export conf_debug_configure 130 fi 131 continue ;; 132 *) 133 conf_processed_arguments=("${conf_processed_arguments[@]}" "$conf_option") ;; 134 esac 135 136 case $conf_option in 137 -build | --build | --buil | --bui | --bu |-build=* | --build=* | --buil=* | --bui=* | --bu=*) 138 conf_legacy_crosscompile="$conf_legacy_crosscompile $conf_option" ;; 139 -target | --target | --targe | --targ | --tar | --ta | --t | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 140 conf_legacy_crosscompile="$conf_legacy_crosscompile $conf_option" ;; 141 -host | --host | --hos | --ho | -host=* | --host=* | --hos=* | --ho=*) 142 conf_legacy_crosscompile="$conf_legacy_crosscompile $conf_option" ;; 143 -help | --help | --hel | --he | -h) 144 conf_print_help=true ;; 145 esac 146 done 147 148 if test "x$conf_legacy_crosscompile" != "x"; then 149 if test "x$conf_openjdk_target" != "x"; then 150 echo "Error: Specifying --openjdk-target together with autoconf" 151 echo "legacy cross-compilation flags is not supported." 152 echo "You specified: --openjdk-target=$conf_openjdk_target and $conf_legacy_crosscompile." 153 echo "The recommended use is just --openjdk-target." 154 exit 1 155 else 156 echo "Warning: You are using legacy autoconf cross-compilation flags." 157 echo "It is recommended that you use --openjdk-target instead." 158 echo "" 159 fi 160 fi 161 162 if test "x$conf_openjdk_target" != "x"; then 163 conf_build_platform=`sh $conf_script_dir/build-aux/config.guess` 164 conf_processed_arguments=("--build=$conf_build_platform" "--host=$conf_openjdk_target" "--target=$conf_openjdk_target" "${conf_processed_arguments[@]}") 165 fi 166 167 # Make configure exit with error on invalid options as default. 168 # Can be overridden by --disable-option-checking, since we prepend our argument 169 # and later options override earlier. 170 conf_processed_arguments=("--enable-option-checking=fatal" "${conf_processed_arguments[@]}") 171 172 ### 173 ### Call the configure script 174 ### 175 if test -e $conf_custom_script_dir/generated-configure.sh; then 176 # Custom source configure available; run that instead 177 echo Running custom generated-configure.sh 178 conf_script_to_run=$conf_custom_script_dir/generated-configure.sh 179 else 180 echo Running generated-configure.sh 181 conf_script_to_run=$conf_script_dir/generated-configure.sh 182 fi 183 184 if test "x$conf_debug_configure" != x; then 185 # Turn on shell debug output if requested (initial or recursive) 186 set -x 187 fi 188 189 if test "x$conf_debug_configure" = xtrue; then 190 # Turn on logging, but don't turn on twice when called recursive 191 conf_debug_logfile=./debug-configure.log 192 (exec 3>&1 ; (. $conf_script_to_run "${conf_processed_arguments[@]}" 2>&1 1>&3 ) | tee -a $conf_debug_logfile 1>&2 ; exec 3>&-) | tee -a $conf_debug_logfile 193 else 194 ( . $conf_script_to_run "${conf_processed_arguments[@]}" ) 195 fi 196 197 conf_result_code=$? 198 ### 199 ### Post-processing 200 ### 201 202 if test $conf_result_code -eq 0; then 203 if test "x$conf_print_help" = xtrue; then 204 cat <<EOT 205 206 Additional (non-autoconf) OpenJDK Options: 207 --openjdk-target=TARGET cross-compile with TARGET as target platform 208 (i.e. the one you will run the resulting binary on). 209 Equivalent to --host=TARGET --target=TARGET 210 --build=<current platform> 211 --debug-configure Run the configure script with additional debug 212 logging enabled. 213 214 Please be aware that, when cross-compiling, the OpenJDK configure script will 215 generally use 'target' where autoconf traditionally uses 'host'. 216 EOT 217 fi 218 else 219 echo configure exiting with result code $conf_result_code 220 fi 221 222 # Move the log file to the output root, if this was successfully created 223 if test -d "$OUTPUT_ROOT"; then 224 mv -f config.log "$OUTPUT_ROOT" 2> /dev/null 225 fi 226 227 exit $conf_result_code | 1 #! /bin/sh 2 # Guess values for system-dependent variables and create Makefiles. 3 # Generated by GNU Autoconf 2.68 for OpenJDK jdk8. 4 # 5 # Report bugs to <build-dev@openjdk.java.net>. 6 # 7 # 8 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 9 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software 10 # Foundation, Inc. 11 # 12 # 13 # This configure script is free software; the Free Software Foundation 14 # gives unlimited permission to copy, distribute and modify it. 15 ## -------------------- ## 16 ## M4sh Initialization. ## 17 ## -------------------- ## 18 19 # Be more Bourne compatible 20 DUALCASE=1; export DUALCASE # for MKS sh 21 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 22 emulate sh 23 NULLCMD=: 24 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 25 # is contrary to our usage. Disable this feature. 26 alias -g '${1+"$@"}'='"$@"' 27 setopt NO_GLOB_SUBST 28 else 29 case `(set -o) 2>/dev/null` in #( 30 *posix*) : 31 set -o posix ;; #( 32 *) : 33 ;; 34 esac 35 fi 36 37 38 as_nl=' 39 ' 40 export as_nl 41 # Printing a long string crashes Solaris 7 /usr/bin/printf. 42 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 43 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 45 # Prefer a ksh shell builtin over an external printf program on Solaris, 46 # but without wasting forks for bash or zsh. 47 if test -z "$BASH_VERSION$ZSH_VERSION" \ 48 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 49 as_echo='print -r --' 50 as_echo_n='print -rn --' 51 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 52 as_echo='printf %s\n' 53 as_echo_n='printf %s' 54 else 55 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 56 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 57 as_echo_n='/usr/ucb/echo -n' 58 else 59 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 60 as_echo_n_body='eval 61 arg=$1; 62 case $arg in #( 63 *"$as_nl"*) 64 expr "X$arg" : "X\\(.*\\)$as_nl"; 65 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 66 esac; 67 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 68 ' 69 export as_echo_n_body 70 as_echo_n='sh -c $as_echo_n_body as_echo' 71 fi 72 export as_echo_body 73 as_echo='sh -c $as_echo_body as_echo' 74 fi 75 76 # The user is always right. 77 if test "${PATH_SEPARATOR+set}" != set; then 78 PATH_SEPARATOR=: 79 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 80 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 81 PATH_SEPARATOR=';' 82 } 83 fi 84 85 86 # IFS 87 # We need space, tab and new line, in precisely that order. Quoting is 88 # there to prevent editors from complaining about space-tab. 89 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 90 # splitting by setting IFS to empty value.) 91 IFS=" "" $as_nl" 92 93 # Find who we are. Look in the path if we contain no directory separator. 94 as_myself= 95 case $0 in #(( 96 *[\\/]* ) as_myself=$0 ;; 97 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 98 for as_dir in $PATH 99 do 100 IFS=$as_save_IFS 101 test -z "$as_dir" && as_dir=. 102 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 103 done 104 IFS=$as_save_IFS 105 106 ;; 107 esac 108 # We did not find ourselves, most probably we were run as `sh COMMAND' 109 # in which case we are not to be found in the path. 110 if test "x$as_myself" = x; then 111 as_myself=$0 112 fi 113 if test ! -f "$as_myself"; then 114 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 115 exit 1 116 fi 117 118 # Unset variables that we do not need and which cause bugs (e.g. in 119 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 120 # suppresses any "Segmentation fault" message there. '((' could 121 # trigger a bug in pdksh 5.2.14. 122 for as_var in BASH_ENV ENV MAIL MAILPATH 123 do eval test x\${$as_var+set} = xset \ 124 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 125 done 126 PS1='$ ' 127 PS2='> ' 128 PS4='+ ' 129 130 # NLS nuisances. 131 LC_ALL=C 132 export LC_ALL 133 LANGUAGE=C 134 export LANGUAGE 135 136 # CDPATH. 137 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 138 139 if test "x$CONFIG_SHELL" = x; then 140 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 141 emulate sh 142 NULLCMD=: 143 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 144 # is contrary to our usage. Disable this feature. 145 alias -g '\${1+\"\$@\"}'='\"\$@\"' 146 setopt NO_GLOB_SUBST 147 else 148 case \`(set -o) 2>/dev/null\` in #( 149 *posix*) : 150 set -o posix ;; #( 151 *) : 152 ;; 153 esac 154 fi 155 " 156 as_required="as_fn_return () { (exit \$1); } 157 as_fn_success () { as_fn_return 0; } 158 as_fn_failure () { as_fn_return 1; } 159 as_fn_ret_success () { return 0; } 160 as_fn_ret_failure () { return 1; } 161 162 exitcode=0 163 as_fn_success || { exitcode=1; echo as_fn_success failed.; } 164 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 165 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 166 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 167 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 168 169 else 170 exitcode=1; echo positional parameters were not saved. 171 fi 172 test x\$exitcode = x0 || exit 1" 173 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 174 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 175 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 176 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 177 test \$(( 1 + 1 )) = 2 || exit 1" 178 if (eval "$as_required") 2>/dev/null; then : 179 as_have_required=yes 180 else 181 as_have_required=no 182 fi 183 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 184 185 else 186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 187 as_found=false 188 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 189 do 190 IFS=$as_save_IFS 191 test -z "$as_dir" && as_dir=. 192 as_found=: 193 case $as_dir in #( 194 /*) 195 for as_base in sh bash ksh sh5; do 196 # Try only shells that exist, to save several forks. 197 as_shell=$as_dir/$as_base 198 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 199 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 200 CONFIG_SHELL=$as_shell as_have_required=yes 201 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 202 break 2 203 fi 204 fi 205 done;; 206 esac 207 as_found=false 208 done 209 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 210 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 211 CONFIG_SHELL=$SHELL as_have_required=yes 212 fi; } 213 IFS=$as_save_IFS 214 215 216 if test "x$CONFIG_SHELL" != x; then : 217 # We cannot yet assume a decent shell, so we have to provide a 218 # neutralization value for shells without unset; and this also 219 # works around shells that cannot unset nonexistent variables. 220 # Preserve -v and -x to the replacement shell. 221 BASH_ENV=/dev/null 222 ENV=/dev/null 223 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 224 export CONFIG_SHELL 225 case $- in # (((( 226 *v*x* | *x*v* ) as_opts=-vx ;; 227 *v* ) as_opts=-v ;; 228 *x* ) as_opts=-x ;; 229 * ) as_opts= ;; 230 esac 231 exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} 232 fi 233 234 if test x$as_have_required = xno; then : 235 $as_echo "$0: This script requires a shell more modern than all" 236 $as_echo "$0: the shells that I found on your system." 237 if test x${ZSH_VERSION+set} = xset ; then 238 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 239 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 240 else 241 $as_echo "$0: Please tell bug-autoconf@gnu.org and 242 $0: build-dev@openjdk.java.net about your system, including 243 $0: any error possibly output before this message. Then 244 $0: install a modern shell, or manually run the script 245 $0: under such a shell if you do have one." 246 fi 247 exit 1 248 fi 249 fi 250 fi 251 SHELL=${CONFIG_SHELL-/bin/sh} 252 export SHELL 253 # Unset more variables known to interfere with behavior of common tools. 254 CLICOLOR_FORCE= GREP_OPTIONS= 255 unset CLICOLOR_FORCE GREP_OPTIONS 256 257 ## --------------------- ## 258 ## M4sh Shell Functions. ## 259 ## --------------------- ## 260 # as_fn_unset VAR 261 # --------------- 262 # Portably unset VAR. 263 as_fn_unset () 264 { 265 { eval $1=; unset $1;} 266 } 267 as_unset=as_fn_unset 268 269 # as_fn_set_status STATUS 270 # ----------------------- 271 # Set $? to STATUS, without forking. 272 as_fn_set_status () 273 { 274 return $1 275 } # as_fn_set_status 276 277 # as_fn_exit STATUS 278 # ----------------- 279 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 280 as_fn_exit () 281 { 282 set +e 283 as_fn_set_status $1 284 exit $1 285 } # as_fn_exit 286 287 # as_fn_mkdir_p 288 # ------------- 289 # Create "$as_dir" as a directory, including parents if necessary. 290 as_fn_mkdir_p () 291 { 292 293 case $as_dir in #( 294 -*) as_dir=./$as_dir;; 295 esac 296 test -d "$as_dir" || eval $as_mkdir_p || { 297 as_dirs= 298 while :; do 299 case $as_dir in #( 300 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 301 *) as_qdir=$as_dir;; 302 esac 303 as_dirs="'$as_qdir' $as_dirs" 304 as_dir=`$as_dirname -- "$as_dir" || 305 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 306 X"$as_dir" : 'X\(//\)[^/]' \| \ 307 X"$as_dir" : 'X\(//\)$' \| \ 308 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 309 $as_echo X"$as_dir" | 310 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 311 s//\1/ 312 q 313 } 314 /^X\(\/\/\)[^/].*/{ 315 s//\1/ 316 q 317 } 318 /^X\(\/\/\)$/{ 319 s//\1/ 320 q 321 } 322 /^X\(\/\).*/{ 323 s//\1/ 324 q 325 } 326 s/.*/./; q'` 327 test -d "$as_dir" && break 328 done 329 test -z "$as_dirs" || eval "mkdir $as_dirs" 330 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 331 332 333 } # as_fn_mkdir_p 334 # as_fn_append VAR VALUE 335 # ---------------------- 336 # Append the text in VALUE to the end of the definition contained in VAR. Take 337 # advantage of any shell optimizations that allow amortized linear growth over 338 # repeated appends, instead of the typical quadratic growth present in naive 339 # implementations. 340 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 341 eval 'as_fn_append () 342 { 343 eval $1+=\$2 344 }' 345 else 346 as_fn_append () 347 { 348 eval $1=\$$1\$2 349 } 350 fi # as_fn_append 351 352 # as_fn_arith ARG... 353 # ------------------ 354 # Perform arithmetic evaluation on the ARGs, and store the result in the 355 # global $as_val. Take advantage of shells that can avoid forks. The arguments 356 # must be portable across $(()) and expr. 357 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 358 eval 'as_fn_arith () 359 { 360 as_val=$(( $* )) 361 }' 362 else 363 as_fn_arith () 364 { 365 as_val=`expr "$@" || test $? -eq 1` 366 } 367 fi # as_fn_arith 368 369 370 # as_fn_error STATUS ERROR [LINENO LOG_FD] 371 # ---------------------------------------- 372 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 373 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 374 # script with STATUS, using 1 if that was 0. 375 as_fn_error () 376 { 377 as_status=$1; test $as_status -eq 0 && as_status=1 378 if test "$4"; then 379 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 380 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 381 fi 382 $as_echo "$as_me: error: $2" >&2 383 as_fn_exit $as_status 384 } # as_fn_error 385 386 if expr a : '\(a\)' >/dev/null 2>&1 && 387 test "X`expr 00001 : '.*\(...\)'`" = X001; then 388 as_expr=expr 389 else 390 as_expr=false 391 fi 392 393 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 394 as_basename=basename 395 else 396 as_basename=false 397 fi 398 399 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 400 as_dirname=dirname 401 else 402 as_dirname=false 403 fi 404 405 as_me=`$as_basename -- "$0" || 406 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 407 X"$0" : 'X\(//\)$' \| \ 408 X"$0" : 'X\(/\)' \| . 2>/dev/null || 409 $as_echo X/"$0" | 410 sed '/^.*\/\([^/][^/]*\)\/*$/{ 411 s//\1/ 412 q 413 } 414 /^X\/\(\/\/\)$/{ 415 s//\1/ 416 q 417 } 418 /^X\/\(\/\).*/{ 419 s//\1/ 420 q 421 } 422 s/.*/./; q'` 423 424 # Avoid depending upon Character Ranges. 425 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 426 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 427 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 428 as_cr_digits='0123456789' 429 as_cr_alnum=$as_cr_Letters$as_cr_digits 430 431 432 as_lineno_1=$LINENO as_lineno_1a=$LINENO 433 as_lineno_2=$LINENO as_lineno_2a=$LINENO 434 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 435 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 436 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 437 sed -n ' 438 p 439 /[$]LINENO/= 440 ' <$as_myself | 441 sed ' 442 s/[$]LINENO.*/&-/ 443 t lineno 444 b 445 :lineno 446 N 447 :loop 448 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 449 t loop 450 s/-\n.*// 451 ' >$as_me.lineno && 452 chmod +x "$as_me.lineno" || 453 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 454 455 # Don't try to exec as it changes $[0], causing all sort of problems 456 # (the dirname of $[0] is not the place where we might find the 457 # original and so on. Autoconf is especially sensitive to this). 458 . "./$as_me.lineno" 459 # Exit status is that of the last command. 460 exit 461 } 462 463 ECHO_C= ECHO_N= ECHO_T= 464 case `echo -n x` in #((((( 465 -n*) 466 case `echo 'xy\c'` in 467 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 468 xy) ECHO_C='\c';; 469 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 470 ECHO_T=' ';; 471 esac;; 472 *) 473 ECHO_N='-n';; 474 esac 475 476 rm -f conf$$ conf$$.exe conf$$.file 477 if test -d conf$$.dir; then 478 rm -f conf$$.dir/conf$$.file 479 else 480 rm -f conf$$.dir 481 mkdir conf$$.dir 2>/dev/null 482 fi 483 if (echo >conf$$.file) 2>/dev/null; then 484 if ln -s conf$$.file conf$$ 2>/dev/null; then 485 as_ln_s='ln -s' 486 # ... but there are two gotchas: 487 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 488 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 489 # In both cases, we have to default to `cp -p'. 490 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 491 as_ln_s='cp -p' 492 elif ln conf$$.file conf$$ 2>/dev/null; then 493 as_ln_s=ln 494 else 495 as_ln_s='cp -p' 496 fi 497 else 498 as_ln_s='cp -p' 499 fi 500 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 501 rmdir conf$$.dir 2>/dev/null 502 503 if mkdir -p . 2>/dev/null; then 504 as_mkdir_p='mkdir -p "$as_dir"' 505 else 506 test -d ./-p && rmdir ./-p 507 as_mkdir_p=false 508 fi 509 510 if test -x / >/dev/null 2>&1; then 511 as_test_x='test -x' 512 else 513 if ls -dL / >/dev/null 2>&1; then 514 as_ls_L_option=L 515 else 516 as_ls_L_option= 517 fi 518 as_test_x=' 519 eval sh -c '\'' 520 if test -d "$1"; then 521 test -d "$1/."; 522 else 523 case $1 in #( 524 -*)set "./$1";; 525 esac; 526 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( 527 ???[sx]*):;;*)false;;esac;fi 528 '\'' sh 529 ' 530 fi 531 as_executable_p=$as_test_x 532 533 # Sed expression to map a string onto a valid CPP name. 534 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 535 536 # Sed expression to map a string onto a valid variable name. 537 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 538 539 540 test -n "$DJDIR" || exec 7<&0 </dev/null 541 exec 6>&1 542 543 # Name of the host. 544 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 545 # so uname gets run too. 546 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 547 548 # 549 # Initializations. 550 # 551 ac_default_prefix=/usr/local 552 ac_clean_files= 553 ac_config_libobj_dir=. 554 LIBOBJS= 555 cross_compiling=no 556 subdirs= 557 MFLAGS= 558 MAKEFLAGS= 559 560 # Identity of this package. 561 PACKAGE_NAME='OpenJDK' 562 PACKAGE_TARNAME='openjdk' 563 PACKAGE_VERSION='jdk8' 564 PACKAGE_STRING='OpenJDK jdk8' 565 PACKAGE_BUGREPORT='build-dev@openjdk.java.net' 566 PACKAGE_URL='http://openjdk.java.net' 567 568 # Factoring default headers for most tests. 569 ac_includes_default="\ 570 #include <stdio.h> 571 #ifdef HAVE_SYS_TYPES_H 572 # include <sys/types.h> 573 #endif 574 #ifdef HAVE_SYS_STAT_H 575 # include <sys/stat.h> 576 #endif 577 #ifdef STDC_HEADERS 578 # include <stdlib.h> 579 # include <stddef.h> 580 #else 581 # ifdef HAVE_STDLIB_H 582 # include <stdlib.h> 583 # endif 584 #endif 585 #ifdef HAVE_STRING_H 586 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 587 # include <memory.h> 588 # endif 589 # include <string.h> 590 #endif 591 #ifdef HAVE_STRINGS_H 592 # include <strings.h> 593 #endif 594 #ifdef HAVE_INTTYPES_H 595 # include <inttypes.h> 596 #endif 597 #ifdef HAVE_STDINT_H 598 # include <stdint.h> 599 #endif 600 #ifdef HAVE_UNISTD_H 601 # include <unistd.h> 602 #endif" 603 604 ac_subst_vars='LTLIBOBJS 605 LIBOBJS 606 CCACHE 607 USE_PRECOMPILED_HEADER 608 SJAVAC_SERVER_DIR 609 ENABLE_SJAVAC 610 SJAVAC_SERVER_JAVA 611 JOBS 612 MEMORY_SIZE 613 NUM_CORES 614 ENABLE_INTREE_EC 615 SALIB_NAME 616 HOTSPOT_MAKE_ARGS 617 FIXPATH 618 LIBCXX 619 LLVM_LIBS 620 LLVM_LDFLAGS 621 LLVM_CFLAGS 622 LLVM_CONFIG 623 LIBFFI_LIBS 624 LIBFFI_CFLAGS 625 STATIC_CXX_SETTING 626 LIBDL 627 LIBM 628 LIBZIP_CAN_USE_MMAP 629 USE_EXTERNAL_LIBZ 630 USE_EXTERNAL_LIBGIF 631 USE_EXTERNAL_LIBJPEG 632 ALSA_LIBS 633 ALSA_CFLAGS 634 FREETYPE2_LIB_PATH 635 USING_SYSTEM_FT_LIB 636 FREETYPE2_LIBS 637 FREETYPE2_CFLAGS 638 CUPS_CFLAGS 639 OPENWIN_HOME 640 X_EXTRA_LIBS 641 X_LIBS 642 X_PRE_LIBS 643 X_CFLAGS 644 XMKMF 645 CXXFLAGS_DEBUG_SYMBOLS 646 CFLAGS_DEBUG_SYMBOLS 647 ZIP_DEBUGINFO_FILES 648 ENABLE_DEBUG_SYMBOLS 649 COMPILER_SUPPORTS_TARGET_BITS_FLAG 650 ZERO_ARCHFLAG 651 LDFLAGS_CXX_JDK 652 LDFLAGS_JDKEXE_SUFFIX 653 LDFLAGS_JDKLIB_SUFFIX 654 LDFLAGS_JDKEXE 655 LDFLAGS_JDKLIB 656 CXXFLAGS_JDKEXE 657 CXXFLAGS_JDKLIB 658 CFLAGS_JDKEXE 659 CFLAGS_JDKLIB 660 MACOSX_VERSION_MIN 661 PACKAGE_PATH 662 LEGACY_EXTRA_LDFLAGS 663 LEGACY_EXTRA_CXXFLAGS 664 LEGACY_EXTRA_CFLAGS 665 CXX_FLAG_DEPS 666 C_FLAG_DEPS 667 CXX_O_FLAG_NONE 668 CXX_O_FLAG_NORM 669 CXX_O_FLAG_HI 670 CXX_O_FLAG_HIGHEST 671 C_O_FLAG_NONE 672 C_O_FLAG_NORM 673 C_O_FLAG_HI 674 C_O_FLAG_HIGHEST 675 POST_MCS_CMD 676 POST_STRIP_CMD 677 SET_EXECUTABLE_ORIGIN 678 SET_SHARED_LIBRARY_ORIGIN 679 CXX_FLAG_REORDER 680 C_FLAG_REORDER 681 SET_SHARED_LIBRARY_MAPFILE 682 SET_SHARED_LIBRARY_NAME 683 SHARED_LIBRARY_FLAGS 684 EXE_SUFFIX 685 STATIC_LIBRARY_SUFFIX 686 SHARED_LIBRARY_SUFFIX 687 LIBRARY_PREFIX 688 STATIC_LIBRARY 689 SHARED_LIBRARY 690 OBJ_SUFFIX 691 COMPILER_NAME 692 TARGET_BITS_FLAG 693 JT_HOME 694 JTREGEXE 695 LIPO 696 ac_ct_OBJDUMP 697 OBJDUMP 698 ac_ct_OBJCOPY 699 OBJCOPY 700 MCS 701 STRIP 702 GNM 703 NM 704 AS 705 CXXCPP 706 CPP 707 COMPILER_TYPE 708 RC_FLAGS 709 DUMPBIN 710 WINAR 711 HOTSPOT_RC 712 HOTSPOT_MT 713 RC 714 MT 715 WINLD 716 HOTSPOT_LD 717 HOTSPOT_CXX 718 ARFLAGS 719 AR 720 LDEXECXX 721 LDCXX 722 LDEXE 723 LD 724 ac_ct_OBJC 725 OBJCFLAGS 726 OBJC 727 ac_ct_CXX 728 CXXFLAGS 729 CXX 730 ac_ct_PROPER_COMPILER_CXX 731 PROPER_COMPILER_CXX 732 POTENTIAL_CXX 733 TOOLS_DIR_CXX 734 OBJEXT 735 EXEEXT 736 ac_ct_CC 737 CPPFLAGS 738 LDFLAGS 739 CFLAGS 740 CC 741 ac_ct_PROPER_COMPILER_CC 742 PROPER_COMPILER_CC 743 POTENTIAL_CC 744 TOOLS_DIR_CC 745 BUILD_LD 746 BUILD_CXX 747 BUILD_CC 748 MSVCR_DLL 749 DXSDK_INCLUDE_PATH 750 DXSDK_LIB_PATH 751 VS_PATH 752 VS_LIB 753 VS_INCLUDE 754 CYGWIN_LINK 755 AR_OUT_OPTION 756 LD_OUT_OPTION 757 EXE_OUT_OPTION 758 CC_OUT_OPTION 759 BUILD_HOTSPOT 760 HOTSPOT_DIST 761 BUILD_OUTPUT 762 OVERRIDE_SRC_ROOT 763 ADD_SRC_ROOT 764 JDK_TOPDIR 765 NASHORN_TOPDIR 766 HOTSPOT_TOPDIR 767 JAXWS_TOPDIR 768 JAXP_TOPDIR 769 CORBA_TOPDIR 770 LANGTOOLS_TOPDIR 771 BOOT_JDK_JVMARGS 772 JAVAC_FLAGS 773 BOOT_JDK_SOURCETARGET 774 BOOT_JDK 775 BOOT_TOOLSJAR 776 BOOT_RTJAR 777 JAVA_CHECK 778 JAVAC_CHECK 779 COOKED_BUILD_NUMBER 780 JDK_VERSION 781 COPYRIGHT_YEAR 782 MACOSX_BUNDLE_ID_BASE 783 MACOSX_BUNDLE_NAME_BASE 784 COMPANY_NAME 785 JDK_RC_PLATFORM_NAME 786 PRODUCT_SUFFIX 787 PRODUCT_NAME 788 LAUNCHER_NAME 789 MILESTONE 790 JDK_BUILD_NUMBER 791 JDK_UPDATE_VERSION 792 JDK_MICRO_VERSION 793 JDK_MINOR_VERSION 794 JDK_MAJOR_VERSION 795 USER_RELEASE_SUFFIX 796 COMPRESS_JARS 797 UNLIMITED_CRYPTO 798 CACERTS_FILE 799 TEST_IN_BUILD 800 BUILD_HEADLESS 801 SUPPORT_HEADFUL 802 SUPPORT_HEADLESS 803 BDEPS_FTP 804 BDEPS_UNZIP 805 OS_VERSION_MICRO 806 OS_VERSION_MINOR 807 OS_VERSION_MAJOR 808 PKG_CONFIG 809 CODESIGN 810 XATTR 811 IS_GNU_TIME 812 TIME 813 STAT 814 HG 815 READELF 816 OTOOL 817 LDD 818 ZIP 819 UNZIP 820 FIND_DELETE 821 MAKE 822 CHECK_TOOLSDIR_MAKE 823 CHECK_TOOLSDIR_GMAKE 824 CHECK_MAKE 825 CHECK_GMAKE 826 PKGHANDLER 827 OUTPUT_ROOT 828 CONF_NAME 829 SPEC 830 BUILD_VARIANT_RELEASE 831 DEBUG_CLASSFILES 832 FASTDEBUG 833 VARIANT 834 DEBUG_LEVEL 835 MACOSX_UNIVERSAL 836 INCLUDE_SA 837 JVM_VARIANT_ZEROSHARK 838 JVM_VARIANT_ZERO 839 JVM_VARIANT_KERNEL 840 JVM_VARIANT_MINIMAL1 841 JVM_VARIANT_CLIENT 842 JVM_VARIANT_SERVER 843 JVM_VARIANTS 844 JDK_VARIANT 845 SET_OPENJDK 846 BUILD_LOG_WRAPPER 847 BUILD_LOG_PREVIOUS 848 BUILD_LOG 849 SYS_ROOT 850 PATH_SEP 851 SRC_ROOT 852 ZERO_ARCHDEF 853 DEFINE_CROSS_COMPILE_ARCH 854 LP64 855 OPENJDK_TARGET_OS_API_DIR 856 OPENJDK_TARGET_CPU_JLI_CFLAGS 857 OPENJDK_TARGET_CPU_OSARCH 858 OPENJDK_TARGET_CPU_ISADIR 859 OPENJDK_TARGET_CPU_LIBDIR 860 OPENJDK_TARGET_CPU_LEGACY_LIB 861 OPENJDK_TARGET_CPU_LEGACY 862 REQUIRED_OS_VERSION 863 REQUIRED_OS_NAME 864 COMPILE_TYPE 865 OPENJDK_TARGET_CPU_ENDIAN 866 OPENJDK_TARGET_CPU_BITS 867 OPENJDK_TARGET_CPU_ARCH 868 OPENJDK_TARGET_CPU 869 OPENJDK_TARGET_OS_API 870 OPENJDK_TARGET_OS 871 OPENJDK_BUILD_CPU_ENDIAN 872 OPENJDK_BUILD_CPU_BITS 873 OPENJDK_BUILD_CPU_ARCH 874 OPENJDK_BUILD_CPU 875 OPENJDK_BUILD_OS_API 876 OPENJDK_BUILD_OS 877 OPENJDK_BUILD_AUTOCONF_NAME 878 OPENJDK_TARGET_AUTOCONF_NAME 879 target_os 880 target_vendor 881 target_cpu 882 target 883 host_os 884 host_vendor 885 host_cpu 886 host 887 build_os 888 build_vendor 889 build_cpu 890 build 891 SETFILE 892 DF 893 READLINK 894 CYGPATH 895 NAWK 896 SED 897 FGREP 898 EGREP 899 GREP 900 AWK 901 XARGS 902 WHICH 903 WC 904 UNIQ 905 UNAME 906 TR 907 TOUCH 908 TEE 909 TAR 910 TAIL 911 SORT 912 SH 913 RM 914 PRINTF 915 MV 916 MKTEMP 917 MKDIR 918 LS 919 LN 920 HEAD 921 FIND 922 FILE 923 EXPR 924 ECHO 925 DIRNAME 926 DIFF 927 DATE 928 CUT 929 CPIO 930 CP 931 COMM 932 CMP 933 CHMOD 934 CAT 935 BASH 936 BASENAME 937 DATE_WHEN_CONFIGURED 938 CONFIGURE_COMMAND_LINE 939 CUSTOM_MAKE_DIR 940 target_alias 941 host_alias 942 build_alias 943 LIBS 944 ECHO_T 945 ECHO_N 946 ECHO_C 947 DEFS 948 mandir 949 localedir 950 libdir 951 psdir 952 pdfdir 953 dvidir 954 htmldir 955 infodir 956 docdir 957 oldincludedir 958 includedir 959 localstatedir 960 sharedstatedir 961 sysconfdir 962 datadir 963 datarootdir 964 libexecdir 965 sbindir 966 bindir 967 program_transform_name 968 prefix 969 exec_prefix 970 PACKAGE_URL 971 PACKAGE_BUGREPORT 972 PACKAGE_STRING 973 PACKAGE_VERSION 974 PACKAGE_TARNAME 975 PACKAGE_NAME 976 PATH_SEPARATOR 977 SHELL' 978 ac_subst_files='' 979 ac_user_opts=' 980 enable_option_checking 981 with_custom_make_dir 982 with_target_bits 983 with_sys_root 984 with_tools_dir 985 with_devkit 986 enable_openjdk_only 987 with_jdk_variant 988 with_jvm_variants 989 enable_debug 990 with_debug_level 991 with_conf_name 992 with_builddeps_conf 993 with_builddeps_server 994 with_builddeps_dir 995 with_builddeps_group 996 enable_headful 997 enable_hotspot_test_in_build 998 with_cacerts_file 999 enable_unlimited_crypto 1000 with_milestone 1001 with_update_version 1002 with_build_number 1003 with_user_release_suffix 1004 with_boot_jdk 1005 with_boot_jdk_jvmargs 1006 with_add_source_root 1007 with_override_source_root 1008 with_adds_and_overrides 1009 with_override_langtools 1010 with_override_corba 1011 with_override_jaxp 1012 with_override_jaxws 1013 with_override_hotspot 1014 with_override_jdk 1015 with_import_hotspot 1016 with_msvcr_dll 1017 with_dxsdk 1018 with_dxsdk_lib 1019 with_dxsdk_include 1020 with_jtreg 1021 with_extra_cflags 1022 with_extra_cxxflags 1023 with_extra_ldflags 1024 enable_debug_symbols 1025 enable_zip_debug_info 1026 enable_macosx_runtime_support 1027 with_x 1028 with_cups 1029 with_cups_include 1030 with_freetype 1031 with_alsa 1032 with_alsa_include 1033 with_alsa_lib 1034 with_giflib 1035 with_zlib 1036 with_stdc__lib 1037 with_num_cores 1038 with_memory_size 1039 with_jobs 1040 with_sjavac_server_java 1041 enable_sjavac 1042 enable_precompiled_headers 1043 enable_ccache 1044 with_ccache_dir 1045 ' 1046 ac_precious_vars='build_alias 1047 host_alias 1048 target_alias 1049 PKG_CONFIG 1050 CC 1051 CFLAGS 1052 LDFLAGS 1053 LIBS 1054 CPPFLAGS 1055 CXX 1056 CXXFLAGS 1057 CCC 1058 OBJC 1059 OBJCFLAGS 1060 CPP 1061 CXXCPP 1062 XMKMF 1063 FREETYPE2_CFLAGS 1064 FREETYPE2_LIBS 1065 ALSA_CFLAGS 1066 ALSA_LIBS 1067 LIBFFI_CFLAGS 1068 LIBFFI_LIBS' 1069 1070 1071 # Initialize some variables set by options. 1072 ac_init_help= 1073 ac_init_version=false 1074 ac_unrecognized_opts= 1075 ac_unrecognized_sep= 1076 # The variables have the same names as the options, with 1077 # dashes changed to underlines. 1078 cache_file=/dev/null 1079 exec_prefix=NONE 1080 no_create= 1081 no_recursion= 1082 prefix=NONE 1083 program_prefix=NONE 1084 program_suffix=NONE 1085 program_transform_name=s,x,x, 1086 silent= 1087 site= 1088 srcdir= 1089 verbose= 1090 x_includes=NONE 1091 x_libraries=NONE 1092 1093 # Installation directory options. 1094 # These are left unexpanded so users can "make install exec_prefix=/foo" 1095 # and all the variables that are supposed to be based on exec_prefix 1096 # by default will actually change. 1097 # Use braces instead of parens because sh, perl, etc. also accept them. 1098 # (The list follows the same order as the GNU Coding Standards.) 1099 bindir='${exec_prefix}/bin' 1100 sbindir='${exec_prefix}/sbin' 1101 libexecdir='${exec_prefix}/libexec' 1102 datarootdir='${prefix}/share' 1103 datadir='${datarootdir}' 1104 sysconfdir='${prefix}/etc' 1105 sharedstatedir='${prefix}/com' 1106 localstatedir='${prefix}/var' 1107 includedir='${prefix}/include' 1108 oldincludedir='/usr/include' 1109 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1110 infodir='${datarootdir}/info' 1111 htmldir='${docdir}' 1112 dvidir='${docdir}' 1113 pdfdir='${docdir}' 1114 psdir='${docdir}' 1115 libdir='${exec_prefix}/lib' 1116 localedir='${datarootdir}/locale' 1117 mandir='${datarootdir}/man' 1118 1119 ac_prev= 1120 ac_dashdash= 1121 for ac_option 1122 do 1123 # If the previous option needs an argument, assign it. 1124 if test -n "$ac_prev"; then 1125 eval $ac_prev=\$ac_option 1126 ac_prev= 1127 continue 1128 fi 1129 1130 case $ac_option in 1131 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1132 *=) ac_optarg= ;; 1133 *) ac_optarg=yes ;; 1134 esac 1135 1136 # Accept the important Cygnus configure options, so we can diagnose typos. 1137 1138 case $ac_dashdash$ac_option in 1139 --) 1140 ac_dashdash=yes ;; 1141 1142 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1143 ac_prev=bindir ;; 1144 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1145 bindir=$ac_optarg ;; 1146 1147 -build | --build | --buil | --bui | --bu) 1148 ac_prev=build_alias ;; 1149 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1150 build_alias=$ac_optarg ;; 1151 1152 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1153 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1154 ac_prev=cache_file ;; 1155 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1156 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1157 cache_file=$ac_optarg ;; 1158 1159 --config-cache | -C) 1160 cache_file=config.cache ;; 1161 1162 -datadir | --datadir | --datadi | --datad) 1163 ac_prev=datadir ;; 1164 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1165 datadir=$ac_optarg ;; 1166 1167 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1168 | --dataroo | --dataro | --datar) 1169 ac_prev=datarootdir ;; 1170 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1171 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1172 datarootdir=$ac_optarg ;; 1173 1174 -disable-* | --disable-*) 1175 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1176 # Reject names that are not valid shell variable names. 1177 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1178 as_fn_error $? "invalid feature name: $ac_useropt" 1179 ac_useropt_orig=$ac_useropt 1180 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1181 case $ac_user_opts in 1182 *" 1183 "enable_$ac_useropt" 1184 "*) ;; 1185 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1186 ac_unrecognized_sep=', ';; 1187 esac 1188 eval enable_$ac_useropt=no ;; 1189 1190 -docdir | --docdir | --docdi | --doc | --do) 1191 ac_prev=docdir ;; 1192 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1193 docdir=$ac_optarg ;; 1194 1195 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1196 ac_prev=dvidir ;; 1197 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1198 dvidir=$ac_optarg ;; 1199 1200 -enable-* | --enable-*) 1201 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1202 # Reject names that are not valid shell variable names. 1203 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1204 as_fn_error $? "invalid feature name: $ac_useropt" 1205 ac_useropt_orig=$ac_useropt 1206 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1207 case $ac_user_opts in 1208 *" 1209 "enable_$ac_useropt" 1210 "*) ;; 1211 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1212 ac_unrecognized_sep=', ';; 1213 esac 1214 eval enable_$ac_useropt=\$ac_optarg ;; 1215 1216 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1217 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1218 | --exec | --exe | --ex) 1219 ac_prev=exec_prefix ;; 1220 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1221 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1222 | --exec=* | --exe=* | --ex=*) 1223 exec_prefix=$ac_optarg ;; 1224 1225 -gas | --gas | --ga | --g) 1226 # Obsolete; use --with-gas. 1227 with_gas=yes ;; 1228 1229 -help | --help | --hel | --he | -h) 1230 ac_init_help=long ;; 1231 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1232 ac_init_help=recursive ;; 1233 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1234 ac_init_help=short ;; 1235 1236 -host | --host | --hos | --ho) 1237 ac_prev=host_alias ;; 1238 -host=* | --host=* | --hos=* | --ho=*) 1239 host_alias=$ac_optarg ;; 1240 1241 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1242 ac_prev=htmldir ;; 1243 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1244 | --ht=*) 1245 htmldir=$ac_optarg ;; 1246 1247 -includedir | --includedir | --includedi | --included | --include \ 1248 | --includ | --inclu | --incl | --inc) 1249 ac_prev=includedir ;; 1250 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1251 | --includ=* | --inclu=* | --incl=* | --inc=*) 1252 includedir=$ac_optarg ;; 1253 1254 -infodir | --infodir | --infodi | --infod | --info | --inf) 1255 ac_prev=infodir ;; 1256 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1257 infodir=$ac_optarg ;; 1258 1259 -libdir | --libdir | --libdi | --libd) 1260 ac_prev=libdir ;; 1261 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1262 libdir=$ac_optarg ;; 1263 1264 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1265 | --libexe | --libex | --libe) 1266 ac_prev=libexecdir ;; 1267 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1268 | --libexe=* | --libex=* | --libe=*) 1269 libexecdir=$ac_optarg ;; 1270 1271 -localedir | --localedir | --localedi | --localed | --locale) 1272 ac_prev=localedir ;; 1273 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1274 localedir=$ac_optarg ;; 1275 1276 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1277 | --localstate | --localstat | --localsta | --localst | --locals) 1278 ac_prev=localstatedir ;; 1279 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1280 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1281 localstatedir=$ac_optarg ;; 1282 1283 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1284 ac_prev=mandir ;; 1285 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1286 mandir=$ac_optarg ;; 1287 1288 -nfp | --nfp | --nf) 1289 # Obsolete; use --without-fp. 1290 with_fp=no ;; 1291 1292 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1293 | --no-cr | --no-c | -n) 1294 no_create=yes ;; 1295 1296 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1297 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1298 no_recursion=yes ;; 1299 1300 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1301 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1302 | --oldin | --oldi | --old | --ol | --o) 1303 ac_prev=oldincludedir ;; 1304 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1305 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1306 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1307 oldincludedir=$ac_optarg ;; 1308 1309 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1310 ac_prev=prefix ;; 1311 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1312 prefix=$ac_optarg ;; 1313 1314 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1315 | --program-pre | --program-pr | --program-p) 1316 ac_prev=program_prefix ;; 1317 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1318 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1319 program_prefix=$ac_optarg ;; 1320 1321 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1322 | --program-suf | --program-su | --program-s) 1323 ac_prev=program_suffix ;; 1324 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1325 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1326 program_suffix=$ac_optarg ;; 1327 1328 -program-transform-name | --program-transform-name \ 1329 | --program-transform-nam | --program-transform-na \ 1330 | --program-transform-n | --program-transform- \ 1331 | --program-transform | --program-transfor \ 1332 | --program-transfo | --program-transf \ 1333 | --program-trans | --program-tran \ 1334 | --progr-tra | --program-tr | --program-t) 1335 ac_prev=program_transform_name ;; 1336 -program-transform-name=* | --program-transform-name=* \ 1337 | --program-transform-nam=* | --program-transform-na=* \ 1338 | --program-transform-n=* | --program-transform-=* \ 1339 | --program-transform=* | --program-transfor=* \ 1340 | --program-transfo=* | --program-transf=* \ 1341 | --program-trans=* | --program-tran=* \ 1342 | --progr-tra=* | --program-tr=* | --program-t=*) 1343 program_transform_name=$ac_optarg ;; 1344 1345 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1346 ac_prev=pdfdir ;; 1347 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1348 pdfdir=$ac_optarg ;; 1349 1350 -psdir | --psdir | --psdi | --psd | --ps) 1351 ac_prev=psdir ;; 1352 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1353 psdir=$ac_optarg ;; 1354 1355 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1356 | -silent | --silent | --silen | --sile | --sil) 1357 silent=yes ;; 1358 1359 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1360 ac_prev=sbindir ;; 1361 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1362 | --sbi=* | --sb=*) 1363 sbindir=$ac_optarg ;; 1364 1365 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1366 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1367 | --sharedst | --shareds | --shared | --share | --shar \ 1368 | --sha | --sh) 1369 ac_prev=sharedstatedir ;; 1370 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1371 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1372 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1373 | --sha=* | --sh=*) 1374 sharedstatedir=$ac_optarg ;; 1375 1376 -site | --site | --sit) 1377 ac_prev=site ;; 1378 -site=* | --site=* | --sit=*) 1379 site=$ac_optarg ;; 1380 1381 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1382 ac_prev=srcdir ;; 1383 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1384 srcdir=$ac_optarg ;; 1385 1386 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1387 | --syscon | --sysco | --sysc | --sys | --sy) 1388 ac_prev=sysconfdir ;; 1389 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1390 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1391 sysconfdir=$ac_optarg ;; 1392 1393 -target | --target | --targe | --targ | --tar | --ta | --t) 1394 ac_prev=target_alias ;; 1395 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1396 target_alias=$ac_optarg ;; 1397 1398 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1399 verbose=yes ;; 1400 1401 -version | --version | --versio | --versi | --vers | -V) 1402 ac_init_version=: ;; 1403 1404 -with-* | --with-*) 1405 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1406 # Reject names that are not valid shell variable names. 1407 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1408 as_fn_error $? "invalid package name: $ac_useropt" 1409 ac_useropt_orig=$ac_useropt 1410 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1411 case $ac_user_opts in 1412 *" 1413 "with_$ac_useropt" 1414 "*) ;; 1415 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1416 ac_unrecognized_sep=', ';; 1417 esac 1418 eval with_$ac_useropt=\$ac_optarg ;; 1419 1420 -without-* | --without-*) 1421 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1422 # Reject names that are not valid shell variable names. 1423 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1424 as_fn_error $? "invalid package name: $ac_useropt" 1425 ac_useropt_orig=$ac_useropt 1426 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1427 case $ac_user_opts in 1428 *" 1429 "with_$ac_useropt" 1430 "*) ;; 1431 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1432 ac_unrecognized_sep=', ';; 1433 esac 1434 eval with_$ac_useropt=no ;; 1435 1436 --x) 1437 # Obsolete; use --with-x. 1438 with_x=yes ;; 1439 1440 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1441 | --x-incl | --x-inc | --x-in | --x-i) 1442 ac_prev=x_includes ;; 1443 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1444 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1445 x_includes=$ac_optarg ;; 1446 1447 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1448 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1449 ac_prev=x_libraries ;; 1450 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1451 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1452 x_libraries=$ac_optarg ;; 1453 1454 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1455 Try \`$0 --help' for more information" 1456 ;; 1457 1458 *=*) 1459 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1460 # Reject names that are not valid shell variable names. 1461 case $ac_envvar in #( 1462 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1463 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1464 esac 1465 eval $ac_envvar=\$ac_optarg 1466 export $ac_envvar ;; 1467 1468 *) 1469 # FIXME: should be removed in autoconf 3.0. 1470 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1471 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1472 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1473 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1474 ;; 1475 1476 esac 1477 done 1478 1479 if test -n "$ac_prev"; then 1480 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1481 as_fn_error $? "missing argument to $ac_option" 1482 fi 1483 1484 if test -n "$ac_unrecognized_opts"; then 1485 case $enable_option_checking in 1486 no) ;; 1487 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1488 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1489 esac 1490 fi 1491 1492 # Check all directory arguments for consistency. 1493 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1494 datadir sysconfdir sharedstatedir localstatedir includedir \ 1495 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1496 libdir localedir mandir 1497 do 1498 eval ac_val=\$$ac_var 1499 # Remove trailing slashes. 1500 case $ac_val in 1501 */ ) 1502 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1503 eval $ac_var=\$ac_val;; 1504 esac 1505 # Be sure to have absolute directory names. 1506 case $ac_val in 1507 [\\/$]* | ?:[\\/]* ) continue;; 1508 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1509 esac 1510 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1511 done 1512 1513 # There might be people who depend on the old broken behavior: `$host' 1514 # used to hold the argument of --host etc. 1515 # FIXME: To remove some day. 1516 build=$build_alias 1517 host=$host_alias 1518 target=$target_alias 1519 1520 # FIXME: To remove some day. 1521 if test "x$host_alias" != x; then 1522 if test "x$build_alias" = x; then 1523 cross_compiling=maybe 1524 $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. 1525 If a cross compiler is detected then cross compile mode will be used" >&2 1526 elif test "x$build_alias" != "x$host_alias"; then 1527 cross_compiling=yes 1528 fi 1529 fi 1530 1531 ac_tool_prefix= 1532 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1533 1534 test "$silent" = yes && exec 6>/dev/null 1535 1536 1537 ac_pwd=`pwd` && test -n "$ac_pwd" && 1538 ac_ls_di=`ls -di .` && 1539 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1540 as_fn_error $? "working directory cannot be determined" 1541 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1542 as_fn_error $? "pwd does not report name of working directory" 1543 1544 1545 # Find the source files, if location was not specified. 1546 if test -z "$srcdir"; then 1547 ac_srcdir_defaulted=yes 1548 # Try the directory containing this script, then the parent directory. 1549 ac_confdir=`$as_dirname -- "$as_myself" || 1550 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1551 X"$as_myself" : 'X\(//\)[^/]' \| \ 1552 X"$as_myself" : 'X\(//\)$' \| \ 1553 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1554 $as_echo X"$as_myself" | 1555 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1556 s//\1/ 1557 q 1558 } 1559 /^X\(\/\/\)[^/].*/{ 1560 s//\1/ 1561 q 1562 } 1563 /^X\(\/\/\)$/{ 1564 s//\1/ 1565 q 1566 } 1567 /^X\(\/\).*/{ 1568 s//\1/ 1569 q 1570 } 1571 s/.*/./; q'` 1572 srcdir=$ac_confdir 1573 if test ! -r "$srcdir/$ac_unique_file"; then 1574 srcdir=.. 1575 fi 1576 else 1577 ac_srcdir_defaulted=no 1578 fi 1579 if test ! -r "$srcdir/$ac_unique_file"; then 1580 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1581 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1582 fi 1583 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1584 ac_abs_confdir=`( 1585 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1586 pwd)` 1587 # When building in place, set srcdir=. 1588 if test "$ac_abs_confdir" = "$ac_pwd"; then 1589 srcdir=. 1590 fi 1591 # Remove unnecessary trailing slashes from srcdir. 1592 # Double slashes in file names in object file debugging info 1593 # mess up M-x gdb in Emacs. 1594 case $srcdir in 1595 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1596 esac 1597 for ac_var in $ac_precious_vars; do 1598 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1599 eval ac_env_${ac_var}_value=\$${ac_var} 1600 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1601 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1602 done 1603 1604 # 1605 # Report the --help message. 1606 # 1607 if test "$ac_init_help" = "long"; then 1608 # Omit some internal or obsolete options to make the list less imposing. 1609 # This message is too long to be a string in the A/UX 3.1 sh. 1610 cat <<_ACEOF 1611 \`configure' configures OpenJDK jdk8 to adapt to many kinds of systems. 1612 1613 Usage: $0 [OPTION]... [VAR=VALUE]... 1614 1615 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1616 VAR=VALUE. See below for descriptions of some of the useful variables. 1617 1618 Defaults for the options are specified in brackets. 1619 1620 Configuration: 1621 -h, --help display this help and exit 1622 --help=short display options specific to this package 1623 --help=recursive display the short help of all the included packages 1624 -V, --version display version information and exit 1625 -q, --quiet, --silent do not print \`checking ...' messages 1626 --cache-file=FILE cache test results in FILE [disabled] 1627 -C, --config-cache alias for \`--cache-file=config.cache' 1628 -n, --no-create do not create output files 1629 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1630 1631 Installation directories: 1632 --prefix=PREFIX install architecture-independent files in PREFIX 1633 [$ac_default_prefix] 1634 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1635 [PREFIX] 1636 1637 By default, \`make install' will install all the files in 1638 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1639 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1640 for instance \`--prefix=\$HOME'. 1641 1642 For better control, use the options below. 1643 1644 Fine tuning of the installation directories: 1645 --bindir=DIR user executables [EPREFIX/bin] 1646 --sbindir=DIR system admin executables [EPREFIX/sbin] 1647 --libexecdir=DIR program executables [EPREFIX/libexec] 1648 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1649 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1650 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1651 --libdir=DIR object code libraries [EPREFIX/lib] 1652 --includedir=DIR C header files [PREFIX/include] 1653 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1654 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1655 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1656 --infodir=DIR info documentation [DATAROOTDIR/info] 1657 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1658 --mandir=DIR man documentation [DATAROOTDIR/man] 1659 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1660 --htmldir=DIR html documentation [DOCDIR] 1661 --dvidir=DIR dvi documentation [DOCDIR] 1662 --pdfdir=DIR pdf documentation [DOCDIR] 1663 --psdir=DIR ps documentation [DOCDIR] 1664 _ACEOF 1665 1666 cat <<\_ACEOF 1667 1668 X features: 1669 --x-includes=DIR X include files are in DIR 1670 --x-libraries=DIR X library files are in DIR 1671 1672 System types: 1673 --build=BUILD configure for building on BUILD [guessed] 1674 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1675 --target=TARGET configure for building compilers for TARGET [HOST] 1676 _ACEOF 1677 fi 1678 1679 if test -n "$ac_init_help"; then 1680 case $ac_init_help in 1681 short | recursive ) echo "Configuration of OpenJDK jdk8:";; 1682 esac 1683 cat <<\_ACEOF 1684 1685 Optional Features: 1686 --disable-option-checking ignore unrecognized --enable/--with options 1687 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1688 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1689 --enable-openjdk-only suppress building custom source even if present 1690 [disabled] 1691 --enable-debug set the debug level to fastdebug (shorthand for 1692 --with-debug-level=fastdebug) [disabled] 1693 --disable-headful disable building headful support (graphical UI 1694 support) [enabled] 1695 --enable-hotspot-test-in-build 1696 run the Queens test after Hotspot build [disabled] 1697 --enable-unlimited-crypto 1698 Enable unlimited crypto policy [disabled] 1699 --disable-debug-symbols disable generation of debug symbols [enabled] 1700 --disable-zip-debug-info 1701 disable zipping of debug-info files [enabled] 1702 --disable-macosx-runtime-support 1703 disable the use of MacOSX Java runtime support 1704 framework [enabled] 1705 --enable-sjavac use sjavac to do fast incremental compiles 1706 [disabled] 1707 --disable-precompiled-headers 1708 disable using precompiled headers when compiling C++ 1709 [enabled] 1710 --disable-ccache disable using ccache to speed up recompilations 1711 [enabled] 1712 1713 Optional Packages: 1714 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 1715 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 1716 --with-custom-make-dir use this directory for custom build/make files 1717 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 1718 support it), e.g. --with-target-bits=32 [guessed] 1719 --with-sys-root pass this sys-root to the compilers and tools (for 1720 cross-compiling) 1721 --with-tools-dir search this directory for compilers and tools (for 1722 cross-compiling) 1723 --with-devkit use this directory as base for tools-dir and 1724 sys-root (for cross-compiling) 1725 --with-jdk-variant JDK variant to build (normal) [normal] 1726 --with-jvm-variants JVM variants (separated by commas) to build (server, 1727 client, minimal1, kernel, zero, zeroshark) [server] 1728 --with-debug-level set the debug level (release, fastdebug, slowdebug) 1729 [release] 1730 --with-conf-name use this as the name of the configuration [generated 1731 from important configuration options] 1732 --with-builddeps-conf use this configuration file for the builddeps 1733 --with-builddeps-server download and use build dependencies from this server 1734 url 1735 --with-builddeps-dir store downloaded build dependencies here 1736 [/localhome/builddeps] 1737 --with-builddeps-group chgrp the downloaded build dependencies to this 1738 group 1739 --with-cacerts-file specify alternative cacerts file 1740 --with-milestone Set milestone value for build [internal] 1741 --with-update-version Set update version value for build [b00] 1742 --with-build-number Set build number value for build [b00] 1743 --with-user-release-suffix 1744 Add a custom string to the version string if build 1745 number isn't set.[username_builddateb00] 1746 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 1747 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all 1748 invocations of the Boot JDK, overriding the default 1749 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 1750 -enableassertions" 1751 --with-add-source-root for each and every source directory, look in this 1752 additional source root for the same directory; if it 1753 exists and have files in it, include it in the build 1754 --with-override-source-root 1755 for each and every source directory, look in this 1756 override source root for the same directory; if it 1757 exists, use that directory instead and ignore the 1758 directory in the original source root 1759 --with-adds-and-overrides 1760 use the subdirs 'adds' and 'overrides' in the 1761 specified directory as add-source-root and 1762 override-source-root 1763 --with-override-langtools 1764 use this langtools dir for the build 1765 --with-override-corba use this corba dir for the build 1766 --with-override-jaxp use this jaxp dir for the build 1767 --with-override-jaxws use this jaxws dir for the build 1768 --with-override-hotspot use this hotspot dir for the build 1769 --with-override-jdk use this jdk dir for the build 1770 --with-import-hotspot import hotspot binaries from this jdk image or 1771 hotspot build dist dir instead of building from 1772 source 1773 --with-msvcr-dll copy this msvcr100.dll into the built JDK (Windows 1774 only) [probed] 1775 --with-dxsdk the DirectX SDK (Windows only) [probed] 1776 --with-dxsdk-lib the DirectX SDK lib directory (Windows only) 1777 [probed] 1778 --with-dxsdk-include the DirectX SDK include directory (Windows only) 1779 [probed] 1780 --with-jtreg Regression Test Harness [probed] 1781 --with-extra-cflags extra flags to be used when compiling jdk c-files 1782 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 1783 --with-extra-ldflags extra flags to be used when linking jdk 1784 --with-x use the X Window System 1785 --with-cups specify prefix directory for the cups package 1786 (expecting the headers under PATH/include) 1787 --with-cups-include specify directory for the cups include files 1788 --with-freetype specify prefix directory for the freetype2 package 1789 (expecting the libraries under PATH/lib and the 1790 headers under PATH/include) 1791 --with-alsa specify prefix directory for the alsa package 1792 (expecting the libraries under PATH/lib and the 1793 headers under PATH/include) 1794 --with-alsa-include specify directory for the alsa include files 1795 --with-alsa-lib specify directory for the alsa library 1796 --with-giflib use giflib from build system or OpenJDK source 1797 (system, bundled) [bundled] 1798 --with-zlib use zlib from build system or OpenJDK source 1799 (system, bundled) [bundled] 1800 --with-stdc++lib=<static>,<dynamic>,<default> 1801 force linking of the C++ runtime on Linux to either 1802 static or dynamic, default is static with dynamic as 1803 fallback 1804 --with-num-cores number of cores in the build system, e.g. 1805 --with-num-cores=8 [probed] 1806 --with-memory-size memory (in MB) available in the build system, e.g. 1807 --with-memory-size=1024 [probed] 1808 --with-jobs number of parallel jobs to let make run [calculated 1809 based on cores and memory] 1810 --with-sjavac-server-java 1811 use this java binary for running the sjavac 1812 background server [Boot JDK java] 1813 --with-ccache-dir where to store ccache files [~/.ccache] 1814 1815 Some influential environment variables: 1816 PKG_CONFIG path to pkg-config utility 1817 CC C compiler command 1818 CFLAGS C compiler flags 1819 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 1820 nonstandard directory <lib dir> 1821 LIBS libraries to pass to the linker, e.g. -l<library> 1822 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 1823 you have headers in a nonstandard directory <include dir> 1824 CXX C++ compiler command 1825 CXXFLAGS C++ compiler flags 1826 OBJC Objective C compiler command 1827 OBJCFLAGS Objective C compiler flags 1828 CPP C preprocessor 1829 CXXCPP C++ preprocessor 1830 XMKMF Path to xmkmf, Makefile generator for X Window System 1831 FREETYPE2_CFLAGS 1832 C compiler flags for FREETYPE2, overriding pkg-config 1833 FREETYPE2_LIBS 1834 linker flags for FREETYPE2, overriding pkg-config 1835 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 1836 ALSA_LIBS linker flags for ALSA, overriding pkg-config 1837 LIBFFI_CFLAGS 1838 C compiler flags for LIBFFI, overriding pkg-config 1839 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 1840 1841 Use these variables to override the choices made by `configure' or to help 1842 it to find libraries and programs with nonstandard names/locations. 1843 1844 Report bugs to <build-dev@openjdk.java.net>. 1845 OpenJDK home page: <http://openjdk.java.net>. 1846 _ACEOF 1847 ac_status=$? 1848 fi 1849 1850 if test "$ac_init_help" = "recursive"; then 1851 # If there are subdirs, report their specific --help. 1852 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 1853 test -d "$ac_dir" || 1854 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 1855 continue 1856 ac_builddir=. 1857 1858 case "$ac_dir" in 1859 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 1860 *) 1861 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 1862 # A ".." for each directory in $ac_dir_suffix. 1863 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 1864 case $ac_top_builddir_sub in 1865 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 1866 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 1867 esac ;; 1868 esac 1869 ac_abs_top_builddir=$ac_pwd 1870 ac_abs_builddir=$ac_pwd$ac_dir_suffix 1871 # for backward compatibility: 1872 ac_top_builddir=$ac_top_build_prefix 1873 1874 case $srcdir in 1875 .) # We are building in place. 1876 ac_srcdir=. 1877 ac_top_srcdir=$ac_top_builddir_sub 1878 ac_abs_top_srcdir=$ac_pwd ;; 1879 [\\/]* | ?:[\\/]* ) # Absolute name. 1880 ac_srcdir=$srcdir$ac_dir_suffix; 1881 ac_top_srcdir=$srcdir 1882 ac_abs_top_srcdir=$srcdir ;; 1883 *) # Relative name. 1884 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 1885 ac_top_srcdir=$ac_top_build_prefix$srcdir 1886 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 1887 esac 1888 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 1889 1890 cd "$ac_dir" || { ac_status=$?; continue; } 1891 # Check for guested configure. 1892 if test -f "$ac_srcdir/configure.gnu"; then 1893 echo && 1894 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 1895 elif test -f "$ac_srcdir/configure"; then 1896 echo && 1897 $SHELL "$ac_srcdir/configure" --help=recursive 1898 else 1899 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 1900 fi || ac_status=$? 1901 cd "$ac_pwd" || { ac_status=$?; break; } 1902 done 1903 fi 1904 1905 test -n "$ac_init_help" && exit $ac_status 1906 if $ac_init_version; then 1907 cat <<\_ACEOF 1908 OpenJDK configure jdk8 1909 generated by GNU Autoconf 2.68 1910 1911 Copyright (C) 2010 Free Software Foundation, Inc. 1912 This configure script is free software; the Free Software Foundation 1913 gives unlimited permission to copy, distribute and modify it. 1914 _ACEOF 1915 exit 1916 fi 1917 1918 ## ------------------------ ## 1919 ## Autoconf initialization. ## 1920 ## ------------------------ ## 1921 1922 # ac_fn_c_try_compile LINENO 1923 # -------------------------- 1924 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1925 ac_fn_c_try_compile () 1926 { 1927 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1928 rm -f conftest.$ac_objext 1929 if { { ac_try="$ac_compile" 1930 case "(($ac_try" in 1931 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1932 *) ac_try_echo=$ac_try;; 1933 esac 1934 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1935 $as_echo "$ac_try_echo"; } >&5 1936 (eval "$ac_compile") 2>conftest.err 1937 ac_status=$? 1938 if test -s conftest.err; then 1939 grep -v '^ *+' conftest.err >conftest.er1 1940 cat conftest.er1 >&5 1941 mv -f conftest.er1 conftest.err 1942 fi 1943 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1944 test $ac_status = 0; } && { 1945 test -z "$ac_c_werror_flag" || 1946 test ! -s conftest.err 1947 } && test -s conftest.$ac_objext; then : 1948 ac_retval=0 1949 else 1950 $as_echo "$as_me: failed program was:" >&5 1951 sed 's/^/| /' conftest.$ac_ext >&5 1952 1953 ac_retval=1 1954 fi 1955 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1956 as_fn_set_status $ac_retval 1957 1958 } # ac_fn_c_try_compile 1959 1960 # ac_fn_cxx_try_compile LINENO 1961 # ---------------------------- 1962 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1963 ac_fn_cxx_try_compile () 1964 { 1965 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1966 rm -f conftest.$ac_objext 1967 if { { ac_try="$ac_compile" 1968 case "(($ac_try" in 1969 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1970 *) ac_try_echo=$ac_try;; 1971 esac 1972 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1973 $as_echo "$ac_try_echo"; } >&5 1974 (eval "$ac_compile") 2>conftest.err 1975 ac_status=$? 1976 if test -s conftest.err; then 1977 grep -v '^ *+' conftest.err >conftest.er1 1978 cat conftest.er1 >&5 1979 mv -f conftest.er1 conftest.err 1980 fi 1981 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1982 test $ac_status = 0; } && { 1983 test -z "$ac_cxx_werror_flag" || 1984 test ! -s conftest.err 1985 } && test -s conftest.$ac_objext; then : 1986 ac_retval=0 1987 else 1988 $as_echo "$as_me: failed program was:" >&5 1989 sed 's/^/| /' conftest.$ac_ext >&5 1990 1991 ac_retval=1 1992 fi 1993 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1994 as_fn_set_status $ac_retval 1995 1996 } # ac_fn_cxx_try_compile 1997 1998 # ac_fn_objc_try_compile LINENO 1999 # ----------------------------- 2000 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2001 ac_fn_objc_try_compile () 2002 { 2003 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2004 rm -f conftest.$ac_objext 2005 if { { ac_try="$ac_compile" 2006 case "(($ac_try" in 2007 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2008 *) ac_try_echo=$ac_try;; 2009 esac 2010 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2011 $as_echo "$ac_try_echo"; } >&5 2012 (eval "$ac_compile") 2>conftest.err 2013 ac_status=$? 2014 if test -s conftest.err; then 2015 grep -v '^ *+' conftest.err >conftest.er1 2016 cat conftest.er1 >&5 2017 mv -f conftest.er1 conftest.err 2018 fi 2019 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2020 test $ac_status = 0; } && { 2021 test -z "$ac_objc_werror_flag" || 2022 test ! -s conftest.err 2023 } && test -s conftest.$ac_objext; then : 2024 ac_retval=0 2025 else 2026 $as_echo "$as_me: failed program was:" >&5 2027 sed 's/^/| /' conftest.$ac_ext >&5 2028 2029 ac_retval=1 2030 fi 2031 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2032 as_fn_set_status $ac_retval 2033 2034 } # ac_fn_objc_try_compile 2035 2036 # ac_fn_c_try_cpp LINENO 2037 # ---------------------- 2038 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2039 ac_fn_c_try_cpp () 2040 { 2041 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2042 if { { ac_try="$ac_cpp conftest.$ac_ext" 2043 case "(($ac_try" in 2044 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2045 *) ac_try_echo=$ac_try;; 2046 esac 2047 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2048 $as_echo "$ac_try_echo"; } >&5 2049 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2050 ac_status=$? 2051 if test -s conftest.err; then 2052 grep -v '^ *+' conftest.err >conftest.er1 2053 cat conftest.er1 >&5 2054 mv -f conftest.er1 conftest.err 2055 fi 2056 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2057 test $ac_status = 0; } > conftest.i && { 2058 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2059 test ! -s conftest.err 2060 }; then : 2061 ac_retval=0 2062 else 2063 $as_echo "$as_me: failed program was:" >&5 2064 sed 's/^/| /' conftest.$ac_ext >&5 2065 2066 ac_retval=1 2067 fi 2068 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2069 as_fn_set_status $ac_retval 2070 2071 } # ac_fn_c_try_cpp 2072 2073 # ac_fn_cxx_try_cpp LINENO 2074 # ------------------------ 2075 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2076 ac_fn_cxx_try_cpp () 2077 { 2078 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2079 if { { ac_try="$ac_cpp conftest.$ac_ext" 2080 case "(($ac_try" in 2081 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2082 *) ac_try_echo=$ac_try;; 2083 esac 2084 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2085 $as_echo "$ac_try_echo"; } >&5 2086 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2087 ac_status=$? 2088 if test -s conftest.err; then 2089 grep -v '^ *+' conftest.err >conftest.er1 2090 cat conftest.er1 >&5 2091 mv -f conftest.er1 conftest.err 2092 fi 2093 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2094 test $ac_status = 0; } > conftest.i && { 2095 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2096 test ! -s conftest.err 2097 }; then : 2098 ac_retval=0 2099 else 2100 $as_echo "$as_me: failed program was:" >&5 2101 sed 's/^/| /' conftest.$ac_ext >&5 2102 2103 ac_retval=1 2104 fi 2105 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2106 as_fn_set_status $ac_retval 2107 2108 } # ac_fn_cxx_try_cpp 2109 2110 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2111 # --------------------------------------------------------- 2112 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2113 # the include files in INCLUDES and setting the cache variable VAR 2114 # accordingly. 2115 ac_fn_cxx_check_header_mongrel () 2116 { 2117 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2118 if eval \${$3+:} false; then : 2119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2120 $as_echo_n "checking for $2... " >&6; } 2121 if eval \${$3+:} false; then : 2122 $as_echo_n "(cached) " >&6 2123 fi 2124 eval ac_res=\$$3 2125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2126 $as_echo "$ac_res" >&6; } 2127 else 2128 # Is the header compilable? 2129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2130 $as_echo_n "checking $2 usability... " >&6; } 2131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2132 /* end confdefs.h. */ 2133 $4 2134 #include <$2> 2135 _ACEOF 2136 if ac_fn_cxx_try_compile "$LINENO"; then : 2137 ac_header_compiler=yes 2138 else 2139 ac_header_compiler=no 2140 fi 2141 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2143 $as_echo "$ac_header_compiler" >&6; } 2144 2145 # Is the header present? 2146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2147 $as_echo_n "checking $2 presence... " >&6; } 2148 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2149 /* end confdefs.h. */ 2150 #include <$2> 2151 _ACEOF 2152 if ac_fn_cxx_try_cpp "$LINENO"; then : 2153 ac_header_preproc=yes 2154 else 2155 ac_header_preproc=no 2156 fi 2157 rm -f conftest.err conftest.i conftest.$ac_ext 2158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2159 $as_echo "$ac_header_preproc" >&6; } 2160 2161 # So? What about this header? 2162 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2163 yes:no: ) 2164 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2165 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2166 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2167 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2168 ;; 2169 no:yes:* ) 2170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2171 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2173 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2174 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2175 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2176 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2177 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2178 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2179 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2180 ( $as_echo "## ----------------------------------------- ## 2181 ## Report this to build-dev@openjdk.java.net ## 2182 ## ----------------------------------------- ##" 2183 ) | sed "s/^/$as_me: WARNING: /" >&2 2184 ;; 2185 esac 2186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2187 $as_echo_n "checking for $2... " >&6; } 2188 if eval \${$3+:} false; then : 2189 $as_echo_n "(cached) " >&6 2190 else 2191 eval "$3=\$ac_header_compiler" 2192 fi 2193 eval ac_res=\$$3 2194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2195 $as_echo "$ac_res" >&6; } 2196 fi 2197 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2198 2199 } # ac_fn_cxx_check_header_mongrel 2200 2201 # ac_fn_cxx_try_run LINENO 2202 # ------------------------ 2203 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2204 # that executables *can* be run. 2205 ac_fn_cxx_try_run () 2206 { 2207 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2208 if { { ac_try="$ac_link" 2209 case "(($ac_try" in 2210 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2211 *) ac_try_echo=$ac_try;; 2212 esac 2213 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2214 $as_echo "$ac_try_echo"; } >&5 2215 (eval "$ac_link") 2>&5 2216 ac_status=$? 2217 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2218 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2219 { { case "(($ac_try" in 2220 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2221 *) ac_try_echo=$ac_try;; 2222 esac 2223 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2224 $as_echo "$ac_try_echo"; } >&5 2225 (eval "$ac_try") 2>&5 2226 ac_status=$? 2227 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2228 test $ac_status = 0; }; }; then : 2229 ac_retval=0 2230 else 2231 $as_echo "$as_me: program exited with status $ac_status" >&5 2232 $as_echo "$as_me: failed program was:" >&5 2233 sed 's/^/| /' conftest.$ac_ext >&5 2234 2235 ac_retval=$ac_status 2236 fi 2237 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2238 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2239 as_fn_set_status $ac_retval 2240 2241 } # ac_fn_cxx_try_run 2242 2243 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2244 # --------------------------------------------------------- 2245 # Tests whether HEADER exists and can be compiled using the include files in 2246 # INCLUDES, setting the cache variable VAR accordingly. 2247 ac_fn_cxx_check_header_compile () 2248 { 2249 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2251 $as_echo_n "checking for $2... " >&6; } 2252 if eval \${$3+:} false; then : 2253 $as_echo_n "(cached) " >&6 2254 else 2255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2256 /* end confdefs.h. */ 2257 $4 2258 #include <$2> 2259 _ACEOF 2260 if ac_fn_cxx_try_compile "$LINENO"; then : 2261 eval "$3=yes" 2262 else 2263 eval "$3=no" 2264 fi 2265 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2266 fi 2267 eval ac_res=\$$3 2268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2269 $as_echo "$ac_res" >&6; } 2270 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2271 2272 } # ac_fn_cxx_check_header_compile 2273 2274 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2275 # ---------------------------------------------- 2276 # Tries to find the compile-time value of EXPR in a program that includes 2277 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2278 # computed 2279 ac_fn_cxx_compute_int () 2280 { 2281 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2282 if test "$cross_compiling" = yes; then 2283 # Depending upon the size, compute the lo and hi bounds. 2284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2285 /* end confdefs.h. */ 2286 $4 2287 int 2288 main () 2289 { 2290 static int test_array [1 - 2 * !(($2) >= 0)]; 2291 test_array [0] = 0 2292 2293 ; 2294 return 0; 2295 } 2296 _ACEOF 2297 if ac_fn_cxx_try_compile "$LINENO"; then : 2298 ac_lo=0 ac_mid=0 2299 while :; do 2300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2301 /* end confdefs.h. */ 2302 $4 2303 int 2304 main () 2305 { 2306 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2307 test_array [0] = 0 2308 2309 ; 2310 return 0; 2311 } 2312 _ACEOF 2313 if ac_fn_cxx_try_compile "$LINENO"; then : 2314 ac_hi=$ac_mid; break 2315 else 2316 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2317 if test $ac_lo -le $ac_mid; then 2318 ac_lo= ac_hi= 2319 break 2320 fi 2321 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2322 fi 2323 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2324 done 2325 else 2326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2327 /* end confdefs.h. */ 2328 $4 2329 int 2330 main () 2331 { 2332 static int test_array [1 - 2 * !(($2) < 0)]; 2333 test_array [0] = 0 2334 2335 ; 2336 return 0; 2337 } 2338 _ACEOF 2339 if ac_fn_cxx_try_compile "$LINENO"; then : 2340 ac_hi=-1 ac_mid=-1 2341 while :; do 2342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2343 /* end confdefs.h. */ 2344 $4 2345 int 2346 main () 2347 { 2348 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2349 test_array [0] = 0 2350 2351 ; 2352 return 0; 2353 } 2354 _ACEOF 2355 if ac_fn_cxx_try_compile "$LINENO"; then : 2356 ac_lo=$ac_mid; break 2357 else 2358 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2359 if test $ac_mid -le $ac_hi; then 2360 ac_lo= ac_hi= 2361 break 2362 fi 2363 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2364 fi 2365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2366 done 2367 else 2368 ac_lo= ac_hi= 2369 fi 2370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2371 fi 2372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2373 # Binary search between lo and hi bounds. 2374 while test "x$ac_lo" != "x$ac_hi"; do 2375 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2377 /* end confdefs.h. */ 2378 $4 2379 int 2380 main () 2381 { 2382 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2383 test_array [0] = 0 2384 2385 ; 2386 return 0; 2387 } 2388 _ACEOF 2389 if ac_fn_cxx_try_compile "$LINENO"; then : 2390 ac_hi=$ac_mid 2391 else 2392 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2393 fi 2394 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2395 done 2396 case $ac_lo in #(( 2397 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2398 '') ac_retval=1 ;; 2399 esac 2400 else 2401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2402 /* end confdefs.h. */ 2403 $4 2404 static long int longval () { return $2; } 2405 static unsigned long int ulongval () { return $2; } 2406 #include <stdio.h> 2407 #include <stdlib.h> 2408 int 2409 main () 2410 { 2411 2412 FILE *f = fopen ("conftest.val", "w"); 2413 if (! f) 2414 return 1; 2415 if (($2) < 0) 2416 { 2417 long int i = longval (); 2418 if (i != ($2)) 2419 return 1; 2420 fprintf (f, "%ld", i); 2421 } 2422 else 2423 { 2424 unsigned long int i = ulongval (); 2425 if (i != ($2)) 2426 return 1; 2427 fprintf (f, "%lu", i); 2428 } 2429 /* Do not output a trailing newline, as this causes \r\n confusion 2430 on some platforms. */ 2431 return ferror (f) || fclose (f) != 0; 2432 2433 ; 2434 return 0; 2435 } 2436 _ACEOF 2437 if ac_fn_cxx_try_run "$LINENO"; then : 2438 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2439 else 2440 ac_retval=1 2441 fi 2442 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2443 conftest.$ac_objext conftest.beam conftest.$ac_ext 2444 rm -f conftest.val 2445 2446 fi 2447 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2448 as_fn_set_status $ac_retval 2449 2450 } # ac_fn_cxx_compute_int 2451 2452 # ac_fn_cxx_try_link LINENO 2453 # ------------------------- 2454 # Try to link conftest.$ac_ext, and return whether this succeeded. 2455 ac_fn_cxx_try_link () 2456 { 2457 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2458 rm -f conftest.$ac_objext conftest$ac_exeext 2459 if { { ac_try="$ac_link" 2460 case "(($ac_try" in 2461 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2462 *) ac_try_echo=$ac_try;; 2463 esac 2464 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2465 $as_echo "$ac_try_echo"; } >&5 2466 (eval "$ac_link") 2>conftest.err 2467 ac_status=$? 2468 if test -s conftest.err; then 2469 grep -v '^ *+' conftest.err >conftest.er1 2470 cat conftest.er1 >&5 2471 mv -f conftest.er1 conftest.err 2472 fi 2473 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2474 test $ac_status = 0; } && { 2475 test -z "$ac_cxx_werror_flag" || 2476 test ! -s conftest.err 2477 } && test -s conftest$ac_exeext && { 2478 test "$cross_compiling" = yes || 2479 $as_test_x conftest$ac_exeext 2480 }; then : 2481 ac_retval=0 2482 else 2483 $as_echo "$as_me: failed program was:" >&5 2484 sed 's/^/| /' conftest.$ac_ext >&5 2485 2486 ac_retval=1 2487 fi 2488 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2489 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2490 # interfere with the next link command; also delete a directory that is 2491 # left behind by Apple's compiler. We do this before executing the actions. 2492 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2493 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2494 as_fn_set_status $ac_retval 2495 2496 } # ac_fn_cxx_try_link 2497 2498 # ac_fn_cxx_check_func LINENO FUNC VAR 2499 # ------------------------------------ 2500 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2501 ac_fn_cxx_check_func () 2502 { 2503 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2505 $as_echo_n "checking for $2... " >&6; } 2506 if eval \${$3+:} false; then : 2507 $as_echo_n "(cached) " >&6 2508 else 2509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2510 /* end confdefs.h. */ 2511 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2512 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2513 #define $2 innocuous_$2 2514 2515 /* System header to define __stub macros and hopefully few prototypes, 2516 which can conflict with char $2 (); below. 2517 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2518 <limits.h> exists even on freestanding compilers. */ 2519 2520 #ifdef __STDC__ 2521 # include <limits.h> 2522 #else 2523 # include <assert.h> 2524 #endif 2525 2526 #undef $2 2527 2528 /* Override any GCC internal prototype to avoid an error. 2529 Use char because int might match the return type of a GCC 2530 builtin and then its argument prototype would still apply. */ 2531 #ifdef __cplusplus 2532 extern "C" 2533 #endif 2534 char $2 (); 2535 /* The GNU C library defines this for functions which it implements 2536 to always fail with ENOSYS. Some functions are actually named 2537 something starting with __ and the normal name is an alias. */ 2538 #if defined __stub_$2 || defined __stub___$2 2539 choke me 2540 #endif 2541 2542 int 2543 main () 2544 { 2545 return $2 (); 2546 ; 2547 return 0; 2548 } 2549 _ACEOF 2550 if ac_fn_cxx_try_link "$LINENO"; then : 2551 eval "$3=yes" 2552 else 2553 eval "$3=no" 2554 fi 2555 rm -f core conftest.err conftest.$ac_objext \ 2556 conftest$ac_exeext conftest.$ac_ext 2557 fi 2558 eval ac_res=\$$3 2559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2560 $as_echo "$ac_res" >&6; } 2561 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2562 2563 } # ac_fn_cxx_check_func 2564 2565 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 2566 # ------------------------------------------------------- 2567 # Tests whether HEADER exists and can be compiled using the include files in 2568 # INCLUDES, setting the cache variable VAR accordingly. 2569 ac_fn_c_check_header_compile () 2570 { 2571 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2573 $as_echo_n "checking for $2... " >&6; } 2574 if eval \${$3+:} false; then : 2575 $as_echo_n "(cached) " >&6 2576 else 2577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2578 /* end confdefs.h. */ 2579 $4 2580 #include <$2> 2581 _ACEOF 2582 if ac_fn_c_try_compile "$LINENO"; then : 2583 eval "$3=yes" 2584 else 2585 eval "$3=no" 2586 fi 2587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2588 fi 2589 eval ac_res=\$$3 2590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2591 $as_echo "$ac_res" >&6; } 2592 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2593 2594 } # ac_fn_c_check_header_compile 2595 cat >config.log <<_ACEOF 2596 This file contains any messages produced by compilers while 2597 running configure, to aid debugging if configure makes a mistake. 2598 2599 It was created by OpenJDK $as_me jdk8, which was 2600 generated by GNU Autoconf 2.68. Invocation command line was 2601 2602 $ $0 $@ 2603 2604 _ACEOF 2605 exec 5>>config.log 2606 { 2607 cat <<_ASUNAME 2608 ## --------- ## 2609 ## Platform. ## 2610 ## --------- ## 2611 2612 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 2613 uname -m = `(uname -m) 2>/dev/null || echo unknown` 2614 uname -r = `(uname -r) 2>/dev/null || echo unknown` 2615 uname -s = `(uname -s) 2>/dev/null || echo unknown` 2616 uname -v = `(uname -v) 2>/dev/null || echo unknown` 2617 2618 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 2619 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 2620 2621 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 2622 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 2623 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 2624 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 2625 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 2626 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 2627 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 2628 2629 _ASUNAME 2630 2631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2632 for as_dir in $PATH 2633 do 2634 IFS=$as_save_IFS 2635 test -z "$as_dir" && as_dir=. 2636 $as_echo "PATH: $as_dir" 2637 done 2638 IFS=$as_save_IFS 2639 2640 } >&5 2641 2642 cat >&5 <<_ACEOF 2643 2644 2645 ## ----------- ## 2646 ## Core tests. ## 2647 ## ----------- ## 2648 2649 _ACEOF 2650 2651 2652 # Keep a trace of the command line. 2653 # Strip out --no-create and --no-recursion so they do not pile up. 2654 # Strip out --silent because we don't want to record it for future runs. 2655 # Also quote any args containing shell meta-characters. 2656 # Make two passes to allow for proper duplicate-argument suppression. 2657 ac_configure_args= 2658 ac_configure_args0= 2659 ac_configure_args1= 2660 ac_must_keep_next=false 2661 for ac_pass in 1 2 2662 do 2663 for ac_arg 2664 do 2665 case $ac_arg in 2666 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 2667 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 2668 | -silent | --silent | --silen | --sile | --sil) 2669 continue ;; 2670 *\'*) 2671 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 2672 esac 2673 case $ac_pass in 2674 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2675 2) 2676 as_fn_append ac_configure_args1 " '$ac_arg'" 2677 if test $ac_must_keep_next = true; then 2678 ac_must_keep_next=false # Got value, back to normal. 2679 else 2680 case $ac_arg in 2681 *=* | --config-cache | -C | -disable-* | --disable-* \ 2682 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 2683 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 2684 | -with-* | --with-* | -without-* | --without-* | --x) 2685 case "$ac_configure_args0 " in 2686 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 2687 esac 2688 ;; 2689 -* ) ac_must_keep_next=true ;; 2690 esac 2691 fi 2692 as_fn_append ac_configure_args " '$ac_arg'" 2693 ;; 2694 esac 2695 done 2696 done 2697 { ac_configure_args0=; unset ac_configure_args0;} 2698 { ac_configure_args1=; unset ac_configure_args1;} 2699 2700 # When interrupted or exit'd, cleanup temporary files, and complete 2701 # config.log. We remove comments because anyway the quotes in there 2702 # would cause problems or look ugly. 2703 # WARNING: Use '\'' to represent an apostrophe within the trap. 2704 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 2705 trap 'exit_status=$? 2706 # Save into config.log some information that might help in debugging. 2707 { 2708 echo 2709 2710 $as_echo "## ---------------- ## 2711 ## Cache variables. ## 2712 ## ---------------- ##" 2713 echo 2714 # The following way of writing the cache mishandles newlines in values, 2715 ( 2716 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 2717 eval ac_val=\$$ac_var 2718 case $ac_val in #( 2719 *${as_nl}*) 2720 case $ac_var in #( 2721 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 2722 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 2723 esac 2724 case $ac_var in #( 2725 _ | IFS | as_nl) ;; #( 2726 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 2727 *) { eval $ac_var=; unset $ac_var;} ;; 2728 esac ;; 2729 esac 2730 done 2731 (set) 2>&1 | 2732 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 2733 *${as_nl}ac_space=\ *) 2734 sed -n \ 2735 "s/'\''/'\''\\\\'\'''\''/g; 2736 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 2737 ;; #( 2738 *) 2739 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 2740 ;; 2741 esac | 2742 sort 2743 ) 2744 echo 2745 2746 $as_echo "## ----------------- ## 2747 ## Output variables. ## 2748 ## ----------------- ##" 2749 echo 2750 for ac_var in $ac_subst_vars 2751 do 2752 eval ac_val=\$$ac_var 2753 case $ac_val in 2754 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2755 esac 2756 $as_echo "$ac_var='\''$ac_val'\''" 2757 done | sort 2758 echo 2759 2760 if test -n "$ac_subst_files"; then 2761 $as_echo "## ------------------- ## 2762 ## File substitutions. ## 2763 ## ------------------- ##" 2764 echo 2765 for ac_var in $ac_subst_files 2766 do 2767 eval ac_val=\$$ac_var 2768 case $ac_val in 2769 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2770 esac 2771 $as_echo "$ac_var='\''$ac_val'\''" 2772 done | sort 2773 echo 2774 fi 2775 2776 if test -s confdefs.h; then 2777 $as_echo "## ----------- ## 2778 ## confdefs.h. ## 2779 ## ----------- ##" 2780 echo 2781 cat confdefs.h 2782 echo 2783 fi 2784 test "$ac_signal" != 0 && 2785 $as_echo "$as_me: caught signal $ac_signal" 2786 $as_echo "$as_me: exit $exit_status" 2787 } >&5 2788 rm -f core *.core core.conftest.* && 2789 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 2790 exit $exit_status 2791 ' 0 2792 for ac_signal in 1 2 13 15; do 2793 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 2794 done 2795 ac_signal=0 2796 2797 # confdefs.h avoids OS command line length limits that DEFS can exceed. 2798 rm -f -r conftest* confdefs.h 2799 2800 $as_echo "/* confdefs.h */" > confdefs.h 2801 2802 # Predefined preprocessor variables. 2803 2804 cat >>confdefs.h <<_ACEOF 2805 #define PACKAGE_NAME "$PACKAGE_NAME" 2806 _ACEOF 2807 2808 cat >>confdefs.h <<_ACEOF 2809 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 2810 _ACEOF 2811 2812 cat >>confdefs.h <<_ACEOF 2813 #define PACKAGE_VERSION "$PACKAGE_VERSION" 2814 _ACEOF 2815 2816 cat >>confdefs.h <<_ACEOF 2817 #define PACKAGE_STRING "$PACKAGE_STRING" 2818 _ACEOF 2819 2820 cat >>confdefs.h <<_ACEOF 2821 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 2822 _ACEOF 2823 2824 cat >>confdefs.h <<_ACEOF 2825 #define PACKAGE_URL "$PACKAGE_URL" 2826 _ACEOF 2827 2828 2829 # Let the site file select an alternate cache file if it wants to. 2830 # Prefer an explicitly selected file to automatically selected ones. 2831 ac_site_file1=NONE 2832 ac_site_file2=NONE 2833 if test -n "$CONFIG_SITE"; then 2834 # We do not want a PATH search for config.site. 2835 case $CONFIG_SITE in #(( 2836 -*) ac_site_file1=./$CONFIG_SITE;; 2837 */*) ac_site_file1=$CONFIG_SITE;; 2838 *) ac_site_file1=./$CONFIG_SITE;; 2839 esac 2840 elif test "x$prefix" != xNONE; then 2841 ac_site_file1=$prefix/share/config.site 2842 ac_site_file2=$prefix/etc/config.site 2843 else 2844 ac_site_file1=$ac_default_prefix/share/config.site 2845 ac_site_file2=$ac_default_prefix/etc/config.site 2846 fi 2847 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 2848 do 2849 test "x$ac_site_file" = xNONE && continue 2850 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 2851 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 2852 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 2853 sed 's/^/| /' "$ac_site_file" >&5 2854 . "$ac_site_file" \ 2855 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2856 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2857 as_fn_error $? "failed to load site script $ac_site_file 2858 See \`config.log' for more details" "$LINENO" 5; } 2859 fi 2860 done 2861 2862 if test -r "$cache_file"; then 2863 # Some versions of bash will fail to source /dev/null (special files 2864 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 2865 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 2866 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 2867 $as_echo "$as_me: loading cache $cache_file" >&6;} 2868 case $cache_file in 2869 [\\/]* | ?:[\\/]* ) . "$cache_file";; 2870 *) . "./$cache_file";; 2871 esac 2872 fi 2873 else 2874 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 2875 $as_echo "$as_me: creating cache $cache_file" >&6;} 2876 >$cache_file 2877 fi 2878 2879 # Check that the precious variables saved in the cache have kept the same 2880 # value. 2881 ac_cache_corrupted=false 2882 for ac_var in $ac_precious_vars; do 2883 eval ac_old_set=\$ac_cv_env_${ac_var}_set 2884 eval ac_new_set=\$ac_env_${ac_var}_set 2885 eval ac_old_val=\$ac_cv_env_${ac_var}_value 2886 eval ac_new_val=\$ac_env_${ac_var}_value 2887 case $ac_old_set,$ac_new_set in 2888 set,) 2889 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 2890 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 2891 ac_cache_corrupted=: ;; 2892 ,set) 2893 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 2894 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 2895 ac_cache_corrupted=: ;; 2896 ,);; 2897 *) 2898 if test "x$ac_old_val" != "x$ac_new_val"; then 2899 # differences in whitespace do not lead to failure. 2900 ac_old_val_w=`echo x $ac_old_val` 2901 ac_new_val_w=`echo x $ac_new_val` 2902 if test "$ac_old_val_w" != "$ac_new_val_w"; then 2903 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 2904 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 2905 ac_cache_corrupted=: 2906 else 2907 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 2908 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 2909 eval $ac_var=\$ac_old_val 2910 fi 2911 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 2912 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 2913 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 2914 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 2915 fi;; 2916 esac 2917 # Pass precious variables to config.status. 2918 if test "$ac_new_set" = set; then 2919 case $ac_new_val in 2920 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 2921 *) ac_arg=$ac_var=$ac_new_val ;; 2922 esac 2923 case " $ac_configure_args " in 2924 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 2925 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 2926 esac 2927 fi 2928 done 2929 if $ac_cache_corrupted; then 2930 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2931 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2932 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 2933 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 2934 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 2935 fi 2936 ## -------------------- ## 2937 ## Main body of script. ## 2938 ## -------------------- ## 2939 2940 ac_ext=c 2941 ac_cpp='$CPP $CPPFLAGS' 2942 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 2943 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 2944 ac_compiler_gnu=$ac_cv_c_compiler_gnu 2945 2946 2947 2948 ac_aux_dir= 2949 for ac_dir in build-aux "$srcdir"/build-aux; do 2950 if test -f "$ac_dir/install-sh"; then 2951 ac_aux_dir=$ac_dir 2952 ac_install_sh="$ac_aux_dir/install-sh -c" 2953 break 2954 elif test -f "$ac_dir/install.sh"; then 2955 ac_aux_dir=$ac_dir 2956 ac_install_sh="$ac_aux_dir/install.sh -c" 2957 break 2958 elif test -f "$ac_dir/shtool"; then 2959 ac_aux_dir=$ac_dir 2960 ac_install_sh="$ac_aux_dir/shtool install -c" 2961 break 2962 fi 2963 done 2964 if test -z "$ac_aux_dir"; then 2965 as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5 2966 fi 2967 2968 # These three variables are undocumented and unsupported, 2969 # and are intended to be withdrawn in a future Autoconf release. 2970 # They can cause serious problems if a builder's source tree is in a directory 2971 # whose full name contains unusual characters. 2972 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 2973 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 2974 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 2975 2976 2977 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 2978 2979 # 2980 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 2981 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 2982 # 2983 # This code is free software; you can redistribute it and/or modify it 2984 # under the terms of the GNU General Public License version 2 only, as 2985 # published by the Free Software Foundation. Oracle designates this 2986 # particular file as subject to the "Classpath" exception as provided 2987 # by Oracle in the LICENSE file that accompanied this code. 2988 # 2989 # This code is distributed in the hope that it will be useful, but WITHOUT 2990 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 2991 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 2992 # version 2 for more details (a copy is included in the LICENSE file that 2993 # accompanied this code). 2994 # 2995 # You should have received a copy of the GNU General Public License version 2996 # 2 along with this work; if not, write to the Free Software Foundation, 2997 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2998 # 2999 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3000 # or visit www.oracle.com if you need additional information or have any 3001 # questions. 3002 # 3003 3004 # 3005 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3006 # 3007 # This program is free software; you can redistribute it and/or modify 3008 # it under the terms of the GNU General Public License as published by 3009 # the Free Software Foundation; either version 2 of the License, or 3010 # (at your option) any later version. 3011 # 3012 # This program is distributed in the hope that it will be useful, but 3013 # WITHOUT ANY WARRANTY; without even the implied warranty of 3014 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3015 # General Public License for more details. 3016 # 3017 # You should have received a copy of the GNU General Public License 3018 # along with this program; if not, write to the Free Software 3019 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3020 # 3021 # As a special exception to the GNU General Public License, if you 3022 # distribute this file as part of a program that contains a 3023 # configuration script generated by Autoconf, you may include it under 3024 # the same distribution terms that you use for the rest of that program. 3025 3026 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3027 # ---------------------------------- 3028 # PKG_PROG_PKG_CONFIG 3029 3030 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3031 # 3032 # Check to see whether a particular set of modules exists. Similar 3033 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3034 # 3035 # 3036 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3037 # this or PKG_CHECK_MODULES is called, or make sure to call 3038 # PKG_CHECK_EXISTS manually 3039 # -------------------------------------------------------------- 3040 3041 3042 3043 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3044 # --------------------------------------------- 3045 # _PKG_CONFIG 3046 3047 # _PKG_SHORT_ERRORS_SUPPORTED 3048 # ----------------------------- 3049 # _PKG_SHORT_ERRORS_SUPPORTED 3050 3051 3052 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3053 # [ACTION-IF-NOT-FOUND]) 3054 # 3055 # 3056 # Note that if there is a possibility the first call to 3057 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3058 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3059 # 3060 # 3061 # -------------------------------------------------------------- 3062 # PKG_CHECK_MODULES 3063 3064 3065 # Include these first... 3066 # 3067 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. 3068 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3069 # 3070 # This code is free software; you can redistribute it and/or modify it 3071 # under the terms of the GNU General Public License version 2 only, as 3072 # published by the Free Software Foundation. Oracle designates this 3073 # particular file as subject to the "Classpath" exception as provided 3074 # by Oracle in the LICENSE file that accompanied this code. 3075 # 3076 # This code is distributed in the hope that it will be useful, but WITHOUT 3077 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3078 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3079 # version 2 for more details (a copy is included in the LICENSE file that 3080 # accompanied this code). 3081 # 3082 # You should have received a copy of the GNU General Public License version 3083 # 2 along with this work; if not, write to the Free Software Foundation, 3084 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3085 # 3086 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3087 # or visit www.oracle.com if you need additional information or have any 3088 # questions. 3089 # 3090 3091 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3092 # If so, then append $1 to $2\ 3093 # Also set JVM_ARG_OK to true/false depending on outcome. 3094 3095 3096 # Appends a string to a path variable, only adding the : when needed. 3097 3098 3099 # This will make sure the given variable points to a full and proper 3100 # path. This means: 3101 # 1) There will be no spaces in the path. On posix platforms, 3102 # spaces in the path will result in an error. On Windows, 3103 # the path will be rewritten using short-style to be space-free. 3104 # 2) The path will be absolute, and it will be in unix-style (on 3105 # cygwin). 3106 # $1: The name of the variable to fix 3107 3108 3109 # This will make sure the given variable points to a executable 3110 # with a full and proper path. This means: 3111 # 1) There will be no spaces in the path. On posix platforms, 3112 # spaces in the path will result in an error. On Windows, 3113 # the path will be rewritten using short-style to be space-free. 3114 # 2) The path will be absolute, and it will be in unix-style (on 3115 # cygwin). 3116 # Any arguments given to the executable is preserved. 3117 # If the input variable does not have a directory specification, then 3118 # it need to be in the PATH. 3119 # $1: The name of the variable to fix 3120 3121 3122 3123 3124 3125 3126 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3127 # $1: variable to check 3128 # $2: executable name to print in warning (optional) 3129 3130 3131 # Does AC_PATH_PROG followed by BASIC_CHECK_NONEMPTY. 3132 # Arguments as AC_PATH_PROG: 3133 # $1: variable to set 3134 # $2: executable name to look for 3135 3136 3137 # Setup the most fundamental tools that relies on not much else to set up, 3138 # but is used by much of the early bootstrap code. 3139 3140 3141 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3142 3143 3144 3145 3146 3147 3148 3149 #%%% Simple tools %%% 3150 3151 # Check if we have found a usable version of make 3152 # $1: the path to a potential make binary (or empty) 3153 # $2: the description on how we found this 3154 3155 3156 # Goes looking for a usable version of GNU make. 3157 3158 3159 3160 3161 3162 3163 # Check if build directory is on local disk. If not possible to determine, 3164 # we prefer to claim it's local. 3165 # Argument 1: directory to test 3166 # Argument 2: what to do if it is on local disk 3167 # Argument 3: what to do otherwise (remote disk or failure) 3168 3169 3170 # Check that source files have basic read permissions set. This might 3171 # not be the case in cygwin in certain conditions. 3172 3173 3174 3175 3176 # 3177 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3178 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3179 # 3180 # This code is free software; you can redistribute it and/or modify it 3181 # under the terms of the GNU General Public License version 2 only, as 3182 # published by the Free Software Foundation. Oracle designates this 3183 # particular file as subject to the "Classpath" exception as provided 3184 # by Oracle in the LICENSE file that accompanied this code. 3185 # 3186 # This code is distributed in the hope that it will be useful, but WITHOUT 3187 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3188 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3189 # version 2 for more details (a copy is included in the LICENSE file that 3190 # accompanied this code). 3191 # 3192 # You should have received a copy of the GNU General Public License version 3193 # 2 along with this work; if not, write to the Free Software Foundation, 3194 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3195 # 3196 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3197 # or visit www.oracle.com if you need additional information or have any 3198 # questions. 3199 # 3200 3201 3202 3203 3204 3205 # Helper function which possibly converts a path using DOS-style short mode. 3206 # If so, the updated path is stored in $new_path. 3207 # $1: The path to check 3208 3209 3210 # Helper function which possibly converts a path using DOS-style short mode. 3211 # If so, the updated path is stored in $new_path. 3212 # $1: The path to check 3213 3214 3215 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3216 # and could probably be heavily simplified. However, all changes in this 3217 # area tend to need lot of testing in different scenarios, and in lack of 3218 # proper unit testing, cleaning this up has not been deemed worth the effort 3219 # at the moment. 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3230 3231 3232 3233 3234 # 3235 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3236 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3237 # 3238 # This code is free software; you can redistribute it and/or modify it 3239 # under the terms of the GNU General Public License version 2 only, as 3240 # published by the Free Software Foundation. Oracle designates this 3241 # particular file as subject to the "Classpath" exception as provided 3242 # by Oracle in the LICENSE file that accompanied this code. 3243 # 3244 # This code is distributed in the hope that it will be useful, but WITHOUT 3245 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3246 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3247 # version 2 for more details (a copy is included in the LICENSE file that 3248 # accompanied this code). 3249 # 3250 # You should have received a copy of the GNU General Public License version 3251 # 2 along with this work; if not, write to the Free Software Foundation, 3252 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3253 # 3254 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3255 # or visit www.oracle.com if you need additional information or have any 3256 # questions. 3257 # 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 # ... then the rest 3270 # 3271 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3272 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3273 # 3274 # This code is free software; you can redistribute it and/or modify it 3275 # under the terms of the GNU General Public License version 2 only, as 3276 # published by the Free Software Foundation. Oracle designates this 3277 # particular file as subject to the "Classpath" exception as provided 3278 # by Oracle in the LICENSE file that accompanied this code. 3279 # 3280 # This code is distributed in the hope that it will be useful, but WITHOUT 3281 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3282 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3283 # version 2 for more details (a copy is included in the LICENSE file that 3284 # accompanied this code). 3285 # 3286 # You should have received a copy of the GNU General Public License version 3287 # 2 along with this work; if not, write to the Free Software Foundation, 3288 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3289 # 3290 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3291 # or visit www.oracle.com if you need additional information or have any 3292 # questions. 3293 # 3294 3295 # Execute the check given as argument, and verify the result 3296 # If the Boot JDK was previously found, do nothing 3297 # $1 A command line (typically autoconf macro) to execute 3298 3299 3300 # Test: Is bootjdk explicitely set by command line arguments? 3301 3302 3303 # Test: Is bootjdk available from builddeps? 3304 3305 3306 # Test: Is $JAVA_HOME set? 3307 3308 3309 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3310 3311 3312 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3313 3314 3315 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3316 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3317 # $1 = Path to directory containing jdk installations. 3318 # $2 = String to append to the found JDK directory to get the proper JDK home 3319 3320 3321 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3322 # environmental variable as base for where to look. 3323 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3324 3325 3326 # Test: Is there a JDK installed in default, well-known locations? 3327 3328 3329 # Check that a command-line tool in the Boot JDK is correct 3330 # $1 = name of variable to assign 3331 # $2 = name of binary 3332 3333 3334 ############################################################################### 3335 # 3336 # We need a Boot JDK to bootstrap the build. 3337 # 3338 3339 3340 3341 3342 3343 # 3344 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3345 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3346 # 3347 # This code is free software; you can redistribute it and/or modify it 3348 # under the terms of the GNU General Public License version 2 only, as 3349 # published by the Free Software Foundation. Oracle designates this 3350 # particular file as subject to the "Classpath" exception as provided 3351 # by Oracle in the LICENSE file that accompanied this code. 3352 # 3353 # This code is distributed in the hope that it will be useful, but WITHOUT 3354 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3355 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3356 # version 2 for more details (a copy is included in the LICENSE file that 3357 # accompanied this code). 3358 # 3359 # You should have received a copy of the GNU General Public License version 3360 # 2 along with this work; if not, write to the Free Software Foundation, 3361 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3362 # 3363 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3364 # or visit www.oracle.com if you need additional information or have any 3365 # questions. 3366 # 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 # 3388 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3389 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3390 # 3391 # This code is free software; you can redistribute it and/or modify it 3392 # under the terms of the GNU General Public License version 2 only, as 3393 # published by the Free Software Foundation. Oracle designates this 3394 # particular file as subject to the "Classpath" exception as provided 3395 # by Oracle in the LICENSE file that accompanied this code. 3396 # 3397 # This code is distributed in the hope that it will be useful, but WITHOUT 3398 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3399 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3400 # version 2 for more details (a copy is included in the LICENSE file that 3401 # accompanied this code). 3402 # 3403 # You should have received a copy of the GNU General Public License version 3404 # 2 along with this work; if not, write to the Free Software Foundation, 3405 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3406 # 3407 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3408 # or visit www.oracle.com if you need additional information or have any 3409 # questions. 3410 # 3411 3412 3413 3414 3415 3416 cygwin_help() { 3417 case $1 in 3418 unzip) 3419 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip" ;; 3420 zip) 3421 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P zip" ;; 3422 make) 3423 PKGHANDLER_COMMAND="cd <location of cygwin setup.exe> && cmd /c setup -q -P make" ;; 3424 * ) 3425 break ;; 3426 esac 3427 } 3428 3429 apt_help() { 3430 case $1 in 3431 devkit) 3432 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 3433 openjdk) 3434 PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;; 3435 alsa) 3436 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 3437 cups) 3438 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 3439 freetype2) 3440 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 3441 pulse) 3442 PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;; 3443 x11) 3444 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev" ;; 3445 ccache) 3446 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 3447 * ) 3448 break ;; 3449 esac 3450 } 3451 3452 yum_help() { 3453 case $1 in 3454 devkit) 3455 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 3456 openjdk) 3457 PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;; 3458 alsa) 3459 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 3460 cups) 3461 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 3462 freetype2) 3463 PKGHANDLER_COMMAND="sudo yum install freetype2-devel" ;; 3464 pulse) 3465 PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;; 3466 x11) 3467 PKGHANDLER_COMMAND="sudo yum install libXtst-devel" ;; 3468 ccache) 3469 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 3470 * ) 3471 break ;; 3472 esac 3473 } 3474 3475 port_help() { 3476 PKGHANDLER_COMMAND="" 3477 } 3478 3479 pkgutil_help() { 3480 PKGHANDLER_COMMAND="" 3481 } 3482 3483 pkgadd_help() { 3484 PKGHANDLER_COMMAND="" 3485 } 3486 3487 3488 3489 # 3490 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved. 3491 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3492 # 3493 # This code is free software; you can redistribute it and/or modify it 3494 # under the terms of the GNU General Public License version 2 only, as 3495 # published by the Free Software Foundation. Oracle designates this 3496 # particular file as subject to the "Classpath" exception as provided 3497 # by Oracle in the LICENSE file that accompanied this code. 3498 # 3499 # This code is distributed in the hope that it will be useful, but WITHOUT 3500 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3501 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3502 # version 2 for more details (a copy is included in the LICENSE file that 3503 # accompanied this code). 3504 # 3505 # You should have received a copy of the GNU General Public License version 3506 # 2 along with this work; if not, write to the Free Software Foundation, 3507 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3508 # 3509 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3510 # or visit www.oracle.com if you need additional information or have any 3511 # questions. 3512 # 3513 3514 3515 3516 3517 3518 3519 3520 3521 ############################################################################### 3522 # 3523 # Should we build only OpenJDK even if closed sources are present? 3524 # 3525 3526 3527 3528 3529 ############################################################################### 3530 # 3531 # Setup version numbers 3532 # 3533 3534 3535 3536 3537 3538 3539 # Support for customization of the build process. Some build files 3540 # will include counterparts from this location, if they exist. This allows 3541 # for a degree of customization of the build targets and the rules/recipes 3542 # to create them 3543 3544 # Check whether --with-custom-make-dir was given. 3545 if test "${with_custom_make_dir+set}" = set; then : 3546 withval=$with_custom_make_dir; CUSTOM_MAKE_DIR=$with_custom_make_dir 3547 fi 3548 3549 3550 3551 # 3552 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3553 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3554 # 3555 # This code is free software; you can redistribute it and/or modify it 3556 # under the terms of the GNU General Public License version 2 only, as 3557 # published by the Free Software Foundation. Oracle designates this 3558 # particular file as subject to the "Classpath" exception as provided 3559 # by Oracle in the LICENSE file that accompanied this code. 3560 # 3561 # This code is distributed in the hope that it will be useful, but WITHOUT 3562 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3563 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3564 # version 2 for more details (a copy is included in the LICENSE file that 3565 # accompanied this code). 3566 # 3567 # You should have received a copy of the GNU General Public License version 3568 # 2 along with this work; if not, write to the Free Software Foundation, 3569 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3570 # 3571 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3572 # or visit www.oracle.com if you need additional information or have any 3573 # questions. 3574 # 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 # 3591 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3592 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3593 # 3594 # This code is free software; you can redistribute it and/or modify it 3595 # under the terms of the GNU General Public License version 2 only, as 3596 # published by the Free Software Foundation. Oracle designates this 3597 # particular file as subject to the "Classpath" exception as provided 3598 # by Oracle in the LICENSE file that accompanied this code. 3599 # 3600 # This code is distributed in the hope that it will be useful, but WITHOUT 3601 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3602 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3603 # version 2 for more details (a copy is included in the LICENSE file that 3604 # accompanied this code). 3605 # 3606 # You should have received a copy of the GNU General Public License version 3607 # 2 along with this work; if not, write to the Free Software Foundation, 3608 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3609 # 3610 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3611 # or visit www.oracle.com if you need additional information or have any 3612 # questions. 3613 # 3614 3615 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 3616 # Converts autoconf style CPU name to OpenJDK style, into 3617 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 3618 3619 3620 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 3621 # Converts autoconf style OS name to OpenJDK style, into 3622 # VAR_OS and VAR_OS_API. 3623 3624 3625 # Expects $host_os $host_cpu $build_os and $build_cpu 3626 # and $with_target_bits to have been setup! 3627 # 3628 # Translate the standard triplet(quadruplet) definition 3629 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 3630 # OPENJDK_BUILD_OS, etc. 3631 3632 3633 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 3634 # accordingly. Must be done after setting up build and target system, but before 3635 # doing anything else with these values. 3636 3637 3638 # Setup the legacy variables, for controlling the old makefiles. 3639 # 3640 3641 3642 3643 3644 #%%% Build and target systems %%% 3645 3646 3647 3648 3649 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 3650 # Add -mX to various FLAGS variables. 3651 3652 3653 3654 3655 3656 3657 # 3658 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3659 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3660 # 3661 # This code is free software; you can redistribute it and/or modify it 3662 # under the terms of the GNU General Public License version 2 only, as 3663 # published by the Free Software Foundation. Oracle designates this 3664 # particular file as subject to the "Classpath" exception as provided 3665 # by Oracle in the LICENSE file that accompanied this code. 3666 # 3667 # This code is distributed in the hope that it will be useful, but WITHOUT 3668 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3669 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3670 # version 2 for more details (a copy is included in the LICENSE file that 3671 # accompanied this code). 3672 # 3673 # You should have received a copy of the GNU General Public License version 3674 # 2 along with this work; if not, write to the Free Software Foundation, 3675 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3676 # 3677 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3678 # or visit www.oracle.com if you need additional information or have any 3679 # questions. 3680 # 3681 3682 3683 3684 3685 3686 3687 3688 3689 # 3690 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3691 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3692 # 3693 # This code is free software; you can redistribute it and/or modify it 3694 # under the terms of the GNU General Public License version 2 only, as 3695 # published by the Free Software Foundation. Oracle designates this 3696 # particular file as subject to the "Classpath" exception as provided 3697 # by Oracle in the LICENSE file that accompanied this code. 3698 # 3699 # This code is distributed in the hope that it will be useful, but WITHOUT 3700 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3701 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3702 # version 2 for more details (a copy is included in the LICENSE file that 3703 # accompanied this code). 3704 # 3705 # You should have received a copy of the GNU General Public License version 3706 # 2 along with this work; if not, write to the Free Software Foundation, 3707 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3708 # 3709 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3710 # or visit www.oracle.com if you need additional information or have any 3711 # questions. 3712 # 3713 3714 # $1 = compiler to test (CC or CXX) 3715 # $2 = human readable name of compiler (C or C++) 3716 3717 3718 3719 3720 3721 # $1 = compiler to test (CC or CXX) 3722 # $2 = human readable name of compiler (C or C++) 3723 # $3 = list of compiler names to search for 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 # TOOLCHAIN_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE], 3738 # [RUN-IF-FALSE]) 3739 # ------------------------------------------------------------ 3740 # Check that the c and c++ compilers support an argument 3741 3742 3743 3744 3745 # Setup the JTREG paths 3746 3747 3748 # 3749 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3750 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3751 # 3752 # This code is free software; you can redistribute it and/or modify it 3753 # under the terms of the GNU General Public License version 2 only, as 3754 # published by the Free Software Foundation. Oracle designates this 3755 # particular file as subject to the "Classpath" exception as provided 3756 # by Oracle in the LICENSE file that accompanied this code. 3757 # 3758 # This code is distributed in the hope that it will be useful, but WITHOUT 3759 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3760 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3761 # version 2 for more details (a copy is included in the LICENSE file that 3762 # accompanied this code). 3763 # 3764 # You should have received a copy of the GNU General Public License version 3765 # 2 along with this work; if not, write to the Free Software Foundation, 3766 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3767 # 3768 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3769 # or visit www.oracle.com if you need additional information or have any 3770 # questions. 3771 # 3772 3773 3774 3775 3776 3777 3778 3779 # Check if the VS env variables were setup prior to running configure. 3780 # If not, then find vcvarsall.bat and run it automatically, and integrate 3781 # the set env variables into the spec file. 3782 3783 3784 3785 # Setup the DXSDK paths 3786 3787 3788 3789 3790 3791 3792 # This line needs to be here, verbatim, after all includes and the dummy hook 3793 # definitions. It is replaced with custom functionality when building 3794 # custom sources. 3795 #CUSTOM_AUTOCONF_INCLUDE 3796 3797 # Do not change or remove the following line, it is needed for consistency checks: 3798 DATE_WHEN_GENERATED=@DATE_WHEN_GENERATED@ 3799 3800 ############################################################################### 3801 # 3802 # Initialization / Boot-strapping 3803 # 3804 # The bootstrapping process needs to solve the "chicken or the egg" problem, 3805 # thus it jumps back and forth, each time gaining something needed later on. 3806 # 3807 ############################################################################### 3808 3809 # Basic initialization that must happen first of all 3810 3811 # Save the original command line. This is passed to us by the wrapper configure script. 3812 3813 DATE_WHEN_CONFIGURED=`LANG=C date` 3814 3815 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 3816 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 3817 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 3818 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 3819 3820 3821 3822 # Start with tools that do not need have cross compilation support 3823 # and can be expected to be found in the default PATH. These tools are 3824 # used by configure. Nor are these tools expected to be found in the 3825 # devkit from the builddeps server either, since they are 3826 # needed to download the devkit. 3827 3828 # First are all the simple required tools. 3829 3830 for ac_prog in basename 3831 do 3832 # Extract the first word of "$ac_prog", so it can be a program name with args. 3833 set dummy $ac_prog; ac_word=$2 3834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3835 $as_echo_n "checking for $ac_word... " >&6; } 3836 if ${ac_cv_path_BASENAME+:} false; then : 3837 $as_echo_n "(cached) " >&6 3838 else 3839 case $BASENAME in 3840 [\\/]* | ?:[\\/]*) 3841 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 3842 ;; 3843 *) 3844 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3845 for as_dir in $PATH 3846 do 3847 IFS=$as_save_IFS 3848 test -z "$as_dir" && as_dir=. 3849 for ac_exec_ext in '' $ac_executable_extensions; do 3850 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3851 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 3852 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3853 break 2 3854 fi 3855 done 3856 done 3857 IFS=$as_save_IFS 3858 3859 ;; 3860 esac 3861 fi 3862 BASENAME=$ac_cv_path_BASENAME 3863 if test -n "$BASENAME"; then 3864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 3865 $as_echo "$BASENAME" >&6; } 3866 else 3867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3868 $as_echo "no" >&6; } 3869 fi 3870 3871 3872 test -n "$BASENAME" && break 3873 done 3874 3875 3876 if test "x$BASENAME" = x; then 3877 if test "xbasename" = x; then 3878 PROG_NAME=basename 3879 else 3880 PROG_NAME=basename 3881 fi 3882 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 3883 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 3884 as_fn_error $? "Cannot continue" "$LINENO" 5 3885 fi 3886 3887 3888 3889 for ac_prog in bash 3890 do 3891 # Extract the first word of "$ac_prog", so it can be a program name with args. 3892 set dummy $ac_prog; ac_word=$2 3893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3894 $as_echo_n "checking for $ac_word... " >&6; } 3895 if ${ac_cv_path_BASH+:} false; then : 3896 $as_echo_n "(cached) " >&6 3897 else 3898 case $BASH in 3899 [\\/]* | ?:[\\/]*) 3900 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 3901 ;; 3902 *) 3903 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3904 for as_dir in $PATH 3905 do 3906 IFS=$as_save_IFS 3907 test -z "$as_dir" && as_dir=. 3908 for ac_exec_ext in '' $ac_executable_extensions; do 3909 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3910 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 3911 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3912 break 2 3913 fi 3914 done 3915 done 3916 IFS=$as_save_IFS 3917 3918 ;; 3919 esac 3920 fi 3921 BASH=$ac_cv_path_BASH 3922 if test -n "$BASH"; then 3923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 3924 $as_echo "$BASH" >&6; } 3925 else 3926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3927 $as_echo "no" >&6; } 3928 fi 3929 3930 3931 test -n "$BASH" && break 3932 done 3933 3934 3935 if test "x$BASH" = x; then 3936 if test "xbash" = x; then 3937 PROG_NAME=bash 3938 else 3939 PROG_NAME=bash 3940 fi 3941 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 3942 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 3943 as_fn_error $? "Cannot continue" "$LINENO" 5 3944 fi 3945 3946 3947 3948 for ac_prog in cat 3949 do 3950 # Extract the first word of "$ac_prog", so it can be a program name with args. 3951 set dummy $ac_prog; ac_word=$2 3952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3953 $as_echo_n "checking for $ac_word... " >&6; } 3954 if ${ac_cv_path_CAT+:} false; then : 3955 $as_echo_n "(cached) " >&6 3956 else 3957 case $CAT in 3958 [\\/]* | ?:[\\/]*) 3959 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 3960 ;; 3961 *) 3962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3963 for as_dir in $PATH 3964 do 3965 IFS=$as_save_IFS 3966 test -z "$as_dir" && as_dir=. 3967 for ac_exec_ext in '' $ac_executable_extensions; do 3968 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3969 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 3970 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3971 break 2 3972 fi 3973 done 3974 done 3975 IFS=$as_save_IFS 3976 3977 ;; 3978 esac 3979 fi 3980 CAT=$ac_cv_path_CAT 3981 if test -n "$CAT"; then 3982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 3983 $as_echo "$CAT" >&6; } 3984 else 3985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3986 $as_echo "no" >&6; } 3987 fi 3988 3989 3990 test -n "$CAT" && break 3991 done 3992 3993 3994 if test "x$CAT" = x; then 3995 if test "xcat" = x; then 3996 PROG_NAME=cat 3997 else 3998 PROG_NAME=cat 3999 fi 4000 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4001 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4002 as_fn_error $? "Cannot continue" "$LINENO" 5 4003 fi 4004 4005 4006 4007 for ac_prog in chmod 4008 do 4009 # Extract the first word of "$ac_prog", so it can be a program name with args. 4010 set dummy $ac_prog; ac_word=$2 4011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4012 $as_echo_n "checking for $ac_word... " >&6; } 4013 if ${ac_cv_path_CHMOD+:} false; then : 4014 $as_echo_n "(cached) " >&6 4015 else 4016 case $CHMOD in 4017 [\\/]* | ?:[\\/]*) 4018 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 4019 ;; 4020 *) 4021 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4022 for as_dir in $PATH 4023 do 4024 IFS=$as_save_IFS 4025 test -z "$as_dir" && as_dir=. 4026 for ac_exec_ext in '' $ac_executable_extensions; do 4027 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4028 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 4029 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4030 break 2 4031 fi 4032 done 4033 done 4034 IFS=$as_save_IFS 4035 4036 ;; 4037 esac 4038 fi 4039 CHMOD=$ac_cv_path_CHMOD 4040 if test -n "$CHMOD"; then 4041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 4042 $as_echo "$CHMOD" >&6; } 4043 else 4044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4045 $as_echo "no" >&6; } 4046 fi 4047 4048 4049 test -n "$CHMOD" && break 4050 done 4051 4052 4053 if test "x$CHMOD" = x; then 4054 if test "xchmod" = x; then 4055 PROG_NAME=chmod 4056 else 4057 PROG_NAME=chmod 4058 fi 4059 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4060 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4061 as_fn_error $? "Cannot continue" "$LINENO" 5 4062 fi 4063 4064 4065 4066 for ac_prog in cmp 4067 do 4068 # Extract the first word of "$ac_prog", so it can be a program name with args. 4069 set dummy $ac_prog; ac_word=$2 4070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4071 $as_echo_n "checking for $ac_word... " >&6; } 4072 if ${ac_cv_path_CMP+:} false; then : 4073 $as_echo_n "(cached) " >&6 4074 else 4075 case $CMP in 4076 [\\/]* | ?:[\\/]*) 4077 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 4078 ;; 4079 *) 4080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4081 for as_dir in $PATH 4082 do 4083 IFS=$as_save_IFS 4084 test -z "$as_dir" && as_dir=. 4085 for ac_exec_ext in '' $ac_executable_extensions; do 4086 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4087 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 4088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4089 break 2 4090 fi 4091 done 4092 done 4093 IFS=$as_save_IFS 4094 4095 ;; 4096 esac 4097 fi 4098 CMP=$ac_cv_path_CMP 4099 if test -n "$CMP"; then 4100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 4101 $as_echo "$CMP" >&6; } 4102 else 4103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4104 $as_echo "no" >&6; } 4105 fi 4106 4107 4108 test -n "$CMP" && break 4109 done 4110 4111 4112 if test "x$CMP" = x; then 4113 if test "xcmp" = x; then 4114 PROG_NAME=cmp 4115 else 4116 PROG_NAME=cmp 4117 fi 4118 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4119 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4120 as_fn_error $? "Cannot continue" "$LINENO" 5 4121 fi 4122 4123 4124 4125 for ac_prog in comm 4126 do 4127 # Extract the first word of "$ac_prog", so it can be a program name with args. 4128 set dummy $ac_prog; ac_word=$2 4129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4130 $as_echo_n "checking for $ac_word... " >&6; } 4131 if ${ac_cv_path_COMM+:} false; then : 4132 $as_echo_n "(cached) " >&6 4133 else 4134 case $COMM in 4135 [\\/]* | ?:[\\/]*) 4136 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 4137 ;; 4138 *) 4139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4140 for as_dir in $PATH 4141 do 4142 IFS=$as_save_IFS 4143 test -z "$as_dir" && as_dir=. 4144 for ac_exec_ext in '' $ac_executable_extensions; do 4145 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4146 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 4147 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4148 break 2 4149 fi 4150 done 4151 done 4152 IFS=$as_save_IFS 4153 4154 ;; 4155 esac 4156 fi 4157 COMM=$ac_cv_path_COMM 4158 if test -n "$COMM"; then 4159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 4160 $as_echo "$COMM" >&6; } 4161 else 4162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4163 $as_echo "no" >&6; } 4164 fi 4165 4166 4167 test -n "$COMM" && break 4168 done 4169 4170 4171 if test "x$COMM" = x; then 4172 if test "xcomm" = x; then 4173 PROG_NAME=comm 4174 else 4175 PROG_NAME=comm 4176 fi 4177 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4178 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4179 as_fn_error $? "Cannot continue" "$LINENO" 5 4180 fi 4181 4182 4183 4184 for ac_prog in cp 4185 do 4186 # Extract the first word of "$ac_prog", so it can be a program name with args. 4187 set dummy $ac_prog; ac_word=$2 4188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4189 $as_echo_n "checking for $ac_word... " >&6; } 4190 if ${ac_cv_path_CP+:} false; then : 4191 $as_echo_n "(cached) " >&6 4192 else 4193 case $CP in 4194 [\\/]* | ?:[\\/]*) 4195 ac_cv_path_CP="$CP" # Let the user override the test with a path. 4196 ;; 4197 *) 4198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4199 for as_dir in $PATH 4200 do 4201 IFS=$as_save_IFS 4202 test -z "$as_dir" && as_dir=. 4203 for ac_exec_ext in '' $ac_executable_extensions; do 4204 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4205 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 4206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4207 break 2 4208 fi 4209 done 4210 done 4211 IFS=$as_save_IFS 4212 4213 ;; 4214 esac 4215 fi 4216 CP=$ac_cv_path_CP 4217 if test -n "$CP"; then 4218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 4219 $as_echo "$CP" >&6; } 4220 else 4221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4222 $as_echo "no" >&6; } 4223 fi 4224 4225 4226 test -n "$CP" && break 4227 done 4228 4229 4230 if test "x$CP" = x; then 4231 if test "xcp" = x; then 4232 PROG_NAME=cp 4233 else 4234 PROG_NAME=cp 4235 fi 4236 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4237 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4238 as_fn_error $? "Cannot continue" "$LINENO" 5 4239 fi 4240 4241 4242 4243 for ac_prog in cpio 4244 do 4245 # Extract the first word of "$ac_prog", so it can be a program name with args. 4246 set dummy $ac_prog; ac_word=$2 4247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4248 $as_echo_n "checking for $ac_word... " >&6; } 4249 if ${ac_cv_path_CPIO+:} false; then : 4250 $as_echo_n "(cached) " >&6 4251 else 4252 case $CPIO in 4253 [\\/]* | ?:[\\/]*) 4254 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 4255 ;; 4256 *) 4257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4258 for as_dir in $PATH 4259 do 4260 IFS=$as_save_IFS 4261 test -z "$as_dir" && as_dir=. 4262 for ac_exec_ext in '' $ac_executable_extensions; do 4263 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4264 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 4265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4266 break 2 4267 fi 4268 done 4269 done 4270 IFS=$as_save_IFS 4271 4272 ;; 4273 esac 4274 fi 4275 CPIO=$ac_cv_path_CPIO 4276 if test -n "$CPIO"; then 4277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 4278 $as_echo "$CPIO" >&6; } 4279 else 4280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4281 $as_echo "no" >&6; } 4282 fi 4283 4284 4285 test -n "$CPIO" && break 4286 done 4287 4288 4289 if test "x$CPIO" = x; then 4290 if test "xcpio" = x; then 4291 PROG_NAME=cpio 4292 else 4293 PROG_NAME=cpio 4294 fi 4295 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4296 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4297 as_fn_error $? "Cannot continue" "$LINENO" 5 4298 fi 4299 4300 4301 4302 for ac_prog in cut 4303 do 4304 # Extract the first word of "$ac_prog", so it can be a program name with args. 4305 set dummy $ac_prog; ac_word=$2 4306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4307 $as_echo_n "checking for $ac_word... " >&6; } 4308 if ${ac_cv_path_CUT+:} false; then : 4309 $as_echo_n "(cached) " >&6 4310 else 4311 case $CUT in 4312 [\\/]* | ?:[\\/]*) 4313 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 4314 ;; 4315 *) 4316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4317 for as_dir in $PATH 4318 do 4319 IFS=$as_save_IFS 4320 test -z "$as_dir" && as_dir=. 4321 for ac_exec_ext in '' $ac_executable_extensions; do 4322 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4323 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 4324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4325 break 2 4326 fi 4327 done 4328 done 4329 IFS=$as_save_IFS 4330 4331 ;; 4332 esac 4333 fi 4334 CUT=$ac_cv_path_CUT 4335 if test -n "$CUT"; then 4336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 4337 $as_echo "$CUT" >&6; } 4338 else 4339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4340 $as_echo "no" >&6; } 4341 fi 4342 4343 4344 test -n "$CUT" && break 4345 done 4346 4347 4348 if test "x$CUT" = x; then 4349 if test "xcut" = x; then 4350 PROG_NAME=cut 4351 else 4352 PROG_NAME=cut 4353 fi 4354 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4355 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4356 as_fn_error $? "Cannot continue" "$LINENO" 5 4357 fi 4358 4359 4360 4361 for ac_prog in date 4362 do 4363 # Extract the first word of "$ac_prog", so it can be a program name with args. 4364 set dummy $ac_prog; ac_word=$2 4365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4366 $as_echo_n "checking for $ac_word... " >&6; } 4367 if ${ac_cv_path_DATE+:} false; then : 4368 $as_echo_n "(cached) " >&6 4369 else 4370 case $DATE in 4371 [\\/]* | ?:[\\/]*) 4372 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 4373 ;; 4374 *) 4375 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4376 for as_dir in $PATH 4377 do 4378 IFS=$as_save_IFS 4379 test -z "$as_dir" && as_dir=. 4380 for ac_exec_ext in '' $ac_executable_extensions; do 4381 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4382 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 4383 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4384 break 2 4385 fi 4386 done 4387 done 4388 IFS=$as_save_IFS 4389 4390 ;; 4391 esac 4392 fi 4393 DATE=$ac_cv_path_DATE 4394 if test -n "$DATE"; then 4395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 4396 $as_echo "$DATE" >&6; } 4397 else 4398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4399 $as_echo "no" >&6; } 4400 fi 4401 4402 4403 test -n "$DATE" && break 4404 done 4405 4406 4407 if test "x$DATE" = x; then 4408 if test "xdate" = x; then 4409 PROG_NAME=date 4410 else 4411 PROG_NAME=date 4412 fi 4413 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4414 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4415 as_fn_error $? "Cannot continue" "$LINENO" 5 4416 fi 4417 4418 4419 4420 for ac_prog in gdiff diff 4421 do 4422 # Extract the first word of "$ac_prog", so it can be a program name with args. 4423 set dummy $ac_prog; ac_word=$2 4424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4425 $as_echo_n "checking for $ac_word... " >&6; } 4426 if ${ac_cv_path_DIFF+:} false; then : 4427 $as_echo_n "(cached) " >&6 4428 else 4429 case $DIFF in 4430 [\\/]* | ?:[\\/]*) 4431 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 4432 ;; 4433 *) 4434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4435 for as_dir in $PATH 4436 do 4437 IFS=$as_save_IFS 4438 test -z "$as_dir" && as_dir=. 4439 for ac_exec_ext in '' $ac_executable_extensions; do 4440 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4441 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 4442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4443 break 2 4444 fi 4445 done 4446 done 4447 IFS=$as_save_IFS 4448 4449 ;; 4450 esac 4451 fi 4452 DIFF=$ac_cv_path_DIFF 4453 if test -n "$DIFF"; then 4454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 4455 $as_echo "$DIFF" >&6; } 4456 else 4457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4458 $as_echo "no" >&6; } 4459 fi 4460 4461 4462 test -n "$DIFF" && break 4463 done 4464 4465 4466 if test "x$DIFF" = x; then 4467 if test "xgdiff diff" = x; then 4468 PROG_NAME=diff 4469 else 4470 PROG_NAME=gdiff diff 4471 fi 4472 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4473 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4474 as_fn_error $? "Cannot continue" "$LINENO" 5 4475 fi 4476 4477 4478 4479 for ac_prog in dirname 4480 do 4481 # Extract the first word of "$ac_prog", so it can be a program name with args. 4482 set dummy $ac_prog; ac_word=$2 4483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4484 $as_echo_n "checking for $ac_word... " >&6; } 4485 if ${ac_cv_path_DIRNAME+:} false; then : 4486 $as_echo_n "(cached) " >&6 4487 else 4488 case $DIRNAME in 4489 [\\/]* | ?:[\\/]*) 4490 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 4491 ;; 4492 *) 4493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4494 for as_dir in $PATH 4495 do 4496 IFS=$as_save_IFS 4497 test -z "$as_dir" && as_dir=. 4498 for ac_exec_ext in '' $ac_executable_extensions; do 4499 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4500 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 4501 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4502 break 2 4503 fi 4504 done 4505 done 4506 IFS=$as_save_IFS 4507 4508 ;; 4509 esac 4510 fi 4511 DIRNAME=$ac_cv_path_DIRNAME 4512 if test -n "$DIRNAME"; then 4513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 4514 $as_echo "$DIRNAME" >&6; } 4515 else 4516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4517 $as_echo "no" >&6; } 4518 fi 4519 4520 4521 test -n "$DIRNAME" && break 4522 done 4523 4524 4525 if test "x$DIRNAME" = x; then 4526 if test "xdirname" = x; then 4527 PROG_NAME=dirname 4528 else 4529 PROG_NAME=dirname 4530 fi 4531 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4532 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4533 as_fn_error $? "Cannot continue" "$LINENO" 5 4534 fi 4535 4536 4537 4538 for ac_prog in echo 4539 do 4540 # Extract the first word of "$ac_prog", so it can be a program name with args. 4541 set dummy $ac_prog; ac_word=$2 4542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4543 $as_echo_n "checking for $ac_word... " >&6; } 4544 if ${ac_cv_path_ECHO+:} false; then : 4545 $as_echo_n "(cached) " >&6 4546 else 4547 case $ECHO in 4548 [\\/]* | ?:[\\/]*) 4549 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 4550 ;; 4551 *) 4552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4553 for as_dir in $PATH 4554 do 4555 IFS=$as_save_IFS 4556 test -z "$as_dir" && as_dir=. 4557 for ac_exec_ext in '' $ac_executable_extensions; do 4558 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4559 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 4560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4561 break 2 4562 fi 4563 done 4564 done 4565 IFS=$as_save_IFS 4566 4567 ;; 4568 esac 4569 fi 4570 ECHO=$ac_cv_path_ECHO 4571 if test -n "$ECHO"; then 4572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 4573 $as_echo "$ECHO" >&6; } 4574 else 4575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4576 $as_echo "no" >&6; } 4577 fi 4578 4579 4580 test -n "$ECHO" && break 4581 done 4582 4583 4584 if test "x$ECHO" = x; then 4585 if test "xecho" = x; then 4586 PROG_NAME=echo 4587 else 4588 PROG_NAME=echo 4589 fi 4590 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4591 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4592 as_fn_error $? "Cannot continue" "$LINENO" 5 4593 fi 4594 4595 4596 4597 for ac_prog in expr 4598 do 4599 # Extract the first word of "$ac_prog", so it can be a program name with args. 4600 set dummy $ac_prog; ac_word=$2 4601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4602 $as_echo_n "checking for $ac_word... " >&6; } 4603 if ${ac_cv_path_EXPR+:} false; then : 4604 $as_echo_n "(cached) " >&6 4605 else 4606 case $EXPR in 4607 [\\/]* | ?:[\\/]*) 4608 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 4609 ;; 4610 *) 4611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4612 for as_dir in $PATH 4613 do 4614 IFS=$as_save_IFS 4615 test -z "$as_dir" && as_dir=. 4616 for ac_exec_ext in '' $ac_executable_extensions; do 4617 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4618 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 4619 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4620 break 2 4621 fi 4622 done 4623 done 4624 IFS=$as_save_IFS 4625 4626 ;; 4627 esac 4628 fi 4629 EXPR=$ac_cv_path_EXPR 4630 if test -n "$EXPR"; then 4631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 4632 $as_echo "$EXPR" >&6; } 4633 else 4634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4635 $as_echo "no" >&6; } 4636 fi 4637 4638 4639 test -n "$EXPR" && break 4640 done 4641 4642 4643 if test "x$EXPR" = x; then 4644 if test "xexpr" = x; then 4645 PROG_NAME=expr 4646 else 4647 PROG_NAME=expr 4648 fi 4649 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4650 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4651 as_fn_error $? "Cannot continue" "$LINENO" 5 4652 fi 4653 4654 4655 4656 for ac_prog in file 4657 do 4658 # Extract the first word of "$ac_prog", so it can be a program name with args. 4659 set dummy $ac_prog; ac_word=$2 4660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4661 $as_echo_n "checking for $ac_word... " >&6; } 4662 if ${ac_cv_path_FILE+:} false; then : 4663 $as_echo_n "(cached) " >&6 4664 else 4665 case $FILE in 4666 [\\/]* | ?:[\\/]*) 4667 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 4668 ;; 4669 *) 4670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4671 for as_dir in $PATH 4672 do 4673 IFS=$as_save_IFS 4674 test -z "$as_dir" && as_dir=. 4675 for ac_exec_ext in '' $ac_executable_extensions; do 4676 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4677 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 4678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4679 break 2 4680 fi 4681 done 4682 done 4683 IFS=$as_save_IFS 4684 4685 ;; 4686 esac 4687 fi 4688 FILE=$ac_cv_path_FILE 4689 if test -n "$FILE"; then 4690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 4691 $as_echo "$FILE" >&6; } 4692 else 4693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4694 $as_echo "no" >&6; } 4695 fi 4696 4697 4698 test -n "$FILE" && break 4699 done 4700 4701 4702 if test "x$FILE" = x; then 4703 if test "xfile" = x; then 4704 PROG_NAME=file 4705 else 4706 PROG_NAME=file 4707 fi 4708 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4709 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4710 as_fn_error $? "Cannot continue" "$LINENO" 5 4711 fi 4712 4713 4714 4715 for ac_prog in find 4716 do 4717 # Extract the first word of "$ac_prog", so it can be a program name with args. 4718 set dummy $ac_prog; ac_word=$2 4719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4720 $as_echo_n "checking for $ac_word... " >&6; } 4721 if ${ac_cv_path_FIND+:} false; then : 4722 $as_echo_n "(cached) " >&6 4723 else 4724 case $FIND in 4725 [\\/]* | ?:[\\/]*) 4726 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 4727 ;; 4728 *) 4729 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4730 for as_dir in $PATH 4731 do 4732 IFS=$as_save_IFS 4733 test -z "$as_dir" && as_dir=. 4734 for ac_exec_ext in '' $ac_executable_extensions; do 4735 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4736 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 4737 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4738 break 2 4739 fi 4740 done 4741 done 4742 IFS=$as_save_IFS 4743 4744 ;; 4745 esac 4746 fi 4747 FIND=$ac_cv_path_FIND 4748 if test -n "$FIND"; then 4749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 4750 $as_echo "$FIND" >&6; } 4751 else 4752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4753 $as_echo "no" >&6; } 4754 fi 4755 4756 4757 test -n "$FIND" && break 4758 done 4759 4760 4761 if test "x$FIND" = x; then 4762 if test "xfind" = x; then 4763 PROG_NAME=find 4764 else 4765 PROG_NAME=find 4766 fi 4767 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4768 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4769 as_fn_error $? "Cannot continue" "$LINENO" 5 4770 fi 4771 4772 4773 4774 for ac_prog in head 4775 do 4776 # Extract the first word of "$ac_prog", so it can be a program name with args. 4777 set dummy $ac_prog; ac_word=$2 4778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4779 $as_echo_n "checking for $ac_word... " >&6; } 4780 if ${ac_cv_path_HEAD+:} false; then : 4781 $as_echo_n "(cached) " >&6 4782 else 4783 case $HEAD in 4784 [\\/]* | ?:[\\/]*) 4785 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 4786 ;; 4787 *) 4788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4789 for as_dir in $PATH 4790 do 4791 IFS=$as_save_IFS 4792 test -z "$as_dir" && as_dir=. 4793 for ac_exec_ext in '' $ac_executable_extensions; do 4794 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4795 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 4796 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4797 break 2 4798 fi 4799 done 4800 done 4801 IFS=$as_save_IFS 4802 4803 ;; 4804 esac 4805 fi 4806 HEAD=$ac_cv_path_HEAD 4807 if test -n "$HEAD"; then 4808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 4809 $as_echo "$HEAD" >&6; } 4810 else 4811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4812 $as_echo "no" >&6; } 4813 fi 4814 4815 4816 test -n "$HEAD" && break 4817 done 4818 4819 4820 if test "x$HEAD" = x; then 4821 if test "xhead" = x; then 4822 PROG_NAME=head 4823 else 4824 PROG_NAME=head 4825 fi 4826 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4827 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4828 as_fn_error $? "Cannot continue" "$LINENO" 5 4829 fi 4830 4831 4832 4833 for ac_prog in ln 4834 do 4835 # Extract the first word of "$ac_prog", so it can be a program name with args. 4836 set dummy $ac_prog; ac_word=$2 4837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4838 $as_echo_n "checking for $ac_word... " >&6; } 4839 if ${ac_cv_path_LN+:} false; then : 4840 $as_echo_n "(cached) " >&6 4841 else 4842 case $LN in 4843 [\\/]* | ?:[\\/]*) 4844 ac_cv_path_LN="$LN" # Let the user override the test with a path. 4845 ;; 4846 *) 4847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4848 for as_dir in $PATH 4849 do 4850 IFS=$as_save_IFS 4851 test -z "$as_dir" && as_dir=. 4852 for ac_exec_ext in '' $ac_executable_extensions; do 4853 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4854 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 4855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4856 break 2 4857 fi 4858 done 4859 done 4860 IFS=$as_save_IFS 4861 4862 ;; 4863 esac 4864 fi 4865 LN=$ac_cv_path_LN 4866 if test -n "$LN"; then 4867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 4868 $as_echo "$LN" >&6; } 4869 else 4870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4871 $as_echo "no" >&6; } 4872 fi 4873 4874 4875 test -n "$LN" && break 4876 done 4877 4878 4879 if test "x$LN" = x; then 4880 if test "xln" = x; then 4881 PROG_NAME=ln 4882 else 4883 PROG_NAME=ln 4884 fi 4885 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4886 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4887 as_fn_error $? "Cannot continue" "$LINENO" 5 4888 fi 4889 4890 4891 4892 for ac_prog in ls 4893 do 4894 # Extract the first word of "$ac_prog", so it can be a program name with args. 4895 set dummy $ac_prog; ac_word=$2 4896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4897 $as_echo_n "checking for $ac_word... " >&6; } 4898 if ${ac_cv_path_LS+:} false; then : 4899 $as_echo_n "(cached) " >&6 4900 else 4901 case $LS in 4902 [\\/]* | ?:[\\/]*) 4903 ac_cv_path_LS="$LS" # Let the user override the test with a path. 4904 ;; 4905 *) 4906 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4907 for as_dir in $PATH 4908 do 4909 IFS=$as_save_IFS 4910 test -z "$as_dir" && as_dir=. 4911 for ac_exec_ext in '' $ac_executable_extensions; do 4912 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4913 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 4914 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4915 break 2 4916 fi 4917 done 4918 done 4919 IFS=$as_save_IFS 4920 4921 ;; 4922 esac 4923 fi 4924 LS=$ac_cv_path_LS 4925 if test -n "$LS"; then 4926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 4927 $as_echo "$LS" >&6; } 4928 else 4929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4930 $as_echo "no" >&6; } 4931 fi 4932 4933 4934 test -n "$LS" && break 4935 done 4936 4937 4938 if test "x$LS" = x; then 4939 if test "xls" = x; then 4940 PROG_NAME=ls 4941 else 4942 PROG_NAME=ls 4943 fi 4944 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 4945 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 4946 as_fn_error $? "Cannot continue" "$LINENO" 5 4947 fi 4948 4949 4950 4951 for ac_prog in mkdir 4952 do 4953 # Extract the first word of "$ac_prog", so it can be a program name with args. 4954 set dummy $ac_prog; ac_word=$2 4955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4956 $as_echo_n "checking for $ac_word... " >&6; } 4957 if ${ac_cv_path_MKDIR+:} false; then : 4958 $as_echo_n "(cached) " >&6 4959 else 4960 case $MKDIR in 4961 [\\/]* | ?:[\\/]*) 4962 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 4963 ;; 4964 *) 4965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4966 for as_dir in $PATH 4967 do 4968 IFS=$as_save_IFS 4969 test -z "$as_dir" && as_dir=. 4970 for ac_exec_ext in '' $ac_executable_extensions; do 4971 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 4972 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 4973 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4974 break 2 4975 fi 4976 done 4977 done 4978 IFS=$as_save_IFS 4979 4980 ;; 4981 esac 4982 fi 4983 MKDIR=$ac_cv_path_MKDIR 4984 if test -n "$MKDIR"; then 4985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 4986 $as_echo "$MKDIR" >&6; } 4987 else 4988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4989 $as_echo "no" >&6; } 4990 fi 4991 4992 4993 test -n "$MKDIR" && break 4994 done 4995 4996 4997 if test "x$MKDIR" = x; then 4998 if test "xmkdir" = x; then 4999 PROG_NAME=mkdir 5000 else 5001 PROG_NAME=mkdir 5002 fi 5003 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5004 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5005 as_fn_error $? "Cannot continue" "$LINENO" 5 5006 fi 5007 5008 5009 5010 for ac_prog in mktemp 5011 do 5012 # Extract the first word of "$ac_prog", so it can be a program name with args. 5013 set dummy $ac_prog; ac_word=$2 5014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5015 $as_echo_n "checking for $ac_word... " >&6; } 5016 if ${ac_cv_path_MKTEMP+:} false; then : 5017 $as_echo_n "(cached) " >&6 5018 else 5019 case $MKTEMP in 5020 [\\/]* | ?:[\\/]*) 5021 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 5022 ;; 5023 *) 5024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5025 for as_dir in $PATH 5026 do 5027 IFS=$as_save_IFS 5028 test -z "$as_dir" && as_dir=. 5029 for ac_exec_ext in '' $ac_executable_extensions; do 5030 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5031 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 5032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5033 break 2 5034 fi 5035 done 5036 done 5037 IFS=$as_save_IFS 5038 5039 ;; 5040 esac 5041 fi 5042 MKTEMP=$ac_cv_path_MKTEMP 5043 if test -n "$MKTEMP"; then 5044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 5045 $as_echo "$MKTEMP" >&6; } 5046 else 5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5048 $as_echo "no" >&6; } 5049 fi 5050 5051 5052 test -n "$MKTEMP" && break 5053 done 5054 5055 5056 if test "x$MKTEMP" = x; then 5057 if test "xmktemp" = x; then 5058 PROG_NAME=mktemp 5059 else 5060 PROG_NAME=mktemp 5061 fi 5062 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5063 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5064 as_fn_error $? "Cannot continue" "$LINENO" 5 5065 fi 5066 5067 5068 5069 for ac_prog in mv 5070 do 5071 # Extract the first word of "$ac_prog", so it can be a program name with args. 5072 set dummy $ac_prog; ac_word=$2 5073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5074 $as_echo_n "checking for $ac_word... " >&6; } 5075 if ${ac_cv_path_MV+:} false; then : 5076 $as_echo_n "(cached) " >&6 5077 else 5078 case $MV in 5079 [\\/]* | ?:[\\/]*) 5080 ac_cv_path_MV="$MV" # Let the user override the test with a path. 5081 ;; 5082 *) 5083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5084 for as_dir in $PATH 5085 do 5086 IFS=$as_save_IFS 5087 test -z "$as_dir" && as_dir=. 5088 for ac_exec_ext in '' $ac_executable_extensions; do 5089 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5090 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 5091 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5092 break 2 5093 fi 5094 done 5095 done 5096 IFS=$as_save_IFS 5097 5098 ;; 5099 esac 5100 fi 5101 MV=$ac_cv_path_MV 5102 if test -n "$MV"; then 5103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 5104 $as_echo "$MV" >&6; } 5105 else 5106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5107 $as_echo "no" >&6; } 5108 fi 5109 5110 5111 test -n "$MV" && break 5112 done 5113 5114 5115 if test "x$MV" = x; then 5116 if test "xmv" = x; then 5117 PROG_NAME=mv 5118 else 5119 PROG_NAME=mv 5120 fi 5121 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5122 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5123 as_fn_error $? "Cannot continue" "$LINENO" 5 5124 fi 5125 5126 5127 5128 for ac_prog in printf 5129 do 5130 # Extract the first word of "$ac_prog", so it can be a program name with args. 5131 set dummy $ac_prog; ac_word=$2 5132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5133 $as_echo_n "checking for $ac_word... " >&6; } 5134 if ${ac_cv_path_PRINTF+:} false; then : 5135 $as_echo_n "(cached) " >&6 5136 else 5137 case $PRINTF in 5138 [\\/]* | ?:[\\/]*) 5139 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 5140 ;; 5141 *) 5142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5143 for as_dir in $PATH 5144 do 5145 IFS=$as_save_IFS 5146 test -z "$as_dir" && as_dir=. 5147 for ac_exec_ext in '' $ac_executable_extensions; do 5148 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5149 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 5150 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5151 break 2 5152 fi 5153 done 5154 done 5155 IFS=$as_save_IFS 5156 5157 ;; 5158 esac 5159 fi 5160 PRINTF=$ac_cv_path_PRINTF 5161 if test -n "$PRINTF"; then 5162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 5163 $as_echo "$PRINTF" >&6; } 5164 else 5165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5166 $as_echo "no" >&6; } 5167 fi 5168 5169 5170 test -n "$PRINTF" && break 5171 done 5172 5173 5174 if test "x$PRINTF" = x; then 5175 if test "xprintf" = x; then 5176 PROG_NAME=printf 5177 else 5178 PROG_NAME=printf 5179 fi 5180 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5181 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5182 as_fn_error $? "Cannot continue" "$LINENO" 5 5183 fi 5184 5185 5186 5187 for ac_prog in rm 5188 do 5189 # Extract the first word of "$ac_prog", so it can be a program name with args. 5190 set dummy $ac_prog; ac_word=$2 5191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5192 $as_echo_n "checking for $ac_word... " >&6; } 5193 if ${ac_cv_path_RM+:} false; then : 5194 $as_echo_n "(cached) " >&6 5195 else 5196 case $RM in 5197 [\\/]* | ?:[\\/]*) 5198 ac_cv_path_RM="$RM" # Let the user override the test with a path. 5199 ;; 5200 *) 5201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5202 for as_dir in $PATH 5203 do 5204 IFS=$as_save_IFS 5205 test -z "$as_dir" && as_dir=. 5206 for ac_exec_ext in '' $ac_executable_extensions; do 5207 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5208 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 5209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5210 break 2 5211 fi 5212 done 5213 done 5214 IFS=$as_save_IFS 5215 5216 ;; 5217 esac 5218 fi 5219 RM=$ac_cv_path_RM 5220 if test -n "$RM"; then 5221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 5222 $as_echo "$RM" >&6; } 5223 else 5224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5225 $as_echo "no" >&6; } 5226 fi 5227 5228 5229 test -n "$RM" && break 5230 done 5231 5232 5233 if test "x$RM" = x; then 5234 if test "xrm" = x; then 5235 PROG_NAME=rm 5236 else 5237 PROG_NAME=rm 5238 fi 5239 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5240 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5241 as_fn_error $? "Cannot continue" "$LINENO" 5 5242 fi 5243 5244 5245 5246 for ac_prog in sh 5247 do 5248 # Extract the first word of "$ac_prog", so it can be a program name with args. 5249 set dummy $ac_prog; ac_word=$2 5250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5251 $as_echo_n "checking for $ac_word... " >&6; } 5252 if ${ac_cv_path_SH+:} false; then : 5253 $as_echo_n "(cached) " >&6 5254 else 5255 case $SH in 5256 [\\/]* | ?:[\\/]*) 5257 ac_cv_path_SH="$SH" # Let the user override the test with a path. 5258 ;; 5259 *) 5260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5261 for as_dir in $PATH 5262 do 5263 IFS=$as_save_IFS 5264 test -z "$as_dir" && as_dir=. 5265 for ac_exec_ext in '' $ac_executable_extensions; do 5266 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5267 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 5268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5269 break 2 5270 fi 5271 done 5272 done 5273 IFS=$as_save_IFS 5274 5275 ;; 5276 esac 5277 fi 5278 SH=$ac_cv_path_SH 5279 if test -n "$SH"; then 5280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 5281 $as_echo "$SH" >&6; } 5282 else 5283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5284 $as_echo "no" >&6; } 5285 fi 5286 5287 5288 test -n "$SH" && break 5289 done 5290 5291 5292 if test "x$SH" = x; then 5293 if test "xsh" = x; then 5294 PROG_NAME=sh 5295 else 5296 PROG_NAME=sh 5297 fi 5298 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5299 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5300 as_fn_error $? "Cannot continue" "$LINENO" 5 5301 fi 5302 5303 5304 5305 for ac_prog in sort 5306 do 5307 # Extract the first word of "$ac_prog", so it can be a program name with args. 5308 set dummy $ac_prog; ac_word=$2 5309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5310 $as_echo_n "checking for $ac_word... " >&6; } 5311 if ${ac_cv_path_SORT+:} false; then : 5312 $as_echo_n "(cached) " >&6 5313 else 5314 case $SORT in 5315 [\\/]* | ?:[\\/]*) 5316 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 5317 ;; 5318 *) 5319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5320 for as_dir in $PATH 5321 do 5322 IFS=$as_save_IFS 5323 test -z "$as_dir" && as_dir=. 5324 for ac_exec_ext in '' $ac_executable_extensions; do 5325 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5326 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 5327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5328 break 2 5329 fi 5330 done 5331 done 5332 IFS=$as_save_IFS 5333 5334 ;; 5335 esac 5336 fi 5337 SORT=$ac_cv_path_SORT 5338 if test -n "$SORT"; then 5339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 5340 $as_echo "$SORT" >&6; } 5341 else 5342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5343 $as_echo "no" >&6; } 5344 fi 5345 5346 5347 test -n "$SORT" && break 5348 done 5349 5350 5351 if test "x$SORT" = x; then 5352 if test "xsort" = x; then 5353 PROG_NAME=sort 5354 else 5355 PROG_NAME=sort 5356 fi 5357 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5358 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5359 as_fn_error $? "Cannot continue" "$LINENO" 5 5360 fi 5361 5362 5363 5364 for ac_prog in tail 5365 do 5366 # Extract the first word of "$ac_prog", so it can be a program name with args. 5367 set dummy $ac_prog; ac_word=$2 5368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5369 $as_echo_n "checking for $ac_word... " >&6; } 5370 if ${ac_cv_path_TAIL+:} false; then : 5371 $as_echo_n "(cached) " >&6 5372 else 5373 case $TAIL in 5374 [\\/]* | ?:[\\/]*) 5375 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 5376 ;; 5377 *) 5378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5379 for as_dir in $PATH 5380 do 5381 IFS=$as_save_IFS 5382 test -z "$as_dir" && as_dir=. 5383 for ac_exec_ext in '' $ac_executable_extensions; do 5384 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5385 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 5386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5387 break 2 5388 fi 5389 done 5390 done 5391 IFS=$as_save_IFS 5392 5393 ;; 5394 esac 5395 fi 5396 TAIL=$ac_cv_path_TAIL 5397 if test -n "$TAIL"; then 5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 5399 $as_echo "$TAIL" >&6; } 5400 else 5401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5402 $as_echo "no" >&6; } 5403 fi 5404 5405 5406 test -n "$TAIL" && break 5407 done 5408 5409 5410 if test "x$TAIL" = x; then 5411 if test "xtail" = x; then 5412 PROG_NAME=tail 5413 else 5414 PROG_NAME=tail 5415 fi 5416 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5417 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5418 as_fn_error $? "Cannot continue" "$LINENO" 5 5419 fi 5420 5421 5422 5423 for ac_prog in tar 5424 do 5425 # Extract the first word of "$ac_prog", so it can be a program name with args. 5426 set dummy $ac_prog; ac_word=$2 5427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5428 $as_echo_n "checking for $ac_word... " >&6; } 5429 if ${ac_cv_path_TAR+:} false; then : 5430 $as_echo_n "(cached) " >&6 5431 else 5432 case $TAR in 5433 [\\/]* | ?:[\\/]*) 5434 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 5435 ;; 5436 *) 5437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5438 for as_dir in $PATH 5439 do 5440 IFS=$as_save_IFS 5441 test -z "$as_dir" && as_dir=. 5442 for ac_exec_ext in '' $ac_executable_extensions; do 5443 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5444 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 5445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5446 break 2 5447 fi 5448 done 5449 done 5450 IFS=$as_save_IFS 5451 5452 ;; 5453 esac 5454 fi 5455 TAR=$ac_cv_path_TAR 5456 if test -n "$TAR"; then 5457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 5458 $as_echo "$TAR" >&6; } 5459 else 5460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5461 $as_echo "no" >&6; } 5462 fi 5463 5464 5465 test -n "$TAR" && break 5466 done 5467 5468 5469 if test "x$TAR" = x; then 5470 if test "xtar" = x; then 5471 PROG_NAME=tar 5472 else 5473 PROG_NAME=tar 5474 fi 5475 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5476 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5477 as_fn_error $? "Cannot continue" "$LINENO" 5 5478 fi 5479 5480 5481 5482 for ac_prog in tee 5483 do 5484 # Extract the first word of "$ac_prog", so it can be a program name with args. 5485 set dummy $ac_prog; ac_word=$2 5486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5487 $as_echo_n "checking for $ac_word... " >&6; } 5488 if ${ac_cv_path_TEE+:} false; then : 5489 $as_echo_n "(cached) " >&6 5490 else 5491 case $TEE in 5492 [\\/]* | ?:[\\/]*) 5493 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 5494 ;; 5495 *) 5496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5497 for as_dir in $PATH 5498 do 5499 IFS=$as_save_IFS 5500 test -z "$as_dir" && as_dir=. 5501 for ac_exec_ext in '' $ac_executable_extensions; do 5502 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5503 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 5504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5505 break 2 5506 fi 5507 done 5508 done 5509 IFS=$as_save_IFS 5510 5511 ;; 5512 esac 5513 fi 5514 TEE=$ac_cv_path_TEE 5515 if test -n "$TEE"; then 5516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 5517 $as_echo "$TEE" >&6; } 5518 else 5519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5520 $as_echo "no" >&6; } 5521 fi 5522 5523 5524 test -n "$TEE" && break 5525 done 5526 5527 5528 if test "x$TEE" = x; then 5529 if test "xtee" = x; then 5530 PROG_NAME=tee 5531 else 5532 PROG_NAME=tee 5533 fi 5534 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5535 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5536 as_fn_error $? "Cannot continue" "$LINENO" 5 5537 fi 5538 5539 5540 5541 for ac_prog in touch 5542 do 5543 # Extract the first word of "$ac_prog", so it can be a program name with args. 5544 set dummy $ac_prog; ac_word=$2 5545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5546 $as_echo_n "checking for $ac_word... " >&6; } 5547 if ${ac_cv_path_TOUCH+:} false; then : 5548 $as_echo_n "(cached) " >&6 5549 else 5550 case $TOUCH in 5551 [\\/]* | ?:[\\/]*) 5552 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 5553 ;; 5554 *) 5555 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5556 for as_dir in $PATH 5557 do 5558 IFS=$as_save_IFS 5559 test -z "$as_dir" && as_dir=. 5560 for ac_exec_ext in '' $ac_executable_extensions; do 5561 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5562 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 5563 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5564 break 2 5565 fi 5566 done 5567 done 5568 IFS=$as_save_IFS 5569 5570 ;; 5571 esac 5572 fi 5573 TOUCH=$ac_cv_path_TOUCH 5574 if test -n "$TOUCH"; then 5575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 5576 $as_echo "$TOUCH" >&6; } 5577 else 5578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5579 $as_echo "no" >&6; } 5580 fi 5581 5582 5583 test -n "$TOUCH" && break 5584 done 5585 5586 5587 if test "x$TOUCH" = x; then 5588 if test "xtouch" = x; then 5589 PROG_NAME=touch 5590 else 5591 PROG_NAME=touch 5592 fi 5593 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5594 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5595 as_fn_error $? "Cannot continue" "$LINENO" 5 5596 fi 5597 5598 5599 5600 for ac_prog in tr 5601 do 5602 # Extract the first word of "$ac_prog", so it can be a program name with args. 5603 set dummy $ac_prog; ac_word=$2 5604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5605 $as_echo_n "checking for $ac_word... " >&6; } 5606 if ${ac_cv_path_TR+:} false; then : 5607 $as_echo_n "(cached) " >&6 5608 else 5609 case $TR in 5610 [\\/]* | ?:[\\/]*) 5611 ac_cv_path_TR="$TR" # Let the user override the test with a path. 5612 ;; 5613 *) 5614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5615 for as_dir in $PATH 5616 do 5617 IFS=$as_save_IFS 5618 test -z "$as_dir" && as_dir=. 5619 for ac_exec_ext in '' $ac_executable_extensions; do 5620 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5621 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 5622 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5623 break 2 5624 fi 5625 done 5626 done 5627 IFS=$as_save_IFS 5628 5629 ;; 5630 esac 5631 fi 5632 TR=$ac_cv_path_TR 5633 if test -n "$TR"; then 5634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 5635 $as_echo "$TR" >&6; } 5636 else 5637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5638 $as_echo "no" >&6; } 5639 fi 5640 5641 5642 test -n "$TR" && break 5643 done 5644 5645 5646 if test "x$TR" = x; then 5647 if test "xtr" = x; then 5648 PROG_NAME=tr 5649 else 5650 PROG_NAME=tr 5651 fi 5652 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5653 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5654 as_fn_error $? "Cannot continue" "$LINENO" 5 5655 fi 5656 5657 5658 5659 for ac_prog in uname 5660 do 5661 # Extract the first word of "$ac_prog", so it can be a program name with args. 5662 set dummy $ac_prog; ac_word=$2 5663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5664 $as_echo_n "checking for $ac_word... " >&6; } 5665 if ${ac_cv_path_UNAME+:} false; then : 5666 $as_echo_n "(cached) " >&6 5667 else 5668 case $UNAME in 5669 [\\/]* | ?:[\\/]*) 5670 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 5671 ;; 5672 *) 5673 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5674 for as_dir in $PATH 5675 do 5676 IFS=$as_save_IFS 5677 test -z "$as_dir" && as_dir=. 5678 for ac_exec_ext in '' $ac_executable_extensions; do 5679 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5680 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 5681 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5682 break 2 5683 fi 5684 done 5685 done 5686 IFS=$as_save_IFS 5687 5688 ;; 5689 esac 5690 fi 5691 UNAME=$ac_cv_path_UNAME 5692 if test -n "$UNAME"; then 5693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 5694 $as_echo "$UNAME" >&6; } 5695 else 5696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5697 $as_echo "no" >&6; } 5698 fi 5699 5700 5701 test -n "$UNAME" && break 5702 done 5703 5704 5705 if test "x$UNAME" = x; then 5706 if test "xuname" = x; then 5707 PROG_NAME=uname 5708 else 5709 PROG_NAME=uname 5710 fi 5711 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5712 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5713 as_fn_error $? "Cannot continue" "$LINENO" 5 5714 fi 5715 5716 5717 5718 for ac_prog in uniq 5719 do 5720 # Extract the first word of "$ac_prog", so it can be a program name with args. 5721 set dummy $ac_prog; ac_word=$2 5722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5723 $as_echo_n "checking for $ac_word... " >&6; } 5724 if ${ac_cv_path_UNIQ+:} false; then : 5725 $as_echo_n "(cached) " >&6 5726 else 5727 case $UNIQ in 5728 [\\/]* | ?:[\\/]*) 5729 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 5730 ;; 5731 *) 5732 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5733 for as_dir in $PATH 5734 do 5735 IFS=$as_save_IFS 5736 test -z "$as_dir" && as_dir=. 5737 for ac_exec_ext in '' $ac_executable_extensions; do 5738 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5739 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 5740 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5741 break 2 5742 fi 5743 done 5744 done 5745 IFS=$as_save_IFS 5746 5747 ;; 5748 esac 5749 fi 5750 UNIQ=$ac_cv_path_UNIQ 5751 if test -n "$UNIQ"; then 5752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 5753 $as_echo "$UNIQ" >&6; } 5754 else 5755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5756 $as_echo "no" >&6; } 5757 fi 5758 5759 5760 test -n "$UNIQ" && break 5761 done 5762 5763 5764 if test "x$UNIQ" = x; then 5765 if test "xuniq" = x; then 5766 PROG_NAME=uniq 5767 else 5768 PROG_NAME=uniq 5769 fi 5770 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5771 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5772 as_fn_error $? "Cannot continue" "$LINENO" 5 5773 fi 5774 5775 5776 5777 for ac_prog in wc 5778 do 5779 # Extract the first word of "$ac_prog", so it can be a program name with args. 5780 set dummy $ac_prog; ac_word=$2 5781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5782 $as_echo_n "checking for $ac_word... " >&6; } 5783 if ${ac_cv_path_WC+:} false; then : 5784 $as_echo_n "(cached) " >&6 5785 else 5786 case $WC in 5787 [\\/]* | ?:[\\/]*) 5788 ac_cv_path_WC="$WC" # Let the user override the test with a path. 5789 ;; 5790 *) 5791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5792 for as_dir in $PATH 5793 do 5794 IFS=$as_save_IFS 5795 test -z "$as_dir" && as_dir=. 5796 for ac_exec_ext in '' $ac_executable_extensions; do 5797 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5798 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 5799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5800 break 2 5801 fi 5802 done 5803 done 5804 IFS=$as_save_IFS 5805 5806 ;; 5807 esac 5808 fi 5809 WC=$ac_cv_path_WC 5810 if test -n "$WC"; then 5811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 5812 $as_echo "$WC" >&6; } 5813 else 5814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5815 $as_echo "no" >&6; } 5816 fi 5817 5818 5819 test -n "$WC" && break 5820 done 5821 5822 5823 if test "x$WC" = x; then 5824 if test "xwc" = x; then 5825 PROG_NAME=wc 5826 else 5827 PROG_NAME=wc 5828 fi 5829 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5830 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5831 as_fn_error $? "Cannot continue" "$LINENO" 5 5832 fi 5833 5834 5835 5836 for ac_prog in which 5837 do 5838 # Extract the first word of "$ac_prog", so it can be a program name with args. 5839 set dummy $ac_prog; ac_word=$2 5840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5841 $as_echo_n "checking for $ac_word... " >&6; } 5842 if ${ac_cv_path_WHICH+:} false; then : 5843 $as_echo_n "(cached) " >&6 5844 else 5845 case $WHICH in 5846 [\\/]* | ?:[\\/]*) 5847 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 5848 ;; 5849 *) 5850 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5851 for as_dir in $PATH 5852 do 5853 IFS=$as_save_IFS 5854 test -z "$as_dir" && as_dir=. 5855 for ac_exec_ext in '' $ac_executable_extensions; do 5856 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5857 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 5858 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5859 break 2 5860 fi 5861 done 5862 done 5863 IFS=$as_save_IFS 5864 5865 ;; 5866 esac 5867 fi 5868 WHICH=$ac_cv_path_WHICH 5869 if test -n "$WHICH"; then 5870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 5871 $as_echo "$WHICH" >&6; } 5872 else 5873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5874 $as_echo "no" >&6; } 5875 fi 5876 5877 5878 test -n "$WHICH" && break 5879 done 5880 5881 5882 if test "x$WHICH" = x; then 5883 if test "xwhich" = x; then 5884 PROG_NAME=which 5885 else 5886 PROG_NAME=which 5887 fi 5888 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5889 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5890 as_fn_error $? "Cannot continue" "$LINENO" 5 5891 fi 5892 5893 5894 5895 for ac_prog in xargs 5896 do 5897 # Extract the first word of "$ac_prog", so it can be a program name with args. 5898 set dummy $ac_prog; ac_word=$2 5899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5900 $as_echo_n "checking for $ac_word... " >&6; } 5901 if ${ac_cv_path_XARGS+:} false; then : 5902 $as_echo_n "(cached) " >&6 5903 else 5904 case $XARGS in 5905 [\\/]* | ?:[\\/]*) 5906 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 5907 ;; 5908 *) 5909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5910 for as_dir in $PATH 5911 do 5912 IFS=$as_save_IFS 5913 test -z "$as_dir" && as_dir=. 5914 for ac_exec_ext in '' $ac_executable_extensions; do 5915 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5916 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 5917 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5918 break 2 5919 fi 5920 done 5921 done 5922 IFS=$as_save_IFS 5923 5924 ;; 5925 esac 5926 fi 5927 XARGS=$ac_cv_path_XARGS 5928 if test -n "$XARGS"; then 5929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 5930 $as_echo "$XARGS" >&6; } 5931 else 5932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5933 $as_echo "no" >&6; } 5934 fi 5935 5936 5937 test -n "$XARGS" && break 5938 done 5939 5940 5941 if test "x$XARGS" = x; then 5942 if test "xxargs" = x; then 5943 PROG_NAME=xargs 5944 else 5945 PROG_NAME=xargs 5946 fi 5947 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 5948 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 5949 as_fn_error $? "Cannot continue" "$LINENO" 5 5950 fi 5951 5952 5953 5954 # Then required tools that require some special treatment. 5955 for ac_prog in gawk mawk nawk awk 5956 do 5957 # Extract the first word of "$ac_prog", so it can be a program name with args. 5958 set dummy $ac_prog; ac_word=$2 5959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5960 $as_echo_n "checking for $ac_word... " >&6; } 5961 if ${ac_cv_prog_AWK+:} false; then : 5962 $as_echo_n "(cached) " >&6 5963 else 5964 if test -n "$AWK"; then 5965 ac_cv_prog_AWK="$AWK" # Let the user override the test. 5966 else 5967 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5968 for as_dir in $PATH 5969 do 5970 IFS=$as_save_IFS 5971 test -z "$as_dir" && as_dir=. 5972 for ac_exec_ext in '' $ac_executable_extensions; do 5973 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 5974 ac_cv_prog_AWK="$ac_prog" 5975 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5976 break 2 5977 fi 5978 done 5979 done 5980 IFS=$as_save_IFS 5981 5982 fi 5983 fi 5984 AWK=$ac_cv_prog_AWK 5985 if test -n "$AWK"; then 5986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 5987 $as_echo "$AWK" >&6; } 5988 else 5989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5990 $as_echo "no" >&6; } 5991 fi 5992 5993 5994 test -n "$AWK" && break 5995 done 5996 5997 5998 if test "x$AWK" = x; then 5999 if test "x" = x; then 6000 PROG_NAME=awk 6001 else 6002 PROG_NAME= 6003 fi 6004 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6005 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6006 as_fn_error $? "Cannot continue" "$LINENO" 5 6007 fi 6008 6009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 6010 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 6011 if ${ac_cv_path_GREP+:} false; then : 6012 $as_echo_n "(cached) " >&6 6013 else 6014 if test -z "$GREP"; then 6015 ac_path_GREP_found=false 6016 # Loop through the user's path and test for each of PROGNAME-LIST 6017 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6018 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6019 do 6020 IFS=$as_save_IFS 6021 test -z "$as_dir" && as_dir=. 6022 for ac_prog in grep ggrep; do 6023 for ac_exec_ext in '' $ac_executable_extensions; do 6024 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 6025 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue 6026 # Check for GNU ac_path_GREP and select it if it is found. 6027 # Check for GNU $ac_path_GREP 6028 case `"$ac_path_GREP" --version 2>&1` in 6029 *GNU*) 6030 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 6031 *) 6032 ac_count=0 6033 $as_echo_n 0123456789 >"conftest.in" 6034 while : 6035 do 6036 cat "conftest.in" "conftest.in" >"conftest.tmp" 6037 mv "conftest.tmp" "conftest.in" 6038 cp "conftest.in" "conftest.nl" 6039 $as_echo 'GREP' >> "conftest.nl" 6040 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 6041 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6042 as_fn_arith $ac_count + 1 && ac_count=$as_val 6043 if test $ac_count -gt ${ac_path_GREP_max-0}; then 6044 # Best one so far, save it but keep looking for a better one 6045 ac_cv_path_GREP="$ac_path_GREP" 6046 ac_path_GREP_max=$ac_count 6047 fi 6048 # 10*(2^10) chars as input seems more than enough 6049 test $ac_count -gt 10 && break 6050 done 6051 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6052 esac 6053 6054 $ac_path_GREP_found && break 3 6055 done 6056 done 6057 done 6058 IFS=$as_save_IFS 6059 if test -z "$ac_cv_path_GREP"; then 6060 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6061 fi 6062 else 6063 ac_cv_path_GREP=$GREP 6064 fi 6065 6066 fi 6067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 6068 $as_echo "$ac_cv_path_GREP" >&6; } 6069 GREP="$ac_cv_path_GREP" 6070 6071 6072 6073 if test "x$GREP" = x; then 6074 if test "x" = x; then 6075 PROG_NAME=grep 6076 else 6077 PROG_NAME= 6078 fi 6079 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6080 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6081 as_fn_error $? "Cannot continue" "$LINENO" 5 6082 fi 6083 6084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 6085 $as_echo_n "checking for egrep... " >&6; } 6086 if ${ac_cv_path_EGREP+:} false; then : 6087 $as_echo_n "(cached) " >&6 6088 else 6089 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 6090 then ac_cv_path_EGREP="$GREP -E" 6091 else 6092 if test -z "$EGREP"; then 6093 ac_path_EGREP_found=false 6094 # Loop through the user's path and test for each of PROGNAME-LIST 6095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6096 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6097 do 6098 IFS=$as_save_IFS 6099 test -z "$as_dir" && as_dir=. 6100 for ac_prog in egrep; do 6101 for ac_exec_ext in '' $ac_executable_extensions; do 6102 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 6103 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue 6104 # Check for GNU ac_path_EGREP and select it if it is found. 6105 # Check for GNU $ac_path_EGREP 6106 case `"$ac_path_EGREP" --version 2>&1` in 6107 *GNU*) 6108 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 6109 *) 6110 ac_count=0 6111 $as_echo_n 0123456789 >"conftest.in" 6112 while : 6113 do 6114 cat "conftest.in" "conftest.in" >"conftest.tmp" 6115 mv "conftest.tmp" "conftest.in" 6116 cp "conftest.in" "conftest.nl" 6117 $as_echo 'EGREP' >> "conftest.nl" 6118 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 6119 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6120 as_fn_arith $ac_count + 1 && ac_count=$as_val 6121 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 6122 # Best one so far, save it but keep looking for a better one 6123 ac_cv_path_EGREP="$ac_path_EGREP" 6124 ac_path_EGREP_max=$ac_count 6125 fi 6126 # 10*(2^10) chars as input seems more than enough 6127 test $ac_count -gt 10 && break 6128 done 6129 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6130 esac 6131 6132 $ac_path_EGREP_found && break 3 6133 done 6134 done 6135 done 6136 IFS=$as_save_IFS 6137 if test -z "$ac_cv_path_EGREP"; then 6138 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6139 fi 6140 else 6141 ac_cv_path_EGREP=$EGREP 6142 fi 6143 6144 fi 6145 fi 6146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 6147 $as_echo "$ac_cv_path_EGREP" >&6; } 6148 EGREP="$ac_cv_path_EGREP" 6149 6150 6151 6152 if test "x$EGREP" = x; then 6153 if test "x" = x; then 6154 PROG_NAME=egrep 6155 else 6156 PROG_NAME= 6157 fi 6158 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6159 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6160 as_fn_error $? "Cannot continue" "$LINENO" 5 6161 fi 6162 6163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 6164 $as_echo_n "checking for fgrep... " >&6; } 6165 if ${ac_cv_path_FGREP+:} false; then : 6166 $as_echo_n "(cached) " >&6 6167 else 6168 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 6169 then ac_cv_path_FGREP="$GREP -F" 6170 else 6171 if test -z "$FGREP"; then 6172 ac_path_FGREP_found=false 6173 # Loop through the user's path and test for each of PROGNAME-LIST 6174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6175 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 6176 do 6177 IFS=$as_save_IFS 6178 test -z "$as_dir" && as_dir=. 6179 for ac_prog in fgrep; do 6180 for ac_exec_ext in '' $ac_executable_extensions; do 6181 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 6182 { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue 6183 # Check for GNU ac_path_FGREP and select it if it is found. 6184 # Check for GNU $ac_path_FGREP 6185 case `"$ac_path_FGREP" --version 2>&1` in 6186 *GNU*) 6187 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 6188 *) 6189 ac_count=0 6190 $as_echo_n 0123456789 >"conftest.in" 6191 while : 6192 do 6193 cat "conftest.in" "conftest.in" >"conftest.tmp" 6194 mv "conftest.tmp" "conftest.in" 6195 cp "conftest.in" "conftest.nl" 6196 $as_echo 'FGREP' >> "conftest.nl" 6197 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 6198 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6199 as_fn_arith $ac_count + 1 && ac_count=$as_val 6200 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 6201 # Best one so far, save it but keep looking for a better one 6202 ac_cv_path_FGREP="$ac_path_FGREP" 6203 ac_path_FGREP_max=$ac_count 6204 fi 6205 # 10*(2^10) chars as input seems more than enough 6206 test $ac_count -gt 10 && break 6207 done 6208 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6209 esac 6210 6211 $ac_path_FGREP_found && break 3 6212 done 6213 done 6214 done 6215 IFS=$as_save_IFS 6216 if test -z "$ac_cv_path_FGREP"; then 6217 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 6218 fi 6219 else 6220 ac_cv_path_FGREP=$FGREP 6221 fi 6222 6223 fi 6224 fi 6225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 6226 $as_echo "$ac_cv_path_FGREP" >&6; } 6227 FGREP="$ac_cv_path_FGREP" 6228 6229 6230 6231 if test "x$FGREP" = x; then 6232 if test "x" = x; then 6233 PROG_NAME=fgrep 6234 else 6235 PROG_NAME= 6236 fi 6237 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6238 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6239 as_fn_error $? "Cannot continue" "$LINENO" 5 6240 fi 6241 6242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 6243 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 6244 if ${ac_cv_path_SED+:} false; then : 6245 $as_echo_n "(cached) " >&6 6246 else 6247 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 6248 for ac_i in 1 2 3 4 5 6 7; do 6249 ac_script="$ac_script$as_nl$ac_script" 6250 done 6251 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 6252 { ac_script=; unset ac_script;} 6253 if test -z "$SED"; then 6254 ac_path_SED_found=false 6255 # Loop through the user's path and test for each of PROGNAME-LIST 6256 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6257 for as_dir in $PATH 6258 do 6259 IFS=$as_save_IFS 6260 test -z "$as_dir" && as_dir=. 6261 for ac_prog in sed gsed; do 6262 for ac_exec_ext in '' $ac_executable_extensions; do 6263 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 6264 { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue 6265 # Check for GNU ac_path_SED and select it if it is found. 6266 # Check for GNU $ac_path_SED 6267 case `"$ac_path_SED" --version 2>&1` in 6268 *GNU*) 6269 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 6270 *) 6271 ac_count=0 6272 $as_echo_n 0123456789 >"conftest.in" 6273 while : 6274 do 6275 cat "conftest.in" "conftest.in" >"conftest.tmp" 6276 mv "conftest.tmp" "conftest.in" 6277 cp "conftest.in" "conftest.nl" 6278 $as_echo '' >> "conftest.nl" 6279 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 6280 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 6281 as_fn_arith $ac_count + 1 && ac_count=$as_val 6282 if test $ac_count -gt ${ac_path_SED_max-0}; then 6283 # Best one so far, save it but keep looking for a better one 6284 ac_cv_path_SED="$ac_path_SED" 6285 ac_path_SED_max=$ac_count 6286 fi 6287 # 10*(2^10) chars as input seems more than enough 6288 test $ac_count -gt 10 && break 6289 done 6290 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 6291 esac 6292 6293 $ac_path_SED_found && break 3 6294 done 6295 done 6296 done 6297 IFS=$as_save_IFS 6298 if test -z "$ac_cv_path_SED"; then 6299 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 6300 fi 6301 else 6302 ac_cv_path_SED=$SED 6303 fi 6304 6305 fi 6306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 6307 $as_echo "$ac_cv_path_SED" >&6; } 6308 SED="$ac_cv_path_SED" 6309 rm -f conftest.sed 6310 6311 6312 if test "x$SED" = x; then 6313 if test "x" = x; then 6314 PROG_NAME=sed 6315 else 6316 PROG_NAME= 6317 fi 6318 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6319 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6320 as_fn_error $? "Cannot continue" "$LINENO" 5 6321 fi 6322 6323 6324 for ac_prog in nawk gawk awk 6325 do 6326 # Extract the first word of "$ac_prog", so it can be a program name with args. 6327 set dummy $ac_prog; ac_word=$2 6328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6329 $as_echo_n "checking for $ac_word... " >&6; } 6330 if ${ac_cv_path_NAWK+:} false; then : 6331 $as_echo_n "(cached) " >&6 6332 else 6333 case $NAWK in 6334 [\\/]* | ?:[\\/]*) 6335 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 6336 ;; 6337 *) 6338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6339 for as_dir in $PATH 6340 do 6341 IFS=$as_save_IFS 6342 test -z "$as_dir" && as_dir=. 6343 for ac_exec_ext in '' $ac_executable_extensions; do 6344 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6345 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 6346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6347 break 2 6348 fi 6349 done 6350 done 6351 IFS=$as_save_IFS 6352 6353 ;; 6354 esac 6355 fi 6356 NAWK=$ac_cv_path_NAWK 6357 if test -n "$NAWK"; then 6358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 6359 $as_echo "$NAWK" >&6; } 6360 else 6361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6362 $as_echo "no" >&6; } 6363 fi 6364 6365 6366 test -n "$NAWK" && break 6367 done 6368 6369 6370 if test "x$NAWK" = x; then 6371 if test "x" = x; then 6372 PROG_NAME=nawk 6373 else 6374 PROG_NAME= 6375 fi 6376 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 6377 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 6378 as_fn_error $? "Cannot continue" "$LINENO" 5 6379 fi 6380 6381 6382 # Always force rm. 6383 RM="$RM -f" 6384 6385 # pwd behaves differently on various platforms and some don't support the -L flag. 6386 # Always use the bash builtin pwd to get uniform behavior. 6387 THEPWDCMD=pwd 6388 6389 # These are not required on all platforms 6390 # Extract the first word of "cygpath", so it can be a program name with args. 6391 set dummy cygpath; ac_word=$2 6392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6393 $as_echo_n "checking for $ac_word... " >&6; } 6394 if ${ac_cv_path_CYGPATH+:} false; then : 6395 $as_echo_n "(cached) " >&6 6396 else 6397 case $CYGPATH in 6398 [\\/]* | ?:[\\/]*) 6399 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 6400 ;; 6401 *) 6402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6403 for as_dir in $PATH 6404 do 6405 IFS=$as_save_IFS 6406 test -z "$as_dir" && as_dir=. 6407 for ac_exec_ext in '' $ac_executable_extensions; do 6408 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6409 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 6410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6411 break 2 6412 fi 6413 done 6414 done 6415 IFS=$as_save_IFS 6416 6417 ;; 6418 esac 6419 fi 6420 CYGPATH=$ac_cv_path_CYGPATH 6421 if test -n "$CYGPATH"; then 6422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 6423 $as_echo "$CYGPATH" >&6; } 6424 else 6425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6426 $as_echo "no" >&6; } 6427 fi 6428 6429 6430 # Extract the first word of "readlink", so it can be a program name with args. 6431 set dummy readlink; ac_word=$2 6432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6433 $as_echo_n "checking for $ac_word... " >&6; } 6434 if ${ac_cv_path_READLINK+:} false; then : 6435 $as_echo_n "(cached) " >&6 6436 else 6437 case $READLINK in 6438 [\\/]* | ?:[\\/]*) 6439 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 6440 ;; 6441 *) 6442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6443 for as_dir in $PATH 6444 do 6445 IFS=$as_save_IFS 6446 test -z "$as_dir" && as_dir=. 6447 for ac_exec_ext in '' $ac_executable_extensions; do 6448 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6449 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 6450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6451 break 2 6452 fi 6453 done 6454 done 6455 IFS=$as_save_IFS 6456 6457 ;; 6458 esac 6459 fi 6460 READLINK=$ac_cv_path_READLINK 6461 if test -n "$READLINK"; then 6462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 6463 $as_echo "$READLINK" >&6; } 6464 else 6465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6466 $as_echo "no" >&6; } 6467 fi 6468 6469 6470 # Extract the first word of "df", so it can be a program name with args. 6471 set dummy df; ac_word=$2 6472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6473 $as_echo_n "checking for $ac_word... " >&6; } 6474 if ${ac_cv_path_DF+:} false; then : 6475 $as_echo_n "(cached) " >&6 6476 else 6477 case $DF in 6478 [\\/]* | ?:[\\/]*) 6479 ac_cv_path_DF="$DF" # Let the user override the test with a path. 6480 ;; 6481 *) 6482 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6483 for as_dir in $PATH 6484 do 6485 IFS=$as_save_IFS 6486 test -z "$as_dir" && as_dir=. 6487 for ac_exec_ext in '' $ac_executable_extensions; do 6488 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6489 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 6490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6491 break 2 6492 fi 6493 done 6494 done 6495 IFS=$as_save_IFS 6496 6497 ;; 6498 esac 6499 fi 6500 DF=$ac_cv_path_DF 6501 if test -n "$DF"; then 6502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 6503 $as_echo "$DF" >&6; } 6504 else 6505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6506 $as_echo "no" >&6; } 6507 fi 6508 6509 6510 # Extract the first word of "SetFile", so it can be a program name with args. 6511 set dummy SetFile; ac_word=$2 6512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6513 $as_echo_n "checking for $ac_word... " >&6; } 6514 if ${ac_cv_path_SETFILE+:} false; then : 6515 $as_echo_n "(cached) " >&6 6516 else 6517 case $SETFILE in 6518 [\\/]* | ?:[\\/]*) 6519 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 6520 ;; 6521 *) 6522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6523 for as_dir in $PATH 6524 do 6525 IFS=$as_save_IFS 6526 test -z "$as_dir" && as_dir=. 6527 for ac_exec_ext in '' $ac_executable_extensions; do 6528 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 6529 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 6530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6531 break 2 6532 fi 6533 done 6534 done 6535 IFS=$as_save_IFS 6536 6537 ;; 6538 esac 6539 fi 6540 SETFILE=$ac_cv_path_SETFILE 6541 if test -n "$SETFILE"; then 6542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 6543 $as_echo "$SETFILE" >&6; } 6544 else 6545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6546 $as_echo "no" >&6; } 6547 fi 6548 6549 6550 6551 6552 # Now we can determine OpenJDK build and target platforms. This is required to 6553 # have early on. 6554 # Make sure we can run config.sub. 6555 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 6556 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 6557 6558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 6559 $as_echo_n "checking build system type... " >&6; } 6560 if ${ac_cv_build+:} false; then : 6561 $as_echo_n "(cached) " >&6 6562 else 6563 ac_build_alias=$build_alias 6564 test "x$ac_build_alias" = x && 6565 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 6566 test "x$ac_build_alias" = x && 6567 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 6568 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 6569 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 6570 6571 fi 6572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 6573 $as_echo "$ac_cv_build" >&6; } 6574 case $ac_cv_build in 6575 *-*-*) ;; 6576 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 6577 esac 6578 build=$ac_cv_build 6579 ac_save_IFS=$IFS; IFS='-' 6580 set x $ac_cv_build 6581 shift 6582 build_cpu=$1 6583 build_vendor=$2 6584 shift; shift 6585 # Remember, the first character of IFS is used to create $*, 6586 # except with old shells: 6587 build_os=$* 6588 IFS=$ac_save_IFS 6589 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 6590 6591 6592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 6593 $as_echo_n "checking host system type... " >&6; } 6594 if ${ac_cv_host+:} false; then : 6595 $as_echo_n "(cached) " >&6 6596 else 6597 if test "x$host_alias" = x; then 6598 ac_cv_host=$ac_cv_build 6599 else 6600 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 6601 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 6602 fi 6603 6604 fi 6605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 6606 $as_echo "$ac_cv_host" >&6; } 6607 case $ac_cv_host in 6608 *-*-*) ;; 6609 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 6610 esac 6611 host=$ac_cv_host 6612 ac_save_IFS=$IFS; IFS='-' 6613 set x $ac_cv_host 6614 shift 6615 host_cpu=$1 6616 host_vendor=$2 6617 shift; shift 6618 # Remember, the first character of IFS is used to create $*, 6619 # except with old shells: 6620 host_os=$* 6621 IFS=$ac_save_IFS 6622 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 6623 6624 6625 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 6626 $as_echo_n "checking target system type... " >&6; } 6627 if ${ac_cv_target+:} false; then : 6628 $as_echo_n "(cached) " >&6 6629 else 6630 if test "x$target_alias" = x; then 6631 ac_cv_target=$ac_cv_host 6632 else 6633 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 6634 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 6635 fi 6636 6637 fi 6638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 6639 $as_echo "$ac_cv_target" >&6; } 6640 case $ac_cv_target in 6641 *-*-*) ;; 6642 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 6643 esac 6644 target=$ac_cv_target 6645 ac_save_IFS=$IFS; IFS='-' 6646 set x $ac_cv_target 6647 shift 6648 target_cpu=$1 6649 target_vendor=$2 6650 shift; shift 6651 # Remember, the first character of IFS is used to create $*, 6652 # except with old shells: 6653 target_os=$* 6654 IFS=$ac_save_IFS 6655 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 6656 6657 6658 # The aliases save the names the user supplied, while $host etc. 6659 # will get canonicalized. 6660 test -n "$target_alias" && 6661 test "$program_prefix$program_suffix$program_transform_name" = \ 6662 NONENONEs,x,x, && 6663 program_prefix=${target_alias}- 6664 6665 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 6666 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 6667 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 6668 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 6669 # to use the configure naming style. 6670 6671 6672 6673 6674 6675 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 6676 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 6677 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 6678 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 6679 OPENJDK_TARGET_AUTOCONF_NAME="$host" 6680 OPENJDK_BUILD_AUTOCONF_NAME="$build" 6681 6682 6683 6684 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 6685 6686 case "$build_os" in 6687 *linux*) 6688 VAR_OS=linux 6689 VAR_OS_API=posix 6690 VAR_OS_ENV=linux 6691 ;; 6692 *solaris*) 6693 VAR_OS=solaris 6694 VAR_OS_API=posix 6695 VAR_OS_ENV=solaris 6696 ;; 6697 *darwin*) 6698 VAR_OS=macosx 6699 VAR_OS_API=posix 6700 VAR_OS_ENV=macosx 6701 ;; 6702 *bsd*) 6703 VAR_OS=bsd 6704 VAR_OS_API=posix 6705 VAR_OS_ENV=bsd 6706 ;; 6707 *cygwin*) 6708 VAR_OS=windows 6709 VAR_OS_API=winapi 6710 VAR_OS_ENV=windows.cygwin 6711 ;; 6712 *mingw*) 6713 VAR_OS=windows 6714 VAR_OS_API=winapi 6715 VAR_OS_ENV=windows.msys 6716 ;; 6717 *) 6718 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 6719 ;; 6720 esac 6721 6722 6723 # First argument is the cpu name from the trip/quad 6724 case "$build_cpu" in 6725 x86_64) 6726 VAR_CPU=x86_64 6727 VAR_CPU_ARCH=x86 6728 VAR_CPU_BITS=64 6729 VAR_CPU_ENDIAN=little 6730 ;; 6731 i?86) 6732 VAR_CPU=x86 6733 VAR_CPU_ARCH=x86 6734 VAR_CPU_BITS=32 6735 VAR_CPU_ENDIAN=little 6736 ;; 6737 arm*) 6738 VAR_CPU=arm 6739 VAR_CPU_ARCH=arm 6740 VAR_CPU_BITS=32 6741 VAR_CPU_ENDIAN=little 6742 ;; 6743 powerpc) 6744 VAR_CPU=ppc 6745 VAR_CPU_ARCH=ppc 6746 VAR_CPU_BITS=32 6747 VAR_CPU_ENDIAN=big 6748 ;; 6749 powerpc64) 6750 VAR_CPU=ppc64 6751 VAR_CPU_ARCH=ppc 6752 VAR_CPU_BITS=64 6753 VAR_CPU_ENDIAN=big 6754 ;; 6755 sparc) 6756 VAR_CPU=sparc 6757 VAR_CPU_ARCH=sparc 6758 VAR_CPU_BITS=32 6759 VAR_CPU_ENDIAN=big 6760 ;; 6761 sparcv9) 6762 VAR_CPU=sparcv9 6763 VAR_CPU_ARCH=sparc 6764 VAR_CPU_BITS=64 6765 VAR_CPU_ENDIAN=big 6766 ;; 6767 *) 6768 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 6769 ;; 6770 esac 6771 6772 # ..and setup our own variables. (Do this explicitely to facilitate searching) 6773 OPENJDK_BUILD_OS="$VAR_OS" 6774 OPENJDK_BUILD_OS_API="$VAR_OS_API" 6775 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 6776 OPENJDK_BUILD_CPU="$VAR_CPU" 6777 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 6778 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 6779 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 6780 6781 6782 6783 6784 6785 6786 6787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 6788 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 6789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 6790 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 6791 6792 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 6793 6794 case "$host_os" in 6795 *linux*) 6796 VAR_OS=linux 6797 VAR_OS_API=posix 6798 VAR_OS_ENV=linux 6799 ;; 6800 *solaris*) 6801 VAR_OS=solaris 6802 VAR_OS_API=posix 6803 VAR_OS_ENV=solaris 6804 ;; 6805 *darwin*) 6806 VAR_OS=macosx 6807 VAR_OS_API=posix 6808 VAR_OS_ENV=macosx 6809 ;; 6810 *bsd*) 6811 VAR_OS=bsd 6812 VAR_OS_API=posix 6813 VAR_OS_ENV=bsd 6814 ;; 6815 *cygwin*) 6816 VAR_OS=windows 6817 VAR_OS_API=winapi 6818 VAR_OS_ENV=windows.cygwin 6819 ;; 6820 *mingw*) 6821 VAR_OS=windows 6822 VAR_OS_API=winapi 6823 VAR_OS_ENV=windows.msys 6824 ;; 6825 *) 6826 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 6827 ;; 6828 esac 6829 6830 6831 # First argument is the cpu name from the trip/quad 6832 case "$host_cpu" in 6833 x86_64) 6834 VAR_CPU=x86_64 6835 VAR_CPU_ARCH=x86 6836 VAR_CPU_BITS=64 6837 VAR_CPU_ENDIAN=little 6838 ;; 6839 i?86) 6840 VAR_CPU=x86 6841 VAR_CPU_ARCH=x86 6842 VAR_CPU_BITS=32 6843 VAR_CPU_ENDIAN=little 6844 ;; 6845 arm*) 6846 VAR_CPU=arm 6847 VAR_CPU_ARCH=arm 6848 VAR_CPU_BITS=32 6849 VAR_CPU_ENDIAN=little 6850 ;; 6851 powerpc) 6852 VAR_CPU=ppc 6853 VAR_CPU_ARCH=ppc 6854 VAR_CPU_BITS=32 6855 VAR_CPU_ENDIAN=big 6856 ;; 6857 powerpc64) 6858 VAR_CPU=ppc64 6859 VAR_CPU_ARCH=ppc 6860 VAR_CPU_BITS=64 6861 VAR_CPU_ENDIAN=big 6862 ;; 6863 sparc) 6864 VAR_CPU=sparc 6865 VAR_CPU_ARCH=sparc 6866 VAR_CPU_BITS=32 6867 VAR_CPU_ENDIAN=big 6868 ;; 6869 sparcv9) 6870 VAR_CPU=sparcv9 6871 VAR_CPU_ARCH=sparc 6872 VAR_CPU_BITS=64 6873 VAR_CPU_ENDIAN=big 6874 ;; 6875 *) 6876 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 6877 ;; 6878 esac 6879 6880 # ... and setup our own variables. (Do this explicitely to facilitate searching) 6881 OPENJDK_TARGET_OS="$VAR_OS" 6882 OPENJDK_TARGET_OS_API="$VAR_OS_API" 6883 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 6884 OPENJDK_TARGET_CPU="$VAR_CPU" 6885 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 6886 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 6887 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 6888 6889 6890 6891 6892 6893 6894 6895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 6896 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 6897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 6898 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 6899 6900 6901 6902 # Check whether --with-target-bits was given. 6903 if test "${with_target_bits+set}" = set; then : 6904 withval=$with_target_bits; 6905 fi 6906 6907 6908 # We have three types of compiles: 6909 # native == normal compilation, target system == build system 6910 # cross == traditional cross compilation, target system != build system; special toolchain needed 6911 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 6912 # 6913 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 6914 # We're doing a proper cross-compilation 6915 COMPILE_TYPE="cross" 6916 else 6917 COMPILE_TYPE="native" 6918 fi 6919 6920 if test "x$with_target_bits" != x; then 6921 if test "x$COMPILE_TYPE" = "xcross"; then 6922 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 6923 fi 6924 6925 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 6926 # A reduced build is requested 6927 COMPILE_TYPE="reduced" 6928 OPENJDK_TARGET_CPU_BITS=32 6929 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 6930 OPENJDK_TARGET_CPU=x86 6931 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 6932 OPENJDK_TARGET_CPU=sparc 6933 else 6934 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 6935 fi 6936 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 6937 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 6938 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 6939 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 6940 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 6941 else 6942 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 6943 fi 6944 fi 6945 6946 6947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 6948 $as_echo_n "checking compilation type... " >&6; } 6949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 6950 $as_echo "$COMPILE_TYPE" >&6; } 6951 6952 6953 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 6954 REQUIRED_OS_NAME=SunOS 6955 REQUIRED_OS_VERSION=5.10 6956 fi 6957 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 6958 REQUIRED_OS_NAME=Linux 6959 REQUIRED_OS_VERSION=2.6 6960 fi 6961 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 6962 REQUIRED_OS_NAME=Windows 6963 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 6964 REQUIRED_OS_VERSION=5.2 6965 else 6966 REQUIRED_OS_VERSION=5.1 6967 fi 6968 fi 6969 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 6970 REQUIRED_OS_NAME=Darwin 6971 REQUIRED_OS_VERSION=11.2 6972 fi 6973 6974 6975 6976 6977 6978 # Also store the legacy naming of the cpu. 6979 # Ie i586 and amd64 instead of x86 and x86_64 6980 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 6981 if test "x$OPENJDK_TARGET_CPU" = xx86; then 6982 OPENJDK_TARGET_CPU_LEGACY="i586" 6983 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 6984 # On all platforms except MacOSX replace x86_64 with amd64. 6985 OPENJDK_TARGET_CPU_LEGACY="amd64" 6986 fi 6987 6988 6989 # And the second legacy naming of the cpu. 6990 # Ie i386 and amd64 instead of x86 and x86_64. 6991 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 6992 if test "x$OPENJDK_TARGET_CPU" = xx86; then 6993 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 6994 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 6995 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 6996 fi 6997 6998 6999 # This is the name of the cpu (but using i386 and amd64 instead of 7000 # x86 and x86_64, respectively), preceeded by a /, to be used when 7001 # locating libraries. On macosx, it's empty, though. 7002 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 7003 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 7004 OPENJDK_TARGET_CPU_LIBDIR="" 7005 fi 7006 7007 7008 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 7009 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 7010 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 7011 OPENJDK_TARGET_CPU_ISADIR="" 7012 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 7013 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7014 OPENJDK_TARGET_CPU_ISADIR="/amd64" 7015 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 7016 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 7017 fi 7018 fi 7019 7020 7021 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 7022 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 7023 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 7024 # On linux only, we replace x86 with i386. 7025 OPENJDK_TARGET_CPU_OSARCH="i386" 7026 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7027 # On all platforms except macosx, we replace x86_64 with amd64. 7028 OPENJDK_TARGET_CPU_OSARCH="amd64" 7029 fi 7030 7031 7032 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 7033 if test "x$OPENJDK_TARGET_CPU" = xx86; then 7034 OPENJDK_TARGET_CPU_JLI="i386" 7035 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 7036 # On all platforms except macosx, we replace x86_64 with amd64. 7037 OPENJDK_TARGET_CPU_JLI="amd64" 7038 fi 7039 # Now setup the -D flags for building libjli. 7040 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 7041 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 7042 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 7043 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 7044 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 7045 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 7046 fi 7047 fi 7048 7049 7050 # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths. 7051 if test "x$OPENJDK_TARGET_OS_API" = xposix; then 7052 OPENJDK_TARGET_OS_API_DIR="solaris" 7053 fi 7054 if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then 7055 OPENJDK_TARGET_OS_API_DIR="windows" 7056 fi 7057 7058 7059 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7060 A_LP64="LP64:=" 7061 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 7062 # unpack200.exe 7063 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 7064 ADD_LP64="-D_LP64=1" 7065 fi 7066 fi 7067 LP64=$A_LP64 7068 7069 7070 if test "x$COMPILE_TYPE" = "xcross"; then 7071 # FIXME: ... or should this include reduced builds..? 7072 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 7073 else 7074 DEFINE_CROSS_COMPILE_ARCH="" 7075 fi 7076 7077 7078 # ZERO_ARCHDEF is used to enable architecture-specific code 7079 case "${OPENJDK_TARGET_CPU}" in 7080 ppc*) ZERO_ARCHDEF=PPC ;; 7081 s390*) ZERO_ARCHDEF=S390 ;; 7082 sparc*) ZERO_ARCHDEF=SPARC ;; 7083 x86_64*) ZERO_ARCHDEF=AMD64 ;; 7084 x86) ZERO_ARCHDEF=IA32 ;; 7085 *) ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z) 7086 esac 7087 7088 7089 7090 7091 7092 # Continue setting up basic stuff. Most remaining code require fundamental tools. 7093 7094 # Locate the directory of this script. 7095 SCRIPT="$0" 7096 AUTOCONF_DIR=`cd \`$DIRNAME $SCRIPT\`; $THEPWDCMD -L` 7097 7098 # Where is the source? It is located two levels above the configure script. 7099 CURDIR="$PWD" 7100 cd "$AUTOCONF_DIR/../.." 7101 SRC_ROOT="`$THEPWDCMD -L`" 7102 7103 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 7104 PATH_SEP=";" 7105 7106 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 7107 if test $SRC_ROOT_LENGTH -gt 100; then 7108 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 7109 fi 7110 7111 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 7113 $as_echo_n "checking cygwin release... " >&6; } 7114 CYGWIN_VERSION=`$UNAME -r` 7115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 7116 $as_echo "$CYGWIN_VERSION" >&6; } 7117 WINDOWS_ENV_VENDOR='cygwin' 7118 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 7119 7120 CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.` 7121 if test "x$CYGWIN_VERSION_OK" = x; then 7122 { $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 7123 $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;} 7124 as_fn_error $? "Cannot continue" "$LINENO" 5 7125 fi 7126 if test "x$CYGPATH" = x; then 7127 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 7128 fi 7129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 7130 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 7131 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 7132 cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"` 7133 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 7134 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 7135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 7136 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 7137 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 7138 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 7139 if test "x$test_cygdrive_prefix" = x; then 7140 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 7141 fi 7142 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 7144 $as_echo_n "checking msys release... " >&6; } 7145 MSYS_VERSION=`$UNAME -r` 7146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 7147 $as_echo "$MSYS_VERSION" >&6; } 7148 7149 WINDOWS_ENV_VENDOR='msys' 7150 WINDOWS_ENV_VERSION="$MSYS_VERSION" 7151 7152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 7153 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 7154 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 7155 MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"` 7156 7157 windows_path="$MSYS_ROOT_PATH" 7158 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7159 unix_path=`$CYGPATH -u "$windows_path"` 7160 MSYS_ROOT_PATH="$unix_path" 7161 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7162 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 7163 MSYS_ROOT_PATH="$unix_path" 7164 fi 7165 7166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 7167 $as_echo "$MSYS_ROOT_PATH" >&6; } 7168 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 7169 else 7170 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 7171 fi 7172 7173 # Test if windows or unix (cygwin/msys) find is first in path. 7174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 7175 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 7176 FIND_BINARY_OUTPUT=`find --version 2>&1` 7177 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 7178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 7179 $as_echo "unix style" >&6; } 7180 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 7181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 7182 $as_echo "Windows" >&6; } 7183 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 7184 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 7185 { $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 7186 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 7187 as_fn_error $? "Cannot continue" "$LINENO" 5 7188 else 7189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 7190 $as_echo "unknown" >&6; } 7191 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 7192 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 7193 fi 7194 7195 else 7196 PATH_SEP=":" 7197 fi 7198 7199 7200 7201 cd "$CURDIR" 7202 7203 7204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7205 7206 # Input might be given as Windows format, start by converting to 7207 # unix format. 7208 path="$SRC_ROOT" 7209 new_path=`$CYGPATH -u "$path"` 7210 7211 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 7212 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 7213 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 7214 # "foo.exe" is OK but "foo" is an error. 7215 # 7216 # This test is therefore slightly more accurate than "test -f" to check for file precense. 7217 # It is also a way to make sure we got the proper file name for the real test later on. 7218 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 7219 if test "x$test_shortpath" = x; then 7220 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&5 7221 $as_echo "$as_me: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&6;} 7222 as_fn_error $? "Cannot locate the the path of SRC_ROOT" "$LINENO" 5 7223 fi 7224 7225 # Call helper function which possibly converts this using DOS-style short mode. 7226 # If so, the updated path is stored in $new_path. 7227 7228 input_path="$new_path" 7229 # Check if we need to convert this using DOS-style short mode. If the path 7230 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7231 # take no chances and rewrite it. 7232 # Note: m4 eats our [], so we need to use [ and ] instead. 7233 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 7234 if test "x$has_forbidden_chars" != x; then 7235 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7236 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 7237 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 7238 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 7239 # Going to short mode and back again did indeed matter. Since short mode is 7240 # case insensitive, let's make it lowercase to improve readability. 7241 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7242 # Now convert it back to Unix-stile (cygpath) 7243 input_path=`$CYGPATH -u "$shortmode_path"` 7244 new_path="$input_path" 7245 fi 7246 fi 7247 7248 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 7249 if test "x$test_cygdrive_prefix" = x; then 7250 # As a simple fix, exclude /usr/bin since it's not a real path. 7251 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 7252 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 7253 # a path prefixed by /cygdrive for fixpath to work. 7254 new_path="$CYGWIN_ROOT_PATH$input_path" 7255 fi 7256 fi 7257 7258 7259 if test "x$path" != "x$new_path"; then 7260 SRC_ROOT="$new_path" 7261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting SRC_ROOT to \"$new_path\"" >&5 7262 $as_echo "$as_me: Rewriting SRC_ROOT to \"$new_path\"" >&6;} 7263 fi 7264 7265 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7266 7267 path="$SRC_ROOT" 7268 has_colon=`$ECHO $path | $GREP ^.:` 7269 new_path="$path" 7270 if test "x$has_colon" = x; then 7271 # Not in mixed or Windows style, start by that. 7272 new_path=`cmd //c echo $path` 7273 fi 7274 7275 7276 input_path="$new_path" 7277 # Check if we need to convert this using DOS-style short mode. If the path 7278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7279 # take no chances and rewrite it. 7280 # Note: m4 eats our [], so we need to use [ and ] instead. 7281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 7282 if test "x$has_forbidden_chars" != x; then 7283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7284 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7285 fi 7286 7287 7288 windows_path="$new_path" 7289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7290 unix_path=`$CYGPATH -u "$windows_path"` 7291 new_path="$unix_path" 7292 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7293 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 7294 new_path="$unix_path" 7295 fi 7296 7297 if test "x$path" != "x$new_path"; then 7298 SRC_ROOT="$new_path" 7299 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting SRC_ROOT to \"$new_path\"" >&5 7300 $as_echo "$as_me: Rewriting SRC_ROOT to \"$new_path\"" >&6;} 7301 fi 7302 7303 # Save the first 10 bytes of this path to the storage, so fixpath can work. 7304 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 7305 7306 else 7307 # We're on a posix platform. Hooray! :) 7308 path="$SRC_ROOT" 7309 has_space=`$ECHO "$path" | $GREP " "` 7310 if test "x$has_space" != x; then 7311 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&5 7312 $as_echo "$as_me: The path of SRC_ROOT, which resolves as \"$path\", is invalid." >&6;} 7313 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 7314 fi 7315 7316 # Use eval to expand a potential ~ 7317 eval path="$path" 7318 if test ! -f "$path" && test ! -d "$path"; then 7319 as_fn_error $? "The path of SRC_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 7320 fi 7321 7322 SRC_ROOT="`cd "$path"; $THEPWDCMD -L`" 7323 fi 7324 7325 7326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7327 7328 # Input might be given as Windows format, start by converting to 7329 # unix format. 7330 path="$CURDIR" 7331 new_path=`$CYGPATH -u "$path"` 7332 7333 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 7334 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 7335 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 7336 # "foo.exe" is OK but "foo" is an error. 7337 # 7338 # This test is therefore slightly more accurate than "test -f" to check for file precense. 7339 # It is also a way to make sure we got the proper file name for the real test later on. 7340 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 7341 if test "x$test_shortpath" = x; then 7342 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 7343 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 7344 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 7345 fi 7346 7347 # Call helper function which possibly converts this using DOS-style short mode. 7348 # If so, the updated path is stored in $new_path. 7349 7350 input_path="$new_path" 7351 # Check if we need to convert this using DOS-style short mode. If the path 7352 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7353 # take no chances and rewrite it. 7354 # Note: m4 eats our [], so we need to use [ and ] instead. 7355 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 7356 if test "x$has_forbidden_chars" != x; then 7357 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7358 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 7359 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 7360 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 7361 # Going to short mode and back again did indeed matter. Since short mode is 7362 # case insensitive, let's make it lowercase to improve readability. 7363 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7364 # Now convert it back to Unix-stile (cygpath) 7365 input_path=`$CYGPATH -u "$shortmode_path"` 7366 new_path="$input_path" 7367 fi 7368 fi 7369 7370 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 7371 if test "x$test_cygdrive_prefix" = x; then 7372 # As a simple fix, exclude /usr/bin since it's not a real path. 7373 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 7374 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 7375 # a path prefixed by /cygdrive for fixpath to work. 7376 new_path="$CYGWIN_ROOT_PATH$input_path" 7377 fi 7378 fi 7379 7380 7381 if test "x$path" != "x$new_path"; then 7382 CURDIR="$new_path" 7383 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 7384 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 7385 fi 7386 7387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7388 7389 path="$CURDIR" 7390 has_colon=`$ECHO $path | $GREP ^.:` 7391 new_path="$path" 7392 if test "x$has_colon" = x; then 7393 # Not in mixed or Windows style, start by that. 7394 new_path=`cmd //c echo $path` 7395 fi 7396 7397 7398 input_path="$new_path" 7399 # Check if we need to convert this using DOS-style short mode. If the path 7400 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7401 # take no chances and rewrite it. 7402 # Note: m4 eats our [], so we need to use [ and ] instead. 7403 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 7404 if test "x$has_forbidden_chars" != x; then 7405 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7406 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7407 fi 7408 7409 7410 windows_path="$new_path" 7411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7412 unix_path=`$CYGPATH -u "$windows_path"` 7413 new_path="$unix_path" 7414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 7416 new_path="$unix_path" 7417 fi 7418 7419 if test "x$path" != "x$new_path"; then 7420 CURDIR="$new_path" 7421 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 7422 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 7423 fi 7424 7425 # Save the first 10 bytes of this path to the storage, so fixpath can work. 7426 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 7427 7428 else 7429 # We're on a posix platform. Hooray! :) 7430 path="$CURDIR" 7431 has_space=`$ECHO "$path" | $GREP " "` 7432 if test "x$has_space" != x; then 7433 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 7434 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 7435 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 7436 fi 7437 7438 # Use eval to expand a potential ~ 7439 eval path="$path" 7440 if test ! -f "$path" && test ! -d "$path"; then 7441 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 7442 fi 7443 7444 CURDIR="`cd "$path"; $THEPWDCMD -L`" 7445 fi 7446 7447 7448 if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 7449 # Add extra search paths on solaris for utilities like ar and as etc... 7450 PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin" 7451 fi 7452 7453 # You can force the sys-root if the sys-root encoded into the cross compiler tools 7454 # is not correct. 7455 7456 # Check whether --with-sys-root was given. 7457 if test "${with_sys_root+set}" = set; then : 7458 withval=$with_sys_root; 7459 fi 7460 7461 7462 if test "x$with_sys_root" != x; then 7463 SYS_ROOT=$with_sys_root 7464 else 7465 SYS_ROOT=/ 7466 fi 7467 7468 7469 7470 # Check whether --with-tools-dir was given. 7471 if test "${with_tools_dir+set}" = set; then : 7472 withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir 7473 7474 fi 7475 7476 7477 7478 # Check whether --with-devkit was given. 7479 if test "${with_devkit+set}" = set; then : 7480 withval=$with_devkit; 7481 if test "x$with_sys_root" != x; then 7482 as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5 7483 fi 7484 7485 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7486 7487 # Input might be given as Windows format, start by converting to 7488 # unix format. 7489 path="$with_devkit" 7490 new_path=`$CYGPATH -u "$path"` 7491 7492 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 7493 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 7494 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 7495 # "foo.exe" is OK but "foo" is an error. 7496 # 7497 # This test is therefore slightly more accurate than "test -f" to check for file precense. 7498 # It is also a way to make sure we got the proper file name for the real test later on. 7499 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 7500 if test "x$test_shortpath" = x; then 7501 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 7502 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 7503 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 7504 fi 7505 7506 # Call helper function which possibly converts this using DOS-style short mode. 7507 # If so, the updated path is stored in $new_path. 7508 7509 input_path="$new_path" 7510 # Check if we need to convert this using DOS-style short mode. If the path 7511 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7512 # take no chances and rewrite it. 7513 # Note: m4 eats our [], so we need to use [ and ] instead. 7514 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 7515 if test "x$has_forbidden_chars" != x; then 7516 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7517 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 7518 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 7519 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 7520 # Going to short mode and back again did indeed matter. Since short mode is 7521 # case insensitive, let's make it lowercase to improve readability. 7522 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7523 # Now convert it back to Unix-stile (cygpath) 7524 input_path=`$CYGPATH -u "$shortmode_path"` 7525 new_path="$input_path" 7526 fi 7527 fi 7528 7529 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 7530 if test "x$test_cygdrive_prefix" = x; then 7531 # As a simple fix, exclude /usr/bin since it's not a real path. 7532 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 7533 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 7534 # a path prefixed by /cygdrive for fixpath to work. 7535 new_path="$CYGWIN_ROOT_PATH$input_path" 7536 fi 7537 fi 7538 7539 7540 if test "x$path" != "x$new_path"; then 7541 with_devkit="$new_path" 7542 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 7543 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 7544 fi 7545 7546 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7547 7548 path="$with_devkit" 7549 has_colon=`$ECHO $path | $GREP ^.:` 7550 new_path="$path" 7551 if test "x$has_colon" = x; then 7552 # Not in mixed or Windows style, start by that. 7553 new_path=`cmd //c echo $path` 7554 fi 7555 7556 7557 input_path="$new_path" 7558 # Check if we need to convert this using DOS-style short mode. If the path 7559 # contains just simple characters, use it. Otherwise (spaces, weird characters), 7560 # take no chances and rewrite it. 7561 # Note: m4 eats our [], so we need to use [ and ] instead. 7562 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 7563 if test "x$has_forbidden_chars" != x; then 7564 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 7565 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 7566 fi 7567 7568 7569 windows_path="$new_path" 7570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 7571 unix_path=`$CYGPATH -u "$windows_path"` 7572 new_path="$unix_path" 7573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 7574 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 7575 new_path="$unix_path" 7576 fi 7577 7578 if test "x$path" != "x$new_path"; then 7579 with_devkit="$new_path" 7580 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 7581 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 7582 fi 7583 7584 # Save the first 10 bytes of this path to the storage, so fixpath can work. 7585 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 7586 7587 else 7588 # We're on a posix platform. Hooray! :) 7589 path="$with_devkit" 7590 has_space=`$ECHO "$path" | $GREP " "` 7591 if test "x$has_space" != x; then 7592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 7593 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 7594 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 7595 fi 7596 7597 # Use eval to expand a potential ~ 7598 eval path="$path" 7599 if test ! -f "$path" && test ! -d "$path"; then 7600 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 7601 fi 7602 7603 with_devkit="`cd "$path"; $THEPWDCMD -L`" 7604 fi 7605 7606 7607 if test "x$TOOLS_DIR" = x; then 7608 TOOLS_DIR="$with_devkit/bin" 7609 else 7610 TOOLS_DIR="$TOOLS_DIR:$with_devkit/bin" 7611 fi 7612 7613 if test -d "$with_devkit/$host_alias/libc"; then 7614 SYS_ROOT=$with_devkit/$host_alias/libc 7615 elif test -d "$with_devkit/$host/sys-root"; then 7616 SYS_ROOT=$with_devkit/$host/sys-root 7617 fi 7618 7619 fi 7620 7621 7622 7623 # Setup default logging of stdout and stderr to build.log in the output root. 7624 BUILD_LOG='$(OUTPUT_ROOT)/build.log' 7625 BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old' 7626 BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)' 7627 7628 7629 7630 7631 7632 # Check if it's a pure open build or if custom sources are to be used. 7633 7634 # Check whether --enable-openjdk-only was given. 7635 if test "${enable_openjdk_only+set}" = set; then : 7636 enableval=$enable_openjdk_only; 7637 else 7638 enable_openjdk_only="no" 7639 fi 7640 7641 7642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5 7643 $as_echo_n "checking for presence of closed sources... " >&6; } 7644 if test -d "$SRC_ROOT/jdk/src/closed"; then 7645 CLOSED_SOURCE_PRESENT=yes 7646 else 7647 CLOSED_SOURCE_PRESENT=no 7648 fi 7649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5 7650 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; } 7651 7652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5 7653 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; } 7654 SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only" 7655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5 7656 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; } 7657 7658 if test "x$CLOSED_SOURCE_PRESENT" = xno; then 7659 OPENJDK=true 7660 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 7661 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5 7662 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;} 7663 fi 7664 else 7665 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 7666 OPENJDK=true 7667 else 7668 OPENJDK=false 7669 fi 7670 fi 7671 7672 if test "x$OPENJDK" = "xtrue"; then 7673 SET_OPENJDK="OPENJDK=true" 7674 fi 7675 7676 7677 7678 7679 # These are needed to be able to create a configuration name (and thus the output directory) 7680 7681 ############################################################################### 7682 # 7683 # Check which variant of the JDK that we want to build. 7684 # Currently we have: 7685 # normal: standard edition 7686 # but the custom make system may add other variants 7687 # 7688 # Effectively the JDK variant gives a name to a specific set of 7689 # modules to compile into the JDK. In the future, these modules 7690 # might even be Jigsaw modules. 7691 # 7692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 7693 $as_echo_n "checking which variant of the JDK to build... " >&6; } 7694 7695 # Check whether --with-jdk-variant was given. 7696 if test "${with_jdk_variant+set}" = set; then : 7697 withval=$with_jdk_variant; 7698 fi 7699 7700 7701 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 7702 JDK_VARIANT="normal" 7703 else 7704 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 7705 fi 7706 7707 7708 7709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 7710 $as_echo "$JDK_VARIANT" >&6; } 7711 7712 7713 7714 ############################################################################### 7715 # 7716 # Check which variants of the JVM that we want to build. 7717 # Currently we have: 7718 # server: normal interpreter and a tiered C1/C2 compiler 7719 # client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms) 7720 # minimal1: reduced form of client with optional VM services and features stripped out 7721 # kernel: kernel footprint JVM that passes the TCK without major performance problems, 7722 # ie normal interpreter and C1, only the serial GC, kernel jvmti etc 7723 # zero: no machine code interpreter, no compiler 7724 # zeroshark: zero interpreter and shark/llvm compiler backend 7725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 7726 $as_echo_n "checking which variants of the JVM to build... " >&6; } 7727 7728 # Check whether --with-jvm-variants was given. 7729 if test "${with_jvm_variants+set}" = set; then : 7730 withval=$with_jvm_variants; 7731 fi 7732 7733 7734 if test "x$with_jvm_variants" = x; then 7735 with_jvm_variants="server" 7736 fi 7737 7738 JVM_VARIANTS=",$with_jvm_variants," 7739 TEST_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,//' -e 's/client,//' -e 's/minimal1,//' -e 's/kernel,//' -e 's/zero,//' -e 's/zeroshark,//'` 7740 7741 if test "x$TEST_VARIANTS" != "x,"; then 7742 as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark" "$LINENO" 5 7743 fi 7744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5 7745 $as_echo "$with_jvm_variants" >&6; } 7746 7747 JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'` 7748 JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'` 7749 JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'` 7750 JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'` 7751 JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'` 7752 JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'` 7753 7754 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 7755 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7756 as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5 7757 fi 7758 fi 7759 if test "x$JVM_VARIANT_KERNEL" = xtrue; then 7760 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7761 as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5 7762 fi 7763 fi 7764 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 7765 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 7766 as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5 7767 fi 7768 fi 7769 7770 # Replace the commas with AND for use in the build directory name. 7771 ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/'` 7772 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/'` 7773 if test "x$COUNT_VARIANTS" != "x,1"; then 7774 BUILDING_MULTIPLE_JVM_VARIANTS=yes 7775 else 7776 BUILDING_MULTIPLE_JVM_VARIANTS=no 7777 fi 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 INCLUDE_SA=true 7788 if test "x$JVM_VARIANT_ZERO" = xtrue ; then 7789 INCLUDE_SA=false 7790 fi 7791 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then 7792 INCLUDE_SA=false 7793 fi 7794 7795 7796 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 7797 MACOSX_UNIVERSAL="true" 7798 fi 7799 7800 7801 7802 7803 7804 ############################################################################### 7805 # 7806 # Set the debug level 7807 # release: no debug information, all optimizations, no asserts. 7808 # fastdebug: debug information (-g), all optimizations, all asserts 7809 # slowdebug: debug information (-g), no optimizations, all asserts 7810 # 7811 DEBUG_LEVEL="release" 7812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 7813 $as_echo_n "checking which debug level to use... " >&6; } 7814 # Check whether --enable-debug was given. 7815 if test "${enable_debug+set}" = set; then : 7816 enableval=$enable_debug; 7817 ENABLE_DEBUG="${enableval}" 7818 DEBUG_LEVEL="fastdebug" 7819 7820 else 7821 ENABLE_DEBUG="no" 7822 fi 7823 7824 7825 7826 # Check whether --with-debug-level was given. 7827 if test "${with_debug_level+set}" = set; then : 7828 withval=$with_debug_level; 7829 DEBUG_LEVEL="${withval}" 7830 if test "x$ENABLE_DEBUG" = xyes; then 7831 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 7832 fi 7833 7834 fi 7835 7836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 7837 $as_echo "$DEBUG_LEVEL" >&6; } 7838 7839 if test "x$DEBUG_LEVEL" != xrelease && \ 7840 test "x$DEBUG_LEVEL" != xfastdebug && \ 7841 test "x$DEBUG_LEVEL" != xslowdebug; then 7842 as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5 7843 fi 7844 7845 7846 ############################################################################### 7847 # 7848 # Setup legacy vars/targets and new vars to deal with different debug levels. 7849 # 7850 7851 case $DEBUG_LEVEL in 7852 release ) 7853 VARIANT="OPT" 7854 FASTDEBUG="false" 7855 DEBUG_CLASSFILES="false" 7856 BUILD_VARIANT_RELEASE="" 7857 HOTSPOT_DEBUG_LEVEL="product" 7858 HOTSPOT_EXPORT="product" 7859 ;; 7860 fastdebug ) 7861 VARIANT="DBG" 7862 FASTDEBUG="true" 7863 DEBUG_CLASSFILES="true" 7864 BUILD_VARIANT_RELEASE="-fastdebug" 7865 HOTSPOT_DEBUG_LEVEL="fastdebug" 7866 HOTSPOT_EXPORT="fastdebug" 7867 ;; 7868 slowdebug ) 7869 VARIANT="DBG" 7870 FASTDEBUG="false" 7871 DEBUG_CLASSFILES="true" 7872 BUILD_VARIANT_RELEASE="-debug" 7873 HOTSPOT_DEBUG_LEVEL="jvmg" 7874 HOTSPOT_EXPORT="debug" 7875 ;; 7876 esac 7877 7878 ##### 7879 # Generate the legacy makefile targets for hotspot. 7880 # The hotspot api for selecting the build artifacts, really, needs to be improved. 7881 # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to 7882 # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc 7883 # But until then ... 7884 HOTSPOT_TARGET="" 7885 7886 if test "x$JVM_VARIANT_SERVER" = xtrue; then 7887 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} " 7888 fi 7889 7890 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 7891 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 " 7892 fi 7893 7894 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 7895 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 " 7896 fi 7897 7898 if test "x$JVM_VARIANT_KERNEL" = xtrue; then 7899 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel " 7900 fi 7901 7902 if test "x$JVM_VARIANT_ZERO" = xtrue; then 7903 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero " 7904 fi 7905 7906 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 7907 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark " 7908 fi 7909 7910 HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT" 7911 7912 # On Macosx universal binaries are produced, but they only contain 7913 # 64 bit intel. This invalidates control of which jvms are built 7914 # from configure, but only server is valid anyway. Fix this 7915 # when hotspot makefiles are rewritten. 7916 if test "x$MACOSX_UNIVERSAL" = xtrue; then 7917 HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT} 7918 fi 7919 7920 ##### 7921 7922 7923 7924 7925 7926 7927 7928 7929 # With basic setup done, call the custom early hook. 7930 7931 7932 # To properly create a configuration name, we need to have the OpenJDK target 7933 # and options (variants and debug level) parsed. 7934 7935 7936 7937 # Check whether --with-conf-name was given. 7938 if test "${with_conf_name+set}" = set; then : 7939 withval=$with_conf_name; CONF_NAME=${with_conf_name} 7940 fi 7941 7942 7943 # Test from where we are running configure, in or outside of src root. 7944 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 7945 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 7946 || test "x$CURDIR" = "x$SRC_ROOT/common/makefiles" ; then 7947 # We are running configure from the src root. 7948 # Create a default ./build/target-variant-debuglevel output root. 7949 if test "x${CONF_NAME}" = x; then 7950 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}" 7951 fi 7952 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 7953 $MKDIR -p "$OUTPUT_ROOT" 7954 if test ! -d "$OUTPUT_ROOT"; then 7955 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 7956 fi 7957 else 7958 # We are running configure from outside of the src dir. 7959 # Then use the current directory as output dir! 7960 # If configuration is situated in normal build directory, just use the build 7961 # directory name as configuration name, otherwise use the complete path. 7962 if test "x${CONF_NAME}" = x; then 7963 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 7964 fi 7965 OUTPUT_ROOT="$CURDIR" 7966 7967 # WARNING: This might be a bad thing to do. You need to be sure you want to 7968 # have a configuration in this directory. Do some sanity checks! 7969 7970 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 7971 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 7972 # other files 7973 files_present=`$LS $OUTPUT_ROOT` 7974 # Configure has already touched config.log and confdefs.h in the current dir when this check 7975 # is performed. 7976 filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \ 7977 | $TR -d '\n'` 7978 if test "x$filtered_files" != x; then 7979 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 7980 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 7981 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 7982 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 7983 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 7984 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 7985 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 7986 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 7987 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 7988 $as_echo "$as_me: seriously mess up just about everything." >&6;} 7989 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 7990 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 7991 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 7992 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 7993 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 7994 fi 7995 fi 7996 fi 7997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 7998 $as_echo_n "checking what configuration name to use... " >&6; } 7999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 8000 $as_echo "$CONF_NAME" >&6; } 8001 8002 8003 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8004 8005 # Input might be given as Windows format, start by converting to 8006 # unix format. 8007 path="$OUTPUT_ROOT" 8008 new_path=`$CYGPATH -u "$path"` 8009 8010 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8011 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8012 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8013 # "foo.exe" is OK but "foo" is an error. 8014 # 8015 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8016 # It is also a way to make sure we got the proper file name for the real test later on. 8017 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8018 if test "x$test_shortpath" = x; then 8019 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 8020 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 8021 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 8022 fi 8023 8024 # Call helper function which possibly converts this using DOS-style short mode. 8025 # If so, the updated path is stored in $new_path. 8026 8027 input_path="$new_path" 8028 # Check if we need to convert this using DOS-style short mode. If the path 8029 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8030 # take no chances and rewrite it. 8031 # Note: m4 eats our [], so we need to use [ and ] instead. 8032 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8033 if test "x$has_forbidden_chars" != x; then 8034 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8035 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8036 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8037 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8038 # Going to short mode and back again did indeed matter. Since short mode is 8039 # case insensitive, let's make it lowercase to improve readability. 8040 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8041 # Now convert it back to Unix-stile (cygpath) 8042 input_path=`$CYGPATH -u "$shortmode_path"` 8043 new_path="$input_path" 8044 fi 8045 fi 8046 8047 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8048 if test "x$test_cygdrive_prefix" = x; then 8049 # As a simple fix, exclude /usr/bin since it's not a real path. 8050 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 8051 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8052 # a path prefixed by /cygdrive for fixpath to work. 8053 new_path="$CYGWIN_ROOT_PATH$input_path" 8054 fi 8055 fi 8056 8057 8058 if test "x$path" != "x$new_path"; then 8059 OUTPUT_ROOT="$new_path" 8060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 8061 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 8062 fi 8063 8064 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8065 8066 path="$OUTPUT_ROOT" 8067 has_colon=`$ECHO $path | $GREP ^.:` 8068 new_path="$path" 8069 if test "x$has_colon" = x; then 8070 # Not in mixed or Windows style, start by that. 8071 new_path=`cmd //c echo $path` 8072 fi 8073 8074 8075 input_path="$new_path" 8076 # Check if we need to convert this using DOS-style short mode. If the path 8077 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8078 # take no chances and rewrite it. 8079 # Note: m4 eats our [], so we need to use [ and ] instead. 8080 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8081 if test "x$has_forbidden_chars" != x; then 8082 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8083 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8084 fi 8085 8086 8087 windows_path="$new_path" 8088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8089 unix_path=`$CYGPATH -u "$windows_path"` 8090 new_path="$unix_path" 8091 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8092 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8093 new_path="$unix_path" 8094 fi 8095 8096 if test "x$path" != "x$new_path"; then 8097 OUTPUT_ROOT="$new_path" 8098 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 8099 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 8100 fi 8101 8102 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8103 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8104 8105 else 8106 # We're on a posix platform. Hooray! :) 8107 path="$OUTPUT_ROOT" 8108 has_space=`$ECHO "$path" | $GREP " "` 8109 if test "x$has_space" != x; then 8110 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 8111 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 8112 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 8113 fi 8114 8115 # Use eval to expand a potential ~ 8116 eval path="$path" 8117 if test ! -f "$path" && test ! -d "$path"; then 8118 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 8119 fi 8120 8121 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 8122 fi 8123 8124 8125 SPEC=$OUTPUT_ROOT/spec.gmk 8126 8127 CONF_NAME=$CONF_NAME 8128 8129 OUTPUT_ROOT=$OUTPUT_ROOT 8130 8131 8132 # Most of the probed defines are put into config.h 8133 ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" 8134 8135 # The spec.gmk file contains all variables for the make system. 8136 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 8137 8138 # The hotspot-spec.gmk file contains legacy variables for the hotspot make system. 8139 ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" 8140 8141 # The bootcycle-spec.gmk file contains support for boot cycle builds. 8142 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 8143 8144 # The compare.sh is used to compare the build output to other builds. 8145 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 8146 8147 # Spec.sh is currently used by compare-objects.sh 8148 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" 8149 8150 # The generated Makefile knows where the spec.gmk is and where the source is. 8151 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 8152 # which will look for generated configurations 8153 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 8154 8155 8156 # Save the arguments given to us 8157 echo "$CONFIGURE_COMMAND_LINE" > $OUTPUT_ROOT/configure-arguments 8158 8159 8160 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 8161 8162 for ac_prog in apt-get yum port pkgutil pkgadd 8163 do 8164 # Extract the first word of "$ac_prog", so it can be a program name with args. 8165 set dummy $ac_prog; ac_word=$2 8166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8167 $as_echo_n "checking for $ac_word... " >&6; } 8168 if ${ac_cv_prog_PKGHANDLER+:} false; then : 8169 $as_echo_n "(cached) " >&6 8170 else 8171 if test -n "$PKGHANDLER"; then 8172 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 8173 else 8174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8175 for as_dir in $PATH 8176 do 8177 IFS=$as_save_IFS 8178 test -z "$as_dir" && as_dir=. 8179 for ac_exec_ext in '' $ac_executable_extensions; do 8180 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 8181 ac_cv_prog_PKGHANDLER="$ac_prog" 8182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8183 break 2 8184 fi 8185 done 8186 done 8187 IFS=$as_save_IFS 8188 8189 fi 8190 fi 8191 PKGHANDLER=$ac_cv_prog_PKGHANDLER 8192 if test -n "$PKGHANDLER"; then 8193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 8194 $as_echo "$PKGHANDLER" >&6; } 8195 else 8196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8197 $as_echo "no" >&6; } 8198 fi 8199 8200 8201 test -n "$PKGHANDLER" && break 8202 done 8203 8204 8205 8206 # Setup tools that requires more complex handling, or that is not needed by the configure script. 8207 8208 8209 # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky. 8210 if test "x$MAKE" != x; then 8211 # User has supplied a make, test it. 8212 if test ! -f "$MAKE"; then 8213 as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5 8214 fi 8215 8216 MAKE_CANDIDATE=""$MAKE"" 8217 DESCRIPTION="user supplied MAKE=$MAKE" 8218 if test "x$MAKE_CANDIDATE" != x; then 8219 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 8220 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 8221 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 8222 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 8223 if test "x$IS_GNU_MAKE" = x; then 8224 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 8225 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 8226 else 8227 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 8228 if test "x$IS_MODERN_MAKE" = x; then 8229 { $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 8230 $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;} 8231 else 8232 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 8233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8234 MAKE_EXPECTED_ENV='cygwin' 8235 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8236 MAKE_EXPECTED_ENV='msys' 8237 else 8238 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 8239 fi 8240 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 8241 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 8242 else 8243 # Not relevant for non-Windows 8244 IS_MAKE_CORRECT_ENV=true 8245 fi 8246 if test "x$IS_MAKE_CORRECT_ENV" = x; then 8247 { $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 8248 $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;} 8249 else 8250 FOUND_MAKE=$MAKE_CANDIDATE 8251 8252 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8253 8254 # First separate the path from the arguments. This will split at the first 8255 # space. 8256 complete="$FOUND_MAKE" 8257 path="${complete%% *}" 8258 tmp="$complete EOL" 8259 arguments="${tmp#* }" 8260 8261 # Input might be given as Windows format, start by converting to 8262 # unix format. 8263 new_path=`$CYGPATH -u "$path"` 8264 8265 # Now try to locate executable using which 8266 new_path=`$WHICH "$new_path" 2> /dev/null` 8267 # bat and cmd files are not always considered executable in cygwin causing which 8268 # to not find them 8269 if test "x$new_path" = x \ 8270 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8271 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8272 new_path=`$CYGPATH -u "$path"` 8273 fi 8274 if test "x$new_path" = x; then 8275 # Oops. Which didn't find the executable. 8276 # The splitting of arguments from the executable at a space might have been incorrect, 8277 # since paths with space are more likely in Windows. Give it another try with the whole 8278 # argument. 8279 path="$complete" 8280 arguments="EOL" 8281 new_path=`$CYGPATH -u "$path"` 8282 new_path=`$WHICH "$new_path" 2> /dev/null` 8283 # bat and cmd files are not always considered executable in cygwin causing which 8284 # to not find them 8285 if test "x$new_path" = x \ 8286 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8287 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8288 new_path=`$CYGPATH -u "$path"` 8289 fi 8290 if test "x$new_path" = x; then 8291 # It's still not found. Now this is an unrecoverable error. 8292 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8293 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8294 has_space=`$ECHO "$complete" | $GREP " "` 8295 if test "x$has_space" != x; then 8296 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 8297 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 8298 fi 8299 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8300 fi 8301 fi 8302 8303 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8304 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8305 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8306 # "foo.exe" is OK but "foo" is an error. 8307 # 8308 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8309 # It is also a way to make sure we got the proper file name for the real test later on. 8310 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8311 if test "x$test_shortpath" = x; then 8312 # Short path failed, file does not exist as specified. 8313 # Try adding .exe or .cmd 8314 if test -f "${new_path}.exe"; then 8315 input_to_shortpath="${new_path}.exe" 8316 elif test -f "${new_path}.cmd"; then 8317 input_to_shortpath="${new_path}.cmd" 8318 else 8319 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 8320 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 8321 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 8322 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 8323 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8324 fi 8325 else 8326 input_to_shortpath="$new_path" 8327 fi 8328 8329 # Call helper function which possibly converts this using DOS-style short mode. 8330 # If so, the updated path is stored in $new_path. 8331 new_path="$input_to_shortpath" 8332 8333 input_path="$input_to_shortpath" 8334 # Check if we need to convert this using DOS-style short mode. If the path 8335 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8336 # take no chances and rewrite it. 8337 # Note: m4 eats our [], so we need to use [ and ] instead. 8338 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8339 if test "x$has_forbidden_chars" != x; then 8340 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8341 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8342 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8343 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8344 # Going to short mode and back again did indeed matter. Since short mode is 8345 # case insensitive, let's make it lowercase to improve readability. 8346 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8347 # Now convert it back to Unix-stile (cygpath) 8348 input_path=`$CYGPATH -u "$shortmode_path"` 8349 new_path="$input_path" 8350 fi 8351 fi 8352 8353 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8354 if test "x$test_cygdrive_prefix" = x; then 8355 # As a simple fix, exclude /usr/bin since it's not a real path. 8356 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 8357 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8358 # a path prefixed by /cygdrive for fixpath to work. 8359 new_path="$CYGWIN_ROOT_PATH$input_path" 8360 fi 8361 fi 8362 8363 # remove trailing .exe if any 8364 new_path="${new_path/%.exe/}" 8365 8366 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8367 8368 # First separate the path from the arguments. This will split at the first 8369 # space. 8370 complete="$FOUND_MAKE" 8371 path="${complete%% *}" 8372 tmp="$complete EOL" 8373 arguments="${tmp#* }" 8374 8375 # Input might be given as Windows format, start by converting to 8376 # unix format. 8377 new_path="$path" 8378 8379 windows_path="$new_path" 8380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8381 unix_path=`$CYGPATH -u "$windows_path"` 8382 new_path="$unix_path" 8383 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8384 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8385 new_path="$unix_path" 8386 fi 8387 8388 8389 # Now try to locate executable using which 8390 new_path=`$WHICH "$new_path" 2> /dev/null` 8391 8392 if test "x$new_path" = x; then 8393 # Oops. Which didn't find the executable. 8394 # The splitting of arguments from the executable at a space might have been incorrect, 8395 # since paths with space are more likely in Windows. Give it another try with the whole 8396 # argument. 8397 path="$complete" 8398 arguments="EOL" 8399 new_path="$path" 8400 8401 windows_path="$new_path" 8402 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8403 unix_path=`$CYGPATH -u "$windows_path"` 8404 new_path="$unix_path" 8405 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8406 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8407 new_path="$unix_path" 8408 fi 8409 8410 8411 new_path=`$WHICH "$new_path" 2> /dev/null` 8412 8413 if test "x$new_path" = x; then 8414 # It's still not found. Now this is an unrecoverable error. 8415 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8416 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8417 has_space=`$ECHO "$complete" | $GREP " "` 8418 if test "x$has_space" != x; then 8419 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 8420 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 8421 fi 8422 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8423 fi 8424 fi 8425 8426 # Now new_path has a complete unix path to the binary 8427 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 8428 # Keep paths in /bin as-is, but remove trailing .exe if any 8429 new_path="${new_path/%.exe/}" 8430 # Do not save /bin paths to all_fixpath_prefixes! 8431 else 8432 # Not in mixed or Windows style, start by that. 8433 new_path=`cmd //c echo $new_path` 8434 8435 input_path="$new_path" 8436 # Check if we need to convert this using DOS-style short mode. If the path 8437 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8438 # take no chances and rewrite it. 8439 # Note: m4 eats our [], so we need to use [ and ] instead. 8440 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8441 if test "x$has_forbidden_chars" != x; then 8442 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8443 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8444 fi 8445 8446 # Output is in $new_path 8447 8448 windows_path="$new_path" 8449 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8450 unix_path=`$CYGPATH -u "$windows_path"` 8451 new_path="$unix_path" 8452 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8453 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8454 new_path="$unix_path" 8455 fi 8456 8457 # remove trailing .exe if any 8458 new_path="${new_path/%.exe/}" 8459 8460 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8461 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8462 fi 8463 8464 else 8465 # We're on a posix platform. Hooray! :) 8466 # First separate the path from the arguments. This will split at the first 8467 # space. 8468 complete="$FOUND_MAKE" 8469 path="${complete%% *}" 8470 tmp="$complete EOL" 8471 arguments="${tmp#* }" 8472 8473 # Cannot rely on the command "which" here since it doesn't always work. 8474 is_absolute_path=`$ECHO "$path" | $GREP ^/` 8475 if test -z "$is_absolute_path"; then 8476 # Path to executable is not absolute. Find it. 8477 IFS_save="$IFS" 8478 IFS=: 8479 for p in $PATH; do 8480 if test -f "$p/$path" && test -x "$p/$path"; then 8481 new_path="$p/$path" 8482 break 8483 fi 8484 done 8485 IFS="$IFS_save" 8486 else 8487 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 8488 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 8489 new_path="$path" 8490 fi 8491 8492 if test "x$new_path" = x; then 8493 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8494 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8495 has_space=`$ECHO "$complete" | $GREP " "` 8496 if test "x$has_space" != x; then 8497 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 8498 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 8499 fi 8500 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8501 fi 8502 fi 8503 8504 # Now join together the path and the arguments once again 8505 if test "x$arguments" != xEOL; then 8506 new_complete="$new_path ${arguments% *}" 8507 else 8508 new_complete="$new_path" 8509 fi 8510 8511 if test "x$complete" != "x$new_complete"; then 8512 FOUND_MAKE="$new_complete" 8513 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 8514 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 8515 fi 8516 8517 fi 8518 fi 8519 fi 8520 fi 8521 8522 if test "x$FOUND_MAKE" = x; then 8523 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5 8524 fi 8525 else 8526 # Try our hardest to locate a correct version of GNU make 8527 for ac_prog in gmake 8528 do 8529 # Extract the first word of "$ac_prog", so it can be a program name with args. 8530 set dummy $ac_prog; ac_word=$2 8531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8532 $as_echo_n "checking for $ac_word... " >&6; } 8533 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 8534 $as_echo_n "(cached) " >&6 8535 else 8536 case $CHECK_GMAKE in 8537 [\\/]* | ?:[\\/]*) 8538 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 8539 ;; 8540 *) 8541 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8542 for as_dir in $PATH 8543 do 8544 IFS=$as_save_IFS 8545 test -z "$as_dir" && as_dir=. 8546 for ac_exec_ext in '' $ac_executable_extensions; do 8547 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 8548 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 8549 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8550 break 2 8551 fi 8552 done 8553 done 8554 IFS=$as_save_IFS 8555 8556 ;; 8557 esac 8558 fi 8559 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 8560 if test -n "$CHECK_GMAKE"; then 8561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 8562 $as_echo "$CHECK_GMAKE" >&6; } 8563 else 8564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8565 $as_echo "no" >&6; } 8566 fi 8567 8568 8569 test -n "$CHECK_GMAKE" && break 8570 done 8571 8572 8573 MAKE_CANDIDATE=""$CHECK_GMAKE"" 8574 DESCRIPTION="gmake in PATH" 8575 if test "x$MAKE_CANDIDATE" != x; then 8576 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 8577 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 8578 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 8579 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 8580 if test "x$IS_GNU_MAKE" = x; then 8581 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 8582 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 8583 else 8584 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 8585 if test "x$IS_MODERN_MAKE" = x; then 8586 { $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 8587 $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;} 8588 else 8589 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 8590 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8591 MAKE_EXPECTED_ENV='cygwin' 8592 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8593 MAKE_EXPECTED_ENV='msys' 8594 else 8595 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 8596 fi 8597 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 8598 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 8599 else 8600 # Not relevant for non-Windows 8601 IS_MAKE_CORRECT_ENV=true 8602 fi 8603 if test "x$IS_MAKE_CORRECT_ENV" = x; then 8604 { $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 8605 $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;} 8606 else 8607 FOUND_MAKE=$MAKE_CANDIDATE 8608 8609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8610 8611 # First separate the path from the arguments. This will split at the first 8612 # space. 8613 complete="$FOUND_MAKE" 8614 path="${complete%% *}" 8615 tmp="$complete EOL" 8616 arguments="${tmp#* }" 8617 8618 # Input might be given as Windows format, start by converting to 8619 # unix format. 8620 new_path=`$CYGPATH -u "$path"` 8621 8622 # Now try to locate executable using which 8623 new_path=`$WHICH "$new_path" 2> /dev/null` 8624 # bat and cmd files are not always considered executable in cygwin causing which 8625 # to not find them 8626 if test "x$new_path" = x \ 8627 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8628 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8629 new_path=`$CYGPATH -u "$path"` 8630 fi 8631 if test "x$new_path" = x; then 8632 # Oops. Which didn't find the executable. 8633 # The splitting of arguments from the executable at a space might have been incorrect, 8634 # since paths with space are more likely in Windows. Give it another try with the whole 8635 # argument. 8636 path="$complete" 8637 arguments="EOL" 8638 new_path=`$CYGPATH -u "$path"` 8639 new_path=`$WHICH "$new_path" 2> /dev/null` 8640 # bat and cmd files are not always considered executable in cygwin causing which 8641 # to not find them 8642 if test "x$new_path" = x \ 8643 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8644 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8645 new_path=`$CYGPATH -u "$path"` 8646 fi 8647 if test "x$new_path" = x; then 8648 # It's still not found. Now this is an unrecoverable error. 8649 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8650 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8651 has_space=`$ECHO "$complete" | $GREP " "` 8652 if test "x$has_space" != x; then 8653 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 8654 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 8655 fi 8656 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8657 fi 8658 fi 8659 8660 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 8661 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 8662 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 8663 # "foo.exe" is OK but "foo" is an error. 8664 # 8665 # This test is therefore slightly more accurate than "test -f" to check for file precense. 8666 # It is also a way to make sure we got the proper file name for the real test later on. 8667 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 8668 if test "x$test_shortpath" = x; then 8669 # Short path failed, file does not exist as specified. 8670 # Try adding .exe or .cmd 8671 if test -f "${new_path}.exe"; then 8672 input_to_shortpath="${new_path}.exe" 8673 elif test -f "${new_path}.cmd"; then 8674 input_to_shortpath="${new_path}.cmd" 8675 else 8676 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 8677 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 8678 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 8679 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 8680 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8681 fi 8682 else 8683 input_to_shortpath="$new_path" 8684 fi 8685 8686 # Call helper function which possibly converts this using DOS-style short mode. 8687 # If so, the updated path is stored in $new_path. 8688 new_path="$input_to_shortpath" 8689 8690 input_path="$input_to_shortpath" 8691 # Check if we need to convert this using DOS-style short mode. If the path 8692 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8693 # take no chances and rewrite it. 8694 # Note: m4 eats our [], so we need to use [ and ] instead. 8695 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 8696 if test "x$has_forbidden_chars" != x; then 8697 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8698 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 8699 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 8700 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 8701 # Going to short mode and back again did indeed matter. Since short mode is 8702 # case insensitive, let's make it lowercase to improve readability. 8703 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8704 # Now convert it back to Unix-stile (cygpath) 8705 input_path=`$CYGPATH -u "$shortmode_path"` 8706 new_path="$input_path" 8707 fi 8708 fi 8709 8710 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 8711 if test "x$test_cygdrive_prefix" = x; then 8712 # As a simple fix, exclude /usr/bin since it's not a real path. 8713 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 8714 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 8715 # a path prefixed by /cygdrive for fixpath to work. 8716 new_path="$CYGWIN_ROOT_PATH$input_path" 8717 fi 8718 fi 8719 8720 # remove trailing .exe if any 8721 new_path="${new_path/%.exe/}" 8722 8723 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8724 8725 # First separate the path from the arguments. This will split at the first 8726 # space. 8727 complete="$FOUND_MAKE" 8728 path="${complete%% *}" 8729 tmp="$complete EOL" 8730 arguments="${tmp#* }" 8731 8732 # Input might be given as Windows format, start by converting to 8733 # unix format. 8734 new_path="$path" 8735 8736 windows_path="$new_path" 8737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8738 unix_path=`$CYGPATH -u "$windows_path"` 8739 new_path="$unix_path" 8740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8741 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8742 new_path="$unix_path" 8743 fi 8744 8745 8746 # Now try to locate executable using which 8747 new_path=`$WHICH "$new_path" 2> /dev/null` 8748 8749 if test "x$new_path" = x; then 8750 # Oops. Which didn't find the executable. 8751 # The splitting of arguments from the executable at a space might have been incorrect, 8752 # since paths with space are more likely in Windows. Give it another try with the whole 8753 # argument. 8754 path="$complete" 8755 arguments="EOL" 8756 new_path="$path" 8757 8758 windows_path="$new_path" 8759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8760 unix_path=`$CYGPATH -u "$windows_path"` 8761 new_path="$unix_path" 8762 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8763 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8764 new_path="$unix_path" 8765 fi 8766 8767 8768 new_path=`$WHICH "$new_path" 2> /dev/null` 8769 8770 if test "x$new_path" = x; then 8771 # It's still not found. Now this is an unrecoverable error. 8772 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8773 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8774 has_space=`$ECHO "$complete" | $GREP " "` 8775 if test "x$has_space" != x; then 8776 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 8777 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 8778 fi 8779 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8780 fi 8781 fi 8782 8783 # Now new_path has a complete unix path to the binary 8784 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 8785 # Keep paths in /bin as-is, but remove trailing .exe if any 8786 new_path="${new_path/%.exe/}" 8787 # Do not save /bin paths to all_fixpath_prefixes! 8788 else 8789 # Not in mixed or Windows style, start by that. 8790 new_path=`cmd //c echo $new_path` 8791 8792 input_path="$new_path" 8793 # Check if we need to convert this using DOS-style short mode. If the path 8794 # contains just simple characters, use it. Otherwise (spaces, weird characters), 8795 # take no chances and rewrite it. 8796 # Note: m4 eats our [], so we need to use [ and ] instead. 8797 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 8798 if test "x$has_forbidden_chars" != x; then 8799 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 8800 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 8801 fi 8802 8803 # Output is in $new_path 8804 8805 windows_path="$new_path" 8806 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8807 unix_path=`$CYGPATH -u "$windows_path"` 8808 new_path="$unix_path" 8809 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8810 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 8811 new_path="$unix_path" 8812 fi 8813 8814 # remove trailing .exe if any 8815 new_path="${new_path/%.exe/}" 8816 8817 # Save the first 10 bytes of this path to the storage, so fixpath can work. 8818 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 8819 fi 8820 8821 else 8822 # We're on a posix platform. Hooray! :) 8823 # First separate the path from the arguments. This will split at the first 8824 # space. 8825 complete="$FOUND_MAKE" 8826 path="${complete%% *}" 8827 tmp="$complete EOL" 8828 arguments="${tmp#* }" 8829 8830 # Cannot rely on the command "which" here since it doesn't always work. 8831 is_absolute_path=`$ECHO "$path" | $GREP ^/` 8832 if test -z "$is_absolute_path"; then 8833 # Path to executable is not absolute. Find it. 8834 IFS_save="$IFS" 8835 IFS=: 8836 for p in $PATH; do 8837 if test -f "$p/$path" && test -x "$p/$path"; then 8838 new_path="$p/$path" 8839 break 8840 fi 8841 done 8842 IFS="$IFS_save" 8843 else 8844 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 8845 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 8846 new_path="$path" 8847 fi 8848 8849 if test "x$new_path" = x; then 8850 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 8851 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 8852 has_space=`$ECHO "$complete" | $GREP " "` 8853 if test "x$has_space" != x; then 8854 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 8855 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 8856 fi 8857 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 8858 fi 8859 fi 8860 8861 # Now join together the path and the arguments once again 8862 if test "x$arguments" != xEOL; then 8863 new_complete="$new_path ${arguments% *}" 8864 else 8865 new_complete="$new_path" 8866 fi 8867 8868 if test "x$complete" != "x$new_complete"; then 8869 FOUND_MAKE="$new_complete" 8870 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 8871 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 8872 fi 8873 8874 fi 8875 fi 8876 fi 8877 fi 8878 8879 8880 if test "x$FOUND_MAKE" = x; then 8881 for ac_prog in make 8882 do 8883 # Extract the first word of "$ac_prog", so it can be a program name with args. 8884 set dummy $ac_prog; ac_word=$2 8885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8886 $as_echo_n "checking for $ac_word... " >&6; } 8887 if ${ac_cv_path_CHECK_MAKE+:} false; then : 8888 $as_echo_n "(cached) " >&6 8889 else 8890 case $CHECK_MAKE in 8891 [\\/]* | ?:[\\/]*) 8892 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 8893 ;; 8894 *) 8895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8896 for as_dir in $PATH 8897 do 8898 IFS=$as_save_IFS 8899 test -z "$as_dir" && as_dir=. 8900 for ac_exec_ext in '' $ac_executable_extensions; do 8901 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 8902 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 8903 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8904 break 2 8905 fi 8906 done 8907 done 8908 IFS=$as_save_IFS 8909 8910 ;; 8911 esac 8912 fi 8913 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 8914 if test -n "$CHECK_MAKE"; then 8915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 8916 $as_echo "$CHECK_MAKE" >&6; } 8917 else 8918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8919 $as_echo "no" >&6; } 8920 fi 8921 8922 8923 test -n "$CHECK_MAKE" && break 8924 done 8925 8926 8927 MAKE_CANDIDATE=""$CHECK_MAKE"" 8928 DESCRIPTION="make in PATH" 8929 if test "x$MAKE_CANDIDATE" != x; then 8930 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 8931 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 8932 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 8933 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 8934 if test "x$IS_GNU_MAKE" = x; then 8935 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 8936 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 8937 else 8938 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 8939 if test "x$IS_MODERN_MAKE" = x; then 8940 { $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 8941 $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;} 8942 else 8943 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 8944 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8945 MAKE_EXPECTED_ENV='cygwin' 8946 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 8947 MAKE_EXPECTED_ENV='msys' 8948 else 8949 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 8950 fi 8951 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 8952 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 8953 else 8954 # Not relevant for non-Windows 8955 IS_MAKE_CORRECT_ENV=true 8956 fi 8957 if test "x$IS_MAKE_CORRECT_ENV" = x; then 8958 { $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 8959 $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;} 8960 else 8961 FOUND_MAKE=$MAKE_CANDIDATE 8962 8963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 8964 8965 # First separate the path from the arguments. This will split at the first 8966 # space. 8967 complete="$FOUND_MAKE" 8968 path="${complete%% *}" 8969 tmp="$complete EOL" 8970 arguments="${tmp#* }" 8971 8972 # Input might be given as Windows format, start by converting to 8973 # unix format. 8974 new_path=`$CYGPATH -u "$path"` 8975 8976 # Now try to locate executable using which 8977 new_path=`$WHICH "$new_path" 2> /dev/null` 8978 # bat and cmd files are not always considered executable in cygwin causing which 8979 # to not find them 8980 if test "x$new_path" = x \ 8981 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8982 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8983 new_path=`$CYGPATH -u "$path"` 8984 fi 8985 if test "x$new_path" = x; then 8986 # Oops. Which didn't find the executable. 8987 # The splitting of arguments from the executable at a space might have been incorrect, 8988 # since paths with space are more likely in Windows. Give it another try with the whole 8989 # argument. 8990 path="$complete" 8991 arguments="EOL" 8992 new_path=`$CYGPATH -u "$path"` 8993 new_path=`$WHICH "$new_path" 2> /dev/null` 8994 # bat and cmd files are not always considered executable in cygwin causing which 8995 # to not find them 8996 if test "x$new_path" = x \ 8997 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 8998 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 8999 new_path=`$CYGPATH -u "$path"` 9000 fi 9001 if test "x$new_path" = x; then 9002 # It's still not found. Now this is an unrecoverable error. 9003 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9004 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9005 has_space=`$ECHO "$complete" | $GREP " "` 9006 if test "x$has_space" != x; then 9007 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9008 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9009 fi 9010 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9011 fi 9012 fi 9013 9014 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9015 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9016 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9017 # "foo.exe" is OK but "foo" is an error. 9018 # 9019 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9020 # It is also a way to make sure we got the proper file name for the real test later on. 9021 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9022 if test "x$test_shortpath" = x; then 9023 # Short path failed, file does not exist as specified. 9024 # Try adding .exe or .cmd 9025 if test -f "${new_path}.exe"; then 9026 input_to_shortpath="${new_path}.exe" 9027 elif test -f "${new_path}.cmd"; then 9028 input_to_shortpath="${new_path}.cmd" 9029 else 9030 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9031 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9032 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9033 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9034 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9035 fi 9036 else 9037 input_to_shortpath="$new_path" 9038 fi 9039 9040 # Call helper function which possibly converts this using DOS-style short mode. 9041 # If so, the updated path is stored in $new_path. 9042 new_path="$input_to_shortpath" 9043 9044 input_path="$input_to_shortpath" 9045 # Check if we need to convert this using DOS-style short mode. If the path 9046 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9047 # take no chances and rewrite it. 9048 # Note: m4 eats our [], so we need to use [ and ] instead. 9049 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9050 if test "x$has_forbidden_chars" != x; then 9051 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9052 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9053 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9054 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9055 # Going to short mode and back again did indeed matter. Since short mode is 9056 # case insensitive, let's make it lowercase to improve readability. 9057 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9058 # Now convert it back to Unix-stile (cygpath) 9059 input_path=`$CYGPATH -u "$shortmode_path"` 9060 new_path="$input_path" 9061 fi 9062 fi 9063 9064 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9065 if test "x$test_cygdrive_prefix" = x; then 9066 # As a simple fix, exclude /usr/bin since it's not a real path. 9067 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9068 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9069 # a path prefixed by /cygdrive for fixpath to work. 9070 new_path="$CYGWIN_ROOT_PATH$input_path" 9071 fi 9072 fi 9073 9074 # remove trailing .exe if any 9075 new_path="${new_path/%.exe/}" 9076 9077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9078 9079 # First separate the path from the arguments. This will split at the first 9080 # space. 9081 complete="$FOUND_MAKE" 9082 path="${complete%% *}" 9083 tmp="$complete EOL" 9084 arguments="${tmp#* }" 9085 9086 # Input might be given as Windows format, start by converting to 9087 # unix format. 9088 new_path="$path" 9089 9090 windows_path="$new_path" 9091 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9092 unix_path=`$CYGPATH -u "$windows_path"` 9093 new_path="$unix_path" 9094 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9095 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9096 new_path="$unix_path" 9097 fi 9098 9099 9100 # Now try to locate executable using which 9101 new_path=`$WHICH "$new_path" 2> /dev/null` 9102 9103 if test "x$new_path" = x; then 9104 # Oops. Which didn't find the executable. 9105 # The splitting of arguments from the executable at a space might have been incorrect, 9106 # since paths with space are more likely in Windows. Give it another try with the whole 9107 # argument. 9108 path="$complete" 9109 arguments="EOL" 9110 new_path="$path" 9111 9112 windows_path="$new_path" 9113 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9114 unix_path=`$CYGPATH -u "$windows_path"` 9115 new_path="$unix_path" 9116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9117 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9118 new_path="$unix_path" 9119 fi 9120 9121 9122 new_path=`$WHICH "$new_path" 2> /dev/null` 9123 9124 if test "x$new_path" = x; then 9125 # It's still not found. Now this is an unrecoverable error. 9126 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9127 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9128 has_space=`$ECHO "$complete" | $GREP " "` 9129 if test "x$has_space" != x; then 9130 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9131 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9132 fi 9133 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9134 fi 9135 fi 9136 9137 # Now new_path has a complete unix path to the binary 9138 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9139 # Keep paths in /bin as-is, but remove trailing .exe if any 9140 new_path="${new_path/%.exe/}" 9141 # Do not save /bin paths to all_fixpath_prefixes! 9142 else 9143 # Not in mixed or Windows style, start by that. 9144 new_path=`cmd //c echo $new_path` 9145 9146 input_path="$new_path" 9147 # Check if we need to convert this using DOS-style short mode. If the path 9148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9149 # take no chances and rewrite it. 9150 # Note: m4 eats our [], so we need to use [ and ] instead. 9151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9152 if test "x$has_forbidden_chars" != x; then 9153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9154 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9155 fi 9156 9157 # Output is in $new_path 9158 9159 windows_path="$new_path" 9160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9161 unix_path=`$CYGPATH -u "$windows_path"` 9162 new_path="$unix_path" 9163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9164 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9165 new_path="$unix_path" 9166 fi 9167 9168 # remove trailing .exe if any 9169 new_path="${new_path/%.exe/}" 9170 9171 # Save the first 10 bytes of this path to the storage, so fixpath can work. 9172 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 9173 fi 9174 9175 else 9176 # We're on a posix platform. Hooray! :) 9177 # First separate the path from the arguments. This will split at the first 9178 # space. 9179 complete="$FOUND_MAKE" 9180 path="${complete%% *}" 9181 tmp="$complete EOL" 9182 arguments="${tmp#* }" 9183 9184 # Cannot rely on the command "which" here since it doesn't always work. 9185 is_absolute_path=`$ECHO "$path" | $GREP ^/` 9186 if test -z "$is_absolute_path"; then 9187 # Path to executable is not absolute. Find it. 9188 IFS_save="$IFS" 9189 IFS=: 9190 for p in $PATH; do 9191 if test -f "$p/$path" && test -x "$p/$path"; then 9192 new_path="$p/$path" 9193 break 9194 fi 9195 done 9196 IFS="$IFS_save" 9197 else 9198 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 9199 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 9200 new_path="$path" 9201 fi 9202 9203 if test "x$new_path" = x; then 9204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9205 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9206 has_space=`$ECHO "$complete" | $GREP " "` 9207 if test "x$has_space" != x; then 9208 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 9209 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 9210 fi 9211 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9212 fi 9213 fi 9214 9215 # Now join together the path and the arguments once again 9216 if test "x$arguments" != xEOL; then 9217 new_complete="$new_path ${arguments% *}" 9218 else 9219 new_complete="$new_path" 9220 fi 9221 9222 if test "x$complete" != "x$new_complete"; then 9223 FOUND_MAKE="$new_complete" 9224 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 9225 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 9226 fi 9227 9228 fi 9229 fi 9230 fi 9231 fi 9232 9233 fi 9234 9235 if test "x$FOUND_MAKE" = x; then 9236 if test "x$TOOLS_DIR" != x; then 9237 # We have a tools-dir, check that as well before giving up. 9238 OLD_PATH=$PATH 9239 PATH=$TOOLS_DIR:$PATH 9240 for ac_prog in gmake 9241 do 9242 # Extract the first word of "$ac_prog", so it can be a program name with args. 9243 set dummy $ac_prog; ac_word=$2 9244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9245 $as_echo_n "checking for $ac_word... " >&6; } 9246 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 9247 $as_echo_n "(cached) " >&6 9248 else 9249 case $CHECK_TOOLSDIR_GMAKE in 9250 [\\/]* | ?:[\\/]*) 9251 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 9252 ;; 9253 *) 9254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9255 for as_dir in $PATH 9256 do 9257 IFS=$as_save_IFS 9258 test -z "$as_dir" && as_dir=. 9259 for ac_exec_ext in '' $ac_executable_extensions; do 9260 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 9261 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 9262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9263 break 2 9264 fi 9265 done 9266 done 9267 IFS=$as_save_IFS 9268 9269 ;; 9270 esac 9271 fi 9272 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 9273 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 9274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 9275 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 9276 else 9277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9278 $as_echo "no" >&6; } 9279 fi 9280 9281 9282 test -n "$CHECK_TOOLSDIR_GMAKE" && break 9283 done 9284 9285 9286 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 9287 DESCRIPTION="gmake in tools-dir" 9288 if test "x$MAKE_CANDIDATE" != x; then 9289 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 9290 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 9291 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 9292 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 9293 if test "x$IS_GNU_MAKE" = x; then 9294 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 9295 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 9296 else 9297 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 9298 if test "x$IS_MODERN_MAKE" = x; then 9299 { $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 9300 $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;} 9301 else 9302 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 9303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9304 MAKE_EXPECTED_ENV='cygwin' 9305 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9306 MAKE_EXPECTED_ENV='msys' 9307 else 9308 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 9309 fi 9310 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 9311 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 9312 else 9313 # Not relevant for non-Windows 9314 IS_MAKE_CORRECT_ENV=true 9315 fi 9316 if test "x$IS_MAKE_CORRECT_ENV" = x; then 9317 { $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 9318 $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;} 9319 else 9320 FOUND_MAKE=$MAKE_CANDIDATE 9321 9322 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9323 9324 # First separate the path from the arguments. This will split at the first 9325 # space. 9326 complete="$FOUND_MAKE" 9327 path="${complete%% *}" 9328 tmp="$complete EOL" 9329 arguments="${tmp#* }" 9330 9331 # Input might be given as Windows format, start by converting to 9332 # unix format. 9333 new_path=`$CYGPATH -u "$path"` 9334 9335 # Now try to locate executable using which 9336 new_path=`$WHICH "$new_path" 2> /dev/null` 9337 # bat and cmd files are not always considered executable in cygwin causing which 9338 # to not find them 9339 if test "x$new_path" = x \ 9340 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9341 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9342 new_path=`$CYGPATH -u "$path"` 9343 fi 9344 if test "x$new_path" = x; then 9345 # Oops. Which didn't find the executable. 9346 # The splitting of arguments from the executable at a space might have been incorrect, 9347 # since paths with space are more likely in Windows. Give it another try with the whole 9348 # argument. 9349 path="$complete" 9350 arguments="EOL" 9351 new_path=`$CYGPATH -u "$path"` 9352 new_path=`$WHICH "$new_path" 2> /dev/null` 9353 # bat and cmd files are not always considered executable in cygwin causing which 9354 # to not find them 9355 if test "x$new_path" = x \ 9356 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9357 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9358 new_path=`$CYGPATH -u "$path"` 9359 fi 9360 if test "x$new_path" = x; then 9361 # It's still not found. Now this is an unrecoverable error. 9362 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9363 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9364 has_space=`$ECHO "$complete" | $GREP " "` 9365 if test "x$has_space" != x; then 9366 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9367 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9368 fi 9369 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9370 fi 9371 fi 9372 9373 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9374 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9375 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9376 # "foo.exe" is OK but "foo" is an error. 9377 # 9378 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9379 # It is also a way to make sure we got the proper file name for the real test later on. 9380 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9381 if test "x$test_shortpath" = x; then 9382 # Short path failed, file does not exist as specified. 9383 # Try adding .exe or .cmd 9384 if test -f "${new_path}.exe"; then 9385 input_to_shortpath="${new_path}.exe" 9386 elif test -f "${new_path}.cmd"; then 9387 input_to_shortpath="${new_path}.cmd" 9388 else 9389 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9390 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9391 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9392 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9393 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9394 fi 9395 else 9396 input_to_shortpath="$new_path" 9397 fi 9398 9399 # Call helper function which possibly converts this using DOS-style short mode. 9400 # If so, the updated path is stored in $new_path. 9401 new_path="$input_to_shortpath" 9402 9403 input_path="$input_to_shortpath" 9404 # Check if we need to convert this using DOS-style short mode. If the path 9405 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9406 # take no chances and rewrite it. 9407 # Note: m4 eats our [], so we need to use [ and ] instead. 9408 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9409 if test "x$has_forbidden_chars" != x; then 9410 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9411 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9412 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9413 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9414 # Going to short mode and back again did indeed matter. Since short mode is 9415 # case insensitive, let's make it lowercase to improve readability. 9416 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9417 # Now convert it back to Unix-stile (cygpath) 9418 input_path=`$CYGPATH -u "$shortmode_path"` 9419 new_path="$input_path" 9420 fi 9421 fi 9422 9423 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9424 if test "x$test_cygdrive_prefix" = x; then 9425 # As a simple fix, exclude /usr/bin since it's not a real path. 9426 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9427 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9428 # a path prefixed by /cygdrive for fixpath to work. 9429 new_path="$CYGWIN_ROOT_PATH$input_path" 9430 fi 9431 fi 9432 9433 # remove trailing .exe if any 9434 new_path="${new_path/%.exe/}" 9435 9436 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9437 9438 # First separate the path from the arguments. This will split at the first 9439 # space. 9440 complete="$FOUND_MAKE" 9441 path="${complete%% *}" 9442 tmp="$complete EOL" 9443 arguments="${tmp#* }" 9444 9445 # Input might be given as Windows format, start by converting to 9446 # unix format. 9447 new_path="$path" 9448 9449 windows_path="$new_path" 9450 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9451 unix_path=`$CYGPATH -u "$windows_path"` 9452 new_path="$unix_path" 9453 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9454 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9455 new_path="$unix_path" 9456 fi 9457 9458 9459 # Now try to locate executable using which 9460 new_path=`$WHICH "$new_path" 2> /dev/null` 9461 9462 if test "x$new_path" = x; then 9463 # Oops. Which didn't find the executable. 9464 # The splitting of arguments from the executable at a space might have been incorrect, 9465 # since paths with space are more likely in Windows. Give it another try with the whole 9466 # argument. 9467 path="$complete" 9468 arguments="EOL" 9469 new_path="$path" 9470 9471 windows_path="$new_path" 9472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9473 unix_path=`$CYGPATH -u "$windows_path"` 9474 new_path="$unix_path" 9475 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9476 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9477 new_path="$unix_path" 9478 fi 9479 9480 9481 new_path=`$WHICH "$new_path" 2> /dev/null` 9482 9483 if test "x$new_path" = x; then 9484 # It's still not found. Now this is an unrecoverable error. 9485 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9486 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9487 has_space=`$ECHO "$complete" | $GREP " "` 9488 if test "x$has_space" != x; then 9489 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9490 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9491 fi 9492 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9493 fi 9494 fi 9495 9496 # Now new_path has a complete unix path to the binary 9497 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9498 # Keep paths in /bin as-is, but remove trailing .exe if any 9499 new_path="${new_path/%.exe/}" 9500 # Do not save /bin paths to all_fixpath_prefixes! 9501 else 9502 # Not in mixed or Windows style, start by that. 9503 new_path=`cmd //c echo $new_path` 9504 9505 input_path="$new_path" 9506 # Check if we need to convert this using DOS-style short mode. If the path 9507 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9508 # take no chances and rewrite it. 9509 # Note: m4 eats our [], so we need to use [ and ] instead. 9510 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9511 if test "x$has_forbidden_chars" != x; then 9512 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9513 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9514 fi 9515 9516 # Output is in $new_path 9517 9518 windows_path="$new_path" 9519 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9520 unix_path=`$CYGPATH -u "$windows_path"` 9521 new_path="$unix_path" 9522 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9523 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9524 new_path="$unix_path" 9525 fi 9526 9527 # remove trailing .exe if any 9528 new_path="${new_path/%.exe/}" 9529 9530 # Save the first 10 bytes of this path to the storage, so fixpath can work. 9531 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 9532 fi 9533 9534 else 9535 # We're on a posix platform. Hooray! :) 9536 # First separate the path from the arguments. This will split at the first 9537 # space. 9538 complete="$FOUND_MAKE" 9539 path="${complete%% *}" 9540 tmp="$complete EOL" 9541 arguments="${tmp#* }" 9542 9543 # Cannot rely on the command "which" here since it doesn't always work. 9544 is_absolute_path=`$ECHO "$path" | $GREP ^/` 9545 if test -z "$is_absolute_path"; then 9546 # Path to executable is not absolute. Find it. 9547 IFS_save="$IFS" 9548 IFS=: 9549 for p in $PATH; do 9550 if test -f "$p/$path" && test -x "$p/$path"; then 9551 new_path="$p/$path" 9552 break 9553 fi 9554 done 9555 IFS="$IFS_save" 9556 else 9557 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 9558 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 9559 new_path="$path" 9560 fi 9561 9562 if test "x$new_path" = x; then 9563 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9564 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9565 has_space=`$ECHO "$complete" | $GREP " "` 9566 if test "x$has_space" != x; then 9567 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 9568 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 9569 fi 9570 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9571 fi 9572 fi 9573 9574 # Now join together the path and the arguments once again 9575 if test "x$arguments" != xEOL; then 9576 new_complete="$new_path ${arguments% *}" 9577 else 9578 new_complete="$new_path" 9579 fi 9580 9581 if test "x$complete" != "x$new_complete"; then 9582 FOUND_MAKE="$new_complete" 9583 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 9584 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 9585 fi 9586 9587 fi 9588 fi 9589 fi 9590 fi 9591 9592 if test "x$FOUND_MAKE" = x; then 9593 for ac_prog in make 9594 do 9595 # Extract the first word of "$ac_prog", so it can be a program name with args. 9596 set dummy $ac_prog; ac_word=$2 9597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9598 $as_echo_n "checking for $ac_word... " >&6; } 9599 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 9600 $as_echo_n "(cached) " >&6 9601 else 9602 case $CHECK_TOOLSDIR_MAKE in 9603 [\\/]* | ?:[\\/]*) 9604 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 9605 ;; 9606 *) 9607 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9608 for as_dir in $PATH 9609 do 9610 IFS=$as_save_IFS 9611 test -z "$as_dir" && as_dir=. 9612 for ac_exec_ext in '' $ac_executable_extensions; do 9613 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 9614 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 9615 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9616 break 2 9617 fi 9618 done 9619 done 9620 IFS=$as_save_IFS 9621 9622 ;; 9623 esac 9624 fi 9625 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 9626 if test -n "$CHECK_TOOLSDIR_MAKE"; then 9627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 9628 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 9629 else 9630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9631 $as_echo "no" >&6; } 9632 fi 9633 9634 9635 test -n "$CHECK_TOOLSDIR_MAKE" && break 9636 done 9637 9638 9639 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 9640 DESCRIPTION="make in tools-dir" 9641 if test "x$MAKE_CANDIDATE" != x; then 9642 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 9643 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 9644 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 9645 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 9646 if test "x$IS_GNU_MAKE" = x; then 9647 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 9648 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 9649 else 9650 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP '3.8[12346789]'` 9651 if test "x$IS_MODERN_MAKE" = x; then 9652 { $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 9653 $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;} 9654 else 9655 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 9656 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9657 MAKE_EXPECTED_ENV='cygwin' 9658 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9659 MAKE_EXPECTED_ENV='msys' 9660 else 9661 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 9662 fi 9663 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 9664 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 9665 else 9666 # Not relevant for non-Windows 9667 IS_MAKE_CORRECT_ENV=true 9668 fi 9669 if test "x$IS_MAKE_CORRECT_ENV" = x; then 9670 { $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 9671 $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;} 9672 else 9673 FOUND_MAKE=$MAKE_CANDIDATE 9674 9675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9676 9677 # First separate the path from the arguments. This will split at the first 9678 # space. 9679 complete="$FOUND_MAKE" 9680 path="${complete%% *}" 9681 tmp="$complete EOL" 9682 arguments="${tmp#* }" 9683 9684 # Input might be given as Windows format, start by converting to 9685 # unix format. 9686 new_path=`$CYGPATH -u "$path"` 9687 9688 # Now try to locate executable using which 9689 new_path=`$WHICH "$new_path" 2> /dev/null` 9690 # bat and cmd files are not always considered executable in cygwin causing which 9691 # to not find them 9692 if test "x$new_path" = x \ 9693 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9694 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9695 new_path=`$CYGPATH -u "$path"` 9696 fi 9697 if test "x$new_path" = x; then 9698 # Oops. Which didn't find the executable. 9699 # The splitting of arguments from the executable at a space might have been incorrect, 9700 # since paths with space are more likely in Windows. Give it another try with the whole 9701 # argument. 9702 path="$complete" 9703 arguments="EOL" 9704 new_path=`$CYGPATH -u "$path"` 9705 new_path=`$WHICH "$new_path" 2> /dev/null` 9706 # bat and cmd files are not always considered executable in cygwin causing which 9707 # to not find them 9708 if test "x$new_path" = x \ 9709 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 9710 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 9711 new_path=`$CYGPATH -u "$path"` 9712 fi 9713 if test "x$new_path" = x; then 9714 # It's still not found. Now this is an unrecoverable error. 9715 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9716 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9717 has_space=`$ECHO "$complete" | $GREP " "` 9718 if test "x$has_space" != x; then 9719 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9720 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9721 fi 9722 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9723 fi 9724 fi 9725 9726 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 9727 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 9728 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 9729 # "foo.exe" is OK but "foo" is an error. 9730 # 9731 # This test is therefore slightly more accurate than "test -f" to check for file precense. 9732 # It is also a way to make sure we got the proper file name for the real test later on. 9733 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 9734 if test "x$test_shortpath" = x; then 9735 # Short path failed, file does not exist as specified. 9736 # Try adding .exe or .cmd 9737 if test -f "${new_path}.exe"; then 9738 input_to_shortpath="${new_path}.exe" 9739 elif test -f "${new_path}.cmd"; then 9740 input_to_shortpath="${new_path}.cmd" 9741 else 9742 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 9743 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 9744 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 9745 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 9746 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9747 fi 9748 else 9749 input_to_shortpath="$new_path" 9750 fi 9751 9752 # Call helper function which possibly converts this using DOS-style short mode. 9753 # If so, the updated path is stored in $new_path. 9754 new_path="$input_to_shortpath" 9755 9756 input_path="$input_to_shortpath" 9757 # Check if we need to convert this using DOS-style short mode. If the path 9758 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9759 # take no chances and rewrite it. 9760 # Note: m4 eats our [], so we need to use [ and ] instead. 9761 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 9762 if test "x$has_forbidden_chars" != x; then 9763 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9764 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 9765 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 9766 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 9767 # Going to short mode and back again did indeed matter. Since short mode is 9768 # case insensitive, let's make it lowercase to improve readability. 9769 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9770 # Now convert it back to Unix-stile (cygpath) 9771 input_path=`$CYGPATH -u "$shortmode_path"` 9772 new_path="$input_path" 9773 fi 9774 fi 9775 9776 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 9777 if test "x$test_cygdrive_prefix" = x; then 9778 # As a simple fix, exclude /usr/bin since it's not a real path. 9779 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 9780 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 9781 # a path prefixed by /cygdrive for fixpath to work. 9782 new_path="$CYGWIN_ROOT_PATH$input_path" 9783 fi 9784 fi 9785 9786 # remove trailing .exe if any 9787 new_path="${new_path/%.exe/}" 9788 9789 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9790 9791 # First separate the path from the arguments. This will split at the first 9792 # space. 9793 complete="$FOUND_MAKE" 9794 path="${complete%% *}" 9795 tmp="$complete EOL" 9796 arguments="${tmp#* }" 9797 9798 # Input might be given as Windows format, start by converting to 9799 # unix format. 9800 new_path="$path" 9801 9802 windows_path="$new_path" 9803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9804 unix_path=`$CYGPATH -u "$windows_path"` 9805 new_path="$unix_path" 9806 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9807 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9808 new_path="$unix_path" 9809 fi 9810 9811 9812 # Now try to locate executable using which 9813 new_path=`$WHICH "$new_path" 2> /dev/null` 9814 9815 if test "x$new_path" = x; then 9816 # Oops. Which didn't find the executable. 9817 # The splitting of arguments from the executable at a space might have been incorrect, 9818 # since paths with space are more likely in Windows. Give it another try with the whole 9819 # argument. 9820 path="$complete" 9821 arguments="EOL" 9822 new_path="$path" 9823 9824 windows_path="$new_path" 9825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9826 unix_path=`$CYGPATH -u "$windows_path"` 9827 new_path="$unix_path" 9828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9829 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9830 new_path="$unix_path" 9831 fi 9832 9833 9834 new_path=`$WHICH "$new_path" 2> /dev/null` 9835 9836 if test "x$new_path" = x; then 9837 # It's still not found. Now this is an unrecoverable error. 9838 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9839 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9840 has_space=`$ECHO "$complete" | $GREP " "` 9841 if test "x$has_space" != x; then 9842 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 9843 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 9844 fi 9845 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9846 fi 9847 fi 9848 9849 # Now new_path has a complete unix path to the binary 9850 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 9851 # Keep paths in /bin as-is, but remove trailing .exe if any 9852 new_path="${new_path/%.exe/}" 9853 # Do not save /bin paths to all_fixpath_prefixes! 9854 else 9855 # Not in mixed or Windows style, start by that. 9856 new_path=`cmd //c echo $new_path` 9857 9858 input_path="$new_path" 9859 # Check if we need to convert this using DOS-style short mode. If the path 9860 # contains just simple characters, use it. Otherwise (spaces, weird characters), 9861 # take no chances and rewrite it. 9862 # Note: m4 eats our [], so we need to use [ and ] instead. 9863 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 9864 if test "x$has_forbidden_chars" != x; then 9865 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 9866 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 9867 fi 9868 9869 # Output is in $new_path 9870 9871 windows_path="$new_path" 9872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 9873 unix_path=`$CYGPATH -u "$windows_path"` 9874 new_path="$unix_path" 9875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 9876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 9877 new_path="$unix_path" 9878 fi 9879 9880 # remove trailing .exe if any 9881 new_path="${new_path/%.exe/}" 9882 9883 # Save the first 10 bytes of this path to the storage, so fixpath can work. 9884 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 9885 fi 9886 9887 else 9888 # We're on a posix platform. Hooray! :) 9889 # First separate the path from the arguments. This will split at the first 9890 # space. 9891 complete="$FOUND_MAKE" 9892 path="${complete%% *}" 9893 tmp="$complete EOL" 9894 arguments="${tmp#* }" 9895 9896 # Cannot rely on the command "which" here since it doesn't always work. 9897 is_absolute_path=`$ECHO "$path" | $GREP ^/` 9898 if test -z "$is_absolute_path"; then 9899 # Path to executable is not absolute. Find it. 9900 IFS_save="$IFS" 9901 IFS=: 9902 for p in $PATH; do 9903 if test -f "$p/$path" && test -x "$p/$path"; then 9904 new_path="$p/$path" 9905 break 9906 fi 9907 done 9908 IFS="$IFS_save" 9909 else 9910 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5 9911 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;} 9912 new_path="$path" 9913 fi 9914 9915 if test "x$new_path" = x; then 9916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 9917 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 9918 has_space=`$ECHO "$complete" | $GREP " "` 9919 if test "x$has_space" != x; then 9920 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 9921 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 9922 fi 9923 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 9924 fi 9925 fi 9926 9927 # Now join together the path and the arguments once again 9928 if test "x$arguments" != xEOL; then 9929 new_complete="$new_path ${arguments% *}" 9930 else 9931 new_complete="$new_path" 9932 fi 9933 9934 if test "x$complete" != "x$new_complete"; then 9935 FOUND_MAKE="$new_complete" 9936 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 9937 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 9938 fi 9939 9940 fi 9941 fi 9942 fi 9943 fi 9944 9945 fi 9946 PATH=$OLD_PATH 9947 fi 9948 fi 9949 9950 if test "x$FOUND_MAKE" = x; then 9951 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 9952 fi 9953 fi 9954 9955 MAKE=$FOUND_MAKE 9956 9957 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 9958 $as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 9959 9960 9961 9962 # Test if find supports -delete 9963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 9964 $as_echo_n "checking if find supports -delete... " >&6; } 9965 FIND_DELETE="-delete" 9966 9967 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 9968 9969 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 9970 9971 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 9972 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 9973 # No, it does not. 9974 rm $DELETEDIR/TestIfFindSupportsDelete 9975 FIND_DELETE="-exec rm \{\} \+" 9976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9977 $as_echo "no" >&6; } 9978 else 9979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9980 $as_echo "yes" >&6; } 9981 fi 9982 rmdir $DELETEDIR 9983 9984 9985 9986 # These tools might not be installed by default, 9987 # need hint on how to install them. 9988 9989 for ac_prog in unzip 9990 do 9991 # Extract the first word of "$ac_prog", so it can be a program name with args. 9992 set dummy $ac_prog; ac_word=$2 9993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9994 $as_echo_n "checking for $ac_word... " >&6; } 9995 if ${ac_cv_path_UNZIP+:} false; then : 9996 $as_echo_n "(cached) " >&6 9997 else 9998 case $UNZIP in 9999 [\\/]* | ?:[\\/]*) 10000 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 10001 ;; 10002 *) 10003 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10004 for as_dir in $PATH 10005 do 10006 IFS=$as_save_IFS 10007 test -z "$as_dir" && as_dir=. 10008 for ac_exec_ext in '' $ac_executable_extensions; do 10009 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10010 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 10011 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10012 break 2 10013 fi 10014 done 10015 done 10016 IFS=$as_save_IFS 10017 10018 ;; 10019 esac 10020 fi 10021 UNZIP=$ac_cv_path_UNZIP 10022 if test -n "$UNZIP"; then 10023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 10024 $as_echo "$UNZIP" >&6; } 10025 else 10026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10027 $as_echo "no" >&6; } 10028 fi 10029 10030 10031 test -n "$UNZIP" && break 10032 done 10033 10034 10035 if test "x$UNZIP" = x; then 10036 if test "xunzip" = x; then 10037 PROG_NAME=unzip 10038 else 10039 PROG_NAME=unzip 10040 fi 10041 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10042 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10043 as_fn_error $? "Cannot continue" "$LINENO" 5 10044 fi 10045 10046 10047 10048 for ac_prog in zip 10049 do 10050 # Extract the first word of "$ac_prog", so it can be a program name with args. 10051 set dummy $ac_prog; ac_word=$2 10052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10053 $as_echo_n "checking for $ac_word... " >&6; } 10054 if ${ac_cv_path_ZIP+:} false; then : 10055 $as_echo_n "(cached) " >&6 10056 else 10057 case $ZIP in 10058 [\\/]* | ?:[\\/]*) 10059 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 10060 ;; 10061 *) 10062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10063 for as_dir in $PATH 10064 do 10065 IFS=$as_save_IFS 10066 test -z "$as_dir" && as_dir=. 10067 for ac_exec_ext in '' $ac_executable_extensions; do 10068 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10069 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 10070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10071 break 2 10072 fi 10073 done 10074 done 10075 IFS=$as_save_IFS 10076 10077 ;; 10078 esac 10079 fi 10080 ZIP=$ac_cv_path_ZIP 10081 if test -n "$ZIP"; then 10082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 10083 $as_echo "$ZIP" >&6; } 10084 else 10085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10086 $as_echo "no" >&6; } 10087 fi 10088 10089 10090 test -n "$ZIP" && break 10091 done 10092 10093 10094 if test "x$ZIP" = x; then 10095 if test "xzip" = x; then 10096 PROG_NAME=zip 10097 else 10098 PROG_NAME=zip 10099 fi 10100 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10101 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10102 as_fn_error $? "Cannot continue" "$LINENO" 5 10103 fi 10104 10105 10106 10107 # Non-required basic tools 10108 10109 # Extract the first word of "ldd", so it can be a program name with args. 10110 set dummy ldd; ac_word=$2 10111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10112 $as_echo_n "checking for $ac_word... " >&6; } 10113 if ${ac_cv_path_LDD+:} false; then : 10114 $as_echo_n "(cached) " >&6 10115 else 10116 case $LDD in 10117 [\\/]* | ?:[\\/]*) 10118 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 10119 ;; 10120 *) 10121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10122 for as_dir in $PATH 10123 do 10124 IFS=$as_save_IFS 10125 test -z "$as_dir" && as_dir=. 10126 for ac_exec_ext in '' $ac_executable_extensions; do 10127 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10128 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 10129 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10130 break 2 10131 fi 10132 done 10133 done 10134 IFS=$as_save_IFS 10135 10136 ;; 10137 esac 10138 fi 10139 LDD=$ac_cv_path_LDD 10140 if test -n "$LDD"; then 10141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 10142 $as_echo "$LDD" >&6; } 10143 else 10144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10145 $as_echo "no" >&6; } 10146 fi 10147 10148 10149 if test "x$LDD" = "x"; then 10150 # List shared lib dependencies is used for 10151 # debug output and checking for forbidden dependencies. 10152 # We can build without it. 10153 LDD="true" 10154 fi 10155 # Extract the first word of "otool", so it can be a program name with args. 10156 set dummy otool; ac_word=$2 10157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10158 $as_echo_n "checking for $ac_word... " >&6; } 10159 if ${ac_cv_path_OTOOL+:} false; then : 10160 $as_echo_n "(cached) " >&6 10161 else 10162 case $OTOOL in 10163 [\\/]* | ?:[\\/]*) 10164 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 10165 ;; 10166 *) 10167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10168 for as_dir in $PATH 10169 do 10170 IFS=$as_save_IFS 10171 test -z "$as_dir" && as_dir=. 10172 for ac_exec_ext in '' $ac_executable_extensions; do 10173 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10174 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 10175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10176 break 2 10177 fi 10178 done 10179 done 10180 IFS=$as_save_IFS 10181 10182 ;; 10183 esac 10184 fi 10185 OTOOL=$ac_cv_path_OTOOL 10186 if test -n "$OTOOL"; then 10187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 10188 $as_echo "$OTOOL" >&6; } 10189 else 10190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10191 $as_echo "no" >&6; } 10192 fi 10193 10194 10195 if test "x$OTOOL" = "x"; then 10196 OTOOL="true" 10197 fi 10198 for ac_prog in readelf greadelf 10199 do 10200 # Extract the first word of "$ac_prog", so it can be a program name with args. 10201 set dummy $ac_prog; ac_word=$2 10202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10203 $as_echo_n "checking for $ac_word... " >&6; } 10204 if ${ac_cv_path_READELF+:} false; then : 10205 $as_echo_n "(cached) " >&6 10206 else 10207 case $READELF in 10208 [\\/]* | ?:[\\/]*) 10209 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 10210 ;; 10211 *) 10212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10213 for as_dir in $PATH 10214 do 10215 IFS=$as_save_IFS 10216 test -z "$as_dir" && as_dir=. 10217 for ac_exec_ext in '' $ac_executable_extensions; do 10218 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10219 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 10220 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10221 break 2 10222 fi 10223 done 10224 done 10225 IFS=$as_save_IFS 10226 10227 ;; 10228 esac 10229 fi 10230 READELF=$ac_cv_path_READELF 10231 if test -n "$READELF"; then 10232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 10233 $as_echo "$READELF" >&6; } 10234 else 10235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10236 $as_echo "no" >&6; } 10237 fi 10238 10239 10240 test -n "$READELF" && break 10241 done 10242 10243 # Extract the first word of "hg", so it can be a program name with args. 10244 set dummy hg; ac_word=$2 10245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10246 $as_echo_n "checking for $ac_word... " >&6; } 10247 if ${ac_cv_path_HG+:} false; then : 10248 $as_echo_n "(cached) " >&6 10249 else 10250 case $HG in 10251 [\\/]* | ?:[\\/]*) 10252 ac_cv_path_HG="$HG" # Let the user override the test with a path. 10253 ;; 10254 *) 10255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10256 for as_dir in $PATH 10257 do 10258 IFS=$as_save_IFS 10259 test -z "$as_dir" && as_dir=. 10260 for ac_exec_ext in '' $ac_executable_extensions; do 10261 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10262 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 10263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10264 break 2 10265 fi 10266 done 10267 done 10268 IFS=$as_save_IFS 10269 10270 ;; 10271 esac 10272 fi 10273 HG=$ac_cv_path_HG 10274 if test -n "$HG"; then 10275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 10276 $as_echo "$HG" >&6; } 10277 else 10278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10279 $as_echo "no" >&6; } 10280 fi 10281 10282 10283 # Extract the first word of "stat", so it can be a program name with args. 10284 set dummy stat; ac_word=$2 10285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10286 $as_echo_n "checking for $ac_word... " >&6; } 10287 if ${ac_cv_path_STAT+:} false; then : 10288 $as_echo_n "(cached) " >&6 10289 else 10290 case $STAT in 10291 [\\/]* | ?:[\\/]*) 10292 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 10293 ;; 10294 *) 10295 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10296 for as_dir in $PATH 10297 do 10298 IFS=$as_save_IFS 10299 test -z "$as_dir" && as_dir=. 10300 for ac_exec_ext in '' $ac_executable_extensions; do 10301 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10302 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 10303 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10304 break 2 10305 fi 10306 done 10307 done 10308 IFS=$as_save_IFS 10309 10310 ;; 10311 esac 10312 fi 10313 STAT=$ac_cv_path_STAT 10314 if test -n "$STAT"; then 10315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 10316 $as_echo "$STAT" >&6; } 10317 else 10318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10319 $as_echo "no" >&6; } 10320 fi 10321 10322 10323 # Extract the first word of "time", so it can be a program name with args. 10324 set dummy time; ac_word=$2 10325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10326 $as_echo_n "checking for $ac_word... " >&6; } 10327 if ${ac_cv_path_TIME+:} false; then : 10328 $as_echo_n "(cached) " >&6 10329 else 10330 case $TIME in 10331 [\\/]* | ?:[\\/]*) 10332 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 10333 ;; 10334 *) 10335 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10336 for as_dir in $PATH 10337 do 10338 IFS=$as_save_IFS 10339 test -z "$as_dir" && as_dir=. 10340 for ac_exec_ext in '' $ac_executable_extensions; do 10341 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10342 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 10343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10344 break 2 10345 fi 10346 done 10347 done 10348 IFS=$as_save_IFS 10349 10350 ;; 10351 esac 10352 fi 10353 TIME=$ac_cv_path_TIME 10354 if test -n "$TIME"; then 10355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 10356 $as_echo "$TIME" >&6; } 10357 else 10358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10359 $as_echo "no" >&6; } 10360 fi 10361 10362 10363 # Check if it's GNU time 10364 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 10365 if test "x$IS_GNU_TIME" != x; then 10366 IS_GNU_TIME=yes 10367 else 10368 IS_GNU_TIME=no 10369 fi 10370 10371 10372 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 10373 10374 for ac_prog in comm 10375 do 10376 # Extract the first word of "$ac_prog", so it can be a program name with args. 10377 set dummy $ac_prog; ac_word=$2 10378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10379 $as_echo_n "checking for $ac_word... " >&6; } 10380 if ${ac_cv_path_COMM+:} false; then : 10381 $as_echo_n "(cached) " >&6 10382 else 10383 case $COMM in 10384 [\\/]* | ?:[\\/]*) 10385 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 10386 ;; 10387 *) 10388 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10389 for as_dir in $PATH 10390 do 10391 IFS=$as_save_IFS 10392 test -z "$as_dir" && as_dir=. 10393 for ac_exec_ext in '' $ac_executable_extensions; do 10394 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10395 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 10396 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10397 break 2 10398 fi 10399 done 10400 done 10401 IFS=$as_save_IFS 10402 10403 ;; 10404 esac 10405 fi 10406 COMM=$ac_cv_path_COMM 10407 if test -n "$COMM"; then 10408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 10409 $as_echo "$COMM" >&6; } 10410 else 10411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10412 $as_echo "no" >&6; } 10413 fi 10414 10415 10416 test -n "$COMM" && break 10417 done 10418 10419 10420 if test "x$COMM" = x; then 10421 if test "xcomm" = x; then 10422 PROG_NAME=comm 10423 else 10424 PROG_NAME=comm 10425 fi 10426 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10427 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10428 as_fn_error $? "Cannot continue" "$LINENO" 5 10429 fi 10430 10431 10432 fi 10433 10434 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 10435 10436 for ac_prog in xattr 10437 do 10438 # Extract the first word of "$ac_prog", so it can be a program name with args. 10439 set dummy $ac_prog; ac_word=$2 10440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10441 $as_echo_n "checking for $ac_word... " >&6; } 10442 if ${ac_cv_path_XATTR+:} false; then : 10443 $as_echo_n "(cached) " >&6 10444 else 10445 case $XATTR in 10446 [\\/]* | ?:[\\/]*) 10447 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 10448 ;; 10449 *) 10450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10451 for as_dir in $PATH 10452 do 10453 IFS=$as_save_IFS 10454 test -z "$as_dir" && as_dir=. 10455 for ac_exec_ext in '' $ac_executable_extensions; do 10456 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10457 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 10458 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10459 break 2 10460 fi 10461 done 10462 done 10463 IFS=$as_save_IFS 10464 10465 ;; 10466 esac 10467 fi 10468 XATTR=$ac_cv_path_XATTR 10469 if test -n "$XATTR"; then 10470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 10471 $as_echo "$XATTR" >&6; } 10472 else 10473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10474 $as_echo "no" >&6; } 10475 fi 10476 10477 10478 test -n "$XATTR" && break 10479 done 10480 10481 10482 if test "x$XATTR" = x; then 10483 if test "xxattr" = x; then 10484 PROG_NAME=xattr 10485 else 10486 PROG_NAME=xattr 10487 fi 10488 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 10489 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 10490 as_fn_error $? "Cannot continue" "$LINENO" 5 10491 fi 10492 10493 10494 # Extract the first word of "codesign", so it can be a program name with args. 10495 set dummy codesign; ac_word=$2 10496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10497 $as_echo_n "checking for $ac_word... " >&6; } 10498 if ${ac_cv_path_CODESIGN+:} false; then : 10499 $as_echo_n "(cached) " >&6 10500 else 10501 case $CODESIGN in 10502 [\\/]* | ?:[\\/]*) 10503 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 10504 ;; 10505 *) 10506 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10507 for as_dir in $PATH 10508 do 10509 IFS=$as_save_IFS 10510 test -z "$as_dir" && as_dir=. 10511 for ac_exec_ext in '' $ac_executable_extensions; do 10512 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10513 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 10514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10515 break 2 10516 fi 10517 done 10518 done 10519 IFS=$as_save_IFS 10520 10521 ;; 10522 esac 10523 fi 10524 CODESIGN=$ac_cv_path_CODESIGN 10525 if test -n "$CODESIGN"; then 10526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 10527 $as_echo "$CODESIGN" >&6; } 10528 else 10529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10530 $as_echo "no" >&6; } 10531 fi 10532 10533 10534 if test "x$CODESIGN" != "x"; then 10535 # Verify that the openjdk_codesign certificate is present 10536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 10537 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 10538 rm -f codesign-testfile 10539 touch codesign-testfile 10540 codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 10541 rm -f codesign-testfile 10542 if test "x$CODESIGN" = x; then 10543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10544 $as_echo "no" >&6; } 10545 else 10546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10547 $as_echo "yes" >&6; } 10548 fi 10549 fi 10550 fi 10551 10552 10553 # Check if pkg-config is available. 10554 10555 10556 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 10557 if test -n "$ac_tool_prefix"; then 10558 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 10559 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 10560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10561 $as_echo_n "checking for $ac_word... " >&6; } 10562 if ${ac_cv_path_PKG_CONFIG+:} false; then : 10563 $as_echo_n "(cached) " >&6 10564 else 10565 case $PKG_CONFIG in 10566 [\\/]* | ?:[\\/]*) 10567 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 10568 ;; 10569 *) 10570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10571 for as_dir in $PATH 10572 do 10573 IFS=$as_save_IFS 10574 test -z "$as_dir" && as_dir=. 10575 for ac_exec_ext in '' $ac_executable_extensions; do 10576 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10577 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 10578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10579 break 2 10580 fi 10581 done 10582 done 10583 IFS=$as_save_IFS 10584 10585 ;; 10586 esac 10587 fi 10588 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 10589 if test -n "$PKG_CONFIG"; then 10590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 10591 $as_echo "$PKG_CONFIG" >&6; } 10592 else 10593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10594 $as_echo "no" >&6; } 10595 fi 10596 10597 10598 fi 10599 if test -z "$ac_cv_path_PKG_CONFIG"; then 10600 ac_pt_PKG_CONFIG=$PKG_CONFIG 10601 # Extract the first word of "pkg-config", so it can be a program name with args. 10602 set dummy pkg-config; ac_word=$2 10603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10604 $as_echo_n "checking for $ac_word... " >&6; } 10605 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 10606 $as_echo_n "(cached) " >&6 10607 else 10608 case $ac_pt_PKG_CONFIG in 10609 [\\/]* | ?:[\\/]*) 10610 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 10611 ;; 10612 *) 10613 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10614 for as_dir in $PATH 10615 do 10616 IFS=$as_save_IFS 10617 test -z "$as_dir" && as_dir=. 10618 for ac_exec_ext in '' $ac_executable_extensions; do 10619 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10620 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 10621 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10622 break 2 10623 fi 10624 done 10625 done 10626 IFS=$as_save_IFS 10627 10628 ;; 10629 esac 10630 fi 10631 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 10632 if test -n "$ac_pt_PKG_CONFIG"; then 10633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 10634 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 10635 else 10636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10637 $as_echo "no" >&6; } 10638 fi 10639 10640 if test "x$ac_pt_PKG_CONFIG" = x; then 10641 PKG_CONFIG="" 10642 else 10643 case $cross_compiling:$ac_tool_warned in 10644 yes:) 10645 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 10646 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 10647 ac_tool_warned=yes ;; 10648 esac 10649 PKG_CONFIG=$ac_pt_PKG_CONFIG 10650 fi 10651 else 10652 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 10653 fi 10654 10655 fi 10656 if test -n "$PKG_CONFIG"; then 10657 _pkg_min_version=0.9.0 10658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 10659 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 10660 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 10661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10662 $as_echo "yes" >&6; } 10663 else 10664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10665 $as_echo "no" >&6; } 10666 PKG_CONFIG="" 10667 fi 10668 10669 fi 10670 10671 # After basic tools have been setup, we can check build os specific details. 10672 10673 ############################################################################### 10674 10675 # Note that this is the build platform OS version! 10676 10677 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 10678 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 10679 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 10680 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 10681 10682 10683 10684 10685 10686 # Setup builddeps, for automatic downloading of tools we need. 10687 # This is needed before we can call BDEPS_CHECK_MODULE, which is done in 10688 # boot-jdk setup, but we need to have basic tools setup first. 10689 10690 10691 # Check whether --with-builddeps-conf was given. 10692 if test "${with_builddeps_conf+set}" = set; then : 10693 withval=$with_builddeps_conf; 10694 fi 10695 10696 10697 10698 # Check whether --with-builddeps-server was given. 10699 if test "${with_builddeps_server+set}" = set; then : 10700 withval=$with_builddeps_server; 10701 fi 10702 10703 10704 10705 # Check whether --with-builddeps-dir was given. 10706 if test "${with_builddeps_dir+set}" = set; then : 10707 withval=$with_builddeps_dir; 10708 else 10709 with_builddeps_dir=/localhome/builddeps 10710 fi 10711 10712 10713 10714 # Check whether --with-builddeps-group was given. 10715 if test "${with_builddeps_group+set}" = set; then : 10716 withval=$with_builddeps_group; 10717 fi 10718 10719 10720 10721 10722 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 10723 if test "x$with_builddeps_conf" != x; then 10724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5 10725 $as_echo_n "checking for supplied builddeps configuration file... " >&6; } 10726 builddepsfile=$with_builddeps_conf 10727 if test -s $builddepsfile; then 10728 . $builddepsfile 10729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5 10730 $as_echo "loaded!" >&6; } 10731 else 10732 as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5 10733 fi 10734 else 10735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5 10736 $as_echo_n "checking for builddeps.conf files in sources...... " >&6; } 10737 builddepsfile=`mktemp` 10738 touch $builddepsfile 10739 # Put all found confs into a single file. 10740 find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile 10741 # Source the file to acquire the variables 10742 if test -s $builddepsfile; then 10743 . $builddepsfile 10744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5 10745 $as_echo "found at least one!" >&6; } 10746 else 10747 as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5 10748 fi 10749 fi 10750 # Create build and target names that use _ instead of "-" and ".". 10751 # This is necessary to use them in variable names. 10752 build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'` 10753 target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'` 10754 # Extract rewrite information for build and target 10755 eval rewritten_build=\${REWRITE_${build_var}} 10756 if test "x$rewritten_build" = x; then 10757 rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME} 10758 echo Build stays the same $rewritten_build 10759 else 10760 echo Rewriting build for builddeps into $rewritten_build 10761 fi 10762 eval rewritten_target=\${REWRITE_${target_var}} 10763 if test "x$rewritten_target" = x; then 10764 rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME} 10765 echo Target stays the same $rewritten_target 10766 else 10767 echo Rewriting target for builddeps into $rewritten_target 10768 fi 10769 rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'` 10770 rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'` 10771 fi 10772 for ac_prog in 7z unzip 10773 do 10774 # Extract the first word of "$ac_prog", so it can be a program name with args. 10775 set dummy $ac_prog; ac_word=$2 10776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10777 $as_echo_n "checking for $ac_word... " >&6; } 10778 if ${ac_cv_prog_BDEPS_UNZIP+:} false; then : 10779 $as_echo_n "(cached) " >&6 10780 else 10781 if test -n "$BDEPS_UNZIP"; then 10782 ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test. 10783 else 10784 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10785 for as_dir in $PATH 10786 do 10787 IFS=$as_save_IFS 10788 test -z "$as_dir" && as_dir=. 10789 for ac_exec_ext in '' $ac_executable_extensions; do 10790 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10791 ac_cv_prog_BDEPS_UNZIP="$ac_prog" 10792 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10793 break 2 10794 fi 10795 done 10796 done 10797 IFS=$as_save_IFS 10798 10799 fi 10800 fi 10801 BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP 10802 if test -n "$BDEPS_UNZIP"; then 10803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5 10804 $as_echo "$BDEPS_UNZIP" >&6; } 10805 else 10806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10807 $as_echo "no" >&6; } 10808 fi 10809 10810 10811 test -n "$BDEPS_UNZIP" && break 10812 done 10813 10814 if test "x$BDEPS_UNZIP" = x7z; then 10815 BDEPS_UNZIP="7z x" 10816 fi 10817 10818 for ac_prog in wget lftp ftp 10819 do 10820 # Extract the first word of "$ac_prog", so it can be a program name with args. 10821 set dummy $ac_prog; ac_word=$2 10822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10823 $as_echo_n "checking for $ac_word... " >&6; } 10824 if ${ac_cv_prog_BDEPS_FTP+:} false; then : 10825 $as_echo_n "(cached) " >&6 10826 else 10827 if test -n "$BDEPS_FTP"; then 10828 ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test. 10829 else 10830 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10831 for as_dir in $PATH 10832 do 10833 IFS=$as_save_IFS 10834 test -z "$as_dir" && as_dir=. 10835 for ac_exec_ext in '' $ac_executable_extensions; do 10836 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 10837 ac_cv_prog_BDEPS_FTP="$ac_prog" 10838 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10839 break 2 10840 fi 10841 done 10842 done 10843 IFS=$as_save_IFS 10844 10845 fi 10846 fi 10847 BDEPS_FTP=$ac_cv_prog_BDEPS_FTP 10848 if test -n "$BDEPS_FTP"; then 10849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5 10850 $as_echo "$BDEPS_FTP" >&6; } 10851 else 10852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10853 $as_echo "no" >&6; } 10854 fi 10855 10856 10857 test -n "$BDEPS_FTP" && break 10858 done 10859 10860 10861 10862 ############################################################################### 10863 # 10864 # Determine OpenJDK variants, options and version numbers. 10865 # 10866 ############################################################################### 10867 10868 # We need build & target for this. 10869 10870 10871 ############################################################################### 10872 # 10873 # Should we build a JDK/JVM with headful support (ie a graphical ui)? 10874 # We always build headless support. 10875 # 10876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5 10877 $as_echo_n "checking headful support... " >&6; } 10878 # Check whether --enable-headful was given. 10879 if test "${enable_headful+set}" = set; then : 10880 enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful} 10881 else 10882 SUPPORT_HEADFUL=yes 10883 fi 10884 10885 10886 SUPPORT_HEADLESS=yes 10887 BUILD_HEADLESS="BUILD_HEADLESS:=true" 10888 10889 if test "x$SUPPORT_HEADFUL" = xyes; then 10890 # We are building both headful and headless. 10891 headful_msg="inlude support for both headful and headless" 10892 fi 10893 10894 if test "x$SUPPORT_HEADFUL" = xno; then 10895 # Thus we are building headless only. 10896 BUILD_HEADLESS="BUILD_HEADLESS:=true" 10897 headful_msg="headless only" 10898 fi 10899 10900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5 10901 $as_echo "$headful_msg" >&6; } 10902 10903 10904 10905 10906 10907 # Control wether Hotspot runs Queens test after build. 10908 # Check whether --enable-hotspot-test-in-build was given. 10909 if test "${enable_hotspot_test_in_build+set}" = set; then : 10910 enableval=$enable_hotspot_test_in_build; 10911 else 10912 enable_hotspot_test_in_build=no 10913 fi 10914 10915 if test "x$enable_hotspot_test_in_build" = "xyes"; then 10916 TEST_IN_BUILD=true 10917 else 10918 TEST_IN_BUILD=false 10919 fi 10920 10921 10922 ############################################################################### 10923 # 10924 # Choose cacerts source file 10925 # 10926 10927 # Check whether --with-cacerts-file was given. 10928 if test "${with_cacerts_file+set}" = set; then : 10929 withval=$with_cacerts_file; 10930 fi 10931 10932 if test "x$with_cacerts_file" != x; then 10933 CACERTS_FILE=$with_cacerts_file 10934 else 10935 CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts 10936 fi 10937 10938 10939 ############################################################################### 10940 # 10941 # Enable or disable unlimited crypto 10942 # 10943 # Check whether --enable-unlimited-crypto was given. 10944 if test "${enable_unlimited_crypto+set}" = set; then : 10945 enableval=$enable_unlimited_crypto; 10946 else 10947 enable_unlimited_crypto=no 10948 fi 10949 10950 if test "x$enable_unlimited_crypto" = "xyes"; then 10951 UNLIMITED_CRYPTO=true 10952 else 10953 UNLIMITED_CRYPTO=false 10954 fi 10955 10956 10957 ############################################################################### 10958 # 10959 # Enable or disable the elliptic curve crypto implementation 10960 # 10961 10962 10963 ############################################################################### 10964 # 10965 # Compress jars 10966 # 10967 COMPRESS_JARS=false 10968 10969 10970 10971 10972 # Source the version numbers 10973 . $AUTOCONF_DIR/version-numbers 10974 10975 # Get the settings from parameters 10976 10977 # Check whether --with-milestone was given. 10978 if test "${with_milestone+set}" = set; then : 10979 withval=$with_milestone; 10980 fi 10981 10982 if test "x$with_milestone" = xyes; then 10983 as_fn_error $? "Milestone must have a value" "$LINENO" 5 10984 elif test "x$with_milestone" != x; then 10985 MILESTONE="$with_milestone" 10986 fi 10987 if test "x$MILESTONE" = x; then 10988 MILESTONE=internal 10989 fi 10990 10991 10992 # Check whether --with-update-version was given. 10993 if test "${with_update_version+set}" = set; then : 10994 withval=$with_update_version; 10995 fi 10996 10997 if test "x$with_update_version" = xyes; then 10998 as_fn_error $? "Update version must have a value" "$LINENO" 5 10999 elif test "x$with_update_version" != x; then 11000 JDK_UPDATE_VERSION="$with_update_version" 11001 fi 11002 11003 11004 # Check whether --with-build-number was given. 11005 if test "${with_build_number+set}" = set; then : 11006 withval=$with_build_number; 11007 fi 11008 11009 if test "x$with_build_number" = xyes; then 11010 as_fn_error $? "Build number must have a value" "$LINENO" 5 11011 elif test "x$with_build_number" != x; then 11012 JDK_BUILD_NUMBER="$with_build_number" 11013 fi 11014 if test "x$JDK_BUILD_NUMBER" = x; then 11015 JDK_BUILD_NUMBER=b00 11016 fi 11017 11018 11019 # Check whether --with-user-release-suffix was given. 11020 if test "${with_user_release_suffix+set}" = set; then : 11021 withval=$with_user_release_suffix; 11022 fi 11023 11024 if test "x$with_user_release_suffix" = xyes; then 11025 as_fn_error $? "Release suffix must have a value" "$LINENO" 5 11026 elif test "x$with_user_release_suffix" != x; then 11027 USER_RELEASE_SUFFIX="$with_user_release_suffix" 11028 else 11029 BUILD_DATE=`date '+%Y_%m_%d_%H_%M'` 11030 # Avoid [:alnum:] since it depends on the locale. 11031 CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyz0123456789'` 11032 USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11033 fi 11034 11035 11036 # Now set the JDK version, milestone, build number etc. 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 COPYRIGHT_YEAR=`date +'%Y'` 11052 11053 11054 if test "x$JDK_UPDATE_VERSION" != x; then 11055 JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}" 11056 else 11057 JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}" 11058 fi 11059 11060 11061 COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'` 11062 11063 11064 11065 ############################################################################### 11066 # 11067 # Setup BootJDK, used to bootstrap the build. 11068 # 11069 ############################################################################### 11070 11071 11072 BOOT_JDK_FOUND=no 11073 11074 # Check whether --with-boot-jdk was given. 11075 if test "${with_boot_jdk+set}" = set; then : 11076 withval=$with_boot_jdk; 11077 fi 11078 11079 11080 # We look for the Boot JDK through various means, going from more certain to 11081 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 11082 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 11083 # must check if this is indeed valid; otherwise we'll continue looking. 11084 11085 # Test: Is bootjdk explicitely set by command line arguments? 11086 11087 if test "x$BOOT_JDK_FOUND" = xno; then 11088 # Now execute the test 11089 11090 if test "x$with_boot_jdk" != x; then 11091 BOOT_JDK=$with_boot_jdk 11092 BOOT_JDK_FOUND=maybe 11093 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 11094 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 11095 fi 11096 11097 11098 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 11099 if test "x$BOOT_JDK_FOUND" = xmaybe; then 11100 # Do we have a bin/java? 11101 if test ! -x "$BOOT_JDK/bin/java"; then 11102 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 11103 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 11104 BOOT_JDK_FOUND=no 11105 else 11106 # Do we have a bin/javac? 11107 if test ! -x "$BOOT_JDK/bin/javac"; then 11108 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 11109 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 11110 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 11111 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 11112 BOOT_JDK_FOUND=no 11113 else 11114 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 11115 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 11116 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 11117 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 11118 BOOT_JDK_FOUND=no 11119 else 11120 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 11121 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 11122 11123 # Extra M4 quote needed to protect [] in grep expression. 11124 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 11125 if test "x$FOUND_VERSION_78" = x; then 11126 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 11127 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 11128 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 11129 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 11130 BOOT_JDK_FOUND=no 11131 else 11132 # We're done! :-) 11133 BOOT_JDK_FOUND=yes 11134 11135 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11136 11137 # Input might be given as Windows format, start by converting to 11138 # unix format. 11139 path="$BOOT_JDK" 11140 new_path=`$CYGPATH -u "$path"` 11141 11142 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11143 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11144 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11145 # "foo.exe" is OK but "foo" is an error. 11146 # 11147 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11148 # It is also a way to make sure we got the proper file name for the real test later on. 11149 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11150 if test "x$test_shortpath" = x; then 11151 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11152 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11153 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 11154 fi 11155 11156 # Call helper function which possibly converts this using DOS-style short mode. 11157 # If so, the updated path is stored in $new_path. 11158 11159 input_path="$new_path" 11160 # Check if we need to convert this using DOS-style short mode. If the path 11161 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11162 # take no chances and rewrite it. 11163 # Note: m4 eats our [], so we need to use [ and ] instead. 11164 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 11165 if test "x$has_forbidden_chars" != x; then 11166 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11167 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 11168 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 11169 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 11170 # Going to short mode and back again did indeed matter. Since short mode is 11171 # case insensitive, let's make it lowercase to improve readability. 11172 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11173 # Now convert it back to Unix-stile (cygpath) 11174 input_path=`$CYGPATH -u "$shortmode_path"` 11175 new_path="$input_path" 11176 fi 11177 fi 11178 11179 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 11180 if test "x$test_cygdrive_prefix" = x; then 11181 # As a simple fix, exclude /usr/bin since it's not a real path. 11182 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 11183 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 11184 # a path prefixed by /cygdrive for fixpath to work. 11185 new_path="$CYGWIN_ROOT_PATH$input_path" 11186 fi 11187 fi 11188 11189 11190 if test "x$path" != "x$new_path"; then 11191 BOOT_JDK="$new_path" 11192 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11193 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11194 fi 11195 11196 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11197 11198 path="$BOOT_JDK" 11199 has_colon=`$ECHO $path | $GREP ^.:` 11200 new_path="$path" 11201 if test "x$has_colon" = x; then 11202 # Not in mixed or Windows style, start by that. 11203 new_path=`cmd //c echo $path` 11204 fi 11205 11206 11207 input_path="$new_path" 11208 # Check if we need to convert this using DOS-style short mode. If the path 11209 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11210 # take no chances and rewrite it. 11211 # Note: m4 eats our [], so we need to use [ and ] instead. 11212 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 11213 if test "x$has_forbidden_chars" != x; then 11214 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11215 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11216 fi 11217 11218 11219 windows_path="$new_path" 11220 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11221 unix_path=`$CYGPATH -u "$windows_path"` 11222 new_path="$unix_path" 11223 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11224 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 11225 new_path="$unix_path" 11226 fi 11227 11228 if test "x$path" != "x$new_path"; then 11229 BOOT_JDK="$new_path" 11230 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11231 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11232 fi 11233 11234 # Save the first 10 bytes of this path to the storage, so fixpath can work. 11235 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 11236 11237 else 11238 # We're on a posix platform. Hooray! :) 11239 path="$BOOT_JDK" 11240 has_space=`$ECHO "$path" | $GREP " "` 11241 if test "x$has_space" != x; then 11242 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11243 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11244 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 11245 fi 11246 11247 # Use eval to expand a potential ~ 11248 eval path="$path" 11249 if test ! -f "$path" && test ! -d "$path"; then 11250 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 11251 fi 11252 11253 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 11254 fi 11255 11256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 11257 $as_echo_n "checking for Boot JDK... " >&6; } 11258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 11259 $as_echo "$BOOT_JDK" >&6; } 11260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 11261 $as_echo_n "checking Boot JDK version... " >&6; } 11262 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 11263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 11264 $as_echo "$BOOT_JDK_VERSION" >&6; } 11265 fi # end check jdk version 11266 fi # end check rt.jar 11267 fi # end check javac 11268 fi # end check java 11269 fi # end check boot jdk found 11270 fi 11271 11272 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 11273 # Having specified an argument which is incorrect will produce an instant failure; 11274 # we should not go on looking 11275 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 11276 fi 11277 11278 # Test: Is bootjdk available from builddeps? 11279 11280 if test "x$BOOT_JDK_FOUND" = xno; then 11281 # Now execute the test 11282 11283 11284 11285 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 11286 # Source the builddeps file again, to make sure it uses the latest variables! 11287 . $builddepsfile 11288 # Look for a target and build machine specific resource! 11289 eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 11290 if test "x$resource" = x; then 11291 # Ok, lets instead look for a target specific resource 11292 eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}} 11293 fi 11294 if test "x$resource" = x; then 11295 # Ok, lets instead look for a build specific resource 11296 eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}} 11297 fi 11298 if test "x$resource" = x; then 11299 # Ok, lets instead look for a generic resource 11300 # (The bootjdk comes from M4 and not the shell, thus no need for eval here.) 11301 resource=${builddep_bootjdk} 11302 fi 11303 if test "x$resource" != x; then 11304 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5 11305 $as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;} 11306 # If the resource in the builddeps.conf file is an existing directory, 11307 # for example /java/linux/cups 11308 if test -d ${resource}; then 11309 depdir=${resource} 11310 else 11311 11312 # bootjdk is for example mymodule 11313 # $resource is for example libs/general/libmymod_1_2_3.zip 11314 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 11315 # $with_builddeps_dir is for example /localhome/builddeps 11316 # depdir is the name of the variable into which we store the depdir, eg MYMOD 11317 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 11318 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 11319 filename=`basename $resource` 11320 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 11321 filebase=${filename%%.*} 11322 extension=${filename#*.} 11323 installdir=$with_builddeps_dir/$filebase 11324 if test ! -f $installdir/$filename.unpacked; then 11325 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5 11326 $as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;} 11327 if test ! -d $installdir; then 11328 mkdir -p $installdir 11329 fi 11330 if test ! -d $installdir; then 11331 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 11332 fi 11333 tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX` 11334 touch $tmpfile 11335 if test ! -f $tmpfile; then 11336 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 11337 fi 11338 11339 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 11340 # $tmpfile is the local file name for the downloaded file. 11341 VALID_TOOL=no 11342 if test "x$BDEPS_FTP" = xwget; then 11343 VALID_TOOL=yes 11344 wget -O $tmpfile $with_builddeps_server/$resource 11345 fi 11346 if test "x$BDEPS_FTP" = xlftp; then 11347 VALID_TOOL=yes 11348 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 11349 fi 11350 if test "x$BDEPS_FTP" = xftp; then 11351 VALID_TOOL=yes 11352 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 11353 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 11354 FTPUSERPWD=${FTPSERVER%%@*} 11355 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 11356 FTPUSER=${userpwd%%:*} 11357 FTPPWD=${userpwd#*@} 11358 FTPSERVER=${FTPSERVER#*@} 11359 else 11360 FTPUSER=ftp 11361 FTPPWD=ftp 11362 fi 11363 # the "pass" command does not work on some 11364 # ftp clients (read ftp.exe) but if it works, 11365 # passive mode is better! 11366 (\ 11367 echo "user $FTPUSER $FTPPWD" ;\ 11368 echo "pass" ;\ 11369 echo "bin" ;\ 11370 echo "get $FTPPATH $tmpfile" ;\ 11371 ) | ftp -in $FTPSERVER 11372 fi 11373 if test "x$VALID_TOOL" != xyes; then 11374 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 11375 fi 11376 11377 mv $tmpfile $installdir/$filename 11378 if test ! -s $installdir/$filename; then 11379 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 11380 fi 11381 case "$extension" in 11382 zip) echo "Unzipping $installdir/$filename..." 11383 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 11384 ;; 11385 tar.gz) echo "Untaring $installdir/$filename..." 11386 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 11387 ;; 11388 tgz) echo "Untaring $installdir/$filename..." 11389 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 11390 ;; 11391 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 11392 ;; 11393 esac 11394 fi 11395 if test -f $installdir/$filename.unpacked; then 11396 depdir=$installdir 11397 fi 11398 11399 fi 11400 # Source the builddeps file again, because in the previous command, the depdir 11401 # was updated to point at the current build dependency install directory. 11402 . $builddepsfile 11403 # Now extract variables from the builddeps.conf files. 11404 theroot=${builddep_bootjdk_ROOT} 11405 thecflags=${builddep_bootjdk_CFLAGS} 11406 thelibs=${builddep_bootjdk_LIBS} 11407 if test "x$depdir" = x; then 11408 as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5 11409 fi 11410 BOOT_JDK=$depdir 11411 if test "x$theroot" != x; then 11412 BOOT_JDK="$theroot" 11413 fi 11414 if test "x$thecflags" != x; then 11415 BOOT_JDK_CFLAGS="$thecflags" 11416 fi 11417 if test "x$thelibs" != x; then 11418 BOOT_JDK_LIBS="$thelibs" 11419 fi 11420 BOOT_JDK_FOUND=maybe 11421 else BOOT_JDK_FOUND=no 11422 11423 fi 11424 else BOOT_JDK_FOUND=no 11425 11426 fi 11427 11428 11429 11430 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 11431 if test "x$BOOT_JDK_FOUND" = xmaybe; then 11432 # Do we have a bin/java? 11433 if test ! -x "$BOOT_JDK/bin/java"; then 11434 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 11435 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 11436 BOOT_JDK_FOUND=no 11437 else 11438 # Do we have a bin/javac? 11439 if test ! -x "$BOOT_JDK/bin/javac"; then 11440 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 11441 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 11442 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 11443 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 11444 BOOT_JDK_FOUND=no 11445 else 11446 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 11447 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 11448 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 11449 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 11450 BOOT_JDK_FOUND=no 11451 else 11452 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 11453 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 11454 11455 # Extra M4 quote needed to protect [] in grep expression. 11456 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 11457 if test "x$FOUND_VERSION_78" = x; then 11458 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 11459 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 11460 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 11461 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 11462 BOOT_JDK_FOUND=no 11463 else 11464 # We're done! :-) 11465 BOOT_JDK_FOUND=yes 11466 11467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11468 11469 # Input might be given as Windows format, start by converting to 11470 # unix format. 11471 path="$BOOT_JDK" 11472 new_path=`$CYGPATH -u "$path"` 11473 11474 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11475 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11476 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11477 # "foo.exe" is OK but "foo" is an error. 11478 # 11479 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11480 # It is also a way to make sure we got the proper file name for the real test later on. 11481 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11482 if test "x$test_shortpath" = x; then 11483 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11484 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11485 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 11486 fi 11487 11488 # Call helper function which possibly converts this using DOS-style short mode. 11489 # If so, the updated path is stored in $new_path. 11490 11491 input_path="$new_path" 11492 # Check if we need to convert this using DOS-style short mode. If the path 11493 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11494 # take no chances and rewrite it. 11495 # Note: m4 eats our [], so we need to use [ and ] instead. 11496 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 11497 if test "x$has_forbidden_chars" != x; then 11498 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11499 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 11500 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 11501 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 11502 # Going to short mode and back again did indeed matter. Since short mode is 11503 # case insensitive, let's make it lowercase to improve readability. 11504 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11505 # Now convert it back to Unix-stile (cygpath) 11506 input_path=`$CYGPATH -u "$shortmode_path"` 11507 new_path="$input_path" 11508 fi 11509 fi 11510 11511 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 11512 if test "x$test_cygdrive_prefix" = x; then 11513 # As a simple fix, exclude /usr/bin since it's not a real path. 11514 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 11515 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 11516 # a path prefixed by /cygdrive for fixpath to work. 11517 new_path="$CYGWIN_ROOT_PATH$input_path" 11518 fi 11519 fi 11520 11521 11522 if test "x$path" != "x$new_path"; then 11523 BOOT_JDK="$new_path" 11524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11525 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11526 fi 11527 11528 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11529 11530 path="$BOOT_JDK" 11531 has_colon=`$ECHO $path | $GREP ^.:` 11532 new_path="$path" 11533 if test "x$has_colon" = x; then 11534 # Not in mixed or Windows style, start by that. 11535 new_path=`cmd //c echo $path` 11536 fi 11537 11538 11539 input_path="$new_path" 11540 # Check if we need to convert this using DOS-style short mode. If the path 11541 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11542 # take no chances and rewrite it. 11543 # Note: m4 eats our [], so we need to use [ and ] instead. 11544 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 11545 if test "x$has_forbidden_chars" != x; then 11546 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11547 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11548 fi 11549 11550 11551 windows_path="$new_path" 11552 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11553 unix_path=`$CYGPATH -u "$windows_path"` 11554 new_path="$unix_path" 11555 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11556 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 11557 new_path="$unix_path" 11558 fi 11559 11560 if test "x$path" != "x$new_path"; then 11561 BOOT_JDK="$new_path" 11562 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11563 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11564 fi 11565 11566 # Save the first 10 bytes of this path to the storage, so fixpath can work. 11567 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 11568 11569 else 11570 # We're on a posix platform. Hooray! :) 11571 path="$BOOT_JDK" 11572 has_space=`$ECHO "$path" | $GREP " "` 11573 if test "x$has_space" != x; then 11574 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11575 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11576 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 11577 fi 11578 11579 # Use eval to expand a potential ~ 11580 eval path="$path" 11581 if test ! -f "$path" && test ! -d "$path"; then 11582 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 11583 fi 11584 11585 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 11586 fi 11587 11588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 11589 $as_echo_n "checking for Boot JDK... " >&6; } 11590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 11591 $as_echo "$BOOT_JDK" >&6; } 11592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 11593 $as_echo_n "checking Boot JDK version... " >&6; } 11594 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 11595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 11596 $as_echo "$BOOT_JDK_VERSION" >&6; } 11597 fi # end check jdk version 11598 fi # end check rt.jar 11599 fi # end check javac 11600 fi # end check java 11601 fi # end check boot jdk found 11602 fi 11603 11604 11605 # Test: Is $JAVA_HOME set? 11606 11607 if test "x$BOOT_JDK_FOUND" = xno; then 11608 # Now execute the test 11609 11610 if test "x$JAVA_HOME" != x; then 11611 JAVA_HOME_PROCESSED="$JAVA_HOME" 11612 11613 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11614 11615 # Input might be given as Windows format, start by converting to 11616 # unix format. 11617 path="$JAVA_HOME_PROCESSED" 11618 new_path=`$CYGPATH -u "$path"` 11619 11620 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11621 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11622 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11623 # "foo.exe" is OK but "foo" is an error. 11624 # 11625 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11626 # It is also a way to make sure we got the proper file name for the real test later on. 11627 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11628 if test "x$test_shortpath" = x; then 11629 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 11630 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 11631 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 11632 fi 11633 11634 # Call helper function which possibly converts this using DOS-style short mode. 11635 # If so, the updated path is stored in $new_path. 11636 11637 input_path="$new_path" 11638 # Check if we need to convert this using DOS-style short mode. If the path 11639 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11640 # take no chances and rewrite it. 11641 # Note: m4 eats our [], so we need to use [ and ] instead. 11642 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 11643 if test "x$has_forbidden_chars" != x; then 11644 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11645 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 11646 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 11647 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 11648 # Going to short mode and back again did indeed matter. Since short mode is 11649 # case insensitive, let's make it lowercase to improve readability. 11650 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11651 # Now convert it back to Unix-stile (cygpath) 11652 input_path=`$CYGPATH -u "$shortmode_path"` 11653 new_path="$input_path" 11654 fi 11655 fi 11656 11657 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 11658 if test "x$test_cygdrive_prefix" = x; then 11659 # As a simple fix, exclude /usr/bin since it's not a real path. 11660 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 11661 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 11662 # a path prefixed by /cygdrive for fixpath to work. 11663 new_path="$CYGWIN_ROOT_PATH$input_path" 11664 fi 11665 fi 11666 11667 11668 if test "x$path" != "x$new_path"; then 11669 JAVA_HOME_PROCESSED="$new_path" 11670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 11671 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 11672 fi 11673 11674 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11675 11676 path="$JAVA_HOME_PROCESSED" 11677 has_colon=`$ECHO $path | $GREP ^.:` 11678 new_path="$path" 11679 if test "x$has_colon" = x; then 11680 # Not in mixed or Windows style, start by that. 11681 new_path=`cmd //c echo $path` 11682 fi 11683 11684 11685 input_path="$new_path" 11686 # Check if we need to convert this using DOS-style short mode. If the path 11687 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11688 # take no chances and rewrite it. 11689 # Note: m4 eats our [], so we need to use [ and ] instead. 11690 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 11691 if test "x$has_forbidden_chars" != x; then 11692 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11693 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11694 fi 11695 11696 11697 windows_path="$new_path" 11698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11699 unix_path=`$CYGPATH -u "$windows_path"` 11700 new_path="$unix_path" 11701 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11702 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 11703 new_path="$unix_path" 11704 fi 11705 11706 if test "x$path" != "x$new_path"; then 11707 JAVA_HOME_PROCESSED="$new_path" 11708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 11709 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 11710 fi 11711 11712 # Save the first 10 bytes of this path to the storage, so fixpath can work. 11713 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 11714 11715 else 11716 # We're on a posix platform. Hooray! :) 11717 path="$JAVA_HOME_PROCESSED" 11718 has_space=`$ECHO "$path" | $GREP " "` 11719 if test "x$has_space" != x; then 11720 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 11721 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 11722 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 11723 fi 11724 11725 # Use eval to expand a potential ~ 11726 eval path="$path" 11727 if test ! -f "$path" && test ! -d "$path"; then 11728 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 11729 fi 11730 11731 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 11732 fi 11733 11734 if test ! -d "$JAVA_HOME_PROCESSED"; then 11735 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 11736 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 11737 else 11738 # Aha, the user has set a JAVA_HOME 11739 # let us use that as the Boot JDK. 11740 BOOT_JDK="$JAVA_HOME_PROCESSED" 11741 BOOT_JDK_FOUND=maybe 11742 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 11743 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 11744 fi 11745 fi 11746 11747 11748 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 11749 if test "x$BOOT_JDK_FOUND" = xmaybe; then 11750 # Do we have a bin/java? 11751 if test ! -x "$BOOT_JDK/bin/java"; then 11752 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 11753 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 11754 BOOT_JDK_FOUND=no 11755 else 11756 # Do we have a bin/javac? 11757 if test ! -x "$BOOT_JDK/bin/javac"; then 11758 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 11759 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 11760 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 11761 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 11762 BOOT_JDK_FOUND=no 11763 else 11764 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 11765 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 11766 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 11767 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 11768 BOOT_JDK_FOUND=no 11769 else 11770 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 11771 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 11772 11773 # Extra M4 quote needed to protect [] in grep expression. 11774 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 11775 if test "x$FOUND_VERSION_78" = x; then 11776 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 11777 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 11778 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 11779 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 11780 BOOT_JDK_FOUND=no 11781 else 11782 # We're done! :-) 11783 BOOT_JDK_FOUND=yes 11784 11785 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11786 11787 # Input might be given as Windows format, start by converting to 11788 # unix format. 11789 path="$BOOT_JDK" 11790 new_path=`$CYGPATH -u "$path"` 11791 11792 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11793 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11794 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11795 # "foo.exe" is OK but "foo" is an error. 11796 # 11797 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11798 # It is also a way to make sure we got the proper file name for the real test later on. 11799 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11800 if test "x$test_shortpath" = x; then 11801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11802 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11803 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 11804 fi 11805 11806 # Call helper function which possibly converts this using DOS-style short mode. 11807 # If so, the updated path is stored in $new_path. 11808 11809 input_path="$new_path" 11810 # Check if we need to convert this using DOS-style short mode. If the path 11811 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11812 # take no chances and rewrite it. 11813 # Note: m4 eats our [], so we need to use [ and ] instead. 11814 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 11815 if test "x$has_forbidden_chars" != x; then 11816 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11817 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 11818 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 11819 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 11820 # Going to short mode and back again did indeed matter. Since short mode is 11821 # case insensitive, let's make it lowercase to improve readability. 11822 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11823 # Now convert it back to Unix-stile (cygpath) 11824 input_path=`$CYGPATH -u "$shortmode_path"` 11825 new_path="$input_path" 11826 fi 11827 fi 11828 11829 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 11830 if test "x$test_cygdrive_prefix" = x; then 11831 # As a simple fix, exclude /usr/bin since it's not a real path. 11832 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 11833 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 11834 # a path prefixed by /cygdrive for fixpath to work. 11835 new_path="$CYGWIN_ROOT_PATH$input_path" 11836 fi 11837 fi 11838 11839 11840 if test "x$path" != "x$new_path"; then 11841 BOOT_JDK="$new_path" 11842 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11843 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11844 fi 11845 11846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11847 11848 path="$BOOT_JDK" 11849 has_colon=`$ECHO $path | $GREP ^.:` 11850 new_path="$path" 11851 if test "x$has_colon" = x; then 11852 # Not in mixed or Windows style, start by that. 11853 new_path=`cmd //c echo $path` 11854 fi 11855 11856 11857 input_path="$new_path" 11858 # Check if we need to convert this using DOS-style short mode. If the path 11859 # contains just simple characters, use it. Otherwise (spaces, weird characters), 11860 # take no chances and rewrite it. 11861 # Note: m4 eats our [], so we need to use [ and ] instead. 11862 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 11863 if test "x$has_forbidden_chars" != x; then 11864 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 11865 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 11866 fi 11867 11868 11869 windows_path="$new_path" 11870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11871 unix_path=`$CYGPATH -u "$windows_path"` 11872 new_path="$unix_path" 11873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 11874 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 11875 new_path="$unix_path" 11876 fi 11877 11878 if test "x$path" != "x$new_path"; then 11879 BOOT_JDK="$new_path" 11880 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 11881 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 11882 fi 11883 11884 # Save the first 10 bytes of this path to the storage, so fixpath can work. 11885 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 11886 11887 else 11888 # We're on a posix platform. Hooray! :) 11889 path="$BOOT_JDK" 11890 has_space=`$ECHO "$path" | $GREP " "` 11891 if test "x$has_space" != x; then 11892 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11893 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11894 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 11895 fi 11896 11897 # Use eval to expand a potential ~ 11898 eval path="$path" 11899 if test ! -f "$path" && test ! -d "$path"; then 11900 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 11901 fi 11902 11903 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 11904 fi 11905 11906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 11907 $as_echo_n "checking for Boot JDK... " >&6; } 11908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 11909 $as_echo "$BOOT_JDK" >&6; } 11910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 11911 $as_echo_n "checking Boot JDK version... " >&6; } 11912 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 11913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 11914 $as_echo "$BOOT_JDK_VERSION" >&6; } 11915 fi # end check jdk version 11916 fi # end check rt.jar 11917 fi # end check javac 11918 fi # end check java 11919 fi # end check boot jdk found 11920 fi 11921 11922 11923 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 11924 11925 if test "x$BOOT_JDK_FOUND" = xno; then 11926 # Now execute the test 11927 11928 if test -x /usr/libexec/java_home; then 11929 BOOT_JDK=`/usr/libexec/java_home` 11930 BOOT_JDK_FOUND=maybe 11931 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home" >&5 11932 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home" >&6;} 11933 fi 11934 11935 11936 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 11937 if test "x$BOOT_JDK_FOUND" = xmaybe; then 11938 # Do we have a bin/java? 11939 if test ! -x "$BOOT_JDK/bin/java"; then 11940 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 11941 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 11942 BOOT_JDK_FOUND=no 11943 else 11944 # Do we have a bin/javac? 11945 if test ! -x "$BOOT_JDK/bin/javac"; then 11946 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 11947 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 11948 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 11949 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 11950 BOOT_JDK_FOUND=no 11951 else 11952 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 11953 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 11954 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 11955 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 11956 BOOT_JDK_FOUND=no 11957 else 11958 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 11959 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 11960 11961 # Extra M4 quote needed to protect [] in grep expression. 11962 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 11963 if test "x$FOUND_VERSION_78" = x; then 11964 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 11965 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 11966 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 11967 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 11968 BOOT_JDK_FOUND=no 11969 else 11970 # We're done! :-) 11971 BOOT_JDK_FOUND=yes 11972 11973 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 11974 11975 # Input might be given as Windows format, start by converting to 11976 # unix format. 11977 path="$BOOT_JDK" 11978 new_path=`$CYGPATH -u "$path"` 11979 11980 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 11981 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 11982 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 11983 # "foo.exe" is OK but "foo" is an error. 11984 # 11985 # This test is therefore slightly more accurate than "test -f" to check for file precense. 11986 # It is also a way to make sure we got the proper file name for the real test later on. 11987 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 11988 if test "x$test_shortpath" = x; then 11989 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 11990 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 11991 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 11992 fi 11993 11994 # Call helper function which possibly converts this using DOS-style short mode. 11995 # If so, the updated path is stored in $new_path. 11996 11997 input_path="$new_path" 11998 # Check if we need to convert this using DOS-style short mode. If the path 11999 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12000 # take no chances and rewrite it. 12001 # Note: m4 eats our [], so we need to use [ and ] instead. 12002 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12003 if test "x$has_forbidden_chars" != x; then 12004 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12005 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12006 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12007 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12008 # Going to short mode and back again did indeed matter. Since short mode is 12009 # case insensitive, let's make it lowercase to improve readability. 12010 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12011 # Now convert it back to Unix-stile (cygpath) 12012 input_path=`$CYGPATH -u "$shortmode_path"` 12013 new_path="$input_path" 12014 fi 12015 fi 12016 12017 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12018 if test "x$test_cygdrive_prefix" = x; then 12019 # As a simple fix, exclude /usr/bin since it's not a real path. 12020 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12021 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12022 # a path prefixed by /cygdrive for fixpath to work. 12023 new_path="$CYGWIN_ROOT_PATH$input_path" 12024 fi 12025 fi 12026 12027 12028 if test "x$path" != "x$new_path"; then 12029 BOOT_JDK="$new_path" 12030 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12031 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12032 fi 12033 12034 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12035 12036 path="$BOOT_JDK" 12037 has_colon=`$ECHO $path | $GREP ^.:` 12038 new_path="$path" 12039 if test "x$has_colon" = x; then 12040 # Not in mixed or Windows style, start by that. 12041 new_path=`cmd //c echo $path` 12042 fi 12043 12044 12045 input_path="$new_path" 12046 # Check if we need to convert this using DOS-style short mode. If the path 12047 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12048 # take no chances and rewrite it. 12049 # Note: m4 eats our [], so we need to use [ and ] instead. 12050 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12051 if test "x$has_forbidden_chars" != x; then 12052 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12053 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12054 fi 12055 12056 12057 windows_path="$new_path" 12058 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12059 unix_path=`$CYGPATH -u "$windows_path"` 12060 new_path="$unix_path" 12061 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12062 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12063 new_path="$unix_path" 12064 fi 12065 12066 if test "x$path" != "x$new_path"; then 12067 BOOT_JDK="$new_path" 12068 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12069 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12070 fi 12071 12072 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12073 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12074 12075 else 12076 # We're on a posix platform. Hooray! :) 12077 path="$BOOT_JDK" 12078 has_space=`$ECHO "$path" | $GREP " "` 12079 if test "x$has_space" != x; then 12080 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12081 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12082 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12083 fi 12084 12085 # Use eval to expand a potential ~ 12086 eval path="$path" 12087 if test ! -f "$path" && test ! -d "$path"; then 12088 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12089 fi 12090 12091 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 12092 fi 12093 12094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12095 $as_echo_n "checking for Boot JDK... " >&6; } 12096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12097 $as_echo "$BOOT_JDK" >&6; } 12098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12099 $as_echo_n "checking Boot JDK version... " >&6; } 12100 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12102 $as_echo "$BOOT_JDK_VERSION" >&6; } 12103 fi # end check jdk version 12104 fi # end check rt.jar 12105 fi # end check javac 12106 fi # end check java 12107 fi # end check boot jdk found 12108 fi 12109 12110 12111 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 12112 12113 if test "x$BOOT_JDK_FOUND" = xno; then 12114 # Now execute the test 12115 12116 # Extract the first word of "javac", so it can be a program name with args. 12117 set dummy javac; ac_word=$2 12118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12119 $as_echo_n "checking for $ac_word... " >&6; } 12120 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 12121 $as_echo_n "(cached) " >&6 12122 else 12123 case $JAVAC_CHECK in 12124 [\\/]* | ?:[\\/]*) 12125 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 12126 ;; 12127 *) 12128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12129 for as_dir in $PATH 12130 do 12131 IFS=$as_save_IFS 12132 test -z "$as_dir" && as_dir=. 12133 for ac_exec_ext in '' $ac_executable_extensions; do 12134 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 12135 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 12136 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12137 break 2 12138 fi 12139 done 12140 done 12141 IFS=$as_save_IFS 12142 12143 ;; 12144 esac 12145 fi 12146 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 12147 if test -n "$JAVAC_CHECK"; then 12148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 12149 $as_echo "$JAVAC_CHECK" >&6; } 12150 else 12151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12152 $as_echo "no" >&6; } 12153 fi 12154 12155 12156 # Extract the first word of "java", so it can be a program name with args. 12157 set dummy java; ac_word=$2 12158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12159 $as_echo_n "checking for $ac_word... " >&6; } 12160 if ${ac_cv_path_JAVA_CHECK+:} false; then : 12161 $as_echo_n "(cached) " >&6 12162 else 12163 case $JAVA_CHECK in 12164 [\\/]* | ?:[\\/]*) 12165 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 12166 ;; 12167 *) 12168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12169 for as_dir in $PATH 12170 do 12171 IFS=$as_save_IFS 12172 test -z "$as_dir" && as_dir=. 12173 for ac_exec_ext in '' $ac_executable_extensions; do 12174 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 12175 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 12176 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12177 break 2 12178 fi 12179 done 12180 done 12181 IFS=$as_save_IFS 12182 12183 ;; 12184 esac 12185 fi 12186 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 12187 if test -n "$JAVA_CHECK"; then 12188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 12189 $as_echo "$JAVA_CHECK" >&6; } 12190 else 12191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12192 $as_echo "no" >&6; } 12193 fi 12194 12195 12196 BINARY="$JAVAC_CHECK" 12197 if test "x$JAVAC_CHECK" = x; then 12198 BINARY="$JAVA_CHECK" 12199 fi 12200 if test "x$BINARY" != x; then 12201 # So there is a java(c) binary, it might be part of a JDK. 12202 # Lets find the JDK/JRE directory by following symbolic links. 12203 # Linux/GNU systems often have links from /usr/bin/java to 12204 # /etc/alternatives/java to the real JDK binary. 12205 12206 if test "x$OPENJDK_BUILD_OS" != xwindows; then 12207 # Follow a chain of symbolic links. Use readlink 12208 # where it exists, else fall back to horribly 12209 # complicated shell code. 12210 if test "x$READLINK_TESTED" != yes; then 12211 # On MacOSX there is a readlink tool with a different 12212 # purpose than the GNU readlink tool. Check the found readlink. 12213 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 12214 if test "x$ISGNU" = x; then 12215 # A readlink that we do not know how to use. 12216 # Are there other non-GNU readlinks out there? 12217 READLINK_TESTED=yes 12218 READLINK= 12219 fi 12220 fi 12221 12222 if test "x$READLINK" != x; then 12223 BINARY=`$READLINK -f $BINARY` 12224 else 12225 # Save the current directory for restoring afterwards 12226 STARTDIR=$PWD 12227 COUNTER=0 12228 sym_link_dir=`$DIRNAME $BINARY` 12229 sym_link_file=`$BASENAME $BINARY` 12230 cd $sym_link_dir 12231 # Use -P flag to resolve symlinks in directories. 12232 cd `$THEPWDCMD -P` 12233 sym_link_dir=`$THEPWDCMD -P` 12234 # Resolve file symlinks 12235 while test $COUNTER -lt 20; do 12236 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 12237 if test "x$ISLINK" == x; then 12238 # This is not a symbolic link! We are done! 12239 break 12240 fi 12241 # Again resolve directory symlinks since the target of the just found 12242 # link could be in a different directory 12243 cd `$DIRNAME $ISLINK` 12244 sym_link_dir=`$THEPWDCMD -P` 12245 sym_link_file=`$BASENAME $ISLINK` 12246 let COUNTER=COUNTER+1 12247 done 12248 cd $STARTDIR 12249 BINARY=$sym_link_dir/$sym_link_file 12250 fi 12251 fi 12252 12253 BOOT_JDK=`dirname "$BINARY"` 12254 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 12255 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 12256 # Looks like we found ourselves an JDK 12257 BOOT_JDK_FOUND=maybe 12258 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 12259 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 12260 fi 12261 fi 12262 12263 12264 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12265 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12266 # Do we have a bin/java? 12267 if test ! -x "$BOOT_JDK/bin/java"; then 12268 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12269 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12270 BOOT_JDK_FOUND=no 12271 else 12272 # Do we have a bin/javac? 12273 if test ! -x "$BOOT_JDK/bin/javac"; then 12274 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12275 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12276 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12277 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12278 BOOT_JDK_FOUND=no 12279 else 12280 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12281 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12282 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12283 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12284 BOOT_JDK_FOUND=no 12285 else 12286 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12287 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12288 12289 # Extra M4 quote needed to protect [] in grep expression. 12290 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12291 if test "x$FOUND_VERSION_78" = x; then 12292 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12293 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12294 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12295 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12296 BOOT_JDK_FOUND=no 12297 else 12298 # We're done! :-) 12299 BOOT_JDK_FOUND=yes 12300 12301 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12302 12303 # Input might be given as Windows format, start by converting to 12304 # unix format. 12305 path="$BOOT_JDK" 12306 new_path=`$CYGPATH -u "$path"` 12307 12308 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12309 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12310 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12311 # "foo.exe" is OK but "foo" is an error. 12312 # 12313 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12314 # It is also a way to make sure we got the proper file name for the real test later on. 12315 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12316 if test "x$test_shortpath" = x; then 12317 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12318 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12319 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12320 fi 12321 12322 # Call helper function which possibly converts this using DOS-style short mode. 12323 # If so, the updated path is stored in $new_path. 12324 12325 input_path="$new_path" 12326 # Check if we need to convert this using DOS-style short mode. If the path 12327 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12328 # take no chances and rewrite it. 12329 # Note: m4 eats our [], so we need to use [ and ] instead. 12330 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12331 if test "x$has_forbidden_chars" != x; then 12332 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12333 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12334 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12335 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12336 # Going to short mode and back again did indeed matter. Since short mode is 12337 # case insensitive, let's make it lowercase to improve readability. 12338 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12339 # Now convert it back to Unix-stile (cygpath) 12340 input_path=`$CYGPATH -u "$shortmode_path"` 12341 new_path="$input_path" 12342 fi 12343 fi 12344 12345 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12346 if test "x$test_cygdrive_prefix" = x; then 12347 # As a simple fix, exclude /usr/bin since it's not a real path. 12348 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12349 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12350 # a path prefixed by /cygdrive for fixpath to work. 12351 new_path="$CYGWIN_ROOT_PATH$input_path" 12352 fi 12353 fi 12354 12355 12356 if test "x$path" != "x$new_path"; then 12357 BOOT_JDK="$new_path" 12358 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12359 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12360 fi 12361 12362 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12363 12364 path="$BOOT_JDK" 12365 has_colon=`$ECHO $path | $GREP ^.:` 12366 new_path="$path" 12367 if test "x$has_colon" = x; then 12368 # Not in mixed or Windows style, start by that. 12369 new_path=`cmd //c echo $path` 12370 fi 12371 12372 12373 input_path="$new_path" 12374 # Check if we need to convert this using DOS-style short mode. If the path 12375 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12376 # take no chances and rewrite it. 12377 # Note: m4 eats our [], so we need to use [ and ] instead. 12378 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12379 if test "x$has_forbidden_chars" != x; then 12380 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12381 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12382 fi 12383 12384 12385 windows_path="$new_path" 12386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12387 unix_path=`$CYGPATH -u "$windows_path"` 12388 new_path="$unix_path" 12389 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12390 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12391 new_path="$unix_path" 12392 fi 12393 12394 if test "x$path" != "x$new_path"; then 12395 BOOT_JDK="$new_path" 12396 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12397 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12398 fi 12399 12400 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12401 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12402 12403 else 12404 # We're on a posix platform. Hooray! :) 12405 path="$BOOT_JDK" 12406 has_space=`$ECHO "$path" | $GREP " "` 12407 if test "x$has_space" != x; then 12408 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12409 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12410 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12411 fi 12412 12413 # Use eval to expand a potential ~ 12414 eval path="$path" 12415 if test ! -f "$path" && test ! -d "$path"; then 12416 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12417 fi 12418 12419 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 12420 fi 12421 12422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12423 $as_echo_n "checking for Boot JDK... " >&6; } 12424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12425 $as_echo "$BOOT_JDK" >&6; } 12426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12427 $as_echo_n "checking Boot JDK version... " >&6; } 12428 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12430 $as_echo "$BOOT_JDK_VERSION" >&6; } 12431 fi # end check jdk version 12432 fi # end check rt.jar 12433 fi # end check javac 12434 fi # end check java 12435 fi # end check boot jdk found 12436 fi 12437 12438 12439 # Test: Is there a JDK installed in default, well-known locations? 12440 12441 if test "x$BOOT_JDK_FOUND" = xno; then 12442 # Now execute the test 12443 12444 if test "x$OPENJDK_TARGET_OS" = xwindows; then 12445 12446 if test "x$BOOT_JDK_FOUND" = xno; then 12447 # Now execute the test 12448 12449 if test "x$ProgramW6432" != x; then 12450 VIRTUAL_DIR="$ProgramW6432/Java" 12451 12452 windows_path="$VIRTUAL_DIR" 12453 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12454 unix_path=`$CYGPATH -u "$windows_path"` 12455 VIRTUAL_DIR="$unix_path" 12456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12457 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12458 VIRTUAL_DIR="$unix_path" 12459 fi 12460 12461 12462 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 12463 BOOT_JDK_SUFFIX="" 12464 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 12465 if test "x$ALL_JDKS_FOUND" != x; then 12466 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 12467 12468 if test "x$BOOT_JDK_FOUND" = xno; then 12469 # Now execute the test 12470 12471 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 12472 if test -d "$BOOT_JDK"; then 12473 BOOT_JDK_FOUND=maybe 12474 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 12475 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 12476 fi 12477 12478 12479 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12480 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12481 # Do we have a bin/java? 12482 if test ! -x "$BOOT_JDK/bin/java"; then 12483 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12484 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12485 BOOT_JDK_FOUND=no 12486 else 12487 # Do we have a bin/javac? 12488 if test ! -x "$BOOT_JDK/bin/javac"; then 12489 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12490 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12491 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12492 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12493 BOOT_JDK_FOUND=no 12494 else 12495 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12496 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12497 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12498 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12499 BOOT_JDK_FOUND=no 12500 else 12501 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12502 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12503 12504 # Extra M4 quote needed to protect [] in grep expression. 12505 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12506 if test "x$FOUND_VERSION_78" = x; then 12507 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12508 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12509 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12510 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12511 BOOT_JDK_FOUND=no 12512 else 12513 # We're done! :-) 12514 BOOT_JDK_FOUND=yes 12515 12516 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12517 12518 # Input might be given as Windows format, start by converting to 12519 # unix format. 12520 path="$BOOT_JDK" 12521 new_path=`$CYGPATH -u "$path"` 12522 12523 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12524 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12525 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12526 # "foo.exe" is OK but "foo" is an error. 12527 # 12528 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12529 # It is also a way to make sure we got the proper file name for the real test later on. 12530 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12531 if test "x$test_shortpath" = x; then 12532 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12533 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12534 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12535 fi 12536 12537 # Call helper function which possibly converts this using DOS-style short mode. 12538 # If so, the updated path is stored in $new_path. 12539 12540 input_path="$new_path" 12541 # Check if we need to convert this using DOS-style short mode. If the path 12542 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12543 # take no chances and rewrite it. 12544 # Note: m4 eats our [], so we need to use [ and ] instead. 12545 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12546 if test "x$has_forbidden_chars" != x; then 12547 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12548 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12549 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12550 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12551 # Going to short mode and back again did indeed matter. Since short mode is 12552 # case insensitive, let's make it lowercase to improve readability. 12553 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12554 # Now convert it back to Unix-stile (cygpath) 12555 input_path=`$CYGPATH -u "$shortmode_path"` 12556 new_path="$input_path" 12557 fi 12558 fi 12559 12560 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12561 if test "x$test_cygdrive_prefix" = x; then 12562 # As a simple fix, exclude /usr/bin since it's not a real path. 12563 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12564 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12565 # a path prefixed by /cygdrive for fixpath to work. 12566 new_path="$CYGWIN_ROOT_PATH$input_path" 12567 fi 12568 fi 12569 12570 12571 if test "x$path" != "x$new_path"; then 12572 BOOT_JDK="$new_path" 12573 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12574 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12575 fi 12576 12577 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12578 12579 path="$BOOT_JDK" 12580 has_colon=`$ECHO $path | $GREP ^.:` 12581 new_path="$path" 12582 if test "x$has_colon" = x; then 12583 # Not in mixed or Windows style, start by that. 12584 new_path=`cmd //c echo $path` 12585 fi 12586 12587 12588 input_path="$new_path" 12589 # Check if we need to convert this using DOS-style short mode. If the path 12590 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12591 # take no chances and rewrite it. 12592 # Note: m4 eats our [], so we need to use [ and ] instead. 12593 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12594 if test "x$has_forbidden_chars" != x; then 12595 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12596 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12597 fi 12598 12599 12600 windows_path="$new_path" 12601 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12602 unix_path=`$CYGPATH -u "$windows_path"` 12603 new_path="$unix_path" 12604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12605 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12606 new_path="$unix_path" 12607 fi 12608 12609 if test "x$path" != "x$new_path"; then 12610 BOOT_JDK="$new_path" 12611 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12612 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12613 fi 12614 12615 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12616 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12617 12618 else 12619 # We're on a posix platform. Hooray! :) 12620 path="$BOOT_JDK" 12621 has_space=`$ECHO "$path" | $GREP " "` 12622 if test "x$has_space" != x; then 12623 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12624 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12625 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12626 fi 12627 12628 # Use eval to expand a potential ~ 12629 eval path="$path" 12630 if test ! -f "$path" && test ! -d "$path"; then 12631 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12632 fi 12633 12634 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 12635 fi 12636 12637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12638 $as_echo_n "checking for Boot JDK... " >&6; } 12639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12640 $as_echo "$BOOT_JDK" >&6; } 12641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12642 $as_echo_n "checking Boot JDK version... " >&6; } 12643 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12645 $as_echo "$BOOT_JDK_VERSION" >&6; } 12646 fi # end check jdk version 12647 fi # end check rt.jar 12648 fi # end check javac 12649 fi # end check java 12650 fi # end check boot jdk found 12651 fi 12652 12653 done 12654 fi 12655 12656 fi 12657 12658 12659 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12660 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12661 # Do we have a bin/java? 12662 if test ! -x "$BOOT_JDK/bin/java"; then 12663 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12664 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12665 BOOT_JDK_FOUND=no 12666 else 12667 # Do we have a bin/javac? 12668 if test ! -x "$BOOT_JDK/bin/javac"; then 12669 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12670 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12671 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12672 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12673 BOOT_JDK_FOUND=no 12674 else 12675 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12676 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12677 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12678 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12679 BOOT_JDK_FOUND=no 12680 else 12681 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12682 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12683 12684 # Extra M4 quote needed to protect [] in grep expression. 12685 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12686 if test "x$FOUND_VERSION_78" = x; then 12687 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12688 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12689 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12690 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12691 BOOT_JDK_FOUND=no 12692 else 12693 # We're done! :-) 12694 BOOT_JDK_FOUND=yes 12695 12696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12697 12698 # Input might be given as Windows format, start by converting to 12699 # unix format. 12700 path="$BOOT_JDK" 12701 new_path=`$CYGPATH -u "$path"` 12702 12703 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12704 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12705 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12706 # "foo.exe" is OK but "foo" is an error. 12707 # 12708 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12709 # It is also a way to make sure we got the proper file name for the real test later on. 12710 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12711 if test "x$test_shortpath" = x; then 12712 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12713 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12714 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12715 fi 12716 12717 # Call helper function which possibly converts this using DOS-style short mode. 12718 # If so, the updated path is stored in $new_path. 12719 12720 input_path="$new_path" 12721 # Check if we need to convert this using DOS-style short mode. If the path 12722 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12723 # take no chances and rewrite it. 12724 # Note: m4 eats our [], so we need to use [ and ] instead. 12725 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12726 if test "x$has_forbidden_chars" != x; then 12727 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12728 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12729 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12730 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12731 # Going to short mode and back again did indeed matter. Since short mode is 12732 # case insensitive, let's make it lowercase to improve readability. 12733 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12734 # Now convert it back to Unix-stile (cygpath) 12735 input_path=`$CYGPATH -u "$shortmode_path"` 12736 new_path="$input_path" 12737 fi 12738 fi 12739 12740 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12741 if test "x$test_cygdrive_prefix" = x; then 12742 # As a simple fix, exclude /usr/bin since it's not a real path. 12743 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12744 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12745 # a path prefixed by /cygdrive for fixpath to work. 12746 new_path="$CYGWIN_ROOT_PATH$input_path" 12747 fi 12748 fi 12749 12750 12751 if test "x$path" != "x$new_path"; then 12752 BOOT_JDK="$new_path" 12753 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12754 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12755 fi 12756 12757 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12758 12759 path="$BOOT_JDK" 12760 has_colon=`$ECHO $path | $GREP ^.:` 12761 new_path="$path" 12762 if test "x$has_colon" = x; then 12763 # Not in mixed or Windows style, start by that. 12764 new_path=`cmd //c echo $path` 12765 fi 12766 12767 12768 input_path="$new_path" 12769 # Check if we need to convert this using DOS-style short mode. If the path 12770 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12771 # take no chances and rewrite it. 12772 # Note: m4 eats our [], so we need to use [ and ] instead. 12773 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12774 if test "x$has_forbidden_chars" != x; then 12775 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12776 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12777 fi 12778 12779 12780 windows_path="$new_path" 12781 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12782 unix_path=`$CYGPATH -u "$windows_path"` 12783 new_path="$unix_path" 12784 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12785 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12786 new_path="$unix_path" 12787 fi 12788 12789 if test "x$path" != "x$new_path"; then 12790 BOOT_JDK="$new_path" 12791 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12792 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12793 fi 12794 12795 # Save the first 10 bytes of this path to the storage, so fixpath can work. 12796 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 12797 12798 else 12799 # We're on a posix platform. Hooray! :) 12800 path="$BOOT_JDK" 12801 has_space=`$ECHO "$path" | $GREP " "` 12802 if test "x$has_space" != x; then 12803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12804 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12805 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 12806 fi 12807 12808 # Use eval to expand a potential ~ 12809 eval path="$path" 12810 if test ! -f "$path" && test ! -d "$path"; then 12811 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 12812 fi 12813 12814 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 12815 fi 12816 12817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 12818 $as_echo_n "checking for Boot JDK... " >&6; } 12819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 12820 $as_echo "$BOOT_JDK" >&6; } 12821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 12822 $as_echo_n "checking Boot JDK version... " >&6; } 12823 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 12824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 12825 $as_echo "$BOOT_JDK_VERSION" >&6; } 12826 fi # end check jdk version 12827 fi # end check rt.jar 12828 fi # end check javac 12829 fi # end check java 12830 fi # end check boot jdk found 12831 fi 12832 12833 12834 if test "x$BOOT_JDK_FOUND" = xno; then 12835 # Now execute the test 12836 12837 if test "x$PROGRAMW6432" != x; then 12838 VIRTUAL_DIR="$PROGRAMW6432/Java" 12839 12840 windows_path="$VIRTUAL_DIR" 12841 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12842 unix_path=`$CYGPATH -u "$windows_path"` 12843 VIRTUAL_DIR="$unix_path" 12844 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12845 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12846 VIRTUAL_DIR="$unix_path" 12847 fi 12848 12849 12850 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 12851 BOOT_JDK_SUFFIX="" 12852 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 12853 if test "x$ALL_JDKS_FOUND" != x; then 12854 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 12855 12856 if test "x$BOOT_JDK_FOUND" = xno; then 12857 # Now execute the test 12858 12859 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 12860 if test -d "$BOOT_JDK"; then 12861 BOOT_JDK_FOUND=maybe 12862 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 12863 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 12864 fi 12865 12866 12867 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 12868 if test "x$BOOT_JDK_FOUND" = xmaybe; then 12869 # Do we have a bin/java? 12870 if test ! -x "$BOOT_JDK/bin/java"; then 12871 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 12872 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 12873 BOOT_JDK_FOUND=no 12874 else 12875 # Do we have a bin/javac? 12876 if test ! -x "$BOOT_JDK/bin/javac"; then 12877 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 12878 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 12879 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 12880 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 12881 BOOT_JDK_FOUND=no 12882 else 12883 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 12884 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 12885 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 12886 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 12887 BOOT_JDK_FOUND=no 12888 else 12889 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 12890 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 12891 12892 # Extra M4 quote needed to protect [] in grep expression. 12893 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 12894 if test "x$FOUND_VERSION_78" = x; then 12895 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 12896 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 12897 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 12898 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 12899 BOOT_JDK_FOUND=no 12900 else 12901 # We're done! :-) 12902 BOOT_JDK_FOUND=yes 12903 12904 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12905 12906 # Input might be given as Windows format, start by converting to 12907 # unix format. 12908 path="$BOOT_JDK" 12909 new_path=`$CYGPATH -u "$path"` 12910 12911 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 12912 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 12913 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 12914 # "foo.exe" is OK but "foo" is an error. 12915 # 12916 # This test is therefore slightly more accurate than "test -f" to check for file precense. 12917 # It is also a way to make sure we got the proper file name for the real test later on. 12918 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 12919 if test "x$test_shortpath" = x; then 12920 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 12921 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 12922 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 12923 fi 12924 12925 # Call helper function which possibly converts this using DOS-style short mode. 12926 # If so, the updated path is stored in $new_path. 12927 12928 input_path="$new_path" 12929 # Check if we need to convert this using DOS-style short mode. If the path 12930 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12931 # take no chances and rewrite it. 12932 # Note: m4 eats our [], so we need to use [ and ] instead. 12933 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 12934 if test "x$has_forbidden_chars" != x; then 12935 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12936 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 12937 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 12938 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 12939 # Going to short mode and back again did indeed matter. Since short mode is 12940 # case insensitive, let's make it lowercase to improve readability. 12941 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12942 # Now convert it back to Unix-stile (cygpath) 12943 input_path=`$CYGPATH -u "$shortmode_path"` 12944 new_path="$input_path" 12945 fi 12946 fi 12947 12948 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 12949 if test "x$test_cygdrive_prefix" = x; then 12950 # As a simple fix, exclude /usr/bin since it's not a real path. 12951 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 12952 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 12953 # a path prefixed by /cygdrive for fixpath to work. 12954 new_path="$CYGWIN_ROOT_PATH$input_path" 12955 fi 12956 fi 12957 12958 12959 if test "x$path" != "x$new_path"; then 12960 BOOT_JDK="$new_path" 12961 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 12962 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 12963 fi 12964 12965 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12966 12967 path="$BOOT_JDK" 12968 has_colon=`$ECHO $path | $GREP ^.:` 12969 new_path="$path" 12970 if test "x$has_colon" = x; then 12971 # Not in mixed or Windows style, start by that. 12972 new_path=`cmd //c echo $path` 12973 fi 12974 12975 12976 input_path="$new_path" 12977 # Check if we need to convert this using DOS-style short mode. If the path 12978 # contains just simple characters, use it. Otherwise (spaces, weird characters), 12979 # take no chances and rewrite it. 12980 # Note: m4 eats our [], so we need to use [ and ] instead. 12981 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 12982 if test "x$has_forbidden_chars" != x; then 12983 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 12984 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 12985 fi 12986 12987 12988 windows_path="$new_path" 12989 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 12990 unix_path=`$CYGPATH -u "$windows_path"` 12991 new_path="$unix_path" 12992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 12993 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 12994 new_path="$unix_path" 12995 fi 12996 12997 if test "x$path" != "x$new_path"; then 12998 BOOT_JDK="$new_path" 12999 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13000 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13001 fi 13002 13003 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13004 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13005 13006 else 13007 # We're on a posix platform. Hooray! :) 13008 path="$BOOT_JDK" 13009 has_space=`$ECHO "$path" | $GREP " "` 13010 if test "x$has_space" != x; then 13011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13012 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13013 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13014 fi 13015 13016 # Use eval to expand a potential ~ 13017 eval path="$path" 13018 if test ! -f "$path" && test ! -d "$path"; then 13019 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13020 fi 13021 13022 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13023 fi 13024 13025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13026 $as_echo_n "checking for Boot JDK... " >&6; } 13027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13028 $as_echo "$BOOT_JDK" >&6; } 13029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13030 $as_echo_n "checking Boot JDK version... " >&6; } 13031 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13033 $as_echo "$BOOT_JDK_VERSION" >&6; } 13034 fi # end check jdk version 13035 fi # end check rt.jar 13036 fi # end check javac 13037 fi # end check java 13038 fi # end check boot jdk found 13039 fi 13040 13041 done 13042 fi 13043 13044 fi 13045 13046 13047 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13048 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13049 # Do we have a bin/java? 13050 if test ! -x "$BOOT_JDK/bin/java"; then 13051 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13052 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13053 BOOT_JDK_FOUND=no 13054 else 13055 # Do we have a bin/javac? 13056 if test ! -x "$BOOT_JDK/bin/javac"; then 13057 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13058 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13059 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13060 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13061 BOOT_JDK_FOUND=no 13062 else 13063 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13064 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13065 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13066 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13067 BOOT_JDK_FOUND=no 13068 else 13069 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13070 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13071 13072 # Extra M4 quote needed to protect [] in grep expression. 13073 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13074 if test "x$FOUND_VERSION_78" = x; then 13075 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13076 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13077 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13078 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13079 BOOT_JDK_FOUND=no 13080 else 13081 # We're done! :-) 13082 BOOT_JDK_FOUND=yes 13083 13084 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13085 13086 # Input might be given as Windows format, start by converting to 13087 # unix format. 13088 path="$BOOT_JDK" 13089 new_path=`$CYGPATH -u "$path"` 13090 13091 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13092 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13093 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13094 # "foo.exe" is OK but "foo" is an error. 13095 # 13096 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13097 # It is also a way to make sure we got the proper file name for the real test later on. 13098 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13099 if test "x$test_shortpath" = x; then 13100 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13101 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13102 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13103 fi 13104 13105 # Call helper function which possibly converts this using DOS-style short mode. 13106 # If so, the updated path is stored in $new_path. 13107 13108 input_path="$new_path" 13109 # Check if we need to convert this using DOS-style short mode. If the path 13110 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13111 # take no chances and rewrite it. 13112 # Note: m4 eats our [], so we need to use [ and ] instead. 13113 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13114 if test "x$has_forbidden_chars" != x; then 13115 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13116 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13117 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13118 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13119 # Going to short mode and back again did indeed matter. Since short mode is 13120 # case insensitive, let's make it lowercase to improve readability. 13121 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13122 # Now convert it back to Unix-stile (cygpath) 13123 input_path=`$CYGPATH -u "$shortmode_path"` 13124 new_path="$input_path" 13125 fi 13126 fi 13127 13128 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13129 if test "x$test_cygdrive_prefix" = x; then 13130 # As a simple fix, exclude /usr/bin since it's not a real path. 13131 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13132 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13133 # a path prefixed by /cygdrive for fixpath to work. 13134 new_path="$CYGWIN_ROOT_PATH$input_path" 13135 fi 13136 fi 13137 13138 13139 if test "x$path" != "x$new_path"; then 13140 BOOT_JDK="$new_path" 13141 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13142 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13143 fi 13144 13145 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13146 13147 path="$BOOT_JDK" 13148 has_colon=`$ECHO $path | $GREP ^.:` 13149 new_path="$path" 13150 if test "x$has_colon" = x; then 13151 # Not in mixed or Windows style, start by that. 13152 new_path=`cmd //c echo $path` 13153 fi 13154 13155 13156 input_path="$new_path" 13157 # Check if we need to convert this using DOS-style short mode. If the path 13158 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13159 # take no chances and rewrite it. 13160 # Note: m4 eats our [], so we need to use [ and ] instead. 13161 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13162 if test "x$has_forbidden_chars" != x; then 13163 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13164 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13165 fi 13166 13167 13168 windows_path="$new_path" 13169 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13170 unix_path=`$CYGPATH -u "$windows_path"` 13171 new_path="$unix_path" 13172 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13173 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13174 new_path="$unix_path" 13175 fi 13176 13177 if test "x$path" != "x$new_path"; then 13178 BOOT_JDK="$new_path" 13179 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13180 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13181 fi 13182 13183 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13184 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13185 13186 else 13187 # We're on a posix platform. Hooray! :) 13188 path="$BOOT_JDK" 13189 has_space=`$ECHO "$path" | $GREP " "` 13190 if test "x$has_space" != x; then 13191 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13192 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13193 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13194 fi 13195 13196 # Use eval to expand a potential ~ 13197 eval path="$path" 13198 if test ! -f "$path" && test ! -d "$path"; then 13199 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13200 fi 13201 13202 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13203 fi 13204 13205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13206 $as_echo_n "checking for Boot JDK... " >&6; } 13207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13208 $as_echo "$BOOT_JDK" >&6; } 13209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13210 $as_echo_n "checking Boot JDK version... " >&6; } 13211 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13213 $as_echo "$BOOT_JDK_VERSION" >&6; } 13214 fi # end check jdk version 13215 fi # end check rt.jar 13216 fi # end check javac 13217 fi # end check java 13218 fi # end check boot jdk found 13219 fi 13220 13221 13222 if test "x$BOOT_JDK_FOUND" = xno; then 13223 # Now execute the test 13224 13225 if test "x$PROGRAMFILES" != x; then 13226 VIRTUAL_DIR="$PROGRAMFILES/Java" 13227 13228 windows_path="$VIRTUAL_DIR" 13229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13230 unix_path=`$CYGPATH -u "$windows_path"` 13231 VIRTUAL_DIR="$unix_path" 13232 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13233 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13234 VIRTUAL_DIR="$unix_path" 13235 fi 13236 13237 13238 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 13239 BOOT_JDK_SUFFIX="" 13240 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 13241 if test "x$ALL_JDKS_FOUND" != x; then 13242 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 13243 13244 if test "x$BOOT_JDK_FOUND" = xno; then 13245 # Now execute the test 13246 13247 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 13248 if test -d "$BOOT_JDK"; then 13249 BOOT_JDK_FOUND=maybe 13250 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 13251 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 13252 fi 13253 13254 13255 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13256 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13257 # Do we have a bin/java? 13258 if test ! -x "$BOOT_JDK/bin/java"; then 13259 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13260 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13261 BOOT_JDK_FOUND=no 13262 else 13263 # Do we have a bin/javac? 13264 if test ! -x "$BOOT_JDK/bin/javac"; then 13265 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13266 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13267 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13268 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13269 BOOT_JDK_FOUND=no 13270 else 13271 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13272 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13273 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13274 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13275 BOOT_JDK_FOUND=no 13276 else 13277 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13278 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13279 13280 # Extra M4 quote needed to protect [] in grep expression. 13281 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13282 if test "x$FOUND_VERSION_78" = x; then 13283 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13284 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13285 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13286 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13287 BOOT_JDK_FOUND=no 13288 else 13289 # We're done! :-) 13290 BOOT_JDK_FOUND=yes 13291 13292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13293 13294 # Input might be given as Windows format, start by converting to 13295 # unix format. 13296 path="$BOOT_JDK" 13297 new_path=`$CYGPATH -u "$path"` 13298 13299 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13300 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13301 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13302 # "foo.exe" is OK but "foo" is an error. 13303 # 13304 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13305 # It is also a way to make sure we got the proper file name for the real test later on. 13306 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13307 if test "x$test_shortpath" = x; then 13308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13309 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13310 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13311 fi 13312 13313 # Call helper function which possibly converts this using DOS-style short mode. 13314 # If so, the updated path is stored in $new_path. 13315 13316 input_path="$new_path" 13317 # Check if we need to convert this using DOS-style short mode. If the path 13318 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13319 # take no chances and rewrite it. 13320 # Note: m4 eats our [], so we need to use [ and ] instead. 13321 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13322 if test "x$has_forbidden_chars" != x; then 13323 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13324 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13325 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13326 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13327 # Going to short mode and back again did indeed matter. Since short mode is 13328 # case insensitive, let's make it lowercase to improve readability. 13329 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13330 # Now convert it back to Unix-stile (cygpath) 13331 input_path=`$CYGPATH -u "$shortmode_path"` 13332 new_path="$input_path" 13333 fi 13334 fi 13335 13336 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13337 if test "x$test_cygdrive_prefix" = x; then 13338 # As a simple fix, exclude /usr/bin since it's not a real path. 13339 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13340 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13341 # a path prefixed by /cygdrive for fixpath to work. 13342 new_path="$CYGWIN_ROOT_PATH$input_path" 13343 fi 13344 fi 13345 13346 13347 if test "x$path" != "x$new_path"; then 13348 BOOT_JDK="$new_path" 13349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13350 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13351 fi 13352 13353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13354 13355 path="$BOOT_JDK" 13356 has_colon=`$ECHO $path | $GREP ^.:` 13357 new_path="$path" 13358 if test "x$has_colon" = x; then 13359 # Not in mixed or Windows style, start by that. 13360 new_path=`cmd //c echo $path` 13361 fi 13362 13363 13364 input_path="$new_path" 13365 # Check if we need to convert this using DOS-style short mode. If the path 13366 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13367 # take no chances and rewrite it. 13368 # Note: m4 eats our [], so we need to use [ and ] instead. 13369 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13370 if test "x$has_forbidden_chars" != x; then 13371 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13372 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13373 fi 13374 13375 13376 windows_path="$new_path" 13377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13378 unix_path=`$CYGPATH -u "$windows_path"` 13379 new_path="$unix_path" 13380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13381 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13382 new_path="$unix_path" 13383 fi 13384 13385 if test "x$path" != "x$new_path"; then 13386 BOOT_JDK="$new_path" 13387 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13388 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13389 fi 13390 13391 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13392 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13393 13394 else 13395 # We're on a posix platform. Hooray! :) 13396 path="$BOOT_JDK" 13397 has_space=`$ECHO "$path" | $GREP " "` 13398 if test "x$has_space" != x; then 13399 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13400 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13401 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13402 fi 13403 13404 # Use eval to expand a potential ~ 13405 eval path="$path" 13406 if test ! -f "$path" && test ! -d "$path"; then 13407 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13408 fi 13409 13410 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13411 fi 13412 13413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13414 $as_echo_n "checking for Boot JDK... " >&6; } 13415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13416 $as_echo "$BOOT_JDK" >&6; } 13417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13418 $as_echo_n "checking Boot JDK version... " >&6; } 13419 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13421 $as_echo "$BOOT_JDK_VERSION" >&6; } 13422 fi # end check jdk version 13423 fi # end check rt.jar 13424 fi # end check javac 13425 fi # end check java 13426 fi # end check boot jdk found 13427 fi 13428 13429 done 13430 fi 13431 13432 fi 13433 13434 13435 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13436 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13437 # Do we have a bin/java? 13438 if test ! -x "$BOOT_JDK/bin/java"; then 13439 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13440 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13441 BOOT_JDK_FOUND=no 13442 else 13443 # Do we have a bin/javac? 13444 if test ! -x "$BOOT_JDK/bin/javac"; then 13445 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13446 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13447 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13448 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13449 BOOT_JDK_FOUND=no 13450 else 13451 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13452 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13453 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13454 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13455 BOOT_JDK_FOUND=no 13456 else 13457 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13458 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13459 13460 # Extra M4 quote needed to protect [] in grep expression. 13461 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13462 if test "x$FOUND_VERSION_78" = x; then 13463 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13464 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13465 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13466 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13467 BOOT_JDK_FOUND=no 13468 else 13469 # We're done! :-) 13470 BOOT_JDK_FOUND=yes 13471 13472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13473 13474 # Input might be given as Windows format, start by converting to 13475 # unix format. 13476 path="$BOOT_JDK" 13477 new_path=`$CYGPATH -u "$path"` 13478 13479 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13480 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13481 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13482 # "foo.exe" is OK but "foo" is an error. 13483 # 13484 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13485 # It is also a way to make sure we got the proper file name for the real test later on. 13486 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13487 if test "x$test_shortpath" = x; then 13488 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13489 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13490 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13491 fi 13492 13493 # Call helper function which possibly converts this using DOS-style short mode. 13494 # If so, the updated path is stored in $new_path. 13495 13496 input_path="$new_path" 13497 # Check if we need to convert this using DOS-style short mode. If the path 13498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13499 # take no chances and rewrite it. 13500 # Note: m4 eats our [], so we need to use [ and ] instead. 13501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13502 if test "x$has_forbidden_chars" != x; then 13503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13504 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13505 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13506 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13507 # Going to short mode and back again did indeed matter. Since short mode is 13508 # case insensitive, let's make it lowercase to improve readability. 13509 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13510 # Now convert it back to Unix-stile (cygpath) 13511 input_path=`$CYGPATH -u "$shortmode_path"` 13512 new_path="$input_path" 13513 fi 13514 fi 13515 13516 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13517 if test "x$test_cygdrive_prefix" = x; then 13518 # As a simple fix, exclude /usr/bin since it's not a real path. 13519 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13520 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13521 # a path prefixed by /cygdrive for fixpath to work. 13522 new_path="$CYGWIN_ROOT_PATH$input_path" 13523 fi 13524 fi 13525 13526 13527 if test "x$path" != "x$new_path"; then 13528 BOOT_JDK="$new_path" 13529 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13530 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13531 fi 13532 13533 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13534 13535 path="$BOOT_JDK" 13536 has_colon=`$ECHO $path | $GREP ^.:` 13537 new_path="$path" 13538 if test "x$has_colon" = x; then 13539 # Not in mixed or Windows style, start by that. 13540 new_path=`cmd //c echo $path` 13541 fi 13542 13543 13544 input_path="$new_path" 13545 # Check if we need to convert this using DOS-style short mode. If the path 13546 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13547 # take no chances and rewrite it. 13548 # Note: m4 eats our [], so we need to use [ and ] instead. 13549 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13550 if test "x$has_forbidden_chars" != x; then 13551 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13552 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13553 fi 13554 13555 13556 windows_path="$new_path" 13557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13558 unix_path=`$CYGPATH -u "$windows_path"` 13559 new_path="$unix_path" 13560 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13561 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13562 new_path="$unix_path" 13563 fi 13564 13565 if test "x$path" != "x$new_path"; then 13566 BOOT_JDK="$new_path" 13567 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13568 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13569 fi 13570 13571 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13572 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13573 13574 else 13575 # We're on a posix platform. Hooray! :) 13576 path="$BOOT_JDK" 13577 has_space=`$ECHO "$path" | $GREP " "` 13578 if test "x$has_space" != x; then 13579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13580 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13581 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13582 fi 13583 13584 # Use eval to expand a potential ~ 13585 eval path="$path" 13586 if test ! -f "$path" && test ! -d "$path"; then 13587 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13588 fi 13589 13590 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13591 fi 13592 13593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13594 $as_echo_n "checking for Boot JDK... " >&6; } 13595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13596 $as_echo "$BOOT_JDK" >&6; } 13597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13598 $as_echo_n "checking Boot JDK version... " >&6; } 13599 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13601 $as_echo "$BOOT_JDK_VERSION" >&6; } 13602 fi # end check jdk version 13603 fi # end check rt.jar 13604 fi # end check javac 13605 fi # end check java 13606 fi # end check boot jdk found 13607 fi 13608 13609 13610 if test "x$BOOT_JDK_FOUND" = xno; then 13611 # Now execute the test 13612 13613 if test "x$ProgramFiles" != x; then 13614 VIRTUAL_DIR="$ProgramFiles/Java" 13615 13616 windows_path="$VIRTUAL_DIR" 13617 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13618 unix_path=`$CYGPATH -u "$windows_path"` 13619 VIRTUAL_DIR="$unix_path" 13620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13621 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13622 VIRTUAL_DIR="$unix_path" 13623 fi 13624 13625 13626 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 13627 BOOT_JDK_SUFFIX="" 13628 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 13629 if test "x$ALL_JDKS_FOUND" != x; then 13630 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 13631 13632 if test "x$BOOT_JDK_FOUND" = xno; then 13633 # Now execute the test 13634 13635 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 13636 if test -d "$BOOT_JDK"; then 13637 BOOT_JDK_FOUND=maybe 13638 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 13639 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 13640 fi 13641 13642 13643 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13644 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13645 # Do we have a bin/java? 13646 if test ! -x "$BOOT_JDK/bin/java"; then 13647 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13648 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13649 BOOT_JDK_FOUND=no 13650 else 13651 # Do we have a bin/javac? 13652 if test ! -x "$BOOT_JDK/bin/javac"; then 13653 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13654 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13655 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13656 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13657 BOOT_JDK_FOUND=no 13658 else 13659 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13660 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13661 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13662 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13663 BOOT_JDK_FOUND=no 13664 else 13665 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13666 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13667 13668 # Extra M4 quote needed to protect [] in grep expression. 13669 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13670 if test "x$FOUND_VERSION_78" = x; then 13671 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13672 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13673 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13674 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13675 BOOT_JDK_FOUND=no 13676 else 13677 # We're done! :-) 13678 BOOT_JDK_FOUND=yes 13679 13680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13681 13682 # Input might be given as Windows format, start by converting to 13683 # unix format. 13684 path="$BOOT_JDK" 13685 new_path=`$CYGPATH -u "$path"` 13686 13687 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13688 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13689 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13690 # "foo.exe" is OK but "foo" is an error. 13691 # 13692 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13693 # It is also a way to make sure we got the proper file name for the real test later on. 13694 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13695 if test "x$test_shortpath" = x; then 13696 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13697 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13698 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13699 fi 13700 13701 # Call helper function which possibly converts this using DOS-style short mode. 13702 # If so, the updated path is stored in $new_path. 13703 13704 input_path="$new_path" 13705 # Check if we need to convert this using DOS-style short mode. If the path 13706 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13707 # take no chances and rewrite it. 13708 # Note: m4 eats our [], so we need to use [ and ] instead. 13709 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13710 if test "x$has_forbidden_chars" != x; then 13711 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13712 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13713 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13714 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13715 # Going to short mode and back again did indeed matter. Since short mode is 13716 # case insensitive, let's make it lowercase to improve readability. 13717 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13718 # Now convert it back to Unix-stile (cygpath) 13719 input_path=`$CYGPATH -u "$shortmode_path"` 13720 new_path="$input_path" 13721 fi 13722 fi 13723 13724 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13725 if test "x$test_cygdrive_prefix" = x; then 13726 # As a simple fix, exclude /usr/bin since it's not a real path. 13727 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13728 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13729 # a path prefixed by /cygdrive for fixpath to work. 13730 new_path="$CYGWIN_ROOT_PATH$input_path" 13731 fi 13732 fi 13733 13734 13735 if test "x$path" != "x$new_path"; then 13736 BOOT_JDK="$new_path" 13737 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13738 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13739 fi 13740 13741 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13742 13743 path="$BOOT_JDK" 13744 has_colon=`$ECHO $path | $GREP ^.:` 13745 new_path="$path" 13746 if test "x$has_colon" = x; then 13747 # Not in mixed or Windows style, start by that. 13748 new_path=`cmd //c echo $path` 13749 fi 13750 13751 13752 input_path="$new_path" 13753 # Check if we need to convert this using DOS-style short mode. If the path 13754 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13755 # take no chances and rewrite it. 13756 # Note: m4 eats our [], so we need to use [ and ] instead. 13757 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13758 if test "x$has_forbidden_chars" != x; then 13759 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13760 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13761 fi 13762 13763 13764 windows_path="$new_path" 13765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13766 unix_path=`$CYGPATH -u "$windows_path"` 13767 new_path="$unix_path" 13768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13769 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13770 new_path="$unix_path" 13771 fi 13772 13773 if test "x$path" != "x$new_path"; then 13774 BOOT_JDK="$new_path" 13775 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13776 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13777 fi 13778 13779 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13780 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13781 13782 else 13783 # We're on a posix platform. Hooray! :) 13784 path="$BOOT_JDK" 13785 has_space=`$ECHO "$path" | $GREP " "` 13786 if test "x$has_space" != x; then 13787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13788 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13789 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13790 fi 13791 13792 # Use eval to expand a potential ~ 13793 eval path="$path" 13794 if test ! -f "$path" && test ! -d "$path"; then 13795 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13796 fi 13797 13798 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13799 fi 13800 13801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13802 $as_echo_n "checking for Boot JDK... " >&6; } 13803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13804 $as_echo "$BOOT_JDK" >&6; } 13805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13806 $as_echo_n "checking Boot JDK version... " >&6; } 13807 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13809 $as_echo "$BOOT_JDK_VERSION" >&6; } 13810 fi # end check jdk version 13811 fi # end check rt.jar 13812 fi # end check javac 13813 fi # end check java 13814 fi # end check boot jdk found 13815 fi 13816 13817 done 13818 fi 13819 13820 fi 13821 13822 13823 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 13824 if test "x$BOOT_JDK_FOUND" = xmaybe; then 13825 # Do we have a bin/java? 13826 if test ! -x "$BOOT_JDK/bin/java"; then 13827 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 13828 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 13829 BOOT_JDK_FOUND=no 13830 else 13831 # Do we have a bin/javac? 13832 if test ! -x "$BOOT_JDK/bin/javac"; then 13833 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 13834 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 13835 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 13836 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 13837 BOOT_JDK_FOUND=no 13838 else 13839 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 13840 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 13841 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 13842 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 13843 BOOT_JDK_FOUND=no 13844 else 13845 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 13846 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 13847 13848 # Extra M4 quote needed to protect [] in grep expression. 13849 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 13850 if test "x$FOUND_VERSION_78" = x; then 13851 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 13852 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 13853 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 13854 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 13855 BOOT_JDK_FOUND=no 13856 else 13857 # We're done! :-) 13858 BOOT_JDK_FOUND=yes 13859 13860 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13861 13862 # Input might be given as Windows format, start by converting to 13863 # unix format. 13864 path="$BOOT_JDK" 13865 new_path=`$CYGPATH -u "$path"` 13866 13867 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 13868 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 13869 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 13870 # "foo.exe" is OK but "foo" is an error. 13871 # 13872 # This test is therefore slightly more accurate than "test -f" to check for file precense. 13873 # It is also a way to make sure we got the proper file name for the real test later on. 13874 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 13875 if test "x$test_shortpath" = x; then 13876 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13877 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13878 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 13879 fi 13880 13881 # Call helper function which possibly converts this using DOS-style short mode. 13882 # If so, the updated path is stored in $new_path. 13883 13884 input_path="$new_path" 13885 # Check if we need to convert this using DOS-style short mode. If the path 13886 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13887 # take no chances and rewrite it. 13888 # Note: m4 eats our [], so we need to use [ and ] instead. 13889 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 13890 if test "x$has_forbidden_chars" != x; then 13891 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13892 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 13893 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 13894 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 13895 # Going to short mode and back again did indeed matter. Since short mode is 13896 # case insensitive, let's make it lowercase to improve readability. 13897 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13898 # Now convert it back to Unix-stile (cygpath) 13899 input_path=`$CYGPATH -u "$shortmode_path"` 13900 new_path="$input_path" 13901 fi 13902 fi 13903 13904 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 13905 if test "x$test_cygdrive_prefix" = x; then 13906 # As a simple fix, exclude /usr/bin since it's not a real path. 13907 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 13908 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 13909 # a path prefixed by /cygdrive for fixpath to work. 13910 new_path="$CYGWIN_ROOT_PATH$input_path" 13911 fi 13912 fi 13913 13914 13915 if test "x$path" != "x$new_path"; then 13916 BOOT_JDK="$new_path" 13917 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13918 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13919 fi 13920 13921 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13922 13923 path="$BOOT_JDK" 13924 has_colon=`$ECHO $path | $GREP ^.:` 13925 new_path="$path" 13926 if test "x$has_colon" = x; then 13927 # Not in mixed or Windows style, start by that. 13928 new_path=`cmd //c echo $path` 13929 fi 13930 13931 13932 input_path="$new_path" 13933 # Check if we need to convert this using DOS-style short mode. If the path 13934 # contains just simple characters, use it. Otherwise (spaces, weird characters), 13935 # take no chances and rewrite it. 13936 # Note: m4 eats our [], so we need to use [ and ] instead. 13937 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 13938 if test "x$has_forbidden_chars" != x; then 13939 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 13940 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 13941 fi 13942 13943 13944 windows_path="$new_path" 13945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 13946 unix_path=`$CYGPATH -u "$windows_path"` 13947 new_path="$unix_path" 13948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 13949 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 13950 new_path="$unix_path" 13951 fi 13952 13953 if test "x$path" != "x$new_path"; then 13954 BOOT_JDK="$new_path" 13955 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 13956 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 13957 fi 13958 13959 # Save the first 10 bytes of this path to the storage, so fixpath can work. 13960 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 13961 13962 else 13963 # We're on a posix platform. Hooray! :) 13964 path="$BOOT_JDK" 13965 has_space=`$ECHO "$path" | $GREP " "` 13966 if test "x$has_space" != x; then 13967 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 13968 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 13969 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 13970 fi 13971 13972 # Use eval to expand a potential ~ 13973 eval path="$path" 13974 if test ! -f "$path" && test ! -d "$path"; then 13975 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 13976 fi 13977 13978 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 13979 fi 13980 13981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 13982 $as_echo_n "checking for Boot JDK... " >&6; } 13983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 13984 $as_echo "$BOOT_JDK" >&6; } 13985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 13986 $as_echo_n "checking Boot JDK version... " >&6; } 13987 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 13988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 13989 $as_echo "$BOOT_JDK_VERSION" >&6; } 13990 fi # end check jdk version 13991 fi # end check rt.jar 13992 fi # end check javac 13993 fi # end check java 13994 fi # end check boot jdk found 13995 fi 13996 13997 13998 if test "x$BOOT_JDK_FOUND" = xno; then 13999 # Now execute the test 14000 14001 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 14002 BOOT_JDK_SUFFIX="" 14003 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 14004 if test "x$ALL_JDKS_FOUND" != x; then 14005 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 14006 14007 if test "x$BOOT_JDK_FOUND" = xno; then 14008 # Now execute the test 14009 14010 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 14011 if test -d "$BOOT_JDK"; then 14012 BOOT_JDK_FOUND=maybe 14013 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 14014 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 14015 fi 14016 14017 14018 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14019 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14020 # Do we have a bin/java? 14021 if test ! -x "$BOOT_JDK/bin/java"; then 14022 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14023 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14024 BOOT_JDK_FOUND=no 14025 else 14026 # Do we have a bin/javac? 14027 if test ! -x "$BOOT_JDK/bin/javac"; then 14028 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14029 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14030 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14031 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14032 BOOT_JDK_FOUND=no 14033 else 14034 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14035 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14036 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14037 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14038 BOOT_JDK_FOUND=no 14039 else 14040 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14041 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14042 14043 # Extra M4 quote needed to protect [] in grep expression. 14044 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14045 if test "x$FOUND_VERSION_78" = x; then 14046 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14047 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14048 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14049 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14050 BOOT_JDK_FOUND=no 14051 else 14052 # We're done! :-) 14053 BOOT_JDK_FOUND=yes 14054 14055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14056 14057 # Input might be given as Windows format, start by converting to 14058 # unix format. 14059 path="$BOOT_JDK" 14060 new_path=`$CYGPATH -u "$path"` 14061 14062 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14063 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14064 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14065 # "foo.exe" is OK but "foo" is an error. 14066 # 14067 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14068 # It is also a way to make sure we got the proper file name for the real test later on. 14069 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14070 if test "x$test_shortpath" = x; then 14071 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14072 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14073 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14074 fi 14075 14076 # Call helper function which possibly converts this using DOS-style short mode. 14077 # If so, the updated path is stored in $new_path. 14078 14079 input_path="$new_path" 14080 # Check if we need to convert this using DOS-style short mode. If the path 14081 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14082 # take no chances and rewrite it. 14083 # Note: m4 eats our [], so we need to use [ and ] instead. 14084 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14085 if test "x$has_forbidden_chars" != x; then 14086 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14087 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14088 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14089 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14090 # Going to short mode and back again did indeed matter. Since short mode is 14091 # case insensitive, let's make it lowercase to improve readability. 14092 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14093 # Now convert it back to Unix-stile (cygpath) 14094 input_path=`$CYGPATH -u "$shortmode_path"` 14095 new_path="$input_path" 14096 fi 14097 fi 14098 14099 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14100 if test "x$test_cygdrive_prefix" = x; then 14101 # As a simple fix, exclude /usr/bin since it's not a real path. 14102 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14103 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14104 # a path prefixed by /cygdrive for fixpath to work. 14105 new_path="$CYGWIN_ROOT_PATH$input_path" 14106 fi 14107 fi 14108 14109 14110 if test "x$path" != "x$new_path"; then 14111 BOOT_JDK="$new_path" 14112 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14113 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14114 fi 14115 14116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14117 14118 path="$BOOT_JDK" 14119 has_colon=`$ECHO $path | $GREP ^.:` 14120 new_path="$path" 14121 if test "x$has_colon" = x; then 14122 # Not in mixed or Windows style, start by that. 14123 new_path=`cmd //c echo $path` 14124 fi 14125 14126 14127 input_path="$new_path" 14128 # Check if we need to convert this using DOS-style short mode. If the path 14129 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14130 # take no chances and rewrite it. 14131 # Note: m4 eats our [], so we need to use [ and ] instead. 14132 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14133 if test "x$has_forbidden_chars" != x; then 14134 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14135 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14136 fi 14137 14138 14139 windows_path="$new_path" 14140 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14141 unix_path=`$CYGPATH -u "$windows_path"` 14142 new_path="$unix_path" 14143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14144 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14145 new_path="$unix_path" 14146 fi 14147 14148 if test "x$path" != "x$new_path"; then 14149 BOOT_JDK="$new_path" 14150 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14151 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14152 fi 14153 14154 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14155 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14156 14157 else 14158 # We're on a posix platform. Hooray! :) 14159 path="$BOOT_JDK" 14160 has_space=`$ECHO "$path" | $GREP " "` 14161 if test "x$has_space" != x; then 14162 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14163 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14164 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14165 fi 14166 14167 # Use eval to expand a potential ~ 14168 eval path="$path" 14169 if test ! -f "$path" && test ! -d "$path"; then 14170 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14171 fi 14172 14173 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 14174 fi 14175 14176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14177 $as_echo_n "checking for Boot JDK... " >&6; } 14178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14179 $as_echo "$BOOT_JDK" >&6; } 14180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14181 $as_echo_n "checking Boot JDK version... " >&6; } 14182 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14184 $as_echo "$BOOT_JDK_VERSION" >&6; } 14185 fi # end check jdk version 14186 fi # end check rt.jar 14187 fi # end check javac 14188 fi # end check java 14189 fi # end check boot jdk found 14190 fi 14191 14192 done 14193 fi 14194 14195 14196 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14197 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14198 # Do we have a bin/java? 14199 if test ! -x "$BOOT_JDK/bin/java"; then 14200 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14201 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14202 BOOT_JDK_FOUND=no 14203 else 14204 # Do we have a bin/javac? 14205 if test ! -x "$BOOT_JDK/bin/javac"; then 14206 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14207 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14208 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14209 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14210 BOOT_JDK_FOUND=no 14211 else 14212 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14213 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14214 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14215 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14216 BOOT_JDK_FOUND=no 14217 else 14218 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14219 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14220 14221 # Extra M4 quote needed to protect [] in grep expression. 14222 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14223 if test "x$FOUND_VERSION_78" = x; then 14224 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14225 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14226 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14227 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14228 BOOT_JDK_FOUND=no 14229 else 14230 # We're done! :-) 14231 BOOT_JDK_FOUND=yes 14232 14233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14234 14235 # Input might be given as Windows format, start by converting to 14236 # unix format. 14237 path="$BOOT_JDK" 14238 new_path=`$CYGPATH -u "$path"` 14239 14240 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14241 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14242 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14243 # "foo.exe" is OK but "foo" is an error. 14244 # 14245 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14246 # It is also a way to make sure we got the proper file name for the real test later on. 14247 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14248 if test "x$test_shortpath" = x; then 14249 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14250 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14251 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14252 fi 14253 14254 # Call helper function which possibly converts this using DOS-style short mode. 14255 # If so, the updated path is stored in $new_path. 14256 14257 input_path="$new_path" 14258 # Check if we need to convert this using DOS-style short mode. If the path 14259 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14260 # take no chances and rewrite it. 14261 # Note: m4 eats our [], so we need to use [ and ] instead. 14262 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14263 if test "x$has_forbidden_chars" != x; then 14264 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14265 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14266 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14267 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14268 # Going to short mode and back again did indeed matter. Since short mode is 14269 # case insensitive, let's make it lowercase to improve readability. 14270 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14271 # Now convert it back to Unix-stile (cygpath) 14272 input_path=`$CYGPATH -u "$shortmode_path"` 14273 new_path="$input_path" 14274 fi 14275 fi 14276 14277 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14278 if test "x$test_cygdrive_prefix" = x; then 14279 # As a simple fix, exclude /usr/bin since it's not a real path. 14280 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14281 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14282 # a path prefixed by /cygdrive for fixpath to work. 14283 new_path="$CYGWIN_ROOT_PATH$input_path" 14284 fi 14285 fi 14286 14287 14288 if test "x$path" != "x$new_path"; then 14289 BOOT_JDK="$new_path" 14290 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14291 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14292 fi 14293 14294 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14295 14296 path="$BOOT_JDK" 14297 has_colon=`$ECHO $path | $GREP ^.:` 14298 new_path="$path" 14299 if test "x$has_colon" = x; then 14300 # Not in mixed or Windows style, start by that. 14301 new_path=`cmd //c echo $path` 14302 fi 14303 14304 14305 input_path="$new_path" 14306 # Check if we need to convert this using DOS-style short mode. If the path 14307 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14308 # take no chances and rewrite it. 14309 # Note: m4 eats our [], so we need to use [ and ] instead. 14310 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14311 if test "x$has_forbidden_chars" != x; then 14312 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14313 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14314 fi 14315 14316 14317 windows_path="$new_path" 14318 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14319 unix_path=`$CYGPATH -u "$windows_path"` 14320 new_path="$unix_path" 14321 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14322 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14323 new_path="$unix_path" 14324 fi 14325 14326 if test "x$path" != "x$new_path"; then 14327 BOOT_JDK="$new_path" 14328 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14329 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14330 fi 14331 14332 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14333 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14334 14335 else 14336 # We're on a posix platform. Hooray! :) 14337 path="$BOOT_JDK" 14338 has_space=`$ECHO "$path" | $GREP " "` 14339 if test "x$has_space" != x; then 14340 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14341 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14342 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14343 fi 14344 14345 # Use eval to expand a potential ~ 14346 eval path="$path" 14347 if test ! -f "$path" && test ! -d "$path"; then 14348 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14349 fi 14350 14351 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 14352 fi 14353 14354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14355 $as_echo_n "checking for Boot JDK... " >&6; } 14356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14357 $as_echo "$BOOT_JDK" >&6; } 14358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14359 $as_echo_n "checking Boot JDK version... " >&6; } 14360 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14362 $as_echo "$BOOT_JDK_VERSION" >&6; } 14363 fi # end check jdk version 14364 fi # end check rt.jar 14365 fi # end check javac 14366 fi # end check java 14367 fi # end check boot jdk found 14368 fi 14369 14370 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 14371 14372 if test "x$BOOT_JDK_FOUND" = xno; then 14373 # Now execute the test 14374 14375 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 14376 BOOT_JDK_SUFFIX="/Contents/Home" 14377 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 14378 if test "x$ALL_JDKS_FOUND" != x; then 14379 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 14380 14381 if test "x$BOOT_JDK_FOUND" = xno; then 14382 # Now execute the test 14383 14384 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 14385 if test -d "$BOOT_JDK"; then 14386 BOOT_JDK_FOUND=maybe 14387 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 14388 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 14389 fi 14390 14391 14392 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14393 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14394 # Do we have a bin/java? 14395 if test ! -x "$BOOT_JDK/bin/java"; then 14396 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14397 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14398 BOOT_JDK_FOUND=no 14399 else 14400 # Do we have a bin/javac? 14401 if test ! -x "$BOOT_JDK/bin/javac"; then 14402 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14403 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14404 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14405 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14406 BOOT_JDK_FOUND=no 14407 else 14408 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14409 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14410 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14411 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14412 BOOT_JDK_FOUND=no 14413 else 14414 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14415 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14416 14417 # Extra M4 quote needed to protect [] in grep expression. 14418 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14419 if test "x$FOUND_VERSION_78" = x; then 14420 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14421 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14422 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14423 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14424 BOOT_JDK_FOUND=no 14425 else 14426 # We're done! :-) 14427 BOOT_JDK_FOUND=yes 14428 14429 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14430 14431 # Input might be given as Windows format, start by converting to 14432 # unix format. 14433 path="$BOOT_JDK" 14434 new_path=`$CYGPATH -u "$path"` 14435 14436 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14437 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14438 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14439 # "foo.exe" is OK but "foo" is an error. 14440 # 14441 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14442 # It is also a way to make sure we got the proper file name for the real test later on. 14443 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14444 if test "x$test_shortpath" = x; then 14445 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14446 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14447 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14448 fi 14449 14450 # Call helper function which possibly converts this using DOS-style short mode. 14451 # If so, the updated path is stored in $new_path. 14452 14453 input_path="$new_path" 14454 # Check if we need to convert this using DOS-style short mode. If the path 14455 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14456 # take no chances and rewrite it. 14457 # Note: m4 eats our [], so we need to use [ and ] instead. 14458 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14459 if test "x$has_forbidden_chars" != x; then 14460 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14461 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14462 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14463 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14464 # Going to short mode and back again did indeed matter. Since short mode is 14465 # case insensitive, let's make it lowercase to improve readability. 14466 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14467 # Now convert it back to Unix-stile (cygpath) 14468 input_path=`$CYGPATH -u "$shortmode_path"` 14469 new_path="$input_path" 14470 fi 14471 fi 14472 14473 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14474 if test "x$test_cygdrive_prefix" = x; then 14475 # As a simple fix, exclude /usr/bin since it's not a real path. 14476 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14477 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14478 # a path prefixed by /cygdrive for fixpath to work. 14479 new_path="$CYGWIN_ROOT_PATH$input_path" 14480 fi 14481 fi 14482 14483 14484 if test "x$path" != "x$new_path"; then 14485 BOOT_JDK="$new_path" 14486 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14487 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14488 fi 14489 14490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14491 14492 path="$BOOT_JDK" 14493 has_colon=`$ECHO $path | $GREP ^.:` 14494 new_path="$path" 14495 if test "x$has_colon" = x; then 14496 # Not in mixed or Windows style, start by that. 14497 new_path=`cmd //c echo $path` 14498 fi 14499 14500 14501 input_path="$new_path" 14502 # Check if we need to convert this using DOS-style short mode. If the path 14503 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14504 # take no chances and rewrite it. 14505 # Note: m4 eats our [], so we need to use [ and ] instead. 14506 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14507 if test "x$has_forbidden_chars" != x; then 14508 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14509 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14510 fi 14511 14512 14513 windows_path="$new_path" 14514 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14515 unix_path=`$CYGPATH -u "$windows_path"` 14516 new_path="$unix_path" 14517 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14518 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14519 new_path="$unix_path" 14520 fi 14521 14522 if test "x$path" != "x$new_path"; then 14523 BOOT_JDK="$new_path" 14524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14525 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14526 fi 14527 14528 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14529 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14530 14531 else 14532 # We're on a posix platform. Hooray! :) 14533 path="$BOOT_JDK" 14534 has_space=`$ECHO "$path" | $GREP " "` 14535 if test "x$has_space" != x; then 14536 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14537 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14538 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14539 fi 14540 14541 # Use eval to expand a potential ~ 14542 eval path="$path" 14543 if test ! -f "$path" && test ! -d "$path"; then 14544 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14545 fi 14546 14547 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 14548 fi 14549 14550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14551 $as_echo_n "checking for Boot JDK... " >&6; } 14552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14553 $as_echo "$BOOT_JDK" >&6; } 14554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14555 $as_echo_n "checking Boot JDK version... " >&6; } 14556 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14558 $as_echo "$BOOT_JDK_VERSION" >&6; } 14559 fi # end check jdk version 14560 fi # end check rt.jar 14561 fi # end check javac 14562 fi # end check java 14563 fi # end check boot jdk found 14564 fi 14565 14566 done 14567 fi 14568 14569 14570 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14571 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14572 # Do we have a bin/java? 14573 if test ! -x "$BOOT_JDK/bin/java"; then 14574 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14575 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14576 BOOT_JDK_FOUND=no 14577 else 14578 # Do we have a bin/javac? 14579 if test ! -x "$BOOT_JDK/bin/javac"; then 14580 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14581 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14582 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14583 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14584 BOOT_JDK_FOUND=no 14585 else 14586 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14587 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14588 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14589 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14590 BOOT_JDK_FOUND=no 14591 else 14592 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14593 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14594 14595 # Extra M4 quote needed to protect [] in grep expression. 14596 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14597 if test "x$FOUND_VERSION_78" = x; then 14598 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14599 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14600 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14601 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14602 BOOT_JDK_FOUND=no 14603 else 14604 # We're done! :-) 14605 BOOT_JDK_FOUND=yes 14606 14607 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14608 14609 # Input might be given as Windows format, start by converting to 14610 # unix format. 14611 path="$BOOT_JDK" 14612 new_path=`$CYGPATH -u "$path"` 14613 14614 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14615 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14616 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14617 # "foo.exe" is OK but "foo" is an error. 14618 # 14619 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14620 # It is also a way to make sure we got the proper file name for the real test later on. 14621 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14622 if test "x$test_shortpath" = x; then 14623 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14624 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14625 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14626 fi 14627 14628 # Call helper function which possibly converts this using DOS-style short mode. 14629 # If so, the updated path is stored in $new_path. 14630 14631 input_path="$new_path" 14632 # Check if we need to convert this using DOS-style short mode. If the path 14633 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14634 # take no chances and rewrite it. 14635 # Note: m4 eats our [], so we need to use [ and ] instead. 14636 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14637 if test "x$has_forbidden_chars" != x; then 14638 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14639 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14640 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14641 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14642 # Going to short mode and back again did indeed matter. Since short mode is 14643 # case insensitive, let's make it lowercase to improve readability. 14644 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14645 # Now convert it back to Unix-stile (cygpath) 14646 input_path=`$CYGPATH -u "$shortmode_path"` 14647 new_path="$input_path" 14648 fi 14649 fi 14650 14651 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14652 if test "x$test_cygdrive_prefix" = x; then 14653 # As a simple fix, exclude /usr/bin since it's not a real path. 14654 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14655 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14656 # a path prefixed by /cygdrive for fixpath to work. 14657 new_path="$CYGWIN_ROOT_PATH$input_path" 14658 fi 14659 fi 14660 14661 14662 if test "x$path" != "x$new_path"; then 14663 BOOT_JDK="$new_path" 14664 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14665 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14666 fi 14667 14668 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14669 14670 path="$BOOT_JDK" 14671 has_colon=`$ECHO $path | $GREP ^.:` 14672 new_path="$path" 14673 if test "x$has_colon" = x; then 14674 # Not in mixed or Windows style, start by that. 14675 new_path=`cmd //c echo $path` 14676 fi 14677 14678 14679 input_path="$new_path" 14680 # Check if we need to convert this using DOS-style short mode. If the path 14681 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14682 # take no chances and rewrite it. 14683 # Note: m4 eats our [], so we need to use [ and ] instead. 14684 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14685 if test "x$has_forbidden_chars" != x; then 14686 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14687 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14688 fi 14689 14690 14691 windows_path="$new_path" 14692 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14693 unix_path=`$CYGPATH -u "$windows_path"` 14694 new_path="$unix_path" 14695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14696 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14697 new_path="$unix_path" 14698 fi 14699 14700 if test "x$path" != "x$new_path"; then 14701 BOOT_JDK="$new_path" 14702 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14703 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14704 fi 14705 14706 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14707 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14708 14709 else 14710 # We're on a posix platform. Hooray! :) 14711 path="$BOOT_JDK" 14712 has_space=`$ECHO "$path" | $GREP " "` 14713 if test "x$has_space" != x; then 14714 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14715 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14716 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14717 fi 14718 14719 # Use eval to expand a potential ~ 14720 eval path="$path" 14721 if test ! -f "$path" && test ! -d "$path"; then 14722 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14723 fi 14724 14725 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 14726 fi 14727 14728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14729 $as_echo_n "checking for Boot JDK... " >&6; } 14730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14731 $as_echo "$BOOT_JDK" >&6; } 14732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14733 $as_echo_n "checking Boot JDK version... " >&6; } 14734 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14736 $as_echo "$BOOT_JDK_VERSION" >&6; } 14737 fi # end check jdk version 14738 fi # end check rt.jar 14739 fi # end check javac 14740 fi # end check java 14741 fi # end check boot jdk found 14742 fi 14743 14744 14745 if test "x$BOOT_JDK_FOUND" = xno; then 14746 # Now execute the test 14747 14748 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 14749 BOOT_JDK_SUFFIX="/Contents/Home" 14750 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 14751 if test "x$ALL_JDKS_FOUND" != x; then 14752 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 14753 14754 if test "x$BOOT_JDK_FOUND" = xno; then 14755 # Now execute the test 14756 14757 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 14758 if test -d "$BOOT_JDK"; then 14759 BOOT_JDK_FOUND=maybe 14760 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 14761 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 14762 fi 14763 14764 14765 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14766 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14767 # Do we have a bin/java? 14768 if test ! -x "$BOOT_JDK/bin/java"; then 14769 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14770 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14771 BOOT_JDK_FOUND=no 14772 else 14773 # Do we have a bin/javac? 14774 if test ! -x "$BOOT_JDK/bin/javac"; then 14775 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14776 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14777 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14778 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14779 BOOT_JDK_FOUND=no 14780 else 14781 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14782 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14783 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14784 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14785 BOOT_JDK_FOUND=no 14786 else 14787 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14788 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14789 14790 # Extra M4 quote needed to protect [] in grep expression. 14791 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14792 if test "x$FOUND_VERSION_78" = x; then 14793 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14794 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14795 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14796 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14797 BOOT_JDK_FOUND=no 14798 else 14799 # We're done! :-) 14800 BOOT_JDK_FOUND=yes 14801 14802 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14803 14804 # Input might be given as Windows format, start by converting to 14805 # unix format. 14806 path="$BOOT_JDK" 14807 new_path=`$CYGPATH -u "$path"` 14808 14809 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14810 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14811 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14812 # "foo.exe" is OK but "foo" is an error. 14813 # 14814 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14815 # It is also a way to make sure we got the proper file name for the real test later on. 14816 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14817 if test "x$test_shortpath" = x; then 14818 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14819 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14820 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14821 fi 14822 14823 # Call helper function which possibly converts this using DOS-style short mode. 14824 # If so, the updated path is stored in $new_path. 14825 14826 input_path="$new_path" 14827 # Check if we need to convert this using DOS-style short mode. If the path 14828 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14829 # take no chances and rewrite it. 14830 # Note: m4 eats our [], so we need to use [ and ] instead. 14831 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 14832 if test "x$has_forbidden_chars" != x; then 14833 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14834 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 14835 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 14836 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 14837 # Going to short mode and back again did indeed matter. Since short mode is 14838 # case insensitive, let's make it lowercase to improve readability. 14839 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14840 # Now convert it back to Unix-stile (cygpath) 14841 input_path=`$CYGPATH -u "$shortmode_path"` 14842 new_path="$input_path" 14843 fi 14844 fi 14845 14846 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 14847 if test "x$test_cygdrive_prefix" = x; then 14848 # As a simple fix, exclude /usr/bin since it's not a real path. 14849 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 14850 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 14851 # a path prefixed by /cygdrive for fixpath to work. 14852 new_path="$CYGWIN_ROOT_PATH$input_path" 14853 fi 14854 fi 14855 14856 14857 if test "x$path" != "x$new_path"; then 14858 BOOT_JDK="$new_path" 14859 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14860 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14861 fi 14862 14863 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14864 14865 path="$BOOT_JDK" 14866 has_colon=`$ECHO $path | $GREP ^.:` 14867 new_path="$path" 14868 if test "x$has_colon" = x; then 14869 # Not in mixed or Windows style, start by that. 14870 new_path=`cmd //c echo $path` 14871 fi 14872 14873 14874 input_path="$new_path" 14875 # Check if we need to convert this using DOS-style short mode. If the path 14876 # contains just simple characters, use it. Otherwise (spaces, weird characters), 14877 # take no chances and rewrite it. 14878 # Note: m4 eats our [], so we need to use [ and ] instead. 14879 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 14880 if test "x$has_forbidden_chars" != x; then 14881 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 14882 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 14883 fi 14884 14885 14886 windows_path="$new_path" 14887 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14888 unix_path=`$CYGPATH -u "$windows_path"` 14889 new_path="$unix_path" 14890 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 14891 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 14892 new_path="$unix_path" 14893 fi 14894 14895 if test "x$path" != "x$new_path"; then 14896 BOOT_JDK="$new_path" 14897 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 14898 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 14899 fi 14900 14901 # Save the first 10 bytes of this path to the storage, so fixpath can work. 14902 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 14903 14904 else 14905 # We're on a posix platform. Hooray! :) 14906 path="$BOOT_JDK" 14907 has_space=`$ECHO "$path" | $GREP " "` 14908 if test "x$has_space" != x; then 14909 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14910 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14911 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 14912 fi 14913 14914 # Use eval to expand a potential ~ 14915 eval path="$path" 14916 if test ! -f "$path" && test ! -d "$path"; then 14917 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 14918 fi 14919 14920 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 14921 fi 14922 14923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 14924 $as_echo_n "checking for Boot JDK... " >&6; } 14925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 14926 $as_echo "$BOOT_JDK" >&6; } 14927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 14928 $as_echo_n "checking Boot JDK version... " >&6; } 14929 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 14930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 14931 $as_echo "$BOOT_JDK_VERSION" >&6; } 14932 fi # end check jdk version 14933 fi # end check rt.jar 14934 fi # end check javac 14935 fi # end check java 14936 fi # end check boot jdk found 14937 fi 14938 14939 done 14940 fi 14941 14942 14943 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 14944 if test "x$BOOT_JDK_FOUND" = xmaybe; then 14945 # Do we have a bin/java? 14946 if test ! -x "$BOOT_JDK/bin/java"; then 14947 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 14948 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 14949 BOOT_JDK_FOUND=no 14950 else 14951 # Do we have a bin/javac? 14952 if test ! -x "$BOOT_JDK/bin/javac"; then 14953 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 14954 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 14955 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 14956 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 14957 BOOT_JDK_FOUND=no 14958 else 14959 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 14960 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 14961 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 14962 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 14963 BOOT_JDK_FOUND=no 14964 else 14965 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 14966 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 14967 14968 # Extra M4 quote needed to protect [] in grep expression. 14969 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 14970 if test "x$FOUND_VERSION_78" = x; then 14971 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 14972 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 14973 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 14974 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 14975 BOOT_JDK_FOUND=no 14976 else 14977 # We're done! :-) 14978 BOOT_JDK_FOUND=yes 14979 14980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 14981 14982 # Input might be given as Windows format, start by converting to 14983 # unix format. 14984 path="$BOOT_JDK" 14985 new_path=`$CYGPATH -u "$path"` 14986 14987 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 14988 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 14989 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 14990 # "foo.exe" is OK but "foo" is an error. 14991 # 14992 # This test is therefore slightly more accurate than "test -f" to check for file precense. 14993 # It is also a way to make sure we got the proper file name for the real test later on. 14994 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 14995 if test "x$test_shortpath" = x; then 14996 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 14997 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 14998 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 14999 fi 15000 15001 # Call helper function which possibly converts this using DOS-style short mode. 15002 # If so, the updated path is stored in $new_path. 15003 15004 input_path="$new_path" 15005 # Check if we need to convert this using DOS-style short mode. If the path 15006 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15007 # take no chances and rewrite it. 15008 # Note: m4 eats our [], so we need to use [ and ] instead. 15009 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15010 if test "x$has_forbidden_chars" != x; then 15011 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15012 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15013 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15014 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15015 # Going to short mode and back again did indeed matter. Since short mode is 15016 # case insensitive, let's make it lowercase to improve readability. 15017 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15018 # Now convert it back to Unix-stile (cygpath) 15019 input_path=`$CYGPATH -u "$shortmode_path"` 15020 new_path="$input_path" 15021 fi 15022 fi 15023 15024 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15025 if test "x$test_cygdrive_prefix" = x; then 15026 # As a simple fix, exclude /usr/bin since it's not a real path. 15027 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15028 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15029 # a path prefixed by /cygdrive for fixpath to work. 15030 new_path="$CYGWIN_ROOT_PATH$input_path" 15031 fi 15032 fi 15033 15034 15035 if test "x$path" != "x$new_path"; then 15036 BOOT_JDK="$new_path" 15037 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15038 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15039 fi 15040 15041 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15042 15043 path="$BOOT_JDK" 15044 has_colon=`$ECHO $path | $GREP ^.:` 15045 new_path="$path" 15046 if test "x$has_colon" = x; then 15047 # Not in mixed or Windows style, start by that. 15048 new_path=`cmd //c echo $path` 15049 fi 15050 15051 15052 input_path="$new_path" 15053 # Check if we need to convert this using DOS-style short mode. If the path 15054 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15055 # take no chances and rewrite it. 15056 # Note: m4 eats our [], so we need to use [ and ] instead. 15057 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15058 if test "x$has_forbidden_chars" != x; then 15059 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15060 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15061 fi 15062 15063 15064 windows_path="$new_path" 15065 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15066 unix_path=`$CYGPATH -u "$windows_path"` 15067 new_path="$unix_path" 15068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15069 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15070 new_path="$unix_path" 15071 fi 15072 15073 if test "x$path" != "x$new_path"; then 15074 BOOT_JDK="$new_path" 15075 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15076 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15077 fi 15078 15079 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15080 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15081 15082 else 15083 # We're on a posix platform. Hooray! :) 15084 path="$BOOT_JDK" 15085 has_space=`$ECHO "$path" | $GREP " "` 15086 if test "x$has_space" != x; then 15087 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15088 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15089 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15090 fi 15091 15092 # Use eval to expand a potential ~ 15093 eval path="$path" 15094 if test ! -f "$path" && test ! -d "$path"; then 15095 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15096 fi 15097 15098 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 15099 fi 15100 15101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15102 $as_echo_n "checking for Boot JDK... " >&6; } 15103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15104 $as_echo "$BOOT_JDK" >&6; } 15105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15106 $as_echo_n "checking Boot JDK version... " >&6; } 15107 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15109 $as_echo "$BOOT_JDK_VERSION" >&6; } 15110 fi # end check jdk version 15111 fi # end check rt.jar 15112 fi # end check javac 15113 fi # end check java 15114 fi # end check boot jdk found 15115 fi 15116 15117 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 15118 15119 if test "x$BOOT_JDK_FOUND" = xno; then 15120 # Now execute the test 15121 15122 BOOT_JDK_PREFIX="/usr/lib/jvm" 15123 BOOT_JDK_SUFFIX="" 15124 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 15125 if test "x$ALL_JDKS_FOUND" != x; then 15126 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 15127 15128 if test "x$BOOT_JDK_FOUND" = xno; then 15129 # Now execute the test 15130 15131 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 15132 if test -d "$BOOT_JDK"; then 15133 BOOT_JDK_FOUND=maybe 15134 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 15135 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 15136 fi 15137 15138 15139 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15140 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15141 # Do we have a bin/java? 15142 if test ! -x "$BOOT_JDK/bin/java"; then 15143 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15144 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15145 BOOT_JDK_FOUND=no 15146 else 15147 # Do we have a bin/javac? 15148 if test ! -x "$BOOT_JDK/bin/javac"; then 15149 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15150 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15151 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15152 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15153 BOOT_JDK_FOUND=no 15154 else 15155 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15156 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15157 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15158 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15159 BOOT_JDK_FOUND=no 15160 else 15161 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15162 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15163 15164 # Extra M4 quote needed to protect [] in grep expression. 15165 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15166 if test "x$FOUND_VERSION_78" = x; then 15167 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15168 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15169 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15170 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15171 BOOT_JDK_FOUND=no 15172 else 15173 # We're done! :-) 15174 BOOT_JDK_FOUND=yes 15175 15176 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15177 15178 # Input might be given as Windows format, start by converting to 15179 # unix format. 15180 path="$BOOT_JDK" 15181 new_path=`$CYGPATH -u "$path"` 15182 15183 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15184 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15185 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15186 # "foo.exe" is OK but "foo" is an error. 15187 # 15188 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15189 # It is also a way to make sure we got the proper file name for the real test later on. 15190 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15191 if test "x$test_shortpath" = x; then 15192 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15193 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15194 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15195 fi 15196 15197 # Call helper function which possibly converts this using DOS-style short mode. 15198 # If so, the updated path is stored in $new_path. 15199 15200 input_path="$new_path" 15201 # Check if we need to convert this using DOS-style short mode. If the path 15202 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15203 # take no chances and rewrite it. 15204 # Note: m4 eats our [], so we need to use [ and ] instead. 15205 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15206 if test "x$has_forbidden_chars" != x; then 15207 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15208 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15209 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15210 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15211 # Going to short mode and back again did indeed matter. Since short mode is 15212 # case insensitive, let's make it lowercase to improve readability. 15213 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15214 # Now convert it back to Unix-stile (cygpath) 15215 input_path=`$CYGPATH -u "$shortmode_path"` 15216 new_path="$input_path" 15217 fi 15218 fi 15219 15220 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15221 if test "x$test_cygdrive_prefix" = x; then 15222 # As a simple fix, exclude /usr/bin since it's not a real path. 15223 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15224 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15225 # a path prefixed by /cygdrive for fixpath to work. 15226 new_path="$CYGWIN_ROOT_PATH$input_path" 15227 fi 15228 fi 15229 15230 15231 if test "x$path" != "x$new_path"; then 15232 BOOT_JDK="$new_path" 15233 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15234 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15235 fi 15236 15237 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15238 15239 path="$BOOT_JDK" 15240 has_colon=`$ECHO $path | $GREP ^.:` 15241 new_path="$path" 15242 if test "x$has_colon" = x; then 15243 # Not in mixed or Windows style, start by that. 15244 new_path=`cmd //c echo $path` 15245 fi 15246 15247 15248 input_path="$new_path" 15249 # Check if we need to convert this using DOS-style short mode. If the path 15250 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15251 # take no chances and rewrite it. 15252 # Note: m4 eats our [], so we need to use [ and ] instead. 15253 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15254 if test "x$has_forbidden_chars" != x; then 15255 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15256 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15257 fi 15258 15259 15260 windows_path="$new_path" 15261 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15262 unix_path=`$CYGPATH -u "$windows_path"` 15263 new_path="$unix_path" 15264 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15265 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15266 new_path="$unix_path" 15267 fi 15268 15269 if test "x$path" != "x$new_path"; then 15270 BOOT_JDK="$new_path" 15271 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15272 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15273 fi 15274 15275 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15276 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15277 15278 else 15279 # We're on a posix platform. Hooray! :) 15280 path="$BOOT_JDK" 15281 has_space=`$ECHO "$path" | $GREP " "` 15282 if test "x$has_space" != x; then 15283 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15284 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15285 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15286 fi 15287 15288 # Use eval to expand a potential ~ 15289 eval path="$path" 15290 if test ! -f "$path" && test ! -d "$path"; then 15291 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15292 fi 15293 15294 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 15295 fi 15296 15297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15298 $as_echo_n "checking for Boot JDK... " >&6; } 15299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15300 $as_echo "$BOOT_JDK" >&6; } 15301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15302 $as_echo_n "checking Boot JDK version... " >&6; } 15303 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15305 $as_echo "$BOOT_JDK_VERSION" >&6; } 15306 fi # end check jdk version 15307 fi # end check rt.jar 15308 fi # end check javac 15309 fi # end check java 15310 fi # end check boot jdk found 15311 fi 15312 15313 done 15314 fi 15315 15316 15317 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15318 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15319 # Do we have a bin/java? 15320 if test ! -x "$BOOT_JDK/bin/java"; then 15321 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15322 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15323 BOOT_JDK_FOUND=no 15324 else 15325 # Do we have a bin/javac? 15326 if test ! -x "$BOOT_JDK/bin/javac"; then 15327 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15328 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15329 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15330 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15331 BOOT_JDK_FOUND=no 15332 else 15333 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15334 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15335 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15336 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15337 BOOT_JDK_FOUND=no 15338 else 15339 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15340 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15341 15342 # Extra M4 quote needed to protect [] in grep expression. 15343 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15344 if test "x$FOUND_VERSION_78" = x; then 15345 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15346 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15347 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15348 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15349 BOOT_JDK_FOUND=no 15350 else 15351 # We're done! :-) 15352 BOOT_JDK_FOUND=yes 15353 15354 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15355 15356 # Input might be given as Windows format, start by converting to 15357 # unix format. 15358 path="$BOOT_JDK" 15359 new_path=`$CYGPATH -u "$path"` 15360 15361 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15362 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15363 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15364 # "foo.exe" is OK but "foo" is an error. 15365 # 15366 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15367 # It is also a way to make sure we got the proper file name for the real test later on. 15368 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15369 if test "x$test_shortpath" = x; then 15370 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15371 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15372 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15373 fi 15374 15375 # Call helper function which possibly converts this using DOS-style short mode. 15376 # If so, the updated path is stored in $new_path. 15377 15378 input_path="$new_path" 15379 # Check if we need to convert this using DOS-style short mode. If the path 15380 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15381 # take no chances and rewrite it. 15382 # Note: m4 eats our [], so we need to use [ and ] instead. 15383 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15384 if test "x$has_forbidden_chars" != x; then 15385 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15386 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15387 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15388 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15389 # Going to short mode and back again did indeed matter. Since short mode is 15390 # case insensitive, let's make it lowercase to improve readability. 15391 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15392 # Now convert it back to Unix-stile (cygpath) 15393 input_path=`$CYGPATH -u "$shortmode_path"` 15394 new_path="$input_path" 15395 fi 15396 fi 15397 15398 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15399 if test "x$test_cygdrive_prefix" = x; then 15400 # As a simple fix, exclude /usr/bin since it's not a real path. 15401 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15402 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15403 # a path prefixed by /cygdrive for fixpath to work. 15404 new_path="$CYGWIN_ROOT_PATH$input_path" 15405 fi 15406 fi 15407 15408 15409 if test "x$path" != "x$new_path"; then 15410 BOOT_JDK="$new_path" 15411 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15412 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15413 fi 15414 15415 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15416 15417 path="$BOOT_JDK" 15418 has_colon=`$ECHO $path | $GREP ^.:` 15419 new_path="$path" 15420 if test "x$has_colon" = x; then 15421 # Not in mixed or Windows style, start by that. 15422 new_path=`cmd //c echo $path` 15423 fi 15424 15425 15426 input_path="$new_path" 15427 # Check if we need to convert this using DOS-style short mode. If the path 15428 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15429 # take no chances and rewrite it. 15430 # Note: m4 eats our [], so we need to use [ and ] instead. 15431 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15432 if test "x$has_forbidden_chars" != x; then 15433 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15434 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15435 fi 15436 15437 15438 windows_path="$new_path" 15439 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15440 unix_path=`$CYGPATH -u "$windows_path"` 15441 new_path="$unix_path" 15442 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15443 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15444 new_path="$unix_path" 15445 fi 15446 15447 if test "x$path" != "x$new_path"; then 15448 BOOT_JDK="$new_path" 15449 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15450 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15451 fi 15452 15453 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15454 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15455 15456 else 15457 # We're on a posix platform. Hooray! :) 15458 path="$BOOT_JDK" 15459 has_space=`$ECHO "$path" | $GREP " "` 15460 if test "x$has_space" != x; then 15461 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15462 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15463 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15464 fi 15465 15466 # Use eval to expand a potential ~ 15467 eval path="$path" 15468 if test ! -f "$path" && test ! -d "$path"; then 15469 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15470 fi 15471 15472 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 15473 fi 15474 15475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15476 $as_echo_n "checking for Boot JDK... " >&6; } 15477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15478 $as_echo "$BOOT_JDK" >&6; } 15479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15480 $as_echo_n "checking Boot JDK version... " >&6; } 15481 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15483 $as_echo "$BOOT_JDK_VERSION" >&6; } 15484 fi # end check jdk version 15485 fi # end check rt.jar 15486 fi # end check javac 15487 fi # end check java 15488 fi # end check boot jdk found 15489 fi 15490 15491 fi 15492 15493 15494 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 15495 if test "x$BOOT_JDK_FOUND" = xmaybe; then 15496 # Do we have a bin/java? 15497 if test ! -x "$BOOT_JDK/bin/java"; then 15498 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 15499 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 15500 BOOT_JDK_FOUND=no 15501 else 15502 # Do we have a bin/javac? 15503 if test ! -x "$BOOT_JDK/bin/javac"; then 15504 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 15505 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 15506 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 15507 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 15508 BOOT_JDK_FOUND=no 15509 else 15510 # Do we have an rt.jar? (On MacOSX it is called classes.jar) 15511 if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then 15512 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5 15513 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;} 15514 BOOT_JDK_FOUND=no 15515 else 15516 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 15517 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 15518 15519 # Extra M4 quote needed to protect [] in grep expression. 15520 FOUND_VERSION_78=`echo $BOOT_JDK_VERSION | grep '\"1\.[78]\.'` 15521 if test "x$FOUND_VERSION_78" = x; then 15522 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 15523 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 15524 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7 or 8)" >&5 15525 $as_echo "$as_me: (Your Boot JDK must be version 7 or 8)" >&6;} 15526 BOOT_JDK_FOUND=no 15527 else 15528 # We're done! :-) 15529 BOOT_JDK_FOUND=yes 15530 15531 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15532 15533 # Input might be given as Windows format, start by converting to 15534 # unix format. 15535 path="$BOOT_JDK" 15536 new_path=`$CYGPATH -u "$path"` 15537 15538 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15539 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15540 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15541 # "foo.exe" is OK but "foo" is an error. 15542 # 15543 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15544 # It is also a way to make sure we got the proper file name for the real test later on. 15545 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15546 if test "x$test_shortpath" = x; then 15547 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15548 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15549 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 15550 fi 15551 15552 # Call helper function which possibly converts this using DOS-style short mode. 15553 # If so, the updated path is stored in $new_path. 15554 15555 input_path="$new_path" 15556 # Check if we need to convert this using DOS-style short mode. If the path 15557 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15558 # take no chances and rewrite it. 15559 # Note: m4 eats our [], so we need to use [ and ] instead. 15560 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15561 if test "x$has_forbidden_chars" != x; then 15562 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15563 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15564 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15565 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15566 # Going to short mode and back again did indeed matter. Since short mode is 15567 # case insensitive, let's make it lowercase to improve readability. 15568 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15569 # Now convert it back to Unix-stile (cygpath) 15570 input_path=`$CYGPATH -u "$shortmode_path"` 15571 new_path="$input_path" 15572 fi 15573 fi 15574 15575 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15576 if test "x$test_cygdrive_prefix" = x; then 15577 # As a simple fix, exclude /usr/bin since it's not a real path. 15578 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15579 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15580 # a path prefixed by /cygdrive for fixpath to work. 15581 new_path="$CYGWIN_ROOT_PATH$input_path" 15582 fi 15583 fi 15584 15585 15586 if test "x$path" != "x$new_path"; then 15587 BOOT_JDK="$new_path" 15588 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15589 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15590 fi 15591 15592 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15593 15594 path="$BOOT_JDK" 15595 has_colon=`$ECHO $path | $GREP ^.:` 15596 new_path="$path" 15597 if test "x$has_colon" = x; then 15598 # Not in mixed or Windows style, start by that. 15599 new_path=`cmd //c echo $path` 15600 fi 15601 15602 15603 input_path="$new_path" 15604 # Check if we need to convert this using DOS-style short mode. If the path 15605 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15606 # take no chances and rewrite it. 15607 # Note: m4 eats our [], so we need to use [ and ] instead. 15608 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15609 if test "x$has_forbidden_chars" != x; then 15610 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15611 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15612 fi 15613 15614 15615 windows_path="$new_path" 15616 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15617 unix_path=`$CYGPATH -u "$windows_path"` 15618 new_path="$unix_path" 15619 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15620 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15621 new_path="$unix_path" 15622 fi 15623 15624 if test "x$path" != "x$new_path"; then 15625 BOOT_JDK="$new_path" 15626 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 15627 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 15628 fi 15629 15630 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15631 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15632 15633 else 15634 # We're on a posix platform. Hooray! :) 15635 path="$BOOT_JDK" 15636 has_space=`$ECHO "$path" | $GREP " "` 15637 if test "x$has_space" != x; then 15638 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 15639 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 15640 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15641 fi 15642 15643 # Use eval to expand a potential ~ 15644 eval path="$path" 15645 if test ! -f "$path" && test ! -d "$path"; then 15646 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 15647 fi 15648 15649 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 15650 fi 15651 15652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 15653 $as_echo_n "checking for Boot JDK... " >&6; } 15654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 15655 $as_echo "$BOOT_JDK" >&6; } 15656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 15657 $as_echo_n "checking Boot JDK version... " >&6; } 15658 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 15659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 15660 $as_echo "$BOOT_JDK_VERSION" >&6; } 15661 fi # end check jdk version 15662 fi # end check rt.jar 15663 fi # end check javac 15664 fi # end check java 15665 fi # end check boot jdk found 15666 fi 15667 15668 15669 # If we haven't found anything yet, we've truly lost. Give up. 15670 if test "x$BOOT_JDK_FOUND" = xno; then 15671 15672 # Print a helpful message on how to acquire the necessary build dependency. 15673 # openjdk is the help tag: freetyp2, cups, pulse, alsa etc 15674 MISSING_DEPENDENCY=openjdk 15675 PKGHANDLER_COMMAND= 15676 15677 case $PKGHANDLER in 15678 apt-get) 15679 apt_help $MISSING_DEPENDENCY ;; 15680 yum) 15681 yum_help $MISSING_DEPENDENCY ;; 15682 port) 15683 port_help $MISSING_DEPENDENCY ;; 15684 pkgutil) 15685 pkgutil_help $MISSING_DEPENDENCY ;; 15686 pkgadd) 15687 pkgadd_help $MISSING_DEPENDENCY ;; 15688 * ) 15689 break ;; 15690 esac 15691 15692 if test "x$PKGHANDLER_COMMAND" != x; then 15693 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 15694 fi 15695 15696 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 15697 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 15698 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 15699 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15700 as_fn_error $? "Cannot continue" "$LINENO" 5 15701 fi 15702 15703 # Setup proper paths for what we found 15704 BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar" 15705 if test ! -f "$BOOT_RTJAR"; then 15706 # On MacOSX it is called classes.jar 15707 BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar" 15708 if test -f "$BOOT_RTJAR"; then 15709 # Remove the .. 15710 BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}" 15711 fi 15712 fi 15713 BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar" 15714 BOOT_JDK="$BOOT_JDK" 15715 15716 15717 15718 15719 # Setup tools from the Boot JDK. 15720 15721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 15722 $as_echo_n "checking for java in Boot JDK... " >&6; } 15723 JAVA=$BOOT_JDK/bin/java 15724 if test ! -x $JAVA; then 15725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15726 $as_echo "not found" >&6; } 15727 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15728 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15729 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 15730 fi 15731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15732 $as_echo "ok" >&6; } 15733 15734 15735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 15736 $as_echo_n "checking for javac in Boot JDK... " >&6; } 15737 JAVAC=$BOOT_JDK/bin/javac 15738 if test ! -x $JAVAC; then 15739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15740 $as_echo "not found" >&6; } 15741 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15742 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15743 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 15744 fi 15745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15746 $as_echo "ok" >&6; } 15747 15748 15749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 15750 $as_echo_n "checking for javah in Boot JDK... " >&6; } 15751 JAVAH=$BOOT_JDK/bin/javah 15752 if test ! -x $JAVAH; then 15753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15754 $as_echo "not found" >&6; } 15755 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15756 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15757 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 15758 fi 15759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15760 $as_echo "ok" >&6; } 15761 15762 15763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javap in Boot JDK" >&5 15764 $as_echo_n "checking for javap in Boot JDK... " >&6; } 15765 JAVAP=$BOOT_JDK/bin/javap 15766 if test ! -x $JAVAP; then 15767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15768 $as_echo "not found" >&6; } 15769 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15770 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15771 as_fn_error $? "Could not find javap in the Boot JDK" "$LINENO" 5 15772 fi 15773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15774 $as_echo "ok" >&6; } 15775 15776 15777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 15778 $as_echo_n "checking for jar in Boot JDK... " >&6; } 15779 JAR=$BOOT_JDK/bin/jar 15780 if test ! -x $JAR; then 15781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15782 $as_echo "not found" >&6; } 15783 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15784 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15785 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 15786 fi 15787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15788 $as_echo "ok" >&6; } 15789 15790 15791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rmic in Boot JDK" >&5 15792 $as_echo_n "checking for rmic in Boot JDK... " >&6; } 15793 RMIC=$BOOT_JDK/bin/rmic 15794 if test ! -x $RMIC; then 15795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15796 $as_echo "not found" >&6; } 15797 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15798 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15799 as_fn_error $? "Could not find rmic in the Boot JDK" "$LINENO" 5 15800 fi 15801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15802 $as_echo "ok" >&6; } 15803 15804 15805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5 15806 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; } 15807 NATIVE2ASCII=$BOOT_JDK/bin/native2ascii 15808 if test ! -x $NATIVE2ASCII; then 15809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15810 $as_echo "not found" >&6; } 15811 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 15812 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 15813 as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5 15814 fi 15815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 15816 $as_echo "ok" >&6; } 15817 15818 15819 # Finally, set some other options... 15820 15821 # When compiling code to be executed by the Boot JDK, force jdk7 compatibility. 15822 BOOT_JDK_SOURCETARGET="-source 7 -target 7" 15823 15824 15825 15826 15827 ############################################################################## 15828 # 15829 # Specify options for anything that is run with the Boot JDK. 15830 # 15831 15832 # Check whether --with-boot-jdk-jvmargs was given. 15833 if test "${with_boot_jdk_jvmargs+set}" = set; then : 15834 withval=$with_boot_jdk_jvmargs; 15835 fi 15836 15837 15838 if test "x$with_boot_jdk_jvmargs" = x; then 15839 # Not all JVM:s accept the same arguments on the command line. 15840 # OpenJDK specific increase in thread stack for JDK build, 15841 # well more specifically, when running javac. 15842 if test "x$BUILD_NUM_BITS" = x32; then 15843 STACK_SIZE=768 15844 else 15845 # Running Javac on a JVM on a 64-bit machine, the stack takes more space 15846 # since 64-bit pointers are pushed on the stach. Apparently, we need 15847 # to increase the stack space when javacing the JDK.... 15848 STACK_SIZE=1536 15849 fi 15850 15851 # Minimum amount of heap memory. 15852 15853 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 15854 $ECHO "Command: $JAVA -Xms64M -version" >&5 15855 OUTPUT=`$JAVA -Xms64M -version 2>&1` 15856 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15857 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15858 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15859 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xms64M" 15860 JVM_ARG_OK=true 15861 else 15862 $ECHO "Arg failed:" >&5 15863 $ECHO "$OUTPUT" >&5 15864 JVM_ARG_OK=false 15865 fi 15866 15867 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15868 # Why does macosx need more heap? Its the huge JDK batch. 15869 15870 $ECHO "Check if jvm arg is ok: -Xmx1600M" >&5 15871 $ECHO "Command: $JAVA -Xmx1600M -version" >&5 15872 OUTPUT=`$JAVA -Xmx1600M -version 2>&1` 15873 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15874 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15875 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15876 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1600M" 15877 JVM_ARG_OK=true 15878 else 15879 $ECHO "Arg failed:" >&5 15880 $ECHO "$OUTPUT" >&5 15881 JVM_ARG_OK=false 15882 fi 15883 15884 else 15885 15886 $ECHO "Check if jvm arg is ok: -Xmx1100M" >&5 15887 $ECHO "Command: $JAVA -Xmx1100M -version" >&5 15888 OUTPUT=`$JAVA -Xmx1100M -version 2>&1` 15889 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15890 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15891 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15892 boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1100M" 15893 JVM_ARG_OK=true 15894 else 15895 $ECHO "Arg failed:" >&5 15896 $ECHO "$OUTPUT" >&5 15897 JVM_ARG_OK=false 15898 fi 15899 15900 fi 15901 # When is adding -client something that speeds up the JVM? 15902 # ADD_JVM_ARG_IF_OK([-client],boot_jdk_jvmargs,[$JAVA]) 15903 15904 $ECHO "Check if jvm arg is ok: -XX:PermSize=32m" >&5 15905 $ECHO "Command: $JAVA -XX:PermSize=32m -version" >&5 15906 OUTPUT=`$JAVA -XX:PermSize=32m -version 2>&1` 15907 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15908 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15909 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15910 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:PermSize=32m" 15911 JVM_ARG_OK=true 15912 else 15913 $ECHO "Arg failed:" >&5 15914 $ECHO "$OUTPUT" >&5 15915 JVM_ARG_OK=false 15916 fi 15917 15918 15919 $ECHO "Check if jvm arg is ok: -XX:MaxPermSize=160m" >&5 15920 $ECHO "Command: $JAVA -XX:MaxPermSize=160m -version" >&5 15921 OUTPUT=`$JAVA -XX:MaxPermSize=160m -version 2>&1` 15922 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15923 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15924 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15925 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:MaxPermSize=160m" 15926 JVM_ARG_OK=true 15927 else 15928 $ECHO "Arg failed:" >&5 15929 $ECHO "$OUTPUT" >&5 15930 JVM_ARG_OK=false 15931 fi 15932 15933 15934 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 15935 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 15936 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 15937 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15938 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15939 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15940 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:ThreadStackSize=$STACK_SIZE" 15941 JVM_ARG_OK=true 15942 else 15943 $ECHO "Arg failed:" >&5 15944 $ECHO "$OUTPUT" >&5 15945 JVM_ARG_OK=false 15946 fi 15947 15948 # Disable special log output when a debug build is used as Boot JDK... 15949 15950 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 15951 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 15952 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 15953 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 15954 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 15955 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 15956 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 15957 JVM_ARG_OK=true 15958 else 15959 $ECHO "Arg failed:" >&5 15960 $ECHO "$OUTPUT" >&5 15961 JVM_ARG_OK=false 15962 fi 15963 15964 fi 15965 15966 BOOT_JDK_JVMARGS=$boot_jdk_jvmargs 15967 15968 15969 15970 ############################################################################### 15971 # 15972 # Configure the sources to use. We can add or override individual directories. 15973 # 15974 ############################################################################### 15975 15976 15977 15978 # Where are the sources. Any of these can be overridden 15979 # using --with-override-corba and the likes. 15980 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 15981 CORBA_TOPDIR="$SRC_ROOT/corba" 15982 JAXP_TOPDIR="$SRC_ROOT/jaxp" 15983 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 15984 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 15985 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 15986 JDK_TOPDIR="$SRC_ROOT/jdk" 15987 15988 15989 15990 15991 15992 15993 15994 15995 15996 15997 ############################################################################### 15998 # 15999 # Pickup additional source for a component from outside of the source root 16000 # or override source for a component. 16001 # 16002 16003 # Check whether --with-add-source-root was given. 16004 if test "${with_add_source_root+set}" = set; then : 16005 withval=$with_add_source_root; 16006 fi 16007 16008 16009 16010 # Check whether --with-override-source-root was given. 16011 if test "${with_override_source_root+set}" = set; then : 16012 withval=$with_override_source_root; 16013 fi 16014 16015 16016 16017 # Check whether --with-adds-and-overrides was given. 16018 if test "${with_adds_and_overrides+set}" = set; then : 16019 withval=$with_adds_and_overrides; 16020 fi 16021 16022 16023 if test "x$with_adds_and_overrides" != x; then 16024 with_add_source_root="$with_adds_and_overrides/adds" 16025 with_override_source_root="$with_adds_and_overrides/overrides" 16026 fi 16027 16028 if test "x$with_add_source_root" != x; then 16029 if ! test -d $with_add_source_root; then 16030 as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5 16031 fi 16032 CURDIR="$PWD" 16033 cd "$with_add_source_root" 16034 ADD_SRC_ROOT="`pwd`" 16035 cd "$CURDIR" 16036 # Verify that the addon source root does not have any root makefiles. 16037 # If it does, then it is usually an error, prevent this. 16038 if test -f $with_add_source_root/langtools/makefiles/Makefile || \ 16039 test -f $with_add_source_root/langtools/make/Makefile; then 16040 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 16041 fi 16042 if test -f $with_add_source_root/corba/makefiles/Makefile || \ 16043 test -f $with_add_source_root/corba/make/Makefile; then 16044 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 16045 fi 16046 if test -f $with_add_source_root/jaxp/makefiles/Makefile || \ 16047 test -f $with_add_source_root/jaxp/make/Makefile; then 16048 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 16049 fi 16050 if test -f $with_add_source_root/jaxws/makefiles/Makefile || \ 16051 test -f $with_add_source_root/jaxws/make/Makefile; then 16052 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 16053 fi 16054 if test -f $with_add_source_root/hotspot/makefiles/Makefile || \ 16055 test -f $with_add_source_root/hotspot/make/Makefile; then 16056 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 16057 fi 16058 if test -f $with_add_source_root/jdk/makefiles/Makefile || \ 16059 test -f $with_add_source_root/jdk/make/Makefile; then 16060 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 16061 fi 16062 fi 16063 16064 16065 if test "x$with_override_source_root" != x; then 16066 if ! test -d $with_override_source_root; then 16067 as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5 16068 fi 16069 CURDIR="$PWD" 16070 cd "$with_override_source_root" 16071 OVERRIDE_SRC_ROOT="`pwd`" 16072 cd "$CURDIR" 16073 if test -f $with_override_source_root/langtools/makefiles/Makefile || \ 16074 test -f $with_override_source_root/langtools/make/Makefile; then 16075 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 16076 fi 16077 if test -f $with_override_source_root/corba/makefiles/Makefile || \ 16078 test -f $with_override_source_root/corba/make/Makefile; then 16079 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 16080 fi 16081 if test -f $with_override_source_root/jaxp/makefiles/Makefile || \ 16082 test -f $with_override_source_root/jaxp/make/Makefile; then 16083 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 16084 fi 16085 if test -f $with_override_source_root/jaxws/makefiles/Makefile || \ 16086 test -f $with_override_source_root/jaxws/make/Makefile; then 16087 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 16088 fi 16089 if test -f $with_override_source_root/hotspot/makefiles/Makefile || \ 16090 test -f $with_override_source_root/hotspot/make/Makefile; then 16091 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 16092 fi 16093 if test -f $with_override_source_root/jdk/makefiles/Makefile || \ 16094 test -f $with_override_source_root/jdk/make/Makefile; then 16095 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 16096 fi 16097 fi 16098 16099 16100 ############################################################################### 16101 # 16102 # Override a repo completely, this is used for example when you have 3 small 16103 # development sandboxes of the langtools sources and want to avoid having 3 full 16104 # OpenJDK sources checked out on disk. 16105 # 16106 # Assuming that the 3 langtools sandboxes are located here: 16107 # /home/fredrik/sandbox1/langtools 16108 # /home/fredrik/sandbox2/langtools 16109 # /home/fredrik/sandbox3/langtools 16110 # 16111 # From the source root you create build subdirs manually: 16112 # mkdir -p build1 build2 build3 16113 # in each build directory run: 16114 # (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make) 16115 # (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make) 16116 # (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make) 16117 # 16118 16119 16120 # Check whether --with-override-langtools was given. 16121 if test "${with_override_langtools+set}" = set; then : 16122 withval=$with_override_langtools; 16123 fi 16124 16125 16126 16127 # Check whether --with-override-corba was given. 16128 if test "${with_override_corba+set}" = set; then : 16129 withval=$with_override_corba; 16130 fi 16131 16132 16133 16134 # Check whether --with-override-jaxp was given. 16135 if test "${with_override_jaxp+set}" = set; then : 16136 withval=$with_override_jaxp; 16137 fi 16138 16139 16140 16141 # Check whether --with-override-jaxws was given. 16142 if test "${with_override_jaxws+set}" = set; then : 16143 withval=$with_override_jaxws; 16144 fi 16145 16146 16147 16148 # Check whether --with-override-hotspot was given. 16149 if test "${with_override_hotspot+set}" = set; then : 16150 withval=$with_override_hotspot; 16151 fi 16152 16153 16154 16155 # Check whether --with-override-jdk was given. 16156 if test "${with_override_jdk+set}" = set; then : 16157 withval=$with_override_jdk; 16158 fi 16159 16160 16161 if test "x$with_override_langtools" != x; then 16162 CURDIR="$PWD" 16163 cd "$with_override_langtools" 16164 LANGTOOLS_TOPDIR="`pwd`" 16165 cd "$CURDIR" 16166 if ! test -f $LANGTOOLS_TOPDIR/makefiles/Makefile; then 16167 as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5 16168 fi 16169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5 16170 $as_echo_n "checking if langtools should be overridden... " >&6; } 16171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5 16172 $as_echo "yes with $LANGTOOLS_TOPDIR" >&6; } 16173 fi 16174 if test "x$with_override_corba" != x; then 16175 CURDIR="$PWD" 16176 cd "$with_override_corba" 16177 CORBA_TOPDIR="`pwd`" 16178 cd "$CURDIR" 16179 if ! test -f $CORBA_TOPDIR/makefiles/Makefile; then 16180 as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5 16181 fi 16182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5 16183 $as_echo_n "checking if corba should be overridden... " >&6; } 16184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5 16185 $as_echo "yes with $CORBA_TOPDIR" >&6; } 16186 fi 16187 if test "x$with_override_jaxp" != x; then 16188 CURDIR="$PWD" 16189 cd "$with_override_jaxp" 16190 JAXP_TOPDIR="`pwd`" 16191 cd "$CURDIR" 16192 if ! test -f $JAXP_TOPDIR/makefiles/Makefile; then 16193 as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5 16194 fi 16195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5 16196 $as_echo_n "checking if jaxp should be overridden... " >&6; } 16197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5 16198 $as_echo "yes with $JAXP_TOPDIR" >&6; } 16199 fi 16200 if test "x$with_override_jaxws" != x; then 16201 CURDIR="$PWD" 16202 cd "$with_override_jaxws" 16203 JAXWS_TOPDIR="`pwd`" 16204 cd "$CURDIR" 16205 if ! test -f $JAXWS_TOPDIR/makefiles/Makefile; then 16206 as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5 16207 fi 16208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5 16209 $as_echo_n "checking if jaxws should be overridden... " >&6; } 16210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5 16211 $as_echo "yes with $JAXWS_TOPDIR" >&6; } 16212 fi 16213 if test "x$with_override_hotspot" != x; then 16214 CURDIR="$PWD" 16215 cd "$with_override_hotspot" 16216 HOTSPOT_TOPDIR="`pwd`" 16217 cd "$CURDIR" 16218 if ! test -f $HOTSPOT_TOPDIR/make/Makefile && \ 16219 ! test -f $HOTSPOT_TOPDIR/makefiles/Makefile; then 16220 as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5 16221 fi 16222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5 16223 $as_echo_n "checking if hotspot should be overridden... " >&6; } 16224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5 16225 $as_echo "yes with $HOTSPOT_TOPDIR" >&6; } 16226 fi 16227 if test "x$with_override_nashorn" != x; then 16228 CURDIR="$PWD" 16229 cd "$with_override_nashorn" 16230 NASHORN_TOPDIR="`pwd`" 16231 cd "$CURDIR" 16232 if ! test -f $NASHORN_TOPDIR/makefiles/BuildNashorn.gmk; then 16233 as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5 16234 fi 16235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5 16236 $as_echo_n "checking if nashorn should be overridden... " >&6; } 16237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5 16238 $as_echo "yes with $NASHORN_TOPDIR" >&6; } 16239 fi 16240 if test "x$with_override_jdk" != x; then 16241 CURDIR="$PWD" 16242 cd "$with_override_jdk" 16243 JDK_TOPDIR="`pwd`" 16244 cd "$CURDIR" 16245 if ! test -f $JDK_TOPDIR/makefiles/Makefile; then 16246 as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5 16247 fi 16248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5 16249 $as_echo_n "checking if JDK should be overridden... " >&6; } 16250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5 16251 $as_echo "yes with $JDK_TOPDIR" >&6; } 16252 fi 16253 16254 16255 16256 BUILD_OUTPUT="$OUTPUT_ROOT" 16257 16258 16259 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 16260 BUILD_HOTSPOT=true 16261 16262 16263 16264 # Check whether --with-import-hotspot was given. 16265 if test "${with_import_hotspot+set}" = set; then : 16266 withval=$with_import_hotspot; 16267 fi 16268 16269 if test "x$with_import_hotspot" != x; then 16270 CURDIR="$PWD" 16271 cd "$with_import_hotspot" 16272 HOTSPOT_DIST="`pwd`" 16273 cd "$CURDIR" 16274 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 16275 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 16276 fi 16277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 16278 $as_echo_n "checking if hotspot should be imported... " >&6; } 16279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 16280 $as_echo "yes from $HOTSPOT_DIST" >&6; } 16281 BUILD_HOTSPOT=false 16282 fi 16283 16284 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 16285 16286 16287 ############################################################################### 16288 # 16289 # Setup the toolchain (compilers etc), i.e. the tools that need to be 16290 # cross-compilation aware. 16291 # 16292 ############################################################################### 16293 16294 16295 ############################################################################### 16296 # 16297 # Configure the development tool paths and potential sysroot. 16298 # 16299 ac_ext=cpp 16300 ac_cpp='$CXXCPP $CPPFLAGS' 16301 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 16302 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 16303 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 16304 16305 16306 # The option used to specify the target .o,.a or .so file. 16307 # When compiling, how to specify the to be created object file. 16308 CC_OUT_OPTION='-o$(SPACE)' 16309 # When linking, how to specify the to be created executable. 16310 EXE_OUT_OPTION='-o$(SPACE)' 16311 # When linking, how to specify the to be created dynamically linkable library. 16312 LD_OUT_OPTION='-o$(SPACE)' 16313 # When archiving, how to specify the to be create static archive for object files. 16314 AR_OUT_OPTION='rcs$(SPACE)' 16315 16316 16317 16318 16319 16320 # Locate the actual tools 16321 16322 16323 # Check whether --with-jtreg was given. 16324 if test "${with_jtreg+set}" = set; then : 16325 withval=$with_jtreg; 16326 else 16327 with_jtreg=no 16328 fi 16329 16330 16331 if test "x$with_jtreg" = xno; then 16332 # jtreg disabled 16333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 16334 $as_echo_n "checking for jtreg... " >&6; } 16335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16336 $as_echo "no" >&6; } 16337 else 16338 if test "x$with_jtreg" != xyes; then 16339 # with path specified. 16340 JT_HOME="$with_jtreg" 16341 fi 16342 16343 if test "x$JT_HOME" != x; then 16344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 16345 $as_echo_n "checking for jtreg... " >&6; } 16346 16347 # use JT_HOME enviroment var. 16348 16349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16350 16351 # Input might be given as Windows format, start by converting to 16352 # unix format. 16353 path="$JT_HOME" 16354 new_path=`$CYGPATH -u "$path"` 16355 16356 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16357 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16358 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16359 # "foo.exe" is OK but "foo" is an error. 16360 # 16361 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16362 # It is also a way to make sure we got the proper file name for the real test later on. 16363 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16364 if test "x$test_shortpath" = x; then 16365 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 16366 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 16367 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 16368 fi 16369 16370 # Call helper function which possibly converts this using DOS-style short mode. 16371 # If so, the updated path is stored in $new_path. 16372 16373 input_path="$new_path" 16374 # Check if we need to convert this using DOS-style short mode. If the path 16375 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16376 # take no chances and rewrite it. 16377 # Note: m4 eats our [], so we need to use [ and ] instead. 16378 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16379 if test "x$has_forbidden_chars" != x; then 16380 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16381 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16382 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16383 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16384 # Going to short mode and back again did indeed matter. Since short mode is 16385 # case insensitive, let's make it lowercase to improve readability. 16386 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16387 # Now convert it back to Unix-stile (cygpath) 16388 input_path=`$CYGPATH -u "$shortmode_path"` 16389 new_path="$input_path" 16390 fi 16391 fi 16392 16393 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16394 if test "x$test_cygdrive_prefix" = x; then 16395 # As a simple fix, exclude /usr/bin since it's not a real path. 16396 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16397 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16398 # a path prefixed by /cygdrive for fixpath to work. 16399 new_path="$CYGWIN_ROOT_PATH$input_path" 16400 fi 16401 fi 16402 16403 16404 if test "x$path" != "x$new_path"; then 16405 JT_HOME="$new_path" 16406 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 16407 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 16408 fi 16409 16410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16411 16412 path="$JT_HOME" 16413 has_colon=`$ECHO $path | $GREP ^.:` 16414 new_path="$path" 16415 if test "x$has_colon" = x; then 16416 # Not in mixed or Windows style, start by that. 16417 new_path=`cmd //c echo $path` 16418 fi 16419 16420 16421 input_path="$new_path" 16422 # Check if we need to convert this using DOS-style short mode. If the path 16423 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16424 # take no chances and rewrite it. 16425 # Note: m4 eats our [], so we need to use [ and ] instead. 16426 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16427 if test "x$has_forbidden_chars" != x; then 16428 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16429 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16430 fi 16431 16432 16433 windows_path="$new_path" 16434 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16435 unix_path=`$CYGPATH -u "$windows_path"` 16436 new_path="$unix_path" 16437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16438 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16439 new_path="$unix_path" 16440 fi 16441 16442 if test "x$path" != "x$new_path"; then 16443 JT_HOME="$new_path" 16444 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 16445 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 16446 fi 16447 16448 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16449 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16450 16451 else 16452 # We're on a posix platform. Hooray! :) 16453 path="$JT_HOME" 16454 has_space=`$ECHO "$path" | $GREP " "` 16455 if test "x$has_space" != x; then 16456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 16457 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 16458 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16459 fi 16460 16461 # Use eval to expand a potential ~ 16462 eval path="$path" 16463 if test ! -f "$path" && test ! -d "$path"; then 16464 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 16465 fi 16466 16467 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 16468 fi 16469 16470 16471 # jtreg win32 script works for everybody 16472 JTREGEXE="$JT_HOME/win32/bin/jtreg" 16473 16474 if test ! -f "$JTREGEXE"; then 16475 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 16476 fi 16477 16478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 16479 $as_echo "$JTREGEXE" >&6; } 16480 else 16481 # try to find jtreg on path 16482 16483 for ac_prog in jtreg 16484 do 16485 # Extract the first word of "$ac_prog", so it can be a program name with args. 16486 set dummy $ac_prog; ac_word=$2 16487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16488 $as_echo_n "checking for $ac_word... " >&6; } 16489 if ${ac_cv_path_JTREGEXE+:} false; then : 16490 $as_echo_n "(cached) " >&6 16491 else 16492 case $JTREGEXE in 16493 [\\/]* | ?:[\\/]*) 16494 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 16495 ;; 16496 *) 16497 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16498 for as_dir in $PATH 16499 do 16500 IFS=$as_save_IFS 16501 test -z "$as_dir" && as_dir=. 16502 for ac_exec_ext in '' $ac_executable_extensions; do 16503 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 16504 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 16505 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 16506 break 2 16507 fi 16508 done 16509 done 16510 IFS=$as_save_IFS 16511 16512 ;; 16513 esac 16514 fi 16515 JTREGEXE=$ac_cv_path_JTREGEXE 16516 if test -n "$JTREGEXE"; then 16517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 16518 $as_echo "$JTREGEXE" >&6; } 16519 else 16520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16521 $as_echo "no" >&6; } 16522 fi 16523 16524 16525 test -n "$JTREGEXE" && break 16526 done 16527 16528 16529 if test "x$JTREGEXE" = x; then 16530 if test "xjtreg" = x; then 16531 PROG_NAME=jtregexe 16532 else 16533 PROG_NAME=jtreg 16534 fi 16535 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $PROG_NAME!" >&5 16536 $as_echo "$as_me: Could not find $PROG_NAME!" >&6;} 16537 as_fn_error $? "Cannot continue" "$LINENO" 5 16538 fi 16539 16540 16541 JT_HOME="`$DIRNAME $JTREGEXE`" 16542 fi 16543 fi 16544 16545 16546 16547 16548 16549 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16550 16551 # Store path to cygwin link.exe to help excluding it when searching for 16552 # VS linker. This must be done before changing the PATH when looking for VS. 16553 # Extract the first word of "link", so it can be a program name with args. 16554 set dummy link; ac_word=$2 16555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16556 $as_echo_n "checking for $ac_word... " >&6; } 16557 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 16558 $as_echo_n "(cached) " >&6 16559 else 16560 case $CYGWIN_LINK in 16561 [\\/]* | ?:[\\/]*) 16562 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 16563 ;; 16564 *) 16565 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16566 for as_dir in $PATH 16567 do 16568 IFS=$as_save_IFS 16569 test -z "$as_dir" && as_dir=. 16570 for ac_exec_ext in '' $ac_executable_extensions; do 16571 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 16572 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 16573 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 16574 break 2 16575 fi 16576 done 16577 done 16578 IFS=$as_save_IFS 16579 16580 ;; 16581 esac 16582 fi 16583 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 16584 if test -n "$CYGWIN_LINK"; then 16585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 16586 $as_echo "$CYGWIN_LINK" >&6; } 16587 else 16588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16589 $as_echo "no" >&6; } 16590 fi 16591 16592 16593 if test "x$CYGWIN_LINK" != x; then 16594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 16595 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 16596 "$CYGWIN_LINK" --version > /dev/null 16597 if test $? -eq 0 ; then 16598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 16599 $as_echo "yes" >&6; } 16600 else 16601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16602 $as_echo "no" >&6; } 16603 # This might be the VS linker. Don't exclude it later on. 16604 CYGWIN_LINK="" 16605 fi 16606 fi 16607 16608 # First-hand choice is to locate and run the vsvars bat file. 16609 16610 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16611 VCVARSFILE="vc/bin/vcvars32.bat" 16612 else 16613 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 16614 fi 16615 16616 VS_ENV_CMD="" 16617 VS_ENV_ARGS="" 16618 if test "x$with_toolsdir" != x; then 16619 16620 if test "x$VS_ENV_CMD" = x; then 16621 VS100BASE="$with_toolsdir/../.." 16622 METHOD="--with-tools-dir" 16623 16624 windows_path="$VS100BASE" 16625 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16626 unix_path=`$CYGPATH -u "$windows_path"` 16627 VS100BASE="$unix_path" 16628 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16629 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16630 VS100BASE="$unix_path" 16631 fi 16632 16633 if test -d "$VS100BASE"; then 16634 if test -f "$VS100BASE/$VCVARSFILE"; then 16635 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16636 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16637 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 16638 else 16639 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16640 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16641 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 16642 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 16643 fi 16644 fi 16645 fi 16646 16647 fi 16648 16649 if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then 16650 # Having specified an argument which is incorrect will produce an instant failure; 16651 # we should not go on looking 16652 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5 16653 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;} 16654 { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5 16655 $as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;} 16656 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 16657 fi 16658 16659 if test "x$VS100COMNTOOLS" != x; then 16660 16661 if test "x$VS_ENV_CMD" = x; then 16662 VS100BASE="$VS100COMNTOOLS/../.." 16663 METHOD="VS100COMNTOOLS variable" 16664 16665 windows_path="$VS100BASE" 16666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16667 unix_path=`$CYGPATH -u "$windows_path"` 16668 VS100BASE="$unix_path" 16669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16670 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16671 VS100BASE="$unix_path" 16672 fi 16673 16674 if test -d "$VS100BASE"; then 16675 if test -f "$VS100BASE/$VCVARSFILE"; then 16676 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16677 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16678 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 16679 else 16680 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16681 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16682 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 16683 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 16684 fi 16685 fi 16686 fi 16687 16688 fi 16689 if test "x$PROGRAMFILES" != x; then 16690 16691 if test "x$VS_ENV_CMD" = x; then 16692 VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0" 16693 METHOD="well-known name" 16694 16695 windows_path="$VS100BASE" 16696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16697 unix_path=`$CYGPATH -u "$windows_path"` 16698 VS100BASE="$unix_path" 16699 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16700 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16701 VS100BASE="$unix_path" 16702 fi 16703 16704 if test -d "$VS100BASE"; then 16705 if test -f "$VS100BASE/$VCVARSFILE"; then 16706 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16707 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16708 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 16709 else 16710 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16711 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16712 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 16713 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 16714 fi 16715 fi 16716 fi 16717 16718 fi 16719 16720 if test "x$VS_ENV_CMD" = x; then 16721 VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0" 16722 METHOD="well-known name" 16723 16724 windows_path="$VS100BASE" 16725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16726 unix_path=`$CYGPATH -u "$windows_path"` 16727 VS100BASE="$unix_path" 16728 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16729 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16730 VS100BASE="$unix_path" 16731 fi 16732 16733 if test -d "$VS100BASE"; then 16734 if test -f "$VS100BASE/$VCVARSFILE"; then 16735 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16736 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16737 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 16738 else 16739 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16740 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16741 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 16742 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 16743 fi 16744 fi 16745 fi 16746 16747 16748 if test "x$VS_ENV_CMD" = x; then 16749 VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0" 16750 METHOD="well-known name" 16751 16752 windows_path="$VS100BASE" 16753 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16754 unix_path=`$CYGPATH -u "$windows_path"` 16755 VS100BASE="$unix_path" 16756 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16757 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16758 VS100BASE="$unix_path" 16759 fi 16760 16761 if test -d "$VS100BASE"; then 16762 if test -f "$VS100BASE/$VCVARSFILE"; then 16763 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16764 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16765 VS_ENV_CMD="$VS100BASE/$VCVARSFILE" 16766 else 16767 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5 16768 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;} 16769 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 16770 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 16771 fi 16772 fi 16773 fi 16774 16775 16776 if test "x$ProgramW6432" != x; then 16777 16778 if test "x$VS_ENV_CMD" = x; then 16779 WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin" 16780 METHOD="well-known name" 16781 16782 windows_path="$WIN_SDK_BASE" 16783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16784 unix_path=`$CYGPATH -u "$windows_path"` 16785 WIN_SDK_BASE="$unix_path" 16786 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16787 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16788 WIN_SDK_BASE="$unix_path" 16789 fi 16790 16791 if test -d "$WIN_SDK_BASE"; then 16792 # There have been cases of partial or broken SDK installations. A missing 16793 # lib dir is not going to work. 16794 if test ! -d "$WIN_SDK_BASE/../lib"; then 16795 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16796 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16797 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 16798 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 16799 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 16800 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16801 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16802 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 16803 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16804 VS_ENV_ARGS="/x86" 16805 else 16806 VS_ENV_ARGS="/x64" 16807 fi 16808 else 16809 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16810 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16811 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 16812 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 16813 fi 16814 fi 16815 fi 16816 16817 fi 16818 if test "x$PROGRAMW6432" != x; then 16819 16820 if test "x$VS_ENV_CMD" = x; then 16821 WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin" 16822 METHOD="well-known name" 16823 16824 windows_path="$WIN_SDK_BASE" 16825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16826 unix_path=`$CYGPATH -u "$windows_path"` 16827 WIN_SDK_BASE="$unix_path" 16828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16829 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16830 WIN_SDK_BASE="$unix_path" 16831 fi 16832 16833 if test -d "$WIN_SDK_BASE"; then 16834 # There have been cases of partial or broken SDK installations. A missing 16835 # lib dir is not going to work. 16836 if test ! -d "$WIN_SDK_BASE/../lib"; then 16837 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16838 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16839 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 16840 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 16841 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 16842 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16843 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16844 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 16845 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16846 VS_ENV_ARGS="/x86" 16847 else 16848 VS_ENV_ARGS="/x64" 16849 fi 16850 else 16851 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16852 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16853 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 16854 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 16855 fi 16856 fi 16857 fi 16858 16859 fi 16860 if test "x$PROGRAMFILES" != x; then 16861 16862 if test "x$VS_ENV_CMD" = x; then 16863 WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin" 16864 METHOD="well-known name" 16865 16866 windows_path="$WIN_SDK_BASE" 16867 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16868 unix_path=`$CYGPATH -u "$windows_path"` 16869 WIN_SDK_BASE="$unix_path" 16870 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16871 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16872 WIN_SDK_BASE="$unix_path" 16873 fi 16874 16875 if test -d "$WIN_SDK_BASE"; then 16876 # There have been cases of partial or broken SDK installations. A missing 16877 # lib dir is not going to work. 16878 if test ! -d "$WIN_SDK_BASE/../lib"; then 16879 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16880 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16881 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 16882 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 16883 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 16884 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16885 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16886 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 16887 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16888 VS_ENV_ARGS="/x86" 16889 else 16890 VS_ENV_ARGS="/x64" 16891 fi 16892 else 16893 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16894 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16895 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 16896 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 16897 fi 16898 fi 16899 fi 16900 16901 fi 16902 16903 if test "x$VS_ENV_CMD" = x; then 16904 WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin" 16905 METHOD="well-known name" 16906 16907 windows_path="$WIN_SDK_BASE" 16908 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16909 unix_path=`$CYGPATH -u "$windows_path"` 16910 WIN_SDK_BASE="$unix_path" 16911 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16912 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16913 WIN_SDK_BASE="$unix_path" 16914 fi 16915 16916 if test -d "$WIN_SDK_BASE"; then 16917 # There have been cases of partial or broken SDK installations. A missing 16918 # lib dir is not going to work. 16919 if test ! -d "$WIN_SDK_BASE/../lib"; then 16920 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16921 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16922 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 16923 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 16924 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 16925 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16926 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16927 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 16928 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16929 VS_ENV_ARGS="/x86" 16930 else 16931 VS_ENV_ARGS="/x64" 16932 fi 16933 else 16934 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16935 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16936 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 16937 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 16938 fi 16939 fi 16940 fi 16941 16942 16943 if test "x$VS_ENV_CMD" = x; then 16944 WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin" 16945 METHOD="well-known name" 16946 16947 windows_path="$WIN_SDK_BASE" 16948 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16949 unix_path=`$CYGPATH -u "$windows_path"` 16950 WIN_SDK_BASE="$unix_path" 16951 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16952 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16953 WIN_SDK_BASE="$unix_path" 16954 fi 16955 16956 if test -d "$WIN_SDK_BASE"; then 16957 # There have been cases of partial or broken SDK installations. A missing 16958 # lib dir is not going to work. 16959 if test ! -d "$WIN_SDK_BASE/../lib"; then 16960 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16961 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16962 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 16963 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 16964 elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then 16965 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16966 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16967 VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd" 16968 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16969 VS_ENV_ARGS="/x86" 16970 else 16971 VS_ENV_ARGS="/x64" 16972 fi 16973 else 16974 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 16975 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 16976 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 16977 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 16978 fi 16979 fi 16980 fi 16981 16982 16983 if test "x$VS_ENV_CMD" != x; then 16984 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 16985 16986 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16987 16988 # First separate the path from the arguments. This will split at the first 16989 # space. 16990 complete="$VS_ENV_CMD" 16991 path="${complete%% *}" 16992 tmp="$complete EOL" 16993 arguments="${tmp#* }" 16994 16995 # Input might be given as Windows format, start by converting to 16996 # unix format. 16997 new_path=`$CYGPATH -u "$path"` 16998 16999 # Now try to locate executable using which 17000 new_path=`$WHICH "$new_path" 2> /dev/null` 17001 # bat and cmd files are not always considered executable in cygwin causing which 17002 # to not find them 17003 if test "x$new_path" = x \ 17004 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17005 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17006 new_path=`$CYGPATH -u "$path"` 17007 fi 17008 if test "x$new_path" = x; then 17009 # Oops. Which didn't find the executable. 17010 # The splitting of arguments from the executable at a space might have been incorrect, 17011 # since paths with space are more likely in Windows. Give it another try with the whole 17012 # argument. 17013 path="$complete" 17014 arguments="EOL" 17015 new_path=`$CYGPATH -u "$path"` 17016 new_path=`$WHICH "$new_path" 2> /dev/null` 17017 # bat and cmd files are not always considered executable in cygwin causing which 17018 # to not find them 17019 if test "x$new_path" = x \ 17020 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17021 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17022 new_path=`$CYGPATH -u "$path"` 17023 fi 17024 if test "x$new_path" = x; then 17025 # It's still not found. Now this is an unrecoverable error. 17026 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17027 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17028 has_space=`$ECHO "$complete" | $GREP " "` 17029 if test "x$has_space" != x; then 17030 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17031 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17032 fi 17033 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17034 fi 17035 fi 17036 17037 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17038 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17039 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17040 # "foo.exe" is OK but "foo" is an error. 17041 # 17042 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17043 # It is also a way to make sure we got the proper file name for the real test later on. 17044 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17045 if test "x$test_shortpath" = x; then 17046 # Short path failed, file does not exist as specified. 17047 # Try adding .exe or .cmd 17048 if test -f "${new_path}.exe"; then 17049 input_to_shortpath="${new_path}.exe" 17050 elif test -f "${new_path}.cmd"; then 17051 input_to_shortpath="${new_path}.cmd" 17052 else 17053 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 17054 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 17055 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17056 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17057 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17058 fi 17059 else 17060 input_to_shortpath="$new_path" 17061 fi 17062 17063 # Call helper function which possibly converts this using DOS-style short mode. 17064 # If so, the updated path is stored in $new_path. 17065 new_path="$input_to_shortpath" 17066 17067 input_path="$input_to_shortpath" 17068 # Check if we need to convert this using DOS-style short mode. If the path 17069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17070 # take no chances and rewrite it. 17071 # Note: m4 eats our [], so we need to use [ and ] instead. 17072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17073 if test "x$has_forbidden_chars" != x; then 17074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17075 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17076 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17077 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17078 # Going to short mode and back again did indeed matter. Since short mode is 17079 # case insensitive, let's make it lowercase to improve readability. 17080 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17081 # Now convert it back to Unix-stile (cygpath) 17082 input_path=`$CYGPATH -u "$shortmode_path"` 17083 new_path="$input_path" 17084 fi 17085 fi 17086 17087 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17088 if test "x$test_cygdrive_prefix" = x; then 17089 # As a simple fix, exclude /usr/bin since it's not a real path. 17090 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17091 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17092 # a path prefixed by /cygdrive for fixpath to work. 17093 new_path="$CYGWIN_ROOT_PATH$input_path" 17094 fi 17095 fi 17096 17097 # remove trailing .exe if any 17098 new_path="${new_path/%.exe/}" 17099 17100 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17101 17102 # First separate the path from the arguments. This will split at the first 17103 # space. 17104 complete="$VS_ENV_CMD" 17105 path="${complete%% *}" 17106 tmp="$complete EOL" 17107 arguments="${tmp#* }" 17108 17109 # Input might be given as Windows format, start by converting to 17110 # unix format. 17111 new_path="$path" 17112 17113 windows_path="$new_path" 17114 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17115 unix_path=`$CYGPATH -u "$windows_path"` 17116 new_path="$unix_path" 17117 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17118 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17119 new_path="$unix_path" 17120 fi 17121 17122 17123 # Now try to locate executable using which 17124 new_path=`$WHICH "$new_path" 2> /dev/null` 17125 17126 if test "x$new_path" = x; then 17127 # Oops. Which didn't find the executable. 17128 # The splitting of arguments from the executable at a space might have been incorrect, 17129 # since paths with space are more likely in Windows. Give it another try with the whole 17130 # argument. 17131 path="$complete" 17132 arguments="EOL" 17133 new_path="$path" 17134 17135 windows_path="$new_path" 17136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17137 unix_path=`$CYGPATH -u "$windows_path"` 17138 new_path="$unix_path" 17139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17140 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17141 new_path="$unix_path" 17142 fi 17143 17144 17145 new_path=`$WHICH "$new_path" 2> /dev/null` 17146 17147 if test "x$new_path" = x; then 17148 # It's still not found. Now this is an unrecoverable error. 17149 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17150 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17151 has_space=`$ECHO "$complete" | $GREP " "` 17152 if test "x$has_space" != x; then 17153 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17154 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17155 fi 17156 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17157 fi 17158 fi 17159 17160 # Now new_path has a complete unix path to the binary 17161 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17162 # Keep paths in /bin as-is, but remove trailing .exe if any 17163 new_path="${new_path/%.exe/}" 17164 # Do not save /bin paths to all_fixpath_prefixes! 17165 else 17166 # Not in mixed or Windows style, start by that. 17167 new_path=`cmd //c echo $new_path` 17168 17169 input_path="$new_path" 17170 # Check if we need to convert this using DOS-style short mode. If the path 17171 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17172 # take no chances and rewrite it. 17173 # Note: m4 eats our [], so we need to use [ and ] instead. 17174 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17175 if test "x$has_forbidden_chars" != x; then 17176 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17177 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17178 fi 17179 17180 # Output is in $new_path 17181 17182 windows_path="$new_path" 17183 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17184 unix_path=`$CYGPATH -u "$windows_path"` 17185 new_path="$unix_path" 17186 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17187 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17188 new_path="$unix_path" 17189 fi 17190 17191 # remove trailing .exe if any 17192 new_path="${new_path/%.exe/}" 17193 17194 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17195 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17196 fi 17197 17198 else 17199 # We're on a posix platform. Hooray! :) 17200 # First separate the path from the arguments. This will split at the first 17201 # space. 17202 complete="$VS_ENV_CMD" 17203 path="${complete%% *}" 17204 tmp="$complete EOL" 17205 arguments="${tmp#* }" 17206 17207 # Cannot rely on the command "which" here since it doesn't always work. 17208 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17209 if test -z "$is_absolute_path"; then 17210 # Path to executable is not absolute. Find it. 17211 IFS_save="$IFS" 17212 IFS=: 17213 for p in $PATH; do 17214 if test -f "$p/$path" && test -x "$p/$path"; then 17215 new_path="$p/$path" 17216 break 17217 fi 17218 done 17219 IFS="$IFS_save" 17220 else 17221 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&5 17222 $as_echo "$as_me: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&6;} 17223 new_path="$path" 17224 fi 17225 17226 if test "x$new_path" = x; then 17227 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 17228 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 17229 has_space=`$ECHO "$complete" | $GREP " "` 17230 if test "x$has_space" != x; then 17231 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17232 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17233 fi 17234 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 17235 fi 17236 fi 17237 17238 # Now join together the path and the arguments once again 17239 if test "x$arguments" != xEOL; then 17240 new_complete="$new_path ${arguments% *}" 17241 else 17242 new_complete="$new_path" 17243 fi 17244 17245 if test "x$complete" != "x$new_complete"; then 17246 VS_ENV_CMD="$new_complete" 17247 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 17248 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 17249 fi 17250 17251 17252 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 17253 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 17254 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 17255 cd $OUTPUT_ROOT 17256 # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted 17257 # to autoconf standards. 17258 17259 #---- 17260 17261 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment) 17262 # but calculate the difference in Cygwin environment before/after running it and then 17263 # apply the diff. 17264 17265 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 17266 _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"` 17267 _dosvs10varsall=`cygpath -a -w -s $_vs10varsall` 17268 _dosbash=`cygpath -a -w -s \`which bash\`.*` 17269 else 17270 _dosvs10varsall=`cmd //c echo $VS_ENV_CMD` 17271 _dosbash=`cmd //c echo \`which bash\`` 17272 fi 17273 17274 # generate the set of exported vars before/after the vs10 setup 17275 $ECHO "@echo off" > localdevenvtmp.bat 17276 $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat 17277 $ECHO "call $_dosvs10varsall $VS_ENV_ARGS" >> localdevenvtmp.bat 17278 $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat 17279 17280 # Now execute the newly created bat file. 17281 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys 17282 cmd /c localdevenvtmp.bat | cat 17283 17284 # apply the diff (less some non-vs10 vars named by "!") 17285 $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort 17286 $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort 17287 $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh 17288 17289 # cleanup 17290 $RM localdevenvtmp* 17291 #---- 17292 cd $CURDIR 17293 if test ! -s $OUTPUT_ROOT/localdevenv.sh; then 17294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17295 $as_echo "no" >&6; } 17296 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 17297 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 17298 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 17299 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 17300 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 17301 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 17302 as_fn_error $? "Cannot continue" "$LINENO" 5 17303 fi 17304 17305 # Now set all paths and other env variables. This will allow the rest of 17306 # the configure script to find and run the compiler in the proper way. 17307 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 17308 $as_echo "$as_me: Setting extracted environment variables" >&6;} 17309 . $OUTPUT_ROOT/localdevenv.sh 17310 else 17311 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 17312 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 17313 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 17314 fi 17315 17316 # At this point, we should have corrent variables in the environment, or we can't continue. 17317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 17318 $as_echo_n "checking for Visual Studio variables... " >&6; } 17319 17320 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then 17321 if test "x$INCLUDE" = x || test "x$LIB" = x; then 17322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 17323 $as_echo "present but broken" >&6; } 17324 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 17325 else 17326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 17327 $as_echo "ok" >&6; } 17328 # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk. 17329 VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'` 17330 VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'` 17331 # Remove any paths containing # (typically F#) as that messes up make 17332 PATH=`$ECHO "$PATH" | $SED 's/[^:#]*#[^:]*://g'` 17333 VS_PATH="$PATH" 17334 17335 17336 17337 fi 17338 else 17339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 17340 $as_echo "not found" >&6; } 17341 17342 if test "x$VS_ENV_CMD" = x; then 17343 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 17344 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 17345 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 17346 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 17347 else 17348 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 17349 $as_echo "$as_me: Running the extraction script failed." >&6;} 17350 fi 17351 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 17352 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 17353 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 17354 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 17355 as_fn_error $? "Cannot continue" "$LINENO" 5 17356 fi 17357 17358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5 17359 $as_echo_n "checking for msvcr100.dll... " >&6; } 17360 17361 # Check whether --with-msvcr-dll was given. 17362 if test "${with_msvcr_dll+set}" = set; then : 17363 withval=$with_msvcr_dll; 17364 fi 17365 17366 if test "x$with_msvcr_dll" != x; then 17367 MSVCR_DLL="$with_msvcr_dll" 17368 else 17369 if test "x$VCINSTALLDIR" != x; then 17370 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 17371 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | grep x64 | head --lines 1` 17372 else 17373 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | grep x86 | grep -v ia64 | grep -v x64 | head --lines 1` 17374 if test "x$MSVCR_DLL" = x; then 17375 MSVCR_DLL=`find "$VCINSTALLDIR" -name msvcr100.dll | head --lines 1` 17376 fi 17377 fi 17378 if test "x$MSVCR_DLL" != x; then 17379 { $as_echo "$as_me:${as_lineno-$LINENO}: msvcr100.dll found in VCINSTALLDIR: $VCINSTALLDIR" >&5 17380 $as_echo "$as_me: msvcr100.dll found in VCINSTALLDIR: $VCINSTALLDIR" >&6;} 17381 else 17382 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: msvcr100.dll not found in VCINSTALLDIR: $VCINSTALLDIR" >&5 17383 $as_echo "$as_me: Warning: msvcr100.dll not found in VCINSTALLDIR: $VCINSTALLDIR" >&6;} 17384 fi 17385 fi 17386 # Try some fallback alternatives 17387 if test "x$MSVCR_DLL" = x; then 17388 # If visual studio express is installed, there is usually one with the debugger 17389 if test "x$VS100COMNTOOLS" != x; then 17390 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 17391 MSVCR_DLL=`find "$VS100COMNTOOLS/.." -name msvcr100.dll | grep -i x64 | head --lines 1` 17392 { $as_echo "$as_me:${as_lineno-$LINENO}: msvcr100.dll found in $VS100COMNTOOLS..: $VS100COMNTOOLS.." >&5 17393 $as_echo "$as_me: msvcr100.dll found in $VS100COMNTOOLS..: $VS100COMNTOOLS.." >&6;} 17394 fi 17395 fi 17396 fi 17397 if test "x$MSVCR_DLL" = x; then 17398 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 17399 # Fallback for 32bit builds, look in the windows directory. 17400 if test -f "$SYSTEMROOT/system32/msvcr100.dll"; then 17401 { $as_echo "$as_me:${as_lineno-$LINENO}: msvcr100.dll found in $SYSTEMROOT/system32" >&5 17402 $as_echo "$as_me: msvcr100.dll found in $SYSTEMROOT/system32" >&6;} 17403 MSVCR_DLL="$SYSTEMROOT/system32/msvcr100.dll" 17404 fi 17405 fi 17406 fi 17407 fi 17408 if test "x$MSVCR_DLL" = x; then 17409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17410 $as_echo "no" >&6; } 17411 as_fn_error $? "Could not find msvcr100.dll !" "$LINENO" 5 17412 fi 17413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5 17414 $as_echo "$MSVCR_DLL" >&6; } 17415 17416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17417 17418 # Input might be given as Windows format, start by converting to 17419 # unix format. 17420 path="$MSVCR_DLL" 17421 new_path=`$CYGPATH -u "$path"` 17422 17423 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17424 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17425 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17426 # "foo.exe" is OK but "foo" is an error. 17427 # 17428 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17429 # It is also a way to make sure we got the proper file name for the real test later on. 17430 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17431 if test "x$test_shortpath" = x; then 17432 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5 17433 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;} 17434 as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5 17435 fi 17436 17437 # Call helper function which possibly converts this using DOS-style short mode. 17438 # If so, the updated path is stored in $new_path. 17439 17440 input_path="$new_path" 17441 # Check if we need to convert this using DOS-style short mode. If the path 17442 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17443 # take no chances and rewrite it. 17444 # Note: m4 eats our [], so we need to use [ and ] instead. 17445 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17446 if test "x$has_forbidden_chars" != x; then 17447 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17448 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17449 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17450 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17451 # Going to short mode and back again did indeed matter. Since short mode is 17452 # case insensitive, let's make it lowercase to improve readability. 17453 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17454 # Now convert it back to Unix-stile (cygpath) 17455 input_path=`$CYGPATH -u "$shortmode_path"` 17456 new_path="$input_path" 17457 fi 17458 fi 17459 17460 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17461 if test "x$test_cygdrive_prefix" = x; then 17462 # As a simple fix, exclude /usr/bin since it's not a real path. 17463 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17464 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17465 # a path prefixed by /cygdrive for fixpath to work. 17466 new_path="$CYGWIN_ROOT_PATH$input_path" 17467 fi 17468 fi 17469 17470 17471 if test "x$path" != "x$new_path"; then 17472 MSVCR_DLL="$new_path" 17473 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5 17474 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;} 17475 fi 17476 17477 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17478 17479 path="$MSVCR_DLL" 17480 has_colon=`$ECHO $path | $GREP ^.:` 17481 new_path="$path" 17482 if test "x$has_colon" = x; then 17483 # Not in mixed or Windows style, start by that. 17484 new_path=`cmd //c echo $path` 17485 fi 17486 17487 17488 input_path="$new_path" 17489 # Check if we need to convert this using DOS-style short mode. If the path 17490 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17491 # take no chances and rewrite it. 17492 # Note: m4 eats our [], so we need to use [ and ] instead. 17493 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17494 if test "x$has_forbidden_chars" != x; then 17495 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17496 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17497 fi 17498 17499 17500 windows_path="$new_path" 17501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17502 unix_path=`$CYGPATH -u "$windows_path"` 17503 new_path="$unix_path" 17504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17505 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17506 new_path="$unix_path" 17507 fi 17508 17509 if test "x$path" != "x$new_path"; then 17510 MSVCR_DLL="$new_path" 17511 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5 17512 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;} 17513 fi 17514 17515 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17516 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17517 17518 else 17519 # We're on a posix platform. Hooray! :) 17520 path="$MSVCR_DLL" 17521 has_space=`$ECHO "$path" | $GREP " "` 17522 if test "x$has_space" != x; then 17523 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5 17524 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;} 17525 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17526 fi 17527 17528 # Use eval to expand a potential ~ 17529 eval path="$path" 17530 if test ! -f "$path" && test ! -d "$path"; then 17531 as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 17532 fi 17533 17534 MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`" 17535 fi 17536 17537 17538 17539 17540 # Check whether --with-dxsdk was given. 17541 if test "${with_dxsdk+set}" = set; then : 17542 withval=$with_dxsdk; 17543 fi 17544 17545 17546 # Check whether --with-dxsdk-lib was given. 17547 if test "${with_dxsdk_lib+set}" = set; then : 17548 withval=$with_dxsdk_lib; 17549 fi 17550 17551 17552 # Check whether --with-dxsdk-include was given. 17553 if test "${with_dxsdk_include+set}" = set; then : 17554 withval=$with_dxsdk_include; 17555 fi 17556 17557 17558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK" >&5 17559 $as_echo_n "checking for DirectX SDK... " >&6; } 17560 17561 if test "x$with_dxsdk" != x; then 17562 dxsdk_path="$with_dxsdk" 17563 elif test "x$DXSDK_DIR" != x; then 17564 dxsdk_path="$DXSDK_DIR" 17565 elif test -d "C:/DXSDK"; then 17566 dxsdk_path="C:/DXSDK" 17567 else 17568 as_fn_error $? "Could not find the DirectX SDK" "$LINENO" 5 17569 fi 17570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dxsdk_path" >&5 17571 $as_echo "$dxsdk_path" >&6; } 17572 17573 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17574 17575 # Input might be given as Windows format, start by converting to 17576 # unix format. 17577 path="$dxsdk_path" 17578 new_path=`$CYGPATH -u "$path"` 17579 17580 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17581 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17582 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17583 # "foo.exe" is OK but "foo" is an error. 17584 # 17585 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17586 # It is also a way to make sure we got the proper file name for the real test later on. 17587 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17588 if test "x$test_shortpath" = x; then 17589 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5 17590 $as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;} 17591 as_fn_error $? "Cannot locate the the path of dxsdk_path" "$LINENO" 5 17592 fi 17593 17594 # Call helper function which possibly converts this using DOS-style short mode. 17595 # If so, the updated path is stored in $new_path. 17596 17597 input_path="$new_path" 17598 # Check if we need to convert this using DOS-style short mode. If the path 17599 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17600 # take no chances and rewrite it. 17601 # Note: m4 eats our [], so we need to use [ and ] instead. 17602 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17603 if test "x$has_forbidden_chars" != x; then 17604 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17605 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17606 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17607 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17608 # Going to short mode and back again did indeed matter. Since short mode is 17609 # case insensitive, let's make it lowercase to improve readability. 17610 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17611 # Now convert it back to Unix-stile (cygpath) 17612 input_path=`$CYGPATH -u "$shortmode_path"` 17613 new_path="$input_path" 17614 fi 17615 fi 17616 17617 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17618 if test "x$test_cygdrive_prefix" = x; then 17619 # As a simple fix, exclude /usr/bin since it's not a real path. 17620 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17621 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17622 # a path prefixed by /cygdrive for fixpath to work. 17623 new_path="$CYGWIN_ROOT_PATH$input_path" 17624 fi 17625 fi 17626 17627 17628 if test "x$path" != "x$new_path"; then 17629 dxsdk_path="$new_path" 17630 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5 17631 $as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;} 17632 fi 17633 17634 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17635 17636 path="$dxsdk_path" 17637 has_colon=`$ECHO $path | $GREP ^.:` 17638 new_path="$path" 17639 if test "x$has_colon" = x; then 17640 # Not in mixed or Windows style, start by that. 17641 new_path=`cmd //c echo $path` 17642 fi 17643 17644 17645 input_path="$new_path" 17646 # Check if we need to convert this using DOS-style short mode. If the path 17647 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17648 # take no chances and rewrite it. 17649 # Note: m4 eats our [], so we need to use [ and ] instead. 17650 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17651 if test "x$has_forbidden_chars" != x; then 17652 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17653 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17654 fi 17655 17656 17657 windows_path="$new_path" 17658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17659 unix_path=`$CYGPATH -u "$windows_path"` 17660 new_path="$unix_path" 17661 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17662 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17663 new_path="$unix_path" 17664 fi 17665 17666 if test "x$path" != "x$new_path"; then 17667 dxsdk_path="$new_path" 17668 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting dxsdk_path to \"$new_path\"" >&5 17669 $as_echo "$as_me: Rewriting dxsdk_path to \"$new_path\"" >&6;} 17670 fi 17671 17672 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17673 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17674 17675 else 17676 # We're on a posix platform. Hooray! :) 17677 path="$dxsdk_path" 17678 has_space=`$ECHO "$path" | $GREP " "` 17679 if test "x$has_space" != x; then 17680 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&5 17681 $as_echo "$as_me: The path of dxsdk_path, which resolves as \"$path\", is invalid." >&6;} 17682 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17683 fi 17684 17685 # Use eval to expand a potential ~ 17686 eval path="$path" 17687 if test ! -f "$path" && test ! -d "$path"; then 17688 as_fn_error $? "The path of dxsdk_path, which resolves as \"$path\", is not found." "$LINENO" 5 17689 fi 17690 17691 dxsdk_path="`cd "$path"; $THEPWDCMD -L`" 17692 fi 17693 17694 17695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK lib dir" >&5 17696 $as_echo_n "checking for DirectX SDK lib dir... " >&6; } 17697 if test "x$with_dxsdk_lib" != x; then 17698 DXSDK_LIB_PATH="$with_dxsdk_lib" 17699 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 17700 DXSDK_LIB_PATH="$dxsdk_path/Lib/x64" 17701 else 17702 DXSDK_LIB_PATH="$dxsdk_path/Lib" 17703 fi 17704 # dsound.lib is linked to in jsoundds 17705 if test ! -f "$DXSDK_LIB_PATH/dsound.lib"; then 17706 as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5 17707 fi 17708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_LIB_PATH" >&5 17709 $as_echo "$DXSDK_LIB_PATH" >&6; } 17710 17711 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17712 17713 # Input might be given as Windows format, start by converting to 17714 # unix format. 17715 path="$DXSDK_LIB_PATH" 17716 new_path=`$CYGPATH -u "$path"` 17717 17718 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17719 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17720 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17721 # "foo.exe" is OK but "foo" is an error. 17722 # 17723 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17724 # It is also a way to make sure we got the proper file name for the real test later on. 17725 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17726 if test "x$test_shortpath" = x; then 17727 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5 17728 $as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 17729 as_fn_error $? "Cannot locate the the path of DXSDK_LIB_PATH" "$LINENO" 5 17730 fi 17731 17732 # Call helper function which possibly converts this using DOS-style short mode. 17733 # If so, the updated path is stored in $new_path. 17734 17735 input_path="$new_path" 17736 # Check if we need to convert this using DOS-style short mode. If the path 17737 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17738 # take no chances and rewrite it. 17739 # Note: m4 eats our [], so we need to use [ and ] instead. 17740 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17741 if test "x$has_forbidden_chars" != x; then 17742 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17743 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17744 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17745 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17746 # Going to short mode and back again did indeed matter. Since short mode is 17747 # case insensitive, let's make it lowercase to improve readability. 17748 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17749 # Now convert it back to Unix-stile (cygpath) 17750 input_path=`$CYGPATH -u "$shortmode_path"` 17751 new_path="$input_path" 17752 fi 17753 fi 17754 17755 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17756 if test "x$test_cygdrive_prefix" = x; then 17757 # As a simple fix, exclude /usr/bin since it's not a real path. 17758 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17759 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17760 # a path prefixed by /cygdrive for fixpath to work. 17761 new_path="$CYGWIN_ROOT_PATH$input_path" 17762 fi 17763 fi 17764 17765 17766 if test "x$path" != "x$new_path"; then 17767 DXSDK_LIB_PATH="$new_path" 17768 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5 17769 $as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;} 17770 fi 17771 17772 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17773 17774 path="$DXSDK_LIB_PATH" 17775 has_colon=`$ECHO $path | $GREP ^.:` 17776 new_path="$path" 17777 if test "x$has_colon" = x; then 17778 # Not in mixed or Windows style, start by that. 17779 new_path=`cmd //c echo $path` 17780 fi 17781 17782 17783 input_path="$new_path" 17784 # Check if we need to convert this using DOS-style short mode. If the path 17785 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17786 # take no chances and rewrite it. 17787 # Note: m4 eats our [], so we need to use [ and ] instead. 17788 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17789 if test "x$has_forbidden_chars" != x; then 17790 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17791 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17792 fi 17793 17794 17795 windows_path="$new_path" 17796 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17797 unix_path=`$CYGPATH -u "$windows_path"` 17798 new_path="$unix_path" 17799 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17800 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17801 new_path="$unix_path" 17802 fi 17803 17804 if test "x$path" != "x$new_path"; then 17805 DXSDK_LIB_PATH="$new_path" 17806 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&5 17807 $as_echo "$as_me: Rewriting DXSDK_LIB_PATH to \"$new_path\"" >&6;} 17808 fi 17809 17810 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17811 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17812 17813 else 17814 # We're on a posix platform. Hooray! :) 17815 path="$DXSDK_LIB_PATH" 17816 has_space=`$ECHO "$path" | $GREP " "` 17817 if test "x$has_space" != x; then 17818 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&5 17819 $as_echo "$as_me: The path of DXSDK_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 17820 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17821 fi 17822 17823 # Use eval to expand a potential ~ 17824 eval path="$path" 17825 if test ! -f "$path" && test ! -d "$path"; then 17826 as_fn_error $? "The path of DXSDK_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 17827 fi 17828 17829 DXSDK_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 17830 fi 17831 17832 17833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DirectX SDK include dir" >&5 17834 $as_echo_n "checking for DirectX SDK include dir... " >&6; } 17835 if test "x$with_dxsdk_include" != x; then 17836 DXSDK_INCLUDE_PATH="$with_dxsdk_include" 17837 else 17838 DXSDK_INCLUDE_PATH="$dxsdk_path/Include" 17839 fi 17840 # dsound.h is included in jsoundds 17841 if test ! -f "$DXSDK_INCLUDE_PATH/dsound.h"; then 17842 as_fn_error $? "Invalid DirectX SDK lib dir" "$LINENO" 5 17843 fi 17844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DXSDK_INCLUDE_PATH" >&5 17845 $as_echo "$DXSDK_INCLUDE_PATH" >&6; } 17846 17847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17848 17849 # Input might be given as Windows format, start by converting to 17850 # unix format. 17851 path="$DXSDK_INCLUDE_PATH" 17852 new_path=`$CYGPATH -u "$path"` 17853 17854 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17855 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17856 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17857 # "foo.exe" is OK but "foo" is an error. 17858 # 17859 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17860 # It is also a way to make sure we got the proper file name for the real test later on. 17861 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17862 if test "x$test_shortpath" = x; then 17863 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 17864 $as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 17865 as_fn_error $? "Cannot locate the the path of DXSDK_INCLUDE_PATH" "$LINENO" 5 17866 fi 17867 17868 # Call helper function which possibly converts this using DOS-style short mode. 17869 # If so, the updated path is stored in $new_path. 17870 17871 input_path="$new_path" 17872 # Check if we need to convert this using DOS-style short mode. If the path 17873 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17874 # take no chances and rewrite it. 17875 # Note: m4 eats our [], so we need to use [ and ] instead. 17876 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17877 if test "x$has_forbidden_chars" != x; then 17878 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17879 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17880 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17881 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17882 # Going to short mode and back again did indeed matter. Since short mode is 17883 # case insensitive, let's make it lowercase to improve readability. 17884 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17885 # Now convert it back to Unix-stile (cygpath) 17886 input_path=`$CYGPATH -u "$shortmode_path"` 17887 new_path="$input_path" 17888 fi 17889 fi 17890 17891 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17892 if test "x$test_cygdrive_prefix" = x; then 17893 # As a simple fix, exclude /usr/bin since it's not a real path. 17894 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17895 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17896 # a path prefixed by /cygdrive for fixpath to work. 17897 new_path="$CYGWIN_ROOT_PATH$input_path" 17898 fi 17899 fi 17900 17901 17902 if test "x$path" != "x$new_path"; then 17903 DXSDK_INCLUDE_PATH="$new_path" 17904 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5 17905 $as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;} 17906 fi 17907 17908 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17909 17910 path="$DXSDK_INCLUDE_PATH" 17911 has_colon=`$ECHO $path | $GREP ^.:` 17912 new_path="$path" 17913 if test "x$has_colon" = x; then 17914 # Not in mixed or Windows style, start by that. 17915 new_path=`cmd //c echo $path` 17916 fi 17917 17918 17919 input_path="$new_path" 17920 # Check if we need to convert this using DOS-style short mode. If the path 17921 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17922 # take no chances and rewrite it. 17923 # Note: m4 eats our [], so we need to use [ and ] instead. 17924 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17925 if test "x$has_forbidden_chars" != x; then 17926 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17927 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17928 fi 17929 17930 17931 windows_path="$new_path" 17932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17933 unix_path=`$CYGPATH -u "$windows_path"` 17934 new_path="$unix_path" 17935 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17936 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17937 new_path="$unix_path" 17938 fi 17939 17940 if test "x$path" != "x$new_path"; then 17941 DXSDK_INCLUDE_PATH="$new_path" 17942 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&5 17943 $as_echo "$as_me: Rewriting DXSDK_INCLUDE_PATH to \"$new_path\"" >&6;} 17944 fi 17945 17946 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17947 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17948 17949 else 17950 # We're on a posix platform. Hooray! :) 17951 path="$DXSDK_INCLUDE_PATH" 17952 has_space=`$ECHO "$path" | $GREP " "` 17953 if test "x$has_space" != x; then 17954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 17955 $as_echo "$as_me: The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 17956 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17957 fi 17958 17959 # Use eval to expand a potential ~ 17960 eval path="$path" 17961 if test ! -f "$path" && test ! -d "$path"; then 17962 as_fn_error $? "The path of DXSDK_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 17963 fi 17964 17965 DXSDK_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 17966 fi 17967 17968 17969 17970 17971 LDFLAGS_JDK="$LDFLAGS_JDK -libpath:$DXSDK_LIB_PATH" 17972 17973 fi 17974 17975 17976 17977 # If --build AND --host is set, then the configure script will find any 17978 # cross compilation tools in the PATH. Cross compilation tools 17979 # follows the cross compilation standard where they are prefixed with ${host}. 17980 # For example the binary i686-sun-solaris2.10-gcc 17981 # will cross compile for i686-sun-solaris2.10 17982 # If neither of build and host is not set, then build=host and the 17983 # default compiler found in the path will be used. 17984 # Setting only --host, does not seem to be really supported. 17985 # Please set both --build and --host if you want to cross compile. 17986 17987 if test "x$COMPILE_TYPE" = "xcross"; then 17988 # Now we to find a C/C++ compiler that can build executables for the build 17989 # platform. We can't use the AC_PROG_CC macro, since it can only be used 17990 # once. Also, we need to do this before adding a tools dir to the path, 17991 # otherwise we might pick up cross-compilers which don't use standard naming. 17992 # Otherwise, we'll set the BUILD_tools to the native tools, but that'll have 17993 # to wait until they are properly discovered. 17994 for ac_prog in cl cc gcc 17995 do 17996 # Extract the first word of "$ac_prog", so it can be a program name with args. 17997 set dummy $ac_prog; ac_word=$2 17998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17999 $as_echo_n "checking for $ac_word... " >&6; } 18000 if ${ac_cv_path_BUILD_CC+:} false; then : 18001 $as_echo_n "(cached) " >&6 18002 else 18003 case $BUILD_CC in 18004 [\\/]* | ?:[\\/]*) 18005 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 18006 ;; 18007 *) 18008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18009 for as_dir in $PATH 18010 do 18011 IFS=$as_save_IFS 18012 test -z "$as_dir" && as_dir=. 18013 for ac_exec_ext in '' $ac_executable_extensions; do 18014 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 18015 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 18016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18017 break 2 18018 fi 18019 done 18020 done 18021 IFS=$as_save_IFS 18022 18023 ;; 18024 esac 18025 fi 18026 BUILD_CC=$ac_cv_path_BUILD_CC 18027 if test -n "$BUILD_CC"; then 18028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 18029 $as_echo "$BUILD_CC" >&6; } 18030 else 18031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18032 $as_echo "no" >&6; } 18033 fi 18034 18035 18036 test -n "$BUILD_CC" && break 18037 done 18038 18039 18040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18041 18042 # First separate the path from the arguments. This will split at the first 18043 # space. 18044 complete="$BUILD_CC" 18045 path="${complete%% *}" 18046 tmp="$complete EOL" 18047 arguments="${tmp#* }" 18048 18049 # Input might be given as Windows format, start by converting to 18050 # unix format. 18051 new_path=`$CYGPATH -u "$path"` 18052 18053 # Now try to locate executable using which 18054 new_path=`$WHICH "$new_path" 2> /dev/null` 18055 # bat and cmd files are not always considered executable in cygwin causing which 18056 # to not find them 18057 if test "x$new_path" = x \ 18058 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18059 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18060 new_path=`$CYGPATH -u "$path"` 18061 fi 18062 if test "x$new_path" = x; then 18063 # Oops. Which didn't find the executable. 18064 # The splitting of arguments from the executable at a space might have been incorrect, 18065 # since paths with space are more likely in Windows. Give it another try with the whole 18066 # argument. 18067 path="$complete" 18068 arguments="EOL" 18069 new_path=`$CYGPATH -u "$path"` 18070 new_path=`$WHICH "$new_path" 2> /dev/null` 18071 # bat and cmd files are not always considered executable in cygwin causing which 18072 # to not find them 18073 if test "x$new_path" = x \ 18074 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18075 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18076 new_path=`$CYGPATH -u "$path"` 18077 fi 18078 if test "x$new_path" = x; then 18079 # It's still not found. Now this is an unrecoverable error. 18080 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18081 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18082 has_space=`$ECHO "$complete" | $GREP " "` 18083 if test "x$has_space" != x; then 18084 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18085 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18086 fi 18087 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18088 fi 18089 fi 18090 18091 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18092 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18093 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18094 # "foo.exe" is OK but "foo" is an error. 18095 # 18096 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18097 # It is also a way to make sure we got the proper file name for the real test later on. 18098 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18099 if test "x$test_shortpath" = x; then 18100 # Short path failed, file does not exist as specified. 18101 # Try adding .exe or .cmd 18102 if test -f "${new_path}.exe"; then 18103 input_to_shortpath="${new_path}.exe" 18104 elif test -f "${new_path}.cmd"; then 18105 input_to_shortpath="${new_path}.cmd" 18106 else 18107 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 18108 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 18109 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18110 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18111 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18112 fi 18113 else 18114 input_to_shortpath="$new_path" 18115 fi 18116 18117 # Call helper function which possibly converts this using DOS-style short mode. 18118 # If so, the updated path is stored in $new_path. 18119 new_path="$input_to_shortpath" 18120 18121 input_path="$input_to_shortpath" 18122 # Check if we need to convert this using DOS-style short mode. If the path 18123 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18124 # take no chances and rewrite it. 18125 # Note: m4 eats our [], so we need to use [ and ] instead. 18126 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18127 if test "x$has_forbidden_chars" != x; then 18128 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18129 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18130 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18131 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18132 # Going to short mode and back again did indeed matter. Since short mode is 18133 # case insensitive, let's make it lowercase to improve readability. 18134 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18135 # Now convert it back to Unix-stile (cygpath) 18136 input_path=`$CYGPATH -u "$shortmode_path"` 18137 new_path="$input_path" 18138 fi 18139 fi 18140 18141 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18142 if test "x$test_cygdrive_prefix" = x; then 18143 # As a simple fix, exclude /usr/bin since it's not a real path. 18144 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18145 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18146 # a path prefixed by /cygdrive for fixpath to work. 18147 new_path="$CYGWIN_ROOT_PATH$input_path" 18148 fi 18149 fi 18150 18151 # remove trailing .exe if any 18152 new_path="${new_path/%.exe/}" 18153 18154 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18155 18156 # First separate the path from the arguments. This will split at the first 18157 # space. 18158 complete="$BUILD_CC" 18159 path="${complete%% *}" 18160 tmp="$complete EOL" 18161 arguments="${tmp#* }" 18162 18163 # Input might be given as Windows format, start by converting to 18164 # unix format. 18165 new_path="$path" 18166 18167 windows_path="$new_path" 18168 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18169 unix_path=`$CYGPATH -u "$windows_path"` 18170 new_path="$unix_path" 18171 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18172 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18173 new_path="$unix_path" 18174 fi 18175 18176 18177 # Now try to locate executable using which 18178 new_path=`$WHICH "$new_path" 2> /dev/null` 18179 18180 if test "x$new_path" = x; then 18181 # Oops. Which didn't find the executable. 18182 # The splitting of arguments from the executable at a space might have been incorrect, 18183 # since paths with space are more likely in Windows. Give it another try with the whole 18184 # argument. 18185 path="$complete" 18186 arguments="EOL" 18187 new_path="$path" 18188 18189 windows_path="$new_path" 18190 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18191 unix_path=`$CYGPATH -u "$windows_path"` 18192 new_path="$unix_path" 18193 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18194 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18195 new_path="$unix_path" 18196 fi 18197 18198 18199 new_path=`$WHICH "$new_path" 2> /dev/null` 18200 18201 if test "x$new_path" = x; then 18202 # It's still not found. Now this is an unrecoverable error. 18203 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18204 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18205 has_space=`$ECHO "$complete" | $GREP " "` 18206 if test "x$has_space" != x; then 18207 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18208 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18209 fi 18210 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18211 fi 18212 fi 18213 18214 # Now new_path has a complete unix path to the binary 18215 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18216 # Keep paths in /bin as-is, but remove trailing .exe if any 18217 new_path="${new_path/%.exe/}" 18218 # Do not save /bin paths to all_fixpath_prefixes! 18219 else 18220 # Not in mixed or Windows style, start by that. 18221 new_path=`cmd //c echo $new_path` 18222 18223 input_path="$new_path" 18224 # Check if we need to convert this using DOS-style short mode. If the path 18225 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18226 # take no chances and rewrite it. 18227 # Note: m4 eats our [], so we need to use [ and ] instead. 18228 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18229 if test "x$has_forbidden_chars" != x; then 18230 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18231 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18232 fi 18233 18234 # Output is in $new_path 18235 18236 windows_path="$new_path" 18237 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18238 unix_path=`$CYGPATH -u "$windows_path"` 18239 new_path="$unix_path" 18240 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18241 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18242 new_path="$unix_path" 18243 fi 18244 18245 # remove trailing .exe if any 18246 new_path="${new_path/%.exe/}" 18247 18248 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18249 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18250 fi 18251 18252 else 18253 # We're on a posix platform. Hooray! :) 18254 # First separate the path from the arguments. This will split at the first 18255 # space. 18256 complete="$BUILD_CC" 18257 path="${complete%% *}" 18258 tmp="$complete EOL" 18259 arguments="${tmp#* }" 18260 18261 # Cannot rely on the command "which" here since it doesn't always work. 18262 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18263 if test -z "$is_absolute_path"; then 18264 # Path to executable is not absolute. Find it. 18265 IFS_save="$IFS" 18266 IFS=: 18267 for p in $PATH; do 18268 if test -f "$p/$path" && test -x "$p/$path"; then 18269 new_path="$p/$path" 18270 break 18271 fi 18272 done 18273 IFS="$IFS_save" 18274 else 18275 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CC (as $path) failed, using $path directly." >&5 18276 $as_echo "$as_me: Resolving BUILD_CC (as $path) failed, using $path directly." >&6;} 18277 new_path="$path" 18278 fi 18279 18280 if test "x$new_path" = x; then 18281 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 18282 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 18283 has_space=`$ECHO "$complete" | $GREP " "` 18284 if test "x$has_space" != x; then 18285 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18286 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18287 fi 18288 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 18289 fi 18290 fi 18291 18292 # Now join together the path and the arguments once again 18293 if test "x$arguments" != xEOL; then 18294 new_complete="$new_path ${arguments% *}" 18295 else 18296 new_complete="$new_path" 18297 fi 18298 18299 if test "x$complete" != "x$new_complete"; then 18300 BUILD_CC="$new_complete" 18301 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 18302 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 18303 fi 18304 18305 for ac_prog in cl CC g++ 18306 do 18307 # Extract the first word of "$ac_prog", so it can be a program name with args. 18308 set dummy $ac_prog; ac_word=$2 18309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18310 $as_echo_n "checking for $ac_word... " >&6; } 18311 if ${ac_cv_path_BUILD_CXX+:} false; then : 18312 $as_echo_n "(cached) " >&6 18313 else 18314 case $BUILD_CXX in 18315 [\\/]* | ?:[\\/]*) 18316 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 18317 ;; 18318 *) 18319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18320 for as_dir in $PATH 18321 do 18322 IFS=$as_save_IFS 18323 test -z "$as_dir" && as_dir=. 18324 for ac_exec_ext in '' $ac_executable_extensions; do 18325 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 18326 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 18327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18328 break 2 18329 fi 18330 done 18331 done 18332 IFS=$as_save_IFS 18333 18334 ;; 18335 esac 18336 fi 18337 BUILD_CXX=$ac_cv_path_BUILD_CXX 18338 if test -n "$BUILD_CXX"; then 18339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 18340 $as_echo "$BUILD_CXX" >&6; } 18341 else 18342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18343 $as_echo "no" >&6; } 18344 fi 18345 18346 18347 test -n "$BUILD_CXX" && break 18348 done 18349 18350 18351 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18352 18353 # First separate the path from the arguments. This will split at the first 18354 # space. 18355 complete="$BUILD_CXX" 18356 path="${complete%% *}" 18357 tmp="$complete EOL" 18358 arguments="${tmp#* }" 18359 18360 # Input might be given as Windows format, start by converting to 18361 # unix format. 18362 new_path=`$CYGPATH -u "$path"` 18363 18364 # Now try to locate executable using which 18365 new_path=`$WHICH "$new_path" 2> /dev/null` 18366 # bat and cmd files are not always considered executable in cygwin causing which 18367 # to not find them 18368 if test "x$new_path" = x \ 18369 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18370 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18371 new_path=`$CYGPATH -u "$path"` 18372 fi 18373 if test "x$new_path" = x; then 18374 # Oops. Which didn't find the executable. 18375 # The splitting of arguments from the executable at a space might have been incorrect, 18376 # since paths with space are more likely in Windows. Give it another try with the whole 18377 # argument. 18378 path="$complete" 18379 arguments="EOL" 18380 new_path=`$CYGPATH -u "$path"` 18381 new_path=`$WHICH "$new_path" 2> /dev/null` 18382 # bat and cmd files are not always considered executable in cygwin causing which 18383 # to not find them 18384 if test "x$new_path" = x \ 18385 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18386 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18387 new_path=`$CYGPATH -u "$path"` 18388 fi 18389 if test "x$new_path" = x; then 18390 # It's still not found. Now this is an unrecoverable error. 18391 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18392 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18393 has_space=`$ECHO "$complete" | $GREP " "` 18394 if test "x$has_space" != x; then 18395 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18396 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18397 fi 18398 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18399 fi 18400 fi 18401 18402 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18403 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18404 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18405 # "foo.exe" is OK but "foo" is an error. 18406 # 18407 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18408 # It is also a way to make sure we got the proper file name for the real test later on. 18409 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18410 if test "x$test_shortpath" = x; then 18411 # Short path failed, file does not exist as specified. 18412 # Try adding .exe or .cmd 18413 if test -f "${new_path}.exe"; then 18414 input_to_shortpath="${new_path}.exe" 18415 elif test -f "${new_path}.cmd"; then 18416 input_to_shortpath="${new_path}.cmd" 18417 else 18418 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 18419 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 18420 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18421 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18422 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18423 fi 18424 else 18425 input_to_shortpath="$new_path" 18426 fi 18427 18428 # Call helper function which possibly converts this using DOS-style short mode. 18429 # If so, the updated path is stored in $new_path. 18430 new_path="$input_to_shortpath" 18431 18432 input_path="$input_to_shortpath" 18433 # Check if we need to convert this using DOS-style short mode. If the path 18434 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18435 # take no chances and rewrite it. 18436 # Note: m4 eats our [], so we need to use [ and ] instead. 18437 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18438 if test "x$has_forbidden_chars" != x; then 18439 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18440 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18441 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18442 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18443 # Going to short mode and back again did indeed matter. Since short mode is 18444 # case insensitive, let's make it lowercase to improve readability. 18445 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18446 # Now convert it back to Unix-stile (cygpath) 18447 input_path=`$CYGPATH -u "$shortmode_path"` 18448 new_path="$input_path" 18449 fi 18450 fi 18451 18452 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18453 if test "x$test_cygdrive_prefix" = x; then 18454 # As a simple fix, exclude /usr/bin since it's not a real path. 18455 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18456 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18457 # a path prefixed by /cygdrive for fixpath to work. 18458 new_path="$CYGWIN_ROOT_PATH$input_path" 18459 fi 18460 fi 18461 18462 # remove trailing .exe if any 18463 new_path="${new_path/%.exe/}" 18464 18465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18466 18467 # First separate the path from the arguments. This will split at the first 18468 # space. 18469 complete="$BUILD_CXX" 18470 path="${complete%% *}" 18471 tmp="$complete EOL" 18472 arguments="${tmp#* }" 18473 18474 # Input might be given as Windows format, start by converting to 18475 # unix format. 18476 new_path="$path" 18477 18478 windows_path="$new_path" 18479 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18480 unix_path=`$CYGPATH -u "$windows_path"` 18481 new_path="$unix_path" 18482 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18483 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18484 new_path="$unix_path" 18485 fi 18486 18487 18488 # Now try to locate executable using which 18489 new_path=`$WHICH "$new_path" 2> /dev/null` 18490 18491 if test "x$new_path" = x; then 18492 # Oops. Which didn't find the executable. 18493 # The splitting of arguments from the executable at a space might have been incorrect, 18494 # since paths with space are more likely in Windows. Give it another try with the whole 18495 # argument. 18496 path="$complete" 18497 arguments="EOL" 18498 new_path="$path" 18499 18500 windows_path="$new_path" 18501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18502 unix_path=`$CYGPATH -u "$windows_path"` 18503 new_path="$unix_path" 18504 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18505 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18506 new_path="$unix_path" 18507 fi 18508 18509 18510 new_path=`$WHICH "$new_path" 2> /dev/null` 18511 18512 if test "x$new_path" = x; then 18513 # It's still not found. Now this is an unrecoverable error. 18514 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18515 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18516 has_space=`$ECHO "$complete" | $GREP " "` 18517 if test "x$has_space" != x; then 18518 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18519 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18520 fi 18521 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18522 fi 18523 fi 18524 18525 # Now new_path has a complete unix path to the binary 18526 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18527 # Keep paths in /bin as-is, but remove trailing .exe if any 18528 new_path="${new_path/%.exe/}" 18529 # Do not save /bin paths to all_fixpath_prefixes! 18530 else 18531 # Not in mixed or Windows style, start by that. 18532 new_path=`cmd //c echo $new_path` 18533 18534 input_path="$new_path" 18535 # Check if we need to convert this using DOS-style short mode. If the path 18536 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18537 # take no chances and rewrite it. 18538 # Note: m4 eats our [], so we need to use [ and ] instead. 18539 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18540 if test "x$has_forbidden_chars" != x; then 18541 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18542 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18543 fi 18544 18545 # Output is in $new_path 18546 18547 windows_path="$new_path" 18548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18549 unix_path=`$CYGPATH -u "$windows_path"` 18550 new_path="$unix_path" 18551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18552 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18553 new_path="$unix_path" 18554 fi 18555 18556 # remove trailing .exe if any 18557 new_path="${new_path/%.exe/}" 18558 18559 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18560 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18561 fi 18562 18563 else 18564 # We're on a posix platform. Hooray! :) 18565 # First separate the path from the arguments. This will split at the first 18566 # space. 18567 complete="$BUILD_CXX" 18568 path="${complete%% *}" 18569 tmp="$complete EOL" 18570 arguments="${tmp#* }" 18571 18572 # Cannot rely on the command "which" here since it doesn't always work. 18573 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18574 if test -z "$is_absolute_path"; then 18575 # Path to executable is not absolute. Find it. 18576 IFS_save="$IFS" 18577 IFS=: 18578 for p in $PATH; do 18579 if test -f "$p/$path" && test -x "$p/$path"; then 18580 new_path="$p/$path" 18581 break 18582 fi 18583 done 18584 IFS="$IFS_save" 18585 else 18586 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CXX (as $path) failed, using $path directly." >&5 18587 $as_echo "$as_me: Resolving BUILD_CXX (as $path) failed, using $path directly." >&6;} 18588 new_path="$path" 18589 fi 18590 18591 if test "x$new_path" = x; then 18592 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 18593 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 18594 has_space=`$ECHO "$complete" | $GREP " "` 18595 if test "x$has_space" != x; then 18596 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18597 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18598 fi 18599 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 18600 fi 18601 fi 18602 18603 # Now join together the path and the arguments once again 18604 if test "x$arguments" != xEOL; then 18605 new_complete="$new_path ${arguments% *}" 18606 else 18607 new_complete="$new_path" 18608 fi 18609 18610 if test "x$complete" != "x$new_complete"; then 18611 BUILD_CXX="$new_complete" 18612 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 18613 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 18614 fi 18615 18616 # Extract the first word of "ld", so it can be a program name with args. 18617 set dummy ld; ac_word=$2 18618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18619 $as_echo_n "checking for $ac_word... " >&6; } 18620 if ${ac_cv_path_BUILD_LD+:} false; then : 18621 $as_echo_n "(cached) " >&6 18622 else 18623 case $BUILD_LD in 18624 [\\/]* | ?:[\\/]*) 18625 ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path. 18626 ;; 18627 *) 18628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18629 for as_dir in $PATH 18630 do 18631 IFS=$as_save_IFS 18632 test -z "$as_dir" && as_dir=. 18633 for ac_exec_ext in '' $ac_executable_extensions; do 18634 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 18635 ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext" 18636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18637 break 2 18638 fi 18639 done 18640 done 18641 IFS=$as_save_IFS 18642 18643 ;; 18644 esac 18645 fi 18646 BUILD_LD=$ac_cv_path_BUILD_LD 18647 if test -n "$BUILD_LD"; then 18648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5 18649 $as_echo "$BUILD_LD" >&6; } 18650 else 18651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18652 $as_echo "no" >&6; } 18653 fi 18654 18655 18656 18657 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18658 18659 # First separate the path from the arguments. This will split at the first 18660 # space. 18661 complete="$BUILD_LD" 18662 path="${complete%% *}" 18663 tmp="$complete EOL" 18664 arguments="${tmp#* }" 18665 18666 # Input might be given as Windows format, start by converting to 18667 # unix format. 18668 new_path=`$CYGPATH -u "$path"` 18669 18670 # Now try to locate executable using which 18671 new_path=`$WHICH "$new_path" 2> /dev/null` 18672 # bat and cmd files are not always considered executable in cygwin causing which 18673 # to not find them 18674 if test "x$new_path" = x \ 18675 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18676 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18677 new_path=`$CYGPATH -u "$path"` 18678 fi 18679 if test "x$new_path" = x; then 18680 # Oops. Which didn't find the executable. 18681 # The splitting of arguments from the executable at a space might have been incorrect, 18682 # since paths with space are more likely in Windows. Give it another try with the whole 18683 # argument. 18684 path="$complete" 18685 arguments="EOL" 18686 new_path=`$CYGPATH -u "$path"` 18687 new_path=`$WHICH "$new_path" 2> /dev/null` 18688 # bat and cmd files are not always considered executable in cygwin causing which 18689 # to not find them 18690 if test "x$new_path" = x \ 18691 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18692 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18693 new_path=`$CYGPATH -u "$path"` 18694 fi 18695 if test "x$new_path" = x; then 18696 # It's still not found. Now this is an unrecoverable error. 18697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 18698 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 18699 has_space=`$ECHO "$complete" | $GREP " "` 18700 if test "x$has_space" != x; then 18701 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18702 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18703 fi 18704 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 18705 fi 18706 fi 18707 18708 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18709 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18710 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18711 # "foo.exe" is OK but "foo" is an error. 18712 # 18713 # This test is therefore slightly more accurate than "test -f" to check for file precense. 18714 # It is also a way to make sure we got the proper file name for the real test later on. 18715 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18716 if test "x$test_shortpath" = x; then 18717 # Short path failed, file does not exist as specified. 18718 # Try adding .exe or .cmd 18719 if test -f "${new_path}.exe"; then 18720 input_to_shortpath="${new_path}.exe" 18721 elif test -f "${new_path}.cmd"; then 18722 input_to_shortpath="${new_path}.cmd" 18723 else 18724 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5 18725 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;} 18726 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18727 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18728 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 18729 fi 18730 else 18731 input_to_shortpath="$new_path" 18732 fi 18733 18734 # Call helper function which possibly converts this using DOS-style short mode. 18735 # If so, the updated path is stored in $new_path. 18736 new_path="$input_to_shortpath" 18737 18738 input_path="$input_to_shortpath" 18739 # Check if we need to convert this using DOS-style short mode. If the path 18740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18741 # take no chances and rewrite it. 18742 # Note: m4 eats our [], so we need to use [ and ] instead. 18743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18744 if test "x$has_forbidden_chars" != x; then 18745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18746 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18747 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18748 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18749 # Going to short mode and back again did indeed matter. Since short mode is 18750 # case insensitive, let's make it lowercase to improve readability. 18751 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18752 # Now convert it back to Unix-stile (cygpath) 18753 input_path=`$CYGPATH -u "$shortmode_path"` 18754 new_path="$input_path" 18755 fi 18756 fi 18757 18758 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18759 if test "x$test_cygdrive_prefix" = x; then 18760 # As a simple fix, exclude /usr/bin since it's not a real path. 18761 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18762 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18763 # a path prefixed by /cygdrive for fixpath to work. 18764 new_path="$CYGWIN_ROOT_PATH$input_path" 18765 fi 18766 fi 18767 18768 # remove trailing .exe if any 18769 new_path="${new_path/%.exe/}" 18770 18771 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18772 18773 # First separate the path from the arguments. This will split at the first 18774 # space. 18775 complete="$BUILD_LD" 18776 path="${complete%% *}" 18777 tmp="$complete EOL" 18778 arguments="${tmp#* }" 18779 18780 # Input might be given as Windows format, start by converting to 18781 # unix format. 18782 new_path="$path" 18783 18784 windows_path="$new_path" 18785 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18786 unix_path=`$CYGPATH -u "$windows_path"` 18787 new_path="$unix_path" 18788 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18789 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18790 new_path="$unix_path" 18791 fi 18792 18793 18794 # Now try to locate executable using which 18795 new_path=`$WHICH "$new_path" 2> /dev/null` 18796 18797 if test "x$new_path" = x; then 18798 # Oops. Which didn't find the executable. 18799 # The splitting of arguments from the executable at a space might have been incorrect, 18800 # since paths with space are more likely in Windows. Give it another try with the whole 18801 # argument. 18802 path="$complete" 18803 arguments="EOL" 18804 new_path="$path" 18805 18806 windows_path="$new_path" 18807 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18808 unix_path=`$CYGPATH -u "$windows_path"` 18809 new_path="$unix_path" 18810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18811 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18812 new_path="$unix_path" 18813 fi 18814 18815 18816 new_path=`$WHICH "$new_path" 2> /dev/null` 18817 18818 if test "x$new_path" = x; then 18819 # It's still not found. Now this is an unrecoverable error. 18820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 18821 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 18822 has_space=`$ECHO "$complete" | $GREP " "` 18823 if test "x$has_space" != x; then 18824 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18825 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18826 fi 18827 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 18828 fi 18829 fi 18830 18831 # Now new_path has a complete unix path to the binary 18832 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18833 # Keep paths in /bin as-is, but remove trailing .exe if any 18834 new_path="${new_path/%.exe/}" 18835 # Do not save /bin paths to all_fixpath_prefixes! 18836 else 18837 # Not in mixed or Windows style, start by that. 18838 new_path=`cmd //c echo $new_path` 18839 18840 input_path="$new_path" 18841 # Check if we need to convert this using DOS-style short mode. If the path 18842 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18843 # take no chances and rewrite it. 18844 # Note: m4 eats our [], so we need to use [ and ] instead. 18845 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18846 if test "x$has_forbidden_chars" != x; then 18847 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18848 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18849 fi 18850 18851 # Output is in $new_path 18852 18853 windows_path="$new_path" 18854 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18855 unix_path=`$CYGPATH -u "$windows_path"` 18856 new_path="$unix_path" 18857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18858 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18859 new_path="$unix_path" 18860 fi 18861 18862 # remove trailing .exe if any 18863 new_path="${new_path/%.exe/}" 18864 18865 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18866 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18867 fi 18868 18869 else 18870 # We're on a posix platform. Hooray! :) 18871 # First separate the path from the arguments. This will split at the first 18872 # space. 18873 complete="$BUILD_LD" 18874 path="${complete%% *}" 18875 tmp="$complete EOL" 18876 arguments="${tmp#* }" 18877 18878 # Cannot rely on the command "which" here since it doesn't always work. 18879 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18880 if test -z "$is_absolute_path"; then 18881 # Path to executable is not absolute. Find it. 18882 IFS_save="$IFS" 18883 IFS=: 18884 for p in $PATH; do 18885 if test -f "$p/$path" && test -x "$p/$path"; then 18886 new_path="$p/$path" 18887 break 18888 fi 18889 done 18890 IFS="$IFS_save" 18891 else 18892 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_LD (as $path) failed, using $path directly." >&5 18893 $as_echo "$as_me: Resolving BUILD_LD (as $path) failed, using $path directly." >&6;} 18894 new_path="$path" 18895 fi 18896 18897 if test "x$new_path" = x; then 18898 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5 18899 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;} 18900 has_space=`$ECHO "$complete" | $GREP " "` 18901 if test "x$has_space" != x; then 18902 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18903 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18904 fi 18905 as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5 18906 fi 18907 fi 18908 18909 # Now join together the path and the arguments once again 18910 if test "x$arguments" != xEOL; then 18911 new_complete="$new_path ${arguments% *}" 18912 else 18913 new_complete="$new_path" 18914 fi 18915 18916 if test "x$complete" != "x$new_complete"; then 18917 BUILD_LD="$new_complete" 18918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5 18919 $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;} 18920 fi 18921 18922 fi 18923 18924 18925 18926 18927 # If a devkit is found on the builddeps server, then prepend its path to the 18928 # PATH variable. If there are cross compilers available in the devkit, these 18929 # will be found by AC_PROG_CC et al. 18930 DEVKIT= 18931 18932 18933 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 18934 # Source the builddeps file again, to make sure it uses the latest variables! 18935 . $builddepsfile 18936 # Look for a target and build machine specific resource! 18937 eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 18938 if test "x$resource" = x; then 18939 # Ok, lets instead look for a target specific resource 18940 eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}} 18941 fi 18942 if test "x$resource" = x; then 18943 # Ok, lets instead look for a build specific resource 18944 eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}} 18945 fi 18946 if test "x$resource" = x; then 18947 # Ok, lets instead look for a generic resource 18948 # (The devkit comes from M4 and not the shell, thus no need for eval here.) 18949 resource=${builddep_devkit} 18950 fi 18951 if test "x$resource" != x; then 18952 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5 18953 $as_echo "$as_me: Using builddeps $resource for devkit" >&6;} 18954 # If the resource in the builddeps.conf file is an existing directory, 18955 # for example /java/linux/cups 18956 if test -d ${resource}; then 18957 depdir=${resource} 18958 else 18959 18960 # devkit is for example mymodule 18961 # $resource is for example libs/general/libmymod_1_2_3.zip 18962 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 18963 # $with_builddeps_dir is for example /localhome/builddeps 18964 # depdir is the name of the variable into which we store the depdir, eg MYMOD 18965 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 18966 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 18967 filename=`basename $resource` 18968 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 18969 filebase=${filename%%.*} 18970 extension=${filename#*.} 18971 installdir=$with_builddeps_dir/$filebase 18972 if test ! -f $installdir/$filename.unpacked; then 18973 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5 18974 $as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;} 18975 if test ! -d $installdir; then 18976 mkdir -p $installdir 18977 fi 18978 if test ! -d $installdir; then 18979 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 18980 fi 18981 tmpfile=`mktemp $installdir/devkit.XXXXXXXXX` 18982 touch $tmpfile 18983 if test ! -f $tmpfile; then 18984 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 18985 fi 18986 18987 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 18988 # $tmpfile is the local file name for the downloaded file. 18989 VALID_TOOL=no 18990 if test "x$BDEPS_FTP" = xwget; then 18991 VALID_TOOL=yes 18992 wget -O $tmpfile $with_builddeps_server/$resource 18993 fi 18994 if test "x$BDEPS_FTP" = xlftp; then 18995 VALID_TOOL=yes 18996 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 18997 fi 18998 if test "x$BDEPS_FTP" = xftp; then 18999 VALID_TOOL=yes 19000 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 19001 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 19002 FTPUSERPWD=${FTPSERVER%%@*} 19003 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 19004 FTPUSER=${userpwd%%:*} 19005 FTPPWD=${userpwd#*@} 19006 FTPSERVER=${FTPSERVER#*@} 19007 else 19008 FTPUSER=ftp 19009 FTPPWD=ftp 19010 fi 19011 # the "pass" command does not work on some 19012 # ftp clients (read ftp.exe) but if it works, 19013 # passive mode is better! 19014 (\ 19015 echo "user $FTPUSER $FTPPWD" ;\ 19016 echo "pass" ;\ 19017 echo "bin" ;\ 19018 echo "get $FTPPATH $tmpfile" ;\ 19019 ) | ftp -in $FTPSERVER 19020 fi 19021 if test "x$VALID_TOOL" != xyes; then 19022 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 19023 fi 19024 19025 mv $tmpfile $installdir/$filename 19026 if test ! -s $installdir/$filename; then 19027 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 19028 fi 19029 case "$extension" in 19030 zip) echo "Unzipping $installdir/$filename..." 19031 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 19032 ;; 19033 tar.gz) echo "Untaring $installdir/$filename..." 19034 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 19035 ;; 19036 tgz) echo "Untaring $installdir/$filename..." 19037 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 19038 ;; 19039 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 19040 ;; 19041 esac 19042 fi 19043 if test -f $installdir/$filename.unpacked; then 19044 depdir=$installdir 19045 fi 19046 19047 fi 19048 # Source the builddeps file again, because in the previous command, the depdir 19049 # was updated to point at the current build dependency install directory. 19050 . $builddepsfile 19051 # Now extract variables from the builddeps.conf files. 19052 theroot=${builddep_devkit_ROOT} 19053 thecflags=${builddep_devkit_CFLAGS} 19054 thelibs=${builddep_devkit_LIBS} 19055 if test "x$depdir" = x; then 19056 as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5 19057 fi 19058 DEVKIT=$depdir 19059 if test "x$theroot" != x; then 19060 DEVKIT="$theroot" 19061 fi 19062 if test "x$thecflags" != x; then 19063 DEVKIT_CFLAGS="$thecflags" 19064 fi 19065 if test "x$thelibs" != x; then 19066 DEVKIT_LIBS="$thelibs" 19067 fi 19068 # Found devkit 19069 PATH="$DEVKIT/bin:$PATH" 19070 SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root" 19071 if test "x$x_includes" = "xNONE"; then 19072 x_includes="$SYS_ROOT/usr/include/X11" 19073 fi 19074 if test "x$x_libraries" = "xNONE"; then 19075 x_libraries="$SYS_ROOT/usr/lib" 19076 fi 19077 19078 19079 fi 19080 19081 fi 19082 19083 19084 # Store the CFLAGS etal passed to the configure script. 19085 ORG_CFLAGS="$CFLAGS" 19086 ORG_CXXFLAGS="$CXXFLAGS" 19087 ORG_OBJCFLAGS="$OBJCFLAGS" 19088 19089 # autoconf magic only relies on PATH, so update it if tools dir is specified 19090 OLD_PATH="$PATH" 19091 if test "x$TOOLS_DIR" != x; then 19092 PATH=$TOOLS_DIR:$PATH 19093 fi 19094 19095 19096 ### Locate C compiler (CC) 19097 19098 # On windows, only cl.exe is supported. 19099 # On Solaris, cc is preferred to gcc. 19100 # Elsewhere, gcc is preferred to cc. 19101 19102 if test "x$CC" != x; then 19103 COMPILER_CHECK_LIST="$CC" 19104 elif test "x$OPENJDK_TARGET_OS" = "xwindows"; then 19105 COMPILER_CHECK_LIST="cl" 19106 elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 19107 COMPILER_CHECK_LIST="cc gcc" 19108 else 19109 COMPILER_CHECK_LIST="gcc cc" 19110 fi 19111 19112 19113 COMPILER_NAME=C 19114 19115 CC= 19116 # If TOOLS_DIR is set, check for all compiler names in there first 19117 # before checking the rest of the PATH. 19118 if test -n "$TOOLS_DIR"; then 19119 PATH_save="$PATH" 19120 PATH="$TOOLS_DIR" 19121 for ac_prog in $COMPILER_CHECK_LIST 19122 do 19123 # Extract the first word of "$ac_prog", so it can be a program name with args. 19124 set dummy $ac_prog; ac_word=$2 19125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19126 $as_echo_n "checking for $ac_word... " >&6; } 19127 if ${ac_cv_path_TOOLS_DIR_CC+:} false; then : 19128 $as_echo_n "(cached) " >&6 19129 else 19130 case $TOOLS_DIR_CC in 19131 [\\/]* | ?:[\\/]*) 19132 ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path. 19133 ;; 19134 *) 19135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19136 for as_dir in $PATH 19137 do 19138 IFS=$as_save_IFS 19139 test -z "$as_dir" && as_dir=. 19140 for ac_exec_ext in '' $ac_executable_extensions; do 19141 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19142 ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext" 19143 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19144 break 2 19145 fi 19146 done 19147 done 19148 IFS=$as_save_IFS 19149 19150 ;; 19151 esac 19152 fi 19153 TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC 19154 if test -n "$TOOLS_DIR_CC"; then 19155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5 19156 $as_echo "$TOOLS_DIR_CC" >&6; } 19157 else 19158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19159 $as_echo "no" >&6; } 19160 fi 19161 19162 19163 test -n "$TOOLS_DIR_CC" && break 19164 done 19165 19166 CC=$TOOLS_DIR_CC 19167 PATH="$PATH_save" 19168 fi 19169 19170 # AC_PATH_PROGS can't be run multiple times with the same variable, 19171 # so create a new name for this run. 19172 if test "x$CC" = x; then 19173 for ac_prog in $COMPILER_CHECK_LIST 19174 do 19175 # Extract the first word of "$ac_prog", so it can be a program name with args. 19176 set dummy $ac_prog; ac_word=$2 19177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19178 $as_echo_n "checking for $ac_word... " >&6; } 19179 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 19180 $as_echo_n "(cached) " >&6 19181 else 19182 case $POTENTIAL_CC in 19183 [\\/]* | ?:[\\/]*) 19184 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 19185 ;; 19186 *) 19187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19188 for as_dir in $PATH 19189 do 19190 IFS=$as_save_IFS 19191 test -z "$as_dir" && as_dir=. 19192 for ac_exec_ext in '' $ac_executable_extensions; do 19193 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19194 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 19195 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19196 break 2 19197 fi 19198 done 19199 done 19200 IFS=$as_save_IFS 19201 19202 ;; 19203 esac 19204 fi 19205 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 19206 if test -n "$POTENTIAL_CC"; then 19207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 19208 $as_echo "$POTENTIAL_CC" >&6; } 19209 else 19210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19211 $as_echo "no" >&6; } 19212 fi 19213 19214 19215 test -n "$POTENTIAL_CC" && break 19216 done 19217 19218 CC=$POTENTIAL_CC 19219 fi 19220 19221 if test "x$CC" = x; then 19222 19223 # Print a helpful message on how to acquire the necessary build dependency. 19224 # devkit is the help tag: freetyp2, cups, pulse, alsa etc 19225 MISSING_DEPENDENCY=devkit 19226 PKGHANDLER_COMMAND= 19227 19228 case $PKGHANDLER in 19229 apt-get) 19230 apt_help $MISSING_DEPENDENCY ;; 19231 yum) 19232 yum_help $MISSING_DEPENDENCY ;; 19233 port) 19234 port_help $MISSING_DEPENDENCY ;; 19235 pkgutil) 19236 pkgutil_help $MISSING_DEPENDENCY ;; 19237 pkgadd) 19238 pkgadd_help $MISSING_DEPENDENCY ;; 19239 * ) 19240 break ;; 19241 esac 19242 19243 if test "x$PKGHANDLER_COMMAND" != x; then 19244 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 19245 fi 19246 19247 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 19248 fi 19249 19250 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19251 19252 # First separate the path from the arguments. This will split at the first 19253 # space. 19254 complete="$CC" 19255 path="${complete%% *}" 19256 tmp="$complete EOL" 19257 arguments="${tmp#* }" 19258 19259 # Input might be given as Windows format, start by converting to 19260 # unix format. 19261 new_path=`$CYGPATH -u "$path"` 19262 19263 # Now try to locate executable using which 19264 new_path=`$WHICH "$new_path" 2> /dev/null` 19265 # bat and cmd files are not always considered executable in cygwin causing which 19266 # to not find them 19267 if test "x$new_path" = x \ 19268 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19269 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19270 new_path=`$CYGPATH -u "$path"` 19271 fi 19272 if test "x$new_path" = x; then 19273 # Oops. Which didn't find the executable. 19274 # The splitting of arguments from the executable at a space might have been incorrect, 19275 # since paths with space are more likely in Windows. Give it another try with the whole 19276 # argument. 19277 path="$complete" 19278 arguments="EOL" 19279 new_path=`$CYGPATH -u "$path"` 19280 new_path=`$WHICH "$new_path" 2> /dev/null` 19281 # bat and cmd files are not always considered executable in cygwin causing which 19282 # to not find them 19283 if test "x$new_path" = x \ 19284 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19285 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19286 new_path=`$CYGPATH -u "$path"` 19287 fi 19288 if test "x$new_path" = x; then 19289 # It's still not found. Now this is an unrecoverable error. 19290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19291 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19292 has_space=`$ECHO "$complete" | $GREP " "` 19293 if test "x$has_space" != x; then 19294 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19295 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19296 fi 19297 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19298 fi 19299 fi 19300 19301 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19302 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19303 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19304 # "foo.exe" is OK but "foo" is an error. 19305 # 19306 # This test is therefore slightly more accurate than "test -f" to check for file precense. 19307 # It is also a way to make sure we got the proper file name for the real test later on. 19308 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19309 if test "x$test_shortpath" = x; then 19310 # Short path failed, file does not exist as specified. 19311 # Try adding .exe or .cmd 19312 if test -f "${new_path}.exe"; then 19313 input_to_shortpath="${new_path}.exe" 19314 elif test -f "${new_path}.cmd"; then 19315 input_to_shortpath="${new_path}.cmd" 19316 else 19317 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 19318 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 19319 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19320 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19321 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19322 fi 19323 else 19324 input_to_shortpath="$new_path" 19325 fi 19326 19327 # Call helper function which possibly converts this using DOS-style short mode. 19328 # If so, the updated path is stored in $new_path. 19329 new_path="$input_to_shortpath" 19330 19331 input_path="$input_to_shortpath" 19332 # Check if we need to convert this using DOS-style short mode. If the path 19333 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19334 # take no chances and rewrite it. 19335 # Note: m4 eats our [], so we need to use [ and ] instead. 19336 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19337 if test "x$has_forbidden_chars" != x; then 19338 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19339 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19340 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19341 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19342 # Going to short mode and back again did indeed matter. Since short mode is 19343 # case insensitive, let's make it lowercase to improve readability. 19344 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19345 # Now convert it back to Unix-stile (cygpath) 19346 input_path=`$CYGPATH -u "$shortmode_path"` 19347 new_path="$input_path" 19348 fi 19349 fi 19350 19351 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19352 if test "x$test_cygdrive_prefix" = x; then 19353 # As a simple fix, exclude /usr/bin since it's not a real path. 19354 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19355 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19356 # a path prefixed by /cygdrive for fixpath to work. 19357 new_path="$CYGWIN_ROOT_PATH$input_path" 19358 fi 19359 fi 19360 19361 # remove trailing .exe if any 19362 new_path="${new_path/%.exe/}" 19363 19364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19365 19366 # First separate the path from the arguments. This will split at the first 19367 # space. 19368 complete="$CC" 19369 path="${complete%% *}" 19370 tmp="$complete EOL" 19371 arguments="${tmp#* }" 19372 19373 # Input might be given as Windows format, start by converting to 19374 # unix format. 19375 new_path="$path" 19376 19377 windows_path="$new_path" 19378 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19379 unix_path=`$CYGPATH -u "$windows_path"` 19380 new_path="$unix_path" 19381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19382 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19383 new_path="$unix_path" 19384 fi 19385 19386 19387 # Now try to locate executable using which 19388 new_path=`$WHICH "$new_path" 2> /dev/null` 19389 19390 if test "x$new_path" = x; then 19391 # Oops. Which didn't find the executable. 19392 # The splitting of arguments from the executable at a space might have been incorrect, 19393 # since paths with space are more likely in Windows. Give it another try with the whole 19394 # argument. 19395 path="$complete" 19396 arguments="EOL" 19397 new_path="$path" 19398 19399 windows_path="$new_path" 19400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19401 unix_path=`$CYGPATH -u "$windows_path"` 19402 new_path="$unix_path" 19403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19404 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19405 new_path="$unix_path" 19406 fi 19407 19408 19409 new_path=`$WHICH "$new_path" 2> /dev/null` 19410 19411 if test "x$new_path" = x; then 19412 # It's still not found. Now this is an unrecoverable error. 19413 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19414 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19415 has_space=`$ECHO "$complete" | $GREP " "` 19416 if test "x$has_space" != x; then 19417 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19418 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19419 fi 19420 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19421 fi 19422 fi 19423 19424 # Now new_path has a complete unix path to the binary 19425 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19426 # Keep paths in /bin as-is, but remove trailing .exe if any 19427 new_path="${new_path/%.exe/}" 19428 # Do not save /bin paths to all_fixpath_prefixes! 19429 else 19430 # Not in mixed or Windows style, start by that. 19431 new_path=`cmd //c echo $new_path` 19432 19433 input_path="$new_path" 19434 # Check if we need to convert this using DOS-style short mode. If the path 19435 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19436 # take no chances and rewrite it. 19437 # Note: m4 eats our [], so we need to use [ and ] instead. 19438 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19439 if test "x$has_forbidden_chars" != x; then 19440 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19441 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19442 fi 19443 19444 # Output is in $new_path 19445 19446 windows_path="$new_path" 19447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19448 unix_path=`$CYGPATH -u "$windows_path"` 19449 new_path="$unix_path" 19450 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19451 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19452 new_path="$unix_path" 19453 fi 19454 19455 # remove trailing .exe if any 19456 new_path="${new_path/%.exe/}" 19457 19458 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19459 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19460 fi 19461 19462 else 19463 # We're on a posix platform. Hooray! :) 19464 # First separate the path from the arguments. This will split at the first 19465 # space. 19466 complete="$CC" 19467 path="${complete%% *}" 19468 tmp="$complete EOL" 19469 arguments="${tmp#* }" 19470 19471 # Cannot rely on the command "which" here since it doesn't always work. 19472 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19473 if test -z "$is_absolute_path"; then 19474 # Path to executable is not absolute. Find it. 19475 IFS_save="$IFS" 19476 IFS=: 19477 for p in $PATH; do 19478 if test -f "$p/$path" && test -x "$p/$path"; then 19479 new_path="$p/$path" 19480 break 19481 fi 19482 done 19483 IFS="$IFS_save" 19484 else 19485 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CC (as $path) failed, using $path directly." >&5 19486 $as_echo "$as_me: Resolving CC (as $path) failed, using $path directly." >&6;} 19487 new_path="$path" 19488 fi 19489 19490 if test "x$new_path" = x; then 19491 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 19492 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 19493 has_space=`$ECHO "$complete" | $GREP " "` 19494 if test "x$has_space" != x; then 19495 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19496 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19497 fi 19498 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 19499 fi 19500 fi 19501 19502 # Now join together the path and the arguments once again 19503 if test "x$arguments" != xEOL; then 19504 new_complete="$new_path ${arguments% *}" 19505 else 19506 new_complete="$new_path" 19507 fi 19508 19509 if test "x$complete" != "x$new_complete"; then 19510 CC="$new_complete" 19511 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 19512 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 19513 fi 19514 19515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 19516 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 19517 TEST_COMPILER="$CC" 19518 19519 if test "x$OPENJDK_BUILD_OS" != xwindows; then 19520 # Follow a chain of symbolic links. Use readlink 19521 # where it exists, else fall back to horribly 19522 # complicated shell code. 19523 if test "x$READLINK_TESTED" != yes; then 19524 # On MacOSX there is a readlink tool with a different 19525 # purpose than the GNU readlink tool. Check the found readlink. 19526 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 19527 if test "x$ISGNU" = x; then 19528 # A readlink that we do not know how to use. 19529 # Are there other non-GNU readlinks out there? 19530 READLINK_TESTED=yes 19531 READLINK= 19532 fi 19533 fi 19534 19535 if test "x$READLINK" != x; then 19536 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 19537 else 19538 # Save the current directory for restoring afterwards 19539 STARTDIR=$PWD 19540 COUNTER=0 19541 sym_link_dir=`$DIRNAME $TEST_COMPILER` 19542 sym_link_file=`$BASENAME $TEST_COMPILER` 19543 cd $sym_link_dir 19544 # Use -P flag to resolve symlinks in directories. 19545 cd `$THEPWDCMD -P` 19546 sym_link_dir=`$THEPWDCMD -P` 19547 # Resolve file symlinks 19548 while test $COUNTER -lt 20; do 19549 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 19550 if test "x$ISLINK" == x; then 19551 # This is not a symbolic link! We are done! 19552 break 19553 fi 19554 # Again resolve directory symlinks since the target of the just found 19555 # link could be in a different directory 19556 cd `$DIRNAME $ISLINK` 19557 sym_link_dir=`$THEPWDCMD -P` 19558 sym_link_file=`$BASENAME $ISLINK` 19559 let COUNTER=COUNTER+1 19560 done 19561 cd $STARTDIR 19562 TEST_COMPILER=$sym_link_dir/$sym_link_file 19563 fi 19564 fi 19565 19566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 19567 $as_echo "$TEST_COMPILER" >&6; } 19568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5 19569 $as_echo_n "checking if CC is disguised ccache... " >&6; } 19570 19571 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 19572 if test "x$COMPILER_BASENAME" = "xccache"; then 19573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 19574 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 19575 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 19576 # We want to control ccache invocation ourselves, so ignore this cc and try 19577 # searching again. 19578 19579 # Remove the path to the fake ccache cc from the PATH 19580 RETRY_COMPILER_SAVED_PATH="$PATH" 19581 COMPILER_DIRNAME=`$DIRNAME $CC` 19582 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 19583 19584 # Try again looking for our compiler 19585 if test -n "$ac_tool_prefix"; then 19586 for ac_prog in $COMPILER_CHECK_LIST 19587 do 19588 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 19589 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 19590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19591 $as_echo_n "checking for $ac_word... " >&6; } 19592 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then : 19593 $as_echo_n "(cached) " >&6 19594 else 19595 if test -n "$PROPER_COMPILER_CC"; then 19596 ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test. 19597 else 19598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19599 for as_dir in $PATH 19600 do 19601 IFS=$as_save_IFS 19602 test -z "$as_dir" && as_dir=. 19603 for ac_exec_ext in '' $ac_executable_extensions; do 19604 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19605 ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog" 19606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19607 break 2 19608 fi 19609 done 19610 done 19611 IFS=$as_save_IFS 19612 19613 fi 19614 fi 19615 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC 19616 if test -n "$PROPER_COMPILER_CC"; then 19617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 19618 $as_echo "$PROPER_COMPILER_CC" >&6; } 19619 else 19620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19621 $as_echo "no" >&6; } 19622 fi 19623 19624 19625 test -n "$PROPER_COMPILER_CC" && break 19626 done 19627 fi 19628 if test -z "$PROPER_COMPILER_CC"; then 19629 ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC 19630 for ac_prog in $COMPILER_CHECK_LIST 19631 do 19632 # Extract the first word of "$ac_prog", so it can be a program name with args. 19633 set dummy $ac_prog; ac_word=$2 19634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19635 $as_echo_n "checking for $ac_word... " >&6; } 19636 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then : 19637 $as_echo_n "(cached) " >&6 19638 else 19639 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 19640 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test. 19641 else 19642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19643 for as_dir in $PATH 19644 do 19645 IFS=$as_save_IFS 19646 test -z "$as_dir" && as_dir=. 19647 for ac_exec_ext in '' $ac_executable_extensions; do 19648 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 19649 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog" 19650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19651 break 2 19652 fi 19653 done 19654 done 19655 IFS=$as_save_IFS 19656 19657 fi 19658 fi 19659 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC 19660 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 19661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5 19662 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; } 19663 else 19664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19665 $as_echo "no" >&6; } 19666 fi 19667 19668 19669 test -n "$ac_ct_PROPER_COMPILER_CC" && break 19670 done 19671 19672 if test "x$ac_ct_PROPER_COMPILER_CC" = x; then 19673 PROPER_COMPILER_CC="" 19674 else 19675 case $cross_compiling:$ac_tool_warned in 19676 yes:) 19677 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 19678 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 19679 ac_tool_warned=yes ;; 19680 esac 19681 PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC 19682 fi 19683 fi 19684 19685 19686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19687 19688 # First separate the path from the arguments. This will split at the first 19689 # space. 19690 complete="$PROPER_COMPILER_CC" 19691 path="${complete%% *}" 19692 tmp="$complete EOL" 19693 arguments="${tmp#* }" 19694 19695 # Input might be given as Windows format, start by converting to 19696 # unix format. 19697 new_path=`$CYGPATH -u "$path"` 19698 19699 # Now try to locate executable using which 19700 new_path=`$WHICH "$new_path" 2> /dev/null` 19701 # bat and cmd files are not always considered executable in cygwin causing which 19702 # to not find them 19703 if test "x$new_path" = x \ 19704 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19705 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19706 new_path=`$CYGPATH -u "$path"` 19707 fi 19708 if test "x$new_path" = x; then 19709 # Oops. Which didn't find the executable. 19710 # The splitting of arguments from the executable at a space might have been incorrect, 19711 # since paths with space are more likely in Windows. Give it another try with the whole 19712 # argument. 19713 path="$complete" 19714 arguments="EOL" 19715 new_path=`$CYGPATH -u "$path"` 19716 new_path=`$WHICH "$new_path" 2> /dev/null` 19717 # bat and cmd files are not always considered executable in cygwin causing which 19718 # to not find them 19719 if test "x$new_path" = x \ 19720 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19721 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19722 new_path=`$CYGPATH -u "$path"` 19723 fi 19724 if test "x$new_path" = x; then 19725 # It's still not found. Now this is an unrecoverable error. 19726 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 19727 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 19728 has_space=`$ECHO "$complete" | $GREP " "` 19729 if test "x$has_space" != x; then 19730 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19731 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19732 fi 19733 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 19734 fi 19735 fi 19736 19737 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19738 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19739 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19740 # "foo.exe" is OK but "foo" is an error. 19741 # 19742 # This test is therefore slightly more accurate than "test -f" to check for file precense. 19743 # It is also a way to make sure we got the proper file name for the real test later on. 19744 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19745 if test "x$test_shortpath" = x; then 19746 # Short path failed, file does not exist as specified. 19747 # Try adding .exe or .cmd 19748 if test -f "${new_path}.exe"; then 19749 input_to_shortpath="${new_path}.exe" 19750 elif test -f "${new_path}.cmd"; then 19751 input_to_shortpath="${new_path}.cmd" 19752 else 19753 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5 19754 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;} 19755 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19756 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19757 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 19758 fi 19759 else 19760 input_to_shortpath="$new_path" 19761 fi 19762 19763 # Call helper function which possibly converts this using DOS-style short mode. 19764 # If so, the updated path is stored in $new_path. 19765 new_path="$input_to_shortpath" 19766 19767 input_path="$input_to_shortpath" 19768 # Check if we need to convert this using DOS-style short mode. If the path 19769 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19770 # take no chances and rewrite it. 19771 # Note: m4 eats our [], so we need to use [ and ] instead. 19772 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19773 if test "x$has_forbidden_chars" != x; then 19774 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19775 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19776 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19777 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19778 # Going to short mode and back again did indeed matter. Since short mode is 19779 # case insensitive, let's make it lowercase to improve readability. 19780 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19781 # Now convert it back to Unix-stile (cygpath) 19782 input_path=`$CYGPATH -u "$shortmode_path"` 19783 new_path="$input_path" 19784 fi 19785 fi 19786 19787 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19788 if test "x$test_cygdrive_prefix" = x; then 19789 # As a simple fix, exclude /usr/bin since it's not a real path. 19790 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19791 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19792 # a path prefixed by /cygdrive for fixpath to work. 19793 new_path="$CYGWIN_ROOT_PATH$input_path" 19794 fi 19795 fi 19796 19797 # remove trailing .exe if any 19798 new_path="${new_path/%.exe/}" 19799 19800 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19801 19802 # First separate the path from the arguments. This will split at the first 19803 # space. 19804 complete="$PROPER_COMPILER_CC" 19805 path="${complete%% *}" 19806 tmp="$complete EOL" 19807 arguments="${tmp#* }" 19808 19809 # Input might be given as Windows format, start by converting to 19810 # unix format. 19811 new_path="$path" 19812 19813 windows_path="$new_path" 19814 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19815 unix_path=`$CYGPATH -u "$windows_path"` 19816 new_path="$unix_path" 19817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19818 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19819 new_path="$unix_path" 19820 fi 19821 19822 19823 # Now try to locate executable using which 19824 new_path=`$WHICH "$new_path" 2> /dev/null` 19825 19826 if test "x$new_path" = x; then 19827 # Oops. Which didn't find the executable. 19828 # The splitting of arguments from the executable at a space might have been incorrect, 19829 # since paths with space are more likely in Windows. Give it another try with the whole 19830 # argument. 19831 path="$complete" 19832 arguments="EOL" 19833 new_path="$path" 19834 19835 windows_path="$new_path" 19836 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19837 unix_path=`$CYGPATH -u "$windows_path"` 19838 new_path="$unix_path" 19839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19840 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19841 new_path="$unix_path" 19842 fi 19843 19844 19845 new_path=`$WHICH "$new_path" 2> /dev/null` 19846 19847 if test "x$new_path" = x; then 19848 # It's still not found. Now this is an unrecoverable error. 19849 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 19850 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 19851 has_space=`$ECHO "$complete" | $GREP " "` 19852 if test "x$has_space" != x; then 19853 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19854 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19855 fi 19856 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 19857 fi 19858 fi 19859 19860 # Now new_path has a complete unix path to the binary 19861 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19862 # Keep paths in /bin as-is, but remove trailing .exe if any 19863 new_path="${new_path/%.exe/}" 19864 # Do not save /bin paths to all_fixpath_prefixes! 19865 else 19866 # Not in mixed or Windows style, start by that. 19867 new_path=`cmd //c echo $new_path` 19868 19869 input_path="$new_path" 19870 # Check if we need to convert this using DOS-style short mode. If the path 19871 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19872 # take no chances and rewrite it. 19873 # Note: m4 eats our [], so we need to use [ and ] instead. 19874 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19875 if test "x$has_forbidden_chars" != x; then 19876 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19877 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19878 fi 19879 19880 # Output is in $new_path 19881 19882 windows_path="$new_path" 19883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19884 unix_path=`$CYGPATH -u "$windows_path"` 19885 new_path="$unix_path" 19886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19888 new_path="$unix_path" 19889 fi 19890 19891 # remove trailing .exe if any 19892 new_path="${new_path/%.exe/}" 19893 19894 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19895 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19896 fi 19897 19898 else 19899 # We're on a posix platform. Hooray! :) 19900 # First separate the path from the arguments. This will split at the first 19901 # space. 19902 complete="$PROPER_COMPILER_CC" 19903 path="${complete%% *}" 19904 tmp="$complete EOL" 19905 arguments="${tmp#* }" 19906 19907 # Cannot rely on the command "which" here since it doesn't always work. 19908 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19909 if test -z "$is_absolute_path"; then 19910 # Path to executable is not absolute. Find it. 19911 IFS_save="$IFS" 19912 IFS=: 19913 for p in $PATH; do 19914 if test -f "$p/$path" && test -x "$p/$path"; then 19915 new_path="$p/$path" 19916 break 19917 fi 19918 done 19919 IFS="$IFS_save" 19920 else 19921 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&5 19922 $as_echo "$as_me: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&6;} 19923 new_path="$path" 19924 fi 19925 19926 if test "x$new_path" = x; then 19927 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 19928 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 19929 has_space=`$ECHO "$complete" | $GREP " "` 19930 if test "x$has_space" != x; then 19931 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19932 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19933 fi 19934 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 19935 fi 19936 fi 19937 19938 # Now join together the path and the arguments once again 19939 if test "x$arguments" != xEOL; then 19940 new_complete="$new_path ${arguments% *}" 19941 else 19942 new_complete="$new_path" 19943 fi 19944 19945 if test "x$complete" != "x$new_complete"; then 19946 PROPER_COMPILER_CC="$new_complete" 19947 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5 19948 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;} 19949 fi 19950 19951 PATH="$RETRY_COMPILER_SAVED_PATH" 19952 19953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5 19954 $as_echo_n "checking for resolved symbolic links for CC... " >&6; } 19955 19956 if test "x$OPENJDK_BUILD_OS" != xwindows; then 19957 # Follow a chain of symbolic links. Use readlink 19958 # where it exists, else fall back to horribly 19959 # complicated shell code. 19960 if test "x$READLINK_TESTED" != yes; then 19961 # On MacOSX there is a readlink tool with a different 19962 # purpose than the GNU readlink tool. Check the found readlink. 19963 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 19964 if test "x$ISGNU" = x; then 19965 # A readlink that we do not know how to use. 19966 # Are there other non-GNU readlinks out there? 19967 READLINK_TESTED=yes 19968 READLINK= 19969 fi 19970 fi 19971 19972 if test "x$READLINK" != x; then 19973 PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC` 19974 else 19975 # Save the current directory for restoring afterwards 19976 STARTDIR=$PWD 19977 COUNTER=0 19978 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC` 19979 sym_link_file=`$BASENAME $PROPER_COMPILER_CC` 19980 cd $sym_link_dir 19981 # Use -P flag to resolve symlinks in directories. 19982 cd `$THEPWDCMD -P` 19983 sym_link_dir=`$THEPWDCMD -P` 19984 # Resolve file symlinks 19985 while test $COUNTER -lt 20; do 19986 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 19987 if test "x$ISLINK" == x; then 19988 # This is not a symbolic link! We are done! 19989 break 19990 fi 19991 # Again resolve directory symlinks since the target of the just found 19992 # link could be in a different directory 19993 cd `$DIRNAME $ISLINK` 19994 sym_link_dir=`$THEPWDCMD -P` 19995 sym_link_file=`$BASENAME $ISLINK` 19996 let COUNTER=COUNTER+1 19997 done 19998 cd $STARTDIR 19999 PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file 20000 fi 20001 fi 20002 20003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 20004 $as_echo "$PROPER_COMPILER_CC" >&6; } 20005 CC="$PROPER_COMPILER_CC" 20006 else 20007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5 20008 $as_echo "no, keeping CC" >&6; } 20009 CC="$TEST_COMPILER" 20010 fi 20011 20012 COMPILER=$CC 20013 COMPILER_NAME=$COMPILER_NAME 20014 20015 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 20016 # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work 20017 COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1` 20018 $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 20019 if test $? -ne 0; then 20020 GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 20021 20022 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&5 20023 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;} 20024 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5 20025 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;} 20026 as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5 20027 else 20028 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"` 20029 COMPILER_VENDOR="Sun Studio" 20030 fi 20031 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 20032 # First line typically looks something like: 20033 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86 20034 COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 20035 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"` 20036 COMPILER_VENDOR="Microsoft CL.EXE" 20037 COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"` 20038 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 20039 if test "x$COMPILER_CPU_TEST" != "x80x86"; then 20040 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5 20041 fi 20042 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 20043 if test "x$COMPILER_CPU_TEST" != "xx64"; then 20044 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 20045 fi 20046 fi 20047 else 20048 COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 20049 # Check that this is likely to be GCC. 20050 $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null 20051 if test $? -ne 0; then 20052 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5 20053 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;} 20054 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5 20055 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;} 20056 as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5 20057 fi 20058 20059 # First line typically looks something like: 20060 # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2 20061 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"` 20062 COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"` 20063 fi 20064 # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker) 20065 CC_VERSION="$COMPILER_VERSION" 20066 # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker) 20067 CC_VENDOR="$COMPILER_VENDOR" 20068 20069 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5 20070 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;} 20071 20072 20073 # Now that we have resolved CC ourself, let autoconf have its go at it 20074 ac_ext=c 20075 ac_cpp='$CPP $CPPFLAGS' 20076 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 20077 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 20078 ac_compiler_gnu=$ac_cv_c_compiler_gnu 20079 if test -n "$ac_tool_prefix"; then 20080 for ac_prog in $CC 20081 do 20082 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 20083 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 20084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20085 $as_echo_n "checking for $ac_word... " >&6; } 20086 if ${ac_cv_prog_CC+:} false; then : 20087 $as_echo_n "(cached) " >&6 20088 else 20089 if test -n "$CC"; then 20090 ac_cv_prog_CC="$CC" # Let the user override the test. 20091 else 20092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20093 for as_dir in $PATH 20094 do 20095 IFS=$as_save_IFS 20096 test -z "$as_dir" && as_dir=. 20097 for ac_exec_ext in '' $ac_executable_extensions; do 20098 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20099 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 20100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20101 break 2 20102 fi 20103 done 20104 done 20105 IFS=$as_save_IFS 20106 20107 fi 20108 fi 20109 CC=$ac_cv_prog_CC 20110 if test -n "$CC"; then 20111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 20112 $as_echo "$CC" >&6; } 20113 else 20114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20115 $as_echo "no" >&6; } 20116 fi 20117 20118 20119 test -n "$CC" && break 20120 done 20121 fi 20122 if test -z "$CC"; then 20123 ac_ct_CC=$CC 20124 for ac_prog in $CC 20125 do 20126 # Extract the first word of "$ac_prog", so it can be a program name with args. 20127 set dummy $ac_prog; ac_word=$2 20128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20129 $as_echo_n "checking for $ac_word... " >&6; } 20130 if ${ac_cv_prog_ac_ct_CC+:} false; then : 20131 $as_echo_n "(cached) " >&6 20132 else 20133 if test -n "$ac_ct_CC"; then 20134 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 20135 else 20136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20137 for as_dir in $PATH 20138 do 20139 IFS=$as_save_IFS 20140 test -z "$as_dir" && as_dir=. 20141 for ac_exec_ext in '' $ac_executable_extensions; do 20142 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20143 ac_cv_prog_ac_ct_CC="$ac_prog" 20144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20145 break 2 20146 fi 20147 done 20148 done 20149 IFS=$as_save_IFS 20150 20151 fi 20152 fi 20153 ac_ct_CC=$ac_cv_prog_ac_ct_CC 20154 if test -n "$ac_ct_CC"; then 20155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 20156 $as_echo "$ac_ct_CC" >&6; } 20157 else 20158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20159 $as_echo "no" >&6; } 20160 fi 20161 20162 20163 test -n "$ac_ct_CC" && break 20164 done 20165 20166 if test "x$ac_ct_CC" = x; then 20167 CC="" 20168 else 20169 case $cross_compiling:$ac_tool_warned in 20170 yes:) 20171 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 20172 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 20173 ac_tool_warned=yes ;; 20174 esac 20175 CC=$ac_ct_CC 20176 fi 20177 fi 20178 20179 20180 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20181 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20182 as_fn_error $? "no acceptable C compiler found in \$PATH 20183 See \`config.log' for more details" "$LINENO" 5; } 20184 20185 # Provide some information about the compiler. 20186 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 20187 set X $ac_compile 20188 ac_compiler=$2 20189 for ac_option in --version -v -V -qversion; do 20190 { { ac_try="$ac_compiler $ac_option >&5" 20191 case "(($ac_try" in 20192 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20193 *) ac_try_echo=$ac_try;; 20194 esac 20195 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20196 $as_echo "$ac_try_echo"; } >&5 20197 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 20198 ac_status=$? 20199 if test -s conftest.err; then 20200 sed '10a\ 20201 ... rest of stderr output deleted ... 20202 10q' conftest.err >conftest.er1 20203 cat conftest.er1 >&5 20204 fi 20205 rm -f conftest.er1 conftest.err 20206 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20207 test $ac_status = 0; } 20208 done 20209 20210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20211 /* end confdefs.h. */ 20212 20213 int 20214 main () 20215 { 20216 20217 ; 20218 return 0; 20219 } 20220 _ACEOF 20221 ac_clean_files_save=$ac_clean_files 20222 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 20223 # Try to create an executable without -o first, disregard a.out. 20224 # It will help us diagnose broken compilers, and finding out an intuition 20225 # of exeext. 20226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 20227 $as_echo_n "checking whether the C compiler works... " >&6; } 20228 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 20229 20230 # The possible output files: 20231 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 20232 20233 ac_rmfiles= 20234 for ac_file in $ac_files 20235 do 20236 case $ac_file in 20237 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 20238 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 20239 esac 20240 done 20241 rm -f $ac_rmfiles 20242 20243 if { { ac_try="$ac_link_default" 20244 case "(($ac_try" in 20245 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20246 *) ac_try_echo=$ac_try;; 20247 esac 20248 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20249 $as_echo "$ac_try_echo"; } >&5 20250 (eval "$ac_link_default") 2>&5 20251 ac_status=$? 20252 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20253 test $ac_status = 0; }; then : 20254 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 20255 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 20256 # in a Makefile. We should not override ac_cv_exeext if it was cached, 20257 # so that the user can short-circuit this test for compilers unknown to 20258 # Autoconf. 20259 for ac_file in $ac_files '' 20260 do 20261 test -f "$ac_file" || continue 20262 case $ac_file in 20263 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 20264 ;; 20265 [ab].out ) 20266 # We found the default executable, but exeext='' is most 20267 # certainly right. 20268 break;; 20269 *.* ) 20270 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 20271 then :; else 20272 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 20273 fi 20274 # We set ac_cv_exeext here because the later test for it is not 20275 # safe: cross compilers may not add the suffix if given an `-o' 20276 # argument, so we may need to know it at that point already. 20277 # Even if this section looks crufty: it has the advantage of 20278 # actually working. 20279 break;; 20280 * ) 20281 break;; 20282 esac 20283 done 20284 test "$ac_cv_exeext" = no && ac_cv_exeext= 20285 20286 else 20287 ac_file='' 20288 fi 20289 if test -z "$ac_file"; then : 20290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20291 $as_echo "no" >&6; } 20292 $as_echo "$as_me: failed program was:" >&5 20293 sed 's/^/| /' conftest.$ac_ext >&5 20294 20295 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20296 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20297 as_fn_error 77 "C compiler cannot create executables 20298 See \`config.log' for more details" "$LINENO" 5; } 20299 else 20300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20301 $as_echo "yes" >&6; } 20302 fi 20303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 20304 $as_echo_n "checking for C compiler default output file name... " >&6; } 20305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 20306 $as_echo "$ac_file" >&6; } 20307 ac_exeext=$ac_cv_exeext 20308 20309 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 20310 ac_clean_files=$ac_clean_files_save 20311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 20312 $as_echo_n "checking for suffix of executables... " >&6; } 20313 if { { ac_try="$ac_link" 20314 case "(($ac_try" in 20315 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20316 *) ac_try_echo=$ac_try;; 20317 esac 20318 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20319 $as_echo "$ac_try_echo"; } >&5 20320 (eval "$ac_link") 2>&5 20321 ac_status=$? 20322 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20323 test $ac_status = 0; }; then : 20324 # If both `conftest.exe' and `conftest' are `present' (well, observable) 20325 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 20326 # work properly (i.e., refer to `conftest.exe'), while it won't with 20327 # `rm'. 20328 for ac_file in conftest.exe conftest conftest.*; do 20329 test -f "$ac_file" || continue 20330 case $ac_file in 20331 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 20332 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 20333 break;; 20334 * ) break;; 20335 esac 20336 done 20337 else 20338 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20339 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20340 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 20341 See \`config.log' for more details" "$LINENO" 5; } 20342 fi 20343 rm -f conftest conftest$ac_cv_exeext 20344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 20345 $as_echo "$ac_cv_exeext" >&6; } 20346 20347 rm -f conftest.$ac_ext 20348 EXEEXT=$ac_cv_exeext 20349 ac_exeext=$EXEEXT 20350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20351 /* end confdefs.h. */ 20352 #include <stdio.h> 20353 int 20354 main () 20355 { 20356 FILE *f = fopen ("conftest.out", "w"); 20357 return ferror (f) || fclose (f) != 0; 20358 20359 ; 20360 return 0; 20361 } 20362 _ACEOF 20363 ac_clean_files="$ac_clean_files conftest.out" 20364 # Check that the compiler produces executables we can run. If not, either 20365 # the compiler is broken, or we cross compile. 20366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 20367 $as_echo_n "checking whether we are cross compiling... " >&6; } 20368 if test "$cross_compiling" != yes; then 20369 { { ac_try="$ac_link" 20370 case "(($ac_try" in 20371 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20372 *) ac_try_echo=$ac_try;; 20373 esac 20374 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20375 $as_echo "$ac_try_echo"; } >&5 20376 (eval "$ac_link") 2>&5 20377 ac_status=$? 20378 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20379 test $ac_status = 0; } 20380 if { ac_try='./conftest$ac_cv_exeext' 20381 { { case "(($ac_try" in 20382 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20383 *) ac_try_echo=$ac_try;; 20384 esac 20385 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20386 $as_echo "$ac_try_echo"; } >&5 20387 (eval "$ac_try") 2>&5 20388 ac_status=$? 20389 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20390 test $ac_status = 0; }; }; then 20391 cross_compiling=no 20392 else 20393 if test "$cross_compiling" = maybe; then 20394 cross_compiling=yes 20395 else 20396 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20397 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20398 as_fn_error $? "cannot run C compiled programs. 20399 If you meant to cross compile, use \`--host'. 20400 See \`config.log' for more details" "$LINENO" 5; } 20401 fi 20402 fi 20403 fi 20404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 20405 $as_echo "$cross_compiling" >&6; } 20406 20407 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 20408 ac_clean_files=$ac_clean_files_save 20409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 20410 $as_echo_n "checking for suffix of object files... " >&6; } 20411 if ${ac_cv_objext+:} false; then : 20412 $as_echo_n "(cached) " >&6 20413 else 20414 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20415 /* end confdefs.h. */ 20416 20417 int 20418 main () 20419 { 20420 20421 ; 20422 return 0; 20423 } 20424 _ACEOF 20425 rm -f conftest.o conftest.obj 20426 if { { ac_try="$ac_compile" 20427 case "(($ac_try" in 20428 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 20429 *) ac_try_echo=$ac_try;; 20430 esac 20431 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 20432 $as_echo "$ac_try_echo"; } >&5 20433 (eval "$ac_compile") 2>&5 20434 ac_status=$? 20435 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 20436 test $ac_status = 0; }; then : 20437 for ac_file in conftest.o conftest.obj conftest.*; do 20438 test -f "$ac_file" || continue; 20439 case $ac_file in 20440 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 20441 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 20442 break;; 20443 esac 20444 done 20445 else 20446 $as_echo "$as_me: failed program was:" >&5 20447 sed 's/^/| /' conftest.$ac_ext >&5 20448 20449 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20450 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 20451 as_fn_error $? "cannot compute suffix of object files: cannot compile 20452 See \`config.log' for more details" "$LINENO" 5; } 20453 fi 20454 rm -f conftest.$ac_cv_objext conftest.$ac_ext 20455 fi 20456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 20457 $as_echo "$ac_cv_objext" >&6; } 20458 OBJEXT=$ac_cv_objext 20459 ac_objext=$OBJEXT 20460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 20461 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 20462 if ${ac_cv_c_compiler_gnu+:} false; then : 20463 $as_echo_n "(cached) " >&6 20464 else 20465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20466 /* end confdefs.h. */ 20467 20468 int 20469 main () 20470 { 20471 #ifndef __GNUC__ 20472 choke me 20473 #endif 20474 20475 ; 20476 return 0; 20477 } 20478 _ACEOF 20479 if ac_fn_c_try_compile "$LINENO"; then : 20480 ac_compiler_gnu=yes 20481 else 20482 ac_compiler_gnu=no 20483 fi 20484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20485 ac_cv_c_compiler_gnu=$ac_compiler_gnu 20486 20487 fi 20488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 20489 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 20490 if test $ac_compiler_gnu = yes; then 20491 GCC=yes 20492 else 20493 GCC= 20494 fi 20495 ac_test_CFLAGS=${CFLAGS+set} 20496 ac_save_CFLAGS=$CFLAGS 20497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 20498 $as_echo_n "checking whether $CC accepts -g... " >&6; } 20499 if ${ac_cv_prog_cc_g+:} false; then : 20500 $as_echo_n "(cached) " >&6 20501 else 20502 ac_save_c_werror_flag=$ac_c_werror_flag 20503 ac_c_werror_flag=yes 20504 ac_cv_prog_cc_g=no 20505 CFLAGS="-g" 20506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20507 /* end confdefs.h. */ 20508 20509 int 20510 main () 20511 { 20512 20513 ; 20514 return 0; 20515 } 20516 _ACEOF 20517 if ac_fn_c_try_compile "$LINENO"; then : 20518 ac_cv_prog_cc_g=yes 20519 else 20520 CFLAGS="" 20521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20522 /* end confdefs.h. */ 20523 20524 int 20525 main () 20526 { 20527 20528 ; 20529 return 0; 20530 } 20531 _ACEOF 20532 if ac_fn_c_try_compile "$LINENO"; then : 20533 20534 else 20535 ac_c_werror_flag=$ac_save_c_werror_flag 20536 CFLAGS="-g" 20537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20538 /* end confdefs.h. */ 20539 20540 int 20541 main () 20542 { 20543 20544 ; 20545 return 0; 20546 } 20547 _ACEOF 20548 if ac_fn_c_try_compile "$LINENO"; then : 20549 ac_cv_prog_cc_g=yes 20550 fi 20551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20552 fi 20553 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20554 fi 20555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 20556 ac_c_werror_flag=$ac_save_c_werror_flag 20557 fi 20558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 20559 $as_echo "$ac_cv_prog_cc_g" >&6; } 20560 if test "$ac_test_CFLAGS" = set; then 20561 CFLAGS=$ac_save_CFLAGS 20562 elif test $ac_cv_prog_cc_g = yes; then 20563 if test "$GCC" = yes; then 20564 CFLAGS="-g -O2" 20565 else 20566 CFLAGS="-g" 20567 fi 20568 else 20569 if test "$GCC" = yes; then 20570 CFLAGS="-O2" 20571 else 20572 CFLAGS= 20573 fi 20574 fi 20575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 20576 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 20577 if ${ac_cv_prog_cc_c89+:} false; then : 20578 $as_echo_n "(cached) " >&6 20579 else 20580 ac_cv_prog_cc_c89=no 20581 ac_save_CC=$CC 20582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20583 /* end confdefs.h. */ 20584 #include <stdarg.h> 20585 #include <stdio.h> 20586 #include <sys/types.h> 20587 #include <sys/stat.h> 20588 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 20589 struct buf { int x; }; 20590 FILE * (*rcsopen) (struct buf *, struct stat *, int); 20591 static char *e (p, i) 20592 char **p; 20593 int i; 20594 { 20595 return p[i]; 20596 } 20597 static char *f (char * (*g) (char **, int), char **p, ...) 20598 { 20599 char *s; 20600 va_list v; 20601 va_start (v,p); 20602 s = g (p, va_arg (v,int)); 20603 va_end (v); 20604 return s; 20605 } 20606 20607 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 20608 function prototypes and stuff, but not '\xHH' hex character constants. 20609 These don't provoke an error unfortunately, instead are silently treated 20610 as 'x'. The following induces an error, until -std is added to get 20611 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 20612 array size at least. It's necessary to write '\x00'==0 to get something 20613 that's true only with -std. */ 20614 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 20615 20616 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 20617 inside strings and character constants. */ 20618 #define FOO(x) 'x' 20619 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 20620 20621 int test (int i, double x); 20622 struct s1 {int (*f) (int a);}; 20623 struct s2 {int (*f) (double a);}; 20624 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 20625 int argc; 20626 char **argv; 20627 int 20628 main () 20629 { 20630 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 20631 ; 20632 return 0; 20633 } 20634 _ACEOF 20635 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 20636 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 20637 do 20638 CC="$ac_save_CC $ac_arg" 20639 if ac_fn_c_try_compile "$LINENO"; then : 20640 ac_cv_prog_cc_c89=$ac_arg 20641 fi 20642 rm -f core conftest.err conftest.$ac_objext 20643 test "x$ac_cv_prog_cc_c89" != "xno" && break 20644 done 20645 rm -f conftest.$ac_ext 20646 CC=$ac_save_CC 20647 20648 fi 20649 # AC_CACHE_VAL 20650 case "x$ac_cv_prog_cc_c89" in 20651 x) 20652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 20653 $as_echo "none needed" >&6; } ;; 20654 xno) 20655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 20656 $as_echo "unsupported" >&6; } ;; 20657 *) 20658 CC="$CC $ac_cv_prog_cc_c89" 20659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 20660 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 20661 esac 20662 if test "x$ac_cv_prog_cc_c89" != xno; then : 20663 20664 fi 20665 20666 ac_ext=cpp 20667 ac_cpp='$CXXCPP $CPPFLAGS' 20668 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 20669 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 20670 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 20671 20672 20673 ### Locate C++ compiler (CXX) 20674 20675 if test "x$CXX" != x; then 20676 COMPILER_CHECK_LIST="$CXX" 20677 elif test "x$OPENJDK_TARGET_OS" = "xwindows"; then 20678 COMPILER_CHECK_LIST="cl" 20679 elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 20680 COMPILER_CHECK_LIST="CC g++" 20681 else 20682 COMPILER_CHECK_LIST="g++ CC" 20683 fi 20684 20685 20686 COMPILER_NAME=C++ 20687 20688 CXX= 20689 # If TOOLS_DIR is set, check for all compiler names in there first 20690 # before checking the rest of the PATH. 20691 if test -n "$TOOLS_DIR"; then 20692 PATH_save="$PATH" 20693 PATH="$TOOLS_DIR" 20694 for ac_prog in $COMPILER_CHECK_LIST 20695 do 20696 # Extract the first word of "$ac_prog", so it can be a program name with args. 20697 set dummy $ac_prog; ac_word=$2 20698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20699 $as_echo_n "checking for $ac_word... " >&6; } 20700 if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then : 20701 $as_echo_n "(cached) " >&6 20702 else 20703 case $TOOLS_DIR_CXX in 20704 [\\/]* | ?:[\\/]*) 20705 ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path. 20706 ;; 20707 *) 20708 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20709 for as_dir in $PATH 20710 do 20711 IFS=$as_save_IFS 20712 test -z "$as_dir" && as_dir=. 20713 for ac_exec_ext in '' $ac_executable_extensions; do 20714 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20715 ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext" 20716 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20717 break 2 20718 fi 20719 done 20720 done 20721 IFS=$as_save_IFS 20722 20723 ;; 20724 esac 20725 fi 20726 TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX 20727 if test -n "$TOOLS_DIR_CXX"; then 20728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5 20729 $as_echo "$TOOLS_DIR_CXX" >&6; } 20730 else 20731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20732 $as_echo "no" >&6; } 20733 fi 20734 20735 20736 test -n "$TOOLS_DIR_CXX" && break 20737 done 20738 20739 CXX=$TOOLS_DIR_CXX 20740 PATH="$PATH_save" 20741 fi 20742 20743 # AC_PATH_PROGS can't be run multiple times with the same variable, 20744 # so create a new name for this run. 20745 if test "x$CXX" = x; then 20746 for ac_prog in $COMPILER_CHECK_LIST 20747 do 20748 # Extract the first word of "$ac_prog", so it can be a program name with args. 20749 set dummy $ac_prog; ac_word=$2 20750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20751 $as_echo_n "checking for $ac_word... " >&6; } 20752 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 20753 $as_echo_n "(cached) " >&6 20754 else 20755 case $POTENTIAL_CXX in 20756 [\\/]* | ?:[\\/]*) 20757 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 20758 ;; 20759 *) 20760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20761 for as_dir in $PATH 20762 do 20763 IFS=$as_save_IFS 20764 test -z "$as_dir" && as_dir=. 20765 for ac_exec_ext in '' $ac_executable_extensions; do 20766 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 20767 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 20768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20769 break 2 20770 fi 20771 done 20772 done 20773 IFS=$as_save_IFS 20774 20775 ;; 20776 esac 20777 fi 20778 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 20779 if test -n "$POTENTIAL_CXX"; then 20780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 20781 $as_echo "$POTENTIAL_CXX" >&6; } 20782 else 20783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20784 $as_echo "no" >&6; } 20785 fi 20786 20787 20788 test -n "$POTENTIAL_CXX" && break 20789 done 20790 20791 CXX=$POTENTIAL_CXX 20792 fi 20793 20794 if test "x$CXX" = x; then 20795 20796 # Print a helpful message on how to acquire the necessary build dependency. 20797 # devkit is the help tag: freetyp2, cups, pulse, alsa etc 20798 MISSING_DEPENDENCY=devkit 20799 PKGHANDLER_COMMAND= 20800 20801 case $PKGHANDLER in 20802 apt-get) 20803 apt_help $MISSING_DEPENDENCY ;; 20804 yum) 20805 yum_help $MISSING_DEPENDENCY ;; 20806 port) 20807 port_help $MISSING_DEPENDENCY ;; 20808 pkgutil) 20809 pkgutil_help $MISSING_DEPENDENCY ;; 20810 pkgadd) 20811 pkgadd_help $MISSING_DEPENDENCY ;; 20812 * ) 20813 break ;; 20814 esac 20815 20816 if test "x$PKGHANDLER_COMMAND" != x; then 20817 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 20818 fi 20819 20820 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 20821 fi 20822 20823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20824 20825 # First separate the path from the arguments. This will split at the first 20826 # space. 20827 complete="$CXX" 20828 path="${complete%% *}" 20829 tmp="$complete EOL" 20830 arguments="${tmp#* }" 20831 20832 # Input might be given as Windows format, start by converting to 20833 # unix format. 20834 new_path=`$CYGPATH -u "$path"` 20835 20836 # Now try to locate executable using which 20837 new_path=`$WHICH "$new_path" 2> /dev/null` 20838 # bat and cmd files are not always considered executable in cygwin causing which 20839 # to not find them 20840 if test "x$new_path" = x \ 20841 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20842 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20843 new_path=`$CYGPATH -u "$path"` 20844 fi 20845 if test "x$new_path" = x; then 20846 # Oops. Which didn't find the executable. 20847 # The splitting of arguments from the executable at a space might have been incorrect, 20848 # since paths with space are more likely in Windows. Give it another try with the whole 20849 # argument. 20850 path="$complete" 20851 arguments="EOL" 20852 new_path=`$CYGPATH -u "$path"` 20853 new_path=`$WHICH "$new_path" 2> /dev/null` 20854 # bat and cmd files are not always considered executable in cygwin causing which 20855 # to not find them 20856 if test "x$new_path" = x \ 20857 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20858 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20859 new_path=`$CYGPATH -u "$path"` 20860 fi 20861 if test "x$new_path" = x; then 20862 # It's still not found. Now this is an unrecoverable error. 20863 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 20864 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 20865 has_space=`$ECHO "$complete" | $GREP " "` 20866 if test "x$has_space" != x; then 20867 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20868 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20869 fi 20870 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 20871 fi 20872 fi 20873 20874 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20875 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20876 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20877 # "foo.exe" is OK but "foo" is an error. 20878 # 20879 # This test is therefore slightly more accurate than "test -f" to check for file precense. 20880 # It is also a way to make sure we got the proper file name for the real test later on. 20881 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20882 if test "x$test_shortpath" = x; then 20883 # Short path failed, file does not exist as specified. 20884 # Try adding .exe or .cmd 20885 if test -f "${new_path}.exe"; then 20886 input_to_shortpath="${new_path}.exe" 20887 elif test -f "${new_path}.cmd"; then 20888 input_to_shortpath="${new_path}.cmd" 20889 else 20890 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 20891 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 20892 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20893 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20894 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 20895 fi 20896 else 20897 input_to_shortpath="$new_path" 20898 fi 20899 20900 # Call helper function which possibly converts this using DOS-style short mode. 20901 # If so, the updated path is stored in $new_path. 20902 new_path="$input_to_shortpath" 20903 20904 input_path="$input_to_shortpath" 20905 # Check if we need to convert this using DOS-style short mode. If the path 20906 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20907 # take no chances and rewrite it. 20908 # Note: m4 eats our [], so we need to use [ and ] instead. 20909 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20910 if test "x$has_forbidden_chars" != x; then 20911 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20912 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20913 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20914 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20915 # Going to short mode and back again did indeed matter. Since short mode is 20916 # case insensitive, let's make it lowercase to improve readability. 20917 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20918 # Now convert it back to Unix-stile (cygpath) 20919 input_path=`$CYGPATH -u "$shortmode_path"` 20920 new_path="$input_path" 20921 fi 20922 fi 20923 20924 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20925 if test "x$test_cygdrive_prefix" = x; then 20926 # As a simple fix, exclude /usr/bin since it's not a real path. 20927 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20928 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20929 # a path prefixed by /cygdrive for fixpath to work. 20930 new_path="$CYGWIN_ROOT_PATH$input_path" 20931 fi 20932 fi 20933 20934 # remove trailing .exe if any 20935 new_path="${new_path/%.exe/}" 20936 20937 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20938 20939 # First separate the path from the arguments. This will split at the first 20940 # space. 20941 complete="$CXX" 20942 path="${complete%% *}" 20943 tmp="$complete EOL" 20944 arguments="${tmp#* }" 20945 20946 # Input might be given as Windows format, start by converting to 20947 # unix format. 20948 new_path="$path" 20949 20950 windows_path="$new_path" 20951 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20952 unix_path=`$CYGPATH -u "$windows_path"` 20953 new_path="$unix_path" 20954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20955 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20956 new_path="$unix_path" 20957 fi 20958 20959 20960 # Now try to locate executable using which 20961 new_path=`$WHICH "$new_path" 2> /dev/null` 20962 20963 if test "x$new_path" = x; then 20964 # Oops. Which didn't find the executable. 20965 # The splitting of arguments from the executable at a space might have been incorrect, 20966 # since paths with space are more likely in Windows. Give it another try with the whole 20967 # argument. 20968 path="$complete" 20969 arguments="EOL" 20970 new_path="$path" 20971 20972 windows_path="$new_path" 20973 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20974 unix_path=`$CYGPATH -u "$windows_path"` 20975 new_path="$unix_path" 20976 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20977 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20978 new_path="$unix_path" 20979 fi 20980 20981 20982 new_path=`$WHICH "$new_path" 2> /dev/null` 20983 20984 if test "x$new_path" = x; then 20985 # It's still not found. Now this is an unrecoverable error. 20986 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 20987 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 20988 has_space=`$ECHO "$complete" | $GREP " "` 20989 if test "x$has_space" != x; then 20990 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20991 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20992 fi 20993 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 20994 fi 20995 fi 20996 20997 # Now new_path has a complete unix path to the binary 20998 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20999 # Keep paths in /bin as-is, but remove trailing .exe if any 21000 new_path="${new_path/%.exe/}" 21001 # Do not save /bin paths to all_fixpath_prefixes! 21002 else 21003 # Not in mixed or Windows style, start by that. 21004 new_path=`cmd //c echo $new_path` 21005 21006 input_path="$new_path" 21007 # Check if we need to convert this using DOS-style short mode. If the path 21008 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21009 # take no chances and rewrite it. 21010 # Note: m4 eats our [], so we need to use [ and ] instead. 21011 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21012 if test "x$has_forbidden_chars" != x; then 21013 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21014 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21015 fi 21016 21017 # Output is in $new_path 21018 21019 windows_path="$new_path" 21020 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21021 unix_path=`$CYGPATH -u "$windows_path"` 21022 new_path="$unix_path" 21023 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21024 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21025 new_path="$unix_path" 21026 fi 21027 21028 # remove trailing .exe if any 21029 new_path="${new_path/%.exe/}" 21030 21031 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21032 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21033 fi 21034 21035 else 21036 # We're on a posix platform. Hooray! :) 21037 # First separate the path from the arguments. This will split at the first 21038 # space. 21039 complete="$CXX" 21040 path="${complete%% *}" 21041 tmp="$complete EOL" 21042 arguments="${tmp#* }" 21043 21044 # Cannot rely on the command "which" here since it doesn't always work. 21045 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21046 if test -z "$is_absolute_path"; then 21047 # Path to executable is not absolute. Find it. 21048 IFS_save="$IFS" 21049 IFS=: 21050 for p in $PATH; do 21051 if test -f "$p/$path" && test -x "$p/$path"; then 21052 new_path="$p/$path" 21053 break 21054 fi 21055 done 21056 IFS="$IFS_save" 21057 else 21058 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXX (as $path) failed, using $path directly." >&5 21059 $as_echo "$as_me: Resolving CXX (as $path) failed, using $path directly." >&6;} 21060 new_path="$path" 21061 fi 21062 21063 if test "x$new_path" = x; then 21064 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 21065 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 21066 has_space=`$ECHO "$complete" | $GREP " "` 21067 if test "x$has_space" != x; then 21068 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21069 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21070 fi 21071 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 21072 fi 21073 fi 21074 21075 # Now join together the path and the arguments once again 21076 if test "x$arguments" != xEOL; then 21077 new_complete="$new_path ${arguments% *}" 21078 else 21079 new_complete="$new_path" 21080 fi 21081 21082 if test "x$complete" != "x$new_complete"; then 21083 CXX="$new_complete" 21084 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 21085 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 21086 fi 21087 21088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 21089 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 21090 TEST_COMPILER="$CXX" 21091 21092 if test "x$OPENJDK_BUILD_OS" != xwindows; then 21093 # Follow a chain of symbolic links. Use readlink 21094 # where it exists, else fall back to horribly 21095 # complicated shell code. 21096 if test "x$READLINK_TESTED" != yes; then 21097 # On MacOSX there is a readlink tool with a different 21098 # purpose than the GNU readlink tool. Check the found readlink. 21099 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 21100 if test "x$ISGNU" = x; then 21101 # A readlink that we do not know how to use. 21102 # Are there other non-GNU readlinks out there? 21103 READLINK_TESTED=yes 21104 READLINK= 21105 fi 21106 fi 21107 21108 if test "x$READLINK" != x; then 21109 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 21110 else 21111 # Save the current directory for restoring afterwards 21112 STARTDIR=$PWD 21113 COUNTER=0 21114 sym_link_dir=`$DIRNAME $TEST_COMPILER` 21115 sym_link_file=`$BASENAME $TEST_COMPILER` 21116 cd $sym_link_dir 21117 # Use -P flag to resolve symlinks in directories. 21118 cd `$THEPWDCMD -P` 21119 sym_link_dir=`$THEPWDCMD -P` 21120 # Resolve file symlinks 21121 while test $COUNTER -lt 20; do 21122 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 21123 if test "x$ISLINK" == x; then 21124 # This is not a symbolic link! We are done! 21125 break 21126 fi 21127 # Again resolve directory symlinks since the target of the just found 21128 # link could be in a different directory 21129 cd `$DIRNAME $ISLINK` 21130 sym_link_dir=`$THEPWDCMD -P` 21131 sym_link_file=`$BASENAME $ISLINK` 21132 let COUNTER=COUNTER+1 21133 done 21134 cd $STARTDIR 21135 TEST_COMPILER=$sym_link_dir/$sym_link_file 21136 fi 21137 fi 21138 21139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 21140 $as_echo "$TEST_COMPILER" >&6; } 21141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5 21142 $as_echo_n "checking if CXX is disguised ccache... " >&6; } 21143 21144 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 21145 if test "x$COMPILER_BASENAME" = "xccache"; then 21146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 21147 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 21148 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 21149 # We want to control ccache invocation ourselves, so ignore this cc and try 21150 # searching again. 21151 21152 # Remove the path to the fake ccache cc from the PATH 21153 RETRY_COMPILER_SAVED_PATH="$PATH" 21154 COMPILER_DIRNAME=`$DIRNAME $CXX` 21155 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 21156 21157 # Try again looking for our compiler 21158 if test -n "$ac_tool_prefix"; then 21159 for ac_prog in $COMPILER_CHECK_LIST 21160 do 21161 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 21162 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 21163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21164 $as_echo_n "checking for $ac_word... " >&6; } 21165 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then : 21166 $as_echo_n "(cached) " >&6 21167 else 21168 if test -n "$PROPER_COMPILER_CXX"; then 21169 ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test. 21170 else 21171 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21172 for as_dir in $PATH 21173 do 21174 IFS=$as_save_IFS 21175 test -z "$as_dir" && as_dir=. 21176 for ac_exec_ext in '' $ac_executable_extensions; do 21177 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21178 ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog" 21179 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21180 break 2 21181 fi 21182 done 21183 done 21184 IFS=$as_save_IFS 21185 21186 fi 21187 fi 21188 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX 21189 if test -n "$PROPER_COMPILER_CXX"; then 21190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 21191 $as_echo "$PROPER_COMPILER_CXX" >&6; } 21192 else 21193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21194 $as_echo "no" >&6; } 21195 fi 21196 21197 21198 test -n "$PROPER_COMPILER_CXX" && break 21199 done 21200 fi 21201 if test -z "$PROPER_COMPILER_CXX"; then 21202 ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX 21203 for ac_prog in $COMPILER_CHECK_LIST 21204 do 21205 # Extract the first word of "$ac_prog", so it can be a program name with args. 21206 set dummy $ac_prog; ac_word=$2 21207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21208 $as_echo_n "checking for $ac_word... " >&6; } 21209 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then : 21210 $as_echo_n "(cached) " >&6 21211 else 21212 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 21213 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test. 21214 else 21215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21216 for as_dir in $PATH 21217 do 21218 IFS=$as_save_IFS 21219 test -z "$as_dir" && as_dir=. 21220 for ac_exec_ext in '' $ac_executable_extensions; do 21221 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21222 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog" 21223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21224 break 2 21225 fi 21226 done 21227 done 21228 IFS=$as_save_IFS 21229 21230 fi 21231 fi 21232 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX 21233 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 21234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5 21235 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; } 21236 else 21237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21238 $as_echo "no" >&6; } 21239 fi 21240 21241 21242 test -n "$ac_ct_PROPER_COMPILER_CXX" && break 21243 done 21244 21245 if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then 21246 PROPER_COMPILER_CXX="" 21247 else 21248 case $cross_compiling:$ac_tool_warned in 21249 yes:) 21250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 21251 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 21252 ac_tool_warned=yes ;; 21253 esac 21254 PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX 21255 fi 21256 fi 21257 21258 21259 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21260 21261 # First separate the path from the arguments. This will split at the first 21262 # space. 21263 complete="$PROPER_COMPILER_CXX" 21264 path="${complete%% *}" 21265 tmp="$complete EOL" 21266 arguments="${tmp#* }" 21267 21268 # Input might be given as Windows format, start by converting to 21269 # unix format. 21270 new_path=`$CYGPATH -u "$path"` 21271 21272 # Now try to locate executable using which 21273 new_path=`$WHICH "$new_path" 2> /dev/null` 21274 # bat and cmd files are not always considered executable in cygwin causing which 21275 # to not find them 21276 if test "x$new_path" = x \ 21277 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21278 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21279 new_path=`$CYGPATH -u "$path"` 21280 fi 21281 if test "x$new_path" = x; then 21282 # Oops. Which didn't find the executable. 21283 # The splitting of arguments from the executable at a space might have been incorrect, 21284 # since paths with space are more likely in Windows. Give it another try with the whole 21285 # argument. 21286 path="$complete" 21287 arguments="EOL" 21288 new_path=`$CYGPATH -u "$path"` 21289 new_path=`$WHICH "$new_path" 2> /dev/null` 21290 # bat and cmd files are not always considered executable in cygwin causing which 21291 # to not find them 21292 if test "x$new_path" = x \ 21293 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21294 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21295 new_path=`$CYGPATH -u "$path"` 21296 fi 21297 if test "x$new_path" = x; then 21298 # It's still not found. Now this is an unrecoverable error. 21299 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21300 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21301 has_space=`$ECHO "$complete" | $GREP " "` 21302 if test "x$has_space" != x; then 21303 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21304 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21305 fi 21306 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21307 fi 21308 fi 21309 21310 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21311 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21312 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21313 # "foo.exe" is OK but "foo" is an error. 21314 # 21315 # This test is therefore slightly more accurate than "test -f" to check for file precense. 21316 # It is also a way to make sure we got the proper file name for the real test later on. 21317 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21318 if test "x$test_shortpath" = x; then 21319 # Short path failed, file does not exist as specified. 21320 # Try adding .exe or .cmd 21321 if test -f "${new_path}.exe"; then 21322 input_to_shortpath="${new_path}.exe" 21323 elif test -f "${new_path}.cmd"; then 21324 input_to_shortpath="${new_path}.cmd" 21325 else 21326 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5 21327 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;} 21328 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21329 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21330 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21331 fi 21332 else 21333 input_to_shortpath="$new_path" 21334 fi 21335 21336 # Call helper function which possibly converts this using DOS-style short mode. 21337 # If so, the updated path is stored in $new_path. 21338 new_path="$input_to_shortpath" 21339 21340 input_path="$input_to_shortpath" 21341 # Check if we need to convert this using DOS-style short mode. If the path 21342 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21343 # take no chances and rewrite it. 21344 # Note: m4 eats our [], so we need to use [ and ] instead. 21345 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21346 if test "x$has_forbidden_chars" != x; then 21347 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21348 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21349 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21350 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21351 # Going to short mode and back again did indeed matter. Since short mode is 21352 # case insensitive, let's make it lowercase to improve readability. 21353 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21354 # Now convert it back to Unix-stile (cygpath) 21355 input_path=`$CYGPATH -u "$shortmode_path"` 21356 new_path="$input_path" 21357 fi 21358 fi 21359 21360 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21361 if test "x$test_cygdrive_prefix" = x; then 21362 # As a simple fix, exclude /usr/bin since it's not a real path. 21363 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21364 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21365 # a path prefixed by /cygdrive for fixpath to work. 21366 new_path="$CYGWIN_ROOT_PATH$input_path" 21367 fi 21368 fi 21369 21370 # remove trailing .exe if any 21371 new_path="${new_path/%.exe/}" 21372 21373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21374 21375 # First separate the path from the arguments. This will split at the first 21376 # space. 21377 complete="$PROPER_COMPILER_CXX" 21378 path="${complete%% *}" 21379 tmp="$complete EOL" 21380 arguments="${tmp#* }" 21381 21382 # Input might be given as Windows format, start by converting to 21383 # unix format. 21384 new_path="$path" 21385 21386 windows_path="$new_path" 21387 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21388 unix_path=`$CYGPATH -u "$windows_path"` 21389 new_path="$unix_path" 21390 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21391 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21392 new_path="$unix_path" 21393 fi 21394 21395 21396 # Now try to locate executable using which 21397 new_path=`$WHICH "$new_path" 2> /dev/null` 21398 21399 if test "x$new_path" = x; then 21400 # Oops. Which didn't find the executable. 21401 # The splitting of arguments from the executable at a space might have been incorrect, 21402 # since paths with space are more likely in Windows. Give it another try with the whole 21403 # argument. 21404 path="$complete" 21405 arguments="EOL" 21406 new_path="$path" 21407 21408 windows_path="$new_path" 21409 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21410 unix_path=`$CYGPATH -u "$windows_path"` 21411 new_path="$unix_path" 21412 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21413 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21414 new_path="$unix_path" 21415 fi 21416 21417 21418 new_path=`$WHICH "$new_path" 2> /dev/null` 21419 21420 if test "x$new_path" = x; then 21421 # It's still not found. Now this is an unrecoverable error. 21422 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21423 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21424 has_space=`$ECHO "$complete" | $GREP " "` 21425 if test "x$has_space" != x; then 21426 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21427 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21428 fi 21429 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21430 fi 21431 fi 21432 21433 # Now new_path has a complete unix path to the binary 21434 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21435 # Keep paths in /bin as-is, but remove trailing .exe if any 21436 new_path="${new_path/%.exe/}" 21437 # Do not save /bin paths to all_fixpath_prefixes! 21438 else 21439 # Not in mixed or Windows style, start by that. 21440 new_path=`cmd //c echo $new_path` 21441 21442 input_path="$new_path" 21443 # Check if we need to convert this using DOS-style short mode. If the path 21444 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21445 # take no chances and rewrite it. 21446 # Note: m4 eats our [], so we need to use [ and ] instead. 21447 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21448 if test "x$has_forbidden_chars" != x; then 21449 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21450 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21451 fi 21452 21453 # Output is in $new_path 21454 21455 windows_path="$new_path" 21456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21457 unix_path=`$CYGPATH -u "$windows_path"` 21458 new_path="$unix_path" 21459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21460 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21461 new_path="$unix_path" 21462 fi 21463 21464 # remove trailing .exe if any 21465 new_path="${new_path/%.exe/}" 21466 21467 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21468 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21469 fi 21470 21471 else 21472 # We're on a posix platform. Hooray! :) 21473 # First separate the path from the arguments. This will split at the first 21474 # space. 21475 complete="$PROPER_COMPILER_CXX" 21476 path="${complete%% *}" 21477 tmp="$complete EOL" 21478 arguments="${tmp#* }" 21479 21480 # Cannot rely on the command "which" here since it doesn't always work. 21481 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21482 if test -z "$is_absolute_path"; then 21483 # Path to executable is not absolute. Find it. 21484 IFS_save="$IFS" 21485 IFS=: 21486 for p in $PATH; do 21487 if test -f "$p/$path" && test -x "$p/$path"; then 21488 new_path="$p/$path" 21489 break 21490 fi 21491 done 21492 IFS="$IFS_save" 21493 else 21494 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&5 21495 $as_echo "$as_me: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&6;} 21496 new_path="$path" 21497 fi 21498 21499 if test "x$new_path" = x; then 21500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 21501 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 21502 has_space=`$ECHO "$complete" | $GREP " "` 21503 if test "x$has_space" != x; then 21504 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21505 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21506 fi 21507 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 21508 fi 21509 fi 21510 21511 # Now join together the path and the arguments once again 21512 if test "x$arguments" != xEOL; then 21513 new_complete="$new_path ${arguments% *}" 21514 else 21515 new_complete="$new_path" 21516 fi 21517 21518 if test "x$complete" != "x$new_complete"; then 21519 PROPER_COMPILER_CXX="$new_complete" 21520 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5 21521 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;} 21522 fi 21523 21524 PATH="$RETRY_COMPILER_SAVED_PATH" 21525 21526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5 21527 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; } 21528 21529 if test "x$OPENJDK_BUILD_OS" != xwindows; then 21530 # Follow a chain of symbolic links. Use readlink 21531 # where it exists, else fall back to horribly 21532 # complicated shell code. 21533 if test "x$READLINK_TESTED" != yes; then 21534 # On MacOSX there is a readlink tool with a different 21535 # purpose than the GNU readlink tool. Check the found readlink. 21536 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 21537 if test "x$ISGNU" = x; then 21538 # A readlink that we do not know how to use. 21539 # Are there other non-GNU readlinks out there? 21540 READLINK_TESTED=yes 21541 READLINK= 21542 fi 21543 fi 21544 21545 if test "x$READLINK" != x; then 21546 PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX` 21547 else 21548 # Save the current directory for restoring afterwards 21549 STARTDIR=$PWD 21550 COUNTER=0 21551 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX` 21552 sym_link_file=`$BASENAME $PROPER_COMPILER_CXX` 21553 cd $sym_link_dir 21554 # Use -P flag to resolve symlinks in directories. 21555 cd `$THEPWDCMD -P` 21556 sym_link_dir=`$THEPWDCMD -P` 21557 # Resolve file symlinks 21558 while test $COUNTER -lt 20; do 21559 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 21560 if test "x$ISLINK" == x; then 21561 # This is not a symbolic link! We are done! 21562 break 21563 fi 21564 # Again resolve directory symlinks since the target of the just found 21565 # link could be in a different directory 21566 cd `$DIRNAME $ISLINK` 21567 sym_link_dir=`$THEPWDCMD -P` 21568 sym_link_file=`$BASENAME $ISLINK` 21569 let COUNTER=COUNTER+1 21570 done 21571 cd $STARTDIR 21572 PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file 21573 fi 21574 fi 21575 21576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 21577 $as_echo "$PROPER_COMPILER_CXX" >&6; } 21578 CXX="$PROPER_COMPILER_CXX" 21579 else 21580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5 21581 $as_echo "no, keeping CXX" >&6; } 21582 CXX="$TEST_COMPILER" 21583 fi 21584 21585 COMPILER=$CXX 21586 COMPILER_NAME=$COMPILER_NAME 21587 21588 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 21589 # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work 21590 COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1` 21591 $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 21592 if test $? -ne 0; then 21593 GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 21594 21595 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&5 21596 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;} 21597 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5 21598 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;} 21599 as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5 21600 else 21601 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"` 21602 COMPILER_VENDOR="Sun Studio" 21603 fi 21604 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 21605 # First line typically looks something like: 21606 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.30319.01 for 80x86 21607 COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 21608 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"` 21609 COMPILER_VENDOR="Microsoft CL.EXE" 21610 COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"` 21611 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 21612 if test "x$COMPILER_CPU_TEST" != "x80x86"; then 21613 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5 21614 fi 21615 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 21616 if test "x$COMPILER_CPU_TEST" != "xx64"; then 21617 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 21618 fi 21619 fi 21620 else 21621 COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1` 21622 # Check that this is likely to be GCC. 21623 $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null 21624 if test $? -ne 0; then 21625 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5 21626 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;} 21627 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5 21628 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;} 21629 as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5 21630 fi 21631 21632 # First line typically looks something like: 21633 # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2 21634 COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"` 21635 COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"` 21636 fi 21637 # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker) 21638 CXX_VERSION="$COMPILER_VERSION" 21639 # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker) 21640 CXX_VENDOR="$COMPILER_VENDOR" 21641 21642 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5 21643 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;} 21644 21645 21646 # Now that we have resolved CXX ourself, let autoconf have its go at it 21647 ac_ext=cpp 21648 ac_cpp='$CXXCPP $CPPFLAGS' 21649 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 21650 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 21651 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 21652 if test -z "$CXX"; then 21653 if test -n "$CCC"; then 21654 CXX=$CCC 21655 else 21656 if test -n "$ac_tool_prefix"; then 21657 for ac_prog in $CXX 21658 do 21659 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 21660 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 21661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21662 $as_echo_n "checking for $ac_word... " >&6; } 21663 if ${ac_cv_prog_CXX+:} false; then : 21664 $as_echo_n "(cached) " >&6 21665 else 21666 if test -n "$CXX"; then 21667 ac_cv_prog_CXX="$CXX" # Let the user override the test. 21668 else 21669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21670 for as_dir in $PATH 21671 do 21672 IFS=$as_save_IFS 21673 test -z "$as_dir" && as_dir=. 21674 for ac_exec_ext in '' $ac_executable_extensions; do 21675 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21676 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 21677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21678 break 2 21679 fi 21680 done 21681 done 21682 IFS=$as_save_IFS 21683 21684 fi 21685 fi 21686 CXX=$ac_cv_prog_CXX 21687 if test -n "$CXX"; then 21688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 21689 $as_echo "$CXX" >&6; } 21690 else 21691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21692 $as_echo "no" >&6; } 21693 fi 21694 21695 21696 test -n "$CXX" && break 21697 done 21698 fi 21699 if test -z "$CXX"; then 21700 ac_ct_CXX=$CXX 21701 for ac_prog in $CXX 21702 do 21703 # Extract the first word of "$ac_prog", so it can be a program name with args. 21704 set dummy $ac_prog; ac_word=$2 21705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21706 $as_echo_n "checking for $ac_word... " >&6; } 21707 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 21708 $as_echo_n "(cached) " >&6 21709 else 21710 if test -n "$ac_ct_CXX"; then 21711 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 21712 else 21713 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21714 for as_dir in $PATH 21715 do 21716 IFS=$as_save_IFS 21717 test -z "$as_dir" && as_dir=. 21718 for ac_exec_ext in '' $ac_executable_extensions; do 21719 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21720 ac_cv_prog_ac_ct_CXX="$ac_prog" 21721 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21722 break 2 21723 fi 21724 done 21725 done 21726 IFS=$as_save_IFS 21727 21728 fi 21729 fi 21730 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 21731 if test -n "$ac_ct_CXX"; then 21732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 21733 $as_echo "$ac_ct_CXX" >&6; } 21734 else 21735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21736 $as_echo "no" >&6; } 21737 fi 21738 21739 21740 test -n "$ac_ct_CXX" && break 21741 done 21742 21743 if test "x$ac_ct_CXX" = x; then 21744 CXX="g++" 21745 else 21746 case $cross_compiling:$ac_tool_warned in 21747 yes:) 21748 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 21749 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 21750 ac_tool_warned=yes ;; 21751 esac 21752 CXX=$ac_ct_CXX 21753 fi 21754 fi 21755 21756 fi 21757 fi 21758 # Provide some information about the compiler. 21759 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 21760 set X $ac_compile 21761 ac_compiler=$2 21762 for ac_option in --version -v -V -qversion; do 21763 { { ac_try="$ac_compiler $ac_option >&5" 21764 case "(($ac_try" in 21765 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 21766 *) ac_try_echo=$ac_try;; 21767 esac 21768 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 21769 $as_echo "$ac_try_echo"; } >&5 21770 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 21771 ac_status=$? 21772 if test -s conftest.err; then 21773 sed '10a\ 21774 ... rest of stderr output deleted ... 21775 10q' conftest.err >conftest.er1 21776 cat conftest.er1 >&5 21777 fi 21778 rm -f conftest.er1 conftest.err 21779 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 21780 test $ac_status = 0; } 21781 done 21782 21783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 21784 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 21785 if ${ac_cv_cxx_compiler_gnu+:} false; then : 21786 $as_echo_n "(cached) " >&6 21787 else 21788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21789 /* end confdefs.h. */ 21790 21791 int 21792 main () 21793 { 21794 #ifndef __GNUC__ 21795 choke me 21796 #endif 21797 21798 ; 21799 return 0; 21800 } 21801 _ACEOF 21802 if ac_fn_cxx_try_compile "$LINENO"; then : 21803 ac_compiler_gnu=yes 21804 else 21805 ac_compiler_gnu=no 21806 fi 21807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 21808 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 21809 21810 fi 21811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 21812 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 21813 if test $ac_compiler_gnu = yes; then 21814 GXX=yes 21815 else 21816 GXX= 21817 fi 21818 ac_test_CXXFLAGS=${CXXFLAGS+set} 21819 ac_save_CXXFLAGS=$CXXFLAGS 21820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 21821 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 21822 if ${ac_cv_prog_cxx_g+:} false; then : 21823 $as_echo_n "(cached) " >&6 21824 else 21825 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 21826 ac_cxx_werror_flag=yes 21827 ac_cv_prog_cxx_g=no 21828 CXXFLAGS="-g" 21829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21830 /* end confdefs.h. */ 21831 21832 int 21833 main () 21834 { 21835 21836 ; 21837 return 0; 21838 } 21839 _ACEOF 21840 if ac_fn_cxx_try_compile "$LINENO"; then : 21841 ac_cv_prog_cxx_g=yes 21842 else 21843 CXXFLAGS="" 21844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21845 /* end confdefs.h. */ 21846 21847 int 21848 main () 21849 { 21850 21851 ; 21852 return 0; 21853 } 21854 _ACEOF 21855 if ac_fn_cxx_try_compile "$LINENO"; then : 21856 21857 else 21858 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 21859 CXXFLAGS="-g" 21860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21861 /* end confdefs.h. */ 21862 21863 int 21864 main () 21865 { 21866 21867 ; 21868 return 0; 21869 } 21870 _ACEOF 21871 if ac_fn_cxx_try_compile "$LINENO"; then : 21872 ac_cv_prog_cxx_g=yes 21873 fi 21874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 21875 fi 21876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 21877 fi 21878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 21879 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 21880 fi 21881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 21882 $as_echo "$ac_cv_prog_cxx_g" >&6; } 21883 if test "$ac_test_CXXFLAGS" = set; then 21884 CXXFLAGS=$ac_save_CXXFLAGS 21885 elif test $ac_cv_prog_cxx_g = yes; then 21886 if test "$GXX" = yes; then 21887 CXXFLAGS="-g -O2" 21888 else 21889 CXXFLAGS="-g" 21890 fi 21891 else 21892 if test "$GXX" = yes; then 21893 CXXFLAGS="-O2" 21894 else 21895 CXXFLAGS= 21896 fi 21897 fi 21898 ac_ext=cpp 21899 ac_cpp='$CXXCPP $CPPFLAGS' 21900 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 21901 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 21902 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 21903 21904 21905 ### Locate other tools 21906 21907 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 21908 ac_ext=m 21909 ac_cpp='$OBJCPP $CPPFLAGS' 21910 ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5' 21911 ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 21912 ac_compiler_gnu=$ac_cv_objc_compiler_gnu 21913 if test -n "$ac_tool_prefix"; then 21914 for ac_prog in gcc objcc objc cc CC 21915 do 21916 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 21917 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 21918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21919 $as_echo_n "checking for $ac_word... " >&6; } 21920 if ${ac_cv_prog_OBJC+:} false; then : 21921 $as_echo_n "(cached) " >&6 21922 else 21923 if test -n "$OBJC"; then 21924 ac_cv_prog_OBJC="$OBJC" # Let the user override the test. 21925 else 21926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21927 for as_dir in $PATH 21928 do 21929 IFS=$as_save_IFS 21930 test -z "$as_dir" && as_dir=. 21931 for ac_exec_ext in '' $ac_executable_extensions; do 21932 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21933 ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog" 21934 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21935 break 2 21936 fi 21937 done 21938 done 21939 IFS=$as_save_IFS 21940 21941 fi 21942 fi 21943 OBJC=$ac_cv_prog_OBJC 21944 if test -n "$OBJC"; then 21945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5 21946 $as_echo "$OBJC" >&6; } 21947 else 21948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21949 $as_echo "no" >&6; } 21950 fi 21951 21952 21953 test -n "$OBJC" && break 21954 done 21955 fi 21956 if test -z "$OBJC"; then 21957 ac_ct_OBJC=$OBJC 21958 for ac_prog in gcc objcc objc cc CC 21959 do 21960 # Extract the first word of "$ac_prog", so it can be a program name with args. 21961 set dummy $ac_prog; ac_word=$2 21962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21963 $as_echo_n "checking for $ac_word... " >&6; } 21964 if ${ac_cv_prog_ac_ct_OBJC+:} false; then : 21965 $as_echo_n "(cached) " >&6 21966 else 21967 if test -n "$ac_ct_OBJC"; then 21968 ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test. 21969 else 21970 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21971 for as_dir in $PATH 21972 do 21973 IFS=$as_save_IFS 21974 test -z "$as_dir" && as_dir=. 21975 for ac_exec_ext in '' $ac_executable_extensions; do 21976 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 21977 ac_cv_prog_ac_ct_OBJC="$ac_prog" 21978 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21979 break 2 21980 fi 21981 done 21982 done 21983 IFS=$as_save_IFS 21984 21985 fi 21986 fi 21987 ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC 21988 if test -n "$ac_ct_OBJC"; then 21989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5 21990 $as_echo "$ac_ct_OBJC" >&6; } 21991 else 21992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21993 $as_echo "no" >&6; } 21994 fi 21995 21996 21997 test -n "$ac_ct_OBJC" && break 21998 done 21999 22000 if test "x$ac_ct_OBJC" = x; then 22001 OBJC="gcc" 22002 else 22003 case $cross_compiling:$ac_tool_warned in 22004 yes:) 22005 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 22006 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 22007 ac_tool_warned=yes ;; 22008 esac 22009 OBJC=$ac_ct_OBJC 22010 fi 22011 fi 22012 22013 # Provide some information about the compiler. 22014 $as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5 22015 set X $ac_compile 22016 ac_compiler=$2 22017 for ac_option in --version -v -V -qversion; do 22018 { { ac_try="$ac_compiler $ac_option >&5" 22019 case "(($ac_try" in 22020 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 22021 *) ac_try_echo=$ac_try;; 22022 esac 22023 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 22024 $as_echo "$ac_try_echo"; } >&5 22025 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 22026 ac_status=$? 22027 if test -s conftest.err; then 22028 sed '10a\ 22029 ... rest of stderr output deleted ... 22030 10q' conftest.err >conftest.er1 22031 cat conftest.er1 >&5 22032 fi 22033 rm -f conftest.er1 conftest.err 22034 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 22035 test $ac_status = 0; } 22036 done 22037 22038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5 22039 $as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; } 22040 if ${ac_cv_objc_compiler_gnu+:} false; then : 22041 $as_echo_n "(cached) " >&6 22042 else 22043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22044 /* end confdefs.h. */ 22045 22046 int 22047 main () 22048 { 22049 #ifndef __GNUC__ 22050 choke me 22051 #endif 22052 22053 ; 22054 return 0; 22055 } 22056 _ACEOF 22057 if ac_fn_objc_try_compile "$LINENO"; then : 22058 ac_compiler_gnu=yes 22059 else 22060 ac_compiler_gnu=no 22061 fi 22062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22063 ac_cv_objc_compiler_gnu=$ac_compiler_gnu 22064 22065 fi 22066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5 22067 $as_echo "$ac_cv_objc_compiler_gnu" >&6; } 22068 if test $ac_compiler_gnu = yes; then 22069 GOBJC=yes 22070 else 22071 GOBJC= 22072 fi 22073 ac_test_OBJCFLAGS=${OBJCFLAGS+set} 22074 ac_save_OBJCFLAGS=$OBJCFLAGS 22075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5 22076 $as_echo_n "checking whether $OBJC accepts -g... " >&6; } 22077 if ${ac_cv_prog_objc_g+:} false; then : 22078 $as_echo_n "(cached) " >&6 22079 else 22080 ac_save_objc_werror_flag=$ac_objc_werror_flag 22081 ac_objc_werror_flag=yes 22082 ac_cv_prog_objc_g=no 22083 OBJCFLAGS="-g" 22084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22085 /* end confdefs.h. */ 22086 22087 int 22088 main () 22089 { 22090 22091 ; 22092 return 0; 22093 } 22094 _ACEOF 22095 if ac_fn_objc_try_compile "$LINENO"; then : 22096 ac_cv_prog_objc_g=yes 22097 else 22098 OBJCFLAGS="" 22099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22100 /* end confdefs.h. */ 22101 22102 int 22103 main () 22104 { 22105 22106 ; 22107 return 0; 22108 } 22109 _ACEOF 22110 if ac_fn_objc_try_compile "$LINENO"; then : 22111 22112 else 22113 ac_objc_werror_flag=$ac_save_objc_werror_flag 22114 OBJCFLAGS="-g" 22115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22116 /* end confdefs.h. */ 22117 22118 int 22119 main () 22120 { 22121 22122 ; 22123 return 0; 22124 } 22125 _ACEOF 22126 if ac_fn_objc_try_compile "$LINENO"; then : 22127 ac_cv_prog_objc_g=yes 22128 fi 22129 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22130 fi 22131 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22132 fi 22133 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 22134 ac_objc_werror_flag=$ac_save_objc_werror_flag 22135 fi 22136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5 22137 $as_echo "$ac_cv_prog_objc_g" >&6; } 22138 if test "$ac_test_OBJCFLAGS" = set; then 22139 OBJCFLAGS=$ac_save_OBJCFLAGS 22140 elif test $ac_cv_prog_objc_g = yes; then 22141 if test "$GOBJC" = yes; then 22142 OBJCFLAGS="-g -O2" 22143 else 22144 OBJCFLAGS="-g" 22145 fi 22146 else 22147 if test "$GOBJC" = yes; then 22148 OBJCFLAGS="-O2" 22149 else 22150 OBJCFLAGS= 22151 fi 22152 fi 22153 ac_ext=cpp 22154 ac_cpp='$CXXCPP $CPPFLAGS' 22155 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 22156 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 22157 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 22158 22159 22160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22161 22162 # First separate the path from the arguments. This will split at the first 22163 # space. 22164 complete="$OBJC" 22165 path="${complete%% *}" 22166 tmp="$complete EOL" 22167 arguments="${tmp#* }" 22168 22169 # Input might be given as Windows format, start by converting to 22170 # unix format. 22171 new_path=`$CYGPATH -u "$path"` 22172 22173 # Now try to locate executable using which 22174 new_path=`$WHICH "$new_path" 2> /dev/null` 22175 # bat and cmd files are not always considered executable in cygwin causing which 22176 # to not find them 22177 if test "x$new_path" = x \ 22178 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22179 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22180 new_path=`$CYGPATH -u "$path"` 22181 fi 22182 if test "x$new_path" = x; then 22183 # Oops. Which didn't find the executable. 22184 # The splitting of arguments from the executable at a space might have been incorrect, 22185 # since paths with space are more likely in Windows. Give it another try with the whole 22186 # argument. 22187 path="$complete" 22188 arguments="EOL" 22189 new_path=`$CYGPATH -u "$path"` 22190 new_path=`$WHICH "$new_path" 2> /dev/null` 22191 # bat and cmd files are not always considered executable in cygwin causing which 22192 # to not find them 22193 if test "x$new_path" = x \ 22194 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22195 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22196 new_path=`$CYGPATH -u "$path"` 22197 fi 22198 if test "x$new_path" = x; then 22199 # It's still not found. Now this is an unrecoverable error. 22200 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22201 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22202 has_space=`$ECHO "$complete" | $GREP " "` 22203 if test "x$has_space" != x; then 22204 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22205 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22206 fi 22207 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22208 fi 22209 fi 22210 22211 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 22212 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 22213 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 22214 # "foo.exe" is OK but "foo" is an error. 22215 # 22216 # This test is therefore slightly more accurate than "test -f" to check for file precense. 22217 # It is also a way to make sure we got the proper file name for the real test later on. 22218 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 22219 if test "x$test_shortpath" = x; then 22220 # Short path failed, file does not exist as specified. 22221 # Try adding .exe or .cmd 22222 if test -f "${new_path}.exe"; then 22223 input_to_shortpath="${new_path}.exe" 22224 elif test -f "${new_path}.cmd"; then 22225 input_to_shortpath="${new_path}.cmd" 22226 else 22227 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5 22228 $as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;} 22229 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 22230 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 22231 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22232 fi 22233 else 22234 input_to_shortpath="$new_path" 22235 fi 22236 22237 # Call helper function which possibly converts this using DOS-style short mode. 22238 # If so, the updated path is stored in $new_path. 22239 new_path="$input_to_shortpath" 22240 22241 input_path="$input_to_shortpath" 22242 # Check if we need to convert this using DOS-style short mode. If the path 22243 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22244 # take no chances and rewrite it. 22245 # Note: m4 eats our [], so we need to use [ and ] instead. 22246 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 22247 if test "x$has_forbidden_chars" != x; then 22248 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22249 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 22250 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 22251 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 22252 # Going to short mode and back again did indeed matter. Since short mode is 22253 # case insensitive, let's make it lowercase to improve readability. 22254 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22255 # Now convert it back to Unix-stile (cygpath) 22256 input_path=`$CYGPATH -u "$shortmode_path"` 22257 new_path="$input_path" 22258 fi 22259 fi 22260 22261 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 22262 if test "x$test_cygdrive_prefix" = x; then 22263 # As a simple fix, exclude /usr/bin since it's not a real path. 22264 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 22265 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 22266 # a path prefixed by /cygdrive for fixpath to work. 22267 new_path="$CYGWIN_ROOT_PATH$input_path" 22268 fi 22269 fi 22270 22271 # remove trailing .exe if any 22272 new_path="${new_path/%.exe/}" 22273 22274 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22275 22276 # First separate the path from the arguments. This will split at the first 22277 # space. 22278 complete="$OBJC" 22279 path="${complete%% *}" 22280 tmp="$complete EOL" 22281 arguments="${tmp#* }" 22282 22283 # Input might be given as Windows format, start by converting to 22284 # unix format. 22285 new_path="$path" 22286 22287 windows_path="$new_path" 22288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22289 unix_path=`$CYGPATH -u "$windows_path"` 22290 new_path="$unix_path" 22291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22292 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22293 new_path="$unix_path" 22294 fi 22295 22296 22297 # Now try to locate executable using which 22298 new_path=`$WHICH "$new_path" 2> /dev/null` 22299 22300 if test "x$new_path" = x; then 22301 # Oops. Which didn't find the executable. 22302 # The splitting of arguments from the executable at a space might have been incorrect, 22303 # since paths with space are more likely in Windows. Give it another try with the whole 22304 # argument. 22305 path="$complete" 22306 arguments="EOL" 22307 new_path="$path" 22308 22309 windows_path="$new_path" 22310 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22311 unix_path=`$CYGPATH -u "$windows_path"` 22312 new_path="$unix_path" 22313 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22314 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22315 new_path="$unix_path" 22316 fi 22317 22318 22319 new_path=`$WHICH "$new_path" 2> /dev/null` 22320 22321 if test "x$new_path" = x; then 22322 # It's still not found. Now this is an unrecoverable error. 22323 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22324 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22325 has_space=`$ECHO "$complete" | $GREP " "` 22326 if test "x$has_space" != x; then 22327 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22328 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22329 fi 22330 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22331 fi 22332 fi 22333 22334 # Now new_path has a complete unix path to the binary 22335 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 22336 # Keep paths in /bin as-is, but remove trailing .exe if any 22337 new_path="${new_path/%.exe/}" 22338 # Do not save /bin paths to all_fixpath_prefixes! 22339 else 22340 # Not in mixed or Windows style, start by that. 22341 new_path=`cmd //c echo $new_path` 22342 22343 input_path="$new_path" 22344 # Check if we need to convert this using DOS-style short mode. If the path 22345 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22346 # take no chances and rewrite it. 22347 # Note: m4 eats our [], so we need to use [ and ] instead. 22348 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 22349 if test "x$has_forbidden_chars" != x; then 22350 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22351 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22352 fi 22353 22354 # Output is in $new_path 22355 22356 windows_path="$new_path" 22357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22358 unix_path=`$CYGPATH -u "$windows_path"` 22359 new_path="$unix_path" 22360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22361 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22362 new_path="$unix_path" 22363 fi 22364 22365 # remove trailing .exe if any 22366 new_path="${new_path/%.exe/}" 22367 22368 # Save the first 10 bytes of this path to the storage, so fixpath can work. 22369 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 22370 fi 22371 22372 else 22373 # We're on a posix platform. Hooray! :) 22374 # First separate the path from the arguments. This will split at the first 22375 # space. 22376 complete="$OBJC" 22377 path="${complete%% *}" 22378 tmp="$complete EOL" 22379 arguments="${tmp#* }" 22380 22381 # Cannot rely on the command "which" here since it doesn't always work. 22382 is_absolute_path=`$ECHO "$path" | $GREP ^/` 22383 if test -z "$is_absolute_path"; then 22384 # Path to executable is not absolute. Find it. 22385 IFS_save="$IFS" 22386 IFS=: 22387 for p in $PATH; do 22388 if test -f "$p/$path" && test -x "$p/$path"; then 22389 new_path="$p/$path" 22390 break 22391 fi 22392 done 22393 IFS="$IFS_save" 22394 else 22395 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJC (as $path) failed, using $path directly." >&5 22396 $as_echo "$as_me: Resolving OBJC (as $path) failed, using $path directly." >&6;} 22397 new_path="$path" 22398 fi 22399 22400 if test "x$new_path" = x; then 22401 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5 22402 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;} 22403 has_space=`$ECHO "$complete" | $GREP " "` 22404 if test "x$has_space" != x; then 22405 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 22406 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 22407 fi 22408 as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5 22409 fi 22410 fi 22411 22412 # Now join together the path and the arguments once again 22413 if test "x$arguments" != xEOL; then 22414 new_complete="$new_path ${arguments% *}" 22415 else 22416 new_complete="$new_path" 22417 fi 22418 22419 if test "x$complete" != "x$new_complete"; then 22420 OBJC="$new_complete" 22421 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5 22422 $as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;} 22423 fi 22424 22425 else 22426 OBJC= 22427 fi 22428 22429 # Restore the flags to the user specified values. 22430 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 22431 CFLAGS="$ORG_CFLAGS" 22432 CXXFLAGS="$ORG_CXXFLAGS" 22433 OBJCFLAGS="$ORG_OBJCFLAGS" 22434 22435 LD="$CC" 22436 LDEXE="$CC" 22437 LDCXX="$CXX" 22438 LDEXECXX="$CXX" 22439 22440 # LDEXE is the linker to use, when creating executables. 22441 22442 # Linking C++ libraries. 22443 22444 # Linking C++ executables. 22445 22446 22447 if test "x$OPENJDK_TARGET_OS" != xwindows; then 22448 if test -n "$ac_tool_prefix"; then 22449 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. 22450 set dummy ${ac_tool_prefix}ar; ac_word=$2 22451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22452 $as_echo_n "checking for $ac_word... " >&6; } 22453 if ${ac_cv_prog_AR+:} false; then : 22454 $as_echo_n "(cached) " >&6 22455 else 22456 if test -n "$AR"; then 22457 ac_cv_prog_AR="$AR" # Let the user override the test. 22458 else 22459 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22460 for as_dir in $PATH 22461 do 22462 IFS=$as_save_IFS 22463 test -z "$as_dir" && as_dir=. 22464 for ac_exec_ext in '' $ac_executable_extensions; do 22465 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22466 ac_cv_prog_AR="${ac_tool_prefix}ar" 22467 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22468 break 2 22469 fi 22470 done 22471 done 22472 IFS=$as_save_IFS 22473 22474 fi 22475 fi 22476 AR=$ac_cv_prog_AR 22477 if test -n "$AR"; then 22478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 22479 $as_echo "$AR" >&6; } 22480 else 22481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22482 $as_echo "no" >&6; } 22483 fi 22484 22485 22486 fi 22487 if test -z "$ac_cv_prog_AR"; then 22488 ac_ct_AR=$AR 22489 # Extract the first word of "ar", so it can be a program name with args. 22490 set dummy ar; ac_word=$2 22491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22492 $as_echo_n "checking for $ac_word... " >&6; } 22493 if ${ac_cv_prog_ac_ct_AR+:} false; then : 22494 $as_echo_n "(cached) " >&6 22495 else 22496 if test -n "$ac_ct_AR"; then 22497 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 22498 else 22499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22500 for as_dir in $PATH 22501 do 22502 IFS=$as_save_IFS 22503 test -z "$as_dir" && as_dir=. 22504 for ac_exec_ext in '' $ac_executable_extensions; do 22505 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22506 ac_cv_prog_ac_ct_AR="ar" 22507 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22508 break 2 22509 fi 22510 done 22511 done 22512 IFS=$as_save_IFS 22513 22514 fi 22515 fi 22516 ac_ct_AR=$ac_cv_prog_ac_ct_AR 22517 if test -n "$ac_ct_AR"; then 22518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 22519 $as_echo "$ac_ct_AR" >&6; } 22520 else 22521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22522 $as_echo "no" >&6; } 22523 fi 22524 22525 if test "x$ac_ct_AR" = x; then 22526 AR="" 22527 else 22528 case $cross_compiling:$ac_tool_warned in 22529 yes:) 22530 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 22531 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 22532 ac_tool_warned=yes ;; 22533 esac 22534 AR=$ac_ct_AR 22535 fi 22536 else 22537 AR="$ac_cv_prog_AR" 22538 fi 22539 22540 22541 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22542 22543 # First separate the path from the arguments. This will split at the first 22544 # space. 22545 complete="$AR" 22546 path="${complete%% *}" 22547 tmp="$complete EOL" 22548 arguments="${tmp#* }" 22549 22550 # Input might be given as Windows format, start by converting to 22551 # unix format. 22552 new_path=`$CYGPATH -u "$path"` 22553 22554 # Now try to locate executable using which 22555 new_path=`$WHICH "$new_path" 2> /dev/null` 22556 # bat and cmd files are not always considered executable in cygwin causing which 22557 # to not find them 22558 if test "x$new_path" = x \ 22559 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22560 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22561 new_path=`$CYGPATH -u "$path"` 22562 fi 22563 if test "x$new_path" = x; then 22564 # Oops. Which didn't find the executable. 22565 # The splitting of arguments from the executable at a space might have been incorrect, 22566 # since paths with space are more likely in Windows. Give it another try with the whole 22567 # argument. 22568 path="$complete" 22569 arguments="EOL" 22570 new_path=`$CYGPATH -u "$path"` 22571 new_path=`$WHICH "$new_path" 2> /dev/null` 22572 # bat and cmd files are not always considered executable in cygwin causing which 22573 # to not find them 22574 if test "x$new_path" = x \ 22575 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22576 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22577 new_path=`$CYGPATH -u "$path"` 22578 fi 22579 if test "x$new_path" = x; then 22580 # It's still not found. Now this is an unrecoverable error. 22581 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22582 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22583 has_space=`$ECHO "$complete" | $GREP " "` 22584 if test "x$has_space" != x; then 22585 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22586 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22587 fi 22588 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22589 fi 22590 fi 22591 22592 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 22593 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 22594 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 22595 # "foo.exe" is OK but "foo" is an error. 22596 # 22597 # This test is therefore slightly more accurate than "test -f" to check for file precense. 22598 # It is also a way to make sure we got the proper file name for the real test later on. 22599 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 22600 if test "x$test_shortpath" = x; then 22601 # Short path failed, file does not exist as specified. 22602 # Try adding .exe or .cmd 22603 if test -f "${new_path}.exe"; then 22604 input_to_shortpath="${new_path}.exe" 22605 elif test -f "${new_path}.cmd"; then 22606 input_to_shortpath="${new_path}.cmd" 22607 else 22608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 22609 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 22610 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 22611 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 22612 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22613 fi 22614 else 22615 input_to_shortpath="$new_path" 22616 fi 22617 22618 # Call helper function which possibly converts this using DOS-style short mode. 22619 # If so, the updated path is stored in $new_path. 22620 new_path="$input_to_shortpath" 22621 22622 input_path="$input_to_shortpath" 22623 # Check if we need to convert this using DOS-style short mode. If the path 22624 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22625 # take no chances and rewrite it. 22626 # Note: m4 eats our [], so we need to use [ and ] instead. 22627 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 22628 if test "x$has_forbidden_chars" != x; then 22629 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22630 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 22631 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 22632 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 22633 # Going to short mode and back again did indeed matter. Since short mode is 22634 # case insensitive, let's make it lowercase to improve readability. 22635 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22636 # Now convert it back to Unix-stile (cygpath) 22637 input_path=`$CYGPATH -u "$shortmode_path"` 22638 new_path="$input_path" 22639 fi 22640 fi 22641 22642 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 22643 if test "x$test_cygdrive_prefix" = x; then 22644 # As a simple fix, exclude /usr/bin since it's not a real path. 22645 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 22646 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 22647 # a path prefixed by /cygdrive for fixpath to work. 22648 new_path="$CYGWIN_ROOT_PATH$input_path" 22649 fi 22650 fi 22651 22652 # remove trailing .exe if any 22653 new_path="${new_path/%.exe/}" 22654 22655 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22656 22657 # First separate the path from the arguments. This will split at the first 22658 # space. 22659 complete="$AR" 22660 path="${complete%% *}" 22661 tmp="$complete EOL" 22662 arguments="${tmp#* }" 22663 22664 # Input might be given as Windows format, start by converting to 22665 # unix format. 22666 new_path="$path" 22667 22668 windows_path="$new_path" 22669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22670 unix_path=`$CYGPATH -u "$windows_path"` 22671 new_path="$unix_path" 22672 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22673 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22674 new_path="$unix_path" 22675 fi 22676 22677 22678 # Now try to locate executable using which 22679 new_path=`$WHICH "$new_path" 2> /dev/null` 22680 22681 if test "x$new_path" = x; then 22682 # Oops. Which didn't find the executable. 22683 # The splitting of arguments from the executable at a space might have been incorrect, 22684 # since paths with space are more likely in Windows. Give it another try with the whole 22685 # argument. 22686 path="$complete" 22687 arguments="EOL" 22688 new_path="$path" 22689 22690 windows_path="$new_path" 22691 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22692 unix_path=`$CYGPATH -u "$windows_path"` 22693 new_path="$unix_path" 22694 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22695 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22696 new_path="$unix_path" 22697 fi 22698 22699 22700 new_path=`$WHICH "$new_path" 2> /dev/null` 22701 22702 if test "x$new_path" = x; then 22703 # It's still not found. Now this is an unrecoverable error. 22704 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22705 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22706 has_space=`$ECHO "$complete" | $GREP " "` 22707 if test "x$has_space" != x; then 22708 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22709 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22710 fi 22711 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22712 fi 22713 fi 22714 22715 # Now new_path has a complete unix path to the binary 22716 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 22717 # Keep paths in /bin as-is, but remove trailing .exe if any 22718 new_path="${new_path/%.exe/}" 22719 # Do not save /bin paths to all_fixpath_prefixes! 22720 else 22721 # Not in mixed or Windows style, start by that. 22722 new_path=`cmd //c echo $new_path` 22723 22724 input_path="$new_path" 22725 # Check if we need to convert this using DOS-style short mode. If the path 22726 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22727 # take no chances and rewrite it. 22728 # Note: m4 eats our [], so we need to use [ and ] instead. 22729 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 22730 if test "x$has_forbidden_chars" != x; then 22731 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22732 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22733 fi 22734 22735 # Output is in $new_path 22736 22737 windows_path="$new_path" 22738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22739 unix_path=`$CYGPATH -u "$windows_path"` 22740 new_path="$unix_path" 22741 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 22742 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 22743 new_path="$unix_path" 22744 fi 22745 22746 # remove trailing .exe if any 22747 new_path="${new_path/%.exe/}" 22748 22749 # Save the first 10 bytes of this path to the storage, so fixpath can work. 22750 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 22751 fi 22752 22753 else 22754 # We're on a posix platform. Hooray! :) 22755 # First separate the path from the arguments. This will split at the first 22756 # space. 22757 complete="$AR" 22758 path="${complete%% *}" 22759 tmp="$complete EOL" 22760 arguments="${tmp#* }" 22761 22762 # Cannot rely on the command "which" here since it doesn't always work. 22763 is_absolute_path=`$ECHO "$path" | $GREP ^/` 22764 if test -z "$is_absolute_path"; then 22765 # Path to executable is not absolute. Find it. 22766 IFS_save="$IFS" 22767 IFS=: 22768 for p in $PATH; do 22769 if test -f "$p/$path" && test -x "$p/$path"; then 22770 new_path="$p/$path" 22771 break 22772 fi 22773 done 22774 IFS="$IFS_save" 22775 else 22776 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AR (as $path) failed, using $path directly." >&5 22777 $as_echo "$as_me: Resolving AR (as $path) failed, using $path directly." >&6;} 22778 new_path="$path" 22779 fi 22780 22781 if test "x$new_path" = x; then 22782 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 22783 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 22784 has_space=`$ECHO "$complete" | $GREP " "` 22785 if test "x$has_space" != x; then 22786 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 22787 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 22788 fi 22789 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 22790 fi 22791 fi 22792 22793 # Now join together the path and the arguments once again 22794 if test "x$arguments" != xEOL; then 22795 new_complete="$new_path ${arguments% *}" 22796 else 22797 new_complete="$new_path" 22798 fi 22799 22800 if test "x$complete" != "x$new_complete"; then 22801 AR="$new_complete" 22802 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 22803 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 22804 fi 22805 22806 fi 22807 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 22808 ARFLAGS="-r" 22809 else 22810 ARFLAGS="" 22811 fi 22812 22813 22814 # For hotspot, we need these in Windows mixed path; other platforms keep them the same 22815 HOTSPOT_CXX="$CXX" 22816 HOTSPOT_LD="$LD" 22817 22818 22819 22820 COMPILER_NAME=gcc 22821 COMPILER_TYPE=CC 22822 if test "x$OPENJDK_TARGET_OS" = xwindows; then : 22823 22824 # For now, assume that we are always compiling using cl.exe. 22825 CC_OUT_OPTION=-Fo 22826 EXE_OUT_OPTION=-out: 22827 LD_OUT_OPTION=-out: 22828 AR_OUT_OPTION=-out: 22829 # On Windows, reject /usr/bin/link (as determined in CYGWIN_LINK), which is a cygwin 22830 # program for something completely different. 22831 # Extract the first word of "link", so it can be a program name with args. 22832 set dummy link; ac_word=$2 22833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22834 $as_echo_n "checking for $ac_word... " >&6; } 22835 if ${ac_cv_prog_WINLD+:} false; then : 22836 $as_echo_n "(cached) " >&6 22837 else 22838 if test -n "$WINLD"; then 22839 ac_cv_prog_WINLD="$WINLD" # Let the user override the test. 22840 else 22841 ac_prog_rejected=no 22842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22843 for as_dir in $PATH 22844 do 22845 IFS=$as_save_IFS 22846 test -z "$as_dir" && as_dir=. 22847 for ac_exec_ext in '' $ac_executable_extensions; do 22848 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 22849 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 22850 ac_prog_rejected=yes 22851 continue 22852 fi 22853 ac_cv_prog_WINLD="link" 22854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22855 break 2 22856 fi 22857 done 22858 done 22859 IFS=$as_save_IFS 22860 22861 if test $ac_prog_rejected = yes; then 22862 # We found a bogon in the path, so make sure we never use it. 22863 set dummy $ac_cv_prog_WINLD 22864 shift 22865 if test $# != 0; then 22866 # We chose a different compiler from the bogus one. 22867 # However, it has the same basename, so the bogon will be chosen 22868 # first if we set WINLD to just the basename; use the full file name. 22869 shift 22870 ac_cv_prog_WINLD="$as_dir/$ac_word${1+' '}$@" 22871 fi 22872 fi 22873 fi 22874 fi 22875 WINLD=$ac_cv_prog_WINLD 22876 if test -n "$WINLD"; then 22877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINLD" >&5 22878 $as_echo "$WINLD" >&6; } 22879 else 22880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22881 $as_echo "no" >&6; } 22882 fi 22883 22884 22885 # Since we must ignore the first found link, WINLD will contain 22886 # the full path to the link.exe program. 22887 22888 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 22889 22890 # First separate the path from the arguments. This will split at the first 22891 # space. 22892 complete="$WINLD" 22893 path="${complete%% *}" 22894 tmp="$complete EOL" 22895 arguments="${tmp#* }" 22896 22897 # Input might be given as Windows format, start by converting to 22898 # unix format. 22899 new_path=`$CYGPATH -u "$path"` 22900 22901 # Now try to locate executable using which 22902 new_path=`$WHICH "$new_path" 2> /dev/null` 22903 # bat and cmd files are not always considered executable in cygwin causing which 22904 # to not find them 22905 if test "x$new_path" = x \ 22906 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22907 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22908 new_path=`$CYGPATH -u "$path"` 22909 fi 22910 if test "x$new_path" = x; then 22911 # Oops. Which didn't find the executable. 22912 # The splitting of arguments from the executable at a space might have been incorrect, 22913 # since paths with space are more likely in Windows. Give it another try with the whole 22914 # argument. 22915 path="$complete" 22916 arguments="EOL" 22917 new_path=`$CYGPATH -u "$path"` 22918 new_path=`$WHICH "$new_path" 2> /dev/null` 22919 # bat and cmd files are not always considered executable in cygwin causing which 22920 # to not find them 22921 if test "x$new_path" = x \ 22922 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 22923 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 22924 new_path=`$CYGPATH -u "$path"` 22925 fi 22926 if test "x$new_path" = x; then 22927 # It's still not found. Now this is an unrecoverable error. 22928 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 22929 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 22930 has_space=`$ECHO "$complete" | $GREP " "` 22931 if test "x$has_space" != x; then 22932 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 22933 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 22934 fi 22935 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 22936 fi 22937 fi 22938 22939 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 22940 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 22941 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 22942 # "foo.exe" is OK but "foo" is an error. 22943 # 22944 # This test is therefore slightly more accurate than "test -f" to check for file precense. 22945 # It is also a way to make sure we got the proper file name for the real test later on. 22946 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 22947 if test "x$test_shortpath" = x; then 22948 # Short path failed, file does not exist as specified. 22949 # Try adding .exe or .cmd 22950 if test -f "${new_path}.exe"; then 22951 input_to_shortpath="${new_path}.exe" 22952 elif test -f "${new_path}.cmd"; then 22953 input_to_shortpath="${new_path}.cmd" 22954 else 22955 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$new_path\", is invalid." >&5 22956 $as_echo "$as_me: The path of WINLD, which resolves as \"$new_path\", is invalid." >&6;} 22957 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 22958 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 22959 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 22960 fi 22961 else 22962 input_to_shortpath="$new_path" 22963 fi 22964 22965 # Call helper function which possibly converts this using DOS-style short mode. 22966 # If so, the updated path is stored in $new_path. 22967 new_path="$input_to_shortpath" 22968 22969 input_path="$input_to_shortpath" 22970 # Check if we need to convert this using DOS-style short mode. If the path 22971 # contains just simple characters, use it. Otherwise (spaces, weird characters), 22972 # take no chances and rewrite it. 22973 # Note: m4 eats our [], so we need to use [ and ] instead. 22974 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 22975 if test "x$has_forbidden_chars" != x; then 22976 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 22977 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 22978 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 22979 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 22980 # Going to short mode and back again did indeed matter. Since short mode is 22981 # case insensitive, let's make it lowercase to improve readability. 22982 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 22983 # Now convert it back to Unix-stile (cygpath) 22984 input_path=`$CYGPATH -u "$shortmode_path"` 22985 new_path="$input_path" 22986 fi 22987 fi 22988 22989 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 22990 if test "x$test_cygdrive_prefix" = x; then 22991 # As a simple fix, exclude /usr/bin since it's not a real path. 22992 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 22993 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 22994 # a path prefixed by /cygdrive for fixpath to work. 22995 new_path="$CYGWIN_ROOT_PATH$input_path" 22996 fi 22997 fi 22998 22999 # remove trailing .exe if any 23000 new_path="${new_path/%.exe/}" 23001 23002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23003 23004 # First separate the path from the arguments. This will split at the first 23005 # space. 23006 complete="$WINLD" 23007 path="${complete%% *}" 23008 tmp="$complete EOL" 23009 arguments="${tmp#* }" 23010 23011 # Input might be given as Windows format, start by converting to 23012 # unix format. 23013 new_path="$path" 23014 23015 windows_path="$new_path" 23016 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23017 unix_path=`$CYGPATH -u "$windows_path"` 23018 new_path="$unix_path" 23019 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23020 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23021 new_path="$unix_path" 23022 fi 23023 23024 23025 # Now try to locate executable using which 23026 new_path=`$WHICH "$new_path" 2> /dev/null` 23027 23028 if test "x$new_path" = x; then 23029 # Oops. Which didn't find the executable. 23030 # The splitting of arguments from the executable at a space might have been incorrect, 23031 # since paths with space are more likely in Windows. Give it another try with the whole 23032 # argument. 23033 path="$complete" 23034 arguments="EOL" 23035 new_path="$path" 23036 23037 windows_path="$new_path" 23038 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23039 unix_path=`$CYGPATH -u "$windows_path"` 23040 new_path="$unix_path" 23041 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23042 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23043 new_path="$unix_path" 23044 fi 23045 23046 23047 new_path=`$WHICH "$new_path" 2> /dev/null` 23048 23049 if test "x$new_path" = x; then 23050 # It's still not found. Now this is an unrecoverable error. 23051 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 23052 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 23053 has_space=`$ECHO "$complete" | $GREP " "` 23054 if test "x$has_space" != x; then 23055 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23056 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23057 fi 23058 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23059 fi 23060 fi 23061 23062 # Now new_path has a complete unix path to the binary 23063 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23064 # Keep paths in /bin as-is, but remove trailing .exe if any 23065 new_path="${new_path/%.exe/}" 23066 # Do not save /bin paths to all_fixpath_prefixes! 23067 else 23068 # Not in mixed or Windows style, start by that. 23069 new_path=`cmd //c echo $new_path` 23070 23071 input_path="$new_path" 23072 # Check if we need to convert this using DOS-style short mode. If the path 23073 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23074 # take no chances and rewrite it. 23075 # Note: m4 eats our [], so we need to use [ and ] instead. 23076 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23077 if test "x$has_forbidden_chars" != x; then 23078 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23079 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23080 fi 23081 23082 # Output is in $new_path 23083 23084 windows_path="$new_path" 23085 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23086 unix_path=`$CYGPATH -u "$windows_path"` 23087 new_path="$unix_path" 23088 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23089 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23090 new_path="$unix_path" 23091 fi 23092 23093 # remove trailing .exe if any 23094 new_path="${new_path/%.exe/}" 23095 23096 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23097 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23098 fi 23099 23100 else 23101 # We're on a posix platform. Hooray! :) 23102 # First separate the path from the arguments. This will split at the first 23103 # space. 23104 complete="$WINLD" 23105 path="${complete%% *}" 23106 tmp="$complete EOL" 23107 arguments="${tmp#* }" 23108 23109 # Cannot rely on the command "which" here since it doesn't always work. 23110 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23111 if test -z "$is_absolute_path"; then 23112 # Path to executable is not absolute. Find it. 23113 IFS_save="$IFS" 23114 IFS=: 23115 for p in $PATH; do 23116 if test -f "$p/$path" && test -x "$p/$path"; then 23117 new_path="$p/$path" 23118 break 23119 fi 23120 done 23121 IFS="$IFS_save" 23122 else 23123 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINLD (as $path) failed, using $path directly." >&5 23124 $as_echo "$as_me: Resolving WINLD (as $path) failed, using $path directly." >&6;} 23125 new_path="$path" 23126 fi 23127 23128 if test "x$new_path" = x; then 23129 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5 23130 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;} 23131 has_space=`$ECHO "$complete" | $GREP " "` 23132 if test "x$has_space" != x; then 23133 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23134 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23135 fi 23136 as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5 23137 fi 23138 fi 23139 23140 # Now join together the path and the arguments once again 23141 if test "x$arguments" != xEOL; then 23142 new_complete="$new_path ${arguments% *}" 23143 else 23144 new_complete="$new_path" 23145 fi 23146 23147 if test "x$complete" != "x$new_complete"; then 23148 WINLD="$new_complete" 23149 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINLD to \"$new_complete\"" >&5 23150 $as_echo "$as_me: Rewriting WINLD to \"$new_complete\"" >&6;} 23151 fi 23152 23153 printf "Windows linker was found at $WINLD\n" 23154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 23155 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 23156 "$WINLD" --version > /dev/null 23157 if test $? -eq 0 ; then 23158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23159 $as_echo "no" >&6; } 23160 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 23161 else 23162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23163 $as_echo "yes" >&6; } 23164 fi 23165 LD="$WINLD" 23166 LDEXE="$WINLD" 23167 LDCXX="$WINLD" 23168 LDEXECXX="$WINLD" 23169 23170 # Extract the first word of "mt", so it can be a program name with args. 23171 set dummy mt; ac_word=$2 23172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23173 $as_echo_n "checking for $ac_word... " >&6; } 23174 if ${ac_cv_prog_MT+:} false; then : 23175 $as_echo_n "(cached) " >&6 23176 else 23177 if test -n "$MT"; then 23178 ac_cv_prog_MT="$MT" # Let the user override the test. 23179 else 23180 ac_prog_rejected=no 23181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23182 for as_dir in $PATH 23183 do 23184 IFS=$as_save_IFS 23185 test -z "$as_dir" && as_dir=. 23186 for ac_exec_ext in '' $ac_executable_extensions; do 23187 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23188 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 23189 ac_prog_rejected=yes 23190 continue 23191 fi 23192 ac_cv_prog_MT="mt" 23193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23194 break 2 23195 fi 23196 done 23197 done 23198 IFS=$as_save_IFS 23199 23200 if test $ac_prog_rejected = yes; then 23201 # We found a bogon in the path, so make sure we never use it. 23202 set dummy $ac_cv_prog_MT 23203 shift 23204 if test $# != 0; then 23205 # We chose a different compiler from the bogus one. 23206 # However, it has the same basename, so the bogon will be chosen 23207 # first if we set MT to just the basename; use the full file name. 23208 shift 23209 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 23210 fi 23211 fi 23212 fi 23213 fi 23214 MT=$ac_cv_prog_MT 23215 if test -n "$MT"; then 23216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 23217 $as_echo "$MT" >&6; } 23218 else 23219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23220 $as_echo "no" >&6; } 23221 fi 23222 23223 23224 23225 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23226 23227 # First separate the path from the arguments. This will split at the first 23228 # space. 23229 complete="$MT" 23230 path="${complete%% *}" 23231 tmp="$complete EOL" 23232 arguments="${tmp#* }" 23233 23234 # Input might be given as Windows format, start by converting to 23235 # unix format. 23236 new_path=`$CYGPATH -u "$path"` 23237 23238 # Now try to locate executable using which 23239 new_path=`$WHICH "$new_path" 2> /dev/null` 23240 # bat and cmd files are not always considered executable in cygwin causing which 23241 # to not find them 23242 if test "x$new_path" = x \ 23243 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23244 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23245 new_path=`$CYGPATH -u "$path"` 23246 fi 23247 if test "x$new_path" = x; then 23248 # Oops. Which didn't find the executable. 23249 # The splitting of arguments from the executable at a space might have been incorrect, 23250 # since paths with space are more likely in Windows. Give it another try with the whole 23251 # argument. 23252 path="$complete" 23253 arguments="EOL" 23254 new_path=`$CYGPATH -u "$path"` 23255 new_path=`$WHICH "$new_path" 2> /dev/null` 23256 # bat and cmd files are not always considered executable in cygwin causing which 23257 # to not find them 23258 if test "x$new_path" = x \ 23259 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23260 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23261 new_path=`$CYGPATH -u "$path"` 23262 fi 23263 if test "x$new_path" = x; then 23264 # It's still not found. Now this is an unrecoverable error. 23265 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23266 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23267 has_space=`$ECHO "$complete" | $GREP " "` 23268 if test "x$has_space" != x; then 23269 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23270 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23271 fi 23272 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23273 fi 23274 fi 23275 23276 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23277 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23278 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23279 # "foo.exe" is OK but "foo" is an error. 23280 # 23281 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23282 # It is also a way to make sure we got the proper file name for the real test later on. 23283 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23284 if test "x$test_shortpath" = x; then 23285 # Short path failed, file does not exist as specified. 23286 # Try adding .exe or .cmd 23287 if test -f "${new_path}.exe"; then 23288 input_to_shortpath="${new_path}.exe" 23289 elif test -f "${new_path}.cmd"; then 23290 input_to_shortpath="${new_path}.cmd" 23291 else 23292 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 23293 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 23294 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23295 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23296 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23297 fi 23298 else 23299 input_to_shortpath="$new_path" 23300 fi 23301 23302 # Call helper function which possibly converts this using DOS-style short mode. 23303 # If so, the updated path is stored in $new_path. 23304 new_path="$input_to_shortpath" 23305 23306 input_path="$input_to_shortpath" 23307 # Check if we need to convert this using DOS-style short mode. If the path 23308 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23309 # take no chances and rewrite it. 23310 # Note: m4 eats our [], so we need to use [ and ] instead. 23311 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23312 if test "x$has_forbidden_chars" != x; then 23313 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23314 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23315 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23316 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23317 # Going to short mode and back again did indeed matter. Since short mode is 23318 # case insensitive, let's make it lowercase to improve readability. 23319 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23320 # Now convert it back to Unix-stile (cygpath) 23321 input_path=`$CYGPATH -u "$shortmode_path"` 23322 new_path="$input_path" 23323 fi 23324 fi 23325 23326 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23327 if test "x$test_cygdrive_prefix" = x; then 23328 # As a simple fix, exclude /usr/bin since it's not a real path. 23329 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 23330 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23331 # a path prefixed by /cygdrive for fixpath to work. 23332 new_path="$CYGWIN_ROOT_PATH$input_path" 23333 fi 23334 fi 23335 23336 # remove trailing .exe if any 23337 new_path="${new_path/%.exe/}" 23338 23339 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23340 23341 # First separate the path from the arguments. This will split at the first 23342 # space. 23343 complete="$MT" 23344 path="${complete%% *}" 23345 tmp="$complete EOL" 23346 arguments="${tmp#* }" 23347 23348 # Input might be given as Windows format, start by converting to 23349 # unix format. 23350 new_path="$path" 23351 23352 windows_path="$new_path" 23353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23354 unix_path=`$CYGPATH -u "$windows_path"` 23355 new_path="$unix_path" 23356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23357 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23358 new_path="$unix_path" 23359 fi 23360 23361 23362 # Now try to locate executable using which 23363 new_path=`$WHICH "$new_path" 2> /dev/null` 23364 23365 if test "x$new_path" = x; then 23366 # Oops. Which didn't find the executable. 23367 # The splitting of arguments from the executable at a space might have been incorrect, 23368 # since paths with space are more likely in Windows. Give it another try with the whole 23369 # argument. 23370 path="$complete" 23371 arguments="EOL" 23372 new_path="$path" 23373 23374 windows_path="$new_path" 23375 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23376 unix_path=`$CYGPATH -u "$windows_path"` 23377 new_path="$unix_path" 23378 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23379 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23380 new_path="$unix_path" 23381 fi 23382 23383 23384 new_path=`$WHICH "$new_path" 2> /dev/null` 23385 23386 if test "x$new_path" = x; then 23387 # It's still not found. Now this is an unrecoverable error. 23388 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23389 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23390 has_space=`$ECHO "$complete" | $GREP " "` 23391 if test "x$has_space" != x; then 23392 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23393 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23394 fi 23395 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23396 fi 23397 fi 23398 23399 # Now new_path has a complete unix path to the binary 23400 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23401 # Keep paths in /bin as-is, but remove trailing .exe if any 23402 new_path="${new_path/%.exe/}" 23403 # Do not save /bin paths to all_fixpath_prefixes! 23404 else 23405 # Not in mixed or Windows style, start by that. 23406 new_path=`cmd //c echo $new_path` 23407 23408 input_path="$new_path" 23409 # Check if we need to convert this using DOS-style short mode. If the path 23410 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23411 # take no chances and rewrite it. 23412 # Note: m4 eats our [], so we need to use [ and ] instead. 23413 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23414 if test "x$has_forbidden_chars" != x; then 23415 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23416 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23417 fi 23418 23419 # Output is in $new_path 23420 23421 windows_path="$new_path" 23422 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23423 unix_path=`$CYGPATH -u "$windows_path"` 23424 new_path="$unix_path" 23425 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23426 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23427 new_path="$unix_path" 23428 fi 23429 23430 # remove trailing .exe if any 23431 new_path="${new_path/%.exe/}" 23432 23433 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23434 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23435 fi 23436 23437 else 23438 # We're on a posix platform. Hooray! :) 23439 # First separate the path from the arguments. This will split at the first 23440 # space. 23441 complete="$MT" 23442 path="${complete%% *}" 23443 tmp="$complete EOL" 23444 arguments="${tmp#* }" 23445 23446 # Cannot rely on the command "which" here since it doesn't always work. 23447 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23448 if test -z "$is_absolute_path"; then 23449 # Path to executable is not absolute. Find it. 23450 IFS_save="$IFS" 23451 IFS=: 23452 for p in $PATH; do 23453 if test -f "$p/$path" && test -x "$p/$path"; then 23454 new_path="$p/$path" 23455 break 23456 fi 23457 done 23458 IFS="$IFS_save" 23459 else 23460 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MT (as $path) failed, using $path directly." >&5 23461 $as_echo "$as_me: Resolving MT (as $path) failed, using $path directly." >&6;} 23462 new_path="$path" 23463 fi 23464 23465 if test "x$new_path" = x; then 23466 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 23467 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 23468 has_space=`$ECHO "$complete" | $GREP " "` 23469 if test "x$has_space" != x; then 23470 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23471 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23472 fi 23473 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 23474 fi 23475 fi 23476 23477 # Now join together the path and the arguments once again 23478 if test "x$arguments" != xEOL; then 23479 new_complete="$new_path ${arguments% *}" 23480 else 23481 new_complete="$new_path" 23482 fi 23483 23484 if test "x$complete" != "x$new_complete"; then 23485 MT="$new_complete" 23486 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 23487 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 23488 fi 23489 23490 # The resource compiler 23491 # Extract the first word of "rc", so it can be a program name with args. 23492 set dummy rc; ac_word=$2 23493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23494 $as_echo_n "checking for $ac_word... " >&6; } 23495 if ${ac_cv_prog_RC+:} false; then : 23496 $as_echo_n "(cached) " >&6 23497 else 23498 if test -n "$RC"; then 23499 ac_cv_prog_RC="$RC" # Let the user override the test. 23500 else 23501 ac_prog_rejected=no 23502 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23503 for as_dir in $PATH 23504 do 23505 IFS=$as_save_IFS 23506 test -z "$as_dir" && as_dir=. 23507 for ac_exec_ext in '' $ac_executable_extensions; do 23508 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23509 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 23510 ac_prog_rejected=yes 23511 continue 23512 fi 23513 ac_cv_prog_RC="rc" 23514 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23515 break 2 23516 fi 23517 done 23518 done 23519 IFS=$as_save_IFS 23520 23521 if test $ac_prog_rejected = yes; then 23522 # We found a bogon in the path, so make sure we never use it. 23523 set dummy $ac_cv_prog_RC 23524 shift 23525 if test $# != 0; then 23526 # We chose a different compiler from the bogus one. 23527 # However, it has the same basename, so the bogon will be chosen 23528 # first if we set RC to just the basename; use the full file name. 23529 shift 23530 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 23531 fi 23532 fi 23533 fi 23534 fi 23535 RC=$ac_cv_prog_RC 23536 if test -n "$RC"; then 23537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 23538 $as_echo "$RC" >&6; } 23539 else 23540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23541 $as_echo "no" >&6; } 23542 fi 23543 23544 23545 23546 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23547 23548 # First separate the path from the arguments. This will split at the first 23549 # space. 23550 complete="$RC" 23551 path="${complete%% *}" 23552 tmp="$complete EOL" 23553 arguments="${tmp#* }" 23554 23555 # Input might be given as Windows format, start by converting to 23556 # unix format. 23557 new_path=`$CYGPATH -u "$path"` 23558 23559 # Now try to locate executable using which 23560 new_path=`$WHICH "$new_path" 2> /dev/null` 23561 # bat and cmd files are not always considered executable in cygwin causing which 23562 # to not find them 23563 if test "x$new_path" = x \ 23564 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23565 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23566 new_path=`$CYGPATH -u "$path"` 23567 fi 23568 if test "x$new_path" = x; then 23569 # Oops. Which didn't find the executable. 23570 # The splitting of arguments from the executable at a space might have been incorrect, 23571 # since paths with space are more likely in Windows. Give it another try with the whole 23572 # argument. 23573 path="$complete" 23574 arguments="EOL" 23575 new_path=`$CYGPATH -u "$path"` 23576 new_path=`$WHICH "$new_path" 2> /dev/null` 23577 # bat and cmd files are not always considered executable in cygwin causing which 23578 # to not find them 23579 if test "x$new_path" = x \ 23580 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23581 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23582 new_path=`$CYGPATH -u "$path"` 23583 fi 23584 if test "x$new_path" = x; then 23585 # It's still not found. Now this is an unrecoverable error. 23586 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23587 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23588 has_space=`$ECHO "$complete" | $GREP " "` 23589 if test "x$has_space" != x; then 23590 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23591 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23592 fi 23593 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23594 fi 23595 fi 23596 23597 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23598 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23599 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23600 # "foo.exe" is OK but "foo" is an error. 23601 # 23602 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23603 # It is also a way to make sure we got the proper file name for the real test later on. 23604 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23605 if test "x$test_shortpath" = x; then 23606 # Short path failed, file does not exist as specified. 23607 # Try adding .exe or .cmd 23608 if test -f "${new_path}.exe"; then 23609 input_to_shortpath="${new_path}.exe" 23610 elif test -f "${new_path}.cmd"; then 23611 input_to_shortpath="${new_path}.cmd" 23612 else 23613 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 23614 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 23615 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23616 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23617 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23618 fi 23619 else 23620 input_to_shortpath="$new_path" 23621 fi 23622 23623 # Call helper function which possibly converts this using DOS-style short mode. 23624 # If so, the updated path is stored in $new_path. 23625 new_path="$input_to_shortpath" 23626 23627 input_path="$input_to_shortpath" 23628 # Check if we need to convert this using DOS-style short mode. If the path 23629 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23630 # take no chances and rewrite it. 23631 # Note: m4 eats our [], so we need to use [ and ] instead. 23632 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23633 if test "x$has_forbidden_chars" != x; then 23634 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23635 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23636 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23637 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23638 # Going to short mode and back again did indeed matter. Since short mode is 23639 # case insensitive, let's make it lowercase to improve readability. 23640 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23641 # Now convert it back to Unix-stile (cygpath) 23642 input_path=`$CYGPATH -u "$shortmode_path"` 23643 new_path="$input_path" 23644 fi 23645 fi 23646 23647 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23648 if test "x$test_cygdrive_prefix" = x; then 23649 # As a simple fix, exclude /usr/bin since it's not a real path. 23650 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 23651 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23652 # a path prefixed by /cygdrive for fixpath to work. 23653 new_path="$CYGWIN_ROOT_PATH$input_path" 23654 fi 23655 fi 23656 23657 # remove trailing .exe if any 23658 new_path="${new_path/%.exe/}" 23659 23660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23661 23662 # First separate the path from the arguments. This will split at the first 23663 # space. 23664 complete="$RC" 23665 path="${complete%% *}" 23666 tmp="$complete EOL" 23667 arguments="${tmp#* }" 23668 23669 # Input might be given as Windows format, start by converting to 23670 # unix format. 23671 new_path="$path" 23672 23673 windows_path="$new_path" 23674 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23675 unix_path=`$CYGPATH -u "$windows_path"` 23676 new_path="$unix_path" 23677 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23678 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23679 new_path="$unix_path" 23680 fi 23681 23682 23683 # Now try to locate executable using which 23684 new_path=`$WHICH "$new_path" 2> /dev/null` 23685 23686 if test "x$new_path" = x; then 23687 # Oops. Which didn't find the executable. 23688 # The splitting of arguments from the executable at a space might have been incorrect, 23689 # since paths with space are more likely in Windows. Give it another try with the whole 23690 # argument. 23691 path="$complete" 23692 arguments="EOL" 23693 new_path="$path" 23694 23695 windows_path="$new_path" 23696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23697 unix_path=`$CYGPATH -u "$windows_path"` 23698 new_path="$unix_path" 23699 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23700 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23701 new_path="$unix_path" 23702 fi 23703 23704 23705 new_path=`$WHICH "$new_path" 2> /dev/null` 23706 23707 if test "x$new_path" = x; then 23708 # It's still not found. Now this is an unrecoverable error. 23709 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23710 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23711 has_space=`$ECHO "$complete" | $GREP " "` 23712 if test "x$has_space" != x; then 23713 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23714 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23715 fi 23716 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23717 fi 23718 fi 23719 23720 # Now new_path has a complete unix path to the binary 23721 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 23722 # Keep paths in /bin as-is, but remove trailing .exe if any 23723 new_path="${new_path/%.exe/}" 23724 # Do not save /bin paths to all_fixpath_prefixes! 23725 else 23726 # Not in mixed or Windows style, start by that. 23727 new_path=`cmd //c echo $new_path` 23728 23729 input_path="$new_path" 23730 # Check if we need to convert this using DOS-style short mode. If the path 23731 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23732 # take no chances and rewrite it. 23733 # Note: m4 eats our [], so we need to use [ and ] instead. 23734 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23735 if test "x$has_forbidden_chars" != x; then 23736 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23737 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23738 fi 23739 23740 # Output is in $new_path 23741 23742 windows_path="$new_path" 23743 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23744 unix_path=`$CYGPATH -u "$windows_path"` 23745 new_path="$unix_path" 23746 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23747 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23748 new_path="$unix_path" 23749 fi 23750 23751 # remove trailing .exe if any 23752 new_path="${new_path/%.exe/}" 23753 23754 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23755 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23756 fi 23757 23758 else 23759 # We're on a posix platform. Hooray! :) 23760 # First separate the path from the arguments. This will split at the first 23761 # space. 23762 complete="$RC" 23763 path="${complete%% *}" 23764 tmp="$complete EOL" 23765 arguments="${tmp#* }" 23766 23767 # Cannot rely on the command "which" here since it doesn't always work. 23768 is_absolute_path=`$ECHO "$path" | $GREP ^/` 23769 if test -z "$is_absolute_path"; then 23770 # Path to executable is not absolute. Find it. 23771 IFS_save="$IFS" 23772 IFS=: 23773 for p in $PATH; do 23774 if test -f "$p/$path" && test -x "$p/$path"; then 23775 new_path="$p/$path" 23776 break 23777 fi 23778 done 23779 IFS="$IFS_save" 23780 else 23781 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving RC (as $path) failed, using $path directly." >&5 23782 $as_echo "$as_me: Resolving RC (as $path) failed, using $path directly." >&6;} 23783 new_path="$path" 23784 fi 23785 23786 if test "x$new_path" = x; then 23787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 23788 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 23789 has_space=`$ECHO "$complete" | $GREP " "` 23790 if test "x$has_space" != x; then 23791 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 23792 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 23793 fi 23794 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 23795 fi 23796 fi 23797 23798 # Now join together the path and the arguments once again 23799 if test "x$arguments" != xEOL; then 23800 new_complete="$new_path ${arguments% *}" 23801 else 23802 new_complete="$new_path" 23803 fi 23804 23805 if test "x$complete" != "x$new_complete"; then 23806 RC="$new_complete" 23807 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 23808 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 23809 fi 23810 23811 23812 # For hotspot, we need these in Windows mixed path, 23813 # so rewrite them all. Need added .exe suffix. 23814 HOTSPOT_CXX="$CXX.exe" 23815 HOTSPOT_LD="$LD.exe" 23816 HOTSPOT_MT="$MT.exe" 23817 HOTSPOT_RC="$RC.exe" 23818 23819 unix_path="$HOTSPOT_CXX" 23820 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23821 windows_path=`$CYGPATH -m "$unix_path"` 23822 HOTSPOT_CXX="$windows_path" 23823 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23824 windows_path=`cmd //c echo $unix_path` 23825 HOTSPOT_CXX="$windows_path" 23826 fi 23827 23828 23829 unix_path="$HOTSPOT_LD" 23830 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23831 windows_path=`$CYGPATH -m "$unix_path"` 23832 HOTSPOT_LD="$windows_path" 23833 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23834 windows_path=`cmd //c echo $unix_path` 23835 HOTSPOT_LD="$windows_path" 23836 fi 23837 23838 23839 unix_path="$HOTSPOT_MT" 23840 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23841 windows_path=`$CYGPATH -m "$unix_path"` 23842 HOTSPOT_MT="$windows_path" 23843 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23844 windows_path=`cmd //c echo $unix_path` 23845 HOTSPOT_MT="$windows_path" 23846 fi 23847 23848 23849 unix_path="$HOTSPOT_RC" 23850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23851 windows_path=`$CYGPATH -m "$unix_path"` 23852 HOTSPOT_RC="$windows_path" 23853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23854 windows_path=`cmd //c echo $unix_path` 23855 HOTSPOT_RC="$windows_path" 23856 fi 23857 23858 23859 23860 23861 RC_FLAGS="-nologo -l 0x409 -r" 23862 if test "x$VARIANT" = xOPT; then : 23863 23864 RC_FLAGS="$RC_FLAGS -d NDEBUG" 23865 23866 fi 23867 23868 # The version variables used to create RC_FLAGS may be overridden 23869 # in a custom configure script, or possibly the command line. 23870 # Let those variables be expanded at make time in spec.gmk. 23871 # The \$ are escaped to the shell, and the $(...) variables 23872 # are evaluated by make. 23873 RC_FLAGS="$RC_FLAGS \ 23874 -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \ 23875 -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \ 23876 -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 23877 -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \ 23878 -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 23879 -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \ 23880 -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\"" 23881 23882 # lib.exe is used to create static libraries. 23883 # Extract the first word of "lib", so it can be a program name with args. 23884 set dummy lib; ac_word=$2 23885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23886 $as_echo_n "checking for $ac_word... " >&6; } 23887 if ${ac_cv_prog_WINAR+:} false; then : 23888 $as_echo_n "(cached) " >&6 23889 else 23890 if test -n "$WINAR"; then 23891 ac_cv_prog_WINAR="$WINAR" # Let the user override the test. 23892 else 23893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23894 for as_dir in $PATH 23895 do 23896 IFS=$as_save_IFS 23897 test -z "$as_dir" && as_dir=. 23898 for ac_exec_ext in '' $ac_executable_extensions; do 23899 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 23900 ac_cv_prog_WINAR="lib" 23901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23902 break 2 23903 fi 23904 done 23905 done 23906 IFS=$as_save_IFS 23907 23908 fi 23909 fi 23910 WINAR=$ac_cv_prog_WINAR 23911 if test -n "$WINAR"; then 23912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINAR" >&5 23913 $as_echo "$WINAR" >&6; } 23914 else 23915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23916 $as_echo "no" >&6; } 23917 fi 23918 23919 23920 23921 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23922 23923 # First separate the path from the arguments. This will split at the first 23924 # space. 23925 complete="$WINAR" 23926 path="${complete%% *}" 23927 tmp="$complete EOL" 23928 arguments="${tmp#* }" 23929 23930 # Input might be given as Windows format, start by converting to 23931 # unix format. 23932 new_path=`$CYGPATH -u "$path"` 23933 23934 # Now try to locate executable using which 23935 new_path=`$WHICH "$new_path" 2> /dev/null` 23936 # bat and cmd files are not always considered executable in cygwin causing which 23937 # to not find them 23938 if test "x$new_path" = x \ 23939 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23940 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23941 new_path=`$CYGPATH -u "$path"` 23942 fi 23943 if test "x$new_path" = x; then 23944 # Oops. Which didn't find the executable. 23945 # The splitting of arguments from the executable at a space might have been incorrect, 23946 # since paths with space are more likely in Windows. Give it another try with the whole 23947 # argument. 23948 path="$complete" 23949 arguments="EOL" 23950 new_path=`$CYGPATH -u "$path"` 23951 new_path=`$WHICH "$new_path" 2> /dev/null` 23952 # bat and cmd files are not always considered executable in cygwin causing which 23953 # to not find them 23954 if test "x$new_path" = x \ 23955 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 23956 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 23957 new_path=`$CYGPATH -u "$path"` 23958 fi 23959 if test "x$new_path" = x; then 23960 # It's still not found. Now this is an unrecoverable error. 23961 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 23962 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 23963 has_space=`$ECHO "$complete" | $GREP " "` 23964 if test "x$has_space" != x; then 23965 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 23966 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 23967 fi 23968 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 23969 fi 23970 fi 23971 23972 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23973 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23974 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23975 # "foo.exe" is OK but "foo" is an error. 23976 # 23977 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23978 # It is also a way to make sure we got the proper file name for the real test later on. 23979 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23980 if test "x$test_shortpath" = x; then 23981 # Short path failed, file does not exist as specified. 23982 # Try adding .exe or .cmd 23983 if test -f "${new_path}.exe"; then 23984 input_to_shortpath="${new_path}.exe" 23985 elif test -f "${new_path}.cmd"; then 23986 input_to_shortpath="${new_path}.cmd" 23987 else 23988 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$new_path\", is invalid." >&5 23989 $as_echo "$as_me: The path of WINAR, which resolves as \"$new_path\", is invalid." >&6;} 23990 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 23991 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 23992 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 23993 fi 23994 else 23995 input_to_shortpath="$new_path" 23996 fi 23997 23998 # Call helper function which possibly converts this using DOS-style short mode. 23999 # If so, the updated path is stored in $new_path. 24000 new_path="$input_to_shortpath" 24001 24002 input_path="$input_to_shortpath" 24003 # Check if we need to convert this using DOS-style short mode. If the path 24004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24005 # take no chances and rewrite it. 24006 # Note: m4 eats our [], so we need to use [ and ] instead. 24007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24008 if test "x$has_forbidden_chars" != x; then 24009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24010 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24011 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24012 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24013 # Going to short mode and back again did indeed matter. Since short mode is 24014 # case insensitive, let's make it lowercase to improve readability. 24015 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24016 # Now convert it back to Unix-stile (cygpath) 24017 input_path=`$CYGPATH -u "$shortmode_path"` 24018 new_path="$input_path" 24019 fi 24020 fi 24021 24022 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24023 if test "x$test_cygdrive_prefix" = x; then 24024 # As a simple fix, exclude /usr/bin since it's not a real path. 24025 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24026 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24027 # a path prefixed by /cygdrive for fixpath to work. 24028 new_path="$CYGWIN_ROOT_PATH$input_path" 24029 fi 24030 fi 24031 24032 # remove trailing .exe if any 24033 new_path="${new_path/%.exe/}" 24034 24035 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24036 24037 # First separate the path from the arguments. This will split at the first 24038 # space. 24039 complete="$WINAR" 24040 path="${complete%% *}" 24041 tmp="$complete EOL" 24042 arguments="${tmp#* }" 24043 24044 # Input might be given as Windows format, start by converting to 24045 # unix format. 24046 new_path="$path" 24047 24048 windows_path="$new_path" 24049 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24050 unix_path=`$CYGPATH -u "$windows_path"` 24051 new_path="$unix_path" 24052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24053 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24054 new_path="$unix_path" 24055 fi 24056 24057 24058 # Now try to locate executable using which 24059 new_path=`$WHICH "$new_path" 2> /dev/null` 24060 24061 if test "x$new_path" = x; then 24062 # Oops. Which didn't find the executable. 24063 # The splitting of arguments from the executable at a space might have been incorrect, 24064 # since paths with space are more likely in Windows. Give it another try with the whole 24065 # argument. 24066 path="$complete" 24067 arguments="EOL" 24068 new_path="$path" 24069 24070 windows_path="$new_path" 24071 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24072 unix_path=`$CYGPATH -u "$windows_path"` 24073 new_path="$unix_path" 24074 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24075 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24076 new_path="$unix_path" 24077 fi 24078 24079 24080 new_path=`$WHICH "$new_path" 2> /dev/null` 24081 24082 if test "x$new_path" = x; then 24083 # It's still not found. Now this is an unrecoverable error. 24084 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 24085 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 24086 has_space=`$ECHO "$complete" | $GREP " "` 24087 if test "x$has_space" != x; then 24088 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24089 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24090 fi 24091 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24092 fi 24093 fi 24094 24095 # Now new_path has a complete unix path to the binary 24096 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24097 # Keep paths in /bin as-is, but remove trailing .exe if any 24098 new_path="${new_path/%.exe/}" 24099 # Do not save /bin paths to all_fixpath_prefixes! 24100 else 24101 # Not in mixed or Windows style, start by that. 24102 new_path=`cmd //c echo $new_path` 24103 24104 input_path="$new_path" 24105 # Check if we need to convert this using DOS-style short mode. If the path 24106 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24107 # take no chances and rewrite it. 24108 # Note: m4 eats our [], so we need to use [ and ] instead. 24109 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24110 if test "x$has_forbidden_chars" != x; then 24111 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24112 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24113 fi 24114 24115 # Output is in $new_path 24116 24117 windows_path="$new_path" 24118 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24119 unix_path=`$CYGPATH -u "$windows_path"` 24120 new_path="$unix_path" 24121 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24122 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24123 new_path="$unix_path" 24124 fi 24125 24126 # remove trailing .exe if any 24127 new_path="${new_path/%.exe/}" 24128 24129 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24130 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24131 fi 24132 24133 else 24134 # We're on a posix platform. Hooray! :) 24135 # First separate the path from the arguments. This will split at the first 24136 # space. 24137 complete="$WINAR" 24138 path="${complete%% *}" 24139 tmp="$complete EOL" 24140 arguments="${tmp#* }" 24141 24142 # Cannot rely on the command "which" here since it doesn't always work. 24143 is_absolute_path=`$ECHO "$path" | $GREP ^/` 24144 if test -z "$is_absolute_path"; then 24145 # Path to executable is not absolute. Find it. 24146 IFS_save="$IFS" 24147 IFS=: 24148 for p in $PATH; do 24149 if test -f "$p/$path" && test -x "$p/$path"; then 24150 new_path="$p/$path" 24151 break 24152 fi 24153 done 24154 IFS="$IFS_save" 24155 else 24156 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINAR (as $path) failed, using $path directly." >&5 24157 $as_echo "$as_me: Resolving WINAR (as $path) failed, using $path directly." >&6;} 24158 new_path="$path" 24159 fi 24160 24161 if test "x$new_path" = x; then 24162 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5 24163 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;} 24164 has_space=`$ECHO "$complete" | $GREP " "` 24165 if test "x$has_space" != x; then 24166 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 24167 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 24168 fi 24169 as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5 24170 fi 24171 fi 24172 24173 # Now join together the path and the arguments once again 24174 if test "x$arguments" != xEOL; then 24175 new_complete="$new_path ${arguments% *}" 24176 else 24177 new_complete="$new_path" 24178 fi 24179 24180 if test "x$complete" != "x$new_complete"; then 24181 WINAR="$new_complete" 24182 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINAR to \"$new_complete\"" >&5 24183 $as_echo "$as_me: Rewriting WINAR to \"$new_complete\"" >&6;} 24184 fi 24185 24186 AR="$WINAR" 24187 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 24188 24189 # Extract the first word of "dumpbin", so it can be a program name with args. 24190 set dummy dumpbin; ac_word=$2 24191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24192 $as_echo_n "checking for $ac_word... " >&6; } 24193 if ${ac_cv_prog_DUMPBIN+:} false; then : 24194 $as_echo_n "(cached) " >&6 24195 else 24196 if test -n "$DUMPBIN"; then 24197 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 24198 else 24199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24200 for as_dir in $PATH 24201 do 24202 IFS=$as_save_IFS 24203 test -z "$as_dir" && as_dir=. 24204 for ac_exec_ext in '' $ac_executable_extensions; do 24205 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 24206 ac_cv_prog_DUMPBIN="dumpbin" 24207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24208 break 2 24209 fi 24210 done 24211 done 24212 IFS=$as_save_IFS 24213 24214 fi 24215 fi 24216 DUMPBIN=$ac_cv_prog_DUMPBIN 24217 if test -n "$DUMPBIN"; then 24218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 24219 $as_echo "$DUMPBIN" >&6; } 24220 else 24221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24222 $as_echo "no" >&6; } 24223 fi 24224 24225 24226 24227 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24228 24229 # First separate the path from the arguments. This will split at the first 24230 # space. 24231 complete="$DUMPBIN" 24232 path="${complete%% *}" 24233 tmp="$complete EOL" 24234 arguments="${tmp#* }" 24235 24236 # Input might be given as Windows format, start by converting to 24237 # unix format. 24238 new_path=`$CYGPATH -u "$path"` 24239 24240 # Now try to locate executable using which 24241 new_path=`$WHICH "$new_path" 2> /dev/null` 24242 # bat and cmd files are not always considered executable in cygwin causing which 24243 # to not find them 24244 if test "x$new_path" = x \ 24245 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24246 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24247 new_path=`$CYGPATH -u "$path"` 24248 fi 24249 if test "x$new_path" = x; then 24250 # Oops. Which didn't find the executable. 24251 # The splitting of arguments from the executable at a space might have been incorrect, 24252 # since paths with space are more likely in Windows. Give it another try with the whole 24253 # argument. 24254 path="$complete" 24255 arguments="EOL" 24256 new_path=`$CYGPATH -u "$path"` 24257 new_path=`$WHICH "$new_path" 2> /dev/null` 24258 # bat and cmd files are not always considered executable in cygwin causing which 24259 # to not find them 24260 if test "x$new_path" = x \ 24261 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24262 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24263 new_path=`$CYGPATH -u "$path"` 24264 fi 24265 if test "x$new_path" = x; then 24266 # It's still not found. Now this is an unrecoverable error. 24267 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24268 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24269 has_space=`$ECHO "$complete" | $GREP " "` 24270 if test "x$has_space" != x; then 24271 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24272 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24273 fi 24274 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24275 fi 24276 fi 24277 24278 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24279 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24280 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24281 # "foo.exe" is OK but "foo" is an error. 24282 # 24283 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24284 # It is also a way to make sure we got the proper file name for the real test later on. 24285 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24286 if test "x$test_shortpath" = x; then 24287 # Short path failed, file does not exist as specified. 24288 # Try adding .exe or .cmd 24289 if test -f "${new_path}.exe"; then 24290 input_to_shortpath="${new_path}.exe" 24291 elif test -f "${new_path}.cmd"; then 24292 input_to_shortpath="${new_path}.cmd" 24293 else 24294 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 24295 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 24296 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 24297 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 24298 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24299 fi 24300 else 24301 input_to_shortpath="$new_path" 24302 fi 24303 24304 # Call helper function which possibly converts this using DOS-style short mode. 24305 # If so, the updated path is stored in $new_path. 24306 new_path="$input_to_shortpath" 24307 24308 input_path="$input_to_shortpath" 24309 # Check if we need to convert this using DOS-style short mode. If the path 24310 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24311 # take no chances and rewrite it. 24312 # Note: m4 eats our [], so we need to use [ and ] instead. 24313 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24314 if test "x$has_forbidden_chars" != x; then 24315 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24316 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24317 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24318 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24319 # Going to short mode and back again did indeed matter. Since short mode is 24320 # case insensitive, let's make it lowercase to improve readability. 24321 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24322 # Now convert it back to Unix-stile (cygpath) 24323 input_path=`$CYGPATH -u "$shortmode_path"` 24324 new_path="$input_path" 24325 fi 24326 fi 24327 24328 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24329 if test "x$test_cygdrive_prefix" = x; then 24330 # As a simple fix, exclude /usr/bin since it's not a real path. 24331 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24332 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24333 # a path prefixed by /cygdrive for fixpath to work. 24334 new_path="$CYGWIN_ROOT_PATH$input_path" 24335 fi 24336 fi 24337 24338 # remove trailing .exe if any 24339 new_path="${new_path/%.exe/}" 24340 24341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24342 24343 # First separate the path from the arguments. This will split at the first 24344 # space. 24345 complete="$DUMPBIN" 24346 path="${complete%% *}" 24347 tmp="$complete EOL" 24348 arguments="${tmp#* }" 24349 24350 # Input might be given as Windows format, start by converting to 24351 # unix format. 24352 new_path="$path" 24353 24354 windows_path="$new_path" 24355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24356 unix_path=`$CYGPATH -u "$windows_path"` 24357 new_path="$unix_path" 24358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24360 new_path="$unix_path" 24361 fi 24362 24363 24364 # Now try to locate executable using which 24365 new_path=`$WHICH "$new_path" 2> /dev/null` 24366 24367 if test "x$new_path" = x; then 24368 # Oops. Which didn't find the executable. 24369 # The splitting of arguments from the executable at a space might have been incorrect, 24370 # since paths with space are more likely in Windows. Give it another try with the whole 24371 # argument. 24372 path="$complete" 24373 arguments="EOL" 24374 new_path="$path" 24375 24376 windows_path="$new_path" 24377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24378 unix_path=`$CYGPATH -u "$windows_path"` 24379 new_path="$unix_path" 24380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24381 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24382 new_path="$unix_path" 24383 fi 24384 24385 24386 new_path=`$WHICH "$new_path" 2> /dev/null` 24387 24388 if test "x$new_path" = x; then 24389 # It's still not found. Now this is an unrecoverable error. 24390 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24391 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24392 has_space=`$ECHO "$complete" | $GREP " "` 24393 if test "x$has_space" != x; then 24394 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24395 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24396 fi 24397 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24398 fi 24399 fi 24400 24401 # Now new_path has a complete unix path to the binary 24402 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24403 # Keep paths in /bin as-is, but remove trailing .exe if any 24404 new_path="${new_path/%.exe/}" 24405 # Do not save /bin paths to all_fixpath_prefixes! 24406 else 24407 # Not in mixed or Windows style, start by that. 24408 new_path=`cmd //c echo $new_path` 24409 24410 input_path="$new_path" 24411 # Check if we need to convert this using DOS-style short mode. If the path 24412 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24413 # take no chances and rewrite it. 24414 # Note: m4 eats our [], so we need to use [ and ] instead. 24415 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24416 if test "x$has_forbidden_chars" != x; then 24417 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24418 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24419 fi 24420 24421 # Output is in $new_path 24422 24423 windows_path="$new_path" 24424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24425 unix_path=`$CYGPATH -u "$windows_path"` 24426 new_path="$unix_path" 24427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24428 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24429 new_path="$unix_path" 24430 fi 24431 24432 # remove trailing .exe if any 24433 new_path="${new_path/%.exe/}" 24434 24435 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24436 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24437 fi 24438 24439 else 24440 # We're on a posix platform. Hooray! :) 24441 # First separate the path from the arguments. This will split at the first 24442 # space. 24443 complete="$DUMPBIN" 24444 path="${complete%% *}" 24445 tmp="$complete EOL" 24446 arguments="${tmp#* }" 24447 24448 # Cannot rely on the command "which" here since it doesn't always work. 24449 is_absolute_path=`$ECHO "$path" | $GREP ^/` 24450 if test -z "$is_absolute_path"; then 24451 # Path to executable is not absolute. Find it. 24452 IFS_save="$IFS" 24453 IFS=: 24454 for p in $PATH; do 24455 if test -f "$p/$path" && test -x "$p/$path"; then 24456 new_path="$p/$path" 24457 break 24458 fi 24459 done 24460 IFS="$IFS_save" 24461 else 24462 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving DUMPBIN (as $path) failed, using $path directly." >&5 24463 $as_echo "$as_me: Resolving DUMPBIN (as $path) failed, using $path directly." >&6;} 24464 new_path="$path" 24465 fi 24466 24467 if test "x$new_path" = x; then 24468 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 24469 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 24470 has_space=`$ECHO "$complete" | $GREP " "` 24471 if test "x$has_space" != x; then 24472 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 24473 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 24474 fi 24475 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 24476 fi 24477 fi 24478 24479 # Now join together the path and the arguments once again 24480 if test "x$arguments" != xEOL; then 24481 new_complete="$new_path ${arguments% *}" 24482 else 24483 new_complete="$new_path" 24484 fi 24485 24486 if test "x$complete" != "x$new_complete"; then 24487 DUMPBIN="$new_complete" 24488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 24489 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 24490 fi 24491 24492 24493 COMPILER_TYPE=CL 24494 CCXXFLAGS="$CCXXFLAGS -nologo" 24495 24496 fi 24497 24498 24499 24500 ac_ext=c 24501 ac_cpp='$CPP $CPPFLAGS' 24502 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 24503 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 24504 ac_compiler_gnu=$ac_cv_c_compiler_gnu 24505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 24506 $as_echo_n "checking how to run the C preprocessor... " >&6; } 24507 # On Suns, sometimes $CPP names a directory. 24508 if test -n "$CPP" && test -d "$CPP"; then 24509 CPP= 24510 fi 24511 if test -z "$CPP"; then 24512 if ${ac_cv_prog_CPP+:} false; then : 24513 $as_echo_n "(cached) " >&6 24514 else 24515 # Double quotes because CPP needs to be expanded 24516 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 24517 do 24518 ac_preproc_ok=false 24519 for ac_c_preproc_warn_flag in '' yes 24520 do 24521 # Use a header file that comes with gcc, so configuring glibc 24522 # with a fresh cross-compiler works. 24523 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24524 # <limits.h> exists even on freestanding compilers. 24525 # On the NeXT, cc -E runs the code through the compiler's parser, 24526 # not just through cpp. "Syntax error" is here to catch this case. 24527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24528 /* end confdefs.h. */ 24529 #ifdef __STDC__ 24530 # include <limits.h> 24531 #else 24532 # include <assert.h> 24533 #endif 24534 Syntax error 24535 _ACEOF 24536 if ac_fn_c_try_cpp "$LINENO"; then : 24537 24538 else 24539 # Broken: fails on valid input. 24540 continue 24541 fi 24542 rm -f conftest.err conftest.i conftest.$ac_ext 24543 24544 # OK, works on sane cases. Now check whether nonexistent headers 24545 # can be detected and how. 24546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24547 /* end confdefs.h. */ 24548 #include <ac_nonexistent.h> 24549 _ACEOF 24550 if ac_fn_c_try_cpp "$LINENO"; then : 24551 # Broken: success on invalid input. 24552 continue 24553 else 24554 # Passes both tests. 24555 ac_preproc_ok=: 24556 break 24557 fi 24558 rm -f conftest.err conftest.i conftest.$ac_ext 24559 24560 done 24561 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 24562 rm -f conftest.i conftest.err conftest.$ac_ext 24563 if $ac_preproc_ok; then : 24564 break 24565 fi 24566 24567 done 24568 ac_cv_prog_CPP=$CPP 24569 24570 fi 24571 CPP=$ac_cv_prog_CPP 24572 else 24573 ac_cv_prog_CPP=$CPP 24574 fi 24575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 24576 $as_echo "$CPP" >&6; } 24577 ac_preproc_ok=false 24578 for ac_c_preproc_warn_flag in '' yes 24579 do 24580 # Use a header file that comes with gcc, so configuring glibc 24581 # with a fresh cross-compiler works. 24582 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24583 # <limits.h> exists even on freestanding compilers. 24584 # On the NeXT, cc -E runs the code through the compiler's parser, 24585 # not just through cpp. "Syntax error" is here to catch this case. 24586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24587 /* end confdefs.h. */ 24588 #ifdef __STDC__ 24589 # include <limits.h> 24590 #else 24591 # include <assert.h> 24592 #endif 24593 Syntax error 24594 _ACEOF 24595 if ac_fn_c_try_cpp "$LINENO"; then : 24596 24597 else 24598 # Broken: fails on valid input. 24599 continue 24600 fi 24601 rm -f conftest.err conftest.i conftest.$ac_ext 24602 24603 # OK, works on sane cases. Now check whether nonexistent headers 24604 # can be detected and how. 24605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24606 /* end confdefs.h. */ 24607 #include <ac_nonexistent.h> 24608 _ACEOF 24609 if ac_fn_c_try_cpp "$LINENO"; then : 24610 # Broken: success on invalid input. 24611 continue 24612 else 24613 # Passes both tests. 24614 ac_preproc_ok=: 24615 break 24616 fi 24617 rm -f conftest.err conftest.i conftest.$ac_ext 24618 24619 done 24620 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 24621 rm -f conftest.i conftest.err conftest.$ac_ext 24622 if $ac_preproc_ok; then : 24623 24624 else 24625 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 24626 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 24627 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 24628 See \`config.log' for more details" "$LINENO" 5; } 24629 fi 24630 24631 ac_ext=cpp 24632 ac_cpp='$CXXCPP $CPPFLAGS' 24633 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 24634 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 24635 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 24636 24637 24638 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24639 24640 # First separate the path from the arguments. This will split at the first 24641 # space. 24642 complete="$CPP" 24643 path="${complete%% *}" 24644 tmp="$complete EOL" 24645 arguments="${tmp#* }" 24646 24647 # Input might be given as Windows format, start by converting to 24648 # unix format. 24649 new_path=`$CYGPATH -u "$path"` 24650 24651 # Now try to locate executable using which 24652 new_path=`$WHICH "$new_path" 2> /dev/null` 24653 # bat and cmd files are not always considered executable in cygwin causing which 24654 # to not find them 24655 if test "x$new_path" = x \ 24656 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24657 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24658 new_path=`$CYGPATH -u "$path"` 24659 fi 24660 if test "x$new_path" = x; then 24661 # Oops. Which didn't find the executable. 24662 # The splitting of arguments from the executable at a space might have been incorrect, 24663 # since paths with space are more likely in Windows. Give it another try with the whole 24664 # argument. 24665 path="$complete" 24666 arguments="EOL" 24667 new_path=`$CYGPATH -u "$path"` 24668 new_path=`$WHICH "$new_path" 2> /dev/null` 24669 # bat and cmd files are not always considered executable in cygwin causing which 24670 # to not find them 24671 if test "x$new_path" = x \ 24672 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 24673 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 24674 new_path=`$CYGPATH -u "$path"` 24675 fi 24676 if test "x$new_path" = x; then 24677 # It's still not found. Now this is an unrecoverable error. 24678 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 24679 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 24680 has_space=`$ECHO "$complete" | $GREP " "` 24681 if test "x$has_space" != x; then 24682 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24683 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24684 fi 24685 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24686 fi 24687 fi 24688 24689 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24690 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24691 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24692 # "foo.exe" is OK but "foo" is an error. 24693 # 24694 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24695 # It is also a way to make sure we got the proper file name for the real test later on. 24696 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24697 if test "x$test_shortpath" = x; then 24698 # Short path failed, file does not exist as specified. 24699 # Try adding .exe or .cmd 24700 if test -f "${new_path}.exe"; then 24701 input_to_shortpath="${new_path}.exe" 24702 elif test -f "${new_path}.cmd"; then 24703 input_to_shortpath="${new_path}.cmd" 24704 else 24705 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 24706 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 24707 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 24708 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 24709 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24710 fi 24711 else 24712 input_to_shortpath="$new_path" 24713 fi 24714 24715 # Call helper function which possibly converts this using DOS-style short mode. 24716 # If so, the updated path is stored in $new_path. 24717 new_path="$input_to_shortpath" 24718 24719 input_path="$input_to_shortpath" 24720 # Check if we need to convert this using DOS-style short mode. If the path 24721 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24722 # take no chances and rewrite it. 24723 # Note: m4 eats our [], so we need to use [ and ] instead. 24724 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24725 if test "x$has_forbidden_chars" != x; then 24726 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24727 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24728 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24729 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24730 # Going to short mode and back again did indeed matter. Since short mode is 24731 # case insensitive, let's make it lowercase to improve readability. 24732 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24733 # Now convert it back to Unix-stile (cygpath) 24734 input_path=`$CYGPATH -u "$shortmode_path"` 24735 new_path="$input_path" 24736 fi 24737 fi 24738 24739 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24740 if test "x$test_cygdrive_prefix" = x; then 24741 # As a simple fix, exclude /usr/bin since it's not a real path. 24742 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 24743 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24744 # a path prefixed by /cygdrive for fixpath to work. 24745 new_path="$CYGWIN_ROOT_PATH$input_path" 24746 fi 24747 fi 24748 24749 # remove trailing .exe if any 24750 new_path="${new_path/%.exe/}" 24751 24752 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24753 24754 # First separate the path from the arguments. This will split at the first 24755 # space. 24756 complete="$CPP" 24757 path="${complete%% *}" 24758 tmp="$complete EOL" 24759 arguments="${tmp#* }" 24760 24761 # Input might be given as Windows format, start by converting to 24762 # unix format. 24763 new_path="$path" 24764 24765 windows_path="$new_path" 24766 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24767 unix_path=`$CYGPATH -u "$windows_path"` 24768 new_path="$unix_path" 24769 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24770 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24771 new_path="$unix_path" 24772 fi 24773 24774 24775 # Now try to locate executable using which 24776 new_path=`$WHICH "$new_path" 2> /dev/null` 24777 24778 if test "x$new_path" = x; then 24779 # Oops. Which didn't find the executable. 24780 # The splitting of arguments from the executable at a space might have been incorrect, 24781 # since paths with space are more likely in Windows. Give it another try with the whole 24782 # argument. 24783 path="$complete" 24784 arguments="EOL" 24785 new_path="$path" 24786 24787 windows_path="$new_path" 24788 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24789 unix_path=`$CYGPATH -u "$windows_path"` 24790 new_path="$unix_path" 24791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24792 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24793 new_path="$unix_path" 24794 fi 24795 24796 24797 new_path=`$WHICH "$new_path" 2> /dev/null` 24798 24799 if test "x$new_path" = x; then 24800 # It's still not found. Now this is an unrecoverable error. 24801 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 24802 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 24803 has_space=`$ECHO "$complete" | $GREP " "` 24804 if test "x$has_space" != x; then 24805 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 24806 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 24807 fi 24808 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24809 fi 24810 fi 24811 24812 # Now new_path has a complete unix path to the binary 24813 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 24814 # Keep paths in /bin as-is, but remove trailing .exe if any 24815 new_path="${new_path/%.exe/}" 24816 # Do not save /bin paths to all_fixpath_prefixes! 24817 else 24818 # Not in mixed or Windows style, start by that. 24819 new_path=`cmd //c echo $new_path` 24820 24821 input_path="$new_path" 24822 # Check if we need to convert this using DOS-style short mode. If the path 24823 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24824 # take no chances and rewrite it. 24825 # Note: m4 eats our [], so we need to use [ and ] instead. 24826 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24827 if test "x$has_forbidden_chars" != x; then 24828 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24829 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24830 fi 24831 24832 # Output is in $new_path 24833 24834 windows_path="$new_path" 24835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24836 unix_path=`$CYGPATH -u "$windows_path"` 24837 new_path="$unix_path" 24838 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24839 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24840 new_path="$unix_path" 24841 fi 24842 24843 # remove trailing .exe if any 24844 new_path="${new_path/%.exe/}" 24845 24846 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24847 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24848 fi 24849 24850 else 24851 # We're on a posix platform. Hooray! :) 24852 # First separate the path from the arguments. This will split at the first 24853 # space. 24854 complete="$CPP" 24855 path="${complete%% *}" 24856 tmp="$complete EOL" 24857 arguments="${tmp#* }" 24858 24859 # Cannot rely on the command "which" here since it doesn't always work. 24860 is_absolute_path=`$ECHO "$path" | $GREP ^/` 24861 if test -z "$is_absolute_path"; then 24862 # Path to executable is not absolute. Find it. 24863 IFS_save="$IFS" 24864 IFS=: 24865 for p in $PATH; do 24866 if test -f "$p/$path" && test -x "$p/$path"; then 24867 new_path="$p/$path" 24868 break 24869 fi 24870 done 24871 IFS="$IFS_save" 24872 else 24873 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CPP (as $path) failed, using $path directly." >&5 24874 $as_echo "$as_me: Resolving CPP (as $path) failed, using $path directly." >&6;} 24875 new_path="$path" 24876 fi 24877 24878 if test "x$new_path" = x; then 24879 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 24880 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 24881 has_space=`$ECHO "$complete" | $GREP " "` 24882 if test "x$has_space" != x; then 24883 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 24884 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 24885 fi 24886 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 24887 fi 24888 fi 24889 24890 # Now join together the path and the arguments once again 24891 if test "x$arguments" != xEOL; then 24892 new_complete="$new_path ${arguments% *}" 24893 else 24894 new_complete="$new_path" 24895 fi 24896 24897 if test "x$complete" != "x$new_complete"; then 24898 CPP="$new_complete" 24899 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 24900 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 24901 fi 24902 24903 24904 ac_ext=cpp 24905 ac_cpp='$CXXCPP $CPPFLAGS' 24906 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 24907 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 24908 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 24909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 24910 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 24911 if test -z "$CXXCPP"; then 24912 if ${ac_cv_prog_CXXCPP+:} false; then : 24913 $as_echo_n "(cached) " >&6 24914 else 24915 # Double quotes because CXXCPP needs to be expanded 24916 for CXXCPP in "$CXX -E" "/lib/cpp" 24917 do 24918 ac_preproc_ok=false 24919 for ac_cxx_preproc_warn_flag in '' yes 24920 do 24921 # Use a header file that comes with gcc, so configuring glibc 24922 # with a fresh cross-compiler works. 24923 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24924 # <limits.h> exists even on freestanding compilers. 24925 # On the NeXT, cc -E runs the code through the compiler's parser, 24926 # not just through cpp. "Syntax error" is here to catch this case. 24927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24928 /* end confdefs.h. */ 24929 #ifdef __STDC__ 24930 # include <limits.h> 24931 #else 24932 # include <assert.h> 24933 #endif 24934 Syntax error 24935 _ACEOF 24936 if ac_fn_cxx_try_cpp "$LINENO"; then : 24937 24938 else 24939 # Broken: fails on valid input. 24940 continue 24941 fi 24942 rm -f conftest.err conftest.i conftest.$ac_ext 24943 24944 # OK, works on sane cases. Now check whether nonexistent headers 24945 # can be detected and how. 24946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24947 /* end confdefs.h. */ 24948 #include <ac_nonexistent.h> 24949 _ACEOF 24950 if ac_fn_cxx_try_cpp "$LINENO"; then : 24951 # Broken: success on invalid input. 24952 continue 24953 else 24954 # Passes both tests. 24955 ac_preproc_ok=: 24956 break 24957 fi 24958 rm -f conftest.err conftest.i conftest.$ac_ext 24959 24960 done 24961 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 24962 rm -f conftest.i conftest.err conftest.$ac_ext 24963 if $ac_preproc_ok; then : 24964 break 24965 fi 24966 24967 done 24968 ac_cv_prog_CXXCPP=$CXXCPP 24969 24970 fi 24971 CXXCPP=$ac_cv_prog_CXXCPP 24972 else 24973 ac_cv_prog_CXXCPP=$CXXCPP 24974 fi 24975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 24976 $as_echo "$CXXCPP" >&6; } 24977 ac_preproc_ok=false 24978 for ac_cxx_preproc_warn_flag in '' yes 24979 do 24980 # Use a header file that comes with gcc, so configuring glibc 24981 # with a fresh cross-compiler works. 24982 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 24983 # <limits.h> exists even on freestanding compilers. 24984 # On the NeXT, cc -E runs the code through the compiler's parser, 24985 # not just through cpp. "Syntax error" is here to catch this case. 24986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24987 /* end confdefs.h. */ 24988 #ifdef __STDC__ 24989 # include <limits.h> 24990 #else 24991 # include <assert.h> 24992 #endif 24993 Syntax error 24994 _ACEOF 24995 if ac_fn_cxx_try_cpp "$LINENO"; then : 24996 24997 else 24998 # Broken: fails on valid input. 24999 continue 25000 fi 25001 rm -f conftest.err conftest.i conftest.$ac_ext 25002 25003 # OK, works on sane cases. Now check whether nonexistent headers 25004 # can be detected and how. 25005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25006 /* end confdefs.h. */ 25007 #include <ac_nonexistent.h> 25008 _ACEOF 25009 if ac_fn_cxx_try_cpp "$LINENO"; then : 25010 # Broken: success on invalid input. 25011 continue 25012 else 25013 # Passes both tests. 25014 ac_preproc_ok=: 25015 break 25016 fi 25017 rm -f conftest.err conftest.i conftest.$ac_ext 25018 25019 done 25020 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 25021 rm -f conftest.i conftest.err conftest.$ac_ext 25022 if $ac_preproc_ok; then : 25023 25024 else 25025 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 25026 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 25027 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 25028 See \`config.log' for more details" "$LINENO" 5; } 25029 fi 25030 25031 ac_ext=cpp 25032 ac_cpp='$CXXCPP $CPPFLAGS' 25033 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 25034 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 25035 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 25036 25037 25038 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25039 25040 # First separate the path from the arguments. This will split at the first 25041 # space. 25042 complete="$CXXCPP" 25043 path="${complete%% *}" 25044 tmp="$complete EOL" 25045 arguments="${tmp#* }" 25046 25047 # Input might be given as Windows format, start by converting to 25048 # unix format. 25049 new_path=`$CYGPATH -u "$path"` 25050 25051 # Now try to locate executable using which 25052 new_path=`$WHICH "$new_path" 2> /dev/null` 25053 # bat and cmd files are not always considered executable in cygwin causing which 25054 # to not find them 25055 if test "x$new_path" = x \ 25056 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25057 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25058 new_path=`$CYGPATH -u "$path"` 25059 fi 25060 if test "x$new_path" = x; then 25061 # Oops. Which didn't find the executable. 25062 # The splitting of arguments from the executable at a space might have been incorrect, 25063 # since paths with space are more likely in Windows. Give it another try with the whole 25064 # argument. 25065 path="$complete" 25066 arguments="EOL" 25067 new_path=`$CYGPATH -u "$path"` 25068 new_path=`$WHICH "$new_path" 2> /dev/null` 25069 # bat and cmd files are not always considered executable in cygwin causing which 25070 # to not find them 25071 if test "x$new_path" = x \ 25072 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25073 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25074 new_path=`$CYGPATH -u "$path"` 25075 fi 25076 if test "x$new_path" = x; then 25077 # It's still not found. Now this is an unrecoverable error. 25078 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25079 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25080 has_space=`$ECHO "$complete" | $GREP " "` 25081 if test "x$has_space" != x; then 25082 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25083 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25084 fi 25085 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25086 fi 25087 fi 25088 25089 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25090 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25091 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25092 # "foo.exe" is OK but "foo" is an error. 25093 # 25094 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25095 # It is also a way to make sure we got the proper file name for the real test later on. 25096 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25097 if test "x$test_shortpath" = x; then 25098 # Short path failed, file does not exist as specified. 25099 # Try adding .exe or .cmd 25100 if test -f "${new_path}.exe"; then 25101 input_to_shortpath="${new_path}.exe" 25102 elif test -f "${new_path}.cmd"; then 25103 input_to_shortpath="${new_path}.cmd" 25104 else 25105 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 25106 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 25107 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25108 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25109 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25110 fi 25111 else 25112 input_to_shortpath="$new_path" 25113 fi 25114 25115 # Call helper function which possibly converts this using DOS-style short mode. 25116 # If so, the updated path is stored in $new_path. 25117 new_path="$input_to_shortpath" 25118 25119 input_path="$input_to_shortpath" 25120 # Check if we need to convert this using DOS-style short mode. If the path 25121 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25122 # take no chances and rewrite it. 25123 # Note: m4 eats our [], so we need to use [ and ] instead. 25124 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25125 if test "x$has_forbidden_chars" != x; then 25126 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25127 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25128 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25129 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25130 # Going to short mode and back again did indeed matter. Since short mode is 25131 # case insensitive, let's make it lowercase to improve readability. 25132 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25133 # Now convert it back to Unix-stile (cygpath) 25134 input_path=`$CYGPATH -u "$shortmode_path"` 25135 new_path="$input_path" 25136 fi 25137 fi 25138 25139 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25140 if test "x$test_cygdrive_prefix" = x; then 25141 # As a simple fix, exclude /usr/bin since it's not a real path. 25142 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25143 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25144 # a path prefixed by /cygdrive for fixpath to work. 25145 new_path="$CYGWIN_ROOT_PATH$input_path" 25146 fi 25147 fi 25148 25149 # remove trailing .exe if any 25150 new_path="${new_path/%.exe/}" 25151 25152 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25153 25154 # First separate the path from the arguments. This will split at the first 25155 # space. 25156 complete="$CXXCPP" 25157 path="${complete%% *}" 25158 tmp="$complete EOL" 25159 arguments="${tmp#* }" 25160 25161 # Input might be given as Windows format, start by converting to 25162 # unix format. 25163 new_path="$path" 25164 25165 windows_path="$new_path" 25166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25167 unix_path=`$CYGPATH -u "$windows_path"` 25168 new_path="$unix_path" 25169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25170 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25171 new_path="$unix_path" 25172 fi 25173 25174 25175 # Now try to locate executable using which 25176 new_path=`$WHICH "$new_path" 2> /dev/null` 25177 25178 if test "x$new_path" = x; then 25179 # Oops. Which didn't find the executable. 25180 # The splitting of arguments from the executable at a space might have been incorrect, 25181 # since paths with space are more likely in Windows. Give it another try with the whole 25182 # argument. 25183 path="$complete" 25184 arguments="EOL" 25185 new_path="$path" 25186 25187 windows_path="$new_path" 25188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25189 unix_path=`$CYGPATH -u "$windows_path"` 25190 new_path="$unix_path" 25191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25192 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25193 new_path="$unix_path" 25194 fi 25195 25196 25197 new_path=`$WHICH "$new_path" 2> /dev/null` 25198 25199 if test "x$new_path" = x; then 25200 # It's still not found. Now this is an unrecoverable error. 25201 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25202 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25203 has_space=`$ECHO "$complete" | $GREP " "` 25204 if test "x$has_space" != x; then 25205 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25206 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25207 fi 25208 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25209 fi 25210 fi 25211 25212 # Now new_path has a complete unix path to the binary 25213 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 25214 # Keep paths in /bin as-is, but remove trailing .exe if any 25215 new_path="${new_path/%.exe/}" 25216 # Do not save /bin paths to all_fixpath_prefixes! 25217 else 25218 # Not in mixed or Windows style, start by that. 25219 new_path=`cmd //c echo $new_path` 25220 25221 input_path="$new_path" 25222 # Check if we need to convert this using DOS-style short mode. If the path 25223 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25224 # take no chances and rewrite it. 25225 # Note: m4 eats our [], so we need to use [ and ] instead. 25226 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25227 if test "x$has_forbidden_chars" != x; then 25228 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25229 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25230 fi 25231 25232 # Output is in $new_path 25233 25234 windows_path="$new_path" 25235 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25236 unix_path=`$CYGPATH -u "$windows_path"` 25237 new_path="$unix_path" 25238 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25239 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25240 new_path="$unix_path" 25241 fi 25242 25243 # remove trailing .exe if any 25244 new_path="${new_path/%.exe/}" 25245 25246 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25247 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25248 fi 25249 25250 else 25251 # We're on a posix platform. Hooray! :) 25252 # First separate the path from the arguments. This will split at the first 25253 # space. 25254 complete="$CXXCPP" 25255 path="${complete%% *}" 25256 tmp="$complete EOL" 25257 arguments="${tmp#* }" 25258 25259 # Cannot rely on the command "which" here since it doesn't always work. 25260 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25261 if test -z "$is_absolute_path"; then 25262 # Path to executable is not absolute. Find it. 25263 IFS_save="$IFS" 25264 IFS=: 25265 for p in $PATH; do 25266 if test -f "$p/$path" && test -x "$p/$path"; then 25267 new_path="$p/$path" 25268 break 25269 fi 25270 done 25271 IFS="$IFS_save" 25272 else 25273 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXXCPP (as $path) failed, using $path directly." >&5 25274 $as_echo "$as_me: Resolving CXXCPP (as $path) failed, using $path directly." >&6;} 25275 new_path="$path" 25276 fi 25277 25278 if test "x$new_path" = x; then 25279 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 25280 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 25281 has_space=`$ECHO "$complete" | $GREP " "` 25282 if test "x$has_space" != x; then 25283 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25284 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25285 fi 25286 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 25287 fi 25288 fi 25289 25290 # Now join together the path and the arguments once again 25291 if test "x$arguments" != xEOL; then 25292 new_complete="$new_path ${arguments% *}" 25293 else 25294 new_complete="$new_path" 25295 fi 25296 25297 if test "x$complete" != "x$new_complete"; then 25298 CXXCPP="$new_complete" 25299 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 25300 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 25301 fi 25302 25303 25304 if test "x$COMPILE_TYPE" != "xcross"; then 25305 # If we are not cross compiling, use the same compilers for 25306 # building the build platform executables. The cross-compilation 25307 # case needed to be done earlier, but this can only be done after 25308 # the native tools have been localized. 25309 BUILD_CC="$CC" 25310 BUILD_CXX="$CXX" 25311 BUILD_LD="$LD" 25312 fi 25313 25314 # for solaris we really need solaris tools, and not gnu equivalent 25315 # these seems to normally reside in /usr/ccs/bin so add that to path before 25316 # starting to probe 25317 # 25318 # NOTE: I add this /usr/ccs/bin after TOOLS but before OLD_PATH 25319 # so that it can be overriden --with-tools-dir 25320 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 25321 PATH="${TOOLS_DIR}:/usr/ccs/bin:${OLD_PATH}" 25322 fi 25323 25324 # Find the right assembler. 25325 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 25326 # Extract the first word of "as", so it can be a program name with args. 25327 set dummy as; ac_word=$2 25328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25329 $as_echo_n "checking for $ac_word... " >&6; } 25330 if ${ac_cv_path_AS+:} false; then : 25331 $as_echo_n "(cached) " >&6 25332 else 25333 case $AS in 25334 [\\/]* | ?:[\\/]*) 25335 ac_cv_path_AS="$AS" # Let the user override the test with a path. 25336 ;; 25337 *) 25338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25339 for as_dir in $PATH 25340 do 25341 IFS=$as_save_IFS 25342 test -z "$as_dir" && as_dir=. 25343 for ac_exec_ext in '' $ac_executable_extensions; do 25344 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 25345 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 25346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25347 break 2 25348 fi 25349 done 25350 done 25351 IFS=$as_save_IFS 25352 25353 ;; 25354 esac 25355 fi 25356 AS=$ac_cv_path_AS 25357 if test -n "$AS"; then 25358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 25359 $as_echo "$AS" >&6; } 25360 else 25361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25362 $as_echo "no" >&6; } 25363 fi 25364 25365 25366 25367 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25368 25369 # First separate the path from the arguments. This will split at the first 25370 # space. 25371 complete="$AS" 25372 path="${complete%% *}" 25373 tmp="$complete EOL" 25374 arguments="${tmp#* }" 25375 25376 # Input might be given as Windows format, start by converting to 25377 # unix format. 25378 new_path=`$CYGPATH -u "$path"` 25379 25380 # Now try to locate executable using which 25381 new_path=`$WHICH "$new_path" 2> /dev/null` 25382 # bat and cmd files are not always considered executable in cygwin causing which 25383 # to not find them 25384 if test "x$new_path" = x \ 25385 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25386 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25387 new_path=`$CYGPATH -u "$path"` 25388 fi 25389 if test "x$new_path" = x; then 25390 # Oops. Which didn't find the executable. 25391 # The splitting of arguments from the executable at a space might have been incorrect, 25392 # since paths with space are more likely in Windows. Give it another try with the whole 25393 # argument. 25394 path="$complete" 25395 arguments="EOL" 25396 new_path=`$CYGPATH -u "$path"` 25397 new_path=`$WHICH "$new_path" 2> /dev/null` 25398 # bat and cmd files are not always considered executable in cygwin causing which 25399 # to not find them 25400 if test "x$new_path" = x \ 25401 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25402 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25403 new_path=`$CYGPATH -u "$path"` 25404 fi 25405 if test "x$new_path" = x; then 25406 # It's still not found. Now this is an unrecoverable error. 25407 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25408 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25409 has_space=`$ECHO "$complete" | $GREP " "` 25410 if test "x$has_space" != x; then 25411 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25412 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25413 fi 25414 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25415 fi 25416 fi 25417 25418 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25419 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25420 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25421 # "foo.exe" is OK but "foo" is an error. 25422 # 25423 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25424 # It is also a way to make sure we got the proper file name for the real test later on. 25425 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25426 if test "x$test_shortpath" = x; then 25427 # Short path failed, file does not exist as specified. 25428 # Try adding .exe or .cmd 25429 if test -f "${new_path}.exe"; then 25430 input_to_shortpath="${new_path}.exe" 25431 elif test -f "${new_path}.cmd"; then 25432 input_to_shortpath="${new_path}.cmd" 25433 else 25434 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 25435 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 25436 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25437 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25438 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25439 fi 25440 else 25441 input_to_shortpath="$new_path" 25442 fi 25443 25444 # Call helper function which possibly converts this using DOS-style short mode. 25445 # If so, the updated path is stored in $new_path. 25446 new_path="$input_to_shortpath" 25447 25448 input_path="$input_to_shortpath" 25449 # Check if we need to convert this using DOS-style short mode. If the path 25450 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25451 # take no chances and rewrite it. 25452 # Note: m4 eats our [], so we need to use [ and ] instead. 25453 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25454 if test "x$has_forbidden_chars" != x; then 25455 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25456 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25457 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25458 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25459 # Going to short mode and back again did indeed matter. Since short mode is 25460 # case insensitive, let's make it lowercase to improve readability. 25461 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25462 # Now convert it back to Unix-stile (cygpath) 25463 input_path=`$CYGPATH -u "$shortmode_path"` 25464 new_path="$input_path" 25465 fi 25466 fi 25467 25468 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25469 if test "x$test_cygdrive_prefix" = x; then 25470 # As a simple fix, exclude /usr/bin since it's not a real path. 25471 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25472 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25473 # a path prefixed by /cygdrive for fixpath to work. 25474 new_path="$CYGWIN_ROOT_PATH$input_path" 25475 fi 25476 fi 25477 25478 # remove trailing .exe if any 25479 new_path="${new_path/%.exe/}" 25480 25481 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25482 25483 # First separate the path from the arguments. This will split at the first 25484 # space. 25485 complete="$AS" 25486 path="${complete%% *}" 25487 tmp="$complete EOL" 25488 arguments="${tmp#* }" 25489 25490 # Input might be given as Windows format, start by converting to 25491 # unix format. 25492 new_path="$path" 25493 25494 windows_path="$new_path" 25495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25496 unix_path=`$CYGPATH -u "$windows_path"` 25497 new_path="$unix_path" 25498 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25499 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25500 new_path="$unix_path" 25501 fi 25502 25503 25504 # Now try to locate executable using which 25505 new_path=`$WHICH "$new_path" 2> /dev/null` 25506 25507 if test "x$new_path" = x; then 25508 # Oops. Which didn't find the executable. 25509 # The splitting of arguments from the executable at a space might have been incorrect, 25510 # since paths with space are more likely in Windows. Give it another try with the whole 25511 # argument. 25512 path="$complete" 25513 arguments="EOL" 25514 new_path="$path" 25515 25516 windows_path="$new_path" 25517 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25518 unix_path=`$CYGPATH -u "$windows_path"` 25519 new_path="$unix_path" 25520 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25521 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25522 new_path="$unix_path" 25523 fi 25524 25525 25526 new_path=`$WHICH "$new_path" 2> /dev/null` 25527 25528 if test "x$new_path" = x; then 25529 # It's still not found. Now this is an unrecoverable error. 25530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25531 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25532 has_space=`$ECHO "$complete" | $GREP " "` 25533 if test "x$has_space" != x; then 25534 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25535 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25536 fi 25537 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25538 fi 25539 fi 25540 25541 # Now new_path has a complete unix path to the binary 25542 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 25543 # Keep paths in /bin as-is, but remove trailing .exe if any 25544 new_path="${new_path/%.exe/}" 25545 # Do not save /bin paths to all_fixpath_prefixes! 25546 else 25547 # Not in mixed or Windows style, start by that. 25548 new_path=`cmd //c echo $new_path` 25549 25550 input_path="$new_path" 25551 # Check if we need to convert this using DOS-style short mode. If the path 25552 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25553 # take no chances and rewrite it. 25554 # Note: m4 eats our [], so we need to use [ and ] instead. 25555 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25556 if test "x$has_forbidden_chars" != x; then 25557 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25558 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25559 fi 25560 25561 # Output is in $new_path 25562 25563 windows_path="$new_path" 25564 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25565 unix_path=`$CYGPATH -u "$windows_path"` 25566 new_path="$unix_path" 25567 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25568 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25569 new_path="$unix_path" 25570 fi 25571 25572 # remove trailing .exe if any 25573 new_path="${new_path/%.exe/}" 25574 25575 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25576 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25577 fi 25578 25579 else 25580 # We're on a posix platform. Hooray! :) 25581 # First separate the path from the arguments. This will split at the first 25582 # space. 25583 complete="$AS" 25584 path="${complete%% *}" 25585 tmp="$complete EOL" 25586 arguments="${tmp#* }" 25587 25588 # Cannot rely on the command "which" here since it doesn't always work. 25589 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25590 if test -z "$is_absolute_path"; then 25591 # Path to executable is not absolute. Find it. 25592 IFS_save="$IFS" 25593 IFS=: 25594 for p in $PATH; do 25595 if test -f "$p/$path" && test -x "$p/$path"; then 25596 new_path="$p/$path" 25597 break 25598 fi 25599 done 25600 IFS="$IFS_save" 25601 else 25602 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AS (as $path) failed, using $path directly." >&5 25603 $as_echo "$as_me: Resolving AS (as $path) failed, using $path directly." >&6;} 25604 new_path="$path" 25605 fi 25606 25607 if test "x$new_path" = x; then 25608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 25609 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 25610 has_space=`$ECHO "$complete" | $GREP " "` 25611 if test "x$has_space" != x; then 25612 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25613 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25614 fi 25615 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 25616 fi 25617 fi 25618 25619 # Now join together the path and the arguments once again 25620 if test "x$arguments" != xEOL; then 25621 new_complete="$new_path ${arguments% *}" 25622 else 25623 new_complete="$new_path" 25624 fi 25625 25626 if test "x$complete" != "x$new_complete"; then 25627 AS="$new_complete" 25628 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 25629 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 25630 fi 25631 25632 else 25633 # Enforce preprocessing of assembler files for GCC 25634 if test "x$ac_compiler_gnu" = "xyes"; then 25635 AS="$CC -c -x assembler-with-cpp " 25636 else 25637 AS="$CC -c" 25638 fi 25639 fi 25640 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $AS as assembler" >&5 25641 $as_echo "$as_me: Using $AS as assembler" >&6;} 25642 25643 25644 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 25645 # Extract the first word of "nm", so it can be a program name with args. 25646 set dummy nm; ac_word=$2 25647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25648 $as_echo_n "checking for $ac_word... " >&6; } 25649 if ${ac_cv_path_NM+:} false; then : 25650 $as_echo_n "(cached) " >&6 25651 else 25652 case $NM in 25653 [\\/]* | ?:[\\/]*) 25654 ac_cv_path_NM="$NM" # Let the user override the test with a path. 25655 ;; 25656 *) 25657 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25658 for as_dir in $PATH 25659 do 25660 IFS=$as_save_IFS 25661 test -z "$as_dir" && as_dir=. 25662 for ac_exec_ext in '' $ac_executable_extensions; do 25663 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 25664 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 25665 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25666 break 2 25667 fi 25668 done 25669 done 25670 IFS=$as_save_IFS 25671 25672 ;; 25673 esac 25674 fi 25675 NM=$ac_cv_path_NM 25676 if test -n "$NM"; then 25677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 25678 $as_echo "$NM" >&6; } 25679 else 25680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25681 $as_echo "no" >&6; } 25682 fi 25683 25684 25685 25686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25687 25688 # First separate the path from the arguments. This will split at the first 25689 # space. 25690 complete="$NM" 25691 path="${complete%% *}" 25692 tmp="$complete EOL" 25693 arguments="${tmp#* }" 25694 25695 # Input might be given as Windows format, start by converting to 25696 # unix format. 25697 new_path=`$CYGPATH -u "$path"` 25698 25699 # Now try to locate executable using which 25700 new_path=`$WHICH "$new_path" 2> /dev/null` 25701 # bat and cmd files are not always considered executable in cygwin causing which 25702 # to not find them 25703 if test "x$new_path" = x \ 25704 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25705 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25706 new_path=`$CYGPATH -u "$path"` 25707 fi 25708 if test "x$new_path" = x; then 25709 # Oops. Which didn't find the executable. 25710 # The splitting of arguments from the executable at a space might have been incorrect, 25711 # since paths with space are more likely in Windows. Give it another try with the whole 25712 # argument. 25713 path="$complete" 25714 arguments="EOL" 25715 new_path=`$CYGPATH -u "$path"` 25716 new_path=`$WHICH "$new_path" 2> /dev/null` 25717 # bat and cmd files are not always considered executable in cygwin causing which 25718 # to not find them 25719 if test "x$new_path" = x \ 25720 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 25721 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 25722 new_path=`$CYGPATH -u "$path"` 25723 fi 25724 if test "x$new_path" = x; then 25725 # It's still not found. Now this is an unrecoverable error. 25726 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 25727 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 25728 has_space=`$ECHO "$complete" | $GREP " "` 25729 if test "x$has_space" != x; then 25730 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25731 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25732 fi 25733 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25734 fi 25735 fi 25736 25737 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25738 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25739 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25740 # "foo.exe" is OK but "foo" is an error. 25741 # 25742 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25743 # It is also a way to make sure we got the proper file name for the real test later on. 25744 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25745 if test "x$test_shortpath" = x; then 25746 # Short path failed, file does not exist as specified. 25747 # Try adding .exe or .cmd 25748 if test -f "${new_path}.exe"; then 25749 input_to_shortpath="${new_path}.exe" 25750 elif test -f "${new_path}.cmd"; then 25751 input_to_shortpath="${new_path}.cmd" 25752 else 25753 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 25754 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 25755 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 25756 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 25757 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25758 fi 25759 else 25760 input_to_shortpath="$new_path" 25761 fi 25762 25763 # Call helper function which possibly converts this using DOS-style short mode. 25764 # If so, the updated path is stored in $new_path. 25765 new_path="$input_to_shortpath" 25766 25767 input_path="$input_to_shortpath" 25768 # Check if we need to convert this using DOS-style short mode. If the path 25769 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25770 # take no chances and rewrite it. 25771 # Note: m4 eats our [], so we need to use [ and ] instead. 25772 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25773 if test "x$has_forbidden_chars" != x; then 25774 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25775 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25776 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25777 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25778 # Going to short mode and back again did indeed matter. Since short mode is 25779 # case insensitive, let's make it lowercase to improve readability. 25780 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25781 # Now convert it back to Unix-stile (cygpath) 25782 input_path=`$CYGPATH -u "$shortmode_path"` 25783 new_path="$input_path" 25784 fi 25785 fi 25786 25787 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25788 if test "x$test_cygdrive_prefix" = x; then 25789 # As a simple fix, exclude /usr/bin since it's not a real path. 25790 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 25791 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25792 # a path prefixed by /cygdrive for fixpath to work. 25793 new_path="$CYGWIN_ROOT_PATH$input_path" 25794 fi 25795 fi 25796 25797 # remove trailing .exe if any 25798 new_path="${new_path/%.exe/}" 25799 25800 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25801 25802 # First separate the path from the arguments. This will split at the first 25803 # space. 25804 complete="$NM" 25805 path="${complete%% *}" 25806 tmp="$complete EOL" 25807 arguments="${tmp#* }" 25808 25809 # Input might be given as Windows format, start by converting to 25810 # unix format. 25811 new_path="$path" 25812 25813 windows_path="$new_path" 25814 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25815 unix_path=`$CYGPATH -u "$windows_path"` 25816 new_path="$unix_path" 25817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25818 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25819 new_path="$unix_path" 25820 fi 25821 25822 25823 # Now try to locate executable using which 25824 new_path=`$WHICH "$new_path" 2> /dev/null` 25825 25826 if test "x$new_path" = x; then 25827 # Oops. Which didn't find the executable. 25828 # The splitting of arguments from the executable at a space might have been incorrect, 25829 # since paths with space are more likely in Windows. Give it another try with the whole 25830 # argument. 25831 path="$complete" 25832 arguments="EOL" 25833 new_path="$path" 25834 25835 windows_path="$new_path" 25836 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25837 unix_path=`$CYGPATH -u "$windows_path"` 25838 new_path="$unix_path" 25839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25840 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25841 new_path="$unix_path" 25842 fi 25843 25844 25845 new_path=`$WHICH "$new_path" 2> /dev/null` 25846 25847 if test "x$new_path" = x; then 25848 # It's still not found. Now this is an unrecoverable error. 25849 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 25850 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 25851 has_space=`$ECHO "$complete" | $GREP " "` 25852 if test "x$has_space" != x; then 25853 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 25854 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 25855 fi 25856 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25857 fi 25858 fi 25859 25860 # Now new_path has a complete unix path to the binary 25861 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 25862 # Keep paths in /bin as-is, but remove trailing .exe if any 25863 new_path="${new_path/%.exe/}" 25864 # Do not save /bin paths to all_fixpath_prefixes! 25865 else 25866 # Not in mixed or Windows style, start by that. 25867 new_path=`cmd //c echo $new_path` 25868 25869 input_path="$new_path" 25870 # Check if we need to convert this using DOS-style short mode. If the path 25871 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25872 # take no chances and rewrite it. 25873 # Note: m4 eats our [], so we need to use [ and ] instead. 25874 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25875 if test "x$has_forbidden_chars" != x; then 25876 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25877 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25878 fi 25879 25880 # Output is in $new_path 25881 25882 windows_path="$new_path" 25883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25884 unix_path=`$CYGPATH -u "$windows_path"` 25885 new_path="$unix_path" 25886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25888 new_path="$unix_path" 25889 fi 25890 25891 # remove trailing .exe if any 25892 new_path="${new_path/%.exe/}" 25893 25894 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25895 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25896 fi 25897 25898 else 25899 # We're on a posix platform. Hooray! :) 25900 # First separate the path from the arguments. This will split at the first 25901 # space. 25902 complete="$NM" 25903 path="${complete%% *}" 25904 tmp="$complete EOL" 25905 arguments="${tmp#* }" 25906 25907 # Cannot rely on the command "which" here since it doesn't always work. 25908 is_absolute_path=`$ECHO "$path" | $GREP ^/` 25909 if test -z "$is_absolute_path"; then 25910 # Path to executable is not absolute. Find it. 25911 IFS_save="$IFS" 25912 IFS=: 25913 for p in $PATH; do 25914 if test -f "$p/$path" && test -x "$p/$path"; then 25915 new_path="$p/$path" 25916 break 25917 fi 25918 done 25919 IFS="$IFS_save" 25920 else 25921 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5 25922 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;} 25923 new_path="$path" 25924 fi 25925 25926 if test "x$new_path" = x; then 25927 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 25928 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 25929 has_space=`$ECHO "$complete" | $GREP " "` 25930 if test "x$has_space" != x; then 25931 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 25932 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 25933 fi 25934 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 25935 fi 25936 fi 25937 25938 # Now join together the path and the arguments once again 25939 if test "x$arguments" != xEOL; then 25940 new_complete="$new_path ${arguments% *}" 25941 else 25942 new_complete="$new_path" 25943 fi 25944 25945 if test "x$complete" != "x$new_complete"; then 25946 NM="$new_complete" 25947 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 25948 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 25949 fi 25950 25951 # Extract the first word of "gnm", so it can be a program name with args. 25952 set dummy gnm; ac_word=$2 25953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25954 $as_echo_n "checking for $ac_word... " >&6; } 25955 if ${ac_cv_path_GNM+:} false; then : 25956 $as_echo_n "(cached) " >&6 25957 else 25958 case $GNM in 25959 [\\/]* | ?:[\\/]*) 25960 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 25961 ;; 25962 *) 25963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25964 for as_dir in $PATH 25965 do 25966 IFS=$as_save_IFS 25967 test -z "$as_dir" && as_dir=. 25968 for ac_exec_ext in '' $ac_executable_extensions; do 25969 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 25970 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 25971 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25972 break 2 25973 fi 25974 done 25975 done 25976 IFS=$as_save_IFS 25977 25978 ;; 25979 esac 25980 fi 25981 GNM=$ac_cv_path_GNM 25982 if test -n "$GNM"; then 25983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 25984 $as_echo "$GNM" >&6; } 25985 else 25986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25987 $as_echo "no" >&6; } 25988 fi 25989 25990 25991 25992 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25993 25994 # First separate the path from the arguments. This will split at the first 25995 # space. 25996 complete="$GNM" 25997 path="${complete%% *}" 25998 tmp="$complete EOL" 25999 arguments="${tmp#* }" 26000 26001 # Input might be given as Windows format, start by converting to 26002 # unix format. 26003 new_path=`$CYGPATH -u "$path"` 26004 26005 # Now try to locate executable using which 26006 new_path=`$WHICH "$new_path" 2> /dev/null` 26007 # bat and cmd files are not always considered executable in cygwin causing which 26008 # to not find them 26009 if test "x$new_path" = x \ 26010 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26011 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26012 new_path=`$CYGPATH -u "$path"` 26013 fi 26014 if test "x$new_path" = x; then 26015 # Oops. Which didn't find the executable. 26016 # The splitting of arguments from the executable at a space might have been incorrect, 26017 # since paths with space are more likely in Windows. Give it another try with the whole 26018 # argument. 26019 path="$complete" 26020 arguments="EOL" 26021 new_path=`$CYGPATH -u "$path"` 26022 new_path=`$WHICH "$new_path" 2> /dev/null` 26023 # bat and cmd files are not always considered executable in cygwin causing which 26024 # to not find them 26025 if test "x$new_path" = x \ 26026 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26027 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26028 new_path=`$CYGPATH -u "$path"` 26029 fi 26030 if test "x$new_path" = x; then 26031 # It's still not found. Now this is an unrecoverable error. 26032 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26033 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26034 has_space=`$ECHO "$complete" | $GREP " "` 26035 if test "x$has_space" != x; then 26036 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26037 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26038 fi 26039 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26040 fi 26041 fi 26042 26043 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26044 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26045 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26046 # "foo.exe" is OK but "foo" is an error. 26047 # 26048 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26049 # It is also a way to make sure we got the proper file name for the real test later on. 26050 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26051 if test "x$test_shortpath" = x; then 26052 # Short path failed, file does not exist as specified. 26053 # Try adding .exe or .cmd 26054 if test -f "${new_path}.exe"; then 26055 input_to_shortpath="${new_path}.exe" 26056 elif test -f "${new_path}.cmd"; then 26057 input_to_shortpath="${new_path}.cmd" 26058 else 26059 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 26060 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 26061 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26062 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26063 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26064 fi 26065 else 26066 input_to_shortpath="$new_path" 26067 fi 26068 26069 # Call helper function which possibly converts this using DOS-style short mode. 26070 # If so, the updated path is stored in $new_path. 26071 new_path="$input_to_shortpath" 26072 26073 input_path="$input_to_shortpath" 26074 # Check if we need to convert this using DOS-style short mode. If the path 26075 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26076 # take no chances and rewrite it. 26077 # Note: m4 eats our [], so we need to use [ and ] instead. 26078 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26079 if test "x$has_forbidden_chars" != x; then 26080 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26081 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26082 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26083 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26084 # Going to short mode and back again did indeed matter. Since short mode is 26085 # case insensitive, let's make it lowercase to improve readability. 26086 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26087 # Now convert it back to Unix-stile (cygpath) 26088 input_path=`$CYGPATH -u "$shortmode_path"` 26089 new_path="$input_path" 26090 fi 26091 fi 26092 26093 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26094 if test "x$test_cygdrive_prefix" = x; then 26095 # As a simple fix, exclude /usr/bin since it's not a real path. 26096 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26097 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26098 # a path prefixed by /cygdrive for fixpath to work. 26099 new_path="$CYGWIN_ROOT_PATH$input_path" 26100 fi 26101 fi 26102 26103 # remove trailing .exe if any 26104 new_path="${new_path/%.exe/}" 26105 26106 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26107 26108 # First separate the path from the arguments. This will split at the first 26109 # space. 26110 complete="$GNM" 26111 path="${complete%% *}" 26112 tmp="$complete EOL" 26113 arguments="${tmp#* }" 26114 26115 # Input might be given as Windows format, start by converting to 26116 # unix format. 26117 new_path="$path" 26118 26119 windows_path="$new_path" 26120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26121 unix_path=`$CYGPATH -u "$windows_path"` 26122 new_path="$unix_path" 26123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26125 new_path="$unix_path" 26126 fi 26127 26128 26129 # Now try to locate executable using which 26130 new_path=`$WHICH "$new_path" 2> /dev/null` 26131 26132 if test "x$new_path" = x; then 26133 # Oops. Which didn't find the executable. 26134 # The splitting of arguments from the executable at a space might have been incorrect, 26135 # since paths with space are more likely in Windows. Give it another try with the whole 26136 # argument. 26137 path="$complete" 26138 arguments="EOL" 26139 new_path="$path" 26140 26141 windows_path="$new_path" 26142 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26143 unix_path=`$CYGPATH -u "$windows_path"` 26144 new_path="$unix_path" 26145 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26146 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26147 new_path="$unix_path" 26148 fi 26149 26150 26151 new_path=`$WHICH "$new_path" 2> /dev/null` 26152 26153 if test "x$new_path" = x; then 26154 # It's still not found. Now this is an unrecoverable error. 26155 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26156 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26157 has_space=`$ECHO "$complete" | $GREP " "` 26158 if test "x$has_space" != x; then 26159 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26160 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26161 fi 26162 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26163 fi 26164 fi 26165 26166 # Now new_path has a complete unix path to the binary 26167 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26168 # Keep paths in /bin as-is, but remove trailing .exe if any 26169 new_path="${new_path/%.exe/}" 26170 # Do not save /bin paths to all_fixpath_prefixes! 26171 else 26172 # Not in mixed or Windows style, start by that. 26173 new_path=`cmd //c echo $new_path` 26174 26175 input_path="$new_path" 26176 # Check if we need to convert this using DOS-style short mode. If the path 26177 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26178 # take no chances and rewrite it. 26179 # Note: m4 eats our [], so we need to use [ and ] instead. 26180 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26181 if test "x$has_forbidden_chars" != x; then 26182 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26183 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26184 fi 26185 26186 # Output is in $new_path 26187 26188 windows_path="$new_path" 26189 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26190 unix_path=`$CYGPATH -u "$windows_path"` 26191 new_path="$unix_path" 26192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26193 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26194 new_path="$unix_path" 26195 fi 26196 26197 # remove trailing .exe if any 26198 new_path="${new_path/%.exe/}" 26199 26200 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26201 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26202 fi 26203 26204 else 26205 # We're on a posix platform. Hooray! :) 26206 # First separate the path from the arguments. This will split at the first 26207 # space. 26208 complete="$GNM" 26209 path="${complete%% *}" 26210 tmp="$complete EOL" 26211 arguments="${tmp#* }" 26212 26213 # Cannot rely on the command "which" here since it doesn't always work. 26214 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26215 if test -z "$is_absolute_path"; then 26216 # Path to executable is not absolute. Find it. 26217 IFS_save="$IFS" 26218 IFS=: 26219 for p in $PATH; do 26220 if test -f "$p/$path" && test -x "$p/$path"; then 26221 new_path="$p/$path" 26222 break 26223 fi 26224 done 26225 IFS="$IFS_save" 26226 else 26227 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving GNM (as $path) failed, using $path directly." >&5 26228 $as_echo "$as_me: Resolving GNM (as $path) failed, using $path directly." >&6;} 26229 new_path="$path" 26230 fi 26231 26232 if test "x$new_path" = x; then 26233 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 26234 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 26235 has_space=`$ECHO "$complete" | $GREP " "` 26236 if test "x$has_space" != x; then 26237 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26238 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26239 fi 26240 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 26241 fi 26242 fi 26243 26244 # Now join together the path and the arguments once again 26245 if test "x$arguments" != xEOL; then 26246 new_complete="$new_path ${arguments% *}" 26247 else 26248 new_complete="$new_path" 26249 fi 26250 26251 if test "x$complete" != "x$new_complete"; then 26252 GNM="$new_complete" 26253 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 26254 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 26255 fi 26256 26257 # Extract the first word of "strip", so it can be a program name with args. 26258 set dummy strip; ac_word=$2 26259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26260 $as_echo_n "checking for $ac_word... " >&6; } 26261 if ${ac_cv_path_STRIP+:} false; then : 26262 $as_echo_n "(cached) " >&6 26263 else 26264 case $STRIP in 26265 [\\/]* | ?:[\\/]*) 26266 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 26267 ;; 26268 *) 26269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26270 for as_dir in $PATH 26271 do 26272 IFS=$as_save_IFS 26273 test -z "$as_dir" && as_dir=. 26274 for ac_exec_ext in '' $ac_executable_extensions; do 26275 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26276 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 26277 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26278 break 2 26279 fi 26280 done 26281 done 26282 IFS=$as_save_IFS 26283 26284 ;; 26285 esac 26286 fi 26287 STRIP=$ac_cv_path_STRIP 26288 if test -n "$STRIP"; then 26289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 26290 $as_echo "$STRIP" >&6; } 26291 else 26292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26293 $as_echo "no" >&6; } 26294 fi 26295 26296 26297 26298 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26299 26300 # First separate the path from the arguments. This will split at the first 26301 # space. 26302 complete="$STRIP" 26303 path="${complete%% *}" 26304 tmp="$complete EOL" 26305 arguments="${tmp#* }" 26306 26307 # Input might be given as Windows format, start by converting to 26308 # unix format. 26309 new_path=`$CYGPATH -u "$path"` 26310 26311 # Now try to locate executable using which 26312 new_path=`$WHICH "$new_path" 2> /dev/null` 26313 # bat and cmd files are not always considered executable in cygwin causing which 26314 # to not find them 26315 if test "x$new_path" = x \ 26316 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26317 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26318 new_path=`$CYGPATH -u "$path"` 26319 fi 26320 if test "x$new_path" = x; then 26321 # Oops. Which didn't find the executable. 26322 # The splitting of arguments from the executable at a space might have been incorrect, 26323 # since paths with space are more likely in Windows. Give it another try with the whole 26324 # argument. 26325 path="$complete" 26326 arguments="EOL" 26327 new_path=`$CYGPATH -u "$path"` 26328 new_path=`$WHICH "$new_path" 2> /dev/null` 26329 # bat and cmd files are not always considered executable in cygwin causing which 26330 # to not find them 26331 if test "x$new_path" = x \ 26332 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26333 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26334 new_path=`$CYGPATH -u "$path"` 26335 fi 26336 if test "x$new_path" = x; then 26337 # It's still not found. Now this is an unrecoverable error. 26338 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26339 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26340 has_space=`$ECHO "$complete" | $GREP " "` 26341 if test "x$has_space" != x; then 26342 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26343 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26344 fi 26345 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26346 fi 26347 fi 26348 26349 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26350 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26351 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26352 # "foo.exe" is OK but "foo" is an error. 26353 # 26354 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26355 # It is also a way to make sure we got the proper file name for the real test later on. 26356 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26357 if test "x$test_shortpath" = x; then 26358 # Short path failed, file does not exist as specified. 26359 # Try adding .exe or .cmd 26360 if test -f "${new_path}.exe"; then 26361 input_to_shortpath="${new_path}.exe" 26362 elif test -f "${new_path}.cmd"; then 26363 input_to_shortpath="${new_path}.cmd" 26364 else 26365 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 26366 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 26367 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26368 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26369 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26370 fi 26371 else 26372 input_to_shortpath="$new_path" 26373 fi 26374 26375 # Call helper function which possibly converts this using DOS-style short mode. 26376 # If so, the updated path is stored in $new_path. 26377 new_path="$input_to_shortpath" 26378 26379 input_path="$input_to_shortpath" 26380 # Check if we need to convert this using DOS-style short mode. If the path 26381 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26382 # take no chances and rewrite it. 26383 # Note: m4 eats our [], so we need to use [ and ] instead. 26384 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26385 if test "x$has_forbidden_chars" != x; then 26386 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26387 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26388 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26389 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26390 # Going to short mode and back again did indeed matter. Since short mode is 26391 # case insensitive, let's make it lowercase to improve readability. 26392 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26393 # Now convert it back to Unix-stile (cygpath) 26394 input_path=`$CYGPATH -u "$shortmode_path"` 26395 new_path="$input_path" 26396 fi 26397 fi 26398 26399 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26400 if test "x$test_cygdrive_prefix" = x; then 26401 # As a simple fix, exclude /usr/bin since it's not a real path. 26402 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26403 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26404 # a path prefixed by /cygdrive for fixpath to work. 26405 new_path="$CYGWIN_ROOT_PATH$input_path" 26406 fi 26407 fi 26408 26409 # remove trailing .exe if any 26410 new_path="${new_path/%.exe/}" 26411 26412 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26413 26414 # First separate the path from the arguments. This will split at the first 26415 # space. 26416 complete="$STRIP" 26417 path="${complete%% *}" 26418 tmp="$complete EOL" 26419 arguments="${tmp#* }" 26420 26421 # Input might be given as Windows format, start by converting to 26422 # unix format. 26423 new_path="$path" 26424 26425 windows_path="$new_path" 26426 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26427 unix_path=`$CYGPATH -u "$windows_path"` 26428 new_path="$unix_path" 26429 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26430 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26431 new_path="$unix_path" 26432 fi 26433 26434 26435 # Now try to locate executable using which 26436 new_path=`$WHICH "$new_path" 2> /dev/null` 26437 26438 if test "x$new_path" = x; then 26439 # Oops. Which didn't find the executable. 26440 # The splitting of arguments from the executable at a space might have been incorrect, 26441 # since paths with space are more likely in Windows. Give it another try with the whole 26442 # argument. 26443 path="$complete" 26444 arguments="EOL" 26445 new_path="$path" 26446 26447 windows_path="$new_path" 26448 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26449 unix_path=`$CYGPATH -u "$windows_path"` 26450 new_path="$unix_path" 26451 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26452 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26453 new_path="$unix_path" 26454 fi 26455 26456 26457 new_path=`$WHICH "$new_path" 2> /dev/null` 26458 26459 if test "x$new_path" = x; then 26460 # It's still not found. Now this is an unrecoverable error. 26461 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26462 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26463 has_space=`$ECHO "$complete" | $GREP " "` 26464 if test "x$has_space" != x; then 26465 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26466 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26467 fi 26468 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26469 fi 26470 fi 26471 26472 # Now new_path has a complete unix path to the binary 26473 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26474 # Keep paths in /bin as-is, but remove trailing .exe if any 26475 new_path="${new_path/%.exe/}" 26476 # Do not save /bin paths to all_fixpath_prefixes! 26477 else 26478 # Not in mixed or Windows style, start by that. 26479 new_path=`cmd //c echo $new_path` 26480 26481 input_path="$new_path" 26482 # Check if we need to convert this using DOS-style short mode. If the path 26483 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26484 # take no chances and rewrite it. 26485 # Note: m4 eats our [], so we need to use [ and ] instead. 26486 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26487 if test "x$has_forbidden_chars" != x; then 26488 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26489 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26490 fi 26491 26492 # Output is in $new_path 26493 26494 windows_path="$new_path" 26495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26496 unix_path=`$CYGPATH -u "$windows_path"` 26497 new_path="$unix_path" 26498 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26499 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26500 new_path="$unix_path" 26501 fi 26502 26503 # remove trailing .exe if any 26504 new_path="${new_path/%.exe/}" 26505 26506 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26507 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26508 fi 26509 26510 else 26511 # We're on a posix platform. Hooray! :) 26512 # First separate the path from the arguments. This will split at the first 26513 # space. 26514 complete="$STRIP" 26515 path="${complete%% *}" 26516 tmp="$complete EOL" 26517 arguments="${tmp#* }" 26518 26519 # Cannot rely on the command "which" here since it doesn't always work. 26520 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26521 if test -z "$is_absolute_path"; then 26522 # Path to executable is not absolute. Find it. 26523 IFS_save="$IFS" 26524 IFS=: 26525 for p in $PATH; do 26526 if test -f "$p/$path" && test -x "$p/$path"; then 26527 new_path="$p/$path" 26528 break 26529 fi 26530 done 26531 IFS="$IFS_save" 26532 else 26533 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5 26534 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;} 26535 new_path="$path" 26536 fi 26537 26538 if test "x$new_path" = x; then 26539 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 26540 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 26541 has_space=`$ECHO "$complete" | $GREP " "` 26542 if test "x$has_space" != x; then 26543 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26544 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26545 fi 26546 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 26547 fi 26548 fi 26549 26550 # Now join together the path and the arguments once again 26551 if test "x$arguments" != xEOL; then 26552 new_complete="$new_path ${arguments% *}" 26553 else 26554 new_complete="$new_path" 26555 fi 26556 26557 if test "x$complete" != "x$new_complete"; then 26558 STRIP="$new_complete" 26559 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 26560 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 26561 fi 26562 26563 # Extract the first word of "mcs", so it can be a program name with args. 26564 set dummy mcs; ac_word=$2 26565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26566 $as_echo_n "checking for $ac_word... " >&6; } 26567 if ${ac_cv_path_MCS+:} false; then : 26568 $as_echo_n "(cached) " >&6 26569 else 26570 case $MCS in 26571 [\\/]* | ?:[\\/]*) 26572 ac_cv_path_MCS="$MCS" # Let the user override the test with a path. 26573 ;; 26574 *) 26575 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26576 for as_dir in $PATH 26577 do 26578 IFS=$as_save_IFS 26579 test -z "$as_dir" && as_dir=. 26580 for ac_exec_ext in '' $ac_executable_extensions; do 26581 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26582 ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext" 26583 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26584 break 2 26585 fi 26586 done 26587 done 26588 IFS=$as_save_IFS 26589 26590 ;; 26591 esac 26592 fi 26593 MCS=$ac_cv_path_MCS 26594 if test -n "$MCS"; then 26595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5 26596 $as_echo "$MCS" >&6; } 26597 else 26598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26599 $as_echo "no" >&6; } 26600 fi 26601 26602 26603 26604 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26605 26606 # First separate the path from the arguments. This will split at the first 26607 # space. 26608 complete="$MCS" 26609 path="${complete%% *}" 26610 tmp="$complete EOL" 26611 arguments="${tmp#* }" 26612 26613 # Input might be given as Windows format, start by converting to 26614 # unix format. 26615 new_path=`$CYGPATH -u "$path"` 26616 26617 # Now try to locate executable using which 26618 new_path=`$WHICH "$new_path" 2> /dev/null` 26619 # bat and cmd files are not always considered executable in cygwin causing which 26620 # to not find them 26621 if test "x$new_path" = x \ 26622 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26623 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26624 new_path=`$CYGPATH -u "$path"` 26625 fi 26626 if test "x$new_path" = x; then 26627 # Oops. Which didn't find the executable. 26628 # The splitting of arguments from the executable at a space might have been incorrect, 26629 # since paths with space are more likely in Windows. Give it another try with the whole 26630 # argument. 26631 path="$complete" 26632 arguments="EOL" 26633 new_path=`$CYGPATH -u "$path"` 26634 new_path=`$WHICH "$new_path" 2> /dev/null` 26635 # bat and cmd files are not always considered executable in cygwin causing which 26636 # to not find them 26637 if test "x$new_path" = x \ 26638 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26639 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26640 new_path=`$CYGPATH -u "$path"` 26641 fi 26642 if test "x$new_path" = x; then 26643 # It's still not found. Now this is an unrecoverable error. 26644 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26645 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26646 has_space=`$ECHO "$complete" | $GREP " "` 26647 if test "x$has_space" != x; then 26648 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26649 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26650 fi 26651 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26652 fi 26653 fi 26654 26655 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26656 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26657 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26658 # "foo.exe" is OK but "foo" is an error. 26659 # 26660 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26661 # It is also a way to make sure we got the proper file name for the real test later on. 26662 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26663 if test "x$test_shortpath" = x; then 26664 # Short path failed, file does not exist as specified. 26665 # Try adding .exe or .cmd 26666 if test -f "${new_path}.exe"; then 26667 input_to_shortpath="${new_path}.exe" 26668 elif test -f "${new_path}.cmd"; then 26669 input_to_shortpath="${new_path}.cmd" 26670 else 26671 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5 26672 $as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;} 26673 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 26674 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 26675 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26676 fi 26677 else 26678 input_to_shortpath="$new_path" 26679 fi 26680 26681 # Call helper function which possibly converts this using DOS-style short mode. 26682 # If so, the updated path is stored in $new_path. 26683 new_path="$input_to_shortpath" 26684 26685 input_path="$input_to_shortpath" 26686 # Check if we need to convert this using DOS-style short mode. If the path 26687 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26688 # take no chances and rewrite it. 26689 # Note: m4 eats our [], so we need to use [ and ] instead. 26690 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26691 if test "x$has_forbidden_chars" != x; then 26692 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26693 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26694 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26695 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26696 # Going to short mode and back again did indeed matter. Since short mode is 26697 # case insensitive, let's make it lowercase to improve readability. 26698 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26699 # Now convert it back to Unix-stile (cygpath) 26700 input_path=`$CYGPATH -u "$shortmode_path"` 26701 new_path="$input_path" 26702 fi 26703 fi 26704 26705 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26706 if test "x$test_cygdrive_prefix" = x; then 26707 # As a simple fix, exclude /usr/bin since it's not a real path. 26708 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 26709 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26710 # a path prefixed by /cygdrive for fixpath to work. 26711 new_path="$CYGWIN_ROOT_PATH$input_path" 26712 fi 26713 fi 26714 26715 # remove trailing .exe if any 26716 new_path="${new_path/%.exe/}" 26717 26718 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26719 26720 # First separate the path from the arguments. This will split at the first 26721 # space. 26722 complete="$MCS" 26723 path="${complete%% *}" 26724 tmp="$complete EOL" 26725 arguments="${tmp#* }" 26726 26727 # Input might be given as Windows format, start by converting to 26728 # unix format. 26729 new_path="$path" 26730 26731 windows_path="$new_path" 26732 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26733 unix_path=`$CYGPATH -u "$windows_path"` 26734 new_path="$unix_path" 26735 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26736 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26737 new_path="$unix_path" 26738 fi 26739 26740 26741 # Now try to locate executable using which 26742 new_path=`$WHICH "$new_path" 2> /dev/null` 26743 26744 if test "x$new_path" = x; then 26745 # Oops. Which didn't find the executable. 26746 # The splitting of arguments from the executable at a space might have been incorrect, 26747 # since paths with space are more likely in Windows. Give it another try with the whole 26748 # argument. 26749 path="$complete" 26750 arguments="EOL" 26751 new_path="$path" 26752 26753 windows_path="$new_path" 26754 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26755 unix_path=`$CYGPATH -u "$windows_path"` 26756 new_path="$unix_path" 26757 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26758 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26759 new_path="$unix_path" 26760 fi 26761 26762 26763 new_path=`$WHICH "$new_path" 2> /dev/null` 26764 26765 if test "x$new_path" = x; then 26766 # It's still not found. Now this is an unrecoverable error. 26767 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26768 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26769 has_space=`$ECHO "$complete" | $GREP " "` 26770 if test "x$has_space" != x; then 26771 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 26772 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 26773 fi 26774 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26775 fi 26776 fi 26777 26778 # Now new_path has a complete unix path to the binary 26779 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 26780 # Keep paths in /bin as-is, but remove trailing .exe if any 26781 new_path="${new_path/%.exe/}" 26782 # Do not save /bin paths to all_fixpath_prefixes! 26783 else 26784 # Not in mixed or Windows style, start by that. 26785 new_path=`cmd //c echo $new_path` 26786 26787 input_path="$new_path" 26788 # Check if we need to convert this using DOS-style short mode. If the path 26789 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26790 # take no chances and rewrite it. 26791 # Note: m4 eats our [], so we need to use [ and ] instead. 26792 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26793 if test "x$has_forbidden_chars" != x; then 26794 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26795 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26796 fi 26797 26798 # Output is in $new_path 26799 26800 windows_path="$new_path" 26801 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26802 unix_path=`$CYGPATH -u "$windows_path"` 26803 new_path="$unix_path" 26804 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26805 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26806 new_path="$unix_path" 26807 fi 26808 26809 # remove trailing .exe if any 26810 new_path="${new_path/%.exe/}" 26811 26812 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26813 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26814 fi 26815 26816 else 26817 # We're on a posix platform. Hooray! :) 26818 # First separate the path from the arguments. This will split at the first 26819 # space. 26820 complete="$MCS" 26821 path="${complete%% *}" 26822 tmp="$complete EOL" 26823 arguments="${tmp#* }" 26824 26825 # Cannot rely on the command "which" here since it doesn't always work. 26826 is_absolute_path=`$ECHO "$path" | $GREP ^/` 26827 if test -z "$is_absolute_path"; then 26828 # Path to executable is not absolute. Find it. 26829 IFS_save="$IFS" 26830 IFS=: 26831 for p in $PATH; do 26832 if test -f "$p/$path" && test -x "$p/$path"; then 26833 new_path="$p/$path" 26834 break 26835 fi 26836 done 26837 IFS="$IFS_save" 26838 else 26839 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MCS (as $path) failed, using $path directly." >&5 26840 $as_echo "$as_me: Resolving MCS (as $path) failed, using $path directly." >&6;} 26841 new_path="$path" 26842 fi 26843 26844 if test "x$new_path" = x; then 26845 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5 26846 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;} 26847 has_space=`$ECHO "$complete" | $GREP " "` 26848 if test "x$has_space" != x; then 26849 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 26850 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 26851 fi 26852 as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5 26853 fi 26854 fi 26855 26856 # Now join together the path and the arguments once again 26857 if test "x$arguments" != xEOL; then 26858 new_complete="$new_path ${arguments% *}" 26859 else 26860 new_complete="$new_path" 26861 fi 26862 26863 if test "x$complete" != "x$new_complete"; then 26864 MCS="$new_complete" 26865 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5 26866 $as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;} 26867 fi 26868 26869 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 26870 if test -n "$ac_tool_prefix"; then 26871 # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args. 26872 set dummy ${ac_tool_prefix}nm; ac_word=$2 26873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26874 $as_echo_n "checking for $ac_word... " >&6; } 26875 if ${ac_cv_prog_NM+:} false; then : 26876 $as_echo_n "(cached) " >&6 26877 else 26878 if test -n "$NM"; then 26879 ac_cv_prog_NM="$NM" # Let the user override the test. 26880 else 26881 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26882 for as_dir in $PATH 26883 do 26884 IFS=$as_save_IFS 26885 test -z "$as_dir" && as_dir=. 26886 for ac_exec_ext in '' $ac_executable_extensions; do 26887 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26888 ac_cv_prog_NM="${ac_tool_prefix}nm" 26889 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26890 break 2 26891 fi 26892 done 26893 done 26894 IFS=$as_save_IFS 26895 26896 fi 26897 fi 26898 NM=$ac_cv_prog_NM 26899 if test -n "$NM"; then 26900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 26901 $as_echo "$NM" >&6; } 26902 else 26903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26904 $as_echo "no" >&6; } 26905 fi 26906 26907 26908 fi 26909 if test -z "$ac_cv_prog_NM"; then 26910 ac_ct_NM=$NM 26911 # Extract the first word of "nm", so it can be a program name with args. 26912 set dummy nm; ac_word=$2 26913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26914 $as_echo_n "checking for $ac_word... " >&6; } 26915 if ${ac_cv_prog_ac_ct_NM+:} false; then : 26916 $as_echo_n "(cached) " >&6 26917 else 26918 if test -n "$ac_ct_NM"; then 26919 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 26920 else 26921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26922 for as_dir in $PATH 26923 do 26924 IFS=$as_save_IFS 26925 test -z "$as_dir" && as_dir=. 26926 for ac_exec_ext in '' $ac_executable_extensions; do 26927 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 26928 ac_cv_prog_ac_ct_NM="nm" 26929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26930 break 2 26931 fi 26932 done 26933 done 26934 IFS=$as_save_IFS 26935 26936 fi 26937 fi 26938 ac_ct_NM=$ac_cv_prog_ac_ct_NM 26939 if test -n "$ac_ct_NM"; then 26940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 26941 $as_echo "$ac_ct_NM" >&6; } 26942 else 26943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26944 $as_echo "no" >&6; } 26945 fi 26946 26947 if test "x$ac_ct_NM" = x; then 26948 NM="" 26949 else 26950 case $cross_compiling:$ac_tool_warned in 26951 yes:) 26952 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 26953 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 26954 ac_tool_warned=yes ;; 26955 esac 26956 NM=$ac_ct_NM 26957 fi 26958 else 26959 NM="$ac_cv_prog_NM" 26960 fi 26961 26962 26963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26964 26965 # First separate the path from the arguments. This will split at the first 26966 # space. 26967 complete="$NM" 26968 path="${complete%% *}" 26969 tmp="$complete EOL" 26970 arguments="${tmp#* }" 26971 26972 # Input might be given as Windows format, start by converting to 26973 # unix format. 26974 new_path=`$CYGPATH -u "$path"` 26975 26976 # Now try to locate executable using which 26977 new_path=`$WHICH "$new_path" 2> /dev/null` 26978 # bat and cmd files are not always considered executable in cygwin causing which 26979 # to not find them 26980 if test "x$new_path" = x \ 26981 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26982 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26983 new_path=`$CYGPATH -u "$path"` 26984 fi 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=`$CYGPATH -u "$path"` 26993 new_path=`$WHICH "$new_path" 2> /dev/null` 26994 # bat and cmd files are not always considered executable in cygwin causing which 26995 # to not find them 26996 if test "x$new_path" = x \ 26997 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 26998 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 26999 new_path=`$CYGPATH -u "$path"` 27000 fi 27001 if test "x$new_path" = x; then 27002 # It's still not found. Now this is an unrecoverable error. 27003 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27004 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27005 has_space=`$ECHO "$complete" | $GREP " "` 27006 if test "x$has_space" != x; then 27007 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27008 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27009 fi 27010 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27011 fi 27012 fi 27013 27014 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27015 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27016 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27017 # "foo.exe" is OK but "foo" is an error. 27018 # 27019 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27020 # It is also a way to make sure we got the proper file name for the real test later on. 27021 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27022 if test "x$test_shortpath" = x; then 27023 # Short path failed, file does not exist as specified. 27024 # Try adding .exe or .cmd 27025 if test -f "${new_path}.exe"; then 27026 input_to_shortpath="${new_path}.exe" 27027 elif test -f "${new_path}.cmd"; then 27028 input_to_shortpath="${new_path}.cmd" 27029 else 27030 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 27031 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 27032 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27033 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27034 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27035 fi 27036 else 27037 input_to_shortpath="$new_path" 27038 fi 27039 27040 # Call helper function which possibly converts this using DOS-style short mode. 27041 # If so, the updated path is stored in $new_path. 27042 new_path="$input_to_shortpath" 27043 27044 input_path="$input_to_shortpath" 27045 # Check if we need to convert this using DOS-style short mode. If the path 27046 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27047 # take no chances and rewrite it. 27048 # Note: m4 eats our [], so we need to use [ and ] instead. 27049 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27050 if test "x$has_forbidden_chars" != x; then 27051 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27052 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27053 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27054 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27055 # Going to short mode and back again did indeed matter. Since short mode is 27056 # case insensitive, let's make it lowercase to improve readability. 27057 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27058 # Now convert it back to Unix-stile (cygpath) 27059 input_path=`$CYGPATH -u "$shortmode_path"` 27060 new_path="$input_path" 27061 fi 27062 fi 27063 27064 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27065 if test "x$test_cygdrive_prefix" = x; then 27066 # As a simple fix, exclude /usr/bin since it's not a real path. 27067 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27068 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27069 # a path prefixed by /cygdrive for fixpath to work. 27070 new_path="$CYGWIN_ROOT_PATH$input_path" 27071 fi 27072 fi 27073 27074 # remove trailing .exe if any 27075 new_path="${new_path/%.exe/}" 27076 27077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27078 27079 # First separate the path from the arguments. This will split at the first 27080 # space. 27081 complete="$NM" 27082 path="${complete%% *}" 27083 tmp="$complete EOL" 27084 arguments="${tmp#* }" 27085 27086 # Input might be given as Windows format, start by converting to 27087 # unix format. 27088 new_path="$path" 27089 27090 windows_path="$new_path" 27091 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27092 unix_path=`$CYGPATH -u "$windows_path"` 27093 new_path="$unix_path" 27094 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27095 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27096 new_path="$unix_path" 27097 fi 27098 27099 27100 # Now try to locate executable using which 27101 new_path=`$WHICH "$new_path" 2> /dev/null` 27102 27103 if test "x$new_path" = x; then 27104 # Oops. Which didn't find the executable. 27105 # The splitting of arguments from the executable at a space might have been incorrect, 27106 # since paths with space are more likely in Windows. Give it another try with the whole 27107 # argument. 27108 path="$complete" 27109 arguments="EOL" 27110 new_path="$path" 27111 27112 windows_path="$new_path" 27113 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27114 unix_path=`$CYGPATH -u "$windows_path"` 27115 new_path="$unix_path" 27116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27117 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27118 new_path="$unix_path" 27119 fi 27120 27121 27122 new_path=`$WHICH "$new_path" 2> /dev/null` 27123 27124 if test "x$new_path" = x; then 27125 # It's still not found. Now this is an unrecoverable error. 27126 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27127 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27128 has_space=`$ECHO "$complete" | $GREP " "` 27129 if test "x$has_space" != x; then 27130 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27131 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27132 fi 27133 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27134 fi 27135 fi 27136 27137 # Now new_path has a complete unix path to the binary 27138 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 27139 # Keep paths in /bin as-is, but remove trailing .exe if any 27140 new_path="${new_path/%.exe/}" 27141 # Do not save /bin paths to all_fixpath_prefixes! 27142 else 27143 # Not in mixed or Windows style, start by that. 27144 new_path=`cmd //c echo $new_path` 27145 27146 input_path="$new_path" 27147 # Check if we need to convert this using DOS-style short mode. If the path 27148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27149 # take no chances and rewrite it. 27150 # Note: m4 eats our [], so we need to use [ and ] instead. 27151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27152 if test "x$has_forbidden_chars" != x; then 27153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27154 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27155 fi 27156 27157 # Output is in $new_path 27158 27159 windows_path="$new_path" 27160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27161 unix_path=`$CYGPATH -u "$windows_path"` 27162 new_path="$unix_path" 27163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27164 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27165 new_path="$unix_path" 27166 fi 27167 27168 # remove trailing .exe if any 27169 new_path="${new_path/%.exe/}" 27170 27171 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27172 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27173 fi 27174 27175 else 27176 # We're on a posix platform. Hooray! :) 27177 # First separate the path from the arguments. This will split at the first 27178 # space. 27179 complete="$NM" 27180 path="${complete%% *}" 27181 tmp="$complete EOL" 27182 arguments="${tmp#* }" 27183 27184 # Cannot rely on the command "which" here since it doesn't always work. 27185 is_absolute_path=`$ECHO "$path" | $GREP ^/` 27186 if test -z "$is_absolute_path"; then 27187 # Path to executable is not absolute. Find it. 27188 IFS_save="$IFS" 27189 IFS=: 27190 for p in $PATH; do 27191 if test -f "$p/$path" && test -x "$p/$path"; then 27192 new_path="$p/$path" 27193 break 27194 fi 27195 done 27196 IFS="$IFS_save" 27197 else 27198 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5 27199 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;} 27200 new_path="$path" 27201 fi 27202 27203 if test "x$new_path" = x; then 27204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 27205 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 27206 has_space=`$ECHO "$complete" | $GREP " "` 27207 if test "x$has_space" != x; then 27208 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 27209 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27210 fi 27211 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 27212 fi 27213 fi 27214 27215 # Now join together the path and the arguments once again 27216 if test "x$arguments" != xEOL; then 27217 new_complete="$new_path ${arguments% *}" 27218 else 27219 new_complete="$new_path" 27220 fi 27221 27222 if test "x$complete" != "x$new_complete"; then 27223 NM="$new_complete" 27224 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 27225 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 27226 fi 27227 27228 GNM="$NM" 27229 27230 if test -n "$ac_tool_prefix"; then 27231 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. 27232 set dummy ${ac_tool_prefix}strip; ac_word=$2 27233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27234 $as_echo_n "checking for $ac_word... " >&6; } 27235 if ${ac_cv_prog_STRIP+:} false; then : 27236 $as_echo_n "(cached) " >&6 27237 else 27238 if test -n "$STRIP"; then 27239 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 27240 else 27241 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27242 for as_dir in $PATH 27243 do 27244 IFS=$as_save_IFS 27245 test -z "$as_dir" && as_dir=. 27246 for ac_exec_ext in '' $ac_executable_extensions; do 27247 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27248 ac_cv_prog_STRIP="${ac_tool_prefix}strip" 27249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27250 break 2 27251 fi 27252 done 27253 done 27254 IFS=$as_save_IFS 27255 27256 fi 27257 fi 27258 STRIP=$ac_cv_prog_STRIP 27259 if test -n "$STRIP"; then 27260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 27261 $as_echo "$STRIP" >&6; } 27262 else 27263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27264 $as_echo "no" >&6; } 27265 fi 27266 27267 27268 fi 27269 if test -z "$ac_cv_prog_STRIP"; then 27270 ac_ct_STRIP=$STRIP 27271 # Extract the first word of "strip", so it can be a program name with args. 27272 set dummy strip; ac_word=$2 27273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27274 $as_echo_n "checking for $ac_word... " >&6; } 27275 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 27276 $as_echo_n "(cached) " >&6 27277 else 27278 if test -n "$ac_ct_STRIP"; then 27279 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 27280 else 27281 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27282 for as_dir in $PATH 27283 do 27284 IFS=$as_save_IFS 27285 test -z "$as_dir" && as_dir=. 27286 for ac_exec_ext in '' $ac_executable_extensions; do 27287 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27288 ac_cv_prog_ac_ct_STRIP="strip" 27289 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27290 break 2 27291 fi 27292 done 27293 done 27294 IFS=$as_save_IFS 27295 27296 fi 27297 fi 27298 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 27299 if test -n "$ac_ct_STRIP"; then 27300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 27301 $as_echo "$ac_ct_STRIP" >&6; } 27302 else 27303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27304 $as_echo "no" >&6; } 27305 fi 27306 27307 if test "x$ac_ct_STRIP" = x; then 27308 STRIP="" 27309 else 27310 case $cross_compiling:$ac_tool_warned in 27311 yes:) 27312 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 27313 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 27314 ac_tool_warned=yes ;; 27315 esac 27316 STRIP=$ac_ct_STRIP 27317 fi 27318 else 27319 STRIP="$ac_cv_prog_STRIP" 27320 fi 27321 27322 27323 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27324 27325 # First separate the path from the arguments. This will split at the first 27326 # space. 27327 complete="$STRIP" 27328 path="${complete%% *}" 27329 tmp="$complete EOL" 27330 arguments="${tmp#* }" 27331 27332 # Input might be given as Windows format, start by converting to 27333 # unix format. 27334 new_path=`$CYGPATH -u "$path"` 27335 27336 # Now try to locate executable using which 27337 new_path=`$WHICH "$new_path" 2> /dev/null` 27338 # bat and cmd files are not always considered executable in cygwin causing which 27339 # to not find them 27340 if test "x$new_path" = x \ 27341 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27342 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27343 new_path=`$CYGPATH -u "$path"` 27344 fi 27345 if test "x$new_path" = x; then 27346 # Oops. Which didn't find the executable. 27347 # The splitting of arguments from the executable at a space might have been incorrect, 27348 # since paths with space are more likely in Windows. Give it another try with the whole 27349 # argument. 27350 path="$complete" 27351 arguments="EOL" 27352 new_path=`$CYGPATH -u "$path"` 27353 new_path=`$WHICH "$new_path" 2> /dev/null` 27354 # bat and cmd files are not always considered executable in cygwin causing which 27355 # to not find them 27356 if test "x$new_path" = x \ 27357 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27358 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27359 new_path=`$CYGPATH -u "$path"` 27360 fi 27361 if test "x$new_path" = x; then 27362 # It's still not found. Now this is an unrecoverable error. 27363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27364 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27365 has_space=`$ECHO "$complete" | $GREP " "` 27366 if test "x$has_space" != x; then 27367 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27368 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27369 fi 27370 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27371 fi 27372 fi 27373 27374 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27375 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27376 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27377 # "foo.exe" is OK but "foo" is an error. 27378 # 27379 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27380 # It is also a way to make sure we got the proper file name for the real test later on. 27381 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27382 if test "x$test_shortpath" = x; then 27383 # Short path failed, file does not exist as specified. 27384 # Try adding .exe or .cmd 27385 if test -f "${new_path}.exe"; then 27386 input_to_shortpath="${new_path}.exe" 27387 elif test -f "${new_path}.cmd"; then 27388 input_to_shortpath="${new_path}.cmd" 27389 else 27390 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 27391 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 27392 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27393 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27394 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27395 fi 27396 else 27397 input_to_shortpath="$new_path" 27398 fi 27399 27400 # Call helper function which possibly converts this using DOS-style short mode. 27401 # If so, the updated path is stored in $new_path. 27402 new_path="$input_to_shortpath" 27403 27404 input_path="$input_to_shortpath" 27405 # Check if we need to convert this using DOS-style short mode. If the path 27406 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27407 # take no chances and rewrite it. 27408 # Note: m4 eats our [], so we need to use [ and ] instead. 27409 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27410 if test "x$has_forbidden_chars" != x; then 27411 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27412 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27413 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27414 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27415 # Going to short mode and back again did indeed matter. Since short mode is 27416 # case insensitive, let's make it lowercase to improve readability. 27417 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27418 # Now convert it back to Unix-stile (cygpath) 27419 input_path=`$CYGPATH -u "$shortmode_path"` 27420 new_path="$input_path" 27421 fi 27422 fi 27423 27424 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27425 if test "x$test_cygdrive_prefix" = x; then 27426 # As a simple fix, exclude /usr/bin since it's not a real path. 27427 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27428 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27429 # a path prefixed by /cygdrive for fixpath to work. 27430 new_path="$CYGWIN_ROOT_PATH$input_path" 27431 fi 27432 fi 27433 27434 # remove trailing .exe if any 27435 new_path="${new_path/%.exe/}" 27436 27437 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27438 27439 # First separate the path from the arguments. This will split at the first 27440 # space. 27441 complete="$STRIP" 27442 path="${complete%% *}" 27443 tmp="$complete EOL" 27444 arguments="${tmp#* }" 27445 27446 # Input might be given as Windows format, start by converting to 27447 # unix format. 27448 new_path="$path" 27449 27450 windows_path="$new_path" 27451 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27452 unix_path=`$CYGPATH -u "$windows_path"` 27453 new_path="$unix_path" 27454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27455 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27456 new_path="$unix_path" 27457 fi 27458 27459 27460 # Now try to locate executable using which 27461 new_path=`$WHICH "$new_path" 2> /dev/null` 27462 27463 if test "x$new_path" = x; then 27464 # Oops. Which didn't find the executable. 27465 # The splitting of arguments from the executable at a space might have been incorrect, 27466 # since paths with space are more likely in Windows. Give it another try with the whole 27467 # argument. 27468 path="$complete" 27469 arguments="EOL" 27470 new_path="$path" 27471 27472 windows_path="$new_path" 27473 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27474 unix_path=`$CYGPATH -u "$windows_path"` 27475 new_path="$unix_path" 27476 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27477 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27478 new_path="$unix_path" 27479 fi 27480 27481 27482 new_path=`$WHICH "$new_path" 2> /dev/null` 27483 27484 if test "x$new_path" = x; then 27485 # It's still not found. Now this is an unrecoverable error. 27486 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27487 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27488 has_space=`$ECHO "$complete" | $GREP " "` 27489 if test "x$has_space" != x; then 27490 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27491 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27492 fi 27493 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27494 fi 27495 fi 27496 27497 # Now new_path has a complete unix path to the binary 27498 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 27499 # Keep paths in /bin as-is, but remove trailing .exe if any 27500 new_path="${new_path/%.exe/}" 27501 # Do not save /bin paths to all_fixpath_prefixes! 27502 else 27503 # Not in mixed or Windows style, start by that. 27504 new_path=`cmd //c echo $new_path` 27505 27506 input_path="$new_path" 27507 # Check if we need to convert this using DOS-style short mode. If the path 27508 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27509 # take no chances and rewrite it. 27510 # Note: m4 eats our [], so we need to use [ and ] instead. 27511 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27512 if test "x$has_forbidden_chars" != x; then 27513 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27514 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27515 fi 27516 27517 # Output is in $new_path 27518 27519 windows_path="$new_path" 27520 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27521 unix_path=`$CYGPATH -u "$windows_path"` 27522 new_path="$unix_path" 27523 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27524 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27525 new_path="$unix_path" 27526 fi 27527 27528 # remove trailing .exe if any 27529 new_path="${new_path/%.exe/}" 27530 27531 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27532 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27533 fi 27534 27535 else 27536 # We're on a posix platform. Hooray! :) 27537 # First separate the path from the arguments. This will split at the first 27538 # space. 27539 complete="$STRIP" 27540 path="${complete%% *}" 27541 tmp="$complete EOL" 27542 arguments="${tmp#* }" 27543 27544 # Cannot rely on the command "which" here since it doesn't always work. 27545 is_absolute_path=`$ECHO "$path" | $GREP ^/` 27546 if test -z "$is_absolute_path"; then 27547 # Path to executable is not absolute. Find it. 27548 IFS_save="$IFS" 27549 IFS=: 27550 for p in $PATH; do 27551 if test -f "$p/$path" && test -x "$p/$path"; then 27552 new_path="$p/$path" 27553 break 27554 fi 27555 done 27556 IFS="$IFS_save" 27557 else 27558 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5 27559 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;} 27560 new_path="$path" 27561 fi 27562 27563 if test "x$new_path" = x; then 27564 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 27565 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 27566 has_space=`$ECHO "$complete" | $GREP " "` 27567 if test "x$has_space" != x; then 27568 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 27569 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27570 fi 27571 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 27572 fi 27573 fi 27574 27575 # Now join together the path and the arguments once again 27576 if test "x$arguments" != xEOL; then 27577 new_complete="$new_path ${arguments% *}" 27578 else 27579 new_complete="$new_path" 27580 fi 27581 27582 if test "x$complete" != "x$new_complete"; then 27583 STRIP="$new_complete" 27584 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 27585 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 27586 fi 27587 27588 fi 27589 27590 # objcopy is used for moving debug symbols to separate files when 27591 # full debug symbols are enabled. 27592 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 27593 if test -n "$ac_tool_prefix"; then 27594 for ac_prog in gobjcopy objcopy 27595 do 27596 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 27597 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 27598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27599 $as_echo_n "checking for $ac_word... " >&6; } 27600 if ${ac_cv_prog_OBJCOPY+:} false; then : 27601 $as_echo_n "(cached) " >&6 27602 else 27603 if test -n "$OBJCOPY"; then 27604 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 27605 else 27606 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27607 for as_dir in $PATH 27608 do 27609 IFS=$as_save_IFS 27610 test -z "$as_dir" && as_dir=. 27611 for ac_exec_ext in '' $ac_executable_extensions; do 27612 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27613 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 27614 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27615 break 2 27616 fi 27617 done 27618 done 27619 IFS=$as_save_IFS 27620 27621 fi 27622 fi 27623 OBJCOPY=$ac_cv_prog_OBJCOPY 27624 if test -n "$OBJCOPY"; then 27625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 27626 $as_echo "$OBJCOPY" >&6; } 27627 else 27628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27629 $as_echo "no" >&6; } 27630 fi 27631 27632 27633 test -n "$OBJCOPY" && break 27634 done 27635 fi 27636 if test -z "$OBJCOPY"; then 27637 ac_ct_OBJCOPY=$OBJCOPY 27638 for ac_prog in gobjcopy objcopy 27639 do 27640 # Extract the first word of "$ac_prog", so it can be a program name with args. 27641 set dummy $ac_prog; ac_word=$2 27642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27643 $as_echo_n "checking for $ac_word... " >&6; } 27644 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 27645 $as_echo_n "(cached) " >&6 27646 else 27647 if test -n "$ac_ct_OBJCOPY"; then 27648 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 27649 else 27650 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27651 for as_dir in $PATH 27652 do 27653 IFS=$as_save_IFS 27654 test -z "$as_dir" && as_dir=. 27655 for ac_exec_ext in '' $ac_executable_extensions; do 27656 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27657 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 27658 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27659 break 2 27660 fi 27661 done 27662 done 27663 IFS=$as_save_IFS 27664 27665 fi 27666 fi 27667 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 27668 if test -n "$ac_ct_OBJCOPY"; then 27669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 27670 $as_echo "$ac_ct_OBJCOPY" >&6; } 27671 else 27672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 27673 $as_echo "no" >&6; } 27674 fi 27675 27676 27677 test -n "$ac_ct_OBJCOPY" && break 27678 done 27679 27680 if test "x$ac_ct_OBJCOPY" = x; then 27681 OBJCOPY="" 27682 else 27683 case $cross_compiling:$ac_tool_warned in 27684 yes:) 27685 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 27686 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 27687 ac_tool_warned=yes ;; 27688 esac 27689 OBJCOPY=$ac_ct_OBJCOPY 27690 fi 27691 fi 27692 27693 # Only call fixup if objcopy was found. 27694 if test -n "$OBJCOPY"; then 27695 27696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27697 27698 # First separate the path from the arguments. This will split at the first 27699 # space. 27700 complete="$OBJCOPY" 27701 path="${complete%% *}" 27702 tmp="$complete EOL" 27703 arguments="${tmp#* }" 27704 27705 # Input might be given as Windows format, start by converting to 27706 # unix format. 27707 new_path=`$CYGPATH -u "$path"` 27708 27709 # Now try to locate executable using which 27710 new_path=`$WHICH "$new_path" 2> /dev/null` 27711 # bat and cmd files are not always considered executable in cygwin causing which 27712 # to not find them 27713 if test "x$new_path" = x \ 27714 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27715 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27716 new_path=`$CYGPATH -u "$path"` 27717 fi 27718 if test "x$new_path" = x; then 27719 # Oops. Which didn't find the executable. 27720 # The splitting of arguments from the executable at a space might have been incorrect, 27721 # since paths with space are more likely in Windows. Give it another try with the whole 27722 # argument. 27723 path="$complete" 27724 arguments="EOL" 27725 new_path=`$CYGPATH -u "$path"` 27726 new_path=`$WHICH "$new_path" 2> /dev/null` 27727 # bat and cmd files are not always considered executable in cygwin causing which 27728 # to not find them 27729 if test "x$new_path" = x \ 27730 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 27731 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 27732 new_path=`$CYGPATH -u "$path"` 27733 fi 27734 if test "x$new_path" = x; then 27735 # It's still not found. Now this is an unrecoverable error. 27736 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 27737 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 27738 has_space=`$ECHO "$complete" | $GREP " "` 27739 if test "x$has_space" != x; then 27740 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27741 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27742 fi 27743 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27744 fi 27745 fi 27746 27747 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27748 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27749 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27750 # "foo.exe" is OK but "foo" is an error. 27751 # 27752 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27753 # It is also a way to make sure we got the proper file name for the real test later on. 27754 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27755 if test "x$test_shortpath" = x; then 27756 # Short path failed, file does not exist as specified. 27757 # Try adding .exe or .cmd 27758 if test -f "${new_path}.exe"; then 27759 input_to_shortpath="${new_path}.exe" 27760 elif test -f "${new_path}.cmd"; then 27761 input_to_shortpath="${new_path}.cmd" 27762 else 27763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 27764 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 27765 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 27766 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 27767 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27768 fi 27769 else 27770 input_to_shortpath="$new_path" 27771 fi 27772 27773 # Call helper function which possibly converts this using DOS-style short mode. 27774 # If so, the updated path is stored in $new_path. 27775 new_path="$input_to_shortpath" 27776 27777 input_path="$input_to_shortpath" 27778 # Check if we need to convert this using DOS-style short mode. If the path 27779 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27780 # take no chances and rewrite it. 27781 # Note: m4 eats our [], so we need to use [ and ] instead. 27782 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27783 if test "x$has_forbidden_chars" != x; then 27784 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27785 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27786 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27787 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27788 # Going to short mode and back again did indeed matter. Since short mode is 27789 # case insensitive, let's make it lowercase to improve readability. 27790 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27791 # Now convert it back to Unix-stile (cygpath) 27792 input_path=`$CYGPATH -u "$shortmode_path"` 27793 new_path="$input_path" 27794 fi 27795 fi 27796 27797 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27798 if test "x$test_cygdrive_prefix" = x; then 27799 # As a simple fix, exclude /usr/bin since it's not a real path. 27800 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 27801 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27802 # a path prefixed by /cygdrive for fixpath to work. 27803 new_path="$CYGWIN_ROOT_PATH$input_path" 27804 fi 27805 fi 27806 27807 # remove trailing .exe if any 27808 new_path="${new_path/%.exe/}" 27809 27810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27811 27812 # First separate the path from the arguments. This will split at the first 27813 # space. 27814 complete="$OBJCOPY" 27815 path="${complete%% *}" 27816 tmp="$complete EOL" 27817 arguments="${tmp#* }" 27818 27819 # Input might be given as Windows format, start by converting to 27820 # unix format. 27821 new_path="$path" 27822 27823 windows_path="$new_path" 27824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27825 unix_path=`$CYGPATH -u "$windows_path"` 27826 new_path="$unix_path" 27827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27828 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27829 new_path="$unix_path" 27830 fi 27831 27832 27833 # Now try to locate executable using which 27834 new_path=`$WHICH "$new_path" 2> /dev/null` 27835 27836 if test "x$new_path" = x; then 27837 # Oops. Which didn't find the executable. 27838 # The splitting of arguments from the executable at a space might have been incorrect, 27839 # since paths with space are more likely in Windows. Give it another try with the whole 27840 # argument. 27841 path="$complete" 27842 arguments="EOL" 27843 new_path="$path" 27844 27845 windows_path="$new_path" 27846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27847 unix_path=`$CYGPATH -u "$windows_path"` 27848 new_path="$unix_path" 27849 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27850 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27851 new_path="$unix_path" 27852 fi 27853 27854 27855 new_path=`$WHICH "$new_path" 2> /dev/null` 27856 27857 if test "x$new_path" = x; then 27858 # It's still not found. Now this is an unrecoverable error. 27859 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 27860 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 27861 has_space=`$ECHO "$complete" | $GREP " "` 27862 if test "x$has_space" != x; then 27863 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 27864 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 27865 fi 27866 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27867 fi 27868 fi 27869 27870 # Now new_path has a complete unix path to the binary 27871 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 27872 # Keep paths in /bin as-is, but remove trailing .exe if any 27873 new_path="${new_path/%.exe/}" 27874 # Do not save /bin paths to all_fixpath_prefixes! 27875 else 27876 # Not in mixed or Windows style, start by that. 27877 new_path=`cmd //c echo $new_path` 27878 27879 input_path="$new_path" 27880 # Check if we need to convert this using DOS-style short mode. If the path 27881 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27882 # take no chances and rewrite it. 27883 # Note: m4 eats our [], so we need to use [ and ] instead. 27884 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27885 if test "x$has_forbidden_chars" != x; then 27886 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27887 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27888 fi 27889 27890 # Output is in $new_path 27891 27892 windows_path="$new_path" 27893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27894 unix_path=`$CYGPATH -u "$windows_path"` 27895 new_path="$unix_path" 27896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27898 new_path="$unix_path" 27899 fi 27900 27901 # remove trailing .exe if any 27902 new_path="${new_path/%.exe/}" 27903 27904 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27905 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27906 fi 27907 27908 else 27909 # We're on a posix platform. Hooray! :) 27910 # First separate the path from the arguments. This will split at the first 27911 # space. 27912 complete="$OBJCOPY" 27913 path="${complete%% *}" 27914 tmp="$complete EOL" 27915 arguments="${tmp#* }" 27916 27917 # Cannot rely on the command "which" here since it doesn't always work. 27918 is_absolute_path=`$ECHO "$path" | $GREP ^/` 27919 if test -z "$is_absolute_path"; then 27920 # Path to executable is not absolute. Find it. 27921 IFS_save="$IFS" 27922 IFS=: 27923 for p in $PATH; do 27924 if test -f "$p/$path" && test -x "$p/$path"; then 27925 new_path="$p/$path" 27926 break 27927 fi 27928 done 27929 IFS="$IFS_save" 27930 else 27931 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJCOPY (as $path) failed, using $path directly." >&5 27932 $as_echo "$as_me: Resolving OBJCOPY (as $path) failed, using $path directly." >&6;} 27933 new_path="$path" 27934 fi 27935 27936 if test "x$new_path" = x; then 27937 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 27938 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 27939 has_space=`$ECHO "$complete" | $GREP " "` 27940 if test "x$has_space" != x; then 27941 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 27942 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 27943 fi 27944 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 27945 fi 27946 fi 27947 27948 # Now join together the path and the arguments once again 27949 if test "x$arguments" != xEOL; then 27950 new_complete="$new_path ${arguments% *}" 27951 else 27952 new_complete="$new_path" 27953 fi 27954 27955 if test "x$complete" != "x$new_complete"; then 27956 OBJCOPY="$new_complete" 27957 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 27958 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 27959 fi 27960 27961 fi 27962 fi 27963 27964 if test -n "$ac_tool_prefix"; then 27965 for ac_prog in gobjdump objdump 27966 do 27967 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 27968 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 27969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 27970 $as_echo_n "checking for $ac_word... " >&6; } 27971 if ${ac_cv_prog_OBJDUMP+:} false; then : 27972 $as_echo_n "(cached) " >&6 27973 else 27974 if test -n "$OBJDUMP"; then 27975 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 27976 else 27977 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 27978 for as_dir in $PATH 27979 do 27980 IFS=$as_save_IFS 27981 test -z "$as_dir" && as_dir=. 27982 for ac_exec_ext in '' $ac_executable_extensions; do 27983 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 27984 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 27985 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 27986 break 2 27987 fi 27988 done 27989 done 27990 IFS=$as_save_IFS 27991 27992 fi 27993 fi 27994 OBJDUMP=$ac_cv_prog_OBJDUMP 27995 if test -n "$OBJDUMP"; then 27996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 27997 $as_echo "$OBJDUMP" >&6; } 27998 else 27999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28000 $as_echo "no" >&6; } 28001 fi 28002 28003 28004 test -n "$OBJDUMP" && break 28005 done 28006 fi 28007 if test -z "$OBJDUMP"; then 28008 ac_ct_OBJDUMP=$OBJDUMP 28009 for ac_prog in gobjdump objdump 28010 do 28011 # Extract the first word of "$ac_prog", so it can be a program name with args. 28012 set dummy $ac_prog; ac_word=$2 28013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28014 $as_echo_n "checking for $ac_word... " >&6; } 28015 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 28016 $as_echo_n "(cached) " >&6 28017 else 28018 if test -n "$ac_ct_OBJDUMP"; then 28019 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 28020 else 28021 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28022 for as_dir in $PATH 28023 do 28024 IFS=$as_save_IFS 28025 test -z "$as_dir" && as_dir=. 28026 for ac_exec_ext in '' $ac_executable_extensions; do 28027 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 28028 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 28029 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28030 break 2 28031 fi 28032 done 28033 done 28034 IFS=$as_save_IFS 28035 28036 fi 28037 fi 28038 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 28039 if test -n "$ac_ct_OBJDUMP"; then 28040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 28041 $as_echo "$ac_ct_OBJDUMP" >&6; } 28042 else 28043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28044 $as_echo "no" >&6; } 28045 fi 28046 28047 28048 test -n "$ac_ct_OBJDUMP" && break 28049 done 28050 28051 if test "x$ac_ct_OBJDUMP" = x; then 28052 OBJDUMP="" 28053 else 28054 case $cross_compiling:$ac_tool_warned in 28055 yes:) 28056 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 28057 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 28058 ac_tool_warned=yes ;; 28059 esac 28060 OBJDUMP=$ac_ct_OBJDUMP 28061 fi 28062 fi 28063 28064 if test "x$OBJDUMP" != x; then 28065 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE bails if argument is missing. 28066 28067 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28068 28069 # First separate the path from the arguments. This will split at the first 28070 # space. 28071 complete="$OBJDUMP" 28072 path="${complete%% *}" 28073 tmp="$complete EOL" 28074 arguments="${tmp#* }" 28075 28076 # Input might be given as Windows format, start by converting to 28077 # unix format. 28078 new_path=`$CYGPATH -u "$path"` 28079 28080 # Now try to locate executable using which 28081 new_path=`$WHICH "$new_path" 2> /dev/null` 28082 # bat and cmd files are not always considered executable in cygwin causing which 28083 # to not find them 28084 if test "x$new_path" = x \ 28085 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28086 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28087 new_path=`$CYGPATH -u "$path"` 28088 fi 28089 if test "x$new_path" = x; then 28090 # Oops. Which didn't find the executable. 28091 # The splitting of arguments from the executable at a space might have been incorrect, 28092 # since paths with space are more likely in Windows. Give it another try with the whole 28093 # argument. 28094 path="$complete" 28095 arguments="EOL" 28096 new_path=`$CYGPATH -u "$path"` 28097 new_path=`$WHICH "$new_path" 2> /dev/null` 28098 # bat and cmd files are not always considered executable in cygwin causing which 28099 # to not find them 28100 if test "x$new_path" = x \ 28101 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28102 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28103 new_path=`$CYGPATH -u "$path"` 28104 fi 28105 if test "x$new_path" = x; then 28106 # It's still not found. Now this is an unrecoverable error. 28107 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28108 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28109 has_space=`$ECHO "$complete" | $GREP " "` 28110 if test "x$has_space" != x; then 28111 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28112 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28113 fi 28114 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28115 fi 28116 fi 28117 28118 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28119 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28120 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28121 # "foo.exe" is OK but "foo" is an error. 28122 # 28123 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28124 # It is also a way to make sure we got the proper file name for the real test later on. 28125 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28126 if test "x$test_shortpath" = x; then 28127 # Short path failed, file does not exist as specified. 28128 # Try adding .exe or .cmd 28129 if test -f "${new_path}.exe"; then 28130 input_to_shortpath="${new_path}.exe" 28131 elif test -f "${new_path}.cmd"; then 28132 input_to_shortpath="${new_path}.cmd" 28133 else 28134 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 28135 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 28136 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 28137 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 28138 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28139 fi 28140 else 28141 input_to_shortpath="$new_path" 28142 fi 28143 28144 # Call helper function which possibly converts this using DOS-style short mode. 28145 # If so, the updated path is stored in $new_path. 28146 new_path="$input_to_shortpath" 28147 28148 input_path="$input_to_shortpath" 28149 # Check if we need to convert this using DOS-style short mode. If the path 28150 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28151 # take no chances and rewrite it. 28152 # Note: m4 eats our [], so we need to use [ and ] instead. 28153 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28154 if test "x$has_forbidden_chars" != x; then 28155 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28156 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28157 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28158 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28159 # Going to short mode and back again did indeed matter. Since short mode is 28160 # case insensitive, let's make it lowercase to improve readability. 28161 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28162 # Now convert it back to Unix-stile (cygpath) 28163 input_path=`$CYGPATH -u "$shortmode_path"` 28164 new_path="$input_path" 28165 fi 28166 fi 28167 28168 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28169 if test "x$test_cygdrive_prefix" = x; then 28170 # As a simple fix, exclude /usr/bin since it's not a real path. 28171 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 28172 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28173 # a path prefixed by /cygdrive for fixpath to work. 28174 new_path="$CYGWIN_ROOT_PATH$input_path" 28175 fi 28176 fi 28177 28178 # remove trailing .exe if any 28179 new_path="${new_path/%.exe/}" 28180 28181 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28182 28183 # First separate the path from the arguments. This will split at the first 28184 # space. 28185 complete="$OBJDUMP" 28186 path="${complete%% *}" 28187 tmp="$complete EOL" 28188 arguments="${tmp#* }" 28189 28190 # Input might be given as Windows format, start by converting to 28191 # unix format. 28192 new_path="$path" 28193 28194 windows_path="$new_path" 28195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28196 unix_path=`$CYGPATH -u "$windows_path"` 28197 new_path="$unix_path" 28198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28199 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28200 new_path="$unix_path" 28201 fi 28202 28203 28204 # Now try to locate executable using which 28205 new_path=`$WHICH "$new_path" 2> /dev/null` 28206 28207 if test "x$new_path" = x; then 28208 # Oops. Which didn't find the executable. 28209 # The splitting of arguments from the executable at a space might have been incorrect, 28210 # since paths with space are more likely in Windows. Give it another try with the whole 28211 # argument. 28212 path="$complete" 28213 arguments="EOL" 28214 new_path="$path" 28215 28216 windows_path="$new_path" 28217 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28218 unix_path=`$CYGPATH -u "$windows_path"` 28219 new_path="$unix_path" 28220 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28221 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28222 new_path="$unix_path" 28223 fi 28224 28225 28226 new_path=`$WHICH "$new_path" 2> /dev/null` 28227 28228 if test "x$new_path" = x; then 28229 # It's still not found. Now this is an unrecoverable error. 28230 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28231 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28232 has_space=`$ECHO "$complete" | $GREP " "` 28233 if test "x$has_space" != x; then 28234 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28235 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28236 fi 28237 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28238 fi 28239 fi 28240 28241 # Now new_path has a complete unix path to the binary 28242 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 28243 # Keep paths in /bin as-is, but remove trailing .exe if any 28244 new_path="${new_path/%.exe/}" 28245 # Do not save /bin paths to all_fixpath_prefixes! 28246 else 28247 # Not in mixed or Windows style, start by that. 28248 new_path=`cmd //c echo $new_path` 28249 28250 input_path="$new_path" 28251 # Check if we need to convert this using DOS-style short mode. If the path 28252 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28253 # take no chances and rewrite it. 28254 # Note: m4 eats our [], so we need to use [ and ] instead. 28255 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28256 if test "x$has_forbidden_chars" != x; then 28257 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28258 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28259 fi 28260 28261 # Output is in $new_path 28262 28263 windows_path="$new_path" 28264 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28265 unix_path=`$CYGPATH -u "$windows_path"` 28266 new_path="$unix_path" 28267 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28268 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28269 new_path="$unix_path" 28270 fi 28271 28272 # remove trailing .exe if any 28273 new_path="${new_path/%.exe/}" 28274 28275 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28276 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28277 fi 28278 28279 else 28280 # We're on a posix platform. Hooray! :) 28281 # First separate the path from the arguments. This will split at the first 28282 # space. 28283 complete="$OBJDUMP" 28284 path="${complete%% *}" 28285 tmp="$complete EOL" 28286 arguments="${tmp#* }" 28287 28288 # Cannot rely on the command "which" here since it doesn't always work. 28289 is_absolute_path=`$ECHO "$path" | $GREP ^/` 28290 if test -z "$is_absolute_path"; then 28291 # Path to executable is not absolute. Find it. 28292 IFS_save="$IFS" 28293 IFS=: 28294 for p in $PATH; do 28295 if test -f "$p/$path" && test -x "$p/$path"; then 28296 new_path="$p/$path" 28297 break 28298 fi 28299 done 28300 IFS="$IFS_save" 28301 else 28302 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJDUMP (as $path) failed, using $path directly." >&5 28303 $as_echo "$as_me: Resolving OBJDUMP (as $path) failed, using $path directly." >&6;} 28304 new_path="$path" 28305 fi 28306 28307 if test "x$new_path" = x; then 28308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 28309 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 28310 has_space=`$ECHO "$complete" | $GREP " "` 28311 if test "x$has_space" != x; then 28312 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 28313 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 28314 fi 28315 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 28316 fi 28317 fi 28318 28319 # Now join together the path and the arguments once again 28320 if test "x$arguments" != xEOL; then 28321 new_complete="$new_path ${arguments% *}" 28322 else 28323 new_complete="$new_path" 28324 fi 28325 28326 if test "x$complete" != "x$new_complete"; then 28327 OBJDUMP="$new_complete" 28328 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 28329 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 28330 fi 28331 28332 fi 28333 28334 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 28335 # Extract the first word of "lipo", so it can be a program name with args. 28336 set dummy lipo; ac_word=$2 28337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28338 $as_echo_n "checking for $ac_word... " >&6; } 28339 if ${ac_cv_path_LIPO+:} false; then : 28340 $as_echo_n "(cached) " >&6 28341 else 28342 case $LIPO in 28343 [\\/]* | ?:[\\/]*) 28344 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 28345 ;; 28346 *) 28347 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28348 for as_dir in $PATH 28349 do 28350 IFS=$as_save_IFS 28351 test -z "$as_dir" && as_dir=. 28352 for ac_exec_ext in '' $ac_executable_extensions; do 28353 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 28354 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 28355 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28356 break 2 28357 fi 28358 done 28359 done 28360 IFS=$as_save_IFS 28361 28362 ;; 28363 esac 28364 fi 28365 LIPO=$ac_cv_path_LIPO 28366 if test -n "$LIPO"; then 28367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 28368 $as_echo "$LIPO" >&6; } 28369 else 28370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28371 $as_echo "no" >&6; } 28372 fi 28373 28374 28375 28376 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28377 28378 # First separate the path from the arguments. This will split at the first 28379 # space. 28380 complete="$LIPO" 28381 path="${complete%% *}" 28382 tmp="$complete EOL" 28383 arguments="${tmp#* }" 28384 28385 # Input might be given as Windows format, start by converting to 28386 # unix format. 28387 new_path=`$CYGPATH -u "$path"` 28388 28389 # Now try to locate executable using which 28390 new_path=`$WHICH "$new_path" 2> /dev/null` 28391 # bat and cmd files are not always considered executable in cygwin causing which 28392 # to not find them 28393 if test "x$new_path" = x \ 28394 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28395 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28396 new_path=`$CYGPATH -u "$path"` 28397 fi 28398 if test "x$new_path" = x; then 28399 # Oops. Which didn't find the executable. 28400 # The splitting of arguments from the executable at a space might have been incorrect, 28401 # since paths with space are more likely in Windows. Give it another try with the whole 28402 # argument. 28403 path="$complete" 28404 arguments="EOL" 28405 new_path=`$CYGPATH -u "$path"` 28406 new_path=`$WHICH "$new_path" 2> /dev/null` 28407 # bat and cmd files are not always considered executable in cygwin causing which 28408 # to not find them 28409 if test "x$new_path" = x \ 28410 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 28411 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 28412 new_path=`$CYGPATH -u "$path"` 28413 fi 28414 if test "x$new_path" = x; then 28415 # It's still not found. Now this is an unrecoverable error. 28416 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28417 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28418 has_space=`$ECHO "$complete" | $GREP " "` 28419 if test "x$has_space" != x; then 28420 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28421 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28422 fi 28423 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28424 fi 28425 fi 28426 28427 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28428 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28429 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28430 # "foo.exe" is OK but "foo" is an error. 28431 # 28432 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28433 # It is also a way to make sure we got the proper file name for the real test later on. 28434 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28435 if test "x$test_shortpath" = x; then 28436 # Short path failed, file does not exist as specified. 28437 # Try adding .exe or .cmd 28438 if test -f "${new_path}.exe"; then 28439 input_to_shortpath="${new_path}.exe" 28440 elif test -f "${new_path}.cmd"; then 28441 input_to_shortpath="${new_path}.cmd" 28442 else 28443 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 28444 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 28445 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 28446 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 28447 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28448 fi 28449 else 28450 input_to_shortpath="$new_path" 28451 fi 28452 28453 # Call helper function which possibly converts this using DOS-style short mode. 28454 # If so, the updated path is stored in $new_path. 28455 new_path="$input_to_shortpath" 28456 28457 input_path="$input_to_shortpath" 28458 # Check if we need to convert this using DOS-style short mode. If the path 28459 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28460 # take no chances and rewrite it. 28461 # Note: m4 eats our [], so we need to use [ and ] instead. 28462 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28463 if test "x$has_forbidden_chars" != x; then 28464 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28465 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28466 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28467 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28468 # Going to short mode and back again did indeed matter. Since short mode is 28469 # case insensitive, let's make it lowercase to improve readability. 28470 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28471 # Now convert it back to Unix-stile (cygpath) 28472 input_path=`$CYGPATH -u "$shortmode_path"` 28473 new_path="$input_path" 28474 fi 28475 fi 28476 28477 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28478 if test "x$test_cygdrive_prefix" = x; then 28479 # As a simple fix, exclude /usr/bin since it's not a real path. 28480 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 28481 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28482 # a path prefixed by /cygdrive for fixpath to work. 28483 new_path="$CYGWIN_ROOT_PATH$input_path" 28484 fi 28485 fi 28486 28487 # remove trailing .exe if any 28488 new_path="${new_path/%.exe/}" 28489 28490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28491 28492 # First separate the path from the arguments. This will split at the first 28493 # space. 28494 complete="$LIPO" 28495 path="${complete%% *}" 28496 tmp="$complete EOL" 28497 arguments="${tmp#* }" 28498 28499 # Input might be given as Windows format, start by converting to 28500 # unix format. 28501 new_path="$path" 28502 28503 windows_path="$new_path" 28504 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28505 unix_path=`$CYGPATH -u "$windows_path"` 28506 new_path="$unix_path" 28507 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28508 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28509 new_path="$unix_path" 28510 fi 28511 28512 28513 # Now try to locate executable using which 28514 new_path=`$WHICH "$new_path" 2> /dev/null` 28515 28516 if test "x$new_path" = x; then 28517 # Oops. Which didn't find the executable. 28518 # The splitting of arguments from the executable at a space might have been incorrect, 28519 # since paths with space are more likely in Windows. Give it another try with the whole 28520 # argument. 28521 path="$complete" 28522 arguments="EOL" 28523 new_path="$path" 28524 28525 windows_path="$new_path" 28526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28527 unix_path=`$CYGPATH -u "$windows_path"` 28528 new_path="$unix_path" 28529 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28530 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28531 new_path="$unix_path" 28532 fi 28533 28534 28535 new_path=`$WHICH "$new_path" 2> /dev/null` 28536 28537 if test "x$new_path" = x; then 28538 # It's still not found. Now this is an unrecoverable error. 28539 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28540 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28541 has_space=`$ECHO "$complete" | $GREP " "` 28542 if test "x$has_space" != x; then 28543 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 28544 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 28545 fi 28546 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28547 fi 28548 fi 28549 28550 # Now new_path has a complete unix path to the binary 28551 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 28552 # Keep paths in /bin as-is, but remove trailing .exe if any 28553 new_path="${new_path/%.exe/}" 28554 # Do not save /bin paths to all_fixpath_prefixes! 28555 else 28556 # Not in mixed or Windows style, start by that. 28557 new_path=`cmd //c echo $new_path` 28558 28559 input_path="$new_path" 28560 # Check if we need to convert this using DOS-style short mode. If the path 28561 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28562 # take no chances and rewrite it. 28563 # Note: m4 eats our [], so we need to use [ and ] instead. 28564 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28565 if test "x$has_forbidden_chars" != x; then 28566 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28567 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28568 fi 28569 28570 # Output is in $new_path 28571 28572 windows_path="$new_path" 28573 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28574 unix_path=`$CYGPATH -u "$windows_path"` 28575 new_path="$unix_path" 28576 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28577 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28578 new_path="$unix_path" 28579 fi 28580 28581 # remove trailing .exe if any 28582 new_path="${new_path/%.exe/}" 28583 28584 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28585 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28586 fi 28587 28588 else 28589 # We're on a posix platform. Hooray! :) 28590 # First separate the path from the arguments. This will split at the first 28591 # space. 28592 complete="$LIPO" 28593 path="${complete%% *}" 28594 tmp="$complete EOL" 28595 arguments="${tmp#* }" 28596 28597 # Cannot rely on the command "which" here since it doesn't always work. 28598 is_absolute_path=`$ECHO "$path" | $GREP ^/` 28599 if test -z "$is_absolute_path"; then 28600 # Path to executable is not absolute. Find it. 28601 IFS_save="$IFS" 28602 IFS=: 28603 for p in $PATH; do 28604 if test -f "$p/$path" && test -x "$p/$path"; then 28605 new_path="$p/$path" 28606 break 28607 fi 28608 done 28609 IFS="$IFS_save" 28610 else 28611 { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving LIPO (as $path) failed, using $path directly." >&5 28612 $as_echo "$as_me: Resolving LIPO (as $path) failed, using $path directly." >&6;} 28613 new_path="$path" 28614 fi 28615 28616 if test "x$new_path" = x; then 28617 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 28618 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 28619 has_space=`$ECHO "$complete" | $GREP " "` 28620 if test "x$has_space" != x; then 28621 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 28622 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 28623 fi 28624 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 28625 fi 28626 fi 28627 28628 # Now join together the path and the arguments once again 28629 if test "x$arguments" != xEOL; then 28630 new_complete="$new_path ${arguments% *}" 28631 else 28632 new_complete="$new_path" 28633 fi 28634 28635 if test "x$complete" != "x$new_complete"; then 28636 LIPO="$new_complete" 28637 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 28638 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 28639 fi 28640 28641 fi 28642 28643 28644 28645 # Restore old path without tools dir 28646 PATH="$OLD_PATH" 28647 28648 28649 # FIXME: Currently we must test this after paths but before flags. Fix! 28650 28651 # And we can test some aspects on the target using configure macros. 28652 28653 28654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 28655 $as_echo_n "checking for ANSI C header files... " >&6; } 28656 if ${ac_cv_header_stdc+:} false; then : 28657 $as_echo_n "(cached) " >&6 28658 else 28659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28660 /* end confdefs.h. */ 28661 #include <stdlib.h> 28662 #include <stdarg.h> 28663 #include <string.h> 28664 #include <float.h> 28665 28666 int 28667 main () 28668 { 28669 28670 ; 28671 return 0; 28672 } 28673 _ACEOF 28674 if ac_fn_cxx_try_compile "$LINENO"; then : 28675 ac_cv_header_stdc=yes 28676 else 28677 ac_cv_header_stdc=no 28678 fi 28679 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 28680 28681 if test $ac_cv_header_stdc = yes; then 28682 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 28683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28684 /* end confdefs.h. */ 28685 #include <string.h> 28686 28687 _ACEOF 28688 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 28689 $EGREP "memchr" >/dev/null 2>&1; then : 28690 28691 else 28692 ac_cv_header_stdc=no 28693 fi 28694 rm -f conftest* 28695 28696 fi 28697 28698 if test $ac_cv_header_stdc = yes; then 28699 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 28700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28701 /* end confdefs.h. */ 28702 #include <stdlib.h> 28703 28704 _ACEOF 28705 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 28706 $EGREP "free" >/dev/null 2>&1; then : 28707 28708 else 28709 ac_cv_header_stdc=no 28710 fi 28711 rm -f conftest* 28712 28713 fi 28714 28715 if test $ac_cv_header_stdc = yes; then 28716 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 28717 if test "$cross_compiling" = yes; then : 28718 : 28719 else 28720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28721 /* end confdefs.h. */ 28722 #include <ctype.h> 28723 #include <stdlib.h> 28724 #if ((' ' & 0x0FF) == 0x020) 28725 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 28726 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 28727 #else 28728 # define ISLOWER(c) \ 28729 (('a' <= (c) && (c) <= 'i') \ 28730 || ('j' <= (c) && (c) <= 'r') \ 28731 || ('s' <= (c) && (c) <= 'z')) 28732 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 28733 #endif 28734 28735 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 28736 int 28737 main () 28738 { 28739 int i; 28740 for (i = 0; i < 256; i++) 28741 if (XOR (islower (i), ISLOWER (i)) 28742 || toupper (i) != TOUPPER (i)) 28743 return 2; 28744 return 0; 28745 } 28746 _ACEOF 28747 if ac_fn_cxx_try_run "$LINENO"; then : 28748 28749 else 28750 ac_cv_header_stdc=no 28751 fi 28752 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 28753 conftest.$ac_objext conftest.beam conftest.$ac_ext 28754 fi 28755 28756 fi 28757 fi 28758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 28759 $as_echo "$ac_cv_header_stdc" >&6; } 28760 if test $ac_cv_header_stdc = yes; then 28761 28762 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 28763 28764 fi 28765 28766 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 28767 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 28768 inttypes.h stdint.h unistd.h 28769 do : 28770 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 28771 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 28772 " 28773 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 28774 cat >>confdefs.h <<_ACEOF 28775 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 28776 _ACEOF 28777 28778 fi 28779 28780 done 28781 28782 28783 28784 ############################################################################### 28785 # 28786 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 28787 # (The JVM can use 32 or 64 bit Java pointers but that decision 28788 # is made at runtime.) 28789 # 28790 28791 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 28792 # Always specify -m flags on Solaris 28793 28794 # keep track of c/cxx flags that we added outselves... 28795 # to prevent emitting warning... 28796 TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}" 28797 28798 28799 CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}" 28800 CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}" 28801 LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}" 28802 28803 CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}" 28804 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}" 28805 LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}" 28806 28807 elif test "x$COMPILE_TYPE" = xreduced; then 28808 if test "x$OPENJDK_TARGET_OS" != xwindows; then 28809 # Specify -m if running reduced on other Posix platforms 28810 28811 # keep track of c/cxx flags that we added outselves... 28812 # to prevent emitting warning... 28813 TARGET_BITS_FLAG="-m${OPENJDK_TARGET_CPU_BITS}" 28814 28815 28816 CFLAGS="${CFLAGS} ${TARGET_BITS_FLAG}" 28817 CXXFLAGS="${CXXFLAGS} ${TARGET_BITS_FLAG}" 28818 LDFLAGS="${LDFLAGS} ${TARGET_BITS_FLAG}" 28819 28820 CFLAGS_JDK="${CFLAGS_JDK} ${TARGET_BITS_FLAG}" 28821 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${TARGET_BITS_FLAG}" 28822 LDFLAGS_JDK="${LDFLAGS_JDK} ${TARGET_BITS_FLAG}" 28823 28824 fi 28825 fi 28826 28827 # Make compilation sanity check 28828 for ac_header in stdio.h 28829 do : 28830 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 28831 if test "x$ac_cv_header_stdio_h" = xyes; then : 28832 cat >>confdefs.h <<_ACEOF 28833 #define HAVE_STDIO_H 1 28834 _ACEOF 28835 28836 else 28837 28838 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 28839 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 28840 if test "x$COMPILE_TYPE" = xreduced; then 28841 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5 28842 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;} 28843 elif test "x$COMPILE_TYPE" = xcross; then 28844 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 28845 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 28846 fi 28847 as_fn_error $? "Cannot continue." "$LINENO" 5 28848 28849 fi 28850 28851 done 28852 28853 28854 # The cast to long int works around a bug in the HP C Compiler 28855 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 28856 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 28857 # This bug is HP SR number 8606223364. 28858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 28859 $as_echo_n "checking size of int *... " >&6; } 28860 if ${ac_cv_sizeof_int_p+:} false; then : 28861 $as_echo_n "(cached) " >&6 28862 else 28863 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 28864 28865 else 28866 if test "$ac_cv_type_int_p" = yes; then 28867 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 28868 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 28869 as_fn_error 77 "cannot compute sizeof (int *) 28870 See \`config.log' for more details" "$LINENO" 5; } 28871 else 28872 ac_cv_sizeof_int_p=0 28873 fi 28874 fi 28875 28876 fi 28877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 28878 $as_echo "$ac_cv_sizeof_int_p" >&6; } 28879 28880 28881 28882 cat >>confdefs.h <<_ACEOF 28883 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 28884 _ACEOF 28885 28886 28887 28888 if test "x$SIZEOF_INT_P" != "x$ac_cv_sizeof_int_p"; then 28889 # Workaround autoconf bug, see http://lists.gnu.org/archive/html/autoconf/2010-07/msg00004.html 28890 SIZEOF_INT_P="$ac_cv_sizeof_int_p" 28891 fi 28892 28893 if test "x$SIZEOF_INT_P" = x; then 28894 # The test failed, lets stick to the assumed value. 28895 { $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 28896 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 28897 else 28898 TESTED_TARGET_CPU_BITS=`expr 8 \* $SIZEOF_INT_P` 28899 28900 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 28901 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 28902 fi 28903 fi 28904 28905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 28906 $as_echo_n "checking for target address size... " >&6; } 28907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 28908 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 28909 28910 28911 ############################################################################### 28912 # 28913 # Is the target little of big endian? 28914 # 28915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 28916 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 28917 if ${ac_cv_c_bigendian+:} false; then : 28918 $as_echo_n "(cached) " >&6 28919 else 28920 ac_cv_c_bigendian=unknown 28921 # See if we're dealing with a universal compiler. 28922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28923 /* end confdefs.h. */ 28924 #ifndef __APPLE_CC__ 28925 not a universal capable compiler 28926 #endif 28927 typedef int dummy; 28928 28929 _ACEOF 28930 if ac_fn_cxx_try_compile "$LINENO"; then : 28931 28932 # Check for potential -arch flags. It is not universal unless 28933 # there are at least two -arch flags with different values. 28934 ac_arch= 28935 ac_prev= 28936 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 28937 if test -n "$ac_prev"; then 28938 case $ac_word in 28939 i?86 | x86_64 | ppc | ppc64) 28940 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 28941 ac_arch=$ac_word 28942 else 28943 ac_cv_c_bigendian=universal 28944 break 28945 fi 28946 ;; 28947 esac 28948 ac_prev= 28949 elif test "x$ac_word" = "x-arch"; then 28950 ac_prev=arch 28951 fi 28952 done 28953 fi 28954 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 28955 if test $ac_cv_c_bigendian = unknown; then 28956 # See if sys/param.h defines the BYTE_ORDER macro. 28957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28958 /* end confdefs.h. */ 28959 #include <sys/types.h> 28960 #include <sys/param.h> 28961 28962 int 28963 main () 28964 { 28965 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 28966 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 28967 && LITTLE_ENDIAN) 28968 bogus endian macros 28969 #endif 28970 28971 ; 28972 return 0; 28973 } 28974 _ACEOF 28975 if ac_fn_cxx_try_compile "$LINENO"; then : 28976 # It does; now see whether it defined to BIG_ENDIAN or not. 28977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 28978 /* end confdefs.h. */ 28979 #include <sys/types.h> 28980 #include <sys/param.h> 28981 28982 int 28983 main () 28984 { 28985 #if BYTE_ORDER != BIG_ENDIAN 28986 not big endian 28987 #endif 28988 28989 ; 28990 return 0; 28991 } 28992 _ACEOF 28993 if ac_fn_cxx_try_compile "$LINENO"; then : 28994 ac_cv_c_bigendian=yes 28995 else 28996 ac_cv_c_bigendian=no 28997 fi 28998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 28999 fi 29000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29001 fi 29002 if test $ac_cv_c_bigendian = unknown; then 29003 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 29004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29005 /* end confdefs.h. */ 29006 #include <limits.h> 29007 29008 int 29009 main () 29010 { 29011 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 29012 bogus endian macros 29013 #endif 29014 29015 ; 29016 return 0; 29017 } 29018 _ACEOF 29019 if ac_fn_cxx_try_compile "$LINENO"; then : 29020 # It does; now see whether it defined to _BIG_ENDIAN or not. 29021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29022 /* end confdefs.h. */ 29023 #include <limits.h> 29024 29025 int 29026 main () 29027 { 29028 #ifndef _BIG_ENDIAN 29029 not big endian 29030 #endif 29031 29032 ; 29033 return 0; 29034 } 29035 _ACEOF 29036 if ac_fn_cxx_try_compile "$LINENO"; then : 29037 ac_cv_c_bigendian=yes 29038 else 29039 ac_cv_c_bigendian=no 29040 fi 29041 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29042 fi 29043 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29044 fi 29045 if test $ac_cv_c_bigendian = unknown; then 29046 # Compile a test program. 29047 if test "$cross_compiling" = yes; then : 29048 # Try to guess by grepping values from an object file. 29049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29050 /* end confdefs.h. */ 29051 short int ascii_mm[] = 29052 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 29053 short int ascii_ii[] = 29054 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 29055 int use_ascii (int i) { 29056 return ascii_mm[i] + ascii_ii[i]; 29057 } 29058 short int ebcdic_ii[] = 29059 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 29060 short int ebcdic_mm[] = 29061 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 29062 int use_ebcdic (int i) { 29063 return ebcdic_mm[i] + ebcdic_ii[i]; 29064 } 29065 extern int foo; 29066 29067 int 29068 main () 29069 { 29070 return use_ascii (foo) == use_ebcdic (foo); 29071 ; 29072 return 0; 29073 } 29074 _ACEOF 29075 if ac_fn_cxx_try_compile "$LINENO"; then : 29076 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 29077 ac_cv_c_bigendian=yes 29078 fi 29079 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 29080 if test "$ac_cv_c_bigendian" = unknown; then 29081 ac_cv_c_bigendian=no 29082 else 29083 # finding both strings is unlikely to happen, but who knows? 29084 ac_cv_c_bigendian=unknown 29085 fi 29086 fi 29087 fi 29088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29089 else 29090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29091 /* end confdefs.h. */ 29092 $ac_includes_default 29093 int 29094 main () 29095 { 29096 29097 /* Are we little or big endian? From Harbison&Steele. */ 29098 union 29099 { 29100 long int l; 29101 char c[sizeof (long int)]; 29102 } u; 29103 u.l = 1; 29104 return u.c[sizeof (long int) - 1] == 1; 29105 29106 ; 29107 return 0; 29108 } 29109 _ACEOF 29110 if ac_fn_cxx_try_run "$LINENO"; then : 29111 ac_cv_c_bigendian=no 29112 else 29113 ac_cv_c_bigendian=yes 29114 fi 29115 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 29116 conftest.$ac_objext conftest.beam conftest.$ac_ext 29117 fi 29118 29119 fi 29120 fi 29121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 29122 $as_echo "$ac_cv_c_bigendian" >&6; } 29123 case $ac_cv_c_bigendian in #( 29124 yes) 29125 ENDIAN="big";; #( 29126 no) 29127 ENDIAN="little" ;; #( 29128 universal) 29129 ENDIAN="universal_endianness" 29130 ;; #( 29131 *) 29132 ENDIAN="unknown" ;; 29133 esac 29134 29135 29136 if test "x$ENDIAN" = xuniversal_endianness; then 29137 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 29138 fi 29139 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 29140 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 29141 fi 29142 29143 29144 # Configure flags for the tools 29145 29146 29147 ############################################################################### 29148 # 29149 # How to compile shared libraries. 29150 # 29151 29152 if test "x$GCC" = xyes; then 29153 COMPILER_NAME=gcc 29154 PICFLAG="-fPIC" 29155 LIBRARY_PREFIX=lib 29156 SHARED_LIBRARY='lib$1.so' 29157 STATIC_LIBRARY='lib$1.a' 29158 SHARED_LIBRARY_FLAGS="-shared" 29159 SHARED_LIBRARY_SUFFIX='.so' 29160 STATIC_LIBRARY_SUFFIX='.a' 29161 OBJ_SUFFIX='.o' 29162 EXE_SUFFIX='' 29163 SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1' 29164 SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1' 29165 C_FLAG_REORDER='' 29166 CXX_FLAG_REORDER='' 29167 SET_SHARED_LIBRARY_ORIGIN='-Xlinker -z -Xlinker origin -Xlinker -rpath -Xlinker \$$$$ORIGIN$1' 29168 SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1' 29169 LD="$CC" 29170 LDEXE="$CC" 29171 LDCXX="$CXX" 29172 LDEXECXX="$CXX" 29173 POST_STRIP_CMD="$STRIP -g" 29174 29175 # Linking is different on MacOSX 29176 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29177 # Might change in the future to clang. 29178 COMPILER_NAME=gcc 29179 SHARED_LIBRARY='lib$1.dylib' 29180 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 29181 SHARED_LIBRARY_SUFFIX='.dylib' 29182 EXE_SUFFIX='' 29183 SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1' 29184 SET_SHARED_LIBRARY_MAPFILE='' 29185 SET_SHARED_LIBRARY_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.' 29186 SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN" 29187 POST_STRIP_CMD="$STRIP -S" 29188 fi 29189 else 29190 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29191 # If it is not gcc, then assume it is the Oracle Solaris Studio Compiler 29192 COMPILER_NAME=ossc 29193 PICFLAG="-KPIC" 29194 LIBRARY_PREFIX=lib 29195 SHARED_LIBRARY='lib$1.so' 29196 STATIC_LIBRARY='lib$1.a' 29197 SHARED_LIBRARY_FLAGS="-G" 29198 SHARED_LIBRARY_SUFFIX='.so' 29199 STATIC_LIBRARY_SUFFIX='.a' 29200 OBJ_SUFFIX='.o' 29201 EXE_SUFFIX='' 29202 SET_SHARED_LIBRARY_NAME='' 29203 SET_SHARED_LIBRARY_MAPFILE='-M$1' 29204 C_FLAG_REORDER='-xF' 29205 CXX_FLAG_REORDER='-xF' 29206 SET_SHARED_LIBRARY_ORIGIN='-R\$$$$ORIGIN$1' 29207 SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN" 29208 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 29209 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 29210 CFLAGS_JDKLIB_EXTRA='-xstrconst' 29211 POST_STRIP_CMD="$STRIP -x" 29212 POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\"" 29213 fi 29214 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29215 # If it is not gcc, then assume it is the MS Visual Studio compiler 29216 COMPILER_NAME=cl 29217 PICFLAG="" 29218 LIBRARY_PREFIX= 29219 SHARED_LIBRARY='$1.dll' 29220 STATIC_LIBRARY='$1.lib' 29221 SHARED_LIBRARY_FLAGS="-LD" 29222 SHARED_LIBRARY_SUFFIX='.dll' 29223 STATIC_LIBRARY_SUFFIX='.lib' 29224 OBJ_SUFFIX='.obj' 29225 EXE_SUFFIX='.exe' 29226 SET_SHARED_LIBRARY_NAME='' 29227 SET_SHARED_LIBRARY_MAPFILE='' 29228 SET_SHARED_LIBRARY_ORIGIN='' 29229 SET_EXECUTABLE_ORIGIN='' 29230 fi 29231 fi 29232 29233 29234 29235 29236 29237 29238 29239 29240 29241 29242 29243 29244 29245 29246 29247 29248 29249 29250 29251 # The (cross) compiler is now configured, we can now test capabilities 29252 # of the target platform. 29253 29254 29255 29256 ############################################################################### 29257 # 29258 # Setup the opt flags for different compilers 29259 # and different operating systems. 29260 # 29261 29262 # 29263 # NOTE: check for -mstackrealign needs to be below potential addition of -m32 29264 # 29265 if test "x$OPENJDK_TARGET_CPU_BITS" = x32 && test "x$OPENJDK_TARGET_OS" = xmacosx; then 29266 # On 32-bit MacOSX the OS requires C-entry points to be 16 byte aligned. 29267 # While waiting for a better solution, the current workaround is to use -mstackrealign. 29268 CFLAGS="$CFLAGS -mstackrealign" 29269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if 32-bit compiler supports -mstackrealign" >&5 29270 $as_echo_n "checking if 32-bit compiler supports -mstackrealign... " >&6; } 29271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29272 /* end confdefs.h. */ 29273 int main() { return 0; } 29274 _ACEOF 29275 if ac_fn_cxx_try_link "$LINENO"; then : 29276 29277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 29278 $as_echo "yes" >&6; } 29279 29280 else 29281 29282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29283 $as_echo "no" >&6; } 29284 as_fn_error $? "The selected compiler $CXX does not support -mstackrealign! Try to put another compiler in the path." "$LINENO" 5 29285 29286 fi 29287 rm -f core conftest.err conftest.$ac_objext \ 29288 conftest$ac_exeext conftest.$ac_ext 29289 fi 29290 29291 C_FLAG_DEPS="-MMD -MF" 29292 CXX_FLAG_DEPS="-MMD -MF" 29293 29294 case $COMPILER_TYPE in 29295 CC ) 29296 case $COMPILER_NAME in 29297 gcc ) 29298 case $OPENJDK_TARGET_OS in 29299 macosx ) 29300 # On MacOSX we optimize for size, something 29301 # we should do for all platforms? 29302 C_O_FLAG_HI="-Os" 29303 C_O_FLAG_NORM="-Os" 29304 C_O_FLAG_NONE="" 29305 ;; 29306 *) 29307 C_O_FLAG_HI="-O3" 29308 C_O_FLAG_NORM="-O2" 29309 C_O_FLAG_NONE="-O0" 29310 ;; 29311 esac 29312 CXX_O_FLAG_HI="$C_O_FLAG_HI" 29313 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 29314 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 29315 CFLAGS_DEBUG_SYMBOLS="-g" 29316 CXXFLAGS_DEBUG_SYMBOLS="-g" 29317 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 29318 CFLAGS_DEBUG_SYMBOLS="-g1" 29319 CXXFLAGS_DEBUG_SYMBOLS="-g1" 29320 fi 29321 ;; 29322 ossc ) 29323 # 29324 # Forte has different names for this with their C++ compiler... 29325 # 29326 C_FLAG_DEPS="-xMMD -xMF" 29327 CXX_FLAG_DEPS="-xMMD -xMF" 29328 29329 # Extra options used with HIGHEST 29330 # 29331 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 29332 # done with care, there are some assumptions below that need to 29333 # be understood about the use of pointers, and IEEE behavior. 29334 # 29335 # Use non-standard floating point mode (not IEEE 754) 29336 CC_HIGHEST="$CC_HIGHEST -fns" 29337 # Do some simplification of floating point arithmetic (not IEEE 754) 29338 CC_HIGHEST="$CC_HIGHEST -fsimple" 29339 # Use single precision floating point with 'float' 29340 CC_HIGHEST="$CC_HIGHEST -fsingle" 29341 # Assume memory references via basic pointer types do not alias 29342 # (Source with excessing pointer casting and data access with mixed 29343 # pointer types are not recommended) 29344 CC_HIGHEST="$CC_HIGHEST -xalias_level=basic" 29345 # Use intrinsic or inline versions for math/std functions 29346 # (If you expect perfect errno behavior, do not use this) 29347 CC_HIGHEST="$CC_HIGHEST -xbuiltin=%all" 29348 # Loop data dependency optimizations (need -xO3 or higher) 29349 CC_HIGHEST="$CC_HIGHEST -xdepend" 29350 # Pointer parameters to functions do not overlap 29351 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 29352 # If you pass in multiple pointers to the same data, do not use this) 29353 CC_HIGHEST="$CC_HIGHEST -xrestrict" 29354 # Inline some library routines 29355 # (If you expect perfect errno behavior, do not use this) 29356 CC_HIGHEST="$CC_HIGHEST -xlibmil" 29357 # Use optimized math routines 29358 # (If you expect perfect errno behavior, do not use this) 29359 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 29360 #CC_HIGHEST="$CC_HIGHEST -xlibmopt" 29361 29362 if test "x$OPENJDK_TARGET_CPU" = xsparc; then 29363 CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 29364 CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 29365 fi 29366 29367 case $OPENJDK_TARGET_CPU_ARCH in 29368 x86) 29369 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr" 29370 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 29371 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 29372 C_O_FLAG_NONE="-xregs=no%frameptr" 29373 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 29374 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 29375 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 29376 CXX_O_FLAG_NONE="-xregs=no%frameptr" 29377 if test "x$OPENJDK_TARGET_CPU" = xx86; then 29378 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 29379 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 29380 fi 29381 ;; 29382 sparc) 29383 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 29384 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 29385 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 29386 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 29387 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 29388 C_O_FLAG_NONE="" 29389 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 29390 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 29391 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 29392 CXX_O_FLAG_NONE="" 29393 ;; 29394 esac 29395 29396 CFLAGS_DEBUG_SYMBOLS="-g -xs" 29397 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 29398 esac 29399 ;; 29400 CL ) 29401 C_O_FLAG_HIGHEST="-O2" 29402 C_O_FLAG_HI="-O1" 29403 C_O_FLAG_NORM="-O1" 29404 C_O_FLAG_NONE="-Od" 29405 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 29406 CXX_O_FLAG_HI="$C_O_FLAG_HI" 29407 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 29408 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 29409 ;; 29410 esac 29411 29412 if test -z "$C_O_FLAG_HIGHEST"; then 29413 C_O_FLAG_HIGHEST="$C_O_FLAG_HI" 29414 fi 29415 29416 if test -z "$CXX_O_FLAG_HIGHEST"; then 29417 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HI" 29418 fi 29419 29420 29421 29422 29423 29424 29425 29426 29427 29428 29429 29430 29431 29432 29433 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 29434 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 29435 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 29436 fi 29437 29438 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 29439 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 29440 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 29441 fi 29442 29443 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 29444 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 29445 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 29446 fi 29447 29448 29449 # Check whether --with-extra-cflags was given. 29450 if test "${with_extra_cflags+set}" = set; then : 29451 withval=$with_extra_cflags; 29452 fi 29453 29454 29455 29456 # Check whether --with-extra-cxxflags was given. 29457 if test "${with_extra_cxxflags+set}" = set; then : 29458 withval=$with_extra_cxxflags; 29459 fi 29460 29461 29462 29463 # Check whether --with-extra-ldflags was given. 29464 if test "${with_extra_ldflags+set}" = set; then : 29465 withval=$with_extra_ldflags; 29466 fi 29467 29468 29469 CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags" 29470 CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags" 29471 LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags" 29472 29473 # Hotspot needs these set in their legacy form 29474 LEGACY_EXTRA_CFLAGS=$with_extra_cflags 29475 LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags 29476 LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags 29477 29478 29479 29480 29481 29482 ############################################################################### 29483 # 29484 # Now setup the CFLAGS and LDFLAGS for the JDK build. 29485 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 29486 # 29487 case $COMPILER_NAME in 29488 gcc ) 29489 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -W -Wall -Wno-unused -Wno-parentheses \ 29490 -pipe \ 29491 -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 29492 case $OPENJDK_TARGET_CPU_ARCH in 29493 arm ) 29494 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 29495 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 29496 ;; 29497 ppc ) 29498 # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing 29499 ;; 29500 * ) 29501 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer" 29502 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 29503 ;; 29504 esac 29505 ;; 29506 ossc ) 29507 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 29508 case $OPENJDK_TARGET_CPU_ARCH in 29509 x86 ) 29510 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 29511 CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE" 29512 ;; 29513 esac 29514 29515 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 29516 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 29517 29518 LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext" 29519 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib" 29520 ;; 29521 cl ) 29522 CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \ 29523 -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \ 29524 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 29525 -DWIN32 -DIAL" 29526 case $OPENJDK_TARGET_CPU in 29527 x86 ) 29528 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86" 29529 ;; 29530 x86_64 ) 29531 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64" 29532 ;; 29533 esac 29534 ;; 29535 esac 29536 29537 ############################################################################### 29538 29539 # Adjust flags according to debug level. 29540 case $DEBUG_LEVEL in 29541 fastdebug ) 29542 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS" 29543 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS" 29544 C_O_FLAG_HI="$C_O_FLAG_NORM" 29545 C_O_FLAG_NORM="$C_O_FLAG_NORM" 29546 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 29547 CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM" 29548 JAVAC_FLAGS="$JAVAC_FLAGS -g" 29549 ;; 29550 slowdebug ) 29551 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS" 29552 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS" 29553 C_O_FLAG_HI="$C_O_FLAG_NONE" 29554 C_O_FLAG_NORM="$C_O_FLAG_NONE" 29555 CXX_O_FLAG_HI="$CXX_O_FLAG_NONE" 29556 CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE" 29557 JAVAC_FLAGS="$JAVAC_FLAGS -g" 29558 ;; 29559 esac 29560 29561 CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64" 29562 29563 # The package path is used only on macosx? 29564 PACKAGE_PATH=/opt/local 29565 29566 29567 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 29568 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 29569 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 29570 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 29571 # Note: -Dmacro is the same as #define macro 1 29572 # -Dmacro= is the same as #define macro 29573 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29574 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 29575 else 29576 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 29577 fi 29578 else 29579 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN" 29580 fi 29581 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29582 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DLINUX" 29583 fi 29584 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29585 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DWINDOWS" 29586 fi 29587 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29588 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DSOLARIS" 29589 fi 29590 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29591 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMACOSX -D_ALLBSD_SOURCE" 29592 # Setting these parameters makes it an error to link to macosx APIs that are 29593 # newer than the given OS version and makes the linked binaries compatible even 29594 # if built on a newer version of the OS. 29595 # The expected format is X.Y.Z 29596 MACOSX_VERSION_MIN=10.7.0 29597 29598 # The macro takes the version with no dots, ex: 1070 29599 # Let the flags variables get resolved in make for easier override on make 29600 # command line. 29601 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 29602 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 29603 fi 29604 if test "x$OPENJDK_TARGET_OS" = xbsd; then 29605 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DBSD -D_ALLBSD_SOURCE" 29606 fi 29607 if test "x$DEBUG_LEVEL" = xrelease; then 29608 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG" 29609 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29610 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED" 29611 fi 29612 else 29613 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG" 29614 fi 29615 29616 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 29617 CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"$RELEASE\"'" 29618 29619 CCXXFLAGS_JDK="$CCXXFLAGS_JDK \ 29620 -I${JDK_OUTPUTDIR}/include \ 29621 -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \ 29622 -I${JDK_TOPDIR}/src/share/javavm/export \ 29623 -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/javavm/export \ 29624 -I${JDK_TOPDIR}/src/share/native/common \ 29625 -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common" 29626 29627 # The shared libraries are compiled using the picflag. 29628 CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 29629 CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA " 29630 29631 # Executable flags 29632 CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK" 29633 CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK" 29634 29635 # Now this is odd. The JDK native libraries have to link against libjvm.so 29636 # On 32-bit machines there is normally two distinct libjvm.so:s, client and server. 29637 # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library 29638 # is identical for client and server? Yes. Which is picked at runtime (client or server)? 29639 # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following 29640 # libraries will link to whatever is in memory. Yuck. 29641 # 29642 # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh. 29643 if test "x$COMPILER_NAME" = xcl; then 29644 LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no" 29645 if test "x$OPENJDK_TARGET_CPU" = xx86; then 29646 LDFLAGS_JDK="$LDFLAGS_JDK -safeseh" 29647 fi 29648 # TODO: make -debug optional "--disable-full-debug-symbols" 29649 LDFLAGS_JDK="$LDFLAGS_JDK -debug" 29650 LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib" 29651 LDFLAGS_JDKLIB_SUFFIX="" 29652 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 29653 LDFLAGS_STACK_SIZE=1048576 29654 else 29655 LDFLAGS_STACK_SIZE=327680 29656 fi 29657 LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE" 29658 else 29659 if test "x$COMPILER_NAME" = xgcc; then 29660 # If this is a --hash-style=gnu system, use --hash-style=both, why? 29661 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 29662 if test -n "$HAS_GNU_HASH"; then 29663 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both " 29664 fi 29665 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29666 # And since we now know that the linker is gnu, then add -z defs, to forbid 29667 # undefined symbols in object files. 29668 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs" 29669 if test "x$DEBUG_LEVEL" = "xrelease"; then 29670 # When building release libraries, tell the linker optimize them. 29671 # Should this be supplied to the OSS linker as well? 29672 LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1" 29673 fi 29674 fi 29675 fi 29676 LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \ 29677 -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}" 29678 29679 # On some platforms (mac) the linker warns about non existing -L dirs. 29680 # Add server first if available. Linking aginst client does not always produce the same results. 29681 # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1. 29682 # Default to server for other variants. 29683 if test "x$JVM_VARIANT_SERVER" = xtrue; then 29684 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server" 29685 elif test "x$JVM_VARIANT_CLIENT" = xtrue; then 29686 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client" 29687 elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 29688 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal" 29689 else 29690 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server" 29691 fi 29692 29693 LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm" 29694 if test "x$COMPILER_NAME" = xossc; then 29695 LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc" 29696 fi 29697 29698 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 29699 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29700 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined" 29701 fi 29702 fi 29703 29704 29705 29706 29707 29708 29709 29710 29711 29712 29713 29714 29715 29716 29717 29718 # Some Zero and Shark settings. 29719 # ZERO_ARCHFLAG tells the compiler which mode to build for 29720 case "${OPENJDK_TARGET_CPU}" in 29721 s390) 29722 ZERO_ARCHFLAG="-m31" 29723 ;; 29724 *) 29725 ZERO_ARCHFLAG="-m${OPENJDK_TARGET_CPU_BITS}" 29726 esac 29727 29728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5 29729 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 29730 supports=yes 29731 29732 saved_cflags="$CFLAGS" 29733 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 29734 ac_ext=c 29735 ac_cpp='$CPP $CPPFLAGS' 29736 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29737 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29738 ac_compiler_gnu=$ac_cv_c_compiler_gnu 29739 29740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29741 /* end confdefs.h. */ 29742 29743 int i; 29744 29745 _ACEOF 29746 if ac_fn_c_try_compile "$LINENO"; then : 29747 29748 else 29749 supports=no 29750 fi 29751 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29752 ac_ext=cpp 29753 ac_cpp='$CXXCPP $CPPFLAGS' 29754 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29755 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29756 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29757 29758 CFLAGS="$saved_cflags" 29759 29760 saved_cxxflags="$CXXFLAGS" 29761 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 29762 ac_ext=cpp 29763 ac_cpp='$CXXCPP $CPPFLAGS' 29764 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29765 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29766 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29767 29768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29769 /* end confdefs.h. */ 29770 29771 int i; 29772 29773 _ACEOF 29774 if ac_fn_cxx_try_compile "$LINENO"; then : 29775 29776 else 29777 supports=no 29778 fi 29779 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29780 ac_ext=cpp 29781 ac_cpp='$CXXCPP $CPPFLAGS' 29782 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29783 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29784 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29785 29786 CXXFLAGS="$saved_cxxflags" 29787 29788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 29789 $as_echo "$supports" >&6; } 29790 if test "x$supports" = "xyes" ; then 29791 : 29792 else 29793 ZERO_ARCHFLAG="" 29794 fi 29795 29796 29797 29798 # Check that the compiler supports -mX flags 29799 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 29800 29801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"-m${OPENJDK_TARGET_CPU_BITS}\"" >&5 29802 $as_echo_n "checking if compiler supports \"-m${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 29803 supports=yes 29804 29805 saved_cflags="$CFLAGS" 29806 CFLAGS="$CFLAGS -m${OPENJDK_TARGET_CPU_BITS}" 29807 ac_ext=c 29808 ac_cpp='$CPP $CPPFLAGS' 29809 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29810 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29811 ac_compiler_gnu=$ac_cv_c_compiler_gnu 29812 29813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29814 /* end confdefs.h. */ 29815 29816 int i; 29817 29818 _ACEOF 29819 if ac_fn_c_try_compile "$LINENO"; then : 29820 29821 else 29822 supports=no 29823 fi 29824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29825 ac_ext=cpp 29826 ac_cpp='$CXXCPP $CPPFLAGS' 29827 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29828 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29829 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29830 29831 CFLAGS="$saved_cflags" 29832 29833 saved_cxxflags="$CXXFLAGS" 29834 CXXFLAGS="$CXXFLAG -m${OPENJDK_TARGET_CPU_BITS}" 29835 ac_ext=cpp 29836 ac_cpp='$CXXCPP $CPPFLAGS' 29837 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29838 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29839 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29840 29841 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 29842 /* end confdefs.h. */ 29843 29844 int i; 29845 29846 _ACEOF 29847 if ac_fn_cxx_try_compile "$LINENO"; then : 29848 29849 else 29850 supports=no 29851 fi 29852 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 29853 ac_ext=cpp 29854 ac_cpp='$CXXCPP $CPPFLAGS' 29855 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29856 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29857 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29858 29859 CXXFLAGS="$saved_cxxflags" 29860 29861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 29862 $as_echo "$supports" >&6; } 29863 if test "x$supports" = "xyes" ; then 29864 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 29865 else 29866 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 29867 fi 29868 29869 29870 29871 29872 # Setup debug symbols (need objcopy from the toolchain for that) 29873 29874 # 29875 # ENABLE_DEBUG_SYMBOLS 29876 # This must be done after the toolchain is setup, since we're looking at objcopy. 29877 # 29878 # Check whether --enable-debug-symbols was given. 29879 if test "${enable_debug_symbols+set}" = set; then : 29880 enableval=$enable_debug_symbols; 29881 fi 29882 29883 29884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5 29885 $as_echo_n "checking if we should generate debug symbols... " >&6; } 29886 29887 if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then 29888 # explicit enabling of enable-debug-symbols and can't find objcopy 29889 # this is an error 29890 as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5 29891 fi 29892 29893 if test "x$enable_debug_symbols" = "xyes"; then 29894 ENABLE_DEBUG_SYMBOLS=true 29895 elif test "x$enable_debug_symbols" = "xno"; then 29896 ENABLE_DEBUG_SYMBOLS=false 29897 else 29898 # default on macosx is false 29899 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29900 ENABLE_DEBUG_SYMBOLS=false 29901 # Default is on if objcopy is found, otherwise off 29902 elif test "x$OBJCOPY" != x || test "x$OPENJDK_TARGET_OS" = xwindows; then 29903 ENABLE_DEBUG_SYMBOLS=true 29904 else 29905 ENABLE_DEBUG_SYMBOLS=false 29906 fi 29907 fi 29908 29909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5 29910 $as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; } 29911 29912 # 29913 # ZIP_DEBUGINFO_FILES 29914 # 29915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5 29916 $as_echo_n "checking if we should zip debug-info files... " >&6; } 29917 # Check whether --enable-zip-debug-info was given. 29918 if test "${enable_zip_debug_info+set}" = set; then : 29919 enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}" 29920 else 29921 enable_zip_debug_info="yes" 29922 fi 29923 29924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5 29925 $as_echo "${enable_zip_debug_info}" >&6; } 29926 29927 if test "x${enable_zip_debug_info}" = "xno"; then 29928 ZIP_DEBUGINFO_FILES=false 29929 else 29930 ZIP_DEBUGINFO_FILES=true 29931 fi 29932 29933 29934 29935 29936 29937 29938 29939 ############################################################################### 29940 # 29941 # Check dependencies for external and internal libraries. 29942 # 29943 ############################################################################### 29944 29945 29946 29947 ############################################################################### 29948 # 29949 # OS specific settings that we never will need to probe. 29950 # 29951 if test "x$OPENJDK_TARGET_OS" = xlinux; then 29952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5 29953 $as_echo_n "checking what is not needed on Linux?... " >&6; } 29954 PULSE_NOT_NEEDED=yes 29955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5 29956 $as_echo "pulse" >&6; } 29957 fi 29958 29959 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5 29961 $as_echo_n "checking what is not needed on Solaris?... " >&6; } 29962 ALSA_NOT_NEEDED=yes 29963 PULSE_NOT_NEEDED=yes 29964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5 29965 $as_echo "alsa pulse" >&6; } 29966 fi 29967 29968 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5 29970 $as_echo_n "checking what is not needed on Windows?... " >&6; } 29971 CUPS_NOT_NEEDED=yes 29972 ALSA_NOT_NEEDED=yes 29973 PULSE_NOT_NEEDED=yes 29974 X11_NOT_NEEDED=yes 29975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5 29976 $as_echo "alsa cups pulse x11" >&6; } 29977 fi 29978 29979 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5 29981 $as_echo_n "checking what is not needed on MacOSX?... " >&6; } 29982 ALSA_NOT_NEEDED=yes 29983 PULSE_NOT_NEEDED=yes 29984 X11_NOT_NEEDED=yes 29985 FREETYPE2_NOT_NEEDED=yes 29986 # If the java runtime framework is disabled, then we need X11. 29987 # This will be adjusted below. 29988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5 29989 $as_echo "alsa pulse x11" >&6; } 29990 fi 29991 29992 if test "x$OPENJDK_TARGET_OS" = xbsd; then 29993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5 29994 $as_echo_n "checking what is not needed on bsd?... " >&6; } 29995 ALSA_NOT_NEEDED=yes 29996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5 29997 $as_echo "alsa" >&6; } 29998 fi 29999 30000 if test "x$OPENJDK" = "xfalse"; then 30001 FREETYPE2_NOT_NEEDED=yes 30002 fi 30003 30004 if test "x$SUPPORT_HEADFUL" = xno; then 30005 X11_NOT_NEEDED=yes 30006 fi 30007 30008 ############################################################################### 30009 # 30010 # Check for MacOSX support for OpenJDK. If this exists, try to build a JVM 30011 # that uses this API. 30012 # 30013 # Check whether --enable-macosx-runtime-support was given. 30014 if test "${enable_macosx_runtime_support+set}" = set; then : 30015 enableval=$enable_macosx_runtime_support; MACOSX_RUNTIME_SUPPORT="${enableval}" 30016 else 30017 MACOSX_RUNTIME_SUPPORT="no" 30018 fi 30019 30020 30021 USE_MACOSX_RUNTIME_SUPPORT=no 30022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for explicit Java runtime support in the OS" >&5 30023 $as_echo_n "checking for explicit Java runtime support in the OS... " >&6; } 30024 if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then 30025 if test "x$MACOSX_RUNTIME_SUPPORT" != xno; then 30026 MACOSX_RUNTIME_SUPPORT=yes 30027 USE_MACOSX_RUNTIME_SUPPORT=yes 30028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, does not need alsa freetype2 pulse and X11" >&5 30029 $as_echo "yes, does not need alsa freetype2 pulse and X11" >&6; } 30030 else 30031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, but explicitly disabled." >&5 30032 $as_echo "yes, but explicitly disabled." >&6; } 30033 fi 30034 else 30035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30036 $as_echo "no" >&6; } 30037 fi 30038 30039 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$USE_MACOSX_RUNTIME_SUPPORT" = xno; then 30040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on an X11 build on MacOSX?" >&5 30041 $as_echo_n "checking what is not needed on an X11 build on MacOSX?... " >&6; } 30042 X11_NOT_NEEDED= 30043 FREETYPE2_NOT_NEEDED= 30044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5 30045 $as_echo "alsa pulse" >&6; } 30046 fi 30047 30048 30049 30050 ############################################################################### 30051 # 30052 # Check for X Windows 30053 # 30054 30055 # Check if the user has specified sysroot, but not --x-includes or --x-libraries. 30056 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 30057 # --x-libraries for the sysroot, if that seems to be correct. 30058 if test "x$SYS_ROOT" != "x/"; then 30059 if test "x$x_includes" = xNONE; then 30060 if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then 30061 x_includes="$SYS_ROOT/usr/X11R6/include" 30062 elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then 30063 x_includes="$SYS_ROOT/usr/include" 30064 fi 30065 fi 30066 if test "x$x_libraries" = xNONE; then 30067 if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then 30068 x_libraries="$SYS_ROOT/usr/X11R6/lib" 30069 elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 30070 x_libraries="$SYS_ROOT/usr/lib64" 30071 elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then 30072 x_libraries="$SYS_ROOT/usr/lib" 30073 fi 30074 fi 30075 fi 30076 30077 # Now let autoconf do it's magic 30078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 30079 $as_echo_n "checking for X... " >&6; } 30080 30081 30082 # Check whether --with-x was given. 30083 if test "${with_x+set}" = set; then : 30084 withval=$with_x; 30085 fi 30086 30087 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 30088 if test "x$with_x" = xno; then 30089 # The user explicitly disabled X. 30090 have_x=disabled 30091 else 30092 case $x_includes,$x_libraries in #( 30093 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 30094 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 30095 $as_echo_n "(cached) " >&6 30096 else 30097 # One or both of the vars are not set, and there is no cached value. 30098 ac_x_includes=no ac_x_libraries=no 30099 rm -f -r conftest.dir 30100 if mkdir conftest.dir; then 30101 cd conftest.dir 30102 cat >Imakefile <<'_ACEOF' 30103 incroot: 30104 @echo incroot='${INCROOT}' 30105 usrlibdir: 30106 @echo usrlibdir='${USRLIBDIR}' 30107 libdir: 30108 @echo libdir='${LIBDIR}' 30109 _ACEOF 30110 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 30111 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 30112 for ac_var in incroot usrlibdir libdir; do 30113 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 30114 done 30115 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 30116 for ac_extension in a so sl dylib la dll; do 30117 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 30118 test -f "$ac_im_libdir/libX11.$ac_extension"; then 30119 ac_im_usrlibdir=$ac_im_libdir; break 30120 fi 30121 done 30122 # Screen out bogus values from the imake configuration. They are 30123 # bogus both because they are the default anyway, and because 30124 # using them would break gcc on systems where it needs fixed includes. 30125 case $ac_im_incroot in 30126 /usr/include) ac_x_includes= ;; 30127 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 30128 esac 30129 case $ac_im_usrlibdir in 30130 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 30131 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 30132 esac 30133 fi 30134 cd .. 30135 rm -f -r conftest.dir 30136 fi 30137 30138 # Standard set of common directories for X headers. 30139 # Check X11 before X11Rn because it is often a symlink to the current release. 30140 ac_x_header_dirs=' 30141 /usr/X11/include 30142 /usr/X11R7/include 30143 /usr/X11R6/include 30144 /usr/X11R5/include 30145 /usr/X11R4/include 30146 30147 /usr/include/X11 30148 /usr/include/X11R7 30149 /usr/include/X11R6 30150 /usr/include/X11R5 30151 /usr/include/X11R4 30152 30153 /usr/local/X11/include 30154 /usr/local/X11R7/include 30155 /usr/local/X11R6/include 30156 /usr/local/X11R5/include 30157 /usr/local/X11R4/include 30158 30159 /usr/local/include/X11 30160 /usr/local/include/X11R7 30161 /usr/local/include/X11R6 30162 /usr/local/include/X11R5 30163 /usr/local/include/X11R4 30164 30165 /usr/X386/include 30166 /usr/x386/include 30167 /usr/XFree86/include/X11 30168 30169 /usr/include 30170 /usr/local/include 30171 /usr/unsupported/include 30172 /usr/athena/include 30173 /usr/local/x11r5/include 30174 /usr/lpp/Xamples/include 30175 30176 /usr/openwin/include 30177 /usr/openwin/share/include' 30178 30179 if test "$ac_x_includes" = no; then 30180 # Guess where to find include files, by looking for Xlib.h. 30181 # First, try using that file with no special directory specified. 30182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30183 /* end confdefs.h. */ 30184 #include <X11/Xlib.h> 30185 _ACEOF 30186 if ac_fn_cxx_try_cpp "$LINENO"; then : 30187 # We can compile using X headers with no special include directory. 30188 ac_x_includes= 30189 else 30190 for ac_dir in $ac_x_header_dirs; do 30191 if test -r "$ac_dir/X11/Xlib.h"; then 30192 ac_x_includes=$ac_dir 30193 break 30194 fi 30195 done 30196 fi 30197 rm -f conftest.err conftest.i conftest.$ac_ext 30198 fi # $ac_x_includes = no 30199 30200 if test "$ac_x_libraries" = no; then 30201 # Check for the libraries. 30202 # See if we find them without any special options. 30203 # Don't add to $LIBS permanently. 30204 ac_save_LIBS=$LIBS 30205 LIBS="-lX11 $LIBS" 30206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30207 /* end confdefs.h. */ 30208 #include <X11/Xlib.h> 30209 int 30210 main () 30211 { 30212 XrmInitialize () 30213 ; 30214 return 0; 30215 } 30216 _ACEOF 30217 if ac_fn_cxx_try_link "$LINENO"; then : 30218 LIBS=$ac_save_LIBS 30219 # We can link X programs with no special library path. 30220 ac_x_libraries= 30221 else 30222 LIBS=$ac_save_LIBS 30223 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 30224 do 30225 # Don't even attempt the hair of trying to link an X program! 30226 for ac_extension in a so sl dylib la dll; do 30227 if test -r "$ac_dir/libX11.$ac_extension"; then 30228 ac_x_libraries=$ac_dir 30229 break 2 30230 fi 30231 done 30232 done 30233 fi 30234 rm -f core conftest.err conftest.$ac_objext \ 30235 conftest$ac_exeext conftest.$ac_ext 30236 fi # $ac_x_libraries = no 30237 30238 case $ac_x_includes,$ac_x_libraries in #( 30239 no,* | *,no | *\'*) 30240 # Didn't find X, or a directory has "'" in its name. 30241 ac_cv_have_x="have_x=no";; #( 30242 *) 30243 # Record where we found X for the cache. 30244 ac_cv_have_x="have_x=yes\ 30245 ac_x_includes='$ac_x_includes'\ 30246 ac_x_libraries='$ac_x_libraries'" 30247 esac 30248 fi 30249 ;; #( 30250 *) have_x=yes;; 30251 esac 30252 eval "$ac_cv_have_x" 30253 fi # $with_x != no 30254 30255 if test "$have_x" != yes; then 30256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 30257 $as_echo "$have_x" >&6; } 30258 no_x=yes 30259 else 30260 # If each of the values was on the command line, it overrides each guess. 30261 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 30262 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 30263 # Update the cache value to reflect the command line values. 30264 ac_cv_have_x="have_x=yes\ 30265 ac_x_includes='$x_includes'\ 30266 ac_x_libraries='$x_libraries'" 30267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 30268 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 30269 fi 30270 30271 if test "$no_x" = yes; then 30272 # Not all programs may use this symbol, but it does not hurt to define it. 30273 30274 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 30275 30276 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 30277 else 30278 if test -n "$x_includes"; then 30279 X_CFLAGS="$X_CFLAGS -I$x_includes" 30280 fi 30281 30282 # It would also be nice to do this for all -L options, not just this one. 30283 if test -n "$x_libraries"; then 30284 X_LIBS="$X_LIBS -L$x_libraries" 30285 # For Solaris; some versions of Sun CC require a space after -R and 30286 # others require no space. Words are not sufficient . . . . 30287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 30288 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 30289 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 30290 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 30291 ac_cxx_werror_flag=yes 30292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30293 /* end confdefs.h. */ 30294 30295 int 30296 main () 30297 { 30298 30299 ; 30300 return 0; 30301 } 30302 _ACEOF 30303 if ac_fn_cxx_try_link "$LINENO"; then : 30304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30305 $as_echo "no" >&6; } 30306 X_LIBS="$X_LIBS -R$x_libraries" 30307 else 30308 LIBS="$ac_xsave_LIBS -R $x_libraries" 30309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30310 /* end confdefs.h. */ 30311 30312 int 30313 main () 30314 { 30315 30316 ; 30317 return 0; 30318 } 30319 _ACEOF 30320 if ac_fn_cxx_try_link "$LINENO"; then : 30321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30322 $as_echo "yes" >&6; } 30323 X_LIBS="$X_LIBS -R $x_libraries" 30324 else 30325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 30326 $as_echo "neither works" >&6; } 30327 fi 30328 rm -f core conftest.err conftest.$ac_objext \ 30329 conftest$ac_exeext conftest.$ac_ext 30330 fi 30331 rm -f core conftest.err conftest.$ac_objext \ 30332 conftest$ac_exeext conftest.$ac_ext 30333 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 30334 LIBS=$ac_xsave_LIBS 30335 fi 30336 30337 # Check for system-dependent libraries X programs must link with. 30338 # Do this before checking for the system-independent R6 libraries 30339 # (-lICE), since we may need -lsocket or whatever for X linking. 30340 30341 if test "$ISC" = yes; then 30342 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 30343 else 30344 # Martyn Johnson says this is needed for Ultrix, if the X 30345 # libraries were built with DECnet support. And Karl Berry says 30346 # the Alpha needs dnet_stub (dnet does not exist). 30347 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 30348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30349 /* end confdefs.h. */ 30350 30351 /* Override any GCC internal prototype to avoid an error. 30352 Use char because int might match the return type of a GCC 30353 builtin and then its argument prototype would still apply. */ 30354 #ifdef __cplusplus 30355 extern "C" 30356 #endif 30357 char XOpenDisplay (); 30358 int 30359 main () 30360 { 30361 return XOpenDisplay (); 30362 ; 30363 return 0; 30364 } 30365 _ACEOF 30366 if ac_fn_cxx_try_link "$LINENO"; then : 30367 30368 else 30369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 30370 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 30371 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 30372 $as_echo_n "(cached) " >&6 30373 else 30374 ac_check_lib_save_LIBS=$LIBS 30375 LIBS="-ldnet $LIBS" 30376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30377 /* end confdefs.h. */ 30378 30379 /* Override any GCC internal prototype to avoid an error. 30380 Use char because int might match the return type of a GCC 30381 builtin and then its argument prototype would still apply. */ 30382 #ifdef __cplusplus 30383 extern "C" 30384 #endif 30385 char dnet_ntoa (); 30386 int 30387 main () 30388 { 30389 return dnet_ntoa (); 30390 ; 30391 return 0; 30392 } 30393 _ACEOF 30394 if ac_fn_cxx_try_link "$LINENO"; then : 30395 ac_cv_lib_dnet_dnet_ntoa=yes 30396 else 30397 ac_cv_lib_dnet_dnet_ntoa=no 30398 fi 30399 rm -f core conftest.err conftest.$ac_objext \ 30400 conftest$ac_exeext conftest.$ac_ext 30401 LIBS=$ac_check_lib_save_LIBS 30402 fi 30403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 30404 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 30405 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 30406 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 30407 fi 30408 30409 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 30410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 30411 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 30412 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 30413 $as_echo_n "(cached) " >&6 30414 else 30415 ac_check_lib_save_LIBS=$LIBS 30416 LIBS="-ldnet_stub $LIBS" 30417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30418 /* end confdefs.h. */ 30419 30420 /* Override any GCC internal prototype to avoid an error. 30421 Use char because int might match the return type of a GCC 30422 builtin and then its argument prototype would still apply. */ 30423 #ifdef __cplusplus 30424 extern "C" 30425 #endif 30426 char dnet_ntoa (); 30427 int 30428 main () 30429 { 30430 return dnet_ntoa (); 30431 ; 30432 return 0; 30433 } 30434 _ACEOF 30435 if ac_fn_cxx_try_link "$LINENO"; then : 30436 ac_cv_lib_dnet_stub_dnet_ntoa=yes 30437 else 30438 ac_cv_lib_dnet_stub_dnet_ntoa=no 30439 fi 30440 rm -f core conftest.err conftest.$ac_objext \ 30441 conftest$ac_exeext conftest.$ac_ext 30442 LIBS=$ac_check_lib_save_LIBS 30443 fi 30444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 30445 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 30446 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 30447 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 30448 fi 30449 30450 fi 30451 fi 30452 rm -f core conftest.err conftest.$ac_objext \ 30453 conftest$ac_exeext conftest.$ac_ext 30454 LIBS="$ac_xsave_LIBS" 30455 30456 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 30457 # to get the SysV transport functions. 30458 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 30459 # needs -lnsl. 30460 # The nsl library prevents programs from opening the X display 30461 # on Irix 5.2, according to T.E. Dickey. 30462 # The functions gethostbyname, getservbyname, and inet_addr are 30463 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 30464 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 30465 if test "x$ac_cv_func_gethostbyname" = xyes; then : 30466 30467 fi 30468 30469 if test $ac_cv_func_gethostbyname = no; then 30470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 30471 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 30472 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 30473 $as_echo_n "(cached) " >&6 30474 else 30475 ac_check_lib_save_LIBS=$LIBS 30476 LIBS="-lnsl $LIBS" 30477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30478 /* end confdefs.h. */ 30479 30480 /* Override any GCC internal prototype to avoid an error. 30481 Use char because int might match the return type of a GCC 30482 builtin and then its argument prototype would still apply. */ 30483 #ifdef __cplusplus 30484 extern "C" 30485 #endif 30486 char gethostbyname (); 30487 int 30488 main () 30489 { 30490 return gethostbyname (); 30491 ; 30492 return 0; 30493 } 30494 _ACEOF 30495 if ac_fn_cxx_try_link "$LINENO"; then : 30496 ac_cv_lib_nsl_gethostbyname=yes 30497 else 30498 ac_cv_lib_nsl_gethostbyname=no 30499 fi 30500 rm -f core conftest.err conftest.$ac_objext \ 30501 conftest$ac_exeext conftest.$ac_ext 30502 LIBS=$ac_check_lib_save_LIBS 30503 fi 30504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 30505 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 30506 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 30507 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 30508 fi 30509 30510 if test $ac_cv_lib_nsl_gethostbyname = no; then 30511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 30512 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 30513 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 30514 $as_echo_n "(cached) " >&6 30515 else 30516 ac_check_lib_save_LIBS=$LIBS 30517 LIBS="-lbsd $LIBS" 30518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30519 /* end confdefs.h. */ 30520 30521 /* Override any GCC internal prototype to avoid an error. 30522 Use char because int might match the return type of a GCC 30523 builtin and then its argument prototype would still apply. */ 30524 #ifdef __cplusplus 30525 extern "C" 30526 #endif 30527 char gethostbyname (); 30528 int 30529 main () 30530 { 30531 return gethostbyname (); 30532 ; 30533 return 0; 30534 } 30535 _ACEOF 30536 if ac_fn_cxx_try_link "$LINENO"; then : 30537 ac_cv_lib_bsd_gethostbyname=yes 30538 else 30539 ac_cv_lib_bsd_gethostbyname=no 30540 fi 30541 rm -f core conftest.err conftest.$ac_objext \ 30542 conftest$ac_exeext conftest.$ac_ext 30543 LIBS=$ac_check_lib_save_LIBS 30544 fi 30545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 30546 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 30547 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 30548 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 30549 fi 30550 30551 fi 30552 fi 30553 30554 # lieder@skyler.mavd.honeywell.com says without -lsocket, 30555 # socket/setsockopt and other routines are undefined under SCO ODT 30556 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 30557 # on later versions), says Simon Leinen: it contains gethostby* 30558 # variants that don't use the name server (or something). -lsocket 30559 # must be given before -lnsl if both are needed. We assume that 30560 # if connect needs -lnsl, so does gethostbyname. 30561 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 30562 if test "x$ac_cv_func_connect" = xyes; then : 30563 30564 fi 30565 30566 if test $ac_cv_func_connect = no; then 30567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 30568 $as_echo_n "checking for connect in -lsocket... " >&6; } 30569 if ${ac_cv_lib_socket_connect+:} false; then : 30570 $as_echo_n "(cached) " >&6 30571 else 30572 ac_check_lib_save_LIBS=$LIBS 30573 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 30574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30575 /* end confdefs.h. */ 30576 30577 /* Override any GCC internal prototype to avoid an error. 30578 Use char because int might match the return type of a GCC 30579 builtin and then its argument prototype would still apply. */ 30580 #ifdef __cplusplus 30581 extern "C" 30582 #endif 30583 char connect (); 30584 int 30585 main () 30586 { 30587 return connect (); 30588 ; 30589 return 0; 30590 } 30591 _ACEOF 30592 if ac_fn_cxx_try_link "$LINENO"; then : 30593 ac_cv_lib_socket_connect=yes 30594 else 30595 ac_cv_lib_socket_connect=no 30596 fi 30597 rm -f core conftest.err conftest.$ac_objext \ 30598 conftest$ac_exeext conftest.$ac_ext 30599 LIBS=$ac_check_lib_save_LIBS 30600 fi 30601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 30602 $as_echo "$ac_cv_lib_socket_connect" >&6; } 30603 if test "x$ac_cv_lib_socket_connect" = xyes; then : 30604 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 30605 fi 30606 30607 fi 30608 30609 # Guillermo Gomez says -lposix is necessary on A/UX. 30610 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 30611 if test "x$ac_cv_func_remove" = xyes; then : 30612 30613 fi 30614 30615 if test $ac_cv_func_remove = no; then 30616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 30617 $as_echo_n "checking for remove in -lposix... " >&6; } 30618 if ${ac_cv_lib_posix_remove+:} false; then : 30619 $as_echo_n "(cached) " >&6 30620 else 30621 ac_check_lib_save_LIBS=$LIBS 30622 LIBS="-lposix $LIBS" 30623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30624 /* end confdefs.h. */ 30625 30626 /* Override any GCC internal prototype to avoid an error. 30627 Use char because int might match the return type of a GCC 30628 builtin and then its argument prototype would still apply. */ 30629 #ifdef __cplusplus 30630 extern "C" 30631 #endif 30632 char remove (); 30633 int 30634 main () 30635 { 30636 return remove (); 30637 ; 30638 return 0; 30639 } 30640 _ACEOF 30641 if ac_fn_cxx_try_link "$LINENO"; then : 30642 ac_cv_lib_posix_remove=yes 30643 else 30644 ac_cv_lib_posix_remove=no 30645 fi 30646 rm -f core conftest.err conftest.$ac_objext \ 30647 conftest$ac_exeext conftest.$ac_ext 30648 LIBS=$ac_check_lib_save_LIBS 30649 fi 30650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 30651 $as_echo "$ac_cv_lib_posix_remove" >&6; } 30652 if test "x$ac_cv_lib_posix_remove" = xyes; then : 30653 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 30654 fi 30655 30656 fi 30657 30658 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 30659 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 30660 if test "x$ac_cv_func_shmat" = xyes; then : 30661 30662 fi 30663 30664 if test $ac_cv_func_shmat = no; then 30665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 30666 $as_echo_n "checking for shmat in -lipc... " >&6; } 30667 if ${ac_cv_lib_ipc_shmat+:} false; then : 30668 $as_echo_n "(cached) " >&6 30669 else 30670 ac_check_lib_save_LIBS=$LIBS 30671 LIBS="-lipc $LIBS" 30672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30673 /* end confdefs.h. */ 30674 30675 /* Override any GCC internal prototype to avoid an error. 30676 Use char because int might match the return type of a GCC 30677 builtin and then its argument prototype would still apply. */ 30678 #ifdef __cplusplus 30679 extern "C" 30680 #endif 30681 char shmat (); 30682 int 30683 main () 30684 { 30685 return shmat (); 30686 ; 30687 return 0; 30688 } 30689 _ACEOF 30690 if ac_fn_cxx_try_link "$LINENO"; then : 30691 ac_cv_lib_ipc_shmat=yes 30692 else 30693 ac_cv_lib_ipc_shmat=no 30694 fi 30695 rm -f core conftest.err conftest.$ac_objext \ 30696 conftest$ac_exeext conftest.$ac_ext 30697 LIBS=$ac_check_lib_save_LIBS 30698 fi 30699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 30700 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 30701 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 30702 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 30703 fi 30704 30705 fi 30706 fi 30707 30708 # Check for libraries that X11R6 Xt/Xaw programs need. 30709 ac_save_LDFLAGS=$LDFLAGS 30710 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 30711 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 30712 # check for ICE first), but we must link in the order -lSM -lICE or 30713 # we get undefined symbols. So assume we have SM if we have ICE. 30714 # These have to be linked with before -lX11, unlike the other 30715 # libraries we check for below, so use a different variable. 30716 # John Interrante, Karl Berry 30717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 30718 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 30719 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 30720 $as_echo_n "(cached) " >&6 30721 else 30722 ac_check_lib_save_LIBS=$LIBS 30723 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 30724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 30725 /* end confdefs.h. */ 30726 30727 /* Override any GCC internal prototype to avoid an error. 30728 Use char because int might match the return type of a GCC 30729 builtin and then its argument prototype would still apply. */ 30730 #ifdef __cplusplus 30731 extern "C" 30732 #endif 30733 char IceConnectionNumber (); 30734 int 30735 main () 30736 { 30737 return IceConnectionNumber (); 30738 ; 30739 return 0; 30740 } 30741 _ACEOF 30742 if ac_fn_cxx_try_link "$LINENO"; then : 30743 ac_cv_lib_ICE_IceConnectionNumber=yes 30744 else 30745 ac_cv_lib_ICE_IceConnectionNumber=no 30746 fi 30747 rm -f core conftest.err conftest.$ac_objext \ 30748 conftest$ac_exeext conftest.$ac_ext 30749 LIBS=$ac_check_lib_save_LIBS 30750 fi 30751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 30752 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 30753 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 30754 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 30755 fi 30756 30757 LDFLAGS=$ac_save_LDFLAGS 30758 30759 fi 30760 30761 30762 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 30763 # this doesn't make sense so we remove it. 30764 if test "x$COMPILE_TYPE" = xcross; then 30765 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 30766 fi 30767 30768 if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then 30769 30770 # Print a helpful message on how to acquire the necessary build dependency. 30771 # x11 is the help tag: freetyp2, cups, pulse, alsa etc 30772 MISSING_DEPENDENCY=x11 30773 PKGHANDLER_COMMAND= 30774 30775 case $PKGHANDLER in 30776 apt-get) 30777 apt_help $MISSING_DEPENDENCY ;; 30778 yum) 30779 yum_help $MISSING_DEPENDENCY ;; 30780 port) 30781 port_help $MISSING_DEPENDENCY ;; 30782 pkgutil) 30783 pkgutil_help $MISSING_DEPENDENCY ;; 30784 pkgadd) 30785 pkgadd_help $MISSING_DEPENDENCY ;; 30786 * ) 30787 break ;; 30788 esac 30789 30790 if test "x$PKGHANDLER_COMMAND" != x; then 30791 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30792 fi 30793 30794 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 30795 fi 30796 30797 # Some of the old makefiles require a setting of OPENWIN_HOME 30798 # Since the X11R6 directory has disappeared on later Linuxes, 30799 # we need to probe for it. 30800 if test "x$OPENJDK_TARGET_OS" = xlinux; then 30801 if test -d "$SYS_ROOT/usr/X11R6"; then 30802 OPENWIN_HOME="$SYS_ROOT/usr/X11R6" 30803 elif test -d "$SYS_ROOT/usr/include/X11"; then 30804 OPENWIN_HOME="$SYS_ROOT/usr" 30805 fi 30806 fi 30807 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 30808 OPENWIN_HOME="/usr/openwin" 30809 fi 30810 30811 30812 30813 # 30814 # Weird Sol10 something check...TODO change to try compile 30815 # 30816 if test "x${OPENJDK_TARGET_OS}" = xsolaris; then 30817 if test "`uname -r`" = "5.10"; then 30818 if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then 30819 X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS" 30820 fi 30821 fi 30822 fi 30823 30824 ac_ext=c 30825 ac_cpp='$CPP $CPPFLAGS' 30826 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 30827 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 30828 ac_compiler_gnu=$ac_cv_c_compiler_gnu 30829 30830 OLD_CFLAGS="$CFLAGS" 30831 CFLAGS="$CFLAGS $X_CFLAGS" 30832 30833 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 30834 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h 30835 do : 30836 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 30837 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " # include <X11/Xlib.h> 30838 # include <X11/Xutil.h> 30839 30840 " 30841 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 30842 cat >>confdefs.h <<_ACEOF 30843 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 30844 _ACEOF 30845 X11_A_OK=yes 30846 else 30847 X11_A_OK=no; break 30848 fi 30849 30850 done 30851 30852 30853 CFLAGS="$OLD_CFLAGS" 30854 ac_ext=cpp 30855 ac_cpp='$CXXCPP $CPPFLAGS' 30856 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 30857 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 30858 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 30859 30860 30861 if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then 30862 30863 # Print a helpful message on how to acquire the necessary build dependency. 30864 # x11 is the help tag: freetyp2, cups, pulse, alsa etc 30865 MISSING_DEPENDENCY=x11 30866 PKGHANDLER_COMMAND= 30867 30868 case $PKGHANDLER in 30869 apt-get) 30870 apt_help $MISSING_DEPENDENCY ;; 30871 yum) 30872 yum_help $MISSING_DEPENDENCY ;; 30873 port) 30874 port_help $MISSING_DEPENDENCY ;; 30875 pkgutil) 30876 pkgutil_help $MISSING_DEPENDENCY ;; 30877 pkgadd) 30878 pkgadd_help $MISSING_DEPENDENCY ;; 30879 * ) 30880 break ;; 30881 esac 30882 30883 if test "x$PKGHANDLER_COMMAND" != x; then 30884 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30885 fi 30886 30887 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h). $HELP_MSG" "$LINENO" 5 30888 fi 30889 30890 30891 30892 30893 30894 30895 ############################################################################### 30896 # 30897 # The common unix printing system cups is used to print from java. 30898 # 30899 30900 # Check whether --with-cups was given. 30901 if test "${with_cups+set}" = set; then : 30902 withval=$with_cups; 30903 fi 30904 30905 30906 # Check whether --with-cups-include was given. 30907 if test "${with_cups_include+set}" = set; then : 30908 withval=$with_cups_include; 30909 fi 30910 30911 30912 if test "x$CUPS_NOT_NEEDED" = xyes; then 30913 if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then 30914 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5 30915 $as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;} 30916 fi 30917 CUPS_CFLAGS= 30918 else 30919 CUPS_FOUND=no 30920 30921 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 30922 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 30923 fi 30924 30925 if test "x${with_cups}" != x; then 30926 CUPS_CFLAGS="-I${with_cups}/include" 30927 CUPS_FOUND=yes 30928 fi 30929 if test "x${with_cups_include}" != x; then 30930 CUPS_CFLAGS="-I${with_cups_include}" 30931 CUPS_FOUND=yes 30932 fi 30933 if test "x$CUPS_FOUND" = xno; then 30934 30935 30936 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 30937 # Source the builddeps file again, to make sure it uses the latest variables! 30938 . $builddepsfile 30939 # Look for a target and build machine specific resource! 30940 eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 30941 if test "x$resource" = x; then 30942 # Ok, lets instead look for a target specific resource 30943 eval resource=\${builddep_cups_TARGET_${rewritten_target_var}} 30944 fi 30945 if test "x$resource" = x; then 30946 # Ok, lets instead look for a build specific resource 30947 eval resource=\${builddep_cups_BUILD_${rewritten_build_var}} 30948 fi 30949 if test "x$resource" = x; then 30950 # Ok, lets instead look for a generic resource 30951 # (The cups comes from M4 and not the shell, thus no need for eval here.) 30952 resource=${builddep_cups} 30953 fi 30954 if test "x$resource" != x; then 30955 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5 30956 $as_echo "$as_me: Using builddeps $resource for cups" >&6;} 30957 # If the resource in the builddeps.conf file is an existing directory, 30958 # for example /java/linux/cups 30959 if test -d ${resource}; then 30960 depdir=${resource} 30961 else 30962 30963 # cups is for example mymodule 30964 # $resource is for example libs/general/libmymod_1_2_3.zip 30965 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 30966 # $with_builddeps_dir is for example /localhome/builddeps 30967 # depdir is the name of the variable into which we store the depdir, eg MYMOD 30968 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 30969 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 30970 filename=`basename $resource` 30971 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 30972 filebase=${filename%%.*} 30973 extension=${filename#*.} 30974 installdir=$with_builddeps_dir/$filebase 30975 if test ! -f $installdir/$filename.unpacked; then 30976 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5 30977 $as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;} 30978 if test ! -d $installdir; then 30979 mkdir -p $installdir 30980 fi 30981 if test ! -d $installdir; then 30982 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 30983 fi 30984 tmpfile=`mktemp $installdir/cups.XXXXXXXXX` 30985 touch $tmpfile 30986 if test ! -f $tmpfile; then 30987 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 30988 fi 30989 30990 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 30991 # $tmpfile is the local file name for the downloaded file. 30992 VALID_TOOL=no 30993 if test "x$BDEPS_FTP" = xwget; then 30994 VALID_TOOL=yes 30995 wget -O $tmpfile $with_builddeps_server/$resource 30996 fi 30997 if test "x$BDEPS_FTP" = xlftp; then 30998 VALID_TOOL=yes 30999 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31000 fi 31001 if test "x$BDEPS_FTP" = xftp; then 31002 VALID_TOOL=yes 31003 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31004 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31005 FTPUSERPWD=${FTPSERVER%%@*} 31006 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31007 FTPUSER=${userpwd%%:*} 31008 FTPPWD=${userpwd#*@} 31009 FTPSERVER=${FTPSERVER#*@} 31010 else 31011 FTPUSER=ftp 31012 FTPPWD=ftp 31013 fi 31014 # the "pass" command does not work on some 31015 # ftp clients (read ftp.exe) but if it works, 31016 # passive mode is better! 31017 (\ 31018 echo "user $FTPUSER $FTPPWD" ;\ 31019 echo "pass" ;\ 31020 echo "bin" ;\ 31021 echo "get $FTPPATH $tmpfile" ;\ 31022 ) | ftp -in $FTPSERVER 31023 fi 31024 if test "x$VALID_TOOL" != xyes; then 31025 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31026 fi 31027 31028 mv $tmpfile $installdir/$filename 31029 if test ! -s $installdir/$filename; then 31030 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31031 fi 31032 case "$extension" in 31033 zip) echo "Unzipping $installdir/$filename..." 31034 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31035 ;; 31036 tar.gz) echo "Untaring $installdir/$filename..." 31037 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31038 ;; 31039 tgz) echo "Untaring $installdir/$filename..." 31040 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31041 ;; 31042 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31043 ;; 31044 esac 31045 fi 31046 if test -f $installdir/$filename.unpacked; then 31047 depdir=$installdir 31048 fi 31049 31050 fi 31051 # Source the builddeps file again, because in the previous command, the depdir 31052 # was updated to point at the current build dependency install directory. 31053 . $builddepsfile 31054 # Now extract variables from the builddeps.conf files. 31055 theroot=${builddep_cups_ROOT} 31056 thecflags=${builddep_cups_CFLAGS} 31057 thelibs=${builddep_cups_LIBS} 31058 if test "x$depdir" = x; then 31059 as_fn_error $? "Could not download build dependency cups" "$LINENO" 5 31060 fi 31061 CUPS=$depdir 31062 if test "x$theroot" != x; then 31063 CUPS="$theroot" 31064 fi 31065 if test "x$thecflags" != x; then 31066 CUPS_CFLAGS="$thecflags" 31067 fi 31068 if test "x$thelibs" != x; then 31069 CUPS_LIBS="$thelibs" 31070 fi 31071 CUPS_FOUND=yes 31072 31073 fi 31074 31075 fi 31076 31077 fi 31078 if test "x$CUPS_FOUND" = xno; then 31079 # Are the cups headers installed in the default /usr/include location? 31080 for ac_header in cups/cups.h cups/ppd.h 31081 do : 31082 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 31083 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 31084 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 31085 cat >>confdefs.h <<_ACEOF 31086 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 31087 _ACEOF 31088 CUPS_FOUND=yes 31089 CUPS_CFLAGS= 31090 DEFAULT_CUPS=yes 31091 fi 31092 31093 done 31094 31095 fi 31096 if test "x$CUPS_FOUND" = xno; then 31097 # Getting nervous now? Lets poke around for standard Solaris third-party 31098 # package installation locations. 31099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 31100 $as_echo_n "checking for cups headers... " >&6; } 31101 if test -s /opt/sfw/cups/include/cups/cups.h; then 31102 # An SFW package seems to be installed! 31103 CUPS_FOUND=yes 31104 CUPS_CFLAGS="-I/opt/sfw/cups/include" 31105 elif test -s /opt/csw/include/cups/cups.h; then 31106 # A CSW package seems to be installed! 31107 CUPS_FOUND=yes 31108 CUPS_CFLAGS="-I/opt/csw/include" 31109 fi 31110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 31111 $as_echo "$CUPS_FOUND" >&6; } 31112 fi 31113 if test "x$CUPS_FOUND" = xno; then 31114 31115 # Print a helpful message on how to acquire the necessary build dependency. 31116 # cups is the help tag: freetyp2, cups, pulse, alsa etc 31117 MISSING_DEPENDENCY=cups 31118 PKGHANDLER_COMMAND= 31119 31120 case $PKGHANDLER in 31121 apt-get) 31122 apt_help $MISSING_DEPENDENCY ;; 31123 yum) 31124 yum_help $MISSING_DEPENDENCY ;; 31125 port) 31126 port_help $MISSING_DEPENDENCY ;; 31127 pkgutil) 31128 pkgutil_help $MISSING_DEPENDENCY ;; 31129 pkgadd) 31130 pkgadd_help $MISSING_DEPENDENCY ;; 31131 * ) 31132 break ;; 31133 esac 31134 31135 if test "x$PKGHANDLER_COMMAND" != x; then 31136 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 31137 fi 31138 31139 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 31140 fi 31141 fi 31142 31143 31144 31145 31146 31147 31148 ############################################################################### 31149 # 31150 # The ubiquitous freetype2 library is used to render fonts. 31151 # 31152 31153 # Check whether --with-freetype was given. 31154 if test "${with_freetype+set}" = set; then : 31155 withval=$with_freetype; 31156 fi 31157 31158 31159 # If we are using the OS installed system lib for freetype, then we do not need to copy it to the build tree 31160 USING_SYSTEM_FT_LIB=false 31161 31162 if test "x$FREETYPE2_NOT_NEEDED" = xyes; then 31163 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 31164 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5 31165 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;} 31166 fi 31167 FREETYPE2_CFLAGS= 31168 FREETYPE2_LIBS= 31169 FREETYPE2_LIB_PATH= 31170 else 31171 FREETYPE2_FOUND=no 31172 31173 if test "x$with_freetype" != x; then 31174 31175 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31176 31177 # Input might be given as Windows format, start by converting to 31178 # unix format. 31179 path="$with_freetype" 31180 new_path=`$CYGPATH -u "$path"` 31181 31182 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31183 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31184 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31185 # "foo.exe" is OK but "foo" is an error. 31186 # 31187 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31188 # It is also a way to make sure we got the proper file name for the real test later on. 31189 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31190 if test "x$test_shortpath" = x; then 31191 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_freetype, which resolves as \"$path\", is invalid." >&5 31192 $as_echo "$as_me: The path of with_freetype, which resolves as \"$path\", is invalid." >&6;} 31193 as_fn_error $? "Cannot locate the the path of with_freetype" "$LINENO" 5 31194 fi 31195 31196 # Call helper function which possibly converts this using DOS-style short mode. 31197 # If so, the updated path is stored in $new_path. 31198 31199 input_path="$new_path" 31200 # Check if we need to convert this using DOS-style short mode. If the path 31201 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31202 # take no chances and rewrite it. 31203 # Note: m4 eats our [], so we need to use [ and ] instead. 31204 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31205 if test "x$has_forbidden_chars" != x; then 31206 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31207 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31208 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31209 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31210 # Going to short mode and back again did indeed matter. Since short mode is 31211 # case insensitive, let's make it lowercase to improve readability. 31212 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31213 # Now convert it back to Unix-stile (cygpath) 31214 input_path=`$CYGPATH -u "$shortmode_path"` 31215 new_path="$input_path" 31216 fi 31217 fi 31218 31219 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31220 if test "x$test_cygdrive_prefix" = x; then 31221 # As a simple fix, exclude /usr/bin since it's not a real path. 31222 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31223 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31224 # a path prefixed by /cygdrive for fixpath to work. 31225 new_path="$CYGWIN_ROOT_PATH$input_path" 31226 fi 31227 fi 31228 31229 31230 if test "x$path" != "x$new_path"; then 31231 with_freetype="$new_path" 31232 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_freetype to \"$new_path\"" >&5 31233 $as_echo "$as_me: Rewriting with_freetype to \"$new_path\"" >&6;} 31234 fi 31235 31236 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31237 31238 path="$with_freetype" 31239 has_colon=`$ECHO $path | $GREP ^.:` 31240 new_path="$path" 31241 if test "x$has_colon" = x; then 31242 # Not in mixed or Windows style, start by that. 31243 new_path=`cmd //c echo $path` 31244 fi 31245 31246 31247 input_path="$new_path" 31248 # Check if we need to convert this using DOS-style short mode. If the path 31249 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31250 # take no chances and rewrite it. 31251 # Note: m4 eats our [], so we need to use [ and ] instead. 31252 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31253 if test "x$has_forbidden_chars" != x; then 31254 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31255 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31256 fi 31257 31258 31259 windows_path="$new_path" 31260 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31261 unix_path=`$CYGPATH -u "$windows_path"` 31262 new_path="$unix_path" 31263 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31264 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31265 new_path="$unix_path" 31266 fi 31267 31268 if test "x$path" != "x$new_path"; then 31269 with_freetype="$new_path" 31270 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_freetype to \"$new_path\"" >&5 31271 $as_echo "$as_me: Rewriting with_freetype to \"$new_path\"" >&6;} 31272 fi 31273 31274 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31275 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31276 31277 else 31278 # We're on a posix platform. Hooray! :) 31279 path="$with_freetype" 31280 has_space=`$ECHO "$path" | $GREP " "` 31281 if test "x$has_space" != x; then 31282 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_freetype, which resolves as \"$path\", is invalid." >&5 31283 $as_echo "$as_me: The path of with_freetype, which resolves as \"$path\", is invalid." >&6;} 31284 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31285 fi 31286 31287 # Use eval to expand a potential ~ 31288 eval path="$path" 31289 if test ! -f "$path" && test ! -d "$path"; then 31290 as_fn_error $? "The path of with_freetype, which resolves as \"$path\", is not found." "$LINENO" 5 31291 fi 31292 31293 with_freetype="`cd "$path"; $THEPWDCMD -L`" 31294 fi 31295 31296 FREETYPE2_LIBS="-L$with_freetype/lib -lfreetype" 31297 FREETYPE2_LIB_PATH="$with_freetype/lib" 31298 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -d "$with_freetype/lib/amd64"; then 31299 FREETYPE2_LIBS="-L$with_freetype/lib/amd64 -lfreetype" 31300 FREETYPE2_LIB_PATH="$with_freetype/lib/amd64" 31301 fi 31302 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31303 FREETYPE2_LIBS="$with_freetype/lib/freetype.lib" 31304 fi 31305 FREETYPE2_CFLAGS="-I$with_freetype/include" 31306 if test -s $with_freetype/include/ft2build.h && test -d $with_freetype/include/freetype2/freetype; then 31307 FREETYPE2_CFLAGS="-I$with_freetype/include/freetype2 -I$with_freetype/include" 31308 fi 31309 FREETYPE2_FOUND=yes 31310 if test "x$FREETYPE2_FOUND" = xyes; then 31311 # Verify that the directories exist 31312 if ! test -d "$with_freetype/lib" || ! test -d "$with_freetype/include"; then 31313 as_fn_error $? "Could not find the expected directories $with_freetype/lib and $with_freetype/include" "$LINENO" 5 31314 fi 31315 # List the contents of the lib. 31316 FREETYPELIB=`ls $with_freetype/lib/libfreetype.so $with_freetype/lib/freetype.dll 2> /dev/null` 31317 if test "x$FREETYPELIB" = x; then 31318 as_fn_error $? "Could not find libfreetype.so nor freetype.dll in $with_freetype/lib" "$LINENO" 5 31319 fi 31320 # Check one h-file 31321 if ! test -s "$with_freetype/include/ft2build.h"; then 31322 as_fn_error $? "Could not find $with_freetype/include/ft2build.h" "$LINENO" 5 31323 fi 31324 fi 31325 fi 31326 if test "x$FREETYPE2_FOUND" = xno; then 31327 31328 31329 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 31330 # Source the builddeps file again, to make sure it uses the latest variables! 31331 . $builddepsfile 31332 # Look for a target and build machine specific resource! 31333 eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 31334 if test "x$resource" = x; then 31335 # Ok, lets instead look for a target specific resource 31336 eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}} 31337 fi 31338 if test "x$resource" = x; then 31339 # Ok, lets instead look for a build specific resource 31340 eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}} 31341 fi 31342 if test "x$resource" = x; then 31343 # Ok, lets instead look for a generic resource 31344 # (The freetype2 comes from M4 and not the shell, thus no need for eval here.) 31345 resource=${builddep_freetype2} 31346 fi 31347 if test "x$resource" != x; then 31348 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5 31349 $as_echo "$as_me: Using builddeps $resource for freetype2" >&6;} 31350 # If the resource in the builddeps.conf file is an existing directory, 31351 # for example /java/linux/cups 31352 if test -d ${resource}; then 31353 depdir=${resource} 31354 else 31355 31356 # freetype2 is for example mymodule 31357 # $resource is for example libs/general/libmymod_1_2_3.zip 31358 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 31359 # $with_builddeps_dir is for example /localhome/builddeps 31360 # depdir is the name of the variable into which we store the depdir, eg MYMOD 31361 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 31362 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 31363 filename=`basename $resource` 31364 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 31365 filebase=${filename%%.*} 31366 extension=${filename#*.} 31367 installdir=$with_builddeps_dir/$filebase 31368 if test ! -f $installdir/$filename.unpacked; then 31369 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5 31370 $as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;} 31371 if test ! -d $installdir; then 31372 mkdir -p $installdir 31373 fi 31374 if test ! -d $installdir; then 31375 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 31376 fi 31377 tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX` 31378 touch $tmpfile 31379 if test ! -f $tmpfile; then 31380 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 31381 fi 31382 31383 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 31384 # $tmpfile is the local file name for the downloaded file. 31385 VALID_TOOL=no 31386 if test "x$BDEPS_FTP" = xwget; then 31387 VALID_TOOL=yes 31388 wget -O $tmpfile $with_builddeps_server/$resource 31389 fi 31390 if test "x$BDEPS_FTP" = xlftp; then 31391 VALID_TOOL=yes 31392 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31393 fi 31394 if test "x$BDEPS_FTP" = xftp; then 31395 VALID_TOOL=yes 31396 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31397 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31398 FTPUSERPWD=${FTPSERVER%%@*} 31399 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31400 FTPUSER=${userpwd%%:*} 31401 FTPPWD=${userpwd#*@} 31402 FTPSERVER=${FTPSERVER#*@} 31403 else 31404 FTPUSER=ftp 31405 FTPPWD=ftp 31406 fi 31407 # the "pass" command does not work on some 31408 # ftp clients (read ftp.exe) but if it works, 31409 # passive mode is better! 31410 (\ 31411 echo "user $FTPUSER $FTPPWD" ;\ 31412 echo "pass" ;\ 31413 echo "bin" ;\ 31414 echo "get $FTPPATH $tmpfile" ;\ 31415 ) | ftp -in $FTPSERVER 31416 fi 31417 if test "x$VALID_TOOL" != xyes; then 31418 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31419 fi 31420 31421 mv $tmpfile $installdir/$filename 31422 if test ! -s $installdir/$filename; then 31423 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31424 fi 31425 case "$extension" in 31426 zip) echo "Unzipping $installdir/$filename..." 31427 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31428 ;; 31429 tar.gz) echo "Untaring $installdir/$filename..." 31430 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31431 ;; 31432 tgz) echo "Untaring $installdir/$filename..." 31433 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31434 ;; 31435 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31436 ;; 31437 esac 31438 fi 31439 if test -f $installdir/$filename.unpacked; then 31440 depdir=$installdir 31441 fi 31442 31443 fi 31444 # Source the builddeps file again, because in the previous command, the depdir 31445 # was updated to point at the current build dependency install directory. 31446 . $builddepsfile 31447 # Now extract variables from the builddeps.conf files. 31448 theroot=${builddep_freetype2_ROOT} 31449 thecflags=${builddep_freetype2_CFLAGS} 31450 thelibs=${builddep_freetype2_LIBS} 31451 if test "x$depdir" = x; then 31452 as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5 31453 fi 31454 FREETYPE2=$depdir 31455 if test "x$theroot" != x; then 31456 FREETYPE2="$theroot" 31457 fi 31458 if test "x$thecflags" != x; then 31459 FREETYPE2_CFLAGS="$thecflags" 31460 fi 31461 if test "x$thelibs" != x; then 31462 FREETYPE2_LIBS="$thelibs" 31463 fi 31464 FREETYPE2_FOUND=yes 31465 else FREETYPE2_FOUND=no 31466 31467 fi 31468 else FREETYPE2_FOUND=no 31469 31470 fi 31471 31472 USING_SYSTEM_FT_LIB=true 31473 fi 31474 if test "x$FREETYPE2_FOUND" = xno && test "x$OPENJDK_TARGET_OS" = xwindows; then 31475 FREETYPELOCATION="$PROGRAMFILES/GnuWin32" 31476 31477 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31478 31479 # Input might be given as Windows format, start by converting to 31480 # unix format. 31481 path="$FREETYPELOCATION" 31482 new_path=`$CYGPATH -u "$path"` 31483 31484 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31485 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31486 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31487 # "foo.exe" is OK but "foo" is an error. 31488 # 31489 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31490 # It is also a way to make sure we got the proper file name for the real test later on. 31491 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31492 if test "x$test_shortpath" = x; then 31493 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&5 31494 $as_echo "$as_me: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&6;} 31495 as_fn_error $? "Cannot locate the the path of FREETYPELOCATION" "$LINENO" 5 31496 fi 31497 31498 # Call helper function which possibly converts this using DOS-style short mode. 31499 # If so, the updated path is stored in $new_path. 31500 31501 input_path="$new_path" 31502 # Check if we need to convert this using DOS-style short mode. If the path 31503 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31504 # take no chances and rewrite it. 31505 # Note: m4 eats our [], so we need to use [ and ] instead. 31506 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31507 if test "x$has_forbidden_chars" != x; then 31508 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31509 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31510 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31511 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31512 # Going to short mode and back again did indeed matter. Since short mode is 31513 # case insensitive, let's make it lowercase to improve readability. 31514 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31515 # Now convert it back to Unix-stile (cygpath) 31516 input_path=`$CYGPATH -u "$shortmode_path"` 31517 new_path="$input_path" 31518 fi 31519 fi 31520 31521 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31522 if test "x$test_cygdrive_prefix" = x; then 31523 # As a simple fix, exclude /usr/bin since it's not a real path. 31524 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31525 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31526 # a path prefixed by /cygdrive for fixpath to work. 31527 new_path="$CYGWIN_ROOT_PATH$input_path" 31528 fi 31529 fi 31530 31531 31532 if test "x$path" != "x$new_path"; then 31533 FREETYPELOCATION="$new_path" 31534 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPELOCATION to \"$new_path\"" >&5 31535 $as_echo "$as_me: Rewriting FREETYPELOCATION to \"$new_path\"" >&6;} 31536 fi 31537 31538 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31539 31540 path="$FREETYPELOCATION" 31541 has_colon=`$ECHO $path | $GREP ^.:` 31542 new_path="$path" 31543 if test "x$has_colon" = x; then 31544 # Not in mixed or Windows style, start by that. 31545 new_path=`cmd //c echo $path` 31546 fi 31547 31548 31549 input_path="$new_path" 31550 # Check if we need to convert this using DOS-style short mode. If the path 31551 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31552 # take no chances and rewrite it. 31553 # Note: m4 eats our [], so we need to use [ and ] instead. 31554 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31555 if test "x$has_forbidden_chars" != x; then 31556 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31557 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31558 fi 31559 31560 31561 windows_path="$new_path" 31562 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31563 unix_path=`$CYGPATH -u "$windows_path"` 31564 new_path="$unix_path" 31565 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31566 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31567 new_path="$unix_path" 31568 fi 31569 31570 if test "x$path" != "x$new_path"; then 31571 FREETYPELOCATION="$new_path" 31572 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPELOCATION to \"$new_path\"" >&5 31573 $as_echo "$as_me: Rewriting FREETYPELOCATION to \"$new_path\"" >&6;} 31574 fi 31575 31576 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31577 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31578 31579 else 31580 # We're on a posix platform. Hooray! :) 31581 path="$FREETYPELOCATION" 31582 has_space=`$ECHO "$path" | $GREP " "` 31583 if test "x$has_space" != x; then 31584 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&5 31585 $as_echo "$as_me: The path of FREETYPELOCATION, which resolves as \"$path\", is invalid." >&6;} 31586 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31587 fi 31588 31589 # Use eval to expand a potential ~ 31590 eval path="$path" 31591 if test ! -f "$path" && test ! -d "$path"; then 31592 as_fn_error $? "The path of FREETYPELOCATION, which resolves as \"$path\", is not found." "$LINENO" 5 31593 fi 31594 31595 FREETYPELOCATION="`cd "$path"; $THEPWDCMD -L`" 31596 fi 31597 31598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype in some standard windows locations" >&5 31599 $as_echo_n "checking for freetype in some standard windows locations... " >&6; } 31600 if test -s "$FREETYPELOCATION/include/ft2build.h" && test -d "$FREETYPELOCATION/include/freetype2/freetype"; then 31601 FREETYPE2_CFLAGS="-I$FREETYPELOCATION/include/freetype2 -I$FREETYPELOCATION/include" 31602 FREETYPE2_LIBS="$FREETYPELOCATION/lib/freetype.lib" 31603 FREETYPE2_LIB_PATH="$FREETYPELOCATION/lib" 31604 if ! test -s "$FREETYPE2_LIBS"; then 31605 as_fn_error $? "Could not find $FREETYPE2_LIBS" "$LINENO" 5 31606 fi 31607 if ! test -s "$FREETYPE2_LIB_PATH/freetype.dll"; then 31608 as_fn_error $? "Could not find $FREETYPE2_LIB_PATH/freetype.dll" "$LINENO" 5 31609 fi 31610 USING_SYSTEM_FT_LIB=true 31611 FREETYPE2_FOUND=yes 31612 fi 31613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE2_FOUND" >&5 31614 $as_echo "$FREETYPE2_FOUND" >&6; } 31615 fi 31616 if test "x$FREETYPE2_FOUND" = xno; then 31617 31618 pkg_failed=no 31619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE2" >&5 31620 $as_echo_n "checking for FREETYPE2... " >&6; } 31621 31622 if test -n "$FREETYPE2_CFLAGS"; then 31623 pkg_cv_FREETYPE2_CFLAGS="$FREETYPE2_CFLAGS" 31624 elif test -n "$PKG_CONFIG"; then 31625 if test -n "$PKG_CONFIG" && \ 31626 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 31627 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 31628 ac_status=$? 31629 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 31630 test $ac_status = 0; }; then 31631 pkg_cv_FREETYPE2_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 31632 else 31633 pkg_failed=yes 31634 fi 31635 else 31636 pkg_failed=untried 31637 fi 31638 if test -n "$FREETYPE2_LIBS"; then 31639 pkg_cv_FREETYPE2_LIBS="$FREETYPE2_LIBS" 31640 elif test -n "$PKG_CONFIG"; then 31641 if test -n "$PKG_CONFIG" && \ 31642 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 31643 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 31644 ac_status=$? 31645 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 31646 test $ac_status = 0; }; then 31647 pkg_cv_FREETYPE2_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 31648 else 31649 pkg_failed=yes 31650 fi 31651 else 31652 pkg_failed=untried 31653 fi 31654 31655 31656 31657 if test $pkg_failed = yes; then 31658 31659 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 31660 _pkg_short_errors_supported=yes 31661 else 31662 _pkg_short_errors_supported=no 31663 fi 31664 if test $_pkg_short_errors_supported = yes; then 31665 FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 31666 else 31667 FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 31668 fi 31669 # Put the nasty error message in config.log where it belongs 31670 echo "$FREETYPE2_PKG_ERRORS" >&5 31671 31672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31673 $as_echo "no" >&6; } 31674 FREETYPE2_FOUND=no 31675 elif test $pkg_failed = untried; then 31676 FREETYPE2_FOUND=no 31677 else 31678 FREETYPE2_CFLAGS=$pkg_cv_FREETYPE2_CFLAGS 31679 FREETYPE2_LIBS=$pkg_cv_FREETYPE2_LIBS 31680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31681 $as_echo "yes" >&6; } 31682 FREETYPE2_FOUND=yes 31683 fi 31684 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 31685 FREETYPE2_LIBS=`$ECHO $FREETYPE2_LIBS | $SED 's/-lz//g'` 31686 USING_SYSTEM_FT_LIB=true 31687 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 31688 if test "x$FREETYPE2_FOUND" = xyes && test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 31689 FREETYPE2_LIBS=`$ECHO $FREETYPE2_LIBS | $SED 's?/lib?/lib/amd64?g'` 31690 fi 31691 fi 31692 if test "x$FREETYPE2_FOUND" = xno; then 31693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype in some standard locations" >&5 31694 $as_echo_n "checking for freetype in some standard locations... " >&6; } 31695 31696 if test -s $SYS_ROOT/usr/X11/include/ft2build.h && test -d $SYS_ROOT/usr/X11/include/freetype2/freetype; then 31697 DEFAULT_FREETYPE_CFLAGS="-I$SYS_ROOT/usr/X11/include/freetype2 -I$SYS_ROOT/usr/X11/include" 31698 DEFAULT_FREETYPE_LIBS="-L$SYS_ROOT/usr/X11/lib -lfreetype" 31699 fi 31700 if test -s $SYS_ROOT/usr/include/ft2build.h && test -d $SYS_ROOT/usr/include/freetype2/freetype; then 31701 DEFAULT_FREETYPE_CFLAGS="-I$SYS_ROOT/usr/include/freetype2" 31702 DEFAULT_FREETYPE_LIBS="-lfreetype" 31703 fi 31704 31705 PREV_CXXCFLAGS="$CXXFLAGS" 31706 PREV_LDFLAGS="$LDFLAGS" 31707 CXXFLAGS="$CXXFLAGS $DEFAULT_FREETYPE_CFLAGS" 31708 LDFLAGS="$LDFLAGS $DEFAULT_FREETYPE_LIBS" 31709 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 31710 /* end confdefs.h. */ 31711 #include<ft2build.h> 31712 #include FT_FREETYPE_H 31713 int main() { return 0; } 31714 31715 _ACEOF 31716 if ac_fn_cxx_try_link "$LINENO"; then : 31717 31718 # Yes, the default cflags and libs did the trick. 31719 FREETYPE2_FOUND=yes 31720 FREETYPE2_CFLAGS="$DEFAULT_FREETYPE_CFLAGS" 31721 FREETYPE2_LIBS="$DEFAULT_FREETYPE_LIBS" 31722 31723 else 31724 31725 FREETYPE2_FOUND=no 31726 31727 fi 31728 rm -f core conftest.err conftest.$ac_objext \ 31729 conftest$ac_exeext conftest.$ac_ext 31730 CXXCFLAGS="$PREV_CXXFLAGS" 31731 LDFLAGS="$PREV_LDFLAGS" 31732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE2_FOUND" >&5 31733 $as_echo "$FREETYPE2_FOUND" >&6; } 31734 USING_SYSTEM_FT_LIB=true 31735 fi 31736 if test "x$FREETYPE2_FOUND" = xno; then 31737 31738 # Print a helpful message on how to acquire the necessary build dependency. 31739 # freetype2 is the help tag: freetyp2, cups, pulse, alsa etc 31740 MISSING_DEPENDENCY=freetype2 31741 PKGHANDLER_COMMAND= 31742 31743 case $PKGHANDLER in 31744 apt-get) 31745 apt_help $MISSING_DEPENDENCY ;; 31746 yum) 31747 yum_help $MISSING_DEPENDENCY ;; 31748 port) 31749 port_help $MISSING_DEPENDENCY ;; 31750 pkgutil) 31751 pkgutil_help $MISSING_DEPENDENCY ;; 31752 pkgadd) 31753 pkgadd_help $MISSING_DEPENDENCY ;; 31754 * ) 31755 break ;; 31756 esac 31757 31758 if test "x$PKGHANDLER_COMMAND" != x; then 31759 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 31760 fi 31761 31762 as_fn_error $? "Could not find freetype2! $HELP_MSG " "$LINENO" 5 31763 fi 31764 31765 if test "x$OPENJDK_TARGET_OS" != xwindows; then 31766 # AC_CHECK_LIB does not support use of cl.exe 31767 PREV_LDFLAGS="$LDFLAGS" 31768 LDFLAGS="$FREETYPE2_LIBS" 31769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FT_Init_FreeType in -lfreetype" >&5 31770 $as_echo_n "checking for FT_Init_FreeType in -lfreetype... " >&6; } 31771 if ${ac_cv_lib_freetype_FT_Init_FreeType+:} false; then : 31772 $as_echo_n "(cached) " >&6 31773 else 31774 ac_check_lib_save_LIBS=$LIBS 31775 LIBS="-lfreetype $LIBS" 31776 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 31777 /* end confdefs.h. */ 31778 31779 /* Override any GCC internal prototype to avoid an error. 31780 Use char because int might match the return type of a GCC 31781 builtin and then its argument prototype would still apply. */ 31782 #ifdef __cplusplus 31783 extern "C" 31784 #endif 31785 char FT_Init_FreeType (); 31786 int 31787 main () 31788 { 31789 return FT_Init_FreeType (); 31790 ; 31791 return 0; 31792 } 31793 _ACEOF 31794 if ac_fn_cxx_try_link "$LINENO"; then : 31795 ac_cv_lib_freetype_FT_Init_FreeType=yes 31796 else 31797 ac_cv_lib_freetype_FT_Init_FreeType=no 31798 fi 31799 rm -f core conftest.err conftest.$ac_objext \ 31800 conftest$ac_exeext conftest.$ac_ext 31801 LIBS=$ac_check_lib_save_LIBS 31802 fi 31803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_freetype_FT_Init_FreeType" >&5 31804 $as_echo "$ac_cv_lib_freetype_FT_Init_FreeType" >&6; } 31805 if test "x$ac_cv_lib_freetype_FT_Init_FreeType" = xyes; then : 31806 FREETYPE2_FOUND=true 31807 else 31808 as_fn_error $? "Could not find freetype2! $HELP_MSG " "$LINENO" 5 31809 fi 31810 31811 LDFLAGS="$PREV_LDFLAGS" 31812 fi 31813 fi 31814 31815 31816 31817 31818 31819 31820 31821 31822 31823 ############################################################################### 31824 # 31825 # Check for alsa headers and libraries. Used on Linux/GNU systems. 31826 # 31827 31828 # Check whether --with-alsa was given. 31829 if test "${with_alsa+set}" = set; then : 31830 withval=$with_alsa; 31831 fi 31832 31833 31834 # Check whether --with-alsa-include was given. 31835 if test "${with_alsa_include+set}" = set; then : 31836 withval=$with_alsa_include; 31837 fi 31838 31839 31840 # Check whether --with-alsa-lib was given. 31841 if test "${with_alsa_lib+set}" = set; then : 31842 withval=$with_alsa_lib; 31843 fi 31844 31845 31846 if test "x$ALSA_NOT_NEEDED" = xyes; then 31847 if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then 31848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5 31849 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;} 31850 fi 31851 ALSA_CFLAGS= 31852 ALSA_LIBS= 31853 else 31854 ALSA_FOUND=no 31855 31856 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 31857 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 31858 fi 31859 31860 if test "x${with_alsa}" != x; then 31861 ALSA_LIBS="-L${with_alsa}/lib -lalsa" 31862 ALSA_CFLAGS="-I${with_alsa}/include" 31863 ALSA_FOUND=yes 31864 fi 31865 if test "x${with_alsa_include}" != x; then 31866 ALSA_CFLAGS="-I${with_alsa_include}" 31867 ALSA_FOUND=yes 31868 fi 31869 if test "x${with_alsa_lib}" != x; then 31870 ALSA_LIBS="-L${with_alsa_lib} -lalsa" 31871 ALSA_FOUND=yes 31872 fi 31873 if test "x$ALSA_FOUND" = xno; then 31874 31875 31876 if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then 31877 # Source the builddeps file again, to make sure it uses the latest variables! 31878 . $builddepsfile 31879 # Look for a target and build machine specific resource! 31880 eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}} 31881 if test "x$resource" = x; then 31882 # Ok, lets instead look for a target specific resource 31883 eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}} 31884 fi 31885 if test "x$resource" = x; then 31886 # Ok, lets instead look for a build specific resource 31887 eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}} 31888 fi 31889 if test "x$resource" = x; then 31890 # Ok, lets instead look for a generic resource 31891 # (The alsa comes from M4 and not the shell, thus no need for eval here.) 31892 resource=${builddep_alsa} 31893 fi 31894 if test "x$resource" != x; then 31895 { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5 31896 $as_echo "$as_me: Using builddeps $resource for alsa" >&6;} 31897 # If the resource in the builddeps.conf file is an existing directory, 31898 # for example /java/linux/cups 31899 if test -d ${resource}; then 31900 depdir=${resource} 31901 else 31902 31903 # alsa is for example mymodule 31904 # $resource is for example libs/general/libmymod_1_2_3.zip 31905 # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps 31906 # $with_builddeps_dir is for example /localhome/builddeps 31907 # depdir is the name of the variable into which we store the depdir, eg MYMOD 31908 # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and 31909 # unzip into the directory: /localhome/builddeps/libmymod_1_2_3 31910 filename=`basename $resource` 31911 filebase=`echo $filename | sed 's/\.[^\.]*$//'` 31912 filebase=${filename%%.*} 31913 extension=${filename#*.} 31914 installdir=$with_builddeps_dir/$filebase 31915 if test ! -f $installdir/$filename.unpacked; then 31916 { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5 31917 $as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;} 31918 if test ! -d $installdir; then 31919 mkdir -p $installdir 31920 fi 31921 if test ! -d $installdir; then 31922 as_fn_error $? "Could not create directory $installdir" "$LINENO" 5 31923 fi 31924 tmpfile=`mktemp $installdir/alsa.XXXXXXXXX` 31925 touch $tmpfile 31926 if test ! -f $tmpfile; then 31927 as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5 31928 fi 31929 31930 # $with_builddeps_server/$resource is the ftp://abuilddeps.server.com/libs/cups.zip 31931 # $tmpfile is the local file name for the downloaded file. 31932 VALID_TOOL=no 31933 if test "x$BDEPS_FTP" = xwget; then 31934 VALID_TOOL=yes 31935 wget -O $tmpfile $with_builddeps_server/$resource 31936 fi 31937 if test "x$BDEPS_FTP" = xlftp; then 31938 VALID_TOOL=yes 31939 lftp -c "get $with_builddeps_server/$resource -o $tmpfile" 31940 fi 31941 if test "x$BDEPS_FTP" = xftp; then 31942 VALID_TOOL=yes 31943 FTPSERVER=`echo $with_builddeps_server/$resource | cut -f 3 -d '/'` 31944 FTPPATH=`echo $with_builddeps_server/$resource | cut -f 4- -d '/'` 31945 FTPUSERPWD=${FTPSERVER%%@*} 31946 if test "x$FTPSERVER" != "x$FTPUSERPWD"; then 31947 FTPUSER=${userpwd%%:*} 31948 FTPPWD=${userpwd#*@} 31949 FTPSERVER=${FTPSERVER#*@} 31950 else 31951 FTPUSER=ftp 31952 FTPPWD=ftp 31953 fi 31954 # the "pass" command does not work on some 31955 # ftp clients (read ftp.exe) but if it works, 31956 # passive mode is better! 31957 (\ 31958 echo "user $FTPUSER $FTPPWD" ;\ 31959 echo "pass" ;\ 31960 echo "bin" ;\ 31961 echo "get $FTPPATH $tmpfile" ;\ 31962 ) | ftp -in $FTPSERVER 31963 fi 31964 if test "x$VALID_TOOL" != xyes; then 31965 as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5 31966 fi 31967 31968 mv $tmpfile $installdir/$filename 31969 if test ! -s $installdir/$filename; then 31970 as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5 31971 fi 31972 case "$extension" in 31973 zip) echo "Unzipping $installdir/$filename..." 31974 (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked) 31975 ;; 31976 tar.gz) echo "Untaring $installdir/$filename..." 31977 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31978 ;; 31979 tgz) echo "Untaring $installdir/$filename..." 31980 (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked) 31981 ;; 31982 *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5 31983 ;; 31984 esac 31985 fi 31986 if test -f $installdir/$filename.unpacked; then 31987 depdir=$installdir 31988 fi 31989 31990 fi 31991 # Source the builddeps file again, because in the previous command, the depdir 31992 # was updated to point at the current build dependency install directory. 31993 . $builddepsfile 31994 # Now extract variables from the builddeps.conf files. 31995 theroot=${builddep_alsa_ROOT} 31996 thecflags=${builddep_alsa_CFLAGS} 31997 thelibs=${builddep_alsa_LIBS} 31998 if test "x$depdir" = x; then 31999 as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5 32000 fi 32001 ALSA=$depdir 32002 if test "x$theroot" != x; then 32003 ALSA="$theroot" 32004 fi 32005 if test "x$thecflags" != x; then 32006 ALSA_CFLAGS="$thecflags" 32007 fi 32008 if test "x$thelibs" != x; then 32009 ALSA_LIBS="$thelibs" 32010 fi 32011 ALSA_FOUND=yes 32012 else ALSA_FOUND=no 32013 32014 fi 32015 else ALSA_FOUND=no 32016 32017 fi 32018 32019 fi 32020 if test "x$ALSA_FOUND" = xno; then 32021 32022 pkg_failed=no 32023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 32024 $as_echo_n "checking for ALSA... " >&6; } 32025 32026 if test -n "$ALSA_CFLAGS"; then 32027 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 32028 elif test -n "$PKG_CONFIG"; then 32029 if test -n "$PKG_CONFIG" && \ 32030 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 32031 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 32032 ac_status=$? 32033 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32034 test $ac_status = 0; }; then 32035 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 32036 else 32037 pkg_failed=yes 32038 fi 32039 else 32040 pkg_failed=untried 32041 fi 32042 if test -n "$ALSA_LIBS"; then 32043 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 32044 elif test -n "$PKG_CONFIG"; then 32045 if test -n "$PKG_CONFIG" && \ 32046 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 32047 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 32048 ac_status=$? 32049 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32050 test $ac_status = 0; }; then 32051 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 32052 else 32053 pkg_failed=yes 32054 fi 32055 else 32056 pkg_failed=untried 32057 fi 32058 32059 32060 32061 if test $pkg_failed = yes; then 32062 32063 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 32064 _pkg_short_errors_supported=yes 32065 else 32066 _pkg_short_errors_supported=no 32067 fi 32068 if test $_pkg_short_errors_supported = yes; then 32069 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 32070 else 32071 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 32072 fi 32073 # Put the nasty error message in config.log where it belongs 32074 echo "$ALSA_PKG_ERRORS" >&5 32075 32076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32077 $as_echo "no" >&6; } 32078 ALSA_FOUND=no 32079 elif test $pkg_failed = untried; then 32080 ALSA_FOUND=no 32081 else 32082 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 32083 ALSA_LIBS=$pkg_cv_ALSA_LIBS 32084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32085 $as_echo "yes" >&6; } 32086 ALSA_FOUND=yes 32087 fi 32088 fi 32089 if test "x$ALSA_FOUND" = xno; then 32090 for ac_header in alsa/asoundlib.h 32091 do : 32092 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 32093 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 32094 cat >>confdefs.h <<_ACEOF 32095 #define HAVE_ALSA_ASOUNDLIB_H 1 32096 _ACEOF 32097 ALSA_FOUND=yes 32098 ALSA_CFLAGS=-Iignoreme 32099 ALSA_LIBS=-lasound 32100 DEFAULT_ALSA=yes 32101 else 32102 ALSA_FOUND=no 32103 fi 32104 32105 done 32106 32107 fi 32108 if test "x$ALSA_FOUND" = xno; then 32109 32110 # Print a helpful message on how to acquire the necessary build dependency. 32111 # alsa is the help tag: freetyp2, cups, pulse, alsa etc 32112 MISSING_DEPENDENCY=alsa 32113 PKGHANDLER_COMMAND= 32114 32115 case $PKGHANDLER in 32116 apt-get) 32117 apt_help $MISSING_DEPENDENCY ;; 32118 yum) 32119 yum_help $MISSING_DEPENDENCY ;; 32120 port) 32121 port_help $MISSING_DEPENDENCY ;; 32122 pkgutil) 32123 pkgutil_help $MISSING_DEPENDENCY ;; 32124 pkgadd) 32125 pkgadd_help $MISSING_DEPENDENCY ;; 32126 * ) 32127 break ;; 32128 esac 32129 32130 if test "x$PKGHANDLER_COMMAND" != x; then 32131 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 32132 fi 32133 32134 as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5 32135 fi 32136 fi 32137 32138 32139 32140 32141 32142 32143 32144 ############################################################################### 32145 # 32146 # Check for the jpeg library 32147 # 32148 32149 USE_EXTERNAL_LIBJPEG=true 32150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5 32151 $as_echo_n "checking for main in -ljpeg... " >&6; } 32152 if ${ac_cv_lib_jpeg_main+:} false; then : 32153 $as_echo_n "(cached) " >&6 32154 else 32155 ac_check_lib_save_LIBS=$LIBS 32156 LIBS="-ljpeg $LIBS" 32157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32158 /* end confdefs.h. */ 32159 32160 32161 int 32162 main () 32163 { 32164 return main (); 32165 ; 32166 return 0; 32167 } 32168 _ACEOF 32169 if ac_fn_cxx_try_link "$LINENO"; then : 32170 ac_cv_lib_jpeg_main=yes 32171 else 32172 ac_cv_lib_jpeg_main=no 32173 fi 32174 rm -f core conftest.err conftest.$ac_objext \ 32175 conftest$ac_exeext conftest.$ac_ext 32176 LIBS=$ac_check_lib_save_LIBS 32177 fi 32178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5 32179 $as_echo "$ac_cv_lib_jpeg_main" >&6; } 32180 if test "x$ac_cv_lib_jpeg_main" = xyes; then : 32181 cat >>confdefs.h <<_ACEOF 32182 #define HAVE_LIBJPEG 1 32183 _ACEOF 32184 32185 LIBS="-ljpeg $LIBS" 32186 32187 else 32188 USE_EXTERNAL_LIBJPEG=false 32189 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5 32190 $as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;} 32191 32192 fi 32193 32194 32195 32196 ############################################################################### 32197 # 32198 # Check for the gif library 32199 # 32200 32201 32202 # Check whether --with-giflib was given. 32203 if test "${with_giflib+set}" = set; then : 32204 withval=$with_giflib; 32205 fi 32206 32207 32208 32209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 32210 $as_echo_n "checking for which giflib to use... " >&6; } 32211 32212 # default is bundled 32213 DEFAULT_GIFLIB=bundled 32214 32215 # 32216 # if user didn't specify, use DEFAULT_GIFLIB 32217 # 32218 if test "x${with_giflib}" = "x"; then 32219 with_giflib=${DEFAULT_GIFLIB} 32220 fi 32221 32222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 32223 $as_echo "${with_giflib}" >&6; } 32224 32225 if test "x${with_giflib}" = "xbundled"; then 32226 USE_EXTERNAL_LIBGIF=false 32227 elif test "x${with_giflib}" = "xsystem"; then 32228 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 32229 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 32230 32231 else 32232 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 32233 fi 32234 32235 32236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 32237 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 32238 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 32239 $as_echo_n "(cached) " >&6 32240 else 32241 ac_check_lib_save_LIBS=$LIBS 32242 LIBS="-lgif $LIBS" 32243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32244 /* end confdefs.h. */ 32245 32246 /* Override any GCC internal prototype to avoid an error. 32247 Use char because int might match the return type of a GCC 32248 builtin and then its argument prototype would still apply. */ 32249 #ifdef __cplusplus 32250 extern "C" 32251 #endif 32252 char DGifGetCode (); 32253 int 32254 main () 32255 { 32256 return DGifGetCode (); 32257 ; 32258 return 0; 32259 } 32260 _ACEOF 32261 if ac_fn_cxx_try_link "$LINENO"; then : 32262 ac_cv_lib_gif_DGifGetCode=yes 32263 else 32264 ac_cv_lib_gif_DGifGetCode=no 32265 fi 32266 rm -f core conftest.err conftest.$ac_objext \ 32267 conftest$ac_exeext conftest.$ac_ext 32268 LIBS=$ac_check_lib_save_LIBS 32269 fi 32270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 32271 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 32272 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 32273 cat >>confdefs.h <<_ACEOF 32274 #define HAVE_LIBGIF 1 32275 _ACEOF 32276 32277 LIBS="-lgif $LIBS" 32278 32279 else 32280 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 32281 fi 32282 32283 32284 USE_EXTERNAL_LIBGIF=true 32285 else 32286 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 32287 fi 32288 32289 32290 ############################################################################### 32291 # 32292 # Check for the zlib library 32293 # 32294 32295 32296 # Check whether --with-zlib was given. 32297 if test "${with_zlib+set}" = set; then : 32298 withval=$with_zlib; 32299 fi 32300 32301 32302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 32303 $as_echo_n "checking for compress in -lz... " >&6; } 32304 if ${ac_cv_lib_z_compress+:} false; then : 32305 $as_echo_n "(cached) " >&6 32306 else 32307 ac_check_lib_save_LIBS=$LIBS 32308 LIBS="-lz $LIBS" 32309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32310 /* end confdefs.h. */ 32311 32312 /* Override any GCC internal prototype to avoid an error. 32313 Use char because int might match the return type of a GCC 32314 builtin and then its argument prototype would still apply. */ 32315 #ifdef __cplusplus 32316 extern "C" 32317 #endif 32318 char compress (); 32319 int 32320 main () 32321 { 32322 return compress (); 32323 ; 32324 return 0; 32325 } 32326 _ACEOF 32327 if ac_fn_cxx_try_link "$LINENO"; then : 32328 ac_cv_lib_z_compress=yes 32329 else 32330 ac_cv_lib_z_compress=no 32331 fi 32332 rm -f core conftest.err conftest.$ac_objext \ 32333 conftest$ac_exeext conftest.$ac_ext 32334 LIBS=$ac_check_lib_save_LIBS 32335 fi 32336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 32337 $as_echo "$ac_cv_lib_z_compress" >&6; } 32338 if test "x$ac_cv_lib_z_compress" = xyes; then : 32339 ZLIB_FOUND=yes 32340 else 32341 ZLIB_FOUND=no 32342 fi 32343 32344 32345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 32346 $as_echo_n "checking for which zlib to use... " >&6; } 32347 32348 DEFAULT_ZLIB=bundled 32349 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 32350 # 32351 # On macosx default is system...on others default is 32352 # 32353 DEFAULT_ZLIB=system 32354 fi 32355 32356 if test "x${ZLIB_FOUND}" != "xyes"; then 32357 # 32358 # If we don't find any system...set default to bundled 32359 # 32360 DEFAULT_ZLIB=bundled 32361 fi 32362 32363 # 32364 # If user didn't specify, use DEFAULT_ZLIB 32365 # 32366 if test "x${with_zlib}" = "x"; then 32367 with_zlib=${DEFAULT_ZLIB} 32368 fi 32369 32370 if test "x${with_zlib}" = "xbundled"; then 32371 USE_EXTERNAL_LIBZ=false 32372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 32373 $as_echo "bundled" >&6; } 32374 elif test "x${with_zlib}" = "xsystem"; then 32375 if test "x${ZLIB_FOUND}" = "xyes"; then 32376 USE_EXTERNAL_LIBZ=true 32377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 32378 $as_echo "system" >&6; } 32379 else 32380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 32381 $as_echo "system not found" >&6; } 32382 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 32383 fi 32384 else 32385 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 32386 fi 32387 32388 32389 32390 ############################################################################### 32391 LIBZIP_CAN_USE_MMAP=true 32392 32393 32394 32395 ############################################################################### 32396 # 32397 # Check if altzone exists in time.h 32398 # 32399 32400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32401 /* end confdefs.h. */ 32402 #include <time.h> 32403 int 32404 main () 32405 { 32406 return (int)altzone; 32407 ; 32408 return 0; 32409 } 32410 _ACEOF 32411 if ac_fn_cxx_try_link "$LINENO"; then : 32412 has_altzone=yes 32413 else 32414 has_altzone=no 32415 fi 32416 rm -f core conftest.err conftest.$ac_objext \ 32417 conftest$ac_exeext conftest.$ac_ext 32418 if test "x$has_altzone" = xyes; then 32419 32420 $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h 32421 32422 fi 32423 32424 ############################################################################### 32425 # 32426 # Check the maths library 32427 # 32428 32429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 32430 $as_echo_n "checking for cos in -lm... " >&6; } 32431 if ${ac_cv_lib_m_cos+:} false; then : 32432 $as_echo_n "(cached) " >&6 32433 else 32434 ac_check_lib_save_LIBS=$LIBS 32435 LIBS="-lm $LIBS" 32436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32437 /* end confdefs.h. */ 32438 32439 /* Override any GCC internal prototype to avoid an error. 32440 Use char because int might match the return type of a GCC 32441 builtin and then its argument prototype would still apply. */ 32442 #ifdef __cplusplus 32443 extern "C" 32444 #endif 32445 char cos (); 32446 int 32447 main () 32448 { 32449 return cos (); 32450 ; 32451 return 0; 32452 } 32453 _ACEOF 32454 if ac_fn_cxx_try_link "$LINENO"; then : 32455 ac_cv_lib_m_cos=yes 32456 else 32457 ac_cv_lib_m_cos=no 32458 fi 32459 rm -f core conftest.err conftest.$ac_objext \ 32460 conftest$ac_exeext conftest.$ac_ext 32461 LIBS=$ac_check_lib_save_LIBS 32462 fi 32463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 32464 $as_echo "$ac_cv_lib_m_cos" >&6; } 32465 if test "x$ac_cv_lib_m_cos" = xyes; then : 32466 cat >>confdefs.h <<_ACEOF 32467 #define HAVE_LIBM 1 32468 _ACEOF 32469 32470 LIBS="-lm $LIBS" 32471 32472 else 32473 32474 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 32475 $as_echo "$as_me: Maths library was not found" >&6;} 32476 32477 fi 32478 32479 32480 32481 ############################################################################### 32482 # 32483 # Check for libdl.so 32484 32485 save_LIBS="$LIBS" 32486 LIBS="" 32487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 32488 $as_echo_n "checking for dlopen in -ldl... " >&6; } 32489 if ${ac_cv_lib_dl_dlopen+:} false; then : 32490 $as_echo_n "(cached) " >&6 32491 else 32492 ac_check_lib_save_LIBS=$LIBS 32493 LIBS="-ldl $LIBS" 32494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32495 /* end confdefs.h. */ 32496 32497 /* Override any GCC internal prototype to avoid an error. 32498 Use char because int might match the return type of a GCC 32499 builtin and then its argument prototype would still apply. */ 32500 #ifdef __cplusplus 32501 extern "C" 32502 #endif 32503 char dlopen (); 32504 int 32505 main () 32506 { 32507 return dlopen (); 32508 ; 32509 return 0; 32510 } 32511 _ACEOF 32512 if ac_fn_cxx_try_link "$LINENO"; then : 32513 ac_cv_lib_dl_dlopen=yes 32514 else 32515 ac_cv_lib_dl_dlopen=no 32516 fi 32517 rm -f core conftest.err conftest.$ac_objext \ 32518 conftest$ac_exeext conftest.$ac_ext 32519 LIBS=$ac_check_lib_save_LIBS 32520 fi 32521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 32522 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 32523 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 32524 cat >>confdefs.h <<_ACEOF 32525 #define HAVE_LIBDL 1 32526 _ACEOF 32527 32528 LIBS="-ldl $LIBS" 32529 32530 fi 32531 32532 LIBDL="$LIBS" 32533 32534 LIBS="$save_LIBS" 32535 32536 32537 32538 ############################################################################### 32539 # 32540 # statically link libstdc++ before C++ ABI is stablized on Linux unless 32541 # dynamic build is configured on command line. 32542 # 32543 32544 # Check whether --with-stdc++lib was given. 32545 if test "${with_stdc__lib+set}" = set; then : 32546 withval=$with_stdc__lib; 32547 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 32548 && test "x$with_stdc__lib" != xdefault; then 32549 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 32550 fi 32551 32552 else 32553 with_stdc__lib=default 32554 32555 fi 32556 32557 32558 if test "x$OPENJDK_TARGET_OS" = xlinux; then 32559 # Test if -lstdc++ works. 32560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 32561 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 32562 ac_ext=cpp 32563 ac_cpp='$CXXCPP $CPPFLAGS' 32564 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32565 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32566 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32567 32568 OLD_CXXFLAGS="$CXXFLAGS" 32569 CXXFLAGS="$CXXFLAGS -lstdc++" 32570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32571 /* end confdefs.h. */ 32572 32573 int 32574 main () 32575 { 32576 return 0; 32577 ; 32578 return 0; 32579 } 32580 _ACEOF 32581 if ac_fn_cxx_try_link "$LINENO"; then : 32582 has_dynamic_libstdcxx=yes 32583 else 32584 has_dynamic_libstdcxx=no 32585 fi 32586 rm -f core conftest.err conftest.$ac_objext \ 32587 conftest$ac_exeext conftest.$ac_ext 32588 CXXFLAGS="$OLD_CXXFLAGS" 32589 ac_ext=cpp 32590 ac_cpp='$CXXCPP $CPPFLAGS' 32591 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32592 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32593 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32594 32595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 32596 $as_echo "$has_dynamic_libstdcxx" >&6; } 32597 32598 # Test if stdc++ can be linked statically. 32599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 32600 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 32601 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 32602 ac_ext=cpp 32603 ac_cpp='$CXXCPP $CPPFLAGS' 32604 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32605 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32606 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32607 32608 OLD_LIBS="$LIBS" 32609 OLD_CXX="$CXX" 32610 LIBS="$STATIC_STDCXX_FLAGS" 32611 CXX="$CC" 32612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32613 /* end confdefs.h. */ 32614 32615 int 32616 main () 32617 { 32618 return 0; 32619 ; 32620 return 0; 32621 } 32622 _ACEOF 32623 if ac_fn_cxx_try_link "$LINENO"; then : 32624 has_static_libstdcxx=yes 32625 else 32626 has_static_libstdcxx=no 32627 fi 32628 rm -f core conftest.err conftest.$ac_objext \ 32629 conftest$ac_exeext conftest.$ac_ext 32630 LIBS="$OLD_LIBS" 32631 CXX="$OLD_CXX" 32632 ac_ext=cpp 32633 ac_cpp='$CXXCPP $CPPFLAGS' 32634 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32635 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32636 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 32637 32638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 32639 $as_echo "$has_static_libstdcxx" >&6; } 32640 32641 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 32642 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 32643 fi 32644 32645 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 32646 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 32647 fi 32648 32649 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 32650 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 32651 fi 32652 32653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 32654 $as_echo_n "checking how to link with libstdc++... " >&6; } 32655 # If dynamic was requested, it's available since it would fail above otherwise. 32656 # If dynamic wasn't requested, go with static unless it isn't available. 32657 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32658 LIBCXX="$LIBCXX -lstdc++" 32659 LDCXX="$CXX" 32660 STATIC_CXX_SETTING="STATIC_CXX=false" 32661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 32662 $as_echo "dynamic" >&6; } 32663 else 32664 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 32665 LDCXX="$CC" 32666 STATIC_CXX_SETTING="STATIC_CXX=true" 32667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 32668 $as_echo "static" >&6; } 32669 fi 32670 fi 32671 32672 32673 if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32674 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 32675 32676 pkg_failed=no 32677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 32678 $as_echo_n "checking for LIBFFI... " >&6; } 32679 32680 if test -n "$LIBFFI_CFLAGS"; then 32681 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 32682 elif test -n "$PKG_CONFIG"; then 32683 if test -n "$PKG_CONFIG" && \ 32684 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 32685 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 32686 ac_status=$? 32687 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32688 test $ac_status = 0; }; then 32689 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 32690 else 32691 pkg_failed=yes 32692 fi 32693 else 32694 pkg_failed=untried 32695 fi 32696 if test -n "$LIBFFI_LIBS"; then 32697 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 32698 elif test -n "$PKG_CONFIG"; then 32699 if test -n "$PKG_CONFIG" && \ 32700 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 32701 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 32702 ac_status=$? 32703 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32704 test $ac_status = 0; }; then 32705 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 32706 else 32707 pkg_failed=yes 32708 fi 32709 else 32710 pkg_failed=untried 32711 fi 32712 32713 32714 32715 if test $pkg_failed = yes; then 32716 32717 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 32718 _pkg_short_errors_supported=yes 32719 else 32720 _pkg_short_errors_supported=no 32721 fi 32722 if test $_pkg_short_errors_supported = yes; then 32723 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 32724 else 32725 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 32726 fi 32727 # Put the nasty error message in config.log where it belongs 32728 echo "$LIBFFI_PKG_ERRORS" >&5 32729 32730 as_fn_error $? "Package requirements (libffi) were not met: 32731 32732 $LIBFFI_PKG_ERRORS 32733 32734 Consider adjusting the PKG_CONFIG_PATH environment variable if you 32735 installed software in a non-standard prefix. 32736 32737 Alternatively, you may set the environment variables LIBFFI_CFLAGS 32738 and LIBFFI_LIBS to avoid the need to call pkg-config. 32739 See the pkg-config man page for more details. 32740 " "$LINENO" 5 32741 elif test $pkg_failed = untried; then 32742 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32743 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32744 as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it 32745 is in your PATH or set the PKG_CONFIG environment variable to the full 32746 path to pkg-config. 32747 32748 Alternatively, you may set the environment variables LIBFFI_CFLAGS 32749 and LIBFFI_LIBS to avoid the need to call pkg-config. 32750 See the pkg-config man page for more details. 32751 32752 To get pkg-config, see <http://pkg-config.freedesktop.org/>. 32753 See \`config.log' for more details" "$LINENO" 5; } 32754 else 32755 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 32756 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 32757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32758 $as_echo "yes" >&6; } 32759 : 32760 fi 32761 32762 fi 32763 32764 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 32765 # Extract the first word of "llvm-config", so it can be a program name with args. 32766 set dummy llvm-config; ac_word=$2 32767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32768 $as_echo_n "checking for $ac_word... " >&6; } 32769 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 32770 $as_echo_n "(cached) " >&6 32771 else 32772 if test -n "$LLVM_CONFIG"; then 32773 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 32774 else 32775 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32776 for as_dir in $PATH 32777 do 32778 IFS=$as_save_IFS 32779 test -z "$as_dir" && as_dir=. 32780 for ac_exec_ext in '' $ac_executable_extensions; do 32781 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 32782 ac_cv_prog_LLVM_CONFIG="llvm-config" 32783 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32784 break 2 32785 fi 32786 done 32787 done 32788 IFS=$as_save_IFS 32789 32790 fi 32791 fi 32792 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 32793 if test -n "$LLVM_CONFIG"; then 32794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 32795 $as_echo "$LLVM_CONFIG" >&6; } 32796 else 32797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32798 $as_echo "no" >&6; } 32799 fi 32800 32801 32802 32803 if test "x$LLVM_CONFIG" != xllvm-config; then 32804 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 32805 fi 32806 32807 llvm_components="jit mcjit engine nativecodegen native" 32808 unset LLVM_CFLAGS 32809 for flag in $("$LLVM_CONFIG" --cxxflags); do 32810 if echo "${flag}" | grep -q '^-[ID]'; then 32811 if test "${flag}" != "-D_DEBUG" ; then 32812 if test "${LLVM_CFLAGS}" != "" ; then 32813 LLVM_CFLAGS="${LLVM_CFLAGS} " 32814 fi 32815 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 32816 fi 32817 fi 32818 done 32819 llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//') 32820 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 32821 32822 unset LLVM_LDFLAGS 32823 for flag in $("${LLVM_CONFIG}" --ldflags); do 32824 if echo "${flag}" | grep -q '^-L'; then 32825 if test "${LLVM_LDFLAGS}" != ""; then 32826 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 32827 fi 32828 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 32829 fi 32830 done 32831 32832 unset LLVM_LIBS 32833 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 32834 if echo "${flag}" | grep -q '^-l'; then 32835 if test "${LLVM_LIBS}" != ""; then 32836 LLVM_LIBS="${LLVM_LIBS} " 32837 fi 32838 LLVM_LIBS="${LLVM_LIBS}${flag}" 32839 fi 32840 done 32841 32842 32843 32844 32845 fi 32846 32847 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 32848 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$LIBCXX" = x; then 32849 LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 32850 fi 32851 32852 # TODO better (platform agnostic) test 32853 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$GCC" = xyes; then 32854 LIBCXX="-lstdc++" 32855 fi 32856 32857 32858 32859 32860 32861 # After we have toolchain and the paths to all libraries (needed by msys), we can compile the fixpath helper 32862 32863 # When using cygwin or msys, we need a wrapper binary that renames 32864 # /cygdrive/c/ arguments into c:/ arguments and peeks into 32865 # @files and rewrites these too! This wrapper binary is 32866 # called fixpath. 32867 FIXPATH= 32868 if test "x$OPENJDK_BUILD_OS" = xwindows; then 32869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 32870 $as_echo_n "checking if fixpath can be created... " >&6; } 32871 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 32872 FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe" 32873 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 32874 FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC` 32875 FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN` 32876 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 32877 FIXPATH="$OUTPUT_ROOT/fixpath.exe -c" 32878 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 32879 FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC` 32880 FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN` 32881 32882 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 32883 # @ was chosen as separator to minimize risk of other tools messing around with it 32884 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq` 32885 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 32886 32887 FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list" 32888 fi 32889 rm -f $OUTPUT_ROOT/fixpath* 32890 cd $OUTPUT_ROOT 32891 $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1 32892 cd $CURDIR 32893 32894 if test ! -x $OUTPUT_ROOT/fixpath.exe; then 32895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32896 $as_echo "no" >&6; } 32897 cat $OUTPUT_ROOT/fixpath1.log 32898 as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5 32899 fi 32900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32901 $as_echo "yes" >&6; } 32902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 32903 $as_echo_n "checking if fixpath.exe works... " >&6; } 32904 cd $OUTPUT_ROOT 32905 $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1 32906 cd $CURDIR 32907 if test ! -x $OUTPUT_ROOT/fixpath2.exe; then 32908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32909 $as_echo "no" >&6; } 32910 cat $OUTPUT_ROOT/fixpath2.log 32911 as_fn_error $? "fixpath did not work!" "$LINENO" 5 32912 fi 32913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32914 $as_echo "yes" >&6; } 32915 rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj 32916 fi 32917 32918 32919 32920 32921 ############################################################################### 32922 # 32923 # We need to do some final tweaking, when everything else is done. 32924 # 32925 ############################################################################### 32926 32927 32928 HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET" 32929 32930 32931 # The name of the Service Agent jar. 32932 SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}" 32933 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 32934 SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}" 32935 fi 32936 32937 32938 32939 32940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 32941 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 32942 32943 if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then 32944 ENABLE_INTREE_EC=yes 32945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32946 $as_echo "yes" >&6; } 32947 else 32948 ENABLE_INTREE_EC=no 32949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32950 $as_echo "no" >&6; } 32951 fi 32952 32953 32954 32955 32956 ############################################################################### 32957 # 32958 # Configure parts of the build that only affect the build performance, 32959 # not the result. 32960 # 32961 ############################################################################### 32962 32963 32964 # How many cores do we have on this build system? 32965 32966 # Check whether --with-num-cores was given. 32967 if test "${with_num_cores+set}" = set; then : 32968 withval=$with_num_cores; 32969 fi 32970 32971 if test "x$with_num_cores" = x; then 32972 # The number of cores were not specified, try to probe them. 32973 32974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 32975 $as_echo_n "checking for number of cores... " >&6; } 32976 NUM_CORES=1 32977 FOUND_CORES=no 32978 32979 if test -f /proc/cpuinfo; then 32980 # Looks like a Linux (or cygwin) system 32981 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 32982 FOUND_CORES=yes 32983 elif test -x /usr/sbin/psrinfo; then 32984 # Looks like a Solaris system 32985 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 32986 FOUND_CORES=yes 32987 elif test -x /usr/sbin/system_profiler; then 32988 # Looks like a MacOSX system 32989 NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk '{print $5}'` 32990 FOUND_CORES=yes 32991 elif test -n "$NUMBER_OF_PROCESSORS"; then 32992 # On windows, look in the env 32993 NUM_CORES=$NUMBER_OF_PROCESSORS 32994 FOUND_CORES=yes 32995 fi 32996 32997 if test "x$FOUND_CORES" = xyes; then 32998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 32999 $as_echo "$NUM_CORES" >&6; } 33000 else 33001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 33002 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 33003 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 33004 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 33005 fi 33006 33007 33008 else 33009 NUM_CORES=$with_num_cores 33010 fi 33011 33012 33013 33014 # How much memory do we have on this build system? 33015 33016 # Check whether --with-memory-size was given. 33017 if test "${with_memory_size+set}" = set; then : 33018 withval=$with_memory_size; 33019 fi 33020 33021 if test "x$with_memory_size" = x; then 33022 # The memory size was not specified, try to probe it. 33023 33024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 33025 $as_echo_n "checking for memory size... " >&6; } 33026 # Default to 1024 MB 33027 MEMORY_SIZE=1024 33028 FOUND_MEM=no 33029 33030 if test -f /proc/meminfo; then 33031 # Looks like a Linux (or cygwin) system 33032 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 33033 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 33034 FOUND_MEM=yes 33035 elif test -x /usr/sbin/prtconf; then 33036 # Looks like a Solaris system 33037 MEMORY_SIZE=`/usr/sbin/prtconf | grep "Memory size" | awk '{ print $3 }'` 33038 FOUND_MEM=yes 33039 elif test -x /usr/sbin/system_profiler; then 33040 # Looks like a MacOSX system 33041 MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk '{print $2}'` 33042 MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024` 33043 FOUND_MEM=yes 33044 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 33045 # Windows, but without cygwin 33046 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 33047 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 33048 FOUND_MEM=yes 33049 fi 33050 33051 if test "x$FOUND_MEM" = xyes; then 33052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 33053 $as_echo "$MEMORY_SIZE MB" >&6; } 33054 else 33055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5 33056 $as_echo "could not detect memory size, defaulting to 1024 MB" >&6; } 33057 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 33058 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 33059 fi 33060 33061 else 33062 MEMORY_SIZE=$with_memory_size 33063 fi 33064 33065 33066 33067 # Provide a decent default number of parallel jobs for make depending on 33068 # number of cores, amount of memory and machine architecture. 33069 33070 # Check whether --with-jobs was given. 33071 if test "${with_jobs+set}" = set; then : 33072 withval=$with_jobs; 33073 fi 33074 33075 if test "x$with_jobs" = x; then 33076 # Number of jobs was not specified, calculate. 33077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 33078 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 33079 # Approximate memory in GB, rounding up a bit. 33080 memory_gb=`expr $MEMORY_SIZE / 1100` 33081 # Pick the lowest of memory in gb and number of cores. 33082 if test "$memory_gb" -lt "$NUM_CORES"; then 33083 JOBS="$memory_gb" 33084 else 33085 JOBS="$NUM_CORES" 33086 # On bigger machines, leave some room for other processes to run 33087 if test "$JOBS" -gt "4"; then 33088 JOBS=`expr $JOBS '*' 90 / 100` 33089 fi 33090 fi 33091 # Cap number of jobs to 16 33092 if test "$JOBS" -gt "16"; then 33093 JOBS=16 33094 fi 33095 if test "$JOBS" -eq "0"; then 33096 JOBS=1 33097 fi 33098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 33099 $as_echo "$JOBS" >&6; } 33100 else 33101 JOBS=$with_jobs 33102 fi 33103 33104 33105 33106 # Setup smart javac (after cores and memory have been setup) 33107 33108 33109 # Check whether --with-sjavac-server-java was given. 33110 if test "${with_sjavac_server_java+set}" = set; then : 33111 withval=$with_sjavac_server_java; 33112 fi 33113 33114 33115 if test "x$with_sjavac_server_java" != x; then 33116 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 33117 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 33118 if test "x$FOUND_VERSION" = x; then 33119 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 33120 fi 33121 else 33122 SJAVAC_SERVER_JAVA="" 33123 # Hotspot specific options. 33124 33125 $ECHO "Check if jvm arg is ok: -verbosegc" >&5 33126 $ECHO "Command: $JAVA -verbosegc -version" >&5 33127 OUTPUT=`$JAVA -verbosegc -version 2>&1` 33128 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33129 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33130 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33131 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc" 33132 JVM_ARG_OK=true 33133 else 33134 $ECHO "Arg failed:" >&5 33135 $ECHO "$OUTPUT" >&5 33136 JVM_ARG_OK=false 33137 fi 33138 33139 # JRockit specific options. 33140 33141 $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5 33142 $ECHO "Command: $JAVA -Xverbose:gc -version" >&5 33143 OUTPUT=`$JAVA -Xverbose:gc -version 2>&1` 33144 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33145 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33146 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33147 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc" 33148 JVM_ARG_OK=true 33149 else 33150 $ECHO "Arg failed:" >&5 33151 $ECHO "$OUTPUT" >&5 33152 JVM_ARG_OK=false 33153 fi 33154 33155 SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA" 33156 fi 33157 33158 33159 if test "$MEMORY_SIZE" -gt "2500"; then 33160 33161 $ECHO "Check if jvm arg is ok: -d64" >&5 33162 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 33163 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 33164 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33165 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33166 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33167 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64" 33168 JVM_ARG_OK=true 33169 else 33170 $ECHO "Arg failed:" >&5 33171 $ECHO "$OUTPUT" >&5 33172 JVM_ARG_OK=false 33173 fi 33174 33175 if test "$JVM_ARG_OK" = true; then 33176 JVM_64BIT=true 33177 JVM_ARG_OK=false 33178 fi 33179 fi 33180 33181 if test "$JVM_64BIT" = true; then 33182 if test "$MEMORY_SIZE" -gt "17000"; then 33183 33184 $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5 33185 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5 33186 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1` 33187 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33188 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33189 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33190 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G" 33191 JVM_ARG_OK=true 33192 else 33193 $ECHO "Arg failed:" >&5 33194 $ECHO "$OUTPUT" >&5 33195 JVM_ARG_OK=false 33196 fi 33197 33198 fi 33199 if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then 33200 33201 $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5 33202 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5 33203 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1` 33204 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33205 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33206 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33207 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G" 33208 JVM_ARG_OK=true 33209 else 33210 $ECHO "Arg failed:" >&5 33211 $ECHO "$OUTPUT" >&5 33212 JVM_ARG_OK=false 33213 fi 33214 33215 fi 33216 if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then 33217 33218 $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5 33219 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5 33220 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1` 33221 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33222 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33223 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33224 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G" 33225 JVM_ARG_OK=true 33226 else 33227 $ECHO "Arg failed:" >&5 33228 $ECHO "$OUTPUT" >&5 33229 JVM_ARG_OK=false 33230 fi 33231 33232 fi 33233 if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then 33234 33235 $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5 33236 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5 33237 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1` 33238 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33239 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33240 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33241 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M" 33242 JVM_ARG_OK=true 33243 else 33244 $ECHO "Arg failed:" >&5 33245 $ECHO "$OUTPUT" >&5 33246 JVM_ARG_OK=false 33247 fi 33248 33249 fi 33250 fi 33251 if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then 33252 33253 $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5 33254 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5 33255 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1` 33256 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33257 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33258 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33259 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M" 33260 JVM_ARG_OK=true 33261 else 33262 $ECHO "Arg failed:" >&5 33263 $ECHO "$OUTPUT" >&5 33264 JVM_ARG_OK=false 33265 fi 33266 33267 fi 33268 if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then 33269 33270 $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5 33271 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5 33272 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1` 33273 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33274 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33275 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33276 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M" 33277 JVM_ARG_OK=true 33278 else 33279 $ECHO "Arg failed:" >&5 33280 $ECHO "$OUTPUT" >&5 33281 JVM_ARG_OK=false 33282 fi 33283 33284 fi 33285 if test "$JVM_ARG_OK" = false; then 33286 33287 $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5 33288 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5 33289 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1` 33290 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 33291 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 33292 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 33293 SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M" 33294 JVM_ARG_OK=true 33295 else 33296 $ECHO "Arg failed:" >&5 33297 $ECHO "$OUTPUT" >&5 33298 JVM_ARG_OK=false 33299 fi 33300 33301 fi 33302 33303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 33304 $as_echo_n "checking whether to use sjavac... " >&6; } 33305 # Check whether --enable-sjavac was given. 33306 if test "${enable_sjavac+set}" = set; then : 33307 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 33308 else 33309 ENABLE_SJAVAC='no' 33310 fi 33311 33312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 33313 $as_echo "$ENABLE_SJAVAC" >&6; } 33314 33315 33316 if test "x$ENABLE_SJAVAC" = xyes; then 33317 SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers" 33318 else 33319 SJAVAC_SERVER_DIR= 33320 fi 33321 33322 33323 33324 33325 # Can the C/C++ compiler use precompiled headers? 33326 33327 33328 ############################################################################### 33329 # 33330 # Can the C/C++ compiler use precompiled headers? 33331 # 33332 # Check whether --enable-precompiled-headers was given. 33333 if test "${enable_precompiled_headers+set}" = set; then : 33334 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 33335 else 33336 ENABLE_PRECOMPH=yes 33337 fi 33338 33339 33340 USE_PRECOMPILED_HEADER=1 33341 if test "x$ENABLE_PRECOMPH" = xno; then 33342 USE_PRECOMPILED_HEADER=0 33343 fi 33344 33345 if test "x$ENABLE_PRECOMPH" = xyes; then 33346 # Check that the compiler actually supports precomp headers. 33347 if test "x$GCC" = xyes; then 33348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 33349 $as_echo_n "checking that precompiled headers work... " >&6; } 33350 echo "int alfa();" > conftest.h 33351 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 33352 if test ! -f conftest.hpp.gch; then 33353 USE_PRECOMPILED_HEADER=0 33354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33355 $as_echo "no" >&6; } 33356 else 33357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33358 $as_echo "yes" >&6; } 33359 fi 33360 rm -f conftest.h conftest.hpp.gch 33361 fi 33362 fi 33363 33364 33365 33366 33367 # Setup use of ccache, if available 33368 33369 # Check whether --enable-ccache was given. 33370 if test "${enable_ccache+set}" = set; then : 33371 enableval=$enable_ccache; ENABLE_CCACHE=${enable_ccache} 33372 else 33373 ENABLE_CCACHE=yes 33374 fi 33375 33376 if test "x$ENABLE_CCACHE" = xyes; then 33377 OLD_PATH="$PATH" 33378 if test "x$TOOLS_DIR" != x; then 33379 PATH=$TOOLS_DIR:$PATH 33380 fi 33381 # Extract the first word of "ccache", so it can be a program name with args. 33382 set dummy ccache; ac_word=$2 33383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33384 $as_echo_n "checking for $ac_word... " >&6; } 33385 if ${ac_cv_path_CCACHE+:} false; then : 33386 $as_echo_n "(cached) " >&6 33387 else 33388 case $CCACHE in 33389 [\\/]* | ?:[\\/]*) 33390 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 33391 ;; 33392 *) 33393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33394 for as_dir in $PATH 33395 do 33396 IFS=$as_save_IFS 33397 test -z "$as_dir" && as_dir=. 33398 for ac_exec_ext in '' $ac_executable_extensions; do 33399 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 33400 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 33401 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33402 break 2 33403 fi 33404 done 33405 done 33406 IFS=$as_save_IFS 33407 33408 ;; 33409 esac 33410 fi 33411 CCACHE=$ac_cv_path_CCACHE 33412 if test -n "$CCACHE"; then 33413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 33414 $as_echo "$CCACHE" >&6; } 33415 else 33416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33417 $as_echo "no" >&6; } 33418 fi 33419 33420 33421 PATH="$OLD_PATH" 33422 else 33423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ccache" >&5 33424 $as_echo_n "checking for ccache... " >&6; } 33425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: explicitly disabled" >&5 33426 $as_echo "explicitly disabled" >&6; } 33427 CCACHE= 33428 fi 33429 33430 33431 33432 # Check whether --with-ccache-dir was given. 33433 if test "${with_ccache_dir+set}" = set; then : 33434 withval=$with_ccache_dir; 33435 fi 33436 33437 33438 if test "x$with_ccache_dir" != x; then 33439 # When using a non home ccache directory, assume the use is to share ccache files 33440 # with other users. Thus change the umask. 33441 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 33442 fi 33443 CCACHE_FOUND="" 33444 if test "x$CCACHE" != x; then 33445 33446 if test "x$CCACHE" != x; then 33447 CCACHE_FOUND="true" 33448 # Only use ccache if it is 3.1.4 or later, which supports 33449 # precompiled headers. 33450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5 33451 $as_echo_n "checking if ccache supports precompiled headers... " >&6; } 33452 HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null` 33453 if test "x$HAS_GOOD_CCACHE" = x; then 33454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5 33455 $as_echo "no, disabling ccache" >&6; } 33456 CCACHE= 33457 else 33458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33459 $as_echo "yes" >&6; } 33460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 33461 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 33462 PUSHED_FLAGS="$CXXFLAGS" 33463 CXXFLAGS="-fpch-preprocess $CXXFLAGS" 33464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33465 /* end confdefs.h. */ 33466 33467 int 33468 main () 33469 { 33470 33471 ; 33472 return 0; 33473 } 33474 _ACEOF 33475 if ac_fn_cxx_try_compile "$LINENO"; then : 33476 CC_KNOWS_CCACHE_TRICK=yes 33477 else 33478 CC_KNOWS_CCACHE_TRICK=no 33479 fi 33480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33481 CXXFLAGS="$PUSHED_FLAGS" 33482 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 33483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33484 $as_echo "yes" >&6; } 33485 else 33486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5 33487 $as_echo "no, disabling ccaching of precompiled headers" >&6; } 33488 CCACHE= 33489 fi 33490 fi 33491 fi 33492 33493 if test "x$CCACHE" != x; then 33494 CCACHE_SLOPPINESS=time_macros 33495 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE" 33496 CCACHE_FLAGS=-fpch-preprocess 33497 33498 if test "x$SET_CCACHE_DIR" != x; then 33499 mkdir -p $CCACHE_DIR > /dev/null 2>&1 33500 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 33501 fi 33502 fi 33503 33504 fi 33505 33506 33507 ############################################################################### 33508 # 33509 # And now the finish... 33510 # 33511 ############################################################################### 33512 33513 # Check for some common pitfalls 33514 33515 if test x"$OPENJDK_BUILD_OS" = xwindows; then 33516 file_to_test="$SRC_ROOT/LICENSE" 33517 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 33518 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 33519 fi 33520 fi 33521 33522 33523 33524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 33525 $as_echo_n "checking if build directory is on local disk... " >&6; } 33526 33527 # df -l lists only local disks; if the given directory is not found then 33528 # a non-zero exit code is given 33529 if test "x$DF" = x; then 33530 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33531 # msys does not have df; use Windows "net use" instead. 33532 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 33533 if test "x$IS_NETWORK_DISK" = x; then 33534 OUTPUT_DIR_IS_LOCAL="yes" 33535 else 33536 OUTPUT_DIR_IS_LOCAL="no" 33537 fi 33538 else 33539 # No df here, say it's local 33540 OUTPUT_DIR_IS_LOCAL="yes" 33541 fi 33542 else 33543 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 33544 OUTPUT_DIR_IS_LOCAL="yes" 33545 else 33546 OUTPUT_DIR_IS_LOCAL="no" 33547 fi 33548 fi 33549 33550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 33551 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 33552 33553 33554 33555 # Check if the user has any old-style ALT_ variables set. 33556 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 33557 33558 # Before generating output files, test if they exist. If they do, this is a reconfigure. 33559 # Since we can't properly handle the dependencies for this, warn the user about the situation 33560 if test -e $OUTPUT_ROOT/spec.gmk; then 33561 IS_RECONFIGURE=yes 33562 else 33563 IS_RECONFIGURE=no 33564 fi 33565 33566 if test -e $SRC_ROOT/build/.hide-configure-performance-hints; then 33567 HIDE_PERFORMANCE_HINTS=yes 33568 else 33569 HIDE_PERFORMANCE_HINTS=no 33570 # Hide it the next time around... 33571 $TOUCH $SRC_ROOT/build/.hide-configure-performance-hints > /dev/null 2>&1 33572 fi 33573 33574 33575 33576 # At the end, call the custom hook. (Dummy macro if no custom sources available) 33577 33578 33579 # We're messing a bit with internal autoconf variables to put the config.status 33580 # in the output directory instead of the current directory. 33581 CONFIG_STATUS="$OUTPUT_ROOT/config.status" 33582 # Create the actual output files. Now the main work of configure is done. 33583 cat >confcache <<\_ACEOF 33584 # This file is a shell script that caches the results of configure 33585 # tests run on this system so they can be shared between configure 33586 # scripts and configure runs, see configure's option --config-cache. 33587 # It is not useful on other systems. If it contains results you don't 33588 # want to keep, you may remove or edit it. 33589 # 33590 # config.status only pays attention to the cache file if you give it 33591 # the --recheck option to rerun configure. 33592 # 33593 # `ac_cv_env_foo' variables (set or unset) will be overridden when 33594 # loading this file, other *unset* `ac_cv_foo' will be assigned the 33595 # following values. 33596 33597 _ACEOF 33598 33599 # The following way of writing the cache mishandles newlines in values, 33600 # but we know of no workaround that is simple, portable, and efficient. 33601 # So, we kill variables containing newlines. 33602 # Ultrix sh set writes to stderr and can't be redirected directly, 33603 # and sets the high bit in the cache file unless we assign to the vars. 33604 ( 33605 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 33606 eval ac_val=\$$ac_var 33607 case $ac_val in #( 33608 *${as_nl}*) 33609 case $ac_var in #( 33610 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 33611 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 33612 esac 33613 case $ac_var in #( 33614 _ | IFS | as_nl) ;; #( 33615 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 33616 *) { eval $ac_var=; unset $ac_var;} ;; 33617 esac ;; 33618 esac 33619 done 33620 33621 (set) 2>&1 | 33622 case $as_nl`(ac_space=' '; set) 2>&1` in #( 33623 *${as_nl}ac_space=\ *) 33624 # `set' does not quote correctly, so add quotes: double-quote 33625 # substitution turns \\\\ into \\, and sed turns \\ into \. 33626 sed -n \ 33627 "s/'/'\\\\''/g; 33628 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 33629 ;; #( 33630 *) 33631 # `set' quotes correctly as required by POSIX, so do not add quotes. 33632 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 33633 ;; 33634 esac | 33635 sort 33636 ) | 33637 sed ' 33638 /^ac_cv_env_/b end 33639 t clear 33640 :clear 33641 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 33642 t end 33643 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 33644 :end' >>confcache 33645 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 33646 if test -w "$cache_file"; then 33647 if test "x$cache_file" != "x/dev/null"; then 33648 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 33649 $as_echo "$as_me: updating cache $cache_file" >&6;} 33650 if test ! -f "$cache_file" || test -h "$cache_file"; then 33651 cat confcache >"$cache_file" 33652 else 33653 case $cache_file in #( 33654 */* | ?:*) 33655 mv -f confcache "$cache_file"$$ && 33656 mv -f "$cache_file"$$ "$cache_file" ;; #( 33657 *) 33658 mv -f confcache "$cache_file" ;; 33659 esac 33660 fi 33661 fi 33662 else 33663 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 33664 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 33665 fi 33666 fi 33667 rm -f confcache 33668 33669 test "x$prefix" = xNONE && prefix=$ac_default_prefix 33670 # Let make expand exec_prefix. 33671 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 33672 33673 DEFS=-DHAVE_CONFIG_H 33674 33675 ac_libobjs= 33676 ac_ltlibobjs= 33677 U= 33678 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 33679 # 1. Remove the extension, and $U if already installed. 33680 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 33681 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 33682 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 33683 # will be set to the directory where LIBOBJS objects are built. 33684 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 33685 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 33686 done 33687 LIBOBJS=$ac_libobjs 33688 33689 LTLIBOBJS=$ac_ltlibobjs 33690 33691 33692 33693 : "${CONFIG_STATUS=./config.status}" 33694 ac_write_fail=0 33695 ac_clean_files_save=$ac_clean_files 33696 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 33697 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 33698 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 33699 as_write_fail=0 33700 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 33701 #! $SHELL 33702 # Generated by $as_me. 33703 # Run this file to recreate the current configuration. 33704 # Compiler output produced by configure, useful for debugging 33705 # configure, is in config.log if it exists. 33706 33707 debug=false 33708 ac_cs_recheck=false 33709 ac_cs_silent=false 33710 33711 SHELL=\${CONFIG_SHELL-$SHELL} 33712 export SHELL 33713 _ASEOF 33714 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 33715 ## -------------------- ## 33716 ## M4sh Initialization. ## 33717 ## -------------------- ## 33718 33719 # Be more Bourne compatible 33720 DUALCASE=1; export DUALCASE # for MKS sh 33721 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 33722 emulate sh 33723 NULLCMD=: 33724 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 33725 # is contrary to our usage. Disable this feature. 33726 alias -g '${1+"$@"}'='"$@"' 33727 setopt NO_GLOB_SUBST 33728 else 33729 case `(set -o) 2>/dev/null` in #( 33730 *posix*) : 33731 set -o posix ;; #( 33732 *) : 33733 ;; 33734 esac 33735 fi 33736 33737 33738 as_nl=' 33739 ' 33740 export as_nl 33741 # Printing a long string crashes Solaris 7 /usr/bin/printf. 33742 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 33743 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 33744 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 33745 # Prefer a ksh shell builtin over an external printf program on Solaris, 33746 # but without wasting forks for bash or zsh. 33747 if test -z "$BASH_VERSION$ZSH_VERSION" \ 33748 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 33749 as_echo='print -r --' 33750 as_echo_n='print -rn --' 33751 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 33752 as_echo='printf %s\n' 33753 as_echo_n='printf %s' 33754 else 33755 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 33756 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 33757 as_echo_n='/usr/ucb/echo -n' 33758 else 33759 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 33760 as_echo_n_body='eval 33761 arg=$1; 33762 case $arg in #( 33763 *"$as_nl"*) 33764 expr "X$arg" : "X\\(.*\\)$as_nl"; 33765 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 33766 esac; 33767 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 33768 ' 33769 export as_echo_n_body 33770 as_echo_n='sh -c $as_echo_n_body as_echo' 33771 fi 33772 export as_echo_body 33773 as_echo='sh -c $as_echo_body as_echo' 33774 fi 33775 33776 # The user is always right. 33777 if test "${PATH_SEPARATOR+set}" != set; then 33778 PATH_SEPARATOR=: 33779 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 33780 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 33781 PATH_SEPARATOR=';' 33782 } 33783 fi 33784 33785 33786 # IFS 33787 # We need space, tab and new line, in precisely that order. Quoting is 33788 # there to prevent editors from complaining about space-tab. 33789 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 33790 # splitting by setting IFS to empty value.) 33791 IFS=" "" $as_nl" 33792 33793 # Find who we are. Look in the path if we contain no directory separator. 33794 as_myself= 33795 case $0 in #(( 33796 *[\\/]* ) as_myself=$0 ;; 33797 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33798 for as_dir in $PATH 33799 do 33800 IFS=$as_save_IFS 33801 test -z "$as_dir" && as_dir=. 33802 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 33803 done 33804 IFS=$as_save_IFS 33805 33806 ;; 33807 esac 33808 # We did not find ourselves, most probably we were run as `sh COMMAND' 33809 # in which case we are not to be found in the path. 33810 if test "x$as_myself" = x; then 33811 as_myself=$0 33812 fi 33813 if test ! -f "$as_myself"; then 33814 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 33815 exit 1 33816 fi 33817 33818 # Unset variables that we do not need and which cause bugs (e.g. in 33819 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 33820 # suppresses any "Segmentation fault" message there. '((' could 33821 # trigger a bug in pdksh 5.2.14. 33822 for as_var in BASH_ENV ENV MAIL MAILPATH 33823 do eval test x\${$as_var+set} = xset \ 33824 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 33825 done 33826 PS1='$ ' 33827 PS2='> ' 33828 PS4='+ ' 33829 33830 # NLS nuisances. 33831 LC_ALL=C 33832 export LC_ALL 33833 LANGUAGE=C 33834 export LANGUAGE 33835 33836 # CDPATH. 33837 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 33838 33839 33840 # as_fn_error STATUS ERROR [LINENO LOG_FD] 33841 # ---------------------------------------- 33842 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 33843 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 33844 # script with STATUS, using 1 if that was 0. 33845 as_fn_error () 33846 { 33847 as_status=$1; test $as_status -eq 0 && as_status=1 33848 if test "$4"; then 33849 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 33850 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 33851 fi 33852 $as_echo "$as_me: error: $2" >&2 33853 as_fn_exit $as_status 33854 } # as_fn_error 33855 33856 33857 # as_fn_set_status STATUS 33858 # ----------------------- 33859 # Set $? to STATUS, without forking. 33860 as_fn_set_status () 33861 { 33862 return $1 33863 } # as_fn_set_status 33864 33865 # as_fn_exit STATUS 33866 # ----------------- 33867 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 33868 as_fn_exit () 33869 { 33870 set +e 33871 as_fn_set_status $1 33872 exit $1 33873 } # as_fn_exit 33874 33875 # as_fn_unset VAR 33876 # --------------- 33877 # Portably unset VAR. 33878 as_fn_unset () 33879 { 33880 { eval $1=; unset $1;} 33881 } 33882 as_unset=as_fn_unset 33883 # as_fn_append VAR VALUE 33884 # ---------------------- 33885 # Append the text in VALUE to the end of the definition contained in VAR. Take 33886 # advantage of any shell optimizations that allow amortized linear growth over 33887 # repeated appends, instead of the typical quadratic growth present in naive 33888 # implementations. 33889 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 33890 eval 'as_fn_append () 33891 { 33892 eval $1+=\$2 33893 }' 33894 else 33895 as_fn_append () 33896 { 33897 eval $1=\$$1\$2 33898 } 33899 fi # as_fn_append 33900 33901 # as_fn_arith ARG... 33902 # ------------------ 33903 # Perform arithmetic evaluation on the ARGs, and store the result in the 33904 # global $as_val. Take advantage of shells that can avoid forks. The arguments 33905 # must be portable across $(()) and expr. 33906 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 33907 eval 'as_fn_arith () 33908 { 33909 as_val=$(( $* )) 33910 }' 33911 else 33912 as_fn_arith () 33913 { 33914 as_val=`expr "$@" || test $? -eq 1` 33915 } 33916 fi # as_fn_arith 33917 33918 33919 if expr a : '\(a\)' >/dev/null 2>&1 && 33920 test "X`expr 00001 : '.*\(...\)'`" = X001; then 33921 as_expr=expr 33922 else 33923 as_expr=false 33924 fi 33925 33926 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 33927 as_basename=basename 33928 else 33929 as_basename=false 33930 fi 33931 33932 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 33933 as_dirname=dirname 33934 else 33935 as_dirname=false 33936 fi 33937 33938 as_me=`$as_basename -- "$0" || 33939 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 33940 X"$0" : 'X\(//\)$' \| \ 33941 X"$0" : 'X\(/\)' \| . 2>/dev/null || 33942 $as_echo X/"$0" | 33943 sed '/^.*\/\([^/][^/]*\)\/*$/{ 33944 s//\1/ 33945 q 33946 } 33947 /^X\/\(\/\/\)$/{ 33948 s//\1/ 33949 q 33950 } 33951 /^X\/\(\/\).*/{ 33952 s//\1/ 33953 q 33954 } 33955 s/.*/./; q'` 33956 33957 # Avoid depending upon Character Ranges. 33958 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 33959 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 33960 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 33961 as_cr_digits='0123456789' 33962 as_cr_alnum=$as_cr_Letters$as_cr_digits 33963 33964 ECHO_C= ECHO_N= ECHO_T= 33965 case `echo -n x` in #((((( 33966 -n*) 33967 case `echo 'xy\c'` in 33968 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 33969 xy) ECHO_C='\c';; 33970 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 33971 ECHO_T=' ';; 33972 esac;; 33973 *) 33974 ECHO_N='-n';; 33975 esac 33976 33977 rm -f conf$$ conf$$.exe conf$$.file 33978 if test -d conf$$.dir; then 33979 rm -f conf$$.dir/conf$$.file 33980 else 33981 rm -f conf$$.dir 33982 mkdir conf$$.dir 2>/dev/null 33983 fi 33984 if (echo >conf$$.file) 2>/dev/null; then 33985 if ln -s conf$$.file conf$$ 2>/dev/null; then 33986 as_ln_s='ln -s' 33987 # ... but there are two gotchas: 33988 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 33989 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 33990 # In both cases, we have to default to `cp -p'. 33991 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 33992 as_ln_s='cp -p' 33993 elif ln conf$$.file conf$$ 2>/dev/null; then 33994 as_ln_s=ln 33995 else 33996 as_ln_s='cp -p' 33997 fi 33998 else 33999 as_ln_s='cp -p' 34000 fi 34001 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 34002 rmdir conf$$.dir 2>/dev/null 34003 34004 34005 # as_fn_mkdir_p 34006 # ------------- 34007 # Create "$as_dir" as a directory, including parents if necessary. 34008 as_fn_mkdir_p () 34009 { 34010 34011 case $as_dir in #( 34012 -*) as_dir=./$as_dir;; 34013 esac 34014 test -d "$as_dir" || eval $as_mkdir_p || { 34015 as_dirs= 34016 while :; do 34017 case $as_dir in #( 34018 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 34019 *) as_qdir=$as_dir;; 34020 esac 34021 as_dirs="'$as_qdir' $as_dirs" 34022 as_dir=`$as_dirname -- "$as_dir" || 34023 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 34024 X"$as_dir" : 'X\(//\)[^/]' \| \ 34025 X"$as_dir" : 'X\(//\)$' \| \ 34026 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 34027 $as_echo X"$as_dir" | 34028 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 34029 s//\1/ 34030 q 34031 } 34032 /^X\(\/\/\)[^/].*/{ 34033 s//\1/ 34034 q 34035 } 34036 /^X\(\/\/\)$/{ 34037 s//\1/ 34038 q 34039 } 34040 /^X\(\/\).*/{ 34041 s//\1/ 34042 q 34043 } 34044 s/.*/./; q'` 34045 test -d "$as_dir" && break 34046 done 34047 test -z "$as_dirs" || eval "mkdir $as_dirs" 34048 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 34049 34050 34051 } # as_fn_mkdir_p 34052 if mkdir -p . 2>/dev/null; then 34053 as_mkdir_p='mkdir -p "$as_dir"' 34054 else 34055 test -d ./-p && rmdir ./-p 34056 as_mkdir_p=false 34057 fi 34058 34059 if test -x / >/dev/null 2>&1; then 34060 as_test_x='test -x' 34061 else 34062 if ls -dL / >/dev/null 2>&1; then 34063 as_ls_L_option=L 34064 else 34065 as_ls_L_option= 34066 fi 34067 as_test_x=' 34068 eval sh -c '\'' 34069 if test -d "$1"; then 34070 test -d "$1/."; 34071 else 34072 case $1 in #( 34073 -*)set "./$1";; 34074 esac; 34075 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( 34076 ???[sx]*):;;*)false;;esac;fi 34077 '\'' sh 34078 ' 34079 fi 34080 as_executable_p=$as_test_x 34081 34082 # Sed expression to map a string onto a valid CPP name. 34083 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 34084 34085 # Sed expression to map a string onto a valid variable name. 34086 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 34087 34088 34089 exec 6>&1 34090 ## ----------------------------------- ## 34091 ## Main body of $CONFIG_STATUS script. ## 34092 ## ----------------------------------- ## 34093 _ASEOF 34094 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 34095 34096 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34097 # Save the log message, to keep $0 and so on meaningful, and to 34098 # report actual input values of CONFIG_FILES etc. instead of their 34099 # values after options handling. 34100 ac_log=" 34101 This file was extended by OpenJDK $as_me jdk8, which was 34102 generated by GNU Autoconf 2.68. Invocation command line was 34103 34104 CONFIG_FILES = $CONFIG_FILES 34105 CONFIG_HEADERS = $CONFIG_HEADERS 34106 CONFIG_LINKS = $CONFIG_LINKS 34107 CONFIG_COMMANDS = $CONFIG_COMMANDS 34108 $ $0 $@ 34109 34110 on `(hostname || uname -n) 2>/dev/null | sed 1q` 34111 " 34112 34113 _ACEOF 34114 34115 case $ac_config_files in *" 34116 "*) set x $ac_config_files; shift; ac_config_files=$*;; 34117 esac 34118 34119 case $ac_config_headers in *" 34120 "*) set x $ac_config_headers; shift; ac_config_headers=$*;; 34121 esac 34122 34123 34124 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34125 # Files that config.status was made for. 34126 config_files="$ac_config_files" 34127 config_headers="$ac_config_headers" 34128 34129 _ACEOF 34130 34131 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34132 ac_cs_usage="\ 34133 \`$as_me' instantiates files and other configuration actions 34134 from templates according to the current configuration. Unless the files 34135 and actions are specified as TAGs, all are instantiated by default. 34136 34137 Usage: $0 [OPTION]... [TAG]... 34138 34139 -h, --help print this help, then exit 34140 -V, --version print version number and configuration settings, then exit 34141 --config print configuration, then exit 34142 -q, --quiet, --silent 34143 do not print progress messages 34144 -d, --debug don't remove temporary files 34145 --recheck update $as_me by reconfiguring in the same conditions 34146 --file=FILE[:TEMPLATE] 34147 instantiate the configuration file FILE 34148 --header=FILE[:TEMPLATE] 34149 instantiate the configuration header FILE 34150 34151 Configuration files: 34152 $config_files 34153 34154 Configuration headers: 34155 $config_headers 34156 34157 Report bugs to <build-dev@openjdk.java.net>. 34158 OpenJDK home page: <http://openjdk.java.net>." 34159 34160 _ACEOF 34161 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34162 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 34163 ac_cs_version="\\ 34164 OpenJDK config.status jdk8 34165 configured by $0, generated by GNU Autoconf 2.68, 34166 with options \\"\$ac_cs_config\\" 34167 34168 Copyright (C) 2010 Free Software Foundation, Inc. 34169 This config.status script is free software; the Free Software Foundation 34170 gives unlimited permission to copy, distribute and modify it." 34171 34172 ac_pwd='$ac_pwd' 34173 srcdir='$srcdir' 34174 AWK='$AWK' 34175 test -n "\$AWK" || AWK=awk 34176 _ACEOF 34177 34178 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34179 # The default lists apply if the user does not specify any file. 34180 ac_need_defaults=: 34181 while test $# != 0 34182 do 34183 case $1 in 34184 --*=?*) 34185 ac_option=`expr "X$1" : 'X\([^=]*\)='` 34186 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 34187 ac_shift=: 34188 ;; 34189 --*=) 34190 ac_option=`expr "X$1" : 'X\([^=]*\)='` 34191 ac_optarg= 34192 ac_shift=: 34193 ;; 34194 *) 34195 ac_option=$1 34196 ac_optarg=$2 34197 ac_shift=shift 34198 ;; 34199 esac 34200 34201 case $ac_option in 34202 # Handling of the options. 34203 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 34204 ac_cs_recheck=: ;; 34205 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 34206 $as_echo "$ac_cs_version"; exit ;; 34207 --config | --confi | --conf | --con | --co | --c ) 34208 $as_echo "$ac_cs_config"; exit ;; 34209 --debug | --debu | --deb | --de | --d | -d ) 34210 debug=: ;; 34211 --file | --fil | --fi | --f ) 34212 $ac_shift 34213 case $ac_optarg in 34214 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 34215 '') as_fn_error $? "missing file argument" ;; 34216 esac 34217 as_fn_append CONFIG_FILES " '$ac_optarg'" 34218 ac_need_defaults=false;; 34219 --header | --heade | --head | --hea ) 34220 $ac_shift 34221 case $ac_optarg in 34222 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 34223 esac 34224 as_fn_append CONFIG_HEADERS " '$ac_optarg'" 34225 ac_need_defaults=false;; 34226 --he | --h) 34227 # Conflict between --help and --header 34228 as_fn_error $? "ambiguous option: \`$1' 34229 Try \`$0 --help' for more information.";; 34230 --help | --hel | -h ) 34231 $as_echo "$ac_cs_usage"; exit ;; 34232 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 34233 | -silent | --silent | --silen | --sile | --sil | --si | --s) 34234 ac_cs_silent=: ;; 34235 34236 # This is an error. 34237 -*) as_fn_error $? "unrecognized option: \`$1' 34238 Try \`$0 --help' for more information." ;; 34239 34240 *) as_fn_append ac_config_targets " $1" 34241 ac_need_defaults=false ;; 34242 34243 esac 34244 shift 34245 done 34246 34247 ac_configure_extra_args= 34248 34249 if $ac_cs_silent; then 34250 exec 6>/dev/null 34251 ac_configure_extra_args="$ac_configure_extra_args --silent" 34252 fi 34253 34254 _ACEOF 34255 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34256 if \$ac_cs_recheck; then 34257 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 34258 shift 34259 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 34260 CONFIG_SHELL='$SHELL' 34261 export CONFIG_SHELL 34262 exec "\$@" 34263 fi 34264 34265 _ACEOF 34266 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34267 exec 5>>config.log 34268 { 34269 echo 34270 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 34271 ## Running $as_me. ## 34272 _ASBOX 34273 $as_echo "$ac_log" 34274 } >&5 34275 34276 _ACEOF 34277 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34278 _ACEOF 34279 34280 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34281 34282 # Handling of arguments. 34283 for ac_config_target in $ac_config_targets 34284 do 34285 case $ac_config_target in 34286 "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;; 34287 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 34288 "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;; 34289 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 34290 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 34291 "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;; 34292 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 34293 34294 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 34295 esac 34296 done 34297 34298 34299 # If the user did not use the arguments to specify the items to instantiate, 34300 # then the envvar interface is used. Set only those that are not. 34301 # We use the long form for the default assignment because of an extremely 34302 # bizarre bug on SunOS 4.1.3. 34303 if $ac_need_defaults; then 34304 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 34305 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers 34306 fi 34307 34308 # Have a temporary directory for convenience. Make it in the build tree 34309 # simply because there is no reason against having it here, and in addition, 34310 # creating and moving files from /tmp can sometimes cause problems. 34311 # Hook for its removal unless debugging. 34312 # Note that there is a small window in which the directory will not be cleaned: 34313 # after its creation but before its name has been assigned to `$tmp'. 34314 $debug || 34315 { 34316 tmp= ac_tmp= 34317 trap 'exit_status=$? 34318 : "${ac_tmp:=$tmp}" 34319 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 34320 ' 0 34321 trap 'as_fn_exit 1' 1 2 13 15 34322 } 34323 # Create a (secure) tmp directory for tmp files. 34324 34325 { 34326 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 34327 test -d "$tmp" 34328 } || 34329 { 34330 tmp=./conf$$-$RANDOM 34331 (umask 077 && mkdir "$tmp") 34332 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 34333 ac_tmp=$tmp 34334 34335 # Set up the scripts for CONFIG_FILES section. 34336 # No need to generate them if there are no CONFIG_FILES. 34337 # This happens for instance with `./config.status config.h'. 34338 if test -n "$CONFIG_FILES"; then 34339 34340 34341 ac_cr=`echo X | tr X '\015'` 34342 # On cygwin, bash can eat \r inside `` if the user requested igncr. 34343 # But we know of no other shell where ac_cr would be empty at this 34344 # point, so we can use a bashism as a fallback. 34345 if test "x$ac_cr" = x; then 34346 eval ac_cr=\$\'\\r\' 34347 fi 34348 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 34349 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 34350 ac_cs_awk_cr='\\r' 34351 else 34352 ac_cs_awk_cr=$ac_cr 34353 fi 34354 34355 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 34356 _ACEOF 34357 34358 34359 { 34360 echo "cat >conf$$subs.awk <<_ACEOF" && 34361 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 34362 echo "_ACEOF" 34363 } >conf$$subs.sh || 34364 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34365 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 34366 ac_delim='%!_!# ' 34367 for ac_last_try in false false false false false :; do 34368 . ./conf$$subs.sh || 34369 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34370 34371 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 34372 if test $ac_delim_n = $ac_delim_num; then 34373 break 34374 elif $ac_last_try; then 34375 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 34376 else 34377 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 34378 fi 34379 done 34380 rm -f conf$$subs.sh 34381 34382 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34383 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 34384 _ACEOF 34385 sed -n ' 34386 h 34387 s/^/S["/; s/!.*/"]=/ 34388 p 34389 g 34390 s/^[^!]*!// 34391 :repl 34392 t repl 34393 s/'"$ac_delim"'$// 34394 t delim 34395 :nl 34396 h 34397 s/\(.\{148\}\)..*/\1/ 34398 t more1 34399 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 34400 p 34401 n 34402 b repl 34403 :more1 34404 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 34405 p 34406 g 34407 s/.\{148\}// 34408 t nl 34409 :delim 34410 h 34411 s/\(.\{148\}\)..*/\1/ 34412 t more2 34413 s/["\\]/\\&/g; s/^/"/; s/$/"/ 34414 p 34415 b 34416 :more2 34417 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 34418 p 34419 g 34420 s/.\{148\}// 34421 t delim 34422 ' <conf$$subs.awk | sed ' 34423 /^[^""]/{ 34424 N 34425 s/\n// 34426 } 34427 ' >>$CONFIG_STATUS || ac_write_fail=1 34428 rm -f conf$$subs.awk 34429 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34430 _ACAWK 34431 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 34432 for (key in S) S_is_set[key] = 1 34433 FS = "" 34434 34435 } 34436 { 34437 line = $ 0 34438 nfields = split(line, field, "@") 34439 substed = 0 34440 len = length(field[1]) 34441 for (i = 2; i < nfields; i++) { 34442 key = field[i] 34443 keylen = length(key) 34444 if (S_is_set[key]) { 34445 value = S[key] 34446 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 34447 len += length(value) + length(field[++i]) 34448 substed = 1 34449 } else 34450 len += 1 + keylen 34451 } 34452 34453 print line 34454 } 34455 34456 _ACAWK 34457 _ACEOF 34458 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34459 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 34460 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 34461 else 34462 cat 34463 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 34464 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 34465 _ACEOF 34466 34467 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 34468 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 34469 # trailing colons and then remove the whole line if VPATH becomes empty 34470 # (actually we leave an empty line to preserve line numbers). 34471 if test "x$srcdir" = x.; then 34472 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 34473 h 34474 s/// 34475 s/^/:/ 34476 s/[ ]*$/:/ 34477 s/:\$(srcdir):/:/g 34478 s/:\${srcdir}:/:/g 34479 s/:@srcdir@:/:/g 34480 s/^:*// 34481 s/:*$// 34482 x 34483 s/\(=[ ]*\).*/\1/ 34484 G 34485 s/\n// 34486 s/^[^=]*=[ ]*$// 34487 }' 34488 fi 34489 34490 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34491 fi # test -n "$CONFIG_FILES" 34492 34493 # Set up the scripts for CONFIG_HEADERS section. 34494 # No need to generate them if there are no CONFIG_HEADERS. 34495 # This happens for instance with `./config.status Makefile'. 34496 if test -n "$CONFIG_HEADERS"; then 34497 cat >"$ac_tmp/defines.awk" <<\_ACAWK || 34498 BEGIN { 34499 _ACEOF 34500 34501 # Transform confdefs.h into an awk script `defines.awk', embedded as 34502 # here-document in config.status, that substitutes the proper values into 34503 # config.h.in to produce config.h. 34504 34505 # Create a delimiter string that does not exist in confdefs.h, to ease 34506 # handling of long lines. 34507 ac_delim='%!_!# ' 34508 for ac_last_try in false false :; do 34509 ac_tt=`sed -n "/$ac_delim/p" confdefs.h` 34510 if test -z "$ac_tt"; then 34511 break 34512 elif $ac_last_try; then 34513 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 34514 else 34515 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 34516 fi 34517 done 34518 34519 # For the awk script, D is an array of macro values keyed by name, 34520 # likewise P contains macro parameters if any. Preserve backslash 34521 # newline sequences. 34522 34523 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* 34524 sed -n ' 34525 s/.\{148\}/&'"$ac_delim"'/g 34526 t rset 34527 :rset 34528 s/^[ ]*#[ ]*define[ ][ ]*/ / 34529 t def 34530 d 34531 :def 34532 s/\\$// 34533 t bsnl 34534 s/["\\]/\\&/g 34535 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 34536 D["\1"]=" \3"/p 34537 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p 34538 d 34539 :bsnl 34540 s/["\\]/\\&/g 34541 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 34542 D["\1"]=" \3\\\\\\n"\\/p 34543 t cont 34544 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p 34545 t cont 34546 d 34547 :cont 34548 n 34549 s/.\{148\}/&'"$ac_delim"'/g 34550 t clear 34551 :clear 34552 s/\\$// 34553 t bsnlc 34554 s/["\\]/\\&/g; s/^/"/; s/$/"/p 34555 d 34556 :bsnlc 34557 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p 34558 b cont 34559 ' <confdefs.h | sed ' 34560 s/'"$ac_delim"'/"\\\ 34561 "/g' >>$CONFIG_STATUS || ac_write_fail=1 34562 34563 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34564 for (key in D) D_is_set[key] = 1 34565 FS = "" 34566 } 34567 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { 34568 line = \$ 0 34569 split(line, arg, " ") 34570 if (arg[1] == "#") { 34571 defundef = arg[2] 34572 mac1 = arg[3] 34573 } else { 34574 defundef = substr(arg[1], 2) 34575 mac1 = arg[2] 34576 } 34577 split(mac1, mac2, "(") #) 34578 macro = mac2[1] 34579 prefix = substr(line, 1, index(line, defundef) - 1) 34580 if (D_is_set[macro]) { 34581 # Preserve the white space surrounding the "#". 34582 print prefix "define", macro P[macro] D[macro] 34583 next 34584 } else { 34585 # Replace #undef with comments. This is necessary, for example, 34586 # in the case of _POSIX_SOURCE, which is predefined and required 34587 # on some systems where configure will not decide to define it. 34588 if (defundef == "undef") { 34589 print "/*", prefix defundef, macro, "*/" 34590 next 34591 } 34592 } 34593 } 34594 { print } 34595 _ACAWK 34596 _ACEOF 34597 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34598 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 34599 fi # test -n "$CONFIG_HEADERS" 34600 34601 34602 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " 34603 shift 34604 for ac_tag 34605 do 34606 case $ac_tag in 34607 :[FHLC]) ac_mode=$ac_tag; continue;; 34608 esac 34609 case $ac_mode$ac_tag in 34610 :[FHL]*:*);; 34611 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 34612 :[FH]-) ac_tag=-:-;; 34613 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 34614 esac 34615 ac_save_IFS=$IFS 34616 IFS=: 34617 set x $ac_tag 34618 IFS=$ac_save_IFS 34619 shift 34620 ac_file=$1 34621 shift 34622 34623 case $ac_mode in 34624 :L) ac_source=$1;; 34625 :[FH]) 34626 ac_file_inputs= 34627 for ac_f 34628 do 34629 case $ac_f in 34630 -) ac_f="$ac_tmp/stdin";; 34631 *) # Look for the file first in the build tree, then in the source tree 34632 # (if the path is not absolute). The absolute path cannot be DOS-style, 34633 # because $ac_f cannot contain `:'. 34634 test -f "$ac_f" || 34635 case $ac_f in 34636 [\\/$]*) false;; 34637 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 34638 esac || 34639 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 34640 esac 34641 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 34642 as_fn_append ac_file_inputs " '$ac_f'" 34643 done 34644 34645 # Let's still pretend it is `configure' which instantiates (i.e., don't 34646 # use $as_me), people would be surprised to read: 34647 # /* config.h. Generated by config.status. */ 34648 configure_input='Generated from '` 34649 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 34650 `' by configure.' 34651 if test x"$ac_file" != x-; then 34652 configure_input="$ac_file. $configure_input" 34653 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 34654 $as_echo "$as_me: creating $ac_file" >&6;} 34655 fi 34656 # Neutralize special characters interpreted by sed in replacement strings. 34657 case $configure_input in #( 34658 *\&* | *\|* | *\\* ) 34659 ac_sed_conf_input=`$as_echo "$configure_input" | 34660 sed 's/[\\\\&|]/\\\\&/g'`;; #( 34661 *) ac_sed_conf_input=$configure_input;; 34662 esac 34663 34664 case $ac_tag in 34665 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 34666 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 34667 esac 34668 ;; 34669 esac 34670 34671 ac_dir=`$as_dirname -- "$ac_file" || 34672 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 34673 X"$ac_file" : 'X\(//\)[^/]' \| \ 34674 X"$ac_file" : 'X\(//\)$' \| \ 34675 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 34676 $as_echo X"$ac_file" | 34677 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 34678 s//\1/ 34679 q 34680 } 34681 /^X\(\/\/\)[^/].*/{ 34682 s//\1/ 34683 q 34684 } 34685 /^X\(\/\/\)$/{ 34686 s//\1/ 34687 q 34688 } 34689 /^X\(\/\).*/{ 34690 s//\1/ 34691 q 34692 } 34693 s/.*/./; q'` 34694 as_dir="$ac_dir"; as_fn_mkdir_p 34695 ac_builddir=. 34696 34697 case "$ac_dir" in 34698 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 34699 *) 34700 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 34701 # A ".." for each directory in $ac_dir_suffix. 34702 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 34703 case $ac_top_builddir_sub in 34704 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 34705 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 34706 esac ;; 34707 esac 34708 ac_abs_top_builddir=$ac_pwd 34709 ac_abs_builddir=$ac_pwd$ac_dir_suffix 34710 # for backward compatibility: 34711 ac_top_builddir=$ac_top_build_prefix 34712 34713 case $srcdir in 34714 .) # We are building in place. 34715 ac_srcdir=. 34716 ac_top_srcdir=$ac_top_builddir_sub 34717 ac_abs_top_srcdir=$ac_pwd ;; 34718 [\\/]* | ?:[\\/]* ) # Absolute name. 34719 ac_srcdir=$srcdir$ac_dir_suffix; 34720 ac_top_srcdir=$srcdir 34721 ac_abs_top_srcdir=$srcdir ;; 34722 *) # Relative name. 34723 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 34724 ac_top_srcdir=$ac_top_build_prefix$srcdir 34725 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 34726 esac 34727 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 34728 34729 34730 case $ac_mode in 34731 :F) 34732 # 34733 # CONFIG_FILE 34734 # 34735 34736 _ACEOF 34737 34738 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34739 # If the template does not know about datarootdir, expand it. 34740 # FIXME: This hack should be removed a few years after 2.60. 34741 ac_datarootdir_hack=; ac_datarootdir_seen= 34742 ac_sed_dataroot=' 34743 /datarootdir/ { 34744 p 34745 q 34746 } 34747 /@datadir@/p 34748 /@docdir@/p 34749 /@infodir@/p 34750 /@localedir@/p 34751 /@mandir@/p' 34752 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 34753 *datarootdir*) ac_datarootdir_seen=yes;; 34754 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 34755 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 34756 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 34757 _ACEOF 34758 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34759 ac_datarootdir_hack=' 34760 s&@datadir@&$datadir&g 34761 s&@docdir@&$docdir&g 34762 s&@infodir@&$infodir&g 34763 s&@localedir@&$localedir&g 34764 s&@mandir@&$mandir&g 34765 s&\\\${datarootdir}&$datarootdir&g' ;; 34766 esac 34767 _ACEOF 34768 34769 # Neutralize VPATH when `$srcdir' = `.'. 34770 # Shell code in configure.ac might set extrasub. 34771 # FIXME: do we really want to maintain this feature? 34772 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 34773 ac_sed_extra="$ac_vpsub 34774 $extrasub 34775 _ACEOF 34776 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 34777 :t 34778 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 34779 s|@configure_input@|$ac_sed_conf_input|;t t 34780 s&@top_builddir@&$ac_top_builddir_sub&;t t 34781 s&@top_build_prefix@&$ac_top_build_prefix&;t t 34782 s&@srcdir@&$ac_srcdir&;t t 34783 s&@abs_srcdir@&$ac_abs_srcdir&;t t 34784 s&@top_srcdir@&$ac_top_srcdir&;t t 34785 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 34786 s&@builddir@&$ac_builddir&;t t 34787 s&@abs_builddir@&$ac_abs_builddir&;t t 34788 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 34789 $ac_datarootdir_hack 34790 " 34791 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 34792 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34793 34794 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 34795 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 34796 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 34797 "$ac_tmp/out"`; test -z "$ac_out"; } && 34798 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 34799 which seems to be undefined. Please make sure it is defined" >&5 34800 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 34801 which seems to be undefined. Please make sure it is defined" >&2;} 34802 34803 rm -f "$ac_tmp/stdin" 34804 case $ac_file in 34805 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 34806 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 34807 esac \ 34808 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34809 ;; 34810 :H) 34811 # 34812 # CONFIG_HEADER 34813 # 34814 if test x"$ac_file" != x-; then 34815 { 34816 $as_echo "/* $configure_input */" \ 34817 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" 34818 } >"$ac_tmp/config.h" \ 34819 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34820 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then 34821 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 34822 $as_echo "$as_me: $ac_file is unchanged" >&6;} 34823 else 34824 rm -f "$ac_file" 34825 mv "$ac_tmp/config.h" "$ac_file" \ 34826 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 34827 fi 34828 else 34829 $as_echo "/* $configure_input */" \ 34830 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ 34831 || as_fn_error $? "could not create -" "$LINENO" 5 34832 fi 34833 ;; 34834 34835 34836 esac 34837 34838 done # for ac_tag 34839 34840 34841 as_fn_exit 0 34842 _ACEOF 34843 ac_clean_files=$ac_clean_files_save 34844 34845 test $ac_write_fail = 0 || 34846 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 34847 34848 34849 # configure is writing to config.log, and then calls config.status. 34850 # config.status does its own redirection, appending to config.log. 34851 # Unfortunately, on DOS this fails, as config.log is still kept open 34852 # by configure, so config.status won't be able to write to it; its 34853 # output is simply discarded. So we exec the FD to /dev/null, 34854 # effectively closing config.log, so it can be properly (re)opened and 34855 # appended to by config.status. When coming back to configure, we 34856 # need to make the FD available again. 34857 if test "$no_create" != yes; then 34858 ac_cs_success=: 34859 ac_config_status_args= 34860 test "$silent" = yes && 34861 ac_config_status_args="$ac_config_status_args --quiet" 34862 exec 5>/dev/null 34863 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 34864 exec 5>>config.log 34865 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 34866 # would make configure fail if this is the last instruction. 34867 $ac_cs_success || as_fn_exit 1 34868 fi 34869 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 34870 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 34871 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 34872 fi 34873 34874 34875 # Make the compare script executable 34876 $CHMOD +x $OUTPUT_ROOT/compare.sh 34877 34878 # Finally output some useful information to the user 34879 34880 # Finally output some useful information to the user 34881 34882 if test "x$CCACHE_FOUND" != x; then 34883 if test "x$HAS_GOOD_CCACHE" = x; then 34884 CCACHE_STATUS="installed, but disabled (version older than 3.1.4)" 34885 CCACHE_HELP_MSG="You have ccache installed, but it is a version prior to 3.1.4. Try upgrading." 34886 else 34887 CCACHE_STATUS="installed and in use" 34888 fi 34889 else 34890 if test "x$GCC" = xyes; then 34891 CCACHE_STATUS="not installed (consider installing)" 34892 CCACHE_HELP_MSG="You do not have ccache installed. Try installing it." 34893 else 34894 CCACHE_STATUS="not available for your system" 34895 fi 34896 fi 34897 34898 printf "\n" 34899 printf "====================================================\n" 34900 printf "A new configuration has been successfully created in\n" 34901 printf "$OUTPUT_ROOT\n" 34902 if test "x$CONFIGURE_COMMAND_LINE" != x; then 34903 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 34904 else 34905 printf "using default settings.\n" 34906 fi 34907 34908 printf "\n" 34909 printf "Configuration summary:\n" 34910 printf "* Debug level: $DEBUG_LEVEL\n" 34911 printf "* JDK variant: $JDK_VARIANT\n" 34912 printf "* JVM variants: $with_jvm_variants\n" 34913 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 34914 34915 printf "\n" 34916 printf "Tools summary:\n" 34917 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 34918 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 34919 fi 34920 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 34921 printf "* C Compiler: $CC_VENDOR version $CC_VERSION (at $CC)\n" 34922 printf "* C++ Compiler: $CXX_VENDOR version $CXX_VERSION (at $CXX)\n" 34923 34924 printf "\n" 34925 printf "Build performance summary:\n" 34926 printf "* Cores to use: $JOBS\n" 34927 printf "* Memory limit: $MEMORY_SIZE MB\n" 34928 printf "* ccache status: $CCACHE_STATUS\n" 34929 printf "\n" 34930 34931 if test "x$CCACHE_HELP_MSG" != x && test "x$HIDE_PERFORMANCE_HINTS" = "xno"; then 34932 printf "Build performance tip: ccache gives a tremendous speedup for C++ recompilations.\n" 34933 printf "$CCACHE_HELP_MSG\n" 34934 34935 # Print a helpful message on how to acquire the necessary build dependency. 34936 # ccache is the help tag: freetyp2, cups, pulse, alsa etc 34937 MISSING_DEPENDENCY=ccache 34938 PKGHANDLER_COMMAND= 34939 34940 case $PKGHANDLER in 34941 apt-get) 34942 apt_help $MISSING_DEPENDENCY ;; 34943 yum) 34944 yum_help $MISSING_DEPENDENCY ;; 34945 port) 34946 port_help $MISSING_DEPENDENCY ;; 34947 pkgutil) 34948 pkgutil_help $MISSING_DEPENDENCY ;; 34949 pkgadd) 34950 pkgadd_help $MISSING_DEPENDENCY ;; 34951 * ) 34952 break ;; 34953 esac 34954 34955 if test "x$PKGHANDLER_COMMAND" != x; then 34956 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34957 fi 34958 34959 printf "$HELP_MSG\n" 34960 printf "\n" 34961 fi 34962 34963 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then 34964 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 34965 printf "will result in longer build times.\n" 34966 printf "\n" 34967 fi 34968 34969 if test "x$FOUND_ALT_VARIABLES" != "x"; then 34970 printf "WARNING: You have old-style ALT_ environment variables set.\n" 34971 printf "These are not respected, and will be ignored. It is recommended\n" 34972 printf "that you clean your environment. The following variables are set:\n" 34973 printf "$FOUND_ALT_VARIABLES\n" 34974 printf "\n" 34975 fi 34976 34977 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 34978 printf "WARNING: Your build output directory is not on a local disk.\n" 34979 printf "This will severely degrade build performance!\n" 34980 printf "It is recommended that you create an output directory on a local disk,\n" 34981 printf "and run the configure script again from that directory.\n" 34982 printf "\n" 34983 fi 34984 34985 if test "x$IS_RECONFIGURE" = "xyes"; then 34986 printf "WARNING: The result of this configuration has overridden an older\n" 34987 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 34988 printf "proper build. Failure to do so might result in strange build problems.\n" 34989 printf "\n" 34990 fi 34991 |